/* 機種選定・御見積りページ専用スタイル (tower/estimate.html) */

.tower-estimate-confirm-prompt {
  color: #c00;
  font-size: 1.4rem;
  line-height: 1.6;
  margin: 3.2rem 0;
  text-align: center;
  font-weight: 700;
}

.tower-project-name-note {
  flex: 1;
  min-width: 0;
  color: #4a545d;
  font-size: 1.1rem;
  font-weight: 400;
  line-height: 1.5;
}

.page-tower-estimate,
.page-tower-estimate-request {
  padding-top: var(--site-header-offset, 80px);
  overflow-x: auto;
}

.page-tower-estimate-result,
.page-tower-specification {
  overflow-x: auto;
}

@media all and (max-width: 768px) {

  .page-tower-estimate,
  .page-tower-estimate-request {
    margin-top: 0;
    padding-top: 0;
  }
}

.page-tower-estimate .sub-page-hero,
.page-tower-estimate-request .sub-page-hero,
.page-tower-estimate-result .sub-page-hero,
.page-tower-specification .sub-page-hero {
  margin-top: 0;
  padding: 4.2rem 0 0;
  height: 37.4rem;
}

/* PC only — on SP the base absolute centering applies instead */
@media screen and (min-width: 769px) {
  .page-tower-estimate .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title {
    width: 100%;
    position: unset;
    left: unset;
    top: unset;
    transform: unset;
    margin-top: 11.5rem;
    font-weight: 500;
  }
}

@media all and (max-width: 768px) {

  .page-tower-estimate .tower-hero-wrapper,
  .page-tower-estimate-request .tower-hero-wrapper,
  .page-tower-estimate-result .tower-hero-wrapper,
  .page-tower-specification .tower-hero-wrapper {
    margin-top: -2px;
  }

  .page-tower-estimate .sub-page-hero,
  .page-tower-estimate-request .sub-page-hero,
  .page-tower-estimate-result .sub-page-hero,
  .page-tower-specification .sub-page-hero {
    margin-top: 0;
    min-height: 37.2rem;
    height: auto;
    padding: 2.1rem 0;
  }

  /* Reset content div to normal flow so title top/left are relative to hero top */
  .page-tower-estimate .sub-page-hero .product-detail-hero__content,
  .page-tower-estimate-request .sub-page-hero .product-detail-hero__content,
  .page-tower-estimate-result .sub-page-hero .product-detail-hero__content,
  .page-tower-specification .sub-page-hero .product-detail-hero__content {
    position: relative;
    top: unset;
    left: unset;
    transform: none;
    width: 100%;
  }

  .page-tower-estimate .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate-request .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-estimate-result .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content--no-subtitle .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content:not(:has(.product-detail-hero__subtitle)) .product-detail-hero__title,
  .page-tower-specification .product-detail-hero__content:has(.product-detail-hero__subtitle:empty) .product-detail-hero__title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    text-align: center;
    font-size: 2.4rem;
    margin-top: 0;
  }
}

/* SubPageHero border-radius — match renewal (5.5rem) */
.page-tower-estimate .product-detail-hero {
  border-radius: 0 0 5.5rem 5.5rem;
}

/* ヒーローセクション */
.estimate-hero {
  background:
    linear-gradient(135deg, rgba(80, 70, 120, 0.85), rgba(140, 170, 220, 0.7)),
    url(../../img/tower/hero-bg.png);
  background-size: cover;
  background-position: center;
  color: #fff;
  padding: 8rem 0;
  border-radius: 0 0 4rem 4rem;
  text-align: center;
}

.estimate-hero h1 {
  font-size: 4.8rem;
  font-weight: 400;
  letter-spacing: 0.1em;
}

/* フォームコンテンツ */
.form-content {
  max-width: 101rem;
  margin: 6rem auto 10rem;
  padding: 0 4rem;
}

.tower-estimate-layout {
  max-width: 120rem;
  margin: 4.4rem auto 0;
  padding: 0 3rem 0 4rem;
  display: flex;
  gap: 2.8rem;
  align-items: flex-start;
}

.tower-estimate-layout .product-detail-main__content {
  flex: 1;
  min-width: 0;
}

