@charset "UTF-8";

/* =========================================================
   車種案内（page-vehicles.php）- レンタル料金セクションの見た目
   Figma「pricing-season」(node 277:30) の実装。

   HTMLと文言は既存のまま。見た目だけをこのファイルで差し替える。
   そのため既存クラス（.custom-table-title / .custom-table-price / .tag-*）を
   そのまま使い、新しいマークアップは足していない。

   読み込みは page-vehicles.php のインラインstyle（20〜686行）より後ろ。
   同順位のセレクタで競合したときにこちらを勝たせるため。

   Figmaのアクセントは #e53935 だが、サイト既存のブランドレッド #e63312 に
   寄せている（/faq・/usa-faq・ENトップと同じ値）。
   フレーム背景の #f9fafb はFigmaのアートボード色なので取り込んでいない。
   ========================================================= */

.tab-content {
  /* シーズンごとの帯の色（凡例の文字色と対になる） */
  --vp-off: #e3ecde;
  --vp-regular: #e2ebf9;
  --vp-high: #fff0ca;
  --vp-top: #fdd9d9;

  --vp-accent: #e63312;
  --vp-line: #a2a2a2;
  --vp-thead-bg: #f9f9f9;
  --vp-card-border: #e0e0e0;
  --vp-text: #212121;
  --vp-text-cell: #333;

  /* Figmaの content-container 幅。ページ側の .p-entop__inner は1600pxなので、
     料金セクションだけこの幅に絞って中央に置く */
  --vp-container: 1200px;
}

/* 料金・凡例・注意事項のブロックだけ 1200px に絞る。
   詳細セクション（.p-entop）は直下の子ではないので影響しない */
.tab-content > .wpb_wrapper,
.tab-content > .wpb_raw_code,
.tab-content > .wpb_text_column {
  max-width: var(--vp-container);
  margin-left: auto;
  margin-right: auto;
}

/* ---------------------------------------------------------
   セクション見出し（赤い縦バー＋タイトル＋下の細い罫）
   「レンタル料金（税込）」の h3 だけを狙うため、直後に車種ラベルが
   続くことを条件にする（ページ内の他の h3 に当たらないように）
   --------------------------------------------------------- */
.tab-content h3:has(+ .custom-table-title) {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 48px;
  padding: 0 0 16px;
  border-bottom: 2px solid rgba(230, 51, 18, 0.3);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 0;
  color: var(--vp-text);
}

.tab-content h3:has(+ .custom-table-title)::before {
  content: "";
  flex-shrink: 0;
  width: 6px;
  height: 28px;
  border-radius: 3px;
  background: var(--vp-accent);
}

/* ---------------------------------------------------------
   車種ラベル（白カード：緑バッジ＋車種名）
   --------------------------------------------------------- */
.tab-content .custom-table-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 48px;
  padding: 16px;
  border: 1px solid var(--vp-card-border);
  border-radius: 8px;
  background: #fff;
}

.tab-content .custom-table-title-left {
  flex-shrink: 0;
  margin: 0;
  padding: 4px 10px;
  border-radius: 4px;
  background: #e8f5e9;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  color: #2e7d32;
  white-space: nowrap;
}

.tab-content .custom-table-title-right {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  /* 既存の letter-spacing: -2px を打ち消す */
  letter-spacing: 0;
  color: var(--vp-text);
}

/* ---------------------------------------------------------
   料金表
   table-layout: fixed にすると、幅指定のない列は等分される。
   先頭行が colspan="2" + 2セル ＝ 4列なので、4等分になる
   --------------------------------------------------------- */
.tab-content .custom-table-price {
  width: 100%;
  margin: 0 0 48px;
  table-layout: fixed;
  border-collapse: collapse;
}

.tab-content .custom-table-price th,
.tab-content .custom-table-price td {
  height: 50px;
  padding: 8px 10px;
  border: 1px solid var(--vp-line);
  text-align: center;
  vertical-align: middle;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--vp-text-cell);
}

/* 金額 */
.tab-content .custom-table-price td {
  font-size: 18px;
  font-weight: 700;
  color: var(--vp-text);
}

/* シーズン名（rowspan の左端セル、および colspan で伸びるハイ／トップ）。
   同じ colspan="2" でも見出し行の「シーズン」は本文サイズのままにする */
.tab-content .custom-table-price th[rowspan],
.tab-content .custom-table-price th[colspan]:not(.custom-table-price-header) {
  font-size: 20px;
}

/* ---- 見出し行 ---- */
.tab-content .custom-table-price-header,
.tab-content .custom-table-price td.custom-table-price-header {
  background: var(--vp-thead-bg);
  font-size: 16px;
  font-weight: 400;
  color: var(--vp-text-cell);
}

