/* REBOOT JAPAN 共通スタイル（リデザイン案 2026-10-24）
   コンセプト：赤ペンで直す、日本の設計図。方眼紙の上に墨の文字、指摘は赤、修正は藍。
   全ページがこの1ファイルを読み込む。色はすべてトークン経由で指定する。 */

:root {
  --paper: #f5f6f8;      /* 背景（わずかに青みのある白） */
  --surface: #ffffff;    /* カード・表・入力欄 */
  --ink: #16181d;        /* 本文・見出し（墨） */
  --ink-2: #4b515c;      /* 説明文 */
  --ink-3: #626875;      /* 補足・日付 */
  --rule: #dde0e6;       /* 区切り線 */
  --red: #c8161d;        /* 赤ペン：ブランド色・指摘・現行制度 */
  --red-tint: #fcebeb;
  --fix: #1d4f91;        /* 藍：修正案・提言 */
  --fix-tint: #e9eff8;
  --on-accent: #ffffff;  /* 赤・藍の上の文字 */
  --grid: rgba(29, 79, 145, 0.07);
  --mark: rgba(200, 22, 29, 0.14);

  --font-display: 'Zen Kaku Gothic New', 'BIZ UDPGothic', 'Hiragino Sans', sans-serif;
  --display-weight: 900;
  --font-body: 'BIZ UDPGothic', 'Hiragino Sans', 'Noto Sans JP', 'Yu Gothic', sans-serif;
  --font-label: 'BIZ UDGothic', 'BIZ UDPGothic', ui-monospace, monospace;

  --measure: 40rem;      /* 本文の最大幅（1行およそ37字） */
  --wide: 70rem;
  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0f1115; --surface: #171a20; --ink: #eceef2; --ink-2: #b0b6c2; --ink-3: #8f96a4;
    --rule: #2a2f39; --red: #ff5c61; --red-tint: #3a1618; --fix: #86b4ff; --fix-tint: #15233a;
    --on-accent: #14070a; --grid: rgba(134, 180, 255, 0.06); --mark: rgba(255, 92, 97, 0.22);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0f1115; --surface: #171a20; --ink: #eceef2; --ink-2: #b0b6c2; --ink-3: #8f96a4;
  --rule: #2a2f39; --red: #ff5c61; --red-tint: #3a1618; --fix: #86b4ff; --fix-tint: #15233a;
  --on-accent: #14070a; --grid: rgba(134, 180, 255, 0.06); --mark: rgba(255, 92, 97, 0.22);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
/* hidden を付けた要素は、display を指定したクラスより優先して隠す */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.9;
  overflow-x: hidden;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 10; background: var(--paper);
}
a { color: inherit; }
h1, h2, h3, h4 { text-wrap: balance; line-height: 1.35; margin: 0; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--fix); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.wrap {
  max-width: var(--wide);
  margin: 0 auto;
  padding-left: var(--gutter-l);
  padding-right: var(--gutter-r);
}
.label {
  font-family: var(--font-label);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--ink-3);
}

/* ヘッダー */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-block: 0.85rem;
}
.logo {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  white-space: nowrap;
}
.logo span { color: var(--red); }
.main-nav { display: flex; gap: 1.25rem; font-size: 0.9rem; }
.main-nav a { color: var(--ink-2); text-decoration: none; padding-block: 0.25rem; border-bottom: 2px solid transparent; }
.main-nav a:hover { color: var(--ink); }
.main-nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--red); }
.progress {
  position: absolute; left: 0; bottom: -1px; height: 2px; width: 0;
  background: var(--red);
}

/* 方眼紙の背景 */
.graph {
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* トップ：ヒーロー */
.hero { border-bottom: 1px solid var(--rule); }
.hero .wrap { padding-block: clamp(3rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4.5rem); display: grid; gap: 1.75rem; }
.eyebrow { font-family: var(--font-label); font-size: 0.85rem; letter-spacing: 0.12em; color: var(--red); font-weight: 700; }
.hero h1 {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-size: clamp(2.6rem, 9vw, 5.75rem);
  line-height: 1.2;
  letter-spacing: 0.01em;
}
.hero-lead { max-width: 34em; color: var(--ink-2); font-size: 1.1rem; }

/* 赤ペンの丸囲み */
.red-circle { position: relative; display: inline-block; color: var(--red); white-space: nowrap; }
.red-circle svg {
  position: absolute; left: -12%; top: -14%; width: 124%; height: 128%;
  overflow: visible; pointer-events: none;
}
.red-circle path {
  fill: none; stroke: var(--red); stroke-width: 3; stroke-linecap: round;
  stroke-dasharray: 520; stroke-dashoffset: 0;
  animation: draw 0.9s 0.3s ease-out backwards;
}
@keyframes draw { from { stroke-dashoffset: 520; } }

.facts { display: flex; flex-wrap: wrap; gap: 0.5rem 2.5rem; margin: 0; }
.facts div { display: grid; gap: 0.1rem; }
.facts dt { font-family: var(--font-label); font-size: 0.75rem; color: var(--ink-3); letter-spacing: 0.08em; }
.facts dd { margin: 0; font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.6rem; font-variant-numeric: tabular-nums; }
.facts dd small { font-family: var(--font-body); font-size: 0.85rem; color: var(--ink-2); margin-left: 0.2rem; }

/* セクション見出し */
.section { padding-block: clamp(2.5rem, 6vw, 4rem); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.section-head h2 { font-size: 1.5rem; }

/* 考え方の4ステップ（本当に順番があるので番号を付ける） */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border: 1px solid var(--rule); background: var(--surface); }
.steps li { padding: 1.25rem 1.25rem 1.4rem; display: grid; gap: 0.35rem; align-content: start; }
.steps li + li { border-left: 1px solid var(--rule); }
.steps .num { font-family: var(--font-label); font-size: 0.78rem; color: var(--ink-3); }
.steps strong { font-size: 1.05rem; }
.steps p { font-size: 0.9rem; color: var(--ink-2); line-height: 1.7; }
.steps li:nth-child(1) strong { color: var(--red); }
.steps li:nth-child(3) strong { color: var(--fix); }
@media (max-width: 760px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps li:nth-child(3) { border-left: 0; }
  .steps li:nth-child(n+3) { border-top: 1px solid var(--rule); }
}
@media (max-width: 420px) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .steps li + li { border-left: 0; border-top: 1px solid var(--rule); }
}

