/* 顕正会をやめたいあなたへ — スタイル
   方針：深夜にスマートフォンで一人で読む人を想定する。
   落ち着いた配色、長い日本語文章に耐える行間、JSに依存しない。 */

:root {
  --bg:        #fbfaf8;
  --bg-soft:   #f3f1ec;
  --bg-card:   #ffffff;
  --text:      #1f2328;
  --text-mute: #5a6169;
  --rule:      #e2ded6;
  --accent:    #2f6f6a;
  --accent-sb: #e7f0ee;
  --link:      #1c5d86;
  --warn:      #8a4b16;
  --warn-sb:   #fdf3e7;
  --good:      #2d6a43;
  --good-sb:   #ecf5ef;
  --draft:     #6b5b16;
  --draft-sb:  #fbf7e4;
  --measure:   34rem;
  --radius:    10px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:        #15181c;
    --bg-soft:   #1c2026;
    --bg-card:   #1b1f24;
    --text:      #e4e7ea;
    --text-mute: #a3abb4;
    --rule:      #2e343b;
    --accent:    #7fc8bf;
    --accent-sb: #1b2a29;
    --link:      #85c0e8;
    --warn:      #e0a86a;
    --warn-sb:   #2a2219;
    --good:      #8ecfa5;
    --good-sb:   #1a251e;
    --draft:     #d6c572;
    --draft-sb:  #26230f;
  }
}
:root[data-theme="dark"] {
  --bg:#15181c; --bg-soft:#1c2026; --bg-card:#1b1f24; --text:#e4e7ea;
  --text-mute:#a3abb4; --rule:#2e343b; --accent:#7fc8bf; --accent-sb:#1b2a29;
  --link:#85c0e8; --warn:#e0a86a; --warn-sb:#2a2219; --good:#8ecfa5;
  --good-sb:#1a251e; --draft:#d6c572; --draft-sb:#26230f;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", Meiryo, sans-serif;
  font-size: 17px;
  line-height: 1.95;
  letter-spacing: .012em;
  text-align: left;
}

.skip {
  position: absolute; left: -9999px;
}
.skip:focus {
  left: 1rem; top: .5rem; z-index: 99; padding: .5rem .9rem;
  background: var(--accent); color: #fff; border-radius: 6px;
}

/* ───── ヘッダー ───── */
.top {
  border-bottom: 1px solid var(--rule);
  background: var(--bg-card);
  position: sticky; top: 0; z-index: 20;
}
.top-in {
  max-width: 54rem; margin: 0 auto; padding: .7rem 16px;
  display: flex; align-items: center; gap: 1rem; justify-content: space-between;
}
.brand {
  font-weight: 700; font-size: .98rem; color: var(--text);
  text-decoration: none; line-height: 1.4;
}
.exit {
  flex: none; font-size: .82rem; font-weight: 600;
  padding: .45rem .8rem; border: 1px solid var(--rule); border-radius: 999px;
  color: var(--text-mute); text-decoration: none; background: var(--bg-soft);
  min-height: 36px; display: inline-flex; align-items: center;
}
.exit:hover, .exit:focus { color: var(--text); border-color: var(--text-mute); }

/* ───── 本文 ───── */
main { max-width: 54rem; margin: 0 auto; padding: 0 16px 3rem; }

.crumb {
  font-size: .8rem; color: var(--text-mute);
  padding: .9rem 0 0; display: flex; gap: .45rem; flex-wrap: wrap;
}
.crumb a { color: var(--text-mute); }
.crumb span[aria-hidden] { opacity: .6; }

.prose { max-width: var(--measure); margin: 0 auto; }

h1 {
  font-size: 1.6rem; line-height: 1.5; letter-spacing: -.005em;
  margin: 1.4rem 0 .8rem; font-weight: 700;
}
.lede {
  font-size: 1.04rem; color: var(--text-mute);
  margin: 0 0 2rem; padding-bottom: 1.3rem;
  border-bottom: 1px solid var(--rule);
}
.lede:empty { display: none; }

h2 {
  font-size: 1.22rem; line-height: 1.6; margin: 2.8rem 0 .9rem;
  font-weight: 700; padding-top: .3rem;
}
h3 {
  font-size: 1.04rem; line-height: 1.65; margin: 2rem 0 .6rem; font-weight: 700;
}
h4 { font-size: .97rem; margin: 1.5rem 0 .5rem; color: var(--text-mute); }

