/* ============================================================
   guide-common.css
   /car/ /area/ /column/ のガイド系ページ共通スタイル。
   旧 /car/index.css と /css/faq-accordion.css を統合したもの。
   ページ固有の上書きは各ページCSS（このファイルの後に読み込む）で行う。
   ============================================================ */

:root {
  --guide-ink: #2d3436;
  --guide-muted: #637071;
  --guide-gold: #d9a900;
  --guide-gold-dark: #9a7600;
  --guide-gold-pale: #fffde7;
  --guide-green-pale: #f0fff4;
  --guide-border: #ebebeb;
  --guide-soft: #fafafa;
  --guide-red: #d93b55;

  /* ボタン配色の単一ソース。申込フォーム（/form/reserve/）へのCTAだけオレンジ、
     それ以外のボタン・チップは白（枠線付き）で統一する。 */
  --guide-orange: #ff6b35;
  --btn-order-bg: var(--guide-orange);
  --btn-order-text: #ffffff;
  --btn-order-shadow: 0 6px 18px rgba(255, 107, 53, 0.24);
  --btn-plain-bg: #ffffff;
  --btn-plain-text: var(--guide-ink);
  --btn-plain-border: #d8dcdd;
  --btn-plain-hover-bg: var(--guide-soft);
}

html {
  scroll-behavior: smooth;
}

.car-guide-page {
  padding-bottom: 36px;
}

.guide-breadcrumb {
  padding: 14px 32px;
  border-bottom: 1px solid var(--guide-border);
  color: var(--guide-muted);
  font-size: 0.78rem;
}

.guide-breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.guide-breadcrumb li:not(:last-child)::after {
  content: "/";
  margin-left: 8px;
  color: #b5bec0;
}

.guide-breadcrumb a {
  color: #587982;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.car-guide {
  box-sizing: border-box;
  width: calc(100% - 64px);
  margin: 32px auto 0;
  font-size: 1rem;
  line-height: 1.9;
}

.car-guide *,
.car-guide *::before,
.car-guide *::after {
  box-sizing: border-box;
}

/* ページ側で .car-guide を display:grid にした場合に、
   グリッドアイテム（min-width:auto）が表などの min-width に
   引きずられて広がるのを防ぐ */
.car-guide > * {
  min-width: 0;
}