/* 分野フィルター */
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip {
  font: inherit; font-size: 0.85rem; line-height: 1;
  padding: 0.55rem 0.9rem; border: 1px solid var(--rule); border-radius: 999px;
  background: var(--surface); color: var(--ink-2); cursor: pointer;
}
.chip:hover { color: var(--ink); border-color: var(--ink-3); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .count { font-family: var(--font-label); font-size: 0.75rem; margin-left: 0.3rem; opacity: 0.7; }

/* 提言（パッチ）一覧 */
.patches { list-style: none; margin: 1.25rem 0 0; padding: 0; border-top: 1px solid var(--ink); }
.patch a, .patch .soon {
  display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) 7rem; gap: 1.5rem; align-items: start;
  padding: 1.4rem 0.75rem; border-bottom: 1px solid var(--rule); text-decoration: none;
  transition: background-color 0.15s;
}
.patch a:hover { background: var(--surface); }
.patch a:hover .patch-title { color: var(--red); }
.patch-id { display: grid; line-height: 1.1; }
.patch-id .label { font-size: 0.7rem; }
.patch-id b { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.9rem; font-variant-numeric: tabular-nums; }
.patch-body { display: grid; gap: 0.35rem; min-width: 0; }
.patch-title { font-size: 1.15rem; font-weight: 700; line-height: 1.5; transition: color 0.15s; }
.patch-desc { font-size: 0.92rem; color: var(--ink-2); line-height: 1.75; }
.patch-meta { text-align: right; display: grid; gap: 0.15rem; font-family: var(--font-label); font-size: 0.75rem; color: var(--ink-3); font-variant-numeric: tabular-nums; padding-top: 0.3rem; }
.tags { display: flex; gap: 0.4rem; flex-wrap: wrap; align-items: center; }
.tag { font-size: 0.75rem; line-height: 1; padding: 0.3rem 0.5rem; border: 1px solid var(--rule); color: var(--ink-2); background: var(--paper); }
.badge-new { font-family: var(--font-label); font-size: 0.7rem; font-weight: 700; line-height: 1; padding: 0.3rem 0.5rem; background: var(--red); color: var(--on-accent); letter-spacing: 0.08em; }
.patch .soon { color: var(--ink-3); border-bottom-style: dashed; }
.patch .soon .patch-id b { color: var(--ink-3); }
.patch[hidden] { display: none; }
@media (max-width: 640px) {
  .patch a, .patch .soon { grid-template-columns: minmax(0, 1fr); gap: 0.5rem; padding-inline: 0.25rem; }
  .patch-id { display: flex; align-items: baseline; gap: 0.5rem; }
  .patch-id b { font-size: 1.4rem; }
  .patch-meta { text-align: left; display: flex; gap: 1rem; padding-top: 0; }
}

/* フッター */
.site-footer { border-top: 1px solid var(--rule); margin-top: 3rem; }
.site-footer .wrap { padding-block: 2rem 2.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: 0.85rem; color: var(--ink-3); }
.site-footer a { color: var(--ink-2); }
/* reCAPTCHA の右下のマークは出さない（代わりにページの下にお知らせを出す。Google の決まりで認められている形） */
.grecaptcha-badge { visibility: hidden; }

