/* ============================================================
   ときあけ — 配布サイト共通スタイル
   トークンはアプリの DesignSystem/Tokens.swift（docs-internal/design.md §2）に合わせる。
   暁（紅紫）＝操作と「まだ夜」、曙色＝正解と「ひらいた」。曙色は「明ける」意味のときだけ使う。
   ヒーローとナビは外観に関係なく暁の夜。ボタンは角丸の四角（カプセルにしない。design.md §2-6）。
   ============================================================ */

:root {
  --bg: #f8f0f2;            /* 明け方 */
  --surface: #ffffff;
  --surface2: #f3e5e8;
  --ink: #2c1221;
  --ink-sub: #6e4e5f;
  --line: #ebd8dd;
  --line-strong: #9d798b;
  --akatsuki: #9e1673;      /* 暁（操作・リンク） */
  --on-akatsuki: #ffffff;
  --akebono: #c8561f;       /* 曙色（明ける意味だけ） */
  --akebono-text: #a8461a;
  --akebono-soft: #fbe4d5;
  --sky-night: #f3d6e2;
  --sky-dawn: #fadccb;
  --horizon: #8a6176;
  /* 固定の夜（ヒーロー・ナビ・フッター。ブロック画面と同じ暁の夜） */
  --night-top: #1e0715;
  --night: #2a0b1f;
  --night-low: #3e0d2b;
  --night-ground: #14040e;
  --night-ink: #ffeff5;
  --night-sub: #e6bdd2;
  --night-line: #4a1a38;
  --night-akebono: #ff9f66;
  --night-horizon: #f0b08a;
  --radius: 16px;
  --maxw: 1040px;
  --gothic: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #230a17;          /* 暁の夜 */
    --surface: #321525;
    --surface2: #412034;
    --ink: #fbeaf0;
    --ink-sub: #c7a3b5;
    --line: #49273b;
    --line-strong: #976d83;
    --akatsuki: #f2a9b6;
    --on-akatsuki: #2a0a1e;
    --akebono: #ff9f66;
    --akebono-text: #ffb48a;
    --akebono-soft: #42211f;
    --sky-night: #1b0712;
    --sky-dawn: #4c2022;
    --horizon: #f0b08a;
  }
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--gothic);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
.num { font-stretch: condensed; font-variant-numeric: tabular-nums; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- ナビ（暁の夜） ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--night-top) 88%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--night-line);
  color: var(--night-ink);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; letter-spacing: .02em; }
.brand img { width: 30px; height: 30px; border-radius: 7px; }
.nav-links { display: flex; gap: 20px; font-size: 14px; color: var(--night-sub); }
.nav-links a:hover { color: var(--night-ink); }
@media (max-width: 560px) { .nav-links { gap: 14px; font-size: 13px; } .nav-links .hide-sm { display: none; } }

/* ---------- ヒーロー（夜明け前。中央ぞろえ・地平線の中央から輪が昇る） ---------- */
.hero {
  position: relative;
  color: var(--night-ink);
  text-align: center;
  background: linear-gradient(180deg, var(--night-top) 0%, #2f0b22 38%, var(--night-low) 62%, #6d1d3a 100%);
  padding: 76px 0 0;
  overflow: hidden;
}
.hero h1 { font-weight: 800; font-size: clamp(36px, 7vw, 64px); line-height: 1.3; letter-spacing: .01em; margin: 14px 0 18px; }
.hero .lead { color: var(--night-sub); font-size: 17px; max-width: 40em; margin: 0 auto; }
h1, h2, .lead, .desc { word-break: auto-phrase; text-wrap: pretty; }
.eyebrow { font-size: 13px; letter-spacing: .14em; color: var(--night-horizon); font-weight: 600; }
.hero-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 26px 0 28px; }
.tag { font-size: 13px; padding: 4px 12px; border: 1px solid rgba(230, 189, 210, .35); border-radius: 999px; color: var(--night-sub); }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px; }
.badge-soon {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--night-ink); color: var(--night);
  padding: 10px 20px; border-radius: 12px; font-weight: 700; line-height: 1.2; text-align: left;
}
.badge-soon small { display: block; font-size: 11px; font-weight: 500; opacity: .7; }
.badge-soon svg { width: 20px; height: 24px; }
.hero-note { font-size: 13px; color: var(--night-sub); }

