/* AVOSIST — 禁欲的写経シート風スタイル */

:root {
  --paper: #f4f1ea;
  --paper-edge: #e9e4d8;
  --ink: #1a1714;
  --ink-soft: #5c554c;
  --seal: #8a2f24;
  --avo: #5a6b32;
  --rule: #cabfa6;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--paper);
  background-image: radial-gradient(transparent 0, transparent 22px, rgba(0, 0, 0, 0.012) 23px);
  background-size: 24px 24px;
  color: var(--ink);
  font-family: "Hiragino Mincho ProN", "Yu Mincho", "YuMincho", "Noto Serif JP", serif;
  font-size: 17px;
  line-height: 2;
  letter-spacing: 0.04em;
  -webkit-font-smoothing: antialiased;
}

.sheet {
  max-width: 680px;
  margin: 0 auto;
  padding: 32px 28px 96px;
}

/* ── 銘 / ロゴ ── */
.seal {
  display: inline-block;
  border: 1.5px solid var(--seal);
  color: var(--seal);
  font-size: 13px;
  letter-spacing: 0.5em;
  padding: 6px 4px 6px 12px;
  border-radius: 3px;
  margin-bottom: 40px;
}

/* ── 見出し ── */
.brand {
  font-size: clamp(44px, 12vw, 88px);
  letter-spacing: 0.18em;
  margin: 0 0 8px;
  font-weight: 600;
}

.brand .reading {
  display: block;
  font-size: 15px;
  letter-spacing: 0.5em;
  color: var(--ink-soft);
  margin-bottom: 18px;
}

.creed-lead {
  font-size: 19px;
  color: var(--ink-soft);
  margin: 0 0 8px;
}

.expand {
  color: var(--avo);
  letter-spacing: 0.1em;
  font-size: 15px;
  margin: 0 0 48px;
}

/* ── 区切り ── */
.rule {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 48px 0;
}

.rule.short {
  width: 64px;
  margin-left: 0;
}

/* ── 本日の戒め ── */
.today {
  border: 1px solid var(--rule);
  background: rgba(255, 255, 255, 0.4);
  padding: 32px 28px;
  text-align: center;
  margin: 8px 0 48px;
}

.today .label {
  font-size: 13px;
  letter-spacing: 0.4em;
  color: var(--ink-soft);
  margin: 0 0 14px;
}

.today .verdict {
  font-size: clamp(26px, 7vw, 38px);
  margin: 0 0 10px;
  letter-spacing: 0.08em;
}

.today .verdict.abstain { color: var(--ink); }
.today .verdict.release { color: var(--seal); }

.today .detail {
  font-size: 15px;
  color: var(--ink-soft);
  margin: 0;
}

/* ── 戒律リスト ── */
.section-title {
  font-size: 22px;
  letter-spacing: 0.2em;
  margin: 0 0 24px;
}

.precepts {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: precept;
}

.precepts li {
  counter-increment: precept;
  padding: 14px 0 14px 56px;
  position: relative;
  border-bottom: 1px dotted var(--rule);
}

.precepts li::before {
  content: attr(data-label);
  position: absolute;
  left: 0;
  top: 14px;
  color: var(--seal);
  font-size: 14px;
  letter-spacing: 0.1em;
}

/* ── 本文 ── */
.prose p {
  margin: 0 0 24px;
}

.prose .em {
  font-weight: 600;
  border-bottom: 2px solid var(--avo);
}

/* ── アヴォシストの声（フィード） ── */
.feed-form {
  margin: 0 0 28px;
}

.feed-input {
  width: 100%;
  box-sizing: border-box;
  font-family: inherit;
  font-size: 16px;
  padding: 12px 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid var(--rule);
  border-radius: 4px;
}

.feed-input:focus {
  outline: none;
  border-color: var(--avo);
}