/* ボタン */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font: inherit; font-size: 0.92rem; font-weight: 700; line-height: 1.2;
  padding: 0.8rem 1.15rem; border: 1px solid var(--ink); background: var(--ink); color: var(--paper);
  text-decoration: none; cursor: pointer; border-radius: 4px;
}
.btn:hover { background: var(--red); border-color: var(--red); color: var(--on-accent); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { border-color: var(--ink); background: var(--surface); color: var(--ink); }
.btn .label { color: inherit; opacity: 0.75; font-weight: 400; }

/* 提言ページ：冒頭 */
.doc-head { border-bottom: 1px solid var(--rule); }
.doc-head .wrap { padding-block: clamp(2rem, 6vw, 4rem) 2.25rem; display: grid; gap: 1.1rem; }
.crumbs { font-size: 0.85rem; color: var(--ink-3); display: flex; gap: 0.5rem; flex-wrap: wrap; }
.crumbs a { color: var(--ink-2); }
.doc-id { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.doc-id .num { font-family: var(--font-label); font-weight: 700; color: var(--red); letter-spacing: 0.1em; font-size: 0.9rem; }
.doc-head h1 { font-family: var(--font-display); font-weight: var(--display-weight); font-size: clamp(2.1rem, 6.5vw, 3.9rem); line-height: 1.25; }
.doc-head h1 em { font-style: normal; color: var(--red); }
.doc-formal { color: var(--ink-2); font-size: 1.05rem; max-width: 40em; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 0.25rem 1.5rem; font-family: var(--font-label); font-size: 0.8rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }

/* 要点 */
.summary { border: 1px solid var(--rule); background: var(--surface); padding: 1.25rem 1.5rem 1.4rem; display: grid; gap: 0.6rem; }
.summary h2 { font-size: 1rem; display: flex; align-items: baseline; gap: 0.6rem; }
.summary ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 0.5rem; }
.summary li { padding-left: 1.4rem; position: relative; line-height: 1.75; }
.summary li::before { content: ""; position: absolute; left: 0.2rem; top: 0.72em; width: 0.5rem; height: 0.5rem; background: var(--red); }

/* 現行 → 修正（このサイトだけの部品） */
.diff { display: grid; gap: 0.75rem; }
.diff h2 { font-size: 1rem; }
.diff-rows { display: grid; border: 1px solid var(--rule); background: var(--surface); }
.diff-row { display: grid; grid-template-columns: minmax(0, 1fr) 2rem minmax(0, 1fr); align-items: stretch; }
.diff-row + .diff-row { border-top: 1px solid var(--rule); }
.diff-cell { padding: 0.85rem 1rem; display: grid; gap: 0.2rem; line-height: 1.6; font-size: 0.95rem; }
.diff-cell .label { font-weight: 700; }
.diff-old { background: var(--red-tint); }
.diff-old .label { color: var(--red); }
.diff-new { background: var(--fix-tint); }
.diff-new .label { color: var(--fix); }
.diff-arrow { display: grid; place-items: center; color: var(--ink-3); font-family: var(--font-label); }
.diff-cell b { font-family: var(--font-label); font-variant-numeric: tabular-nums; }
.diff-note { font-size: 0.8rem; color: var(--ink-3); }
@media (max-width: 640px) {
  .diff-row { grid-template-columns: minmax(0, 1fr); }
  .diff-arrow { display: none; }
}

/* 提言ページ：本文レイアウト */
.doc-body .wrap { display: grid; grid-template-columns: 14rem minmax(0, var(--measure)); gap: clamp(2rem, 5vw, 4.5rem); padding-block: 2.5rem 1rem; justify-content: center; }
.toc { position: sticky; top: 5rem; align-self: start; font-size: 0.88rem; max-height: calc(100vh - 6rem); overflow-y: auto; }
.toc summary { list-style: none; cursor: default; margin-bottom: 0.75rem; }
.toc summary::-webkit-details-marker { display: none; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.1rem; border-left: 1px solid var(--rule); }
.toc a { display: block; padding: 0.35rem 0 0.35rem 0.9rem; margin-left: -1px; border-left: 2px solid transparent; color: var(--ink-2); text-decoration: none; line-height: 1.5; }
.toc a:hover { color: var(--ink); }
.toc a.active { color: var(--ink); border-left-color: var(--red); font-weight: 700; }
.doc-main { display: grid; gap: 2.5rem; min-width: 0; }
/* 中の横に長いもの（pre・表など）は、それぞれの中で横に流す。ページ全体を横にはみ出させない（2026-10-31） */
.doc-main > * { min-width: 0; }
@media (max-width: 900px) {
  .doc-body .wrap { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .toc { position: static; max-height: none; border: 1px solid var(--rule); background: var(--surface); padding: 0.9rem 1rem; }
  .toc summary { cursor: pointer; margin-bottom: 0; }
  .toc[open] summary { margin-bottom: 0.75rem; }
  .toc summary .label::after { content: " ＋"; }
  .toc[open] summary .label::after { content: " −"; }
}

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.slides { display: grid; gap: 0.6rem; }
.slides-frame { position: relative; aspect-ratio: 16 / 9; max-width: 100%; border: 1px solid var(--rule); background: var(--surface); }
.slides-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.slides-placeholder { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 0.4rem; color: var(--ink-3); font-size: 0.9rem; padding: 1rem; }

/* 本文 */
.prose { font-size: 1.0625rem; }
.prose > * + * { margin-top: 1.1rem; }
.prose hr { display: none; }
.prose h2 { font-size: 1.5rem; margin-top: 3.5rem; padding-top: 1.5rem; border-top: 1px solid var(--ink); scroll-margin-top: 5rem; }
.prose > h2:first-child, .prose > hr:first-child + h2 { margin-top: 0; }
.prose h3 { font-size: 1.15rem; margin-top: 2.25rem; scroll-margin-top: 5rem; }
.prose h4 { font-size: 1rem; margin-top: 1.5rem; }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li + li { margin-top: 0.45rem; }
.prose li::marker { color: var(--ink-3); }
.prose strong { font-weight: 700; background: linear-gradient(transparent 62%, var(--mark) 62%); }
.prose blockquote { margin: 1.25rem 0 0; padding: 0.25rem 0 0.25rem 1.1rem; border-left: 3px solid var(--red); color: var(--ink); }
.prose blockquote p + p { margin-top: 0.6rem; }
.prose .note { font-size: 0.88rem; color: var(--ink-3); line-height: 1.75; }
.table-wrap { overflow-x: auto; border: 1px solid var(--rule); background: var(--surface); }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.92rem; line-height: 1.6; font-variant-numeric: tabular-nums; }
.prose th, .prose td { padding: 0.65rem 0.9rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule); }
.prose th { font-size: 0.82rem; color: var(--ink-2); font-weight: 700; background: var(--paper); white-space: nowrap; }
.prose tbody tr:last-child td { border-bottom: 0; }
.prose td strong { background: none; }
.prose code { font-family: var(--font-label); }
.prose pre { overflow-x: auto; background: var(--surface); border: 1px solid var(--rule); padding: 1rem; font-family: var(--font-label); font-size: 0.85rem; line-height: 1.6; }

