/* ========================================
   アプリガイド（ja/en の guide.html）— パステル版
   - 章（details）は開閉できるカード。見出し（summary）を章ごとの色の付箋に見立てる
   - 章の本文は .prose（css/page.css）を基本に、小見出し・手順・注記をこのページ用に整える
   - 章の id は他のページやアプリから #章 で直接開かれるので、固定ヘッダーに隠れないよう余白を取る
   共通部品は css/cards.css・css/page.css、配色トークンは css/site.css
   ======================================== */

/* 見出しの補足（対応機種の一文）は、リードより一段小さく */
.page-note {
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
  font-size: 0.875rem;
  line-height: 1.85;
  color: var(--c-ink-soft);
}

/* ── 目次（ラベンダーのステッカー） ── */
.guide-toc {
  margin-bottom: 56px;
}

.guide-toc .guide-toc-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1rem;
  color: var(--c-lavender-deep);
}

.guide-toc .toc {
  justify-content: center;
}

.guide-toc .toc a {
  gap: 6px;
  min-height: 44px;
}

.guide-toc .toc .icon {
  width: 16px;
  height: 16px;
}

/* ── 章 ── */
.guide-chapters {
  display: grid;
  gap: 20px;
}

.guide-chapter {
  /* 固定ヘッダー（上から 12px ＋ 高さ約 58px）の下に見出しが来るように */
  scroll-margin-top: 96px;
  padding: 0;
  overflow: hidden;
}

.guide-chapter > * + * {
  margin-top: 0;
}

.guide-chapter.is-pink     { --note-bg: var(--c-pink);     --note-tint: var(--c-pink-tint);     --note-deep: var(--c-pink-deep); }
.guide-chapter.is-mint     { --note-bg: var(--c-mint);     --note-tint: var(--c-mint-tint);     --note-deep: var(--c-mint-deep); }
.guide-chapter.is-lemon    { --note-bg: var(--c-lemon);    --note-tint: var(--c-lemon-tint);    --note-deep: var(--c-lemon-deep); }
.guide-chapter.is-lavender { --note-bg: var(--c-lavender); --note-tint: var(--c-lavender-tint); --note-deep: var(--c-lavender-deep); }
.guide-chapter.is-sky      { --note-bg: var(--c-sky);      --note-tint: var(--c-sky-tint);      --note-deep: var(--c-sky-deep); }
.guide-chapter.is-peach    { --note-bg: var(--c-peach);    --note-tint: var(--c-peach-tint);    --note-deep: var(--c-peach-deep); }

.guide-summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 72px;
  padding: 12px 18px;
  background: var(--note-bg);
  cursor: pointer;
  list-style: none;
}

.guide-summary::-webkit-details-marker {
  display: none;
}

.guide-summary:focus-visible {
  outline: 3px solid var(--c-berry);
  outline-offset: -3px;
}

.guide-summary-title {
  flex: 1;
  min-width: 0;
  font-family: var(--font-headline);
  font-weight: 800;
  font-size: 1.125rem;
  line-height: 1.45;
}

.guide-chevron {
  width: 22px;
  height: 22px;
  color: var(--note-deep);
  transition: transform 0.25s ease;
}

.guide-chapter[open] .guide-chevron {
  transform: rotate(180deg);
}

.guide-body {
  padding: 24px 20px 28px;
}

/* 小見出し。章の色の短い線を頭に付ける */
.guide-body h4 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 32px;
  font-family: var(--font-headline);
  font-weight: 800;
  font-size: 1.0625rem;
  line-height: 1.5;
}

.guide-body h4::before {
  content: "";
  flex-shrink: 0;
  width: 16px;
  height: 6px;
  border-radius: 9999px;
  background: var(--note-tint);
}

.guide-body h4:first-child {
  margin-top: 0;
}

.guide-body ul:not(.check-list) li::marker {
  color: var(--note-deep);
}

.guide-body .fine {
  font-size: 0.8125rem;
}

/* 番号付きの手順。番号は章の色の札に白い丸で載せる */
.guide-body .guide-steps {
  list-style: none;
  padding-left: 0;
  counter-reset: guide-step;
}

.guide-steps > li {
  position: relative;
  padding: 12px 14px 12px 54px;
  border-radius: 14px;
  background: var(--note-bg);
}

.guide-steps > li + li {
  margin-top: 8px;
}

.guide-steps > li::before {
  counter-increment: guide-step;
  content: counter(guide-step);
  position: absolute;
  left: 12px;
  top: 12px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9999px;
  background: var(--c-white);
  font-family: var(--font-headline);
  font-weight: 800;
  font-size: 0.875rem;
  line-height: 1;
  color: var(--note-deep);
}

/* 補足（メモ）と注意（ピンクの付箋） */
.guide-note {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 18px;
  box-shadow: none;
}

.guide-note > * + * {
  margin-top: 0;
}

.guide-note p {
  font-size: 0.875rem;
  line-height: 1.8;
}

.guide-note-icon {
  display: inline-flex;
  margin-top: 3px;
  color: var(--c-lavender-deep);
}

.guide-note.is-caution .guide-note-icon {
  color: var(--c-pink-deep);
}

/* 料金の章の2つの作り方（画びょうで留めたカード） */
.guide-plans {
  display: grid;
  gap: 28px;
  padding-top: 12px;
}

.guide-plans .bcard {
  padding: 28px 20px 20px;
}

/* 小見出しの線の色を、章の色ではなくカードの色に合わせる */
.guide-plans .is-lavender { --note-tint: var(--c-lavender-tint); }
.guide-plans .is-mint     { --note-tint: var(--c-mint-tint); }

/* 3枚目のプランのカード（プレミアム色紙）。画びょうのカードの色は cards.css に紫・緑しか無いので、ここで足す */
.guide-plans .bcard--pinned.is-peach {
  --note-bg: var(--c-peach);
  --note-deep: var(--c-peach-deep);
  --pin: var(--c-peach-deep);
  --note-tint: var(--c-peach-tint);
}

/* 本文の挿絵（ARやVRで見る など）。狭い画面では縦に、広い画面では2枚を横に並べる */
.guide-figures {
  display: grid;
  gap: 16px;
  margin: 16px 0;
}

.guide-figures figure {
  margin: 0;
}

.guide-figures img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  background: var(--c-white);
}

.guide-figures figcaption {
  margin-top: 6px;
  font-size: 0.8125rem;
  text-align: center;
}

.guide-body .check-list {
  list-style: none;
  padding-left: 0;
}

/* ── 問い合わせの案内（虹色のカード） ── */
.guide-cta .round-icon {
  width: 56px;
  height: 56px;
  color: var(--c-berry-deep);
}

.guide-cta .round-icon .icon {
  width: 28px;
  height: 28px;
}

.guide-cta h3 {
  font-size: clamp(1.375rem, 5vw, 1.75rem);
}

@media (min-width: 640px) {
  .guide-plans {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .guide-figures {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* 2列で余った最後の1枚は横幅いっぱいに置く */
  .guide-plans > :last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }
}

@media (min-width: 768px) {
  .guide-summary {
    padding: 14px 28px;
  }

  .guide-summary-title {
    font-size: 1.25rem;
  }

  .guide-body {
    padding: 32px 40px 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .guide-chevron {
    transition: none;
  }
}
