/* 共通の骨組み。色・書体・ヒーローは themes/<slug>.css で決める */
:root { color-scheme: light; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs, 17px);
  line-height: 1.95;
  letter-spacing: .03em;
  font-kerning: normal;
  overflow-wrap: anywhere;
  word-break: normal;
  line-break: strict;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .22em; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--focus, var(--ink)); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: var(--display-weight, 600); line-height: 1.5; letter-spacing: .06em; margin: 0; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul { margin: 0; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 20; background: var(--surface); padding: .5rem 1rem; }

/* セクション */
.section { max-width: 36rem; margin: 0 auto; padding: clamp(2.75rem, 8vw, 4.5rem) 1.25rem; }
.section + .section { border-top: 1px solid var(--line); }
.section h2 { font-size: clamp(1.3rem, 1.12rem + .8vw, 1.65rem); margin-bottom: 1.25rem; }

/* ボタン */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3.4rem; padding: .8rem 1.75rem;
  border-radius: var(--btn-radius, 4px);
  font-family: var(--font-btn, var(--font-body)); font-weight: 700; font-size: 1rem; letter-spacing: .08em;
  text-decoration: none; text-align: center; line-height: 1.5;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-line { background: #047a37; color: #fff; width: min(100%, 24rem); }
.btn-line:hover { box-shadow: 0 0 0 3px rgba(4, 122, 55, .2); }
.btn-buy { background: var(--btn-bg, var(--ink)); color: var(--btn-ink, var(--surface)); width: 100%; }
.btn-buy:hover { box-shadow: 0 0 0 3px var(--btn-ring, rgba(0, 0, 0, .12)); }
.btn.is-disabled { background: var(--line); color: var(--muted); cursor: not-allowed; box-shadow: none; }

/* ヒーロー共通 */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero-inner { position: relative; z-index: 1; }
.hero-place { margin: 0; color: var(--muted); letter-spacing: .18em; font-size: .95rem; }
.hero-lead { font-family: var(--font-display); font-size: clamp(1.12rem, 1rem + .8vw, 1.45rem); line-height: 2.05; margin: 1.1rem 0 2rem; }
.name-ruby { color: var(--muted); font-family: var(--font-body); font-weight: 400; }

/* 上部ナビ（トップ以外） */
.topbar {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  max-width: 60rem; margin: 0 auto; padding: .9rem 1.25rem;
  border-bottom: 1px solid var(--line);
}
.topbar-name { font-family: var(--font-display); font-size: 1.25rem; text-decoration: none; letter-spacing: .15em; }
.topbar-link { font-size: .9rem; }

/* トップ */
.profile p { margin-bottom: 1.2em; }
.features-list { margin: 0; display: grid; gap: 1.5rem; }
.features-list dt { font-family: var(--font-display); font-weight: var(--display-weight, 600); font-size: 1.1rem; margin-bottom: .25rem; }
.features-list dd { margin: 0; color: var(--ink); }
.start { text-align: center; }
.start p { text-align: left; }
.start .btn { margin-top: .5rem; }
.start-sub { text-align: center !important; margin-top: 1.25rem; font-size: .95rem; }
.voices figure { margin: 0 0 1.5rem; }
.voices blockquote { margin: 0 0 .5rem; }
.voices figcaption { color: var(--muted); font-size: .9rem; }

/* 鑑定メニュー */
.reading-head { max-width: 36rem; margin: 0 auto; padding: clamp(2.75rem, 9vw, 5rem) 1.25rem 1rem; }
.reading-head h1 { font-size: clamp(1.45rem, 1.1rem + 1.5vw, 2.1rem); margin-bottom: 1.25rem; line-height: 1.6; }
.plans-note { color: var(--muted); }
.plan-list { display: grid; gap: 1.25rem; margin-top: 1.5rem; }
.plan { background: var(--surface); padding: 1.5rem 1.35rem 1.4rem; }
.plan-head { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: .1rem 1rem; margin-bottom: 1rem; }
.plan-name { font-size: 1.4rem; letter-spacing: .12em; }
.plan-price { margin: 0; font-family: var(--font-display); font-size: 1.45rem; letter-spacing: .02em; white-space: nowrap; }
.plan-price small { font-size: .72rem; color: var(--muted); letter-spacing: 0; margin-left: .15em; }
.plan-slot { grid-column: 1 / -1; margin: .1rem 0 0; font-size: .9rem; font-weight: 700; color: var(--slot, var(--accent)); }
.plan-summary { margin-bottom: .75rem; }
.plan-includes { padding-left: 1.2em; margin: 0 0 1.4rem; }
.plan-includes li { margin: .2rem 0; }
.receipt-note { margin-top: 1.5rem; padding: 1rem 1.1rem; background: var(--surface); border-left: 3px solid var(--accent); font-size: .95rem; }

.flow { list-style: none; padding: 0; margin: 0; counter-reset: flow; }
.flow li { counter-increment: flow; position: relative; margin-left: 1rem; padding: 0 0 1.6rem 2.1rem; border-left: 1px solid var(--line); }
.flow li:last-child { border-left-color: transparent; padding-bottom: 0; }
.flow li::before {
  content: counter(flow);
  position: absolute; left: -1rem; top: .1rem;
  width: 2rem; height: 2rem; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--bg); border: 1px solid var(--ink);
  font-family: var(--font-display); font-size: .9rem; line-height: 1;
}
.flow h3 { font-size: 1.05rem; margin-bottom: .2rem; }