/* 意見・前後の提言 */
.feedback { border: 1px solid var(--rule); background: var(--surface); padding: 1.5rem; display: grid; gap: 1rem; }
.feedback h2 { font-size: 1.2rem; }
.feedback p { color: var(--ink-2); font-size: 0.95rem; }
.field { display: grid; gap: 0.35rem; }
.field label { font-size: 0.85rem; color: var(--ink-2); }
.field input, .field textarea {
  font: inherit; font-size: 1rem; color: var(--ink); background: var(--paper);
  border: 1px solid var(--rule); border-radius: 4px; padding: 0.7rem 0.8rem; width: 100%;
}
.field textarea { min-height: 7rem; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--fix); box-shadow: 0 0 0 3px var(--fix-tint); }
.pager { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.pager a, .pager span { display: grid; gap: 0.2rem; padding: 1rem 1.1rem; border: 1px solid var(--rule); text-decoration: none; min-width: 0; }
.pager a:hover { background: var(--surface); border-color: var(--ink-3); }
.pager .next { text-align: right; }
.pager span { color: var(--ink-3); border-style: dashed; }
.pager strong { font-size: 0.95rem; line-height: 1.5; }
@media (max-width: 520px) { .pager { grid-template-columns: minmax(0, 1fr); } .pager .next { text-align: left; } }

/* ---- 投票（開票速報） ----
   当選確実＝藍（修正案が通る）、差し戻し＝赤ペン、どうでもいい＝墨の薄色。はんこは赤 */
.ballot { border: 2px solid var(--ink); background: var(--surface); padding: 1.25rem 1.5rem 1.4rem; display: grid; gap: 1rem; overflow: hidden; }
.ballot-head { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem 1rem; flex-wrap: wrap; }
.ballot-head h2 { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.35rem; text-wrap: balance; }
.ballot-head b { font-family: var(--font-label); color: var(--ink); font-variant-numeric: tabular-nums; }
.ballot-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.6rem; }
.ballot-btn { font: inherit; cursor: pointer; display: grid; gap: 0.2rem; justify-items: center; padding: 0.9rem 0.5rem; border: 2px solid currentColor; background: var(--surface); text-align: center; transition: transform 0.12s ease, background-color 0.12s ease; }
.ballot-btn strong { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.15rem; line-height: 1.2; }
.ballot-btn span { font-size: 0.78rem; color: var(--ink-2); }
.ballot-btn.yes { color: var(--fix); }
.ballot-btn.no { color: var(--red); }
.ballot-btn.meh { color: var(--ink-3); }
.ballot-btn:hover:not(:disabled) { transform: translateY(-2px); }
.ballot-btn.yes:hover:not(:disabled), .ballot-btn.yes[aria-pressed="true"] { background: var(--fix-tint); }
.ballot-btn.no:hover:not(:disabled), .ballot-btn.no[aria-pressed="true"] { background: var(--red-tint); }
.ballot-btn.meh:hover:not(:disabled), .ballot-btn.meh[aria-pressed="true"] { background: var(--paper); }
.ballot-btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.ballot-btn:disabled { cursor: default; }
.ballot-btn:disabled:not([aria-pressed="true"]) { opacity: 0.45; }
.ballot-msg:empty { display: none; }
.ballot-msg { color: var(--red); font-size: 0.9rem; }
.ballot-result { position: relative; display: grid; gap: 0.7rem; border-top: 1px dashed var(--rule); padding-top: 1rem; }
.ballot-result-head { display: flex; justify-content: space-between; gap: 1rem; }
.ballot-result-head .label:first-child { color: var(--red); font-weight: 700; }
.ballot-bar { display: flex; height: 0.9rem; background: var(--paper); border: 1px solid var(--rule); }
.ballot-seg { display: block; height: 100%; width: 0; transition: width 0.6s ease; }
.ballot-seg.yes { background: var(--fix); }
.ballot-seg.no { background: var(--red); }
.ballot-seg.meh { background: var(--ink-3); opacity: 0.5; }
.ballot-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.3rem; }
.ballot-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 4.5rem; gap: 1rem; font-variant-numeric: tabular-nums; padding: 0.2rem 0.4rem; }
.ballot-row .n, .ballot-row .p { font-family: var(--font-label); text-align: right; }
.ballot-row .p { font-weight: 700; }
.ballot-row.yes .k { color: var(--fix); }
.ballot-row.no .k { color: var(--red); }
.ballot-row.meh .k { color: var(--ink-3); }
.ballot-row.mine { background: var(--paper); outline: 1px solid var(--rule); }
.ballot-row.mine .k::after { content: "← あなた"; margin-left: 0.5rem; font-size: 0.75rem; color: var(--ink-2); }
.ballot-you:empty { display: none; }
.ballot-you { font-size: 0.9rem; color: var(--ink-2); }
.ballot-note { font-size: 0.78rem; color: var(--ink-3); }
.ballot.contest { margin-top: 1.5rem; border-color: var(--fix); }
.c-tally span { white-space: nowrap; }
.c-tally .yes b { color: var(--fix); }
.c-tally .no b { color: var(--red); }
.c-tally b { font-family: var(--font-label); font-variant-numeric: tabular-nums; font-size: 1.15rem; }
.c-form { display: grid; gap: 0.7rem; }
.c-choices { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.c-count select { max-width: 8rem; }
.c-confirm { display: grid; gap: 0.7rem; border-top: 1px dashed var(--rule); padding-top: 1rem; }
.c-mine, .c-off { color: var(--ink-2); }
.contest-result { margin-bottom: 1.5rem; }
.contest-ranking { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.9rem; }
.contest-ranking li { display: grid; gap: 0.2rem; border-top: 1px dashed var(--rule); padding-top: 0.8rem; }
.contest-ranking .rank { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.2rem; color: var(--red); }
.contest-ranking a { font-weight: 700; color: var(--ink); }
.contest-ranking .by, .contest-ranking .pts { font-size: 0.88rem; color: var(--ink-2); }
.contest-ranking .prize { font-family: var(--font-label); font-weight: 700; }
/* はんこは開票速報の真ん中に。下の数字が読めるよう背景は透かす */
.ballot-stamp { position: absolute; left: 50%; top: 55%; margin: -2.6rem 0 0 -2.6rem; width: 5.2rem; height: 5.2rem; display: grid; place-items: center; text-align: center; border: 3px solid var(--red); border-radius: 50%; color: var(--red); font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.05rem; line-height: 1.1; padding: 0.3rem; transform: rotate(-14deg); opacity: 0.85; pointer-events: none; animation: stamp-in 0.35s ease-out; }
.ballot-stamp.yes { font-size: 1.6rem; }
@keyframes stamp-in { from { transform: rotate(-14deg) scale(1.8); opacity: 0; } }
@media (max-width: 560px) {
  .ballot { padding: 1rem; }
  .ballot-choices { grid-template-columns: minmax(0, 1fr); }
  .ballot-btn { grid-template-columns: auto 1fr; justify-items: start; align-items: baseline; gap: 0.75rem; padding: 0.75rem 1rem; text-align: left; }
  .ballot-stamp { margin: -2.2rem 0 0 -2.2rem; width: 4.4rem; height: 4.4rem; font-size: 0.9rem; }
  .ballot-stamp.yes { font-size: 1.35rem; }
}
@media (prefers-reduced-motion: reduce) {
  .ballot-btn, .ballot-seg { transition: none; }
  .ballot-stamp { animation: none; }
}

/* ---- 投稿まわり（投稿のしかた・投稿する・受け付けました・規約） ---- */
.wrap.narrow { max-width: 46rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.2rem; }
.steps.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.guide { display: grid; gap: 2rem; margin-block: 2.5rem; }
.guide section { display: grid; gap: 0.7rem; }
.guide h2 { font-size: 1.25rem; }
.guide p, .guide li { color: var(--ink-2); line-height: 1.8; }
.guide ol { margin: 0; padding-left: 1.4rem; }
.howto { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); gap: 0.6rem 1rem; margin: 0; }
.howto dt { font-weight: 700; }
.howto dd { margin: 0; color: var(--ink-2); line-height: 1.8; }

