/*
 * 全ページ共通：リセット・文字組み・共通レイアウト（ヘッダー・ナビ・フッター）と共通部品。
 * 値はすべて tokens.css の変数から取る。ページ固有の部品（料金表・ギャラリー等）はここに入れない。
 */

/* リセット */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  min-width: 320px;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--f-body);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  -webkit-text-size-adjust: 100%;
  /* 中身が短いページでもフッターを画面の下端に置く */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--c-link); }
:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 2px; }

/* 文字組み */
h1, h2, h3 {
  font-family: var(--f-head);
  font-weight: var(--fw-head);
  line-height: 1.4;
  margin: 0 0 0.6em;
}
h1 { font-size: var(--fs-h1); letter-spacing: 0.12em; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p { margin: 0 0 1em; }

.wrap { max-width: var(--w-content); margin: 0 auto; padding: 0 var(--sp-4); }
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus {
  left: var(--sp-4);
  top: var(--sp-2);
  z-index: 20;
  padding: var(--sp-2);
  background: var(--c-surface);
}

/* ヘッダー */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--c-bg);
  border-bottom: 1px solid var(--c-line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--h-header);
}
.logo { display: flex; flex-direction: column; line-height: 1.1; color: var(--c-text); text-decoration: none; }
.logo b { font-family: var(--f-head); font-weight: var(--fw-head); font-size: 1.6rem; letter-spacing: 0.06em; }
.logo small { font-size: 0.7rem; color: var(--c-muted); letter-spacing: 0.2em; }

/* ナビ：PC は横並び、スマホは details の開閉（JS なし） */
.nav ul { list-style: none; margin: 0; padding: 0; }
.nav a {
  display: block;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-button);
  color: var(--c-text);
  font-size: 0.9rem;
  text-decoration: none;
}
.nav a:hover, .nav a[aria-current="page"] { background: var(--c-accent-soft); }
.nav-desktop { display: flex; gap: var(--sp-1); }
.nav-toggle { display: none; position: relative; }
.nav-toggle summary {
  list-style: none;
  cursor: pointer;
  padding: var(--sp-2) 14px;
  border: 1px solid var(--c-line);
  border-radius: var(--r-button);
  font-size: var(--fs-small);
}
.nav-toggle summary::-webkit-details-marker { display: none; }
.nav-toggle ul {
  position: absolute;
  right: 0;
  top: 48px;
  width: 220px;
  padding: var(--sp-2);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
@media (max-width: 760px) {
  .nav .nav-desktop { display: none; }
  .nav-toggle { display: block; }
}

/* セクション・見出し */
.section { padding: var(--sp-8) 0; }
.section-alt { background: var(--c-surface-alt); }
.section-title { text-align: center; }
.section-title::after {
  content: "";
  display: block;
  width: 24px;
  height: 1px;
  margin: var(--sp-3) auto 0;
  background: var(--c-accent);
}
.lead { text-align: center; color: var(--c-muted); max-width: 40em; margin: 0 auto var(--sp-6); }

/* ボタン */
.btn {
  display: inline-block;
  padding: var(--sp-3) 28px;
  border: 1px solid var(--c-primary);
  border-radius: var(--r-button);
  background: var(--c-primary);
  color: var(--c-on-primary);
  font-weight: 700;
  text-decoration: none;
}
.btn-ghost { background: transparent; color: var(--c-primary); }

/* 注意書き（AC・SET の「専門判断の代わりではない」等、複数ページで使う） */
.notice {
  margin: var(--sp-6) 0 0;
  padding: var(--sp-4) 20px;
  background: var(--c-notice-bg);
  border-left: 4px solid var(--c-accent);
  border-radius: var(--r-small);
  font-size: 0.9rem;
}

/* フッター */
.site-footer {
  padding: 40px 0 var(--sp-5);
  background: var(--c-footer-bg);
  color: var(--c-footer-text);
  font-size: var(--fs-small);
}
.site-footer ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) 20px;
  margin: 0 0 20px;
  padding: 0;
}
.site-footer a { color: var(--c-footer-text); }
.site-footer small { opacity: 0.75; }

/* ページ見出し（トップ以外の各ページの冒頭） */
.page-head { padding: var(--sp-7) 0 var(--sp-6); text-align: center; border-bottom: 1px solid var(--c-line); }
.page-head h1 { margin-bottom: var(--sp-3); }
.page-head p { color: var(--c-muted); margin: 0 auto; max-width: 36em; }
.text { max-width: var(--w-text); margin: 0 auto; }
.small { font-size: var(--fs-small); color: var(--c-muted); }
.center { text-align: center; }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-3); margin-top: var(--sp-6); }