.feed-form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.feed-count {
  font-size: 12px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.feed-submit {
  font-family: inherit;
  font-size: 14px;
  letter-spacing: 0.1em;
  padding: 8px 22px;
  cursor: pointer;
  color: var(--paper);
  background: var(--ink);
  border: none;
  border-radius: 4px;
  transition: background 0.2s;
}

.feed-submit:hover {
  background: var(--avo);
}

.feed-error {
  min-height: 1.2em;
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--seal);
}

.feed-list {
  display: flex;
  flex-direction: column;
}

.feed-item {
  padding: 14px 0;
  border-bottom: 1px dotted var(--rule);
}

.feed-item:last-child {
  border-bottom: none;
}

.feed-item-head {
  display: flex;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 4px;
}

.feed-flag {
  font-size: 18px;
}

.feed-time {
  font-size: 11px;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.feed-text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  word-break: break-word;
}

.feed-empty {
  text-align: center;
  font-size: 14px;
  color: var(--ink-soft);
  padding: 20px 0;
}

/* 日曜：フィードもネオン化 */
html.is-sunday .feed-input {
  color: #fff;
  background: rgba(0, 0, 0, 0.35);
  border-color: #ff2bd6;
}
html.is-sunday .feed-submit {
  background: #ff007a;
  color: #ffe600;
}
html.is-sunday .feed-submit:hover {
  background: #ff2bd6;
}
html.is-sunday .feed-count,
html.is-sunday .feed-time {
  color: #c9a8ff;
}
html.is-sunday .feed-item {
  border-bottom-color: rgba(255, 255, 255, 0.25);
}
html.is-sunday .feed-text {
  color: #fff;
}
html.is-sunday .feed-empty {
  color: #c9a8ff;
}

/* ── 言語別カウンター内訳（4段） ── */
.lang-breakdown {
  margin: 14px auto 0;
  max-width: 280px;
  text-align: left;
  font-variant-numeric: tabular-nums;
}

.lb-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 5px 0;
  border-bottom: 1px dotted var(--rule);
}

.lb-row:last-child {
  border-bottom: none;
}

.lb-name {
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
}

.lb-num {
  margin-left: auto;
  font-size: 22px;
  letter-spacing: 0.04em;
  color: var(--ink);
}

.lb-unit {
  font-size: 11px;
  color: var(--ink-soft);
}
.lb-pct {
  font-size: 11px;
  color: var(--seal);
  min-width: 3.2em;
  text-align: right;
}
.lb-note {
  font-size: 10px;
  color: var(--ink-soft);
  text-align: right;
  margin: 6px auto 0;
  max-width: 280px;
}

html.is-sunday .lb-row {
  border-bottom-color: rgba(255, 255, 255, 0.25);
}
html.is-sunday .lb-name,
html.is-sunday .lb-unit,
html.is-sunday .lb-note {
  color: #c9a8ff;
}
html.is-sunday .lb-pct {
  color: #ff2bd6;
}

html.is-sunday .lb-num {
  color: #ffe600;
  text-shadow: 1px 1px 0 #ff007a;
}

/* ── 学術的小ネタ（脚注風） ── */
.avnote {
  font-size: 12px;
  line-height: 1.9;
  color: var(--ink-soft);
  border-left: 2px solid var(--rule);
  padding-left: 14px;
  margin: 8px 0 0;
}

html.is-sunday .avnote {
  color: #c9a8ff;
  border-left-color: #ff2bd6;
}