.form-card { border: 2px solid var(--ink); background: var(--surface); padding: 1.5rem; display: grid; gap: 1.1rem; }
.form-card h2 { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.35rem; }
.form-card fieldset { border: 0; border-top: 1px solid var(--rule); margin: 0; padding: 1.1rem 0 0; display: grid; gap: 0.8rem; min-width: 0; }
.form-card fieldset:first-of-type { border-top: 0; padding-top: 0; }
.form-card legend { font-weight: 700; font-size: 1.05rem; padding: 0; display: flex; gap: 0.5rem; align-items: baseline; }
.req, .opt { font-family: var(--font-label); font-size: 0.72rem; font-weight: 400; padding: 0.15rem 0.4rem; }
.req { color: var(--on-accent); background: var(--red); }
.opt { color: var(--ink-3); border: 1px solid var(--rule); }
.field { display: grid; gap: 0.35rem; min-width: 0; }
.field > span { font-size: 0.88rem; color: var(--ink-2); }
.field input[type="email"], .field input[type="text"], .field input[type="url"], .field input[type="date"], .field select {
  font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--rule); padding: 0.6rem 0.7rem; width: 100%; min-width: 0;
}
.field input[type="file"] { font: inherit; font-size: 0.9rem; color: var(--ink-2); max-width: 100%; }
.field input:focus-visible, .field select:focus-visible, .check input:focus-visible, .choices input:focus-visible { outline: 3px solid var(--fix); outline-offset: 1px; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.8rem 1rem; }
.choices { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; }
.choices label, .check { display: flex; gap: 0.55rem; align-items: baseline; line-height: 1.7; }
.check input, .choices input { accent-color: var(--fix); flex: none; }
.check a, .form-note a { color: var(--fix); }
.form-note { font-size: 0.85rem; color: var(--ink-3); line-height: 1.7; }
.form-msg { color: var(--red); font-size: 0.92rem; line-height: 1.7; }
.form-msg:empty { display: none; }
.form-msg.big { font-size: 1.05rem; color: var(--ink-2); }
.form-msg ul { margin: 0; padding-left: 1.2rem; }
.form-card .btn { justify-self: start; }
.preview { border: 1px dashed var(--fix); background: var(--paper); padding: 1rem 1.25rem; display: grid; gap: 0.6rem; max-height: 28rem; overflow: auto; }
.preview-title { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 1.3rem; }
@media (max-width: 720px) {
  .steps.three { grid-template-columns: minmax(0, 1fr); }
  .steps.three li + li { border-left: 0; border-top: 1px solid var(--rule); }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .howto { grid-template-columns: minmax(0, 1fr); }
  .howto dd { margin-bottom: 0.4rem; }
  .form-card { padding: 1.1rem; }
}