p { margin: 0 0 1.15rem; }
a { color: var(--link); text-decoration: underline; text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }

strong { font-weight: 700; }

ul, ol { margin: 0 0 1.3rem; padding-left: 1.5em; }
li { margin: 0 0 .5rem; }
li::marker { color: var(--text-mute); }

blockquote {
  margin: 1.5rem 0; padding: .3rem 0 .3rem 1.1rem;
  border-left: 3px solid var(--accent);
  color: var(--text-mute); font-size: .96rem;
}
blockquote p:last-child { margin-bottom: 0; }

hr { border: 0; border-top: 1px solid var(--rule); margin: 2.6rem 0; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .88em; background: var(--bg-soft);
  padding: .12em .4em; border-radius: 4px;
}

/* ───── 表 ───── */
.table-wrap { overflow-x: auto; margin: 1.5rem 0; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; width: 100%; font-size: .9rem; line-height: 1.6; }
th, td { padding: .55rem .7rem; text-align: left; border-bottom: 1px solid var(--rule); }
th { font-weight: 700; background: var(--bg-soft); white-space: nowrap; }
td { vertical-align: top; }

/* ───── コールアウト ───── */
.callout {
  margin: 1.8rem 0; padding: 1.1rem 1.15rem;
  border-radius: var(--radius); border: 1px solid var(--rule);
  background: var(--bg-card); font-size: .96rem;
}
.callout p:last-child, .callout ul:last-child, .callout ol:last-child { margin-bottom: 0; }
.callout-label {
  font-weight: 700; font-size: .84rem; letter-spacing: .04em;
  margin: 0 0 .5rem; color: var(--accent);
}
.callout-note { background: var(--accent-sb); border-color: transparent; }
.callout-note  .callout-label { color: var(--accent); }
.callout-warn  { background: var(--warn-sb);  border-color: transparent; }
.callout-warn  .callout-label { color: var(--warn); }
.callout-good  { background: var(--good-sb);  border-color: transparent; }
.callout-good  .callout-label { color: var(--good); }
.callout-fact  { background: var(--bg-soft);  border-color: var(--rule); }
.callout-fact  .callout-label { color: var(--text-mute); }
.callout-fact  { font-size: .9rem; }
.callout-draft { background: var(--draft-sb); border-color: transparent; }
.callout-draft .callout-label { color: var(--draft); }

/* ───── 図 ───── */
.chart {
  margin: 2rem 0 1.2rem; padding: 1rem .7rem .4rem;
  background: var(--bg-card); border: 1px solid var(--rule);
  border-radius: var(--radius);
}
.chart svg { display: block; overflow: visible; }
.chart .grid  { stroke: var(--rule); stroke-width: 1; }
.chart .line  { fill: none; stroke: var(--accent); stroke-width: 2.4;
                stroke-linejoin: round; stroke-linecap: round; }
.chart .line-gap { stroke-dasharray: 5 5; opacity: .5; }
.chart .evline   { stroke: var(--text-mute); stroke-width: 1; stroke-dasharray: 3 4;
                   opacity: .55; }
.chart .evlabel  { text-anchor: middle; font-size: 10.5px; fill: var(--text-mute); }
.chart .val      { font-size: 11px; font-weight: 700; fill: var(--accent); }
.chart .val-end  { text-anchor: end; }
.chart .dot-excl { fill: var(--bg-card); stroke: var(--text-mute); stroke-width: 2; }
.chart .excl-v   { text-anchor: middle; font-size: 11.5px; font-weight: 700;
                   fill: var(--text-mute); }
.chart .excl-n   { text-anchor: middle; font-size: 10px; fill: var(--text-mute); }
.row-excl td     { color: var(--text-mute); }
.chart .band     { fill: var(--accent); opacity: .10; }
.chart .bandlabel{ text-anchor: middle; font-size: 10px; font-weight: 700;
                   fill: var(--accent); }