.dawn {
  position: relative; height: 150px; margin-top: 36px; overflow: hidden;
}
.dawn::before {  /* 光 */
  content: ""; position: absolute; left: 50%; bottom: 0; width: 520px; height: 260px; transform: translate(-50%, 50%);
  background: radial-gradient(closest-side, rgba(255, 159, 102, .45), rgba(255, 159, 102, 0));
}
.dawn .ring {  /* 昇る輪（地平線より上だけ見せる） */
  position: absolute; left: 50%; bottom: 0; width: 200px; height: 100px; transform: translateX(-50%); overflow: hidden;
}
.dawn .ring::after {
  content: ""; position: absolute; left: 0; top: 0; width: 200px; height: 200px; border-radius: 50%;
  border: 36px solid var(--night-akebono); box-sizing: border-box;
}
.hero-ground {
  background: linear-gradient(180deg, #2b0b22, var(--night-ground));
  border-top: 3px solid var(--night-horizon);
  padding: 40px 0 72px;
}
.hero-phones { display: flex; justify-content: center; align-items: flex-start; gap: 32px; }
.hero-phones .phone { flex: 0 1 280px; margin: 0; }
.hero-phones .phone.small { flex: 0 1 220px; margin-top: 64px; }
@media (max-width: 720px) {
  .hero { padding-top: 48px; }
  .hero-phones .phone.small { display: none; }
  .dawn { height: 120px; }
}

.phone {
  width: 100%; max-width: 300px; margin: 0 auto;
  border-radius: 40px; overflow: hidden;
  border: 1px solid rgba(240, 176, 138, .28);
  box-shadow: 0 24px 60px rgba(20, 4, 14, .45);
  background: var(--night);
}

/* ---------- セクション ---------- */
.section { padding: 88px 0; }
.section-label { font-size: 13px; letter-spacing: .12em; font-weight: 700; color: var(--akatsuki); }
h2 { font-weight: 800; font-size: clamp(26px, 4vw, 36px); line-height: 1.45; margin: 10px 0 16px; }
.desc { color: var(--ink-sub); font-size: 16px; }
.center { text-align: center; }
.intro { max-width: 680px; margin: 0 auto 48px; }

.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; padding: 48px 0; border-top: 1px solid var(--line); }
.feature .phone { max-width: 270px; }
.feature .note { margin-top: 14px; font-size: 13px; color: var(--ink-sub); }
@media (max-width: 820px) {
  .section { padding: 64px 0; }
  .feature, .feature.reverse { grid-template-columns: 1fr; gap: 28px; }
  .feature.reverse > :first-child { order: 2; }  /* 狭い画面では、どの節も文 → 画面の順 */
}

/* 流れ（ブロック画面 → 問題 → そのアプリだけ → 自動で戻る） */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 8px; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 18px; }
.step b { display: block; font-size: 16px; margin-bottom: 4px; }
.step span { font-size: 14px; color: var(--ink-sub); line-height: 1.7; display: block; }
.step .rise { display: block; width: 44px; height: 22px; overflow: hidden; position: relative; margin-bottom: 12px; border-bottom: 2px solid var(--horizon); }
.step .rise::after { content: ""; position: absolute; left: 4px; width: 36px; height: 36px; border-radius: 50%; border: 7px solid var(--akebono); box-sizing: border-box; }
.step:nth-child(1) .rise::after { top: 18px; }
.step:nth-child(2) .rise::after { top: 12px; }
.step:nth-child(3) .rise::after { top: 3px; }
.step:nth-child(4) .rise::after { top: 20px; border-color: var(--line-strong); }
@media (max-width: 820px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 460px) { .steps { grid-template-columns: 1fr; } }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chip { font-size: 13px; padding: 4px 12px; border-radius: 999px; background: var(--surface2); color: var(--ink); }
.chip b { font-weight: 700; }

/* ---------- 正直な説明の帯 ---------- */
.honest {
  background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 56px 0;
}
.honest-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.hcard { border: 1.5px solid var(--line-strong); border-radius: 12px; padding: 18px 18px 16px; }
.hcard b { display: block; font-size: 16px; margin-bottom: 6px; }
.hcard p { font-size: 14px; color: var(--ink-sub); line-height: 1.75; }
@media (max-width: 820px) { .honest-grid { grid-template-columns: 1fr; } }