/* ---- 運営の審査画面（/admin） ---- */
.admin-bar { border-bottom: 1px solid var(--rule); background: var(--surface); }
.admin-bar .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; padding-block: 0.6rem; font-size: 0.88rem; }
.admin-me { margin-left: auto; color: var(--ink-2); overflow-wrap: anywhere; }
.btn.small { padding: 0.35rem 0.8rem; font-size: 0.85rem; }
.admin-h1 { font-family: var(--font-display); font-weight: var(--display-weight); font-size: clamp(1.4rem, 3.5vw, 2rem); line-height: 1.35; text-wrap: balance; }
.admin .chips { margin-block: 1rem; }
.admin-table { width: 100%; border-collapse: collapse; background: var(--surface); font-size: 0.9rem; }
.admin-table th, .admin-table td { text-align: left; padding: 0.65rem 0.75rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
.admin-table th { font-family: var(--font-label); font-size: 0.75rem; font-weight: 400; color: var(--ink-3); white-space: nowrap; }
.admin-table td a { color: var(--fix); font-weight: 700; }
.admin-table .tag { margin-left: 0.4rem; }
.admin-table .empty, .admin-notes .empty { color: var(--ink-3); }
.mono { font-family: var(--font-label); white-space: nowrap; }
.status { display: inline-block; font-size: 0.75rem; line-height: 1; padding: 0.3rem 0.5rem; border: 1px solid var(--rule); color: var(--ink-2); white-space: nowrap; }
.status.s-受付 { border-color: var(--red); color: var(--red); }
.status.s-審査中, .status.r-fix { border-color: var(--ink); color: var(--ink); }
.status.s-公開, .status.r-publish { border-color: var(--fix); color: var(--on-accent); background: var(--fix); }
.status.s-修正のお願い { border-color: var(--fix); color: var(--fix); }
.status.s-見送り, .status.r-reject { color: var(--ink-3); }
.admin-detail { display: grid; gap: 1.25rem; }
.admin-head { display: grid; gap: 0.6rem; }
.admin-head .tags { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.admin-head .form-note a { color: var(--fix); }
.admin-cols { display: grid; grid-template-columns: minmax(0, 1fr) 22rem; gap: 1.5rem; align-items: start; margin-top: 1.25rem; }
.admin-main, .admin-side { display: grid; gap: 1.25rem; min-width: 0; }
.admin-box { border: 1px solid var(--rule); background: var(--surface); padding: 1.1rem 1.25rem; display: grid; gap: 0.8rem; min-width: 0; }
.admin-box h2 { font-size: 1.05rem; display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: baseline; }
.admin-box .prose { max-width: var(--measure); }
.admin-form { display: grid; gap: 0.8rem; }
.admin-form .btn { justify-self: start; }
.admin-form select, .admin-form textarea { font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--rule); padding: 0.55rem 0.7rem; width: 100%; min-width: 0; }
.admin-form textarea { resize: vertical; }
.admin-media { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.5rem; }
.admin-media a { color: var(--fix); }
.admin-dl { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); gap: 0.4rem 0.8rem; margin: 0.7rem 0 0; font-size: 0.88rem; }
.admin-dl dt { color: var(--ink-3); }
.admin-dl dd { margin: 0; overflow-wrap: anywhere; }
.admin-notes, .admin-events { margin: 0; padding: 0; list-style: none; display: grid; gap: 0.8rem; }
.admin-notes li { display: grid; gap: 0.35rem; padding-bottom: 0.8rem; border-bottom: 1px dashed var(--rule); justify-items: start; }
.admin-notes p { white-space: pre-wrap; color: var(--ink-2); line-height: 1.7; font-size: 0.92rem; }
.note-head { display: flex; flex-wrap: wrap; gap: 0.3rem 0.6rem; align-items: baseline; font-size: 0.88rem; }
.admin-events li { font-size: 0.85rem; color: var(--ink-2); line-height: 1.6; }
@media (max-width: 960px) {
  .admin-cols { grid-template-columns: minmax(0, 1fr); }
}
#d-decision { font-size: 0.92rem; line-height: 1.7; overflow-wrap: anywhere; }
#d-decision a { color: var(--fix); }
.admin-nav { display: flex; gap: 1rem; }
.admin-nav a { color: var(--ink); }
.admin-actions { display: flex; gap: 0.4rem; justify-content: flex-end; white-space: nowrap; }