/* ---- シーズンごとの帯 ---- */
/* 見出しセルは既存クラスで塗れる */
.tab-content .custom-table-price-off {
  background: var(--vp-off);
}

.tab-content .custom-table-price-regular {
  background: var(--vp-regular);
}

.tab-content .custom-table-price-high {
  background: var(--vp-high);
}

.tab-content .custom-table-price-top {
  background: var(--vp-top);
}

/* 金額セル側にはシーズンのクラスが付いていないので、
   同じ行にシーズンの見出しセルがあるかで判定して塗る。
   行の並び順に依存しないので、行を足し引きしても崩れない */
.tab-content .custom-table-price tr:has(.custom-table-price-off) td {
  background: var(--vp-off);
}

.tab-content .custom-table-price tr:has(.custom-table-price-regular) td {
  background: var(--vp-regular);
}

.tab-content .custom-table-price tr:has(.custom-table-price-high) td {
  background: var(--vp-high);
}

.tab-content .custom-table-price tr:has(.custom-table-price-top) td {
  background: var(--vp-top);
}

/* ---------------------------------------------------------
   シーズン区分の凡例
   旧デザインの色見本（border-left 40px）をやめ、
   シーズン名自体を表の帯と対になる色にする
   --------------------------------------------------------- */
.tab-content .p-vprice-legend__item {
  margin: 0 0 32px;
}

.tab-content .p-vprice-legend__label {
  margin: 0 0 8px;
  padding-left: 0;
  border-left: none;
  font-size: 20px;
  line-height: 1.4;
}

.tab-content .p-vprice-legend__label strong {
  font-weight: 600;
}

.tab-content .p-vprice-legend__label.tag-off {
  color: #2f7d5b;
}

.tab-content .p-vprice-legend__label.tag-regular {
  color: #2878b5;
}

.tab-content .p-vprice-legend__label.tag-high {
  color: #c58a00;
}

.tab-content .p-vprice-legend__label.tag-top {
  color: #d65a74;
}

.tab-content .p-vprice-legend__dates {
  margin: 0;
  font-size: 16px;
  line-height: 1.8;
  color: #000;
}

/* ---------------------------------------------------------
   注意事項（白カード）
   凡例の下に続く唯一の p 要素なので、位置で拾う
   --------------------------------------------------------- */
.tab-content > .wpb_wrapper > p,
.tab-content > .wpb_text_column > .wpb_wrapper > p {
  margin: 16px 0 0;
  padding: 24px;
  border: 1px solid var(--vp-card-border);
  border-radius: 8px;
  background: #fff;
  font-size: 13px;
  line-height: 1.6;
  color: #757575;
}

/* カードの見出し。既存のHTMLに無い文言なのでCSS側で出している
   （実テキストにしたい場合はマークアップに1行足す） */
.tab-content > .wpb_wrapper > p::before,
.tab-content > .wpb_text_column > .wpb_wrapper > p::before {
  content: "料金に関する注意事項";
  display: block;
  margin-bottom: 12px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--vp-text);
}

/* ---------------------------------------------------------
   タブレット以下
   --------------------------------------------------------- */
@media (max-width: 1024px) {
  .tab-content .custom-table-price th[rowspan],
  .tab-content .custom-table-price th[colspan]:not(.custom-table-price-header) {
    font-size: 17px;
  }

  .tab-content .custom-table-price td {
    font-size: 16px;
  }
}

@media (max-width: 768px) {
  .tab-content h3:has(+ .custom-table-title) {
    margin-bottom: 28px;
    padding-bottom: 12px;
    font-size: 20px;
  }

  .tab-content h3:has(+ .custom-table-title)::before {
    height: 22px;
  }

  .tab-content .custom-table-title {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 28px;
    padding: 12px;
  }

  .tab-content .custom-table-title-right {
    font-size: 15px;
  }

  .tab-content .custom-table-price {
    margin-bottom: 28px;
  }

  .tab-content .custom-table-price th,
  .tab-content .custom-table-price td {
    height: 44px;
    padding: 6px 4px;
    font-size: 13px;
  }

  .tab-content .custom-table-price td {
    font-size: 14px;
  }

  .tab-content .custom-table-price th[rowspan],
  .tab-content .custom-table-price th[colspan]:not(.custom-table-price-header) {
    font-size: 13px;
  }

  .tab-content .p-vprice-legend__item {
    margin-bottom: 24px;
  }

  .tab-content .p-vprice-legend__label {
    font-size: 17px;
  }

  .tab-content .p-vprice-legend__dates {
    font-size: 14px;
  }

  .tab-content > .wpb_wrapper > p,
  .tab-content > .wpb_text_column > .wpb_wrapper > p {
    padding: 16px;
  }
}