/* ---------- データの帯（朝の空） ---------- */
.privacy-band {
  background: linear-gradient(180deg, var(--sky-night), var(--sky-dawn));
  border-bottom: 2px solid var(--horizon);
  padding: 64px 0; text-align: center;
}
.privacy-band h2 { margin-top: 0; }
.privacy-band p { color: var(--ink-sub); }
.privacy-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 28px; }
.pcard { background: var(--surface); border-radius: 14px; padding: 16px 12px; }
.pcard b { display: block; font-size: 15px; }
.pcard span { font-size: 13px; color: var(--ink-sub); }
@media (max-width: 720px) { .privacy-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- 無料と Plus ---------- */
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 36px 0 20px; text-align: left; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 26px 24px; }
.plan.plus { border: 1.5px solid var(--akatsuki); }
.plan h3 { font-size: 18px; font-weight: 800; }
.plan .price { font-size: 14px; color: var(--ink-sub); margin: 2px 0 14px; }
.plan .price .num { font-size: 26px; font-weight: 800; color: var(--ink); margin-right: 6px; }
.plan ul { list-style: none; }
.plan li { font-size: 15px; padding: 7px 0 7px 24px; position: relative; border-top: 1px solid var(--line); }
.plan li:first-child { border-top: none; }
.plan li::before { content: ""; position: absolute; left: 2px; top: 15px; width: 12px; height: 12px; border-radius: 50%; border: 3px solid var(--akebono); box-sizing: border-box; }
.disclaimer { font-size: 13px; color: var(--ink-sub); max-width: 46em; margin: 18px auto 0; }
@media (max-width: 720px) { .plans { grid-template-columns: 1fr; } }

/* ---------- CTA ---------- */
.cta {
  background: linear-gradient(180deg, var(--night-top), var(--night-low));
  color: var(--night-ink); text-align: center; padding: 72px 0 0;
}
.cta .icon { width: 88px; height: 88px; border-radius: 20px; margin: 0 auto 18px; box-shadow: 0 10px 30px rgba(0, 0, 0, .4); }
.cta .desc { color: var(--night-sub); margin-bottom: 26px; }
.cta .dawn { margin-top: 20px; height: 110px; }
.cta-ground { background: var(--night-ground); border-top: 3px solid var(--night-horizon); height: 28px; }

/* ---------- フッター ---------- */
.footer { background: var(--night-ground); color: var(--night-sub); font-size: 13px; padding: 28px 0 36px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.footer .brand { color: var(--night-ink); font-size: 15px; }
.footer .brand img { width: 24px; height: 24px; border-radius: 6px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a:hover { color: var(--night-ink); }

/* ---------- 文書ページ（プライバシー・規約・サポート） ---------- */
.doc { max-width: 760px; margin: 0 auto; padding: 48px 20px 88px; }
.doc .back-home { font-size: 14px; color: var(--akatsuki); display: inline-block; margin-bottom: 20px; }
.doc h1 { font-weight: 800; font-size: clamp(28px, 5vw, 38px); line-height: 1.4; }
.doc .updated { color: var(--ink-sub); font-size: 14px; margin: 6px 0 28px; }
.doc h2 { font-size: 21px; margin: 40px 0 10px; padding-bottom: 6px; border-bottom: 2px solid var(--line); }
.doc h3 { font-size: 17px; font-weight: 700; margin: 30px 0 8px; }
.doc p, .doc li { font-size: 15.5px; }
.doc p + p { margin-top: 12px; }
.doc ul, .doc ol { padding-left: 1.4em; margin: 10px 0; }
.doc li { margin: 4px 0; }
.doc .callout {
  background: var(--akebono-soft); border-radius: 14px; padding: 16px 18px; margin: 20px 0 8px; font-size: 15px;
}
.doc .faq-index { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px 14px 36px; margin: 16px 0 8px; }
.doc .faq-index li { font-size: 14.5px; }
.doc .faq-index a { color: var(--akatsuki); }
a.inline { color: var(--akatsuki); text-decoration: underline; text-underline-offset: 3px; word-break: break-all; }
.doc code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .92em; background: var(--surface2); padding: 1px 6px; border-radius: 6px; }
.doc table { border-collapse: collapse; width: 100%; margin: 12px 0; font-size: 14.5px; }
.doc th, .doc td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.doc th { background: var(--surface2); font-weight: 700; }
