/* Nyo Game Portal の CSS。サイトの CSS はこの1本だけで、トップページ（潜水ログ）、404 ページ、DX版の認証ページが共有する。
 * 色調は「深い水・夜の水面」。フォント（Kosugi Maru、M PLUS Rounded 1c、Oxanium）は各ページの head で Google Fonts から読む。
 * 前半がトップページ、最後の「サブページ」の節が 404 と認証ページである。サブページの規則は body.page の中だけに効く。
 * この CSS を変えたら、読んでいる全ページの styles.css?v= の版の番号を上げる（手順は AGENTS.md「CSS の版の番号」）。 */

:root {
  color-scheme: dark;
  --ink: #e2f2ff;
  --muted: #8eb0c9;
  --soft: #5d7f99;
  --line: rgba(120, 220, 255, 0.24);
  --aqua: #5ff3ff;
  --foam: rgba(214, 248, 255, 0.9);
  --pink: #ff6fbf;
  --pink-soft: rgba(255, 111, 191, 0.14);
  --amber: #ffc56b;
  --cat-original: #7dffc4;     /* オリジナル＝藻の緑（菱形） */
  --cat-bluearchive: #b3a2ff;  /* ブルアカ二次創作＝すみれ（丸） */
  --sky: #040d18;
  --sky-low: #071c30;
  --body: "Kosugi Maru", "M PLUS Rounded 1c", "Yu Gothic UI", sans-serif;
  --round: "M PLUS Rounded 1c", "Kosugi Maru", sans-serif;
  --mono: "Oxanium", "Consolas", ui-monospace, monospace;
  --radius: 14px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --gut: 12px;        /* 左の余白 */
  --reserve: 12px;    /* 右の余白（狭い幅では、深度計の細い帯をこの余白に重ねる） */
  --col: 640px;       /* 本文の最大幅（1段組み） */
  --gap: 14px;        /* 行の間隔 */
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; overflow-anchor: none; }  /* スクロール位置の補正は JS で行う */
body { margin: 0; min-width: 320px; min-height: 100vh; overflow-anchor: none; color: var(--ink); font-family: var(--body); background: #010509; }
html.no-scroll, html.no-scroll body { overflow: hidden; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--aqua); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- ボタン（PLAY＝アクア、DX版・BOOTH＝ピンク、攻略＝控えめ） ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 6px 14px;
  border: 1px solid var(--line); border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  font-family: var(--mono); font-weight: 700; font-size: 13px; letter-spacing: 0.1em;
  text-decoration: none; cursor: pointer;
  transition: transform 0.18s var(--ease-out), box-shadow 0.18s, border-color 0.18s;
}
.btn:hover, .btn:focus-visible { transform: translateY(-1px); }
.btn small { font-family: var(--body); font-weight: 500; font-size: 10.5px; letter-spacing: 0; opacity: 0.8; }
.btn-play { color: #022029; border-color: rgba(95, 243, 255, 0.9); background: linear-gradient(180deg, #8ff8ff, #3fd9ea); box-shadow: 0 0 20px rgba(95, 243, 255, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.6); }
.btn-play:hover, .btn-play:focus-visible { box-shadow: 0 0 32px rgba(95, 243, 255, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.6); }
.btn-booth { color: #ffd3ec; border-color: rgba(255, 111, 191, 0.6); background: var(--pink-soft); }
.btn-booth:hover, .btn-booth:focus-visible { border-color: var(--pink); box-shadow: 0 0 20px rgba(255, 111, 191, 0.28); }
.btn-booth.is-primary { color: #2a0017; background: linear-gradient(180deg, #ffa3d6, #ff5fb4); border-color: #ff8fcb; }
.btn-guide { color: #cfe3f3; background: rgba(3, 16, 32, 0.6); }
.btn-guide:hover, .btn-guide:focus-visible { border-color: rgba(95, 243, 255, 0.6); }
/* 詳細の DX版の枠のボタン：PLAY より一段控えめな、ピンクの淡い塗り。幅いっぱいで押しやすく */
.btn-dx {
  width: 100%; min-height: 50px; padding: 6px 16px; font-family: var(--round); font-size: 15px; letter-spacing: 0.04em; color: #fff3fa;
  border-color: rgba(255, 143, 203, 0.85); background: linear-gradient(180deg, rgba(255, 111, 191, 0.4), rgba(255, 111, 191, 0.22));
}
.btn-dx:hover, .btn-dx:focus-visible { border-color: #ffb8de; background: linear-gradient(180deg, rgba(255, 111, 191, 0.55), rgba(255, 111, 191, 0.32)); box-shadow: 0 0 22px rgba(255, 111, 191, 0.35); }
.i-ext { font-style: normal; font-weight: 500; opacity: 0.85; }
.i-play { width: 0; height: 0; border-left: 8px solid currentColor; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }

/* ---------- 背景の海（固定）。スクロール量で、水面近くの紺 → 深い紺 → ほぼ黒 ---------- */
.sea { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; background: #010509; }
.sea-layer { position: absolute; inset: 0; will-change: opacity; }
.sea-mid { background: linear-gradient(180deg, #06223d 0%, #041a31 55%, #03132a 100%); }
.sea-shallow { background: radial-gradient(900px 420px at 50% -8%, rgba(120, 225, 255, 0.2), transparent 70%), linear-gradient(180deg, #11527a 0%, #0c3d60 42%, #092f4e 100%); }
/* 光の筋（浅いところだけ）。下へ向かって消える */
.rays { position: absolute; left: 0; right: 0; top: 0; height: 88vh; will-change: opacity; -webkit-mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.55) 45%, transparent 92%); mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.55) 45%, transparent 92%); }
.rays i {
  position: absolute; top: -12%; left: var(--x); width: var(--w); min-width: 60px; height: 125%; opacity: var(--o);
  background: linear-gradient(90deg, transparent, rgba(170, 238, 255, 0.07) 30%, rgba(210, 248, 255, 0.15) 50%, rgba(170, 238, 255, 0.07) 70%, transparent);
  transform-origin: 50% 0; transform: rotate(var(--r));
  animation: ray-sway var(--d) ease-in-out infinite alternate;
}
@keyframes ray-sway { 50% { opacity: calc(var(--o) * 0.45); } 100% { transform: rotate(calc(var(--r) - 6deg)) translate3d(3vw, 0, 0); } }
/* 泡（飾り） */
.bubbles { position: absolute; inset: 0; }
.bubbles i {
  position: absolute; bottom: -24px; left: var(--x); width: var(--s); height: var(--s); border-radius: 50%; opacity: 0;
  border: 1px solid rgba(214, 248, 255, 0.38);
  background: radial-gradient(circle at 32% 30%, rgba(255, 255, 255, 0.55), rgba(214, 248, 255, 0.08) 45%, transparent 70%);
  animation: bubble-rise var(--d) linear var(--delay) infinite;
}
@keyframes bubble-rise {
  10% { opacity: 0.75; }
  50% { transform: translate3d(var(--w), -55vh, 0); }
  85% { opacity: 0.5; }
  100% { transform: translate3d(0, -112vh, 0); opacity: 0; }
}
html.is-paused .sea *, html.is-paused .surface * { animation-play-state: paused !important; }

/* ---------- ヘッダー＝水面 ---------- */
.surface { position: relative; z-index: 2; background: radial-gradient(300px 120px at 86% 0%, rgba(214, 248, 255, 0.09), transparent 70%), linear-gradient(180deg, var(--sky), var(--sky-low)); }
.surface-inner, .dive, .seabed-inner, .works-src {
  max-width: calc(var(--col) + var(--gut) + var(--reserve));
  margin: 0 auto; padding-left: var(--gut); padding-right: var(--reserve);
}
.surface-inner {
  position: relative; z-index: 1; padding-top: 2px; padding-bottom: 8px;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand shop" "lead lead" "i18n i18n"; align-items: center; row-gap: 2px;
}
.brand { grid-area: brand; margin: 0; font-family: var(--mono); font-weight: 700; font-size: 18px; letter-spacing: 0.08em; line-height: 44px; color: var(--foam); text-shadow: 0 0 14px rgba(95, 243, 255, 0.35); }
.lead { grid-area: lead; margin: 0; font-size: 11.5px; line-height: 1.45; color: var(--muted); }
.shop-link { grid-area: shop; display: inline-flex; align-items: center; gap: 5px; min-height: 44px; padding: 0 2px 0 12px; font-size: 12px; color: #ffd3ec; text-decoration: none; }
.shop-link::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--pink); box-shadow: 0 0 8px var(--pink); }
.shop-link:hover, .shop-link:focus-visible { text-decoration: underline; }
/* キャッチコピーの「状態」：アンバーに発光し、時折ふるえる */
.jotai { display: inline-block; color: var(--amber); font-weight: 700; text-shadow: 0 0 6px rgba(255, 197, 107, 0.85), 0 0 16px rgba(255, 170, 60, 0.45); }
.jotai.is-shiver { animation: shiver 0.4s linear; }
@keyframes shiver {
  12% { transform: translate(-1.5px, 0.5px) rotate(-2.5deg); }
  25% { transform: translate(1.5px, -1px) rotate(2deg); }
  38% { transform: translate(-1px, 1px) rotate(-1.5deg); }
  50% { transform: translate(1.5px, 0) rotate(2.5deg); }
  63% { transform: translate(-1.5px, -0.5px) rotate(-1deg); }
  76% { transform: translate(1px, 1px) rotate(1.5deg); }
  88% { transform: translate(-0.5px, 0) rotate(-0.5deg); }
}
/* 外国語で来た人向けの案内。日本語のキャッチコピーより小さく、色も控えめ */
.i18n { grid-area: i18n; margin-top: 3px; display: grid; gap: 2px; }
.i18n p { margin: 0; }
.i18n-langs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.i18n-lbl { margin-right: 2px; font: 600 9px/1 var(--mono); letter-spacing: 0.16em; color: var(--soft); }
.i18n-chip { padding: 0 6px; border: 1px solid rgba(120, 220, 255, 0.22); border-radius: 999px; background: rgba(3, 16, 32, 0.5); font-size: 10px; line-height: 15px; color: #a9c7dc; }
.i18n-note { font-family: var(--mono); font-size: 10px; line-height: 1.35; color: var(--soft); }
.nojs-warn { grid-column: 1 / -1; margin: 6px 0 0; padding: 8px 10px; border: 1px solid rgba(255, 197, 107, 0.4); border-radius: 8px; font-size: 12px; line-height: 1.7; color: #ffe6b3; }
/* 水面のきらめきと、揺らぐ水面の線（ヘッダーの下端から水中へ垂れ下がる） */
.glints { position: absolute; left: 0; right: 0; bottom: 0; height: 14px; overflow: hidden; pointer-events: none; }
.glints i { position: absolute; left: var(--x); bottom: var(--t); width: var(--w); height: 2px; border-radius: 2px; background: linear-gradient(90deg, transparent, rgba(230, 250, 255, 0.85), transparent); opacity: 0.2; animation: glint var(--d) ease-in-out infinite alternate; }
@keyframes glint { 0% { opacity: 0.1; transform: scaleX(0.6); } 100% { opacity: 0.9; transform: scaleX(1.1); } }
.waves { position: absolute; left: 0; right: 0; top: 100%; height: 18px; overflow: hidden; pointer-events: none; }
.wave { position: absolute; left: 0; top: 0; width: 200%; height: 100%; }
.wave--back { animation: wave-drift 19s linear infinite reverse; opacity: 0.6; }
.wave--front { animation: wave-drift 12s linear infinite; }
.wave-fill { fill: var(--sky-low); }
.wave--back .wave-fill { fill: rgba(7, 28, 48, 0.8); }
.wave-line { fill: none; stroke: rgba(214, 248, 255, 0.6); stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.wave--back .wave-line { stroke: rgba(95, 243, 255, 0.35); }
@keyframes wave-drift { to { transform: translate3d(-50%, 0, 0); } }

/* ---------- 作品の行（ログ）：キービジュアルと情報で1枚のカード。スマホは列の幅いっぱいの絵 ---------- */
.dive { position: relative; z-index: 1; padding-top: 24px; padding-bottom: 8px; }
.logs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gap); }
.log { position: relative; min-width: 0; }
html:not(.is-entered) .log { opacity: 0; }
html.is-entered .log { animation: log-in 0.62s var(--ease-out) both; animation-delay: calc(min(var(--i), 8) * 60ms); }
@keyframes log-in { from { opacity: 0; transform: translate3d(0, 18px, 0); } }
.log-card {
  overflow: hidden; border: 1px solid rgba(120, 220, 255, 0.2); border-radius: var(--radius);
  background: rgba(3, 16, 30, 0.7); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.32); transition: border-color 0.2s;
}
.log-card:hover { border-color: rgba(95, 243, 255, 0.42); }
.log.is-open .log-card { border-color: rgba(95, 243, 255, 0.55); background: rgba(2, 13, 26, 0.94); }

/* 頭部：絵＋情報。全体が「詳細を開く」ボタン（題名のボタンを頭部いっぱいに広げる） */
.log-head { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); }
.log-kv { position: relative; overflow: hidden; }
.kv { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: #0b3552; }
.kv--pending { display: grid; place-items: center; background: repeating-linear-gradient(135deg, rgba(255, 111, 191, 0.1) 0 12px, transparent 12px 24px), linear-gradient(160deg, #2a1236, #0a1a33); color: rgba(255, 190, 228, 0.85); font: 12px var(--mono); letter-spacing: 0.2em; }
.log-kv .kv { transition: transform 0.5s var(--ease-out); }
.log-head:hover .log-kv .kv { transform: scale(1.025); }
.log-depth {
  position: absolute; left: 8px; top: 8px; display: inline-flex; gap: 6px; align-items: center;
  padding: 3px 8px; border-radius: 6px; background: rgba(1, 8, 16, 0.72);
  font: 600 11px/1.4 var(--mono); letter-spacing: 0.06em; color: var(--aqua);
}
.log-depth b { padding: 0 6px; border-radius: 3px; background: var(--amber); color: #1b1200; font-family: var(--body); letter-spacing: 0; }
.log-node { display: none; }
.log-info { display: grid; gap: 10px; padding: 10px 12px 12px; min-width: 0; }
.log-text { display: grid; gap: 4px; min-width: 0; }
/* 作品内容のタグ（題名の上。分類の印を先頭にまとめる）。折りたたみでは2行まで */
.log-tags { margin: 0; display: flex; flex-wrap: wrap; gap: 4px; max-height: 44px; overflow: hidden; }
.log.is-open .log-tags { max-height: none; }
.tag {
  display: inline-flex; align-items: center; gap: 5px; height: 20px; padding: 0 8px;
  border: 1px solid rgba(120, 200, 255, 0.26); border-radius: 999px; background: rgba(3, 16, 32, 0.55);
  font-size: 10.5px; color: #aac8e6; white-space: nowrap;
}
.tag--mech { border-color: rgba(255, 197, 107, 0.42); background: rgba(255, 197, 107, 0.1); color: #ffe6b3; }
.tag.cat--original, .tag.cat--bluearchive { border-color: currentColor; font-weight: 700; }
.cat--original { color: var(--cat-original); }
.cat--bluearchive { color: var(--cat-bluearchive); }
.tag.cat--original::before, .tag.cat--bluearchive::before { content: ''; width: 6px; height: 6px; background: currentColor; }
.tag.cat--original::before { transform: rotate(45deg); }
.tag.cat--bluearchive::before { border-radius: 50%; }
.log-title { margin: 2px 0 0; font-family: var(--round); font-size: 18px; line-height: 1.35; font-weight: 800; }
.log-open { display: block; width: 100%; margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.log-open::after { content: ''; position: absolute; inset: 0; border-radius: var(--radius); }
.log-open:focus-visible { outline: none; }
.log-open:focus-visible::after { outline: 2px solid var(--aqua); outline-offset: -3px; }
.t-main, .t-sub { display: block; }
.t-sub { margin-top: 1px; font-size: 12.5px; font-weight: 500; color: var(--muted); }
.log-kicker { margin: 0; font: 500 11px/1.45 var(--mono); letter-spacing: 0.05em; color: rgba(95, 243, 255, 0.82); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.log.is-open .log-kicker { white-space: normal; }
.log-meta { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; font-size: 11px; line-height: 1.6; color: var(--muted); }
.log-date { font: 600 12px/1.5 var(--mono); letter-spacing: 0.04em; color: var(--ink); }
.new, .dxonly { padding: 0 7px; border-radius: 999px; font: 700 10px/1.7 var(--mono); letter-spacing: 0.06em; }
.new { background: var(--amber); color: #1b1200; }
.dxonly { border: 1px solid rgba(255, 111, 191, 0.6); background: var(--pink-soft); color: #ffd0ea; font-family: var(--body); }
/* 開閉の目印（押せるのは頭部全体。これは飾り） */
.log-more { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; color: var(--soft); }
.log-more::before { content: '詳細'; }
.log-more::after { content: ''; width: 6px; height: 6px; margin-top: -3px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform 0.25s var(--ease-out); }
.log-head:hover .log-more, .log.is-open .log-more { color: var(--aqua); }
.log.is-open .log-more::before { content: '閉じる'; }
.log.is-open .log-more::after { transform: rotate(-135deg); margin-top: 3px; }
.log-desc { display: none; margin: 2px 0 0; font-size: 13px; line-height: 1.8; color: #cfe3f3; }
.log.is-open .log-desc { display: none !important; }   /* 開いたら、説明の全文は下の詳細に出る */

/* 操作帯：帯そのものは頭部のボタンより手前にあり、隙間を押しても詳細は開かない */
.log-actions { position: relative; z-index: 1; display: flex; gap: 8px; padding-top: 10px; border-top: 1px dashed rgba(120, 220, 255, 0.16); cursor: default; }
.log-actions > .btn { flex: 1 1 0; }
.log-actions > .btn-play { flex-grow: 1.3; }
/* 開いたとき：操作帯は PLAY（と攻略）だけ。DX版の入口は詳細の DX版の枠に1つだけ置く */
.log.is-open .log-actions > .btn-play { flex-grow: 2; font-size: 15px; }

/* 先頭（最新作）＝ヒーロー行。スマホでは画面の端から端まで */
.log--hero { margin: 0 calc(-1 * var(--reserve)) 4px calc(-1 * var(--gut)); }
.log--hero .log-card { border-radius: 0; border-left: 0; border-right: 0; border-color: rgba(95, 243, 255, 0.34); background: rgba(3, 18, 34, 0.78); }
.log--hero .log-open::after { border-radius: 0; }
.log--hero .log-info { padding: 12px var(--reserve) 14px var(--gut); }
.log--hero .log-title { font-size: 22px; line-height: 1.3; }
.log--hero .t-sub { font-size: 13.5px; }
.log--hero .log-actions { border-top: 0; padding-top: 2px; }
.log--hero .log-actions > .btn { min-height: 48px; font-size: 15px; }

/* ---------- 詳細（行の下に開く）。1列では あらすじ → DX版 → スクショ → 言語 → 更新履歴。PC は2列（960px〜の節） ---------- */
.log-detail { position: relative; border-top: 1px solid rgba(120, 220, 255, 0.14); }
.d-in { display: grid; gap: 28px; padding: 18px 12px 8px; animation: detail-in 0.34s var(--ease-out) both; }
@keyframes detail-in { from { opacity: 0; transform: translate3d(0, -10px, 0); } }
.d-side, .d-main { display: contents; }   /* 1列のときは中身を .d-in に並べ、order で順を決める */
.d-desc { order: 1; } .d-in .dx-box { order: 2; } .d-ss { order: 3; } .d-langs { order: 4; } .d-rn { order: 5; } .d-foot { order: 6; }
.d-sec { min-width: 0; }
.d-sec p, .d-foot { margin: 0; }
/* まとまりの見出し：左に短い縦線、右へ細い線。これが区切りも兼ねる */
.d-h { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font: 700 14px/1.4 var(--round); letter-spacing: 0.06em; color: #bdeaf8; }
.d-h::before { content: ''; flex: none; width: 3px; height: 15px; border-radius: 2px; background: var(--aqua); box-shadow: 0 0 8px rgba(95, 243, 255, 0.5); }
.d-h::after { content: ''; flex: 1 1 auto; height: 1px; background: linear-gradient(90deg, rgba(120, 220, 255, 0.32), transparent); }
.d-h small { font: 500 12px var(--mono); letter-spacing: 0.04em; color: var(--muted); }
/* あらすじ：読ませる本文。大きく、行間を広く、いちばん明るい色で */
.d-desc p { max-width: 36em; font-size: 15px; line-height: 1.95; color: #eef7ff; }
/* スクショ：水中の窓のように横へ並べる。押すと拡大 */
.ss-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.ss-row button { flex: none; padding: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: none; cursor: zoom-in; scroll-snap-align: start; transition: border-color 0.2s; }
.ss-row button:hover { border-color: rgba(95, 243, 255, 0.75); }
.ss-row img { display: block; height: 104px; width: auto; }
.d-ss.is-portrait img { height: 168px; }

/* DX版の枠：見出し → 機能の一覧（種類ごとに印と色を変える）→ 幅いっぱいのボタン */
.dx-box { display: grid; gap: 12px; padding: 14px 14px 16px; border: 1px solid rgba(255, 111, 191, 0.36); border-radius: 14px; background: linear-gradient(180deg, rgba(255, 111, 191, 0.12), rgba(255, 111, 191, 0.04)); }
.dx-head { margin: 0; font: 700 14px/1.4 var(--round); color: #ffd3ec; }
.dx-head b { margin-right: 1px; font-size: 17px; font-weight: 800; color: #fff0f8; }
.dx-feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.dx-feats li { display: flex; align-items: center; gap: 10px; font-size: 14px; line-height: 1.45; color: #ffeaf5; }
.dx-feats li::before { content: ''; flex: none; width: 30px; height: 30px; border: 1px solid var(--c); border-radius: 8px; background: rgba(10, 6, 22, 0.55) var(--ic) center / 18px no-repeat; }
.dx-feats .f3d { --c: rgba(180, 192, 255, 0.55); --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b4c0ff' stroke-width='2' stroke-linejoin='round'%3E%3Cpath d='M12 3l8 4.5v9L12 21l-8-4.5v-9zM4 7.5l8 4.5 8-4.5M12 12v9'/%3E%3C/svg%3E"); }
.dx-feats .fanim { --c: rgba(255, 159, 210, 0.55); --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ff9fd2' stroke-width='2' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2.5'/%3E%3Cpath d='M10 9.5v5l4.5-2.5z' fill='%23ff9fd2'/%3E%3C/svg%3E"); }
.dx-feats .cheat { --c: rgba(255, 176, 138, 0.55); --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffb08a' stroke-width='2' stroke-linejoin='round'%3E%3Cpath d='M13 2.5L5 13.5h6l-1 8 8-11h-6z'/%3E%3C/svg%3E"); }
.dx-feats .mech { --c: rgba(255, 197, 107, 0.55); --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffc56b' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 3.5s6 6.4 6 10.8a6 6 0 0 1-12 0C6 9.9 12 3.5 12 3.5zM8.8 15.5h6.4'/%3E%3C/svg%3E"); }
.dx-feats .etc { --c: rgba(255, 196, 228, 0.45); --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffc4e4' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E"); }

/* 対応言語：原語は明るい実線の札、機械翻訳は淡い点線の札で、違いを一目で分ける */
.d-langs dl { margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 10px 12px; }
.d-langs dt { font-size: 12px; line-height: 30px; color: var(--muted); }   /* 札が折り返しても、1行目の札の高さに揃える */
.d-langs dd { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.d-langs dd span { display: inline-flex; align-items: center; min-height: 28px; padding: 0 10px; border: 1px dashed rgba(142, 176, 201, 0.6); border-radius: 999px; font-size: 13px; color: #c3d9ea; }
.d-langs .is-base span { border: 1px solid rgba(226, 242, 255, 0.65); background: rgba(226, 242, 255, 0.1); font-size: 14px; font-weight: 700; color: #fff; }

/* 更新履歴：最新版はそのまま、それ以前だけ折りたたむ。項目の無い版は1行。左の線で版の区切りを示す */
.rn, .rn-min { padding-left: 12px; border-left: 2px solid rgba(95, 243, 255, 0.55); }
.d-rn details .rn, .d-rn details .rn-min { border-left-color: rgba(120, 220, 255, 0.22); }
.rn-h { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; font-size: 14px; font-weight: 700; line-height: 1.55; color: var(--ink); }
.rn-h b { font: 700 13px var(--mono); letter-spacing: 0.04em; color: var(--aqua); }
.rn-h time { font: 500 12px var(--mono); color: var(--muted); }
.rn-h.rn-min { font-weight: 500; color: #c9dcec; }
.rn ul { margin: 6px 0 0; padding-left: 1.2em; font-size: 13.5px; line-height: 1.75; color: #c9dcec; }
/* 「それ以前の更新」：枠・件数・開閉の向きの矢印で、押せることを示す */
.d-rn details { margin-top: 16px; }
.d-rn summary {
  display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 16px; list-style: none; cursor: pointer;
  border: 1px solid rgba(120, 220, 255, 0.36); border-radius: 12px; background: rgba(95, 243, 255, 0.06);
  font-size: 14px; font-weight: 700; color: var(--ink); transition: border-color 0.2s, background-color 0.2s;
}
.d-rn summary::-webkit-details-marker { display: none; }
.d-rn summary em { padding: 0 8px; border-radius: 999px; background: rgba(95, 243, 255, 0.14); font: 600 12px/1.6 var(--mono); font-style: normal; color: var(--aqua); }
.d-rn summary::after { content: ''; margin: -4px 2px 0 auto; width: 8px; height: 8px; border-right: 2px solid var(--aqua); border-bottom: 2px solid var(--aqua); transform: rotate(45deg); transition: transform 0.25s var(--ease-out); }
.d-rn details[open] > summary::after { margin-top: 4px; transform: rotate(-135deg); }
.d-rn summary:hover, .d-rn summary:focus-visible { border-color: rgba(95, 243, 255, 0.8); background: rgba(95, 243, 255, 0.13); }
.d-rn details > * + * { margin-top: 16px; }
.d-foot { display: flex; justify-content: center; }
.d-close { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 22px; border: 1px solid var(--line); border-radius: 999px; background: rgba(3, 16, 32, 0.6); color: var(--muted); cursor: pointer; font-size: 13px; }
.d-close:hover, .d-close:focus-visible { color: var(--ink); border-color: rgba(95, 243, 255, 0.6); }

/* ---------- 海底（フッター）。最後の行も上端まで潜れる高さを取る（--last-h は JS が入れる） ---------- */
.seabed {
  position: relative; z-index: 1; margin-top: 40px; padding: 44px 0 96px; min-height: calc(100vh - 56px - var(--last-h, 200px));
  background: radial-gradient(60% 40px at 20% 0%, rgba(80, 70, 50, 0.22), transparent 70%), linear-gradient(180deg, rgba(20, 18, 14, 0), rgba(20, 18, 14, 0.55) 40%, #07070a);
}
.seabed-inner { display: grid; gap: 12px; justify-items: start; }
.seabed-inner p { margin: 0; }
.seabed-mark { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; font-size: 13px; color: var(--muted); }
.seabed-mark .en { font: 11px var(--mono); letter-spacing: 0.2em; color: #b9a98a; }
#seabed-depth { font-family: var(--mono); color: var(--aqua); }
.to-surface { min-height: 44px; padding: 0 18px; border: 1px solid var(--line); border-radius: 999px; background: rgba(3, 16, 32, 0.6); cursor: pointer; font-size: 13px; }
.ga-note, .author { font-size: 11px; line-height: 1.7; color: var(--soft); }
.seabed code { font: 10.5px var(--mono); overflow-wrap: anywhere; }
.seabed a { color: var(--muted); }

/* ---------- 深度計（狭い幅）：右の余白に重ねた細い帯（押せない）＋ 目次を開く浮いたボタン ---------- */
.strip { position: fixed; top: 14px; right: 3px; bottom: 86px; z-index: 40; width: 6px; pointer-events: none; }
.strip-rail { position: absolute; inset: 0; }
.strip-rail::before { content: ''; position: absolute; left: 2px; top: 0; bottom: 0; width: 2px; border-radius: 1px; background: linear-gradient(180deg, rgba(150, 240, 255, 0.55), rgba(95, 243, 255, 0.2) 45%, rgba(60, 90, 130, 0.3)); }
.lane-dot { position: absolute; left: 0; width: 6px; height: 6px; margin-top: -3px; background: currentColor; opacity: 0.6; }
.lane-dot.cat--original { transform: rotate(45deg); }
.lane-dot.cat--bluearchive { border-radius: 50%; }
.lane-dot.is-current { opacity: 1; box-shadow: 0 0 8px currentColor; }
.strip-marker { position: absolute; left: -3px; top: 0; width: 12px; height: 12px; margin-top: -6px; border: 2px solid var(--aqua); border-radius: 50%; background: rgba(1, 10, 20, 0.85); box-shadow: 0 0 10px rgba(95, 243, 255, 0.6); will-change: transform; }
.fab {
  position: fixed; right: 10px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 60;
  width: 58px; height: 58px; padding: 0; border-radius: 50%; border: 1.5px solid rgba(95, 243, 255, 0.85);
  background: radial-gradient(circle at 50% 30%, rgba(20, 70, 100, 0.95), rgba(2, 14, 26, 0.95) 70%);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.55), 0 0 16px rgba(95, 243, 255, 0.3);
  display: grid; place-content: center; justify-items: center; gap: 2px; color: #eaffff; cursor: pointer;
  /* --lift：止まったときに PLAY などの帯と重なるなら、帯の上まで持ち上げる（JS が入れる） */
  transform: translate3d(0, var(--lift, 0px), 0); transition: transform 0.28s var(--ease-out), opacity 0.2s;
}
.fab.is-scrolling { transform: translate3d(18px, 0, 0) scale(0.8); opacity: 0.72; }
.fab-lbl { font-size: 9.5px; line-height: 1; color: var(--muted); }
.fab-read { font: 700 12px/1 var(--mono); }

/* ---------- 目次の引き出し ---------- */
.toc { position: fixed; inset: 0; z-index: 800; }
.toc-backdrop { position: absolute; inset: 0; background: rgba(1, 6, 14, 0.62); }
.toc-panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(340px, calc(100% - 36px)); display: flex; flex-direction: column;
  border-left: 1px solid var(--line); background: linear-gradient(180deg, rgba(8, 40, 64, 0.97), rgba(2, 12, 24, 0.98) 55%, rgba(1, 5, 10, 0.99));
  box-shadow: -20px 0 50px rgba(0, 0, 0, 0.5); animation: toc-in 0.3s var(--ease-out) both;
}
@keyframes toc-in { from { transform: translate3d(100%, 0, 0); } }
.toc-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 6px 4px 16px; }
.toc-head p, .toc-head h2 { margin: 0; }
.toc-en { font: 10px var(--mono); letter-spacing: 0.22em; color: var(--aqua); }
.toc-head h2 { font-size: 16px; }
.toc-close { width: 44px; height: 44px; border: 0; background: none; font-size: 26px; line-height: 1; color: var(--foam); cursor: pointer; }
.toc-hint { margin: 0; padding: 0 16px 10px; font-size: 12px; line-height: 1.6; color: var(--muted); }
.toc-list { list-style: none; margin: 0; padding: 0 8px 24px; overflow-y: auto; overscroll-behavior: contain; flex: 1 1 auto; }
.toc-item { width: 100%; min-height: 56px; margin: 0; padding: 6px 8px; display: grid; grid-template-columns: 46px 72px minmax(0, 1fr); align-items: center; gap: 10px; border: 0; border-radius: 10px; background: none; text-align: left; cursor: pointer; }
.toc-item:hover, .toc-item:focus-visible { background: rgba(95, 243, 255, 0.08); }
.toc-item[aria-current="true"] { background: rgba(95, 243, 255, 0.14); box-shadow: inset 3px 0 0 var(--aqua); }
.toc-depth { font: 700 12px/1 var(--mono); color: var(--aqua); text-align: right; }
.toc-kv { border-radius: 5px; font-size: 7px; letter-spacing: 0.05em; }
.toc-text { display: grid; gap: 2px; min-width: 0; }
.toc-title { font-size: 13px; font-weight: 700; line-height: 1.35; }
.toc-meta { display: flex; flex-wrap: wrap; gap: 2px 8px; font-size: 10.5px; color: var(--muted); }
.toc-meta time { font-family: var(--mono); }
.toc-meta .tag { height: 18px; font-size: 10px; }
.toc-item--surface { grid-template-columns: 46px minmax(0, 1fr); min-height: 48px; color: var(--foam); }

/* ---------- 年齢確認（初回だけ） ---------- */
.age-gate { position: fixed; inset: 0; z-index: 900; display: grid; place-items: center; padding: 24px 16px; background: radial-gradient(800px 500px at 50% 30%, rgba(95, 243, 255, 0.1), transparent 70%), rgba(1, 6, 14, 0.96); backdrop-filter: blur(6px); }
.age-box { width: min(520px, 100%); padding: 28px clamp(18px, 5vw, 32px); display: grid; gap: 14px; border: 1px solid var(--line); border-radius: 18px; background: rgba(3, 16, 32, 0.94); }
.age-box h2, .age-box p { margin: 0; }
.age-box h2 { font-size: 18px; }
.age-box p { font-size: 14px; line-height: 1.8; color: #cfe3f3; }
.age-box .age-en { font: 11px var(--mono); letter-spacing: 0.2em; color: var(--aqua); }
.age-acts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.age-acts .btn { flex: 1 1 180px; min-height: 48px; }
.age-gate.is-leaving { animation: gate-out 0.5s var(--ease-out) forwards; }
@keyframes gate-out { to { opacity: 0; visibility: hidden; } }

/* ---------- スクショ拡大 ---------- */
.lb { position: fixed; inset: 0; z-index: 1000; display: grid; grid-template-columns: 56px 1fr 56px; align-items: center; background: rgba(1, 6, 14, 0.94); }
.lb figure { margin: 0; display: grid; justify-items: center; gap: 10px; max-height: 100vh; padding: 48px 0 16px; }
.lb img { max-width: 100%; max-height: calc(100vh - 110px); object-fit: contain; border-radius: 8px; }
.lb figcaption { font-size: 12px; color: var(--muted); }
.lb button { height: 100%; border: 0; background: none; font-size: 34px; color: var(--foam); cursor: pointer; }
.lb .lb-close { position: absolute; top: 8px; right: 12px; width: 44px; height: 44px; font-size: 30px; }
.lb.is-single .lb-nav { visibility: hidden; }

/* ---------- JS が動かないとき：article をそのまま縦の一覧として見せる ---------- */
.works-src { display: grid; gap: 16px; padding-top: 28px; padding-bottom: 40px; }
.works-src > h2 { margin: 0; font-size: 16px; }
.game-card { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(3, 16, 30, 0.75); font-size: 13px; line-height: 1.7; }
.game-card > *, .game-card .card-top > * { margin: 0; }
.game-card .card-kv { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; }
.game-card .card-kv[data-kv="pending"] { display: grid; place-items: center; background: #2a1236; font-family: var(--mono); }
.game-card .card-index { display: none; }
.card-tags, .card-badges, .lang-bar, .ss-strip, .dx-tags, .card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; font-size: 11px; }
.tag-badge, .card-badge, .lang-tag { padding: 0 7px; border: 1px solid var(--line); border-radius: 999px; }
.ss-thumb { padding: 0; border: 0; background: none; }
.ss-thumb img { display: block; height: 72px; width: auto; border-radius: 6px; }
.play-link, .dl-link, .guide-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; }
.play-link { background: #3fd9ea; color: #022029; font-weight: 700; }
.dl-link { border-color: rgba(255, 111, 191, 0.6); color: #ffd3ec; }
.release-notes summary { cursor: pointer; }

/* ---------- 700px〜：1段組みのまま、余白と文字を広げる ---------- */
@media (min-width: 700px) {
  :root { --gut: 20px; --reserve: 20px; --gap: 18px; }
  .surface-inner { padding-top: 8px; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "brand lead shop" "i18n i18n i18n"; column-gap: 16px; }
  .brand { font-size: 20px; }
  .lead { font-size: 13px; }
  .i18n { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
  .i18n-note { font-size: 10.5px; }
  .dive { padding-top: 30px; }
  .log--hero { margin: 0 0 6px; }
  .log--hero .log-card { border-radius: var(--radius); border: 1px solid rgba(95, 243, 255, 0.34); }
  .log--hero .log-open::after { border-radius: var(--radius); }
  .log--hero .log-info, .log-info { padding: 14px 18px 16px; }
  .log-title { font-size: 20px; }
  .log-desc { display: block; }
  .d-in { padding: 22px 22px 8px; }
  .d-desc p { font-size: 16px; }
  /* スクショは全枚数を横スクロールなしで並べる。横長は1枚 220〜340px の等幅の格子で、入りきらなければ次の段へ折り返す
     （PC では1段に4枚まで。7枚なら4＋3）。縦長は高くなりすぎないよう細めにして、1段に並べる */
  /* 列数は下限の 220px で数える（上限を minmax の最大に書くと、そちらで数えられて列が減る）。上限はボタンの max-width で抑える */
  .ss-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; overflow: visible; padding-bottom: 0; }
  .ss-row button { max-width: 340px; }
  .d-ss.is-portrait .ss-row { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(0, 160px); }
  .ss-row img, .d-ss.is-portrait .ss-row img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
  .d-ss.is-portrait .ss-row img { aspect-ratio: 9 / 17; }
}

/* ---------- 960px〜：左に深さのレール。各作品は「左に絵、右に情報」の1枚のカード ---------- */
.rail-wrap { display: none; }
@media (min-width: 960px) {
  :root { --col: 1220px; --rail: 140px; --gut: 24px; --reserve: 24px; --gap: 28px; }
  .surface-inner { padding-top: 6px; padding-bottom: 6px; row-gap: 0; }
  .strip, .fab { display: none; }

  /* レール列の見出し（今の深さ・水面へ・目次）。レール列の上部に留まる */
  .rail-wrap { display: block; position: absolute; top: 0; bottom: 0; left: var(--gut); width: var(--rail); z-index: 3; pointer-events: none; }
  .rail-head {
    position: sticky; top: 16px; margin-top: 8px; width: calc(var(--rail) - 14px); padding: 8px; display: grid; gap: 4px;
    border: 1px solid rgba(120, 220, 255, 0.24); border-radius: 12px; background: rgba(2, 12, 24, 0.94); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    pointer-events: auto;
  }
  .rail-head p { margin: 0; }
  .rail-cap { display: flex; align-items: baseline; gap: 6px; font: 600 9px/1.3 var(--mono); letter-spacing: 0.2em; color: var(--soft); white-space: nowrap; }
  .rail-cap span { font: 500 9.5px var(--body); letter-spacing: 0; }
  .rail-read { display: flex; align-items: baseline; gap: 6px; white-space: nowrap; }
  .gauge-readout { font: 700 24px/1 var(--mono); color: #eaffff; text-shadow: 0 0 16px rgba(95, 243, 255, 0.45); }
  .gauge-zone { font-size: 11px; color: var(--muted); }
  .rail-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 2px; }
  .rail-btn { min-height: 44px; padding: 0 2px; border: 1px solid var(--line); border-radius: 10px; background: rgba(3, 16, 32, 0.6); color: var(--foam); font-size: 11.5px; white-space: nowrap; cursor: pointer; }
  .rail-btn:hover, .rail-btn:focus-visible { border-color: var(--aqua); }

  /* レールの線。カードの列の左に1本だけ通す */
  .logs { position: relative; padding-left: var(--rail); }
  .logs::before { content: ''; position: absolute; left: 16px; top: -30px; bottom: 0; width: 2px; border-radius: 1px; background: linear-gradient(180deg, rgba(150, 240, 255, 0.7), rgba(95, 243, 255, 0.32) 30%, rgba(60, 90, 130, 0.4)); }

  /* カード：外枠と背景を絵と情報で共有する */
  .log-card { overflow: visible; }
  .log-head { grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); }
  .log-kv { align-self: start; border-radius: calc(var(--radius) - 1px) 0 0 calc(var(--radius) - 1px); }
  .log.is-open .log-kv { border-bottom-left-radius: 0; }
  .log:not(.log--hero) .log-depth { display: none; }
  .log-info, .log--hero .log-info { align-self: center; padding: 18px 22px; gap: 12px; }
  .log-title { font-size: 24px; }
  .t-sub { font-size: 14px; }
  .log--hero .log-head { grid-template-columns: minmax(0, 1.83fr) minmax(0, 1fr); }
  .log--hero .log-title { font-size: clamp(24px, 2.3vw, 30px); }
  .log--hero .log-depth { left: 12px; top: 12px; font-size: 12px; }
  /* 詳細：最上段に横幅いっぱいのスクショ。その下は頭部と同じ比率の2列で、絵の下に あらすじ・更新履歴、情報の下（PLAY の真下）に DX版・言語 */
  .d-in { grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: 0; padding: 24px 0 10px; }
  .log--hero .d-in { grid-template-columns: minmax(0, 1.83fr) minmax(0, 1fr); }
  .d-ss { grid-column: 1 / -1; grid-row: 1; padding: 0 22px; margin-bottom: 30px; }
  .d-main, .d-side { display: grid; align-content: start; gap: 30px; grid-row: 2; }
  .d-main { grid-column: 1; padding: 0 28px 0 22px; }
  .d-side { grid-column: 2; padding: 0 22px; border-left: 1px solid rgba(120, 220, 255, 0.1); }
  .d-foot { grid-column: 1 / -1; grid-row: 3; margin-top: 22px; }   /* 段を明示する（スクショの無い作品で、空いた1段目へ詰められないように） */

  /* レール上の節（点・深度・公開日）と、カードの左端へ伸ばす横の線。押すとその作品まで潜る */
  /* 節は絵の縦の中央に置く。絵の高さ＝頭部の幅 × 絵の列の割合 × 9/16 なので、頭部の幅（100cqw）から計算する */
  .log-head { container-type: inline-size; }
  .log-node {
    position: absolute; top: calc(100cqw * 1.08 / 2.08 * 9 / 32 - 28px); left: calc(-1 * var(--rail) - 1px); width: calc(var(--rail) + 1px); height: 56px; padding: 0;
    display: flex; align-items: center; border: 0; background: none; text-align: left; cursor: pointer;
  }
  .log--hero .log-node { top: calc(100cqw * 1.83 / 2.83 * 9 / 32 - 28px); }
  .log-node-dot { flex: none; width: 14px; height: 14px; margin-left: 9px; border-radius: 50%; border: 2px solid var(--aqua); background: #03182b; box-shadow: 0 0 0 3px rgba(2, 12, 24, 0.9); transition: background-color 0.2s, box-shadow 0.2s; }
  .log-node-text { display: grid; margin-left: 8px; padding: 2px 6px; border-radius: 6px; background: rgba(2, 12, 24, 0.85); }
  .log-node-text b { font: 700 15px/1.2 var(--mono); color: var(--aqua); }
  .log-node-text time { font: 500 10px/1.3 var(--mono); color: var(--muted); }
  .log-node-line { flex: 1 1 auto; height: 2px; margin-left: 4px; background: linear-gradient(90deg, rgba(95, 243, 255, 0.2), rgba(95, 243, 255, 0.55)); }
  .log-node:hover .log-node-text b { color: #fff; }
  .log.is-current .log-node-dot { background: var(--aqua); box-shadow: 0 0 0 3px rgba(2, 12, 24, 0.9), 0 0 14px rgba(95, 243, 255, 0.85); }
  .log.is-current .log-node-line { background: var(--aqua); }
}

@media (prefers-reduced-motion: reduce) {
  .rays i, .bubbles i, .wave, .glints i, .jotai.is-shiver { animation: none !important; }
  .bubbles { display: none; }
  html.is-entered .log, .d-in, .toc-panel { animation: none !important; }
  .fab, .btn, .log-kv .kv { transition: none; }
}

/* ==========================================================================
   サブページ：404（not_found.html）、DX版の認証ゲート（_auth.html）、認証後のクッション（supporters/auth/ の index.html）
   body に class="page" を付けたページにだけ効く。トップページの body には class が無いので、この節はトップページに当たらない。
   トップページと同じ言葉（色の変数、.btn、.d-h の見出し、.surface の水面と .waves の波）を使う。
   認証ページは保護されたフォルダの中の単一 HTML なので、画像やフォントのファイルを保護の中に置かない（AGENTS.md）。
   ========================================================================== */
.page {
  --accent: var(--aqua);        /* 印の色。404 はアクア、DX版のページ（.page--dx）はピンク */
  --accent-text: #bdeaf8;       /* 印の色の文字（背景に直接載せても 4.5:1 以上） */
  --page-col: 560px;            /* 本文の列の最大幅 */
  --page-side: 16px;            /* 左右の余白 */
  display: flex; flex-direction: column; min-height: 100vh; background: #020a15;
}
.page--dx { --accent: var(--pink); --accent-text: #ffb8de; }
/* 背景の海（固定）：水面近くの紺から、下へ向かって深い紺へ。浅いところにだけ光の筋 */
.page::before, .page::after { content: ''; position: fixed; z-index: -1; pointer-events: none; }
.page::before { inset: 0; background: radial-gradient(900px 420px at 50% -8%, rgba(120, 225, 255, 0.16), transparent 70%), linear-gradient(180deg, #0c3d60 0%, #07294a 30%, #041a31 62%, #020a15 100%); }
.page::after {
  left: 0; right: 0; top: 0; height: 80vh;
  background:
    linear-gradient(104deg, transparent 10%, rgba(170, 238, 255, 0.05) 14%, rgba(210, 248, 255, 0.1) 16.5%, rgba(170, 238, 255, 0.05) 19%, transparent 23%),
    linear-gradient(110deg, transparent 40%, rgba(170, 238, 255, 0.04) 44%, rgba(210, 248, 255, 0.08) 47%, rgba(170, 238, 255, 0.04) 50%, transparent 54%),
    linear-gradient(100deg, transparent 68%, rgba(170, 238, 255, 0.04) 71%, rgba(210, 248, 255, 0.07) 73%, rgba(170, 238, 255, 0.04) 75%, transparent 78%);
  -webkit-mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.5) 45%, transparent 92%); mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.5) 45%, transparent 92%);
}
.page-top-inner, .page-main, .page-foot { width: min(var(--page-col), 100% - 2 * var(--page-side)); margin: 0 auto; }

/* ヘッダー＝水面。トップページと同じ .surface と .waves を使い、題字だけを置く（押すとトップページへ） */
.page-top { flex: none; }
.page-top-inner { padding: 2px 0 8px; }
.page-top .brand { display: inline-flex; align-items: center; min-height: 44px; line-height: 1.2; text-decoration: none; }
.page-top .brand:hover, .page-top .brand:focus-visible { color: #fff; }

/* 本文の列 */
.page-main { flex: 1 0 auto; padding: 48px 0 56px; display: grid; gap: 28px; align-content: start; }
.page-head { display: grid; gap: 10px; }
.page-head > *, .page-box > *, .page-sec > * { margin: 0; }
/* 頭の一行（英字のラベルと日本語）。左の点が印の色 */
.page-kicker { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; font-size: 13px; line-height: 1.5; color: var(--accent-text); }
.page-kicker::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.page-kicker .en { font: 700 12px/1.5 var(--mono); letter-spacing: 0.2em; }
.page-title { font: 800 clamp(26px, 7vw, 36px)/1.3 var(--round); letter-spacing: 0.02em; color: #fff; overflow-wrap: anywhere; text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35); }
.page-lead { font-size: 16px; line-height: 1.8; color: #e2f2ff; }
.page-text { font-size: 15px; line-height: 1.85; color: #cfe3f3; }

/* 404 の大きな番号 */
.page-code { font: 700 clamp(96px, 30vw, 160px)/0.9 var(--mono); letter-spacing: 0.02em; color: var(--foam); text-shadow: 0 0 30px rgba(95, 243, 255, 0.45); }

/* 枠：DX版のページはトップページの DX版の枠と同じピンクの淡い塗り */
.page-box {
  display: grid; gap: 16px; padding: 20px 16px;
  border: 1px solid rgba(120, 220, 255, 0.24); border-radius: var(--radius); background: rgba(3, 16, 30, 0.82); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.32);
}
.page--dx .page-box { border-color: rgba(255, 111, 191, 0.4); background: linear-gradient(180deg, rgba(255, 111, 191, 0.13), rgba(255, 111, 191, 0.04)), rgba(3, 14, 28, 0.86); }
.page-thanks { font-size: 15px; line-height: 1.9; color: #ffeaf5; }

/* 大きなボタン（トップページの .btn を大きくしたもの）。幅いっぱいで押しやすく */
.page-acts { margin: 0; display: flex; }
.page .btn-lg { width: 100%; min-height: 54px; padding: 8px 20px; gap: 10px; font-family: var(--round); font-size: 17px; letter-spacing: 0.06em; }
.page-acts .btn-lg { flex: 1 1 auto; }
.page .btn-lg .i-play { border-left-width: 10px; border-top-width: 6px; border-bottom-width: 6px; }
/* ピンクの塗りのボタン（DX版）：トップページの DX版だけの作品の BOOTH ボタンと同じ色 */
.page .btn-pink { color: #2a0017; border-color: #ff8fcb; background: linear-gradient(180deg, #ffa3d6, #ff5fb4); box-shadow: 0 0 22px rgba(255, 111, 191, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.55); }
.page .btn-pink:hover, .page .btn-pink:focus-visible { box-shadow: 0 0 34px rgba(255, 111, 191, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.55); }
/* 戻る向きの矢印 */
.page .btn-back::before { content: ''; width: 8px; height: 8px; margin-right: 2px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }

/* 認証ゲートのフォーム。form と input の属性は Nekoweb の保護が使うので、HTML 側では見た目の class 以外を変えない */
.page .auth-error:empty { display: none; }   /* Nekoweb の SSI（error）の出力が空のときは出さない */
.page .auth-error { padding: 12px 14px; border: 1px solid rgba(255, 138, 160, 0.6); border-radius: 12px; background: rgba(255, 80, 120, 0.14); font-size: 15px; line-height: 1.7; color: #ffe0e8; }
.page .auth-form { display: grid; gap: 10px; }
.page .auth-form label { font: 700 12px/1.5 var(--mono); letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent-text); }
.page .auth-form input[type="password"] {
  width: 100%; min-height: 54px; margin: 0; padding: 0 16px;
  border: 1px solid rgba(255, 143, 203, 0.55); border-radius: 12px; background: rgba(2, 8, 18, 0.9);
  color: #fff; font: 500 18px/1.2 var(--mono); letter-spacing: 0.12em;
}
.page .auth-form input[type="password"]::placeholder { font-family: var(--body); font-size: 15px; letter-spacing: 0.02em; color: #9fc0d8; opacity: 1; }
.page .auth-form input[type="password"]:focus { outline: none; border-color: #ff8fcb; box-shadow: 0 0 0 3px rgba(255, 111, 191, 0.28), 0 0 22px rgba(255, 111, 191, 0.2); }
.page .auth-form .btn-lg { margin-top: 8px; }

/* 認証を通ったあとの一言（アクア＝通れた、の印） */
.page-status { display: inline-flex; align-items: center; gap: 10px; justify-self: start; min-height: 34px; padding: 0 14px 0 12px; border: 1px solid rgba(95, 243, 255, 0.45); border-radius: 999px; background: rgba(95, 243, 255, 0.1); font-size: 15px; color: #d9fbff; }
.page-status::before { content: ''; width: 10px; height: 5px; margin-top: -3px; border-left: 2px solid var(--aqua); border-bottom: 2px solid var(--aqua); transform: rotate(-45deg); }

/* 注意書きの一覧。見出しはトップページの詳細と同じ .d-h（左の縦線を印の色にする） */
.page .d-h { font-size: 15px; color: var(--accent-text); }
.page .d-h::before { background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.page--dx .d-h::after { background: linear-gradient(90deg, rgba(255, 143, 203, 0.35), transparent); }
.page-notes { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.page-notes li { position: relative; padding-left: 16px; font-size: 15px; line-height: 1.8; color: #cfe3f3; }
.page-notes li::before { content: ''; position: absolute; left: 2px; top: calc(0.9em - 3px); width: 6px; height: 6px; border-radius: 50%; background: var(--accent); opacity: 0.85; }
.page-notes strong { font-family: var(--round); font-weight: 700; color: #fff; }
.page-box .page-notes { padding-top: 14px; border-top: 1px dashed rgba(255, 143, 203, 0.3); }
.page-box .page-notes li { color: #c3d9ea; }

/* フッター（作者） */
.page-foot { flex: none; padding: 12px 0 24px; border-top: 1px solid rgba(120, 220, 255, 0.14); font-size: 14px; color: #9fc0d8; }
.page-foot p { margin: 0; display: flex; flex-wrap: wrap; align-items: center; }
.page-foot a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 8px; color: #cfe3f3; }

/* 700px〜：列を少し広げ、上の余白を画面の高さに合わせる。404 のボタンは幅を決める */
@media (min-width: 700px) {
  .page { --page-col: 600px; --page-side: 24px; }
  .page-top-inner { padding-top: 8px; }
  .page-main { padding: 9vh 0 72px; gap: 32px; }
  .page-box { padding: 24px 24px 26px; }
  .page-lead { font-size: 17px; }
  .page-acts .btn-lg { flex: 0 1 360px; }
}