.car-guide p {
  margin: 0 0 1.25em;
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.guide-source-badge {
  display: inline-block;
  margin-top: 10px !important;
  padding: 5px 12px;
  background: #f4f1e8;
  border-radius: 999px;
  color: #625b48;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.5;
}

.guide-note,
.guide-official-source {
  color: var(--guide-muted);
  font-size: 0.82rem;
}

.luna-bubble {
  display: grid;
  grid-template-columns: 124px 1fr;
  align-items: center;
  gap: 24px;
  margin: 34px 0;
}

.luna-bubble__image {
  display: block;
  width: 124px;
  height: 124px;
  object-fit: cover;
  border: 4px solid #fff;
  border-radius: 50%;
  box-shadow: 0 6px 20px rgba(217, 59, 85, 0.18);
}

.luna-bubble__content {
  position: relative;
  min-width: 0;
  padding: 22px 26px;
  background: #fff4f6;
  border: 1px solid #f5c7cf;
  border-radius: 18px;
  overflow-wrap: anywhere;
}

.luna-bubble__content::before {
  content: "";
  position: absolute;
  top: 50%;
  left: -13px;
  width: 24px;
  height: 24px;
  background: #fff4f6;
  border-bottom: 1px solid #f5c7cf;
  border-left: 1px solid #f5c7cf;
  transform: translateY(-50%) rotate(45deg);
}

.luna-bubble__content p {
  margin: 0;
}

.luna-bubble__label {
  color: var(--guide-red);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.guide-toc {
  margin: 34px 0 0;
  padding: 26px clamp(20px, 4vw, 36px);
  background: var(--guide-soft);
  border: 1px solid var(--guide-border);
  border-radius: 14px;
}

.guide-toc__title {
  margin-bottom: 10px !important;
  font-size: 1.2rem;
  font-weight: 800;
}

.guide-toc ol {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 28px;
  margin: 0;
  padding-left: 1.5em;
}

.guide-toc a {
  color: #285f7d;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.guide-section {
  padding: clamp(48px, 8vw, 40px) 0;
  border-bottom: 1px solid var(--guide-border);
  scroll-margin-top: 20px;
}

.guide-section-label {
  margin-bottom: 6px !important;
  color: var(--guide-gold-dark);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.guide-section > h2,
.guide-cta > h2 {
  position: relative;
  margin: 0 0 28px;
  padding-bottom: 14px;
  color: var(--guide-ink);
  font-size: clamp(1.4rem, 3.5vw, 1.9rem);
  line-height: 1.45;
}

.guide-section > h2::after,
.guide-cta > h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 70px;
  height: 4px;
  background: var(--guide-gold);
  border-radius: 999px;
}

.guide-table-scroll {
  margin: 28px 0 12px;
  /* max-width で親（グリッドアイテム等）が表の min-width に
     引きずられて広がるのを防ぎ、表はこの中で横スクロールさせる */
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--guide-border);
  border-radius: 12px;
  overscroll-behavior-inline: contain;
}

.guide-table-scroll:focus-visible {
  outline: 3px solid rgba(217, 169, 0, 0.35);
  outline-offset: 3px;
}

.guide-table {
  width: 100%;
  min-width: 680px;
  margin: 0;
  border-collapse: collapse;
  background: #fff;
}

.guide-table th,
.guide-table td {
  padding: 16px 18px;
  border: 1px solid var(--guide-border);
  vertical-align: middle;
}

.guide-table thead th {
  background: var(--guide-ink);
  color: #fff;
  font-weight: 700;
  text-align: center;
}

.guide-table tbody th {
  min-width: 170px;
  background: #f6f6f6;
  text-align: left;
}

.guide-table td {
  text-align: center;
}

.guide-callout {
  margin-top: 30px;
  padding: 22px 26px;
  background: #fff9e6;
  border-left: 5px solid var(--guide-gold);
  border-radius: 0 12px 12px 0;
}

.guide-callout h3 {
  margin: 0 0 8px;
  color: var(--guide-ink);
  font-size: 1.12rem;
}

.guide-callout p {
  margin: 0;
}

.guide-text-link,
.guide-button-wrap {
  margin-top: 24px !important;
}

.guide-text-link a,
.guide-official-source a {
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.guide-text-link a::after {
  content: " →";
}

.guide-button {
  display: inline-flex;
  min-height: 52px;
  padding: 12px 24px;
  align-items: center;
  justify-content: center;
  background: var(--btn-plain-bg);
  border: 1px solid var(--btn-plain-border);
  border-radius: 999px;
  color: var(--btn-plain-text);
  font-weight: 800;
  line-height: 1.5;
}

.guide-button:hover {
  color: var(--btn-plain-text);
  background: var(--btn-plain-hover-bg);
}

.guide-button::after {
  content: "→";
  margin-left: 10px;
}

.guide-cta {
  margin: clamp(50px, 8vw, 80px) 0 40px;
  padding: clamp(28px, 5vw, 46px);
  background: var(--guide-soft);
  border-radius: 18px;
}

.related-link-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.related-link-cards a {
  display: flex;
  min-height: 130px;
  padding: 22px 18px;
  flex-direction: column;
  justify-content: center;
  background: #fff;
  border: 1px solid var(--guide-border);
  border-radius: 12px;
  color: var(--guide-ink);
  box-shadow: 0 6px 18px rgba(45, 52, 54, 0.05);
}

.related-link-cards span {
  font-weight: 800;
}

.related-link-cards small {
  color: var(--guide-muted);
}

.guide-cta__primary {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid #dedede;
  text-align: center;
}

/* 申込フォームへのCTA専用。ページ内でオレンジになるのはこのボタンだけ。 */
.guide-button--primary,
.guide-button--primary:hover {
  border-color: transparent;
  background: var(--btn-order-bg);
  color: var(--btn-order-text);
  box-shadow: var(--btn-order-shadow);
}

@media (max-width: 767px) {
  .guide-breadcrumb {
    padding-right: 20px;
    padding-left: 20px;
  }

  .car-guide {
    width: calc(100% - 40px);
    margin-top: 24px;
    font-size: 0.94rem;
  }

  .guide-toc ol,
  .related-link-cards {
    grid-template-columns: 1fr;
  }

  .related-link-cards a {
    min-height: auto;
  }
}

@media (max-width: 560px) {
  .luna-bubble {
    grid-template-columns: 76px 1fr;
    gap: 14px;
  }

  .luna-bubble__image {
    width: 76px;
    height: 76px;
  }

  .luna-bubble__content {
    padding: 16px;
  }

  .guide-table-scroll::after {
    content: "横にスクロールできます";
    display: block;
    padding: 6px 12px;
    background: #f6f6f6;
    color: var(--guide-muted);
    font-size: 0.75rem;
    text-align: right;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* ============================================================
   ページヘッダー（/column/ 系のデザインを共通化）
   ============================================================ */

.guide-page-header {
  padding: clamp(30px, 5vw, 52px) 32px;
  background: linear-gradient(135deg, #fff9e6 0%, #fff 56%, #f0fff4 100%);
  border-bottom: 1px solid #f1dfad;
}

.guide-page-header__eyebrow {
  margin: 0 0 8px;
  color: var(--guide-gold-dark);
  font-family: "Poppins", sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.guide-page-header h1 {
  margin: 0;
  color: var(--guide-ink);
  font-size: clamp(1.65rem, 4vw, 2.35rem);
  font-weight: 900;
  line-height: 1.45;
}

.guide-page-header h1 span {
  display: block;
  color: #744d56;
}

.guide-page-header p:last-child {
  max-width: 780px;
  margin: 14px 0 0;
  color: #4f575b;
  line-height: 1.9;
}

@media (max-width: 768px) {
  .guide-page-header {
    padding: 26px 20px;
  }
}

@media (max-width: 560px) {
  .guide-page-header h1 span {
    margin-top: 4px;
  }
}

/* ============================================================
   FAQアコーディオン（inc/common/faq-accordion.php）
   サイトTOP（top-renewal.css）のトンマナに合わせたカード型。
   top-renewal.css の :root 変数（--paper / --line / --text /
   --coral / --yellow / --pink）を前提とする。
   ============================================================ */

.faq-accordion {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.faq-accordion__item {
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(45, 52, 54, .05);
  transition: border-color .2s ease, box-shadow .2s ease;
}

.faq-accordion__item:hover {
  box-shadow: 0 12px 26px rgba(45, 52, 54, .09);
}

.faq-accordion__item:has(.faq-accordion__button[aria-expanded="true"]) {
  border-color: rgba(255, 71, 87, .28);
  box-shadow: 0 12px 28px rgba(255, 71, 87, .08);
}

.faq-accordion__heading {
  margin: 0;
}

.faq-accordion__button {
  display: grid;
  grid-template-columns: 36px 1fr 26px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 18px;
  border: 0;
  background: none;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.6;
  text-align: left;
  cursor: pointer;
}

.faq-accordion__button:focus-visible {
  outline: 3px solid rgba(255, 71, 87, .35);
  outline-offset: -3px;
  border-radius: 16px;
}

/* Q / A の丸バッジ */
.faq-accordion__mark {
  display: inline-grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 999px;
  background: var(--coral);
  color: #fff;
  font-family: "Poppins", "Kosugi Maru", sans-serif;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1;
}

/* 開閉アイコン（＋ → −） */
.faq-accordion__icon {
  position: relative;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: rgba(255, 183, 197, .35);
  transition: background .2s ease;
}

.faq-accordion__button:hover .faq-accordion__icon {
  background: rgba(255, 183, 197, .6);
}

.faq-accordion__icon::before,
.faq-accordion__icon::after {
  content: "";
  position: absolute;
  top: 12px;
  left: 7px;
  width: 12px;
  height: 2px;
  border-radius: 2px;
  background: var(--coral);
  transition: transform .25s ease;
}

.faq-accordion__icon::after {
  transform: rotate(90deg);
}

.faq-accordion__button[aria-expanded="true"] .faq-accordion__icon::after {
  transform: rotate(0deg);
}

.faq-accordion__panel {
  padding: 0 18px 18px;
}

.faq-accordion__answer {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: rgba(255, 217, 61, .12);
  border-radius: 12px;
}

.faq-accordion__answer .faq-accordion__mark {
  flex-shrink: 0;
  background: var(--yellow);
  color: var(--text);
}

.faq-accordion__answer p {
  margin: 0;
  color: var(--text);
  line-height: 1.85;
}

.faq-accordion__link {
  margin-top: 10px !important;
}

.faq-accordion__link a {
  color: var(--coral);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.faq-accordion__link a::after {
  content: " →";
}

@media (max-width: 767px) {
  .faq-accordion {
    gap: 12px;
  }

  .faq-accordion__button {
    grid-template-columns: 32px 1fr 24px;
    gap: 10px;
    padding: 15px 14px;
    font-size: 0.92rem;
  }

  .faq-accordion__mark {
    width: 32px;
    height: 32px;
    font-size: 0.92rem;
  }

  .faq-accordion__panel {
    padding: 0 14px 15px;
  }

  .faq-accordion__answer {
    padding: 14px;
  }
}

/* ============================================================
   教習所カード共通パーツ（inc/tool/school-card.php）
   全ページ共通の基準スタイル。ページ固有CSSがある場合は
   後から読み込まれるそちらが優先される（従来どおり）。
   ============================================================ */
/* 横型カード：上段だけ写真＋見出し（県・市区町村・バッジ・教習所名・料金）を横並びにし、
   スペック表・紹介文・CTA は写真の下も使うカード全幅で表示する。
   （下段まで右カラムに閉じ込めると、写真の下に無駄な余白ができる）
   写真が無い校は .area-school-card--no-media が付いて上段も1カラムになる。 */
.area-school-card {
  /* カード自身の幅で写真の配置を切り替えるためのコンテナ（下の @container で使用）。
     2カラムグリッドに入るページ（/area/kyushu/ など）では横並びにできる幅がない。 */
  container-type: inline-size;
  background: #fff;
  border: 1px solid var(--guide-border);
  border-radius: 14px;
  box-shadow: 0 8px 22px rgba(45, 52, 54, .05);
  padding: 20px;
}

.area-school-card__top {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 18px;
}

.area-school-card--no-media .area-school-card__top {
  grid-template-columns: minmax(0, 1fr);
}

.area-school-card + .area-school-card {
  margin-top: 16px;
}

/* 写真は 4:3 の枠に固定する（上段の高さに引き伸ばさない）。 */
.area-school-card__media {
  align-self: start;
  margin: 0;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  background: var(--guide-soft);
}

.area-school-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* カードが狭いとき（2カラムグリッド内など）は写真を上に回す。
   @container 非対応ブラウザでは従来どおり横並びのまま。 */
@container (max-width: 500px) {
  .area-school-card__top {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .area-school-card__media {
    aspect-ratio: 16 / 9;
  }
}

.area-school-card__intro,
.area-school-card__body {
  min-width: 0;
}

/* 上段テキストの先頭は写真の上端とそろえる（県バッジが無い校でもずれないように） */
.area-school-card__intro > :first-child {
  margin-top: 0;
}

.area-school-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
}

.area-school-card__pref,
.area-school-card__area {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 5px 12px;
  border-radius: 999px;
  background: #f4f1e8;
  color: #625b48;
  font-size: 0.78rem;
  font-weight: 700;
}

/* バッジ（1カードに最大1つ。museum=ピンク系 / kokoro=ミント系） */
.area-school-card__badge,
.area-school-card__group-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  padding: 6px 12px;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.45;
  white-space: normal;
  word-break: break-word;
}

.area-school-card__group-badge {
  font-size: 0.75rem;
  padding: 5px 12px;
}

.area-school-card__badge--museum,
.area-school-card__group-badge--museum {
  background: #FFF5F8;
  color: #FF5A72;
  border: 1px solid #FFE0EA;
}

.area-school-card__badge--kokoro,
.area-school-card__group-badge--kokoro {
  background: #F2FFF9;
  color: #38A978;
  border: 1px solid #CDEFE1;
}

.area-school-card__name {
  margin: 10px 0 6px;
  color: var(--guide-ink);
  font-size: 1.15rem;
  line-height: 1.45;
}

.area-school-card__group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
}

.area-school-card__group-name {
  color: var(--guide-muted);
  font-size: 0.85rem;
  font-weight: 700;
}

/* 料金：一覧で最初に目に入る要素。金額だけを大きく、単位・注記は小さく添える。 */
.area-school-card__price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin: 10px 0 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--guide-gold-pale);
  border: 1px solid #f2e6a8;
}

.area-school-card__price-label {
  color: var(--guide-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.area-school-card__price-value {
  color: var(--guide-red);
  font-size: 1.3rem;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: .01em;
}

/* 料金の出典注記：教習所カードを並べたセクションの末尾に置く小さめの補足。
   金額そのものではないため、カード内の料金より弱いトーンにする。 */
.guide-price-source {
  margin: 14px 0 0;
  color: var(--guide-muted);
  font-size: 0.82rem;
  line-height: 1.8;
}

/* スペック表：最短日数・宿泊・車種・アクセス・交通費をまとめて表示する。
   1行1項目（1列）で縦に積む。所在地や取扱車種を折り返さずに読めるようにするため、
   横に2列並べない（ユーザー指示）。 */
.area-school-card__facts {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px 14px;
  margin: 12px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--guide-soft);
}

.area-school-card__facts > div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
}

.area-school-card__facts dt {
  margin: 0;
  color: var(--guide-muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.area-school-card__facts dd {
  margin: 0;
  color: var(--guide-ink);
  font-size: 0.88rem;
  line-height: 1.6;
}

.area-school-card__desc {
  margin: 12px 0 0;
  color: var(--guide-muted);
  font-size: 0.92rem;
  line-height: 1.8;
}

/* 特徴：既存データは短いタグではなく一文なので、チップにせず詰めた箇条書きで出す。 */
.area-school-card__features {
  display: grid;
  gap: 2px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.area-school-card__features li {
  position: relative;
  padding: 0 0 0 18px;
  color: var(--guide-ink);
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.6;
}

.area-school-card__features li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 8px;
  width: 8px;
  height: 4px;
  border-left: 2px solid var(--guide-gold-dark);
  border-bottom: 2px solid var(--guide-gold-dark);
  transform: rotate(-45deg);
}

.area-school-card__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

/* カード内のボタンは共通の固定幅(250px)を解除し、横に並べて高さを詰める。 */
.area-school-card__actions .guide-button {
  width: auto;
  min-width: 0;
  margin-top: 0;
  padding: 10px 18px;
  font-size: 0.88rem;
}

@media (max-width: 900px) {
  .area-school-card__top {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 16px;
  }
}

@media (max-width: 600px) {
  .area-school-card {
    padding: 16px;
  }

  .area-school-card__top {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .area-school-card__media {
    aspect-ratio: 16 / 9;
  }

  .area-school-card__price-value {
    font-size: 1.15rem;
  }

  .area-school-card__facts > div {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 8px;
  }

  .area-school-card__actions {
    flex-direction: column;
    align-items: stretch;
  }
}

/* ============================================================
   取扱車種一覧（LICENSE TYPES / #car-types）
   inc/common/cartype-section.php 用の共通スタイル
   ============================================================ */

.cartype-table {
  width: 100%;
  min-width: 680px;
  margin: 0;
  border-collapse: collapse;
  background: #fff;
  table-layout: auto;
}

.cartype-table th,
.cartype-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--guide-border);
  line-height: 1.65;
  vertical-align: middle;
  text-align: left;
}

.cartype-table thead th {
  background: var(--guide-soft);
  color: var(--guide-ink);
  font-size: 0.85rem;
  white-space: nowrap;
}

.cartype-table tbody tr:last-child th,
.cartype-table tbody tr:last-child td {
  border-bottom: 0;
}

/* 都道府県セル（rowspan） */
.cartype-table__pref {
  width: 6em;
  white-space: nowrap;
  text-align: center;
  font-weight: 700;
  background: var(--guide-soft);
}

/* 教習所名セル */
.cartype-table tbody th[scope="row"] {
  width: 14em;
  color: var(--guide-ink);
  font-weight: 700;
  line-height: 1.6;
}

.cartype-table tbody th[scope="row"] a {
  color: var(--guide-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 車種タグ */
.cartype-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.cartype-list li {
  margin: 0;
  padding: 0;
}

a.cartype-tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 3px 12px;
  border-radius: 999px;
  border: 1px solid var(--guide-border);
  background: #fff;
  color: var(--guide-ink);
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

a.cartype-tag:hover,
a.cartype-tag:focus-visible {
  background: var(--guide-gold-pale);
  border-color: var(--guide-gold);
}

/* 注記 */
.cartype-note {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}

.cartype-note li {
  position: relative;
  padding-left: 1.2em;
  color: var(--guide-muted);
  font-size: 0.85rem;
  line-height: 1.7;
}

.cartype-note li::before {
  content: "※";
  position: absolute;
  left: 0;
}

/* 車種別ピックアップ */
.cartype-pickup {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 28px;
}

.cartype-pickup__block {
  border: 1px solid var(--guide-border);
  border-radius: 12px;
  background: #fff;
  padding: 18px 16px;
}

.cartype-pickup__block h3 {
  margin: 0 0 8px;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.6;
}

.cartype-pickup__block > p {
  margin: 0 0 12px;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--guide-muted);
}

.cartype-pickup__list {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
}

.cartype-pickup__list li {
  padding: 10px 0;
  border-top: 1px dashed var(--guide-border);
}

.cartype-pickup__list li:last-child {
  border-bottom: 1px dashed var(--guide-border);
}

.cartype-pickup__list a {
  color: var(--guide-ink);
  font-weight: 700;
  line-height: 1.6;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cartype-pickup__name {
  font-weight: 700;
  line-height: 1.6;
}

.cartype-pickup__pref {
  display: inline-block;
  margin-left: 8px;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--guide-soft);
  color: var(--guide-muted);
  font-size: 0.75rem;
  line-height: 1;
  vertical-align: middle;
}

.cartype-pickup__list small {
  display: block;
  margin-top: 4px;
  color: var(--guide-muted);
  font-size: 0.85rem;
  line-height: 1.7;
}

.cartype-pickup__link {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin: 0;
}

.cartype-pickup__link a {
  position: relative;
  padding-right: 0.9em;
  color: var(--guide-ink);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.6;
  text-decoration: none;
}

.cartype-pickup__link a::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 5px;
  height: 5px;
  margin-top: -3px;
  border-top: 2px solid var(--guide-gold-dark);
  border-right: 2px solid var(--guide-gold-dark);
  transform: rotate(45deg);
}

/* PC */
@media only screen and (min-width: 897px) {
  .cartype-pickup {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 20px;
  }

  .cartype-pickup__block {
    padding: 22px 20px;
  }
}

/* SP: テーブルを縦積みカードに切り替え、横スクロールを出さない */
@media only screen and (max-width: 640px) {
  .cartype-table {
    min-width: 0;
  }

  .cartype-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .cartype-table,
  .cartype-table tbody,
  .cartype-table tr,
  .cartype-table th,
  .cartype-table td {
    display: block;
    width: auto;
  }

  .cartype-table tr {
    border-bottom: 1px solid var(--guide-border);
    padding: 12px 0;
  }

  .cartype-table tbody tr:last-child {
    border-bottom: 0;
  }

  /* rowspan の都道府県セルはSPでは各行に出さず、行内ラベルで代替
     （上の display:block 一括指定に負けないよう詳細度を上げる） */
  .cartype-table .cartype-table__pref {
    display: none;
  }

  .cartype-table tbody th[scope="row"] {
    width: auto;
    padding: 0 4px 8px;
    border-bottom: 0;
  }

  /* 単一県ページでは行内の県ラベルも不要 */
  .cartype-table:not(.cartype-table--single-pref) tbody th[scope="row"]::after {
    content: attr(data-pref);
    display: inline-block;
    margin-left: 8px;
    padding: 3px 8px;
    border-radius: 6px;
    background: var(--guide-soft);
    color: var(--guide-muted);
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1;
    vertical-align: middle;
  }

  .cartype-table tbody td {
    padding: 0 4px;
    border-bottom: 0;
  }

  .guide-table-scroll:has(.cartype-table) {
    overflow-x: visible;
  }
}

/* モーション設定を尊重 */
@media (prefers-reduced-motion: reduce) {
  a.cartype-tag {
    transition: none;
  }
}