/* ---- PDF のスライド（提言ページ。動きは site/slides.js） ---- */
.viewer-bar { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; flex-wrap: wrap; }
.viewer-counter { font-family: var(--font-label); font-size: 0.85rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
/* 縦長の PDF でも画面からはみ出さないよう、幅を「画面の高さの8割 × 縦横比」までにする（--ar は slides.js が入れる） */
.viewer-stage { position: relative; aspect-ratio: 16 / 9; margin-inline: auto; width: min(100%, calc(80vh * var(--ar, 1.7778))); background: var(--surface); border: 1px solid var(--rule); overflow: hidden; touch-action: pan-y; }
.viewer-stage:focus-visible { outline: 3px solid var(--fix); outline-offset: 2px; }
.viewer-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.viewer-stage .slides-placeholder { position: absolute; inset: 0; }
.viewer-loading { position: absolute; inset: 0; display: grid; place-items: center; padding: 1rem; text-align: center; color: var(--ink-3); font-size: 0.9rem; }
.viewer-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 2.75rem; height: 2.75rem; border-radius: 999px; border: 1px solid var(--rule); background: var(--surface); color: var(--ink); font: inherit; font-size: 1.1rem; cursor: pointer; display: grid; place-items: center; opacity: 0.92; }
.viewer-nav:hover { border-color: var(--ink); }
.viewer-nav:disabled { opacity: 0.3; cursor: default; }
.viewer-nav.prev { left: 0.6rem; }
/* 全画面（動きは slides.js）。右上のボタン。全画面のときは黒地に、ページの縦横比のまま画面に収める */
.viewer-full { position: absolute; top: 0.5rem; right: 0.5rem; z-index: 2; border: 1px solid var(--rule); background: var(--surface); color: var(--ink); font: inherit; font-family: var(--font-label); font-size: 0.78rem; padding: 0.3rem 0.65rem; border-radius: 999px; cursor: pointer; opacity: 0.92; }
.viewer-full:hover { border-color: var(--ink); }
.viewer-stage:fullscreen, .viewer-stage.is-full { width: 100%; height: 100%; max-width: none; aspect-ratio: auto; border: 0; background: #000; }
.viewer-stage.is-full { position: fixed; inset: 0; z-index: 1000; height: 100dvh; }
.viewer-stage:fullscreen canvas, .viewer-stage.is-full canvas { object-fit: contain; }
html.viewer-locked, html.viewer-locked body { overflow: hidden; }
.viewer-nav.next { right: 0.6rem; }
.viewer-thumbs { display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.35rem; scroll-snap-type: x proximity; }
.viewer-thumbs:empty { display: none; }
.viewer-thumb { flex: 0 0 auto; height: 4.25rem; width: auto; aspect-ratio: 16 / 9; border: 2px solid transparent; outline: 1px solid var(--rule); background: var(--surface); padding: 0; cursor: pointer; scroll-snap-align: start; position: relative; }
.viewer-thumb canvas { width: 100%; height: 100%; display: block; }
.viewer-thumb span { position: absolute; left: 0.25rem; bottom: 0.2rem; font-family: var(--font-label); font-size: 0.65rem; color: var(--ink-3); background: var(--surface); padding: 0 0.2rem; }
.viewer-thumb[aria-current="true"] { border-color: var(--red); outline-color: var(--red); }
@media (max-width: 600px) {
  .viewer-nav { width: 2.2rem; height: 2.2rem; font-size: 0.95rem; }
  .viewer-nav.prev { left: 0.3rem; }
  .viewer-nav.next { right: 0.3rem; }
}

/* ---- 意見欄（提言ページ。動きは site/comments.js） ---- */
.comments-head { display: flex; align-items: baseline; justify-content: space-between; gap: 0.5rem 1rem; flex-wrap: wrap; }
.comment-list { list-style: none; margin: 0; padding: 0; display: grid; }
.comment-list:empty { display: none; }
.comment { display: grid; gap: 0.4rem; padding-block: 0.9rem; border-top: 1px dashed var(--rule); }
.comment:first-child { border-top: 0; padding-top: 0; }
.comment-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.3rem 0.8rem; font-size: 0.85rem; color: var(--ink-3); }
.comment-meta b { color: var(--ink); font-size: 0.92rem; }
.comment-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.8; color: var(--ink); }
.comment-report { margin-left: auto; font: inherit; font-size: 0.78rem; color: var(--ink-3); background: none; border: 0; padding: 0.2rem 0; cursor: pointer; text-decoration: underline; }
.comment-report:disabled { text-decoration: none; cursor: default; }
.comment.mine { background: var(--fix-tint); margin-inline: -0.6rem; padding-inline: 0.6rem; }
.comment-form { display: grid; gap: 0.8rem; border-top: 1px solid var(--rule); padding-top: 1.1rem; }
.comment-form h3 { font-size: 1.05rem; }
.comment-form .btn { justify-self: start; }
.comment-form .field textarea { font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--rule); padding: 0.6rem 0.7rem; width: 100%; resize: vertical; }
.comment-form .form-msg.ok { color: var(--fix); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.nav-count:not(:empty) { margin-left: 0.3rem; font-size: 0.72rem; color: var(--on-accent); background: var(--red); border-radius: 999px; padding: 0.05rem 0.4rem; }
.admin-toggle { margin-block: 0.5rem; }
.admin-comments { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.admin-comments .empty { color: var(--ink-3); }
.admin-comments .comment-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.8; }
.admin-comments a { color: var(--fix); }
.admin-actions.start { justify-content: flex-start; }

/* ---- 本人確認済みの印・マイページ ---- */
.verified { display: inline-block; margin-left: 0.4rem; font-size: 0.72rem; line-height: 1; padding: 0.25rem 0.45rem; color: var(--on-accent); background: var(--fix); vertical-align: 0.1em; }
.verified::before { content: "✓ "; }
.account-steps { display: grid; gap: 1.5rem; }
.account .form-card + .form-card { margin-top: 1.25rem; }
.qr svg { width: 12rem; height: 12rem; background: #fff; }
.account code { font-family: var(--font-label); overflow-wrap: anywhere; }
.admin-fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 0.5rem; min-width: 0; }
.admin-fieldset legend { font-size: 0.88rem; color: var(--ink-2); padding: 0; margin-bottom: 0.4rem; }
.admin-events .btn { margin-left: 0.4rem; }
#u-page { display: grid; gap: 1.25rem; }
.form-msg.ok { color: var(--fix); }

/* ---- キャラクター（03_制作：ペー＝赤ペン係、ニー＝ツッコミ係。絵は site/img/characters/） ---- */
.chara { display: block; height: auto; object-fit: contain; user-select: none; }
.hero .wrap { position: relative; }
.hero-chara { margin: 0; position: absolute; right: max(16px, calc((100% - var(--wide)) / 2)); bottom: clamp(2rem, 5vw, 3.5rem); width: clamp(9rem, 20vw, 15rem); display: grid; justify-items: center; gap: 0.3rem; }
.hero-chara figcaption, .diff-cast figcaption { font-family: var(--font-label); font-size: 0.8rem; color: var(--ink-2); background: var(--surface); border: 1px solid var(--rule); border-radius: 999px; padding: 0.2rem 0.7rem; white-space: nowrap; }
.hero-chara .chara { width: 100%; animation: chara-bob 3.2s ease-in-out infinite; }
@keyframes chara-bob { 50% { transform: translateY(-6px) rotate(-1.5deg); } }
.step-chara { width: 4.5rem; margin-bottom: 0.4rem; }
.diff-cast { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 0.4rem; }
.diff-cast figure { margin: 0; display: flex; align-items: center; gap: 0.5rem; }
.diff-cast figure:last-child { justify-content: flex-end; flex-direction: row-reverse; }
.diff-cast .chara { width: 4.2rem; }
/* スマートフォンでは、吹き出しの言葉を折り返す（折り返さないと、画面の横にはみ出す。2026-10-31） */
.diff-cast { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.diff-cast figure { min-width: 0; }
@media (max-width: 600px) {
  .diff-cast .chara { width: 3.2rem; flex: 0 0 auto; }
  .diff-cast figcaption { white-space: normal; border-radius: 0.8rem; }
}
.doc-head .wrap { position: relative; }
.side-chara { margin: 0; position: absolute; right: max(16px, calc((100% - var(--wide)) / 2)); bottom: 1.5rem; width: clamp(8rem, 16vw, 11rem); }
.side-chara.pair { display: flex; gap: 0.5rem; width: auto; }
.side-chara.pair .chara { width: clamp(6rem, 14vw, 9rem); }
.side-chara .chara { width: 100%; }
.ballot-chara { width: 7rem; justify-self: center; animation: chara-pop 0.35s ease-out; }
@keyframes chara-pop { from { transform: scale(0.6); opacity: 0; } }
.note-chara { display: inline-block; width: 2.6rem; vertical-align: middle; margin-right: 0.4rem; }
.comments-empty { display: flex; align-items: center; gap: 0.8rem; }
.comments-empty[hidden] { display: none; }
.empty-chara { display: inline-block; width: 4rem; vertical-align: middle; margin-right: 0.6rem; }
.loading-chara { width: 5rem; margin-inline: auto; }
.viewer-loading { gap: 0.4rem; align-content: center; }
.footer-chara { width: 5.5rem; }
.site-footer small { color: var(--ink-3); }
@media (max-width: 900px) {
  .hero-chara { position: static; justify-self: end; margin-top: -1rem; width: 8.5rem; }
  .side-chara { position: static; justify-self: end; width: 7.5rem; }
  .side-chara.pair .chara { width: 6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-chara .chara, .ballot-chara { animation: none; }
}

/* ---- 提言ページの「問題を報告」（site/report.js） ---- */
.report { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1rem; border-top: 1px dashed var(--rule); padding-top: 1.25rem; }
.report > p { flex: 1 1 18rem; margin: 0; color: var(--ink-3); font-size: 0.88rem; }
.report-dialog { width: min(34rem, calc(100vw - 2rem)); max-height: calc(100dvh - 2rem); overflow: auto; border: 1px solid var(--rule); background: var(--surface); color: var(--ink); padding: 1.5rem; }
.report-dialog::backdrop { background: rgb(0 0 0 / 0.45); }
.report-form { display: grid; gap: 1rem; }
.report-form h2 { font-size: 1.15rem; display: flex; gap: 0.6rem; align-items: baseline; }
.report-form fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 0.35rem; }
.report-form legend { font-weight: 700; margin-bottom: 0.4rem; }
.report-form .actions { margin: 0; }
.slides-stopped { border: 1px dashed var(--rule); padding: 1rem 1.25rem; }
.slides-stopped .form-note { margin: 0; }
.contest-review { display: grid; gap: 0.8rem; }
.contest-review td:first-child, .contest-review td:nth-child(5), .contest-review .btn { white-space: nowrap; }
#prizes .pre { white-space: pre-line; }
#prizes .btn, #prizes td:nth-child(3) { white-space: nowrap; }
.party-replies { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.6rem; }
.party-replies li { border-top: 1px dashed var(--rule); padding-top: 0.6rem; }
.party-head { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.party-head .state.yes { color: var(--fix); font-weight: 700; }
.party-reply { white-space: pre-wrap; overflow-wrap: anywhere; background: var(--paper); border: 1px solid var(--rule); padding: 0.8rem 1rem; margin-top: 0.5rem; font-size: 0.92rem; }
.mail-preview { white-space: pre-wrap; font-size: 0.85rem; background: var(--paper); border: 1px solid var(--rule); padding: 0.8rem; max-height: 24rem; overflow: auto; }
#parties input { width: 100%; min-width: 10rem; }
#sendings textarea { width: 100%; min-width: 14rem; }
#sendings td:nth-child(-n+2) { white-space: nowrap; }
.admin-table td.warn { color: var(--red, #c0392b); font-weight: 700; }
/* 上のナビのログインの状態（functions/pages.js の head） */
.main-nav .session { display: inline-flex; align-items: baseline; gap: 0.35em; max-width: 14em; }
.main-nav .session b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.main-nav .session .session-label { font-size: 0.75rem; color: var(--ink-2); }
.main-nav .session.on { color: var(--ink); }
@media (max-width: 520px) { .main-nav { gap: 0.8rem; } .main-nav .session .session-label { display: none; } .main-nav .session { max-width: 7em; } }
/* スマートフォン：メニューの言葉を途中で折り返さない（「トッ／プ」にならないように）。入りきらないときは、ログイン中の名前を「…」で縮める（2026-10-31） */
.main-nav { min-width: 0; }
.main-nav a { white-space: nowrap; flex: 0 0 auto; }
.main-nav .session { flex: 0 1 auto; min-width: 4.5em; }
@media (max-width: 420px) {
  .site-header .wrap { gap: 0.6rem; }
  .logo { font-size: 0.95rem; letter-spacing: 0.02em; }
  .main-nav { gap: 0.6rem; font-size: 0.82rem; }
  /* 狭い画面では「トップ」を出さない（左の REBOOT JAPAN がトップへのリンク） */
  .main-nav .nav-top { display: none; }
}
@media (max-width: 360px) {
  .logo { font-size: 0.88rem; }
  .main-nav { gap: 0.5rem; }
}