.faq { border-top: 1px solid var(--line); }
.faq:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; position: relative; padding: 1rem 2.25rem 1rem 0; font-weight: 700; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "＋"; position: absolute; right: .25rem; top: 1rem; color: var(--accent); font-weight: 400; }
.faq[open] summary::after { content: "－"; }
.faq > div { padding: 0 0 1.1rem; }

.notes ul { padding-left: 1.2em; color: var(--muted); font-size: .95rem; }
.notes li { margin: .35rem 0; }

/* フッター */
.foot { border-top: 1px solid var(--line); padding: 2.5rem 1.25rem 3rem; text-align: center; font-size: .875rem; color: var(--muted); }
.foot-name { font-family: var(--font-display); color: var(--ink); font-size: 1.1rem; letter-spacing: .15em; margin-bottom: 1rem; }
.foot-name span { display: block; font-family: var(--font-body); font-size: .8rem; color: var(--muted); letter-spacing: .1em; }
.foot-links { list-style: none; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1.25rem; }

/* 法務ページ */
.legal { max-width: 40rem; margin: 0 auto; padding: clamp(2.5rem, 8vw, 4rem) 1.25rem; }
.legal h1 { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); margin-bottom: 2rem; }
.legal h2 { font-size: 1.1rem; margin: 2rem 0 .5rem; }
.legal-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: .95rem .5rem; border-bottom: 1px solid var(--line); }
.legal-table th { width: 11em; font-weight: 700; }
@media (max-width: 560px) {
  .legal-table th, .legal-table td { display: block; width: auto; }
  .legal-table th { border-bottom: 0; padding-bottom: .1rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* 未記入の目印（公開前に消える） */
mark.todo { background: #ffe066; color: #3a2a00; padding: 0 .2em; border-radius: 2px; font-family: system-ui, sans-serif; font-size: .85em; }

/* 文節の塊（build.mjs の phr）。行頭・行末の約物の詰めも入れる */
.ph { display: inline-block; }
.hero-lead, .reading-head h1 { text-wrap: balance; }

/* 音無 — 新宮・熊野。霧の地に深い川の色。筆文字の名前と、一度だけ流れる滝の線 */
.t-otonashi {
  --bg: #dfe5e4; --surface: #eef2f1; --ink: #1b2f33; --muted: #50656a;
  --accent: #6e5434; --line: #c3cecd; --focus: #1b2f33;
  --font-brush: "Yuji Syuku", "Hiragino Mincho ProN", serif;
  --font-display: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --font-body: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --display-weight: 600; --btn-radius: 999px; --btn-ring: rgba(27, 47, 51, .18);
}
.t-otonashi .hero-name, .t-otonashi .reading-head h1, .t-otonashi .topbar-name, .t-otonashi .foot-name { font-family: var(--font-brush); font-weight: 400; }
.hero-falls { min-height: min(96vh, 50rem); display: grid; place-items: center; text-align: center; background: linear-gradient(180deg, #cdd7d6 0%, var(--bg) 62%); }
.hero-falls .falls { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; color: #6f8888; }
.hero-falls .falls path { vector-effect: non-scaling-stroke; stroke-width: 1.2px; stroke-dasharray: 1; stroke-dashoffset: 1; animation: otonashi-fall 3.2s cubic-bezier(.35, .05, .2, 1) forwards; animation-delay: var(--d); }
@keyframes otonashi-fall { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .hero-falls .falls path { stroke-dashoffset: 0; } }
.hero-falls .hero-inner {
  max-width: 30rem; margin: 0 auto; padding: 4rem 1.75rem;
  background: radial-gradient(closest-side, rgba(223, 229, 228, .95) 55%, rgba(223, 229, 228, 0));
}
.hero-falls .hero-name { font-size: clamp(5.2rem, 25vw, 10rem); line-height: 1; letter-spacing: .08em; }
.hero-falls .name-ruby { margin: .9rem 0 1.4rem; letter-spacing: .6em; font-size: .9rem; }
.hero-falls .hero-lead { margin-top: .9rem; }
.t-otonashi .plan { background: transparent; padding: 1.6rem .25rem 1.5rem; border-top: 1px solid var(--ink); }
.t-otonashi .plan + .plan { border-top-color: var(--line); }
.t-otonashi .receipt-note { background: transparent; border: 1px solid var(--line); border-radius: 12px; }
.t-otonashi .flow li::before { background: var(--ink); color: var(--bg); border: 0; }
@media (max-width: 600px) { .hero-falls { min-height: 82vh; } }