/* ボタン：行き先が未確定のもの（Phase 5 で YASHIRO の URL が決まったら <a class="btn" href> に差し替える）。
   差し替え対象は data-cta 属性で探す（grep -rn 'data-cta' site） */
.btn-sm { padding: var(--sp-1) var(--sp-4); font-size: var(--fs-small); }
.btn-pending {
  background: var(--c-pending-bg);
  border-color: var(--c-pending-bg);
  color: var(--c-pending-text);
  font-weight: 400;
  cursor: default;
}

/* カード（メニュー・セッション等の並び） */
.cards { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card {
  display: flex;
  flex-direction: column;
  padding: var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
.card h3 { margin-bottom: var(--sp-2); }
.card p:last-child { margin-bottom: 0; }
.card .price { font-family: var(--f-head); font-size: 1.25rem; margin: auto 0 0; }
.card-kicker { font-size: 0.75rem; letter-spacing: 0.2em; color: var(--c-accent); margin: 0 0 var(--sp-1); }

/* 料金表：PC は表で横に比べる。スマホ（760px 以下）は1行を1枚のカードにする（td の data-label を見出しに使う） */
.price-table { width: 100%; border-collapse: collapse; background: var(--c-surface); font-size: 0.95rem; }
.price-table caption {
  text-align: left;
  font-size: var(--fs-small);
  color: var(--c-muted);
  padding-bottom: var(--sp-2);
}
.price-table th, .price-table td { padding: var(--sp-3); border-bottom: 1px solid var(--c-line); text-align: left; }
.price-table thead th {
  background: var(--c-surface-alt);
  font-size: var(--fs-small);
  font-weight: 700;
  white-space: nowrap;
}
.price-table tbody th { font-family: var(--f-head); font-weight: var(--fw-head); }
.price-table .num { white-space: nowrap; }
.price-table .yen { font-family: var(--f-head); font-size: 1.1rem; }
.tbd { color: var(--c-pending-text); }
.price-table + p, .price-table + .list { margin-top: var(--sp-4); }
@media (max-width: 760px) {
  .price-table, .price-table tbody, .price-table tr, .price-table th, .price-table td { display: block; }
  .price-table { background: none; }
  .price-table caption { display: block; }
  .price-table thead { display: none; }
  .price-table tr {
    margin-bottom: var(--sp-4);
    padding: var(--sp-2) var(--sp-4);
    background: var(--c-surface);
    border: 1px solid var(--c-line);
    border-radius: var(--r-card);
  }
  .price-table tbody th { padding: var(--sp-3) 0; font-size: 1.1rem; border-bottom: 1px solid var(--c-accent); }
  .price-table td { padding: var(--sp-2) 0; text-align: right; }
  .price-table td::after { content: ""; display: block; clear: both; }
  .price-table td:last-child { border-bottom: 0; }
  .price-table td::before {
    content: attr(data-label);
    float: left;
    margin-right: var(--sp-4);
    color: var(--c-muted);
    font-size: var(--fs-small);
  }
}

/* 箇条書き（注意事項など） */
.list { margin: 0; padding-left: 1.3em; }
.list li { margin-bottom: var(--sp-2); }

/* 項目と内容の一覧（講座の概要・セッションの条件など） */
.spec { margin: var(--sp-5) 0; border-top: 1px solid var(--c-line); }
.spec div { display: flex; gap: var(--sp-4); padding: var(--sp-3) 0; border-bottom: 1px solid var(--c-line); }
.spec dt { flex: none; width: 7em; color: var(--c-muted); font-size: 0.9rem; }
.spec dd { margin: 0; }
@media (max-width: 760px) {
  .spec div { flex-direction: column; gap: 0; }
}

/* お届けいただいた文章の改行を保つ */
.original-copy {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* よくあるご質問：質問だけを並べ、押すと答えが下に開く（JS なし・むっちゃんさん 2026-12-01 seq 37） */
.faq-item {
  border-bottom: 1px solid var(--c-line);
}
.faq-item summary {
  cursor: pointer;
  min-height: 44px;
  padding: 0.9em 2em 0.9em 0;
  position: relative;
  list-style: none;
  font-weight: 600;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "＋";
  color: var(--c-accent);
  position: absolute;
  right: 0.2em;
  top: 0.9em;
}
.faq-item[open] summary::after { content: "－"; }
.faq-answer {
  padding: 0 0 1.2em;
}