.chart .ceil     { stroke: var(--warn); stroke-width: 1.2; opacity: .55; }
.chart .ceil-l   { fill: var(--warn); font-weight: 700; }
.chart .ceil-n   { text-anchor: end; font-size: 9.5px; fill: var(--warn); opacity: .9; }
.chart .evdot    { fill: var(--text-mute); opacity: .7; }
.chart .dot   { fill: var(--accent); }
.chart .ax    { fill: var(--text-mute); font-size: 11px; }
.chart .ax-y  { text-anchor: end; }
.chart .ax-x  { text-anchor: middle; }
.chart .ax-t  { fill: var(--text-mute); font-size: 11.5px; font-weight: 700; }
.chart .ax-note { text-anchor: start; font-size: 9.5px; opacity: .85; }
.chart figcaption {
  font-size: .82rem; color: var(--text-mute); line-height: 1.75;
  margin: .9rem .3rem .4rem;
}

.data-table { margin: 0 0 1.8rem; font-size: .9rem; }
.data-table summary {
  cursor: pointer; color: var(--link); padding: .5rem 0;
  min-height: 36px; display: flex; align-items: center;
}
.fn { font-size: .8rem; color: var(--text-mute); }

/* ───── 次の一歩 ───── */
.nextstep {
  display: block; margin: 3rem 0 0; padding: 1.1rem 1.25rem;
  background: var(--accent); color: #fff; border-radius: var(--radius);
  text-decoration: none; line-height: 1.6;
}
:root[data-theme="dark"] .nextstep,
:root:not([data-theme="light"]) .nextstep { color: #10211f; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .nextstep { color: #fff; }
}
.nextstep:hover { filter: brightness(1.07); }
.nextstep-k {
  display: block; font-size: .78rem; font-weight: 700;
  letter-spacing: .08em; opacity: .82; margin-bottom: .2rem;
}
.nextstep-t { display: block; font-size: 1.06rem; font-weight: 700; }

/* ───── 相談窓口 ───── */
.help {
  max-width: var(--measure); margin: 3.2rem auto 0;
  padding: 1.3rem 1.3rem .4rem;
  background: var(--bg-soft); border-radius: var(--radius);
  border: 1px solid var(--rule); font-size: .94rem;
}
.help h2 { font-size: 1.02rem; margin: 0 0 .6rem; padding: 0; }
.help ul { padding-left: 1.3em; }

/* ───── フッター ───── */
.foot {
  border-top: 1px solid var(--rule); background: var(--bg-card);
  margin-top: 3.5rem; padding: 2.2rem 0 3rem;
}
.foot-in {
  max-width: 54rem; margin: 0 auto; padding: 0 16px;
  display: grid; gap: 2.4rem;
}
.sitenav { font-size: .92rem; }
.sitenav .navsec {
  font-size: .78rem; font-weight: 700; letter-spacing: .06em;
  color: var(--text-mute); margin: 1.4rem 0 .4rem;
}
.sitenav .navsec:first-child { margin-top: 0; }
.sitenav ul { list-style: none; padding: 0; margin: 0; }
.sitenav li { margin: 0; }
.sitenav a {
  display: block; padding: .42rem 0; text-decoration: none;
  color: var(--link); min-height: 36px;
}
.sitenav a:hover { text-decoration: underline; }
.sitenav a[aria-current="page"] { color: var(--text-mute); font-weight: 700; }

.foot-meta { font-size: .85rem; color: var(--text-mute); line-height: 1.8; }
.foot-meta .safety {
  padding: .9rem 1rem; background: var(--bg-soft);
  border-radius: 8px; border: 1px solid var(--rule);
}
.foot-meta .upd { font-size: .78rem; opacity: .8; }

/* ───── 画面幅 ───── */
@media (min-width: 52rem) {
  body { font-size: 17.5px; }
  h1 { font-size: 1.95rem; }
  h2 { font-size: 1.32rem; }
  .foot-in { grid-template-columns: 1fr 1.1fr; gap: 3rem; }
}

@media print {
  .top, .exit, .foot, .nextstep { display: none; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .prose { max-width: none; }
}

/* 対比グラフ（入信者総数と活動者数） */
.chart-two .line-b  { stroke: var(--warn); }
.chart-two .dot-b   { fill: var(--warn); }
.chart-two .goal    { stroke: var(--text-mute); stroke-dasharray: 4 4; opacity: .5; }
.chart-two .goal-l  { text-anchor: end; font-size: 10.5px; fill: var(--text-mute); }
.chart-two .val     { font-size: 11.5px; }