/* ── お知らせ：作品一覧 ── */
.works {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.work {
  padding: 22px 0;
  border-bottom: 1px dotted var(--rule);
}

.work:last-child {
  border-bottom: none;
}

.work-cat {
  font-size: 12px;
  letter-spacing: 0.25em;
  color: var(--seal);
  margin: 0 0 6px;
}

.work-title {
  font-size: 22px;
  letter-spacing: 0.06em;
  margin: 0 0 10px;
  font-weight: 600;
}

.work-desc {
  font-size: 15px;
  color: var(--ink-soft);
  margin: 0 0 14px;
}

.work-link {
  display: inline-block;
  font-size: 14px;
  letter-spacing: 0.1em;
  color: var(--avo);
  text-decoration: none;
  border-bottom: 1px solid var(--avo);
  padding-bottom: 2px;
}

.work-link:hover {
  color: var(--seal);
  border-bottom-color: var(--seal);
}

.news-disclaim {
  font-size: 12px;
  color: var(--ink-soft);
  margin: 32px 0 0;
  line-height: 1.9;
}

/* 日曜：作品一覧もネオン化 */
html.is-sunday .work {
  border-bottom-color: rgba(255, 255, 255, 0.25);
}
html.is-sunday .work-cat {
  color: #ffe600;
}
html.is-sunday .work-title {
  color: #fff;
}
html.is-sunday .work-desc,
html.is-sunday .news-disclaim {
  color: #c9a8ff;
}
html.is-sunday .work-link {
  color: #00ff8c;
  border-bottom-color: #00ff8c;
}
html.is-sunday .work-link:hover {
  color: #ffe600;
  border-bottom-color: #ffe600;
}

/* ── FAQ ── */
.faq dt {
  font-weight: 600;
  margin: 28px 0 6px;
}

.faq dt::before {
  content: "問　";
  color: var(--avo);
}

.faq dd {
  margin: 0;
  color: var(--ink-soft);
}

.faq dd::before {
  content: "答　";
  color: var(--seal);
}

/* ── 入信ページ：誓いとカウンター ── */
.join-wrap {
  text-align: center;
  margin: 8px 0 0;
}

.vow-button {
  font-family: inherit;
  font-size: 19px;
  letter-spacing: 0.18em;
  color: var(--paper);
  background: var(--ink);
  border: none;
  padding: 18px 40px;
  cursor: pointer;
  border-radius: 3px;
  transition: background 0.2s, transform 0.1s;
}

.vow-button:hover {
  background: var(--seal);
}

.vow-button:active {
  transform: translateY(1px);
}

.vow-button.joined,
.vow-button:disabled {
  background: var(--paper-edge);
  color: var(--ink-soft);
  border: 1px solid var(--rule);
  cursor: default;
  font-size: 15px;
  letter-spacing: 0.1em;
}

.vow-note {
  font-size: 13px;
  color: var(--ink-soft);
  margin: 18px 0 0;
}

.counter {
  margin: 56px 0 0;
  padding-top: 40px;
  border-top: 1px solid var(--rule);
}

.counter-label {
  font-size: 13px;
  letter-spacing: 0.4em;
  color: var(--ink-soft);
  margin: 0 0 8px;
}

.counter-num {
  margin: 0;
  font-size: clamp(40px, 11vw, 64px);
  letter-spacing: 0.06em;
  color: var(--seal);
  font-variant-numeric: tabular-nums;
}

.counter-unit {
  font-size: 18px;
  letter-spacing: 0.2em;
  color: var(--ink-soft);
  margin-left: 10px;
}

/* ── 教祖ページ：Hero（創世記のもじり） ── */
.gospel {
  text-align: center;
  margin: 16px 0 8px;
}

.gospel-line {
  font-size: clamp(20px, 5vw, 30px);
  line-height: 1.9;
  letter-spacing: 0.08em;
  margin: 0;
  color: var(--ink);
}

.gospel-line--accent {
  color: var(--seal);
}

.gospel-div {
  margin: 28px auto;
}

/* ── 教祖紹介 ── */
.founder {
  text-align: center;
}

.portrait {
  width: 132px;
  height: 132px;
  margin: 0 auto 24px;
  border-radius: 50%;
  border: 1px solid var(--rule);
  background:
    repeating-linear-gradient(
      45deg,
      rgba(0, 0, 0, 0.03) 0,
      rgba(0, 0, 0, 0.03) 6px,
      transparent 6px,
      transparent 12px
    ),
    var(--paper-edge);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.portrait-mark {
  font-size: 40px;
  color: var(--ink-soft);
  letter-spacing: 0;
}

.portrait-cap {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--ink-soft);
}

.founder-name {
  font-size: clamp(34px, 10vw, 56px);
  letter-spacing: 0.2em;
  margin: 0;
  font-weight: 600;
}

.founder-reading {
  font-size: 14px;
  letter-spacing: 0.4em;
  color: var(--ink-soft);
  margin: 8px 0 32px;
}

.founder-meta {
  max-width: 420px;
  margin: 0 auto;
  text-align: left;
}

.founder-meta > div {
  display: flex;
  gap: 20px;
  padding: 12px 0;
  border-bottom: 1px dotted var(--rule);
}

.founder-meta dt {
  flex: 0 0 88px;
  color: var(--seal);
  font-size: 14px;
  letter-spacing: 0.2em;
  margin: 0;
}

.founder-meta dd {
  margin: 0;
  letter-spacing: 0.06em;
}

/* ── 解禁までのカウントダウン ── */
.countdown {
  text-align: center;
  margin: 0 0 8px;
}

.countdown-label {
  font-size: 13px;
  letter-spacing: 0.4em;
  color: var(--ink-soft);
  margin: 0 0 12px;
}

.countdown-clock {
  margin: 0;
  display: flex;
  justify-content: center;
  gap: 20px;
}

.cd-unit {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  font-variant-numeric: tabular-nums;
}

.cd-unit > span:first-child {
  font-size: clamp(34px, 9vw, 48px);
  letter-spacing: 0.04em;
  color: var(--seal);
}

.cd-cap {
  font-size: 14px;
  color: var(--ink-soft);
}

/* 日曜：解禁中はネオン配色に */
html.is-sunday .countdown-label,
html.is-sunday .cd-cap {
  color: #c9a8ff;
}

html.is-sunday .cd-unit > span:first-child {
  color: #ffe600;
  text-shadow: 2px 2px 0 #ff007a;
}

/* ── 自省ページ：守れた／破れたり ── */
.reflect-msg {
  text-align: center;
  min-height: 2em;
  margin: 0 0 24px;
  font-size: 17px;
  color: var(--ink-soft);
}

.reflect-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.reflect-col {
  text-align: center;
}

.reflect-btn {
  width: 100%;
  font-family: inherit;
  font-size: 22px;
  letter-spacing: 0.18em;
  color: var(--paper);
  border: none;
  padding: 28px 12px;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.2s, transform 0.1s, opacity 0.2s;
}

.reflect-btn.good { background: var(--avo); }
.reflect-btn.bad  { background: var(--seal); }

.reflect-btn:hover { transform: translateY(-2px); }
.reflect-btn:active { transform: translateY(0); }

.reflect-btn:disabled {
  cursor: default;
  transform: none;
  opacity: 0.4;
}

.reflect-btn.chosen {
  opacity: 1;
  box-shadow: 0 0 0 3px var(--paper), 0 0 0 5px currentColor;
}

.reflect-count {
  margin: 22px 0 0;
}

.reflect-count-label {
  font-size: 12px;
  letter-spacing: 0.25em;
  color: var(--ink-soft);
  margin: 0 0 6px;
}

.reflect-count-num {
  margin: 0;
  font-size: clamp(34px, 9vw, 48px);
  letter-spacing: 0.06em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.reflect-count-unit {
  font-size: 15px;
  letter-spacing: 0.2em;
  color: var(--ink-soft);
  margin-left: 8px;
}

.reflect-note {
  text-align: center;
  font-size: 13px;
  color: var(--ink-soft);
  margin: 40px 0 0;
}

/* ── 曜日による表示切替（月〜土／日） ── */
.weekday-view,
.sunday-view {
  display: none;
}

html.is-weekday .weekday-view {
  display: block;
}

html.is-sunday .sunday-view {
  display: block;
}

/* 自省ページの見出し切替（平日は厳格／日曜は解禁ヘッダ＋大量リンク） */
.sunday-head {
  display: none;
}

html.is-sunday .sunday-head {
  display: block;
}

html.is-sunday .weekday-head {
  display: none;
}

/* 汎用：日曜だけ／平日だけ表示する要素（JS無効時は平日版を表示） */
.sunday-only {
  display: none;
}

html.is-sunday .sunday-only {
  display: revert;
}

html.is-sunday .weekday-only {
  display: none;
}

/* 日曜の自省欄の問いかけ（下品ネオン） */
.reflect-lead-sun {
  text-align: center;
  font-size: clamp(24px, 7vw, 42px);
  font-weight: 900;
  font-style: italic;
  color: #ff2bd6;
  text-shadow: 2px 2px 0 #ffe600;
  margin: 8px 0 4px;
  animation: blink 0.9s steps(2, start) infinite;
}

/* JSが無効でも最低限フォールバック（厳格版を表示） */
html:not(.is-sunday):not(.is-weekday) .weekday-view {
  display: block;
}

/* ── 日曜：解禁ページ（下品モード） ── */
html.is-sunday body {
  background: #1a0030;
  color: #fff;
  font-family: "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  animation: sun-bg 6s linear infinite;
}

@keyframes sun-bg {
  0%   { background: #1a0030; }
  25%  { background: #3a0030; }
  50%  { background: #00203a; }
  75%  { background: #3a2000; }
  100% { background: #1a0030; }
}

.sun-marquee {
  overflow: hidden;
  white-space: nowrap;
  border-top: 3px solid #ff2bd6;
  border-bottom: 3px solid #ffe600;
  background: #000;
  margin: 0 0 28px;
  padding: 8px 0;
}

/* 全ページ差し込み版は最上部いっぱいに */
.sun-marquee.site {
  margin: 0 0 24px;
}

.sun-marquee span {
  display: inline-block;
  padding-left: 100%;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #ffe600;
  animation: marquee 14s linear infinite;
}

@keyframes marquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

.sun-title {
  text-align: center;
  font-size: clamp(48px, 16vw, 110px);
  line-height: 1.05;
  margin: 10px 0 16px;
  font-weight: 900;
  font-style: italic;
  color: #ff2bd6;
  text-shadow: 3px 3px 0 #ffe600, 6px 6px 0 #00e0ff;
  animation: shake 0.35s ease-in-out infinite;
}

@keyframes shake {
  0%, 100% { transform: rotate(-1.5deg); }
  50%      { transform: rotate(1.5deg); }
}

.sun-sub {
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: #00ff8c;
  margin: 0 0 32px;
  animation: blink 0.9s steps(2, start) infinite;
}

@keyframes blink {
  50% { opacity: 0.25; }
}

.banner-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.banner {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 84px;
  padding: 12px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 800;
  font-size: 15px;
  line-height: 1.4;
  color: #fff;
  border: 3px solid #fff;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.5);
  transition: transform 0.12s;
}

.banner:hover {
  transform: scale(1.04) rotate(-1deg);
  z-index: 1;
}

.banner:nth-child(6n+1) { background: linear-gradient(135deg, #ff007a, #ff8a00); }
.banner:nth-child(6n+2) { background: linear-gradient(135deg, #7a00ff, #00d0ff); }
.banner:nth-child(6n+3) { background: linear-gradient(135deg, #ff2bd6, #ffe600); color: #000; text-shadow: none; }
.banner:nth-child(6n+4) { background: linear-gradient(135deg, #00b050, #b6ff00); color: #000; text-shadow: none; }
.banner:nth-child(6n+5) { background: linear-gradient(135deg, #ff0000, #ff00a8); }
.banner:nth-child(6n+6) { background: linear-gradient(135deg, #0050ff, #00ffd0); }

.sun-foot {
  text-align: center;
  font-size: 13px;
  line-height: 2;
  color: #c9a8ff;
  margin: 36px 0 0;
}

/* ── 日曜：全ページ解禁ムード（main以外の通常ページにも適用） ── */
html.is-sunday .seal {
  border-color: #ffe600;
  background: #ff007a;
  color: #ffe600;
  animation: blink 0.9s steps(2, start) infinite;
}

html.is-sunday .brand,
html.is-sunday .founder-name {
  color: #ff2bd6;
  font-style: italic;
  font-weight: 900;
  text-shadow: 2px 2px 0 #ffe600, 4px 4px 0 #00e0ff;
  animation: shake 0.4s ease-in-out infinite;
}

html.is-sunday .brand .reading,
html.is-sunday .founder-reading {
  color: #00ff8c;
  -webkit-text-fill-color: #00ff8c;
}

html.is-sunday .creed-lead,
html.is-sunday .expand,
html.is-sunday .gospel-line,
html.is-sunday .reflect-msg {
  color: #00ff8c;
}

html.is-sunday .gospel-line--accent {
  color: #ff2bd6;
}

html.is-sunday .section-title {
  color: #ffe600;
  text-shadow: 2px 2px 0 #ff007a;
}

html.is-sunday .rule {
  border-top-color: #ff2bd6;
}

html.is-sunday .nav a {
  color: #ffe600;
}

html.is-sunday .nav a:hover,
html.is-sunday .nav a[aria-current="page"] {
  color: #ff2bd6;
  border-bottom-color: #ffe600;
}

html.is-sunday .prose p,
html.is-sunday .founder-meta dd,
html.is-sunday .faq dd {
  color: #e9d6ff;
}

html.is-sunday .prose .em {
  color: #fff;
  border-bottom-color: #ffe600;
}

html.is-sunday .precepts li {
  color: #fff;
  border-bottom-color: rgba(255, 255, 255, 0.25);
}

html.is-sunday .precepts li::before,
html.is-sunday .founder-meta dt,
html.is-sunday .faq dt {
  color: #ffe600;
}

html.is-sunday .faq dt::before {
  color: #00ff8c;
}

html.is-sunday .faq dd::before {
  color: #ff2bd6;
}

/* 本日の戒め（教義ページ） */
html.is-sunday .today {
  background: rgba(255, 255, 255, 0.08);
  border-color: #ff2bd6;
}
html.is-sunday .today .label,
html.is-sunday .today .detail {
  color: #c9a8ff;
}
html.is-sunday .today .verdict.release {
  color: #ffe600;
  text-shadow: 2px 2px 0 #ff007a;
}

/* 自省ページのカウンター */
html.is-sunday .counter,
html.is-sunday .reflect-count {
  border-top-color: #ff2bd6;
}
html.is-sunday .counter-label,
html.is-sunday .reflect-count-label,
html.is-sunday .counter-unit,
html.is-sunday .reflect-count-unit {
  color: #c9a8ff;
}
html.is-sunday .counter-num,
html.is-sunday .reflect-count-num {
  color: #ffe600;
  text-shadow: 2px 2px 0 #ff007a;
}

/* 教祖ページの御真影 */
html.is-sunday .portrait {
  border-color: #ffe600;
}
html.is-sunday .portrait-mark,
html.is-sunday .portrait-cap {
  color: #00ff8c;
}

/* ボタン類 */
html.is-sunday .vow-button {
  background: #ff007a;
  color: #ffe600;
}
html.is-sunday .vow-button:hover {
  background: #ff2bd6;
}
html.is-sunday .reflect-btn.good { background: #00b050; color: #fff; }
html.is-sunday .reflect-btn.bad { background: #ff0000; color: #fff; }

/* フッター */
html.is-sunday .foot {
  color: #c9a8ff;
}
html.is-sunday .foot .disclaim {
  color: #9a7fd0;
}

/* ── トースト（日曜のツッコミ） ── */
.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%) translateY(20px);
  background: #000;
  color: #fff;
  border: 2px solid #ff2bd6;
  padding: 14px 22px;
  border-radius: 8px;
  font-family: "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  font-size: 14px;
  font-weight: 700;
  max-width: 86vw;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 10;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── ナビ / フッタ ── */
.nav {
  display: flex;
  gap: 28px;
  font-size: 14px;
  letter-spacing: 0.2em;
  margin-bottom: 48px;
}

.nav a {
  color: var(--ink-soft);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--avo);
}

.foot {
  margin-top: 80px;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--ink-soft);
  line-height: 2.2;
}

.foot .disclaim {
  font-size: 11px;
  color: #9a917f;
}

/* ── 言語タブ（右上・固定） ── */
.lang-tabs {
  display: flex;
  justify-content: flex-end;
  gap: 3px;
  margin: 0 0 22px;
  font-family: "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
}

.lang-tabs button {
  font: inherit;
  font-size: 11px;
  letter-spacing: 0.02em;
  padding: 4px 8px;
  cursor: pointer;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid var(--rule);
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}

.lang-tabs button:hover {
  color: var(--ink);
}

.lang-tabs button.active {
  color: var(--paper);
  background: var(--ink);
  border-color: var(--ink);
}

/* 日曜：言語タブもネオン化 */
html.is-sunday .lang-tabs button {
  color: #ffe600;
  background: rgba(0, 0, 0, 0.45);
  border-color: #ff2bd6;
}

html.is-sunday .lang-tabs button.active {
  color: #fff;
  background: #ff007a;
  border-color: #ff007a;
}

/* 狭い画面ではナビと重ならないよう本文を少し下げる */
/* ───────── モバイル調整（余白と見出しを詰めてファーストビューに本文を入れる） ───────── */
@media (max-width: 560px) {
  .sheet {
    padding: 18px 20px 56px;
  }
  .lang-tabs {
    gap: 2px;
    margin-bottom: 16px;
  }
  .lang-tabs button {
    font-size: 10px;
    padding: 3px 6px;
  }
  .nav {
    gap: 13px;
    font-size: 13px;
    letter-spacing: 0.1em;
    margin-bottom: 26px;
    flex-wrap: wrap;
  }
  .nav a {
    white-space: nowrap;
  }
  .seal {
    margin-bottom: 20px;
  }
  .brand {
    font-size: clamp(36px, 10.5vw, 44px);
  }
  .brand .reading {
    font-size: 13px;
    letter-spacing: 0.4em;
    margin-bottom: 10px;
  }
  .creed-lead {
    font-size: 17px;
  }
  .rule {
    margin: 26px 0;
  }
  .countdown-clock {
    gap: 12px;
  }
  .reflect-grid {
    gap: 12px;
  }
  /* 未投票時の空メッセージ枠は詰める（投票後に現れる分には構わない） */
  .reflect-msg:empty {
    min-height: 0;
    margin: 0;
  }
  /* 狭い2カラムでは国名の行＋数字の行の2段組みにする（1行だと国名が縦に折れる） */
  .lb-row {
    flex-wrap: wrap;
    padding: 6px 0;
  }
  .lb-name {
    width: 100%;
    white-space: nowrap;
  }
  .lb-num {
    font-size: 18px;
  }
  .reflect-btn {
    font-size: 19px;
    padding: 18px 10px;
  }
  .vow-button {
    padding: 16px 28px;
  }
  /* 日曜モード */
  .sun-title {
    font-size: clamp(40px, 14vw, 64px);
  }
  .sun-sub {
    font-size: 15px;
    margin-bottom: 22px;
  }
  .sun-marquee.site {
    margin-bottom: 14px;
  }
}

/* Measured-data status and concise collection notice. */
.live-note, .live-state { font-size: 12px; color: var(--ink-soft); line-height: 1.8; }
.live-state p:empty { display: none; }
.live-state button { font: inherit; padding: 6px 14px; cursor: pointer; }
html.is-sunday .live-note, html.is-sunday .live-state { color: #eee; }
[hidden] { display: none !important; }