.page-tower-estimate .tower-estimate-layout .form-content {
  max-width: none;
  margin: 0;
  padding: 0;
}

.tower-estimate-background {
  background: #f7f7f7;
  height: 4rem;
  border-radius: 0 4rem 0 0;
}

@media screen and (min-width: 897px) {
  .page-tower-estimate #container {
    min-width: 1120px;
  }

  .page-tower-estimate .tower-estimate-layout .product-detail-main__sidebar .sidebar-box {
    position: sticky;
    top: 14rem;
    height: fit-content;
  }
}

.form-intro {
  text-align: center;
  font-size: 1.6rem;
  margin-bottom: 5rem;
  color: #4a545d;
}

.estimate-test-block {
  padding: 3rem;
  margin-bottom: 4rem;
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 0.8rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.estimate-test-block__title {
  font-size: 2rem;
  margin-bottom: 2.4rem;
  color: #4a545d;
}

.estimate-test-grid-half {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
}

/* 製品情報ボックス */
.product-info-box {
  margin-bottom: 5rem;
  background-color: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}

.product-title-box {
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 0.8rem;
  padding: 3rem 4rem;
  margin-bottom: 4rem;
  box-shadow: 0 0 10px rgba(222, 228, 234, 0.8);
}

.product-info-box h2 {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.8rem;
  color: #4a545d;
  line-height: 1.5;
}

.product-name-tail {
  white-space: nowrap;
}

.product-info-box h3 {
  font-size: 1.8rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0;
  color: #4a545d;
}

.product-info-message {
  margin: 1.2rem 0 0;
  text-align: center;
  color: #b12222;
  font-size: 1.5rem;
  line-height: 1.7;
}

/* 仕様テーブル */
.spec-table {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0 3rem;
  border: none;
  border-radius: 0;
  overflow: visible;
}

.spec-cell {
  padding: 2rem 0;
  border-bottom: 1px solid #e0e0e0;
  border-right: none;
}

.spec-table .spec-cell:last-child,
.spec-table .spec-cell:nth-last-child(2),
.spec-table .spec-cell:nth-last-child(3),
.spec-table .spec-cell:nth-last-child(4) {
  border-bottom: 1px solid #e0e0e0;
}

.spec-label {
  color: var(--, #4a545d);
  leading-trim: both;
  text-edge: cap;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 1.6rem;
  font-style: normal;
  font-weight: 700;
  line-height: 5.3rem;
  margin-bottom: 0.8rem;
}

.spec-value {
  color: #4a545d;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 1.6rem;
  font-style: normal;
  font-weight: 400;
  line-height: 2.4rem;
  leading-trim: both;
  text-edge: cap;
}

.spec-value-small {
  color: #4a545d;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 1.4rem;
  font-style: normal;
  font-weight: 400;
  line-height: 2.4rem;
  leading-trim: both;
  text-edge: cap;
}

.spec-capacity-line {
  white-space: nowrap;
}

.spec-cell.header {
  background-color: #f5f5f5;
  font-weight: 700;
  text-align: center;
}

.spec-cell.label {
  background-color: #f5f5f5;
  font-weight: 700;
}

/* 金額表示エリア */
.price-display {
  margin-top: 3rem;
  padding: 2rem;
  background-color: #f7f7f7;
  border-radius: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.price-label {
  font-size: 1.6rem;
  font-weight: 700;
  color: #4a545d;
}

.price-value {
  font-size: 2.4rem;
  font-weight: 700;
  color: #eb3b3b;
}

/* セクション説明 */
.section-note {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 4rem;
  color: #4a545d;
  line-height: 1.8;
}

/* フォームグループ（estimate専用） */
.form-content .form-group {
  margin-bottom: 3rem;
}

.customer-info-form .form-group {
  margin-bottom: 4rem;
}

.form-content .form-label {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 0.9rem;
  font-size: 1.6rem;
  font-weight: 700;
  color: #4a545d;
}

/* セレクトボックス（estimate専用） */
.form-content .select-box select {
  width: 100%;
  min-height: 4.3rem;
  padding: 1.5rem 4rem 1.9rem 1.6rem;
  font-size: 1.6rem;
  line-height: 1.4;
  border-radius: 0.6rem;
}

.form-content .tower-delivery-location-select-box {
  width: 100%;
  max-width: 16rem;
}

.form-content .tower-delivery-location-select-box select {
  width: 100%;
}

.form-content .select-box select option {
  color: #4a545d;
  background-color: #fff;
}

.source-grid-half {
  grid-column: 1 / -1;
}

.source-grid-half .source-grid-cell .select-box {
  width: 100%;
}

.source-grid-half .source-grid-cell .select-box select {
  padding: 1.8rem 4rem 1.8rem 1.6rem;
}

.page-tower-estimate-test .quote-form__select,
.page-tower-estimate-test .quote-form__select option {
  color: #4a545d !important;
  background-color: #fff !important;
  -webkit-text-fill-color: #4a545d;
}

.page-tower-estimate-test .quote-form__select {
  height: auto;
  min-height: 4.8rem;
  padding: 1.2rem 4rem 1.2rem 1.6rem;
  line-height: 1.5;
}

.page-tower-estimate-test .quote-form__select-wrap::after {
  content: none;
}

.form-content .select-box::after {
  width: 1rem;
  height: 0.6rem;
  right: 2rem;
}

/* 入力フィールド（estimate専用） */
.form-content .input-box input,
.form-content .input-box textarea {
  padding: 1.6rem;
  font-size: 1.6rem;
  border-radius: 0.6rem;
  background-color: #f5f5f5;
  border: 1px solid #d5d5d5;
}

/* チェックボックス・ラジオグループ（estimate専用） */
.form-content .checkbox-group,
.form-content .radio-group {
  flex-wrap: wrap;
}

.form-content .checkbox-item,
.form-content .radio-item {
  gap: 0.8rem;
}

.form-content .checkbox-item .select-box {
  width: 9.2rem;
}

.form-content .checkbox-item select {
  width: 9.2rem;
  padding: 0.8rem 4rem 0.8rem 1.6rem;
  font-size: 1.5rem;
}

.form-content .checkbox-item select:disabled {
  color: #999;
  background-color: #f0f0f0;
  cursor: not-allowed;
}

.form-content .checkbox-item input[type='checkbox'],
.form-content .radio-item input[type='radio'] {
  width: 1.8rem;
  height: 1.8rem;
}

/* 郵便番号グループ */
.zip-group {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 25rem;
}

.zip-group input {
  flex: 1;
  text-align: center;
}

.zip-group span {
  color: #4a545d;
  font-size: 1.6rem;
}

/* 電話番号グループ (tank/download.htmlスタイルに統一) */
.phone-group {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.phone-group input {
  padding: 1.6rem;
  font-size: 1.6rem;
  color: #4a545d;
  background-color: #f5f5f5;
  border: 1px solid #d5d5d5;
  border-radius: 0.6rem;
  text-align: start;
  transition: border-color 0.3s;
}

.phone-group input:first-of-type {
  max-width: 9rem;
}

.phone-group input:last-of-type {
  max-width: 9rem;
}

.phone-group input::placeholder {
  color: #999;
}

.phone-group input:focus {
  outline: none;
  border-color: #eb3b3b;
  background-color: #fff;
}

.phone-group span {
  color: #4a545d;
  font-size: 1.6rem;
}

/* TEL/FAXグループ (tank/download.htmlスタイルに統一) */
.form-grid-half {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3.1rem;
  margin-bottom: 0;
}

.tel-fax-group {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem;
}

/* ボタングループ */
.button-group {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-bottom: 6rem;
}

/* ダウンロード関連ボタン・お問い合わせボタン */
.form-content .submit-btn,
.form-content .inquiry-btn {
  color: #222c34 !important;
  text-indent: 0 !important;
  letter-spacing: normal !important;
  text-align: left;
  background: #fff;
  border: none;
  border-radius: 10rem;
  position: relative;
  height: 5.8rem;
  padding: 0 0.8rem 0 2.4rem;
  min-width: 32rem;
  flex-shrink: 0;
  white-space: nowrap;
  line-height: 1;
  font-size: 1.5rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  overflow: visible;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 10px 0 #DEE4EA;
}

.page-tower-estimate-request .form-content .inquiry-btn {
  width: 42rem;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.form-content .submit-btn:hover,
.form-content .inquiry-btn:hover {
  background: #fff;
  border-color: #d5d5d5;
  color: #222c34;
  opacity: 0.92;
}

.form-content .submit-btn::after,
.form-content .inquiry-btn::after {
  content: '';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  min-width: 4rem;
  min-height: 4rem;
  border-radius: 50%;
  border: none;
  box-shadow: none;
  background: #eb3b3b;
  color: #fff !important;
  font-size: 2.2rem;
  font-weight: 400;
  flex-shrink: 0;
  margin-left: auto;
  position: static;
  transform: none;
  background-image: url(../../img/tower/icon-feather-arrow-right.svg);
  background-size: 1rem;
  background-position: center;
  background-repeat: no-repeat;
}

/* その他セクション */
.other-section {
  text-align: center;
  padding: 4rem 0;
  background: transparent;
  margin-bottom: 4rem;
}

.other-section h2 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  color: #4a545d;
}

/* ファイナルセクション */
.final-section {
  text-align: center;
  padding: 4rem 0 6rem;
  background: transparent;
  border-radius: 0;
  margin-bottom: 6rem;
}

.final-section h2 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  color: #4a545d;
  line-height: 1.8;
}

/* レスポンシブ */
@media all and (max-width: 768px) {
  .estimate-hero {
    padding: 6rem 2.4rem;
  }

  .estimate-hero h1 {
    font-size: 3rem;
  }

  .form-content {
    padding: 0 2.4rem;
    margin: 4rem auto 6rem;
  }

  .tower-estimate-layout {
    flex-direction: column;
    margin: 4rem auto 0;
    padding: 0 2.4rem;
  }

  .tower-estimate-layout .product-detail-main__sidebar {
    width: 100%;
    margin-top: 0;
    margin-bottom: 4rem;
    padding: 0;
    border-radius: 2rem;
    background: transparent;
  }

  .tower-estimate-layout .product-detail-main__sidebar::before {
    display: none;
  }

  .page-tower-estimate .tower-estimate-layout .product-detail-main__sidebar .sidebar-box {
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    position: static;
  }

  .page-tower-estimate .tower-estimate-layout .sidebar-box__title {
    margin-bottom: 0;
  }

  .page-tower-estimate .tower-estimate-layout .product-detail-main__sidebar .tower-search-sidebar.sidebar-box h3.sidebar-title.sidebar-box__title {
    margin-bottom: 1.6rem;
    padding-bottom: 0;
    border-bottom: none;
  }

  .page-tower-estimate .tower-estimate-layout .sidebar-toggle {
    background: #8b959e;
    color: #fff;
    width: 100%;
    margin-left: 0;
    padding: 0 1.6rem;
    min-height: 43px;
    font-size: 1.6rem;
    justify-content: center;
    gap: 0.8rem;
    cursor: pointer;
    position: relative;
    border-radius: 0;
    pointer-events: auto;
  }

  .page-tower-estimate .tower-estimate-layout .sidebar-toggle-icon {
    display: block;
  }

  .page-tower-estimate .tower-estimate-layout .sidebar-toggle-icon::before {
    content: '';
    display: block;
    width: 0.75rem;
    height: 0.75rem;
    border-top: 0.2rem solid #fff;
    border-right: 0.2rem solid #fff;
    transform: rotate(-45deg);
    transition: transform 0.3s;
    margin-top: -0.2rem;
  }

  .page-tower-estimate .tower-estimate-layout .sidebar-toggle[aria-expanded='true'] .sidebar-toggle-icon::before {
    transform: rotate(135deg);
    margin-top: 0.9rem;
  }

  .page-tower-estimate .tower-estimate-layout .form-content {
    padding: 0;
    margin: 0;
  }

  .page-tower-estimate .tower-estimate-layout [data-sidebar-panel] {
    background: #fff;
    padding: 2.4rem;
    border-radius: 0 0 1.2rem 1.2rem;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  }

  .page-tower-estimate .product-detail-main__sidebar .quote-form__submit {
    width: 26.6rem;
    padding: 1.8rem 4.6rem;
    margin: 1rem auto 2.2rem;
  }

  .tower-estimate-background {
    display: none;
  }

  .product-title-box {
    padding: 2rem;
  }

  .spec-table {
    grid-template-columns: repeat(2, 1fr);
    gap: 0 2rem;
  }

  .spec-cell:nth-child(2n),
  .spec-cell:nth-child(4n) {
    border-right: none;
  }

  .form-grid-half {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .estimate-test-block {
    padding: 2rem;
  }

  .estimate-test-grid-half {
    grid-template-columns: 1fr;
  }

  .tel-fax-group {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .button-group {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .form-content .submit-btn,
  .form-content .inquiry-btn {
    width: 100%;
    min-width: auto;
    height: 5.2rem;
    padding: 0 0.6rem 0 1.8rem;
    font-size: 1.4rem;
  }

  .form-content .submit-btn::after,
  .form-content .inquiry-btn::after {
    width: 4rem;
    height: 4rem;
    min-width: 4rem;
    min-height: 4rem;
    font-size: 2rem;
  }
}


/* サイドバー内のプルダウン表示調整 */
/* 注：ボックス自体の大きさ（width）は変更せず、余白と文字サイズで調整 */
.tower-search-sidebar .quote-form__label,
.product-detail-main__sidebar .quote-form__label {
  width: 40% !important;
}

.tower-search-sidebar .quote-form__select-wrap,
.product-detail-main__sidebar .quote-form__select-wrap {
  width: 53% !important;
}

/* アイコン（矢印）の配置と余白の調整 */
.tower-search-sidebar .quote-form__select-wrap::after,
.product-detail-main__sidebar .quote-form__select-wrap::after {
  right: 0.5rem !important;
}

.tower-search-sidebar .quote-form__select,
.product-detail-main__sidebar .quote-form__select {
  font-size: 1.05rem;
  /* 53%幅の中で「二重効用吸収式冷凍」を表示するためのサイズ */
  padding: 0 1.5rem 0 0.5rem;
  /* アイコン左右の間隔を0.5remで均等化 */
}

/* =========================================
   PowerCMS ContactForm の左寄せ・固定幅打ち消し
   tower estimate / estimate request 用
========================================= */

.page-tower-estimate .form-content #contactform,
.page-tower-estimate .form-content #contactform form,
.page-tower-estimate .form-content .contact-form,
.page-tower-estimate-request .form-content #contactform,
.page-tower-estimate-request .form-content #contactform form,
.page-tower-estimate-request .form-content .contact-form {
  width: 100% !important;
  max-width: none !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box;
}

/* PowerCMS標準の div.contact-form { width:520px } を打ち消す */
.page-tower-estimate .form-content div.contact-form,
.page-tower-estimate-request .form-content div.contact-form {
  width: 100% !important;
  max-width: none !important;
  border-top: none !important;
}

/* PowerCMS標準の各項目固定幅を打ち消す */
.page-tower-estimate .form-content div.contact-form div.contact-form-field,
.page-tower-estimate .form-content div.contact-form div.contact-form-submit,
.page-tower-estimate-request .form-content div.contact-form div.contact-form-field,
.page-tower-estimate-request .form-content div.contact-form div.contact-form-submit {
  width: 100% !important;
  max-width: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  border-left: none !important;
  border-right: none !important;
  box-sizing: border-box;
}

/* PowerCMS側の情報文が不要・邪魔な場合 */
.page-tower-estimate .form-content .contact-form-information,
.page-tower-estimate-request .form-content .contact-form-information {
  display: none;
}

.page-tower-estimate-request .form-content .field_error,
.page-tower-estimate-request .tower-estimate-request-form .field_error {
  color: #eb3b3b !important;
}

/* =========================================
   PowerCMS 郵便番号 2分割表示
   cooling-tower-estimate / estimate-request 共通
========================================= */

.page-tower-estimate .form-content .zip-merged-group,
.page-tower-estimate-request .form-content .zip-merged-group {
  width: 100%;
  margin-bottom: 3rem;
  box-sizing: border-box;
}

.page-tower-estimate .form-content .zip-phone-group,
.page-tower-estimate-request .form-content .zip-phone-group {
  display: flex !important;
  align-items: center !important;
  gap: 1rem !important;
  width: auto !important;
  max-width: none !important;
}

/* 入力画面：前3桁・後4桁を同じ幅にする */
.page-tower-estimate .form-content .zip-phone-group input,
.page-tower-estimate-request .form-content .zip-phone-group input {
  flex: 0 0 9rem !important;
  width: 9rem !important;
  min-width: 9rem !important;
  max-width: 9rem !important;
  height: 5.6rem !important;
  padding: 1.6rem !important;
  box-sizing: border-box !important;
}

/* ハイフン */
.page-tower-estimate .form-content .zip-phone-group .zip-separator,
.page-tower-estimate-request .form-content .zip-phone-group .zip-separator,
.page-tower-estimate .form-content .zip-phone-group > span,
.page-tower-estimate-request .form-content .zip-phone-group > span {
  flex: 0 0 auto !important;
}

/* 確認画面：前3桁・後4桁を同じ幅にする */
.page-tower-estimate .form-content .field_value--zip,
.page-tower-estimate-request .form-content .field_value--zip {
  display: flex;
  align-items: center;
  flex: 0 0 9rem !important;
  width: 9rem !important;
  min-width: 9rem !important;
  max-width: 9rem !important;
  min-height: 5.6rem;
  padding: 1.6rem;
  box-sizing: border-box !important;
}

/* 空欄でも箱を維持 */
.page-tower-estimate .form-content .field_value--zip:empty::before,
.page-tower-estimate-request .form-content .field_value--zip:empty::before {
  content: "　";
}

@media all and (max-width: 768px) {
  .page-tower-estimate .form-content .zip-merged-group,
  .page-tower-estimate-request .form-content .zip-merged-group {
    margin-bottom: 2rem;
  }

  .page-tower-estimate .form-content .zip-phone-group input,
  .page-tower-estimate-request .form-content .zip-phone-group input,
  .page-tower-estimate .form-content .field_value--zip,
  .page-tower-estimate-request .form-content .field_value--zip {
    flex-basis: 9rem !important;
    width: 9rem !important;
    min-width: 9rem !important;
    max-width: 9rem !important;
    height: 5.2rem !important;
    min-height: 5.2rem !important;
  }
}


/* =========================================
   PowerCMS ContactForm 確認画面用
   tower / tank風に整える
========================================= */

/* 確認画面のPowerCMSフォーム全体 */
.page-tower-estimate .tower-download-customer-form,
.page-tower-estimate .tower-download-customer-form #contactform,
.page-tower-estimate .tower-download-customer-form #contactform form,
.page-tower-estimate .tower-download-customer-form .contact-form {
  width: 100% !important;
  max-width: none !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  border-top: none !important;
  box-sizing: border-box;
}

/* PowerCMS標準の固定幅・枠線を打ち消す */
.page-tower-estimate .tower-download-customer-form div.contact-form div.contact-form-field,
.page-tower-estimate .tower-download-customer-form div.contact-form div.contact-form-submit {
  width: 100% !important;
  max-width: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  border-left: none !important;
  border-right: none !important;
  box-sizing: border-box;
}

/* 空の案内文は非表示 */
.page-tower-estimate .tower-download-customer-form .contact-form-information:empty {
  display: none;
}

/* 確認画面の各項目余白 */
.page-tower-estimate .tower-download-customer-form .form-group {
  margin-bottom: 2.6rem;
}

/* 確認画面の値表示：tankと同じ枠付き表示 */
.page-tower-estimate .tower-download-customer-form .field_value,
.page-tower-estimate .tower-download-customer-form .tower-request-delivery-location {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 5.6rem;
  padding: 1.6rem;
  border: 1px solid #d5d5d5;
  border-radius: 0.6rem;
  background: #fff;
  box-sizing: border-box;
  font-size: 1.6rem;
  line-height: 1.5;
  color: #222c34;
}

/* pで出ている物件名称・所在地（都道府県）の余白をリセット */
.page-tower-estimate .tower-download-customer-form .tower-request-delivery-location {
  margin: 0;
}

/* 空欄でも高さを維持 */
.page-tower-estimate .tower-download-customer-form .field_value:empty::before {
  content: "　";
}

/* 郵便番号は1行表示 */
.page-tower-estimate .tower-download-customer-form .zip-phone-group {
  display: flex !important;
  align-items: center !important;
  gap: 1rem !important;
  width: auto !important;
  max-width: none !important;
}

/* 郵便番号の確認表示：前3桁・後4桁を同じ幅 */
.page-tower-estimate .tower-download-customer-form .field_value--zip {
  flex: 0 0 9rem !important;
  width: 9rem !important;
  min-width: 9rem !important;
  max-width: 9rem !important;
}

/* 郵便番号のハイフン */
.page-tower-estimate .tower-download-customer-form .zip-separator {
  flex: 0 0 auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #4a545d !important;
  font-size: 1.6rem !important;
  line-height: 1 !important;
}

/* 何で知りましたか？の幅調整 */
.page-tower-estimate .tower-download-customer-form .form-grid-half,
.page-tower-estimate .tower-download-customer-form .source-grid-half,
.page-tower-estimate .tower-download-customer-form .source-grid-cell {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* =========================================
   PowerCMS確認画面 投稿ボタン
   ※ tower-download-customer-form 内の __mode で判定
========================================= */

/* 入力画面のPowerCMS標準submitは必ず非表示 */
.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="confirm"])
  .tower-download-customer-form .contact-form-submit {
  display: none !important;
}

/* 確認画面だけボタン外枠を表示・整形 */
.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
  .tower-download-customer-form .contact-form-submit {
  position: relative;
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 5.5rem 0 5.5rem !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  text-align: center !important;
  box-sizing: border-box;
}

/* 確認画面だけinput本体を既存ボタン風にする */
.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
  .tower-download-customer-form .contact-form-submit input[type="submit"] {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;

  width: 42rem !important;
  max-width: 100% !important;
  min-height: 5.8rem !important;

  margin: 0 auto !important;
  padding: 0 6.2rem 0 2.4rem !important;

  border: none !important;
  border-radius: 10rem !important;
  background: #fff !important;
  box-shadow: 0 0 10px 0 #DEE4EA !important;

  color: #222c34 !important;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  text-align: left !important;
  white-space: normal !important;

  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
}

/* 確認画面だけ赤丸矢印 */
.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
  .tower-download-customer-form .contact-form-submit::after {
  content: "";
  position: absolute;
  top: 50%;
  left: calc(50% + 21rem - 4.8rem);
  transform: translateY(-50%);

  width: 4rem;
  height: 4rem;
  border-radius: 50%;

  background-color: #eb3b3b;
  background-image: url(../../img/tower/icon-feather-arrow-right.svg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 1rem;

  pointer-events: none;
}

.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
  .tower-download-customer-form .contact-form-submit:hover input[type="submit"] {
  opacity: 0.92;
}

/* =========================================
   PowerCMS確認画面 SP版のみ
   フォーム中央寄せ + 赤丸飛び出し防止
   ※PC版には効かせない
========================================= */

@media all and (max-width: 768px) {
  /* SP確認画面の外側だけ中央寄せ */
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-estimate-layout {
    width: 100%;
    padding-left: 2.4rem;
    padding-right: 2.4rem;
    box-sizing: border-box;
  }

  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-estimate-layout .product-detail-main__content {
    width: 100%;
    max-width: 43rem;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box;
  }

  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-estimate-layout .form-content {
    width: 100%;
    max-width: 43rem;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box;
  }

  /* 製品情報とフォームも同じ幅にそろえる */
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    [data-component*="TowerEstimateProductInfo.html"],
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-download-customer-form {
    width: 100%;
    max-width: 43rem;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box;
  }

  /* 投稿ボタンの外枠も中央寄せ。ここが赤丸の基準になる */
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-download-customer-form .contact-form-submit {
    position: relative;
    width: 100% !important;
    max-width: 43rem !important;
    margin: 3.5rem auto 3rem !important;
    padding: 0 !important;
    box-sizing: border-box;
    text-align: center !important;
  }

  /* ボタン本体は親幅いっぱい */
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-download-customer-form .contact-form-submit input[type="submit"] {
    display: block !important;
    width: 100% !important;
    max-width: 43rem !important;
    min-height: 5.2rem !important;
    margin: 0 auto !important;
    padding: 0 5.8rem 0 1.8rem !important;
    box-sizing: border-box !important;
    font-size: 1.3rem !important;
  }

  /* 赤丸は計算式を使わず、ボタン内の右端に固定 */
  .page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
    .tower-download-customer-form .contact-form-submit::after {
    left: auto !important;
    right: 0.6rem !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 4rem !important;
    height: 4rem !important;
  }
}

/* =========================================
   cooling-tower-estimate-request.html
   PowerCMS確認画面：値表示ボックス追加
========================================= */

.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .form-group {
  margin-bottom: 2.6rem;
}

/* 確認画面の値表示をボックス化 */
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .field_value,
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .input-box > span.contact-form-text-full {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 5.6rem;
  padding: 1.6rem;
  border: 1px solid #d5d5d5;
  border-radius: 0.6rem;
  background: #fff;
  box-sizing: border-box;

  color: #222c34;
  font-size: 1.6rem;
  line-height: 1.5;
}

/* 空欄でも高さを維持 */
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .field_value:empty::before,
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .input-box > span.contact-form-text-full:empty::before {
  content: "　";
}

/* textarea系の確認表示が複数行になる場合 */
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .field_value br {
  display: block;
}

/* 請求書類など、チェックボックス確認表示用 */
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .checkbox-group {
  width: 100%;
  min-height: 5.6rem;
  padding: 1.6rem;
  border: 1px solid #d5d5d5;
  border-radius: 0.6rem;
  background: #fff;
  box-sizing: border-box;

  color: #222c34;
  font-size: 1.6rem;
  line-height: 1.5;
}

/* 郵便番号だけは横並びを維持 */
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .form-group[data-zip-merged="1"] .input-box,
.page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
  .tower-estimate-request-form .form-group[data-zip-merged="1"] .phone-group {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* SP調整 */
@media all and (max-width: 768px) {
  .page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
    .tower-estimate-request-form .field_value,
  .page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
    .tower-estimate-request-form .input-box > span.contact-form-text-full,
  .page-tower-estimate-request:has(.tower-estimate-request-form input[name="__mode"][value="submit"])
    .tower-estimate-request-form .checkbox-group {
    min-height: 5.2rem;
    padding: 1.6rem;
    font-size: 1.6rem;
  }
}


/* =========================================
   PowerCMS確認画面では下部の再ダウンロード用ボタングループを非表示
   ※ contact-form-submit の投稿ボタンは残す
========================================= */

.page-tower-estimate:has(.tower-download-customer-form input[name="__mode"][value="submit"])
  [data-component="tower/_components/TowerDownloadButtons.html"] {
  display: none !important;
}


/* =========================================
   cooling-tower-estimate-request.html
   見積依頼フォーム submitボタン共通
========================================= */

.page-tower-estimate-request .tower-estimate-request-form .contact-form-submit {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 5.5rem 0 5.5rem !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  text-align: center !important;
  box-sizing: border-box !important;
}

.page-tower-estimate-request .tower-estimate-request-form .contact-form-submit input[type="submit"] {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;

  width: 42rem !important;
  max-width: 100% !important;
  min-height: 5.8rem !important;

  margin: 0 auto !important;
  padding: 0 6.2rem 0 2.4rem !important;

  border: none !important;
  border-radius: 10rem !important;
  background: #fff !important;
  box-shadow: 0 0 10px 0 #dee4ea !important;

  color: #222c34 !important;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  text-align: left !important;
  white-space: normal !important;

  cursor: pointer !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  box-sizing: border-box !important;
}

.page-tower-estimate-request .tower-estimate-request-form .contact-form-submit::after {
  content: "" !important;
  position: absolute !important;
  top: 50% !important;
  left: calc(50% + 21rem - 4.8rem) !important;
  transform: translateY(-50%) !important;

  width: 4rem !important;
  height: 4rem !important;
  border-radius: 50% !important;

  background-color: #eb3b3b !important;
  background-image: url(../../img/tower/icon-feather-arrow-right.svg) !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: 1rem !important;

  pointer-events: none !important;
}


