/* ============ タガルの軌跡 スタイル ============ */
:root {
  --accent: #e8894a;
  --accent2: #6fb3a5;
  --gold: #ffd48a;
  --ink: #f5f1ea;
  --ink-dim: #c9c2b8;
  --box: rgba(18, 16, 30, .82);
  --box-line: rgba(255, 212, 138, .35);
  --font: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Hiragino Sans", sans-serif;
  --font-title: "Kaisei Decol", "Hiragino Mincho ProN", serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; background: #07060d; overflow: hidden; }
body { font-family: var(--font); color: var(--ink); -webkit-font-smoothing: antialiased; user-select: none; -webkit-user-select: none; touch-action: manipulation; }
button { font-family: inherit; cursor: pointer; }

#viewport { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; }
#stage { position: relative; width: 1280px; height: 720px; flex: none; overflow: hidden; background: #000; transform-origin: center center; }
.layer { position: absolute; inset: 0; }
.layer svg { width: 100%; height: 100%; display: block; }
#bg2 { opacity: 0; transition: opacity 1s ease; }
#fx { pointer-events: none; }
#tone { pointer-events: none; transition: background .8s, opacity .8s; mix-blend-mode: multiply; opacity: 0; }
#tone.past { background: #b99a6e; opacity: .55; mix-blend-mode: color; }
#tone.dark { background: #1a1630; opacity: .55; }
#tone.warm { background: #ffb36b; opacity: .18; mix-blend-mode: soft-light; }
#spot { pointer-events: none; }

.hidden { display: none !important; }

/* 星のまたたき */
.tw { animation: tw 3.2s ease-in-out infinite; }
@keyframes tw { 0%,100% { opacity: .25 } 50% { opacity: 1 } }
.blink { animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0 } }

/* ---------- 会話ウィンドウ ---------- */
#textbox {
  position: absolute; left: 40px; right: 40px; bottom: 58px; height: 190px;
  background: var(--box); border: 1.5px solid var(--box-line); border-radius: 18px;
  padding: 34px 44px 24px 44px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 10px 40px rgba(0,0,0,.45), inset 0 0 0 1px rgba(255,255,255,.04);
  cursor: pointer;
}
#textbox.withface { padding-left: 226px; }
#face { position: absolute; left: 26px; bottom: 22px; width: 172px; height: 172px; display: none; }
#textbox.withface #face { display: block; }
#faceInner { width: 100%; height: 100%; border-radius: 16px; overflow: hidden; border: 2px solid var(--gold); background: #1c1a2c; box-shadow: 0 6px 18px rgba(0,0,0,.4); transition: filter .4s, transform .4s; position: relative; }
#faceInner img { width: 100%; height: 100%; object-fit: cover; display: block; }
#faceInner .glyph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 64px; font-weight: 700; color: #fff; }
#faceInner.f-sad { filter: saturate(.45) brightness(.8) hue-rotate(10deg); }
#faceInner.f-past { filter: sepia(.7) saturate(.6); }
#faceInner.f-think { transform: rotate(-3deg); }
#faceInner.f-shock { animation: shake .35s; }
#faceInner.f-smile::after, #faceInner.f-shine::after { content: "✦"; position: absolute; right: 8px; top: 4px; color: var(--gold); font-size: 26px; text-shadow: 0 0 10px #fff; animation: tw 1.6s infinite; }
#face.young #faceInner img { transform: scale(1.18) translateY(6%); }

#nameplate {
  position: absolute; top: -20px; left: 36px; padding: 6px 22px; border-radius: 10px;
  background: #221d33; border: 1.5px solid var(--gold); color: var(--gold);
  font-weight: 700; font-size: 22px; letter-spacing: .08em; display: none;
}
#textbox.withface #nameplate { left: 218px; }
#nameplate.show { display: block; }
#text { font-size: 27px; line-height: 1.75; letter-spacing: .04em; white-space: pre-wrap; text-shadow: 0 1px 2px rgba(0,0,0,.5); }
#text.narr { color: #e7e2f5; }
#text em { font-style: normal; color: var(--gold); font-weight: 700; }
#text b { color: #9fe3d6; font-weight: 700; }
#nextmark { position: absolute; right: 26px; bottom: 16px; color: var(--gold); font-size: 18px; animation: bob 1s ease-in-out infinite; opacity: 0; }
#nextmark.on { opacity: 1; }
@keyframes bob { 50% { transform: translateY(5px); } }

/* ---------- 選択肢 ---------- */
#choices { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; background: rgba(5, 4, 12, .45); padding-bottom: 150px; }
#choices .prompt { font-size: 26px; color: var(--gold); margin-bottom: 8px; text-shadow: 0 2px 8px #000; letter-spacing: .06em; }
#choices button {
  width: 760px; padding: 20px 30px; font-size: 25px; color: var(--ink); text-align: left;
  background: rgba(24, 20, 40, .9); border: 1.5px solid rgba(255,255,255,.18); border-radius: 12px;
  transition: transform .15s, border-color .15s, background .15s; line-height: 1.5;
}
#choices button:hover, #choices button:focus-visible { transform: translateX(8px); border-color: var(--gold); background: rgba(48, 36, 60, .95); outline: none; }
#choices button::before { content: "◆"; color: var(--accent); margin-right: 14px; font-size: 18px; vertical-align: 2px; }

/* ---------- 画面下メニュー ---------- */
#menubar { position: absolute; right: 44px; bottom: 14px; display: flex; gap: 8px; }
#menubar button { background: rgba(18,16,30,.7); color: var(--ink-dim); border: 1px solid rgba(255,255,255,.15); border-radius: 8px; padding: 6px 16px; font-size: 17px; }
#menubar button:hover { color: var(--gold); border-color: var(--gold); }
#menubar button.on { color: #1a1426; background: var(--gold); border-color: var(--gold); }

/* ---------- オーバーレイ（章タイトル・かけら獲得） ---------- */
#overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; z-index: 20; }
.chapter-card { text-align: center; animation: chIn 3.4s ease forwards; }
.chapter-card .no { font-size: 26px; letter-spacing: .5em; color: var(--gold); margin-bottom: 18px; }
.chapter-card .ttl { font-family: var(--font-title); font-size: 64px; letter-spacing: .12em; text-shadow: 0 4px 20px rgba(0,0,0,.6); }
.chapter-card .sub { margin-top: 20px; font-size: 22px; color: var(--ink-dim); letter-spacing: .2em; }
.chapter-card .line { width: 0; height: 2px; margin: 26px auto 0; background: linear-gradient(90deg, transparent, var(--gold), transparent); animation: lineGrow 1.6s .4s ease forwards; }
@keyframes lineGrow { to { width: 520px; } }
@keyframes chIn { 0% { opacity: 0; transform: translateY(14px); } 18% { opacity: 1; transform: none; } 82% { opacity: 1; } 100% { opacity: 0; } }
#overlay.dim { background: rgba(0,0,0,.72); }

.card-get { width: 620px; padding: 40px 48px 34px; border-radius: 22px; text-align: center; position: relative;
  background: radial-gradient(circle at 50% 0%, rgba(255,212,138,.22), transparent 60%), #16122a;
  border: 2px solid var(--gold); box-shadow: 0 0 60px rgba(255, 212, 138, .35); animation: pop .6s cubic-bezier(.2,1.4,.4,1); }
.card-get .lbl { color: var(--gold); letter-spacing: .3em; font-size: 18px; }
.card-get .ttl { font-family: var(--font-title); font-size: 38px; margin: 14px 0 18px; }
.card-get .q { font-size: 23px; line-height: 1.8; color: #efe9ff; }
.card-get .src { margin-top: 16px; font-size: 15px; color: var(--ink-dim); }
.card-get .tap { margin-top: 22px; font-size: 16px; color: var(--ink-dim); animation: tw 1.6s infinite; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }

/* 実際の選択の表示 */
.reveal { width: 760px; padding: 30px 40px; border-radius: 18px; background: #16122a; border: 1.5px solid var(--accent2); text-align: center; animation: pop .5s ease; }
.reveal .lbl { color: var(--accent2); font-size: 18px; letter-spacing: .25em; }
.reveal .pick { font-size: 26px; margin: 14px 0; line-height: 1.6; }
.reveal .why { font-size: 20px; color: var(--ink-dim); line-height: 1.8; text-align: left; }
.reveal .sync { margin-top: 16px; font-size: 20px; color: var(--gold); }
.reveal .tap { margin-top: 14px; font-size: 16px; color: var(--ink-dim); animation: tw 1.6s infinite; }

#toast { position: absolute; top: 24px; left: 50%; transform: translate(-50%, -80px); background: rgba(22,18,42,.95); border: 1px solid var(--gold); padding: 10px 26px; border-radius: 10px; font-size: 19px; color: var(--gold); transition: transform .4s; z-index: 30; pointer-events: none; }
#toast.on { transform: translate(-50%, 0); }

/* ---------- タイトル ---------- */
.screen { position: absolute; inset: 0; z-index: 40; }
#title { background: #0a0918; overflow: hidden; }
.title-sky { position: absolute; inset: 0; }
.title-inner { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding-bottom: 40px; }
.title-pre { letter-spacing: .6em; font-size: 16px; color: var(--ink-dim); margin-bottom: 18px; opacity: 0; animation: fadeUp 1.2s .3s forwards; }
.title-logo { font-family: var(--font-title); font-size: 104px; font-weight: 700; letter-spacing: .1em; text-shadow: 0 0 40px rgba(255, 200, 120, .45), 0 6px 30px rgba(0,0,0,.6); opacity: 0; animation: fadeUp 1.6s .6s forwards; }
.title-logo span { background: linear-gradient(180deg, #fff6df, #ffc98a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.title-sub { margin-top: 16px; font-size: 21px; color: #e2dcf0; letter-spacing: .1em; opacity: 0; animation: fadeUp 1.4s 1.2s forwards; }
.title-buttons { margin-top: 52px; display: flex; flex-direction: column; gap: 12px; opacity: 0; animation: fadeUp 1.2s 1.8s forwards; }
.title-buttons button { width: 300px; padding: 13px; font-size: 22px; letter-spacing: .2em; color: var(--ink); background: rgba(20,18,36,.55); border: 1px solid rgba(255,212,138,.35); border-radius: 10px; transition: all .2s; }
.title-buttons button:hover, .title-buttons button:focus-visible { background: rgba(255,212,138,.14); border-color: var(--gold); color: var(--gold); outline: none; }
.title-buttons button:disabled { opacity: .3; cursor: default; }
.title-foot { position: absolute; bottom: 20px; width: 100%; text-align: center; font-size: 14px; color: #8d86a3; letter-spacing: .08em; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ---------- モーダル ---------- */
#modal { position: fixed; inset: 0; background: rgba(4,3,10,.78); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 16px; }
#modalBox { position: relative; width: min(860px, 100%); max-height: 90vh; overflow: auto; background: #14111f; border: 1.5px solid var(--box-line); border-radius: 16px; padding: 32px 30px 26px; color: var(--ink); font-size: 17px; line-height: 1.8; -webkit-overflow-scrolling: touch; }
#modalClose { position: absolute; top: 10px; right: 14px; background: none; border: none; color: var(--ink-dim); font-size: 30px; line-height: 1; }
#modalBody h2 { font-family: var(--font-title); color: var(--gold); font-size: 26px; margin-bottom: 14px; letter-spacing: .08em; }
#modalBody h3 { color: var(--accent2); font-size: 18px; margin: 18px 0 6px; }
#modalBody .log-line { padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
#modalBody .log-line .who { color: var(--gold); font-weight: 700; margin-right: 8px; }
#modalBody .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
#modalBody .kcard { padding: 14px 16px; border-radius: 12px; background: #1e1930; border: 1px solid rgba(255,212,138,.3); }
#modalBody .kcard .t { color: var(--gold); font-weight: 700; margin-bottom: 4px; }
#modalBody .kcard .q { font-size: 15px; line-height: 1.7; }
#modalBody .kcard .s { font-size: 12px; color: var(--ink-dim); margin-top: 6px; }
#modalBody .kcard.locked { opacity: .35; border-style: dashed; }
#modalBody .kcard.locked .q { filter: blur(3px); }
#modalBody .row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,.07); }
#modalBody .seg button { background: #221d33; color: var(--ink-dim); border: 1px solid rgba(255,255,255,.15); padding: 6px 14px; font-size: 15px; }
#modalBody .seg button:first-child { border-radius: 8px 0 0 8px; }
#modalBody .seg button:last-child { border-radius: 0 8px 8px 0; }
#modalBody .seg button.on { background: var(--gold); color: #1a1426; }
#modalBody .btn { background: #221d33; color: var(--ink); border: 1px solid var(--box-line); border-radius: 8px; padding: 10px 18px; font-size: 16px; margin: 4px 6px 4px 0; }
#modalBody .btn:hover { border-color: var(--gold); color: var(--gold); }
#modalBody .chap { display: block; width: 100%; text-align: left; margin: 0 0 8px; }
#modalBody .chap small { color: var(--ink-dim); margin-left: 8px; }
#modalBody .muted { color: var(--ink-dim); font-size: 14px; }

/* ---------- ミニゲーム ---------- */
#game { position: absolute; inset: 0; z-index: 15; display: flex; align-items: center; justify-content: center; background: rgba(6,5,14,.55); }
.mg { width: 1060px; padding: 34px 44px; border-radius: 20px; background: rgba(20,17,36,.95); border: 1.5px solid var(--box-line); box-shadow: 0 20px 60px rgba(0,0,0,.5); animation: pop .5s ease; }
.mg .mg-lbl { color: var(--accent2); letter-spacing: .3em; font-size: 17px; }
.mg .mg-q { font-size: 27px; margin: 10px 0 24px; line-height: 1.6; }
.mg .mg-hint { font-size: 18px; color: var(--ink-dim); margin-top: 16px; min-height: 28px; }
.mg .sentence { font-size: 34px; line-height: 2; text-align: center; padding: 18px; border-radius: 14px; background: rgba(255,255,255,.04); margin-bottom: 26px; font-family: var(--font-title); }
.mg .blank { display: inline-block; min-width: 150px; padding: 0 16px; margin: 0 6px; border-bottom: 3px solid var(--gold); color: var(--gold); cursor: pointer; text-align: center; transition: background .2s; border-radius: 6px 6px 0 0; }
.mg .blank.empty { color: transparent; }
.mg .blank.active { background: rgba(255,212,138,.15); }
.mg .pool { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.mg .tile { font-size: 25px; padding: 12px 24px; border-radius: 12px; background: #2a2340; color: var(--ink); border: 1.5px solid rgba(255,255,255,.2); transition: transform .15s, opacity .2s; }
.mg .tile:hover { transform: translateY(-3px); border-color: var(--gold); }
.mg .tile.used { opacity: .25; pointer-events: none; }
.mg .actions { display: flex; justify-content: center; gap: 14px; margin-top: 26px; }
.mg .go { font-size: 22px; padding: 12px 40px; border-radius: 12px; background: var(--accent); color: #1a1020; border: none; font-weight: 700; letter-spacing: .1em; }
.mg .go:disabled { opacity: .35; cursor: default; }
.mg .sub { font-size: 20px; padding: 12px 26px; border-radius: 12px; background: transparent; color: var(--ink-dim); border: 1px solid rgba(255,255,255,.2); }
.mg .result { text-align: center; font-size: 24px; line-height: 1.8; margin-top: 10px; }
.mg .result .big { font-family: var(--font-title); font-size: 36px; color: var(--gold); display: block; margin-bottom: 8px; }

/* 手放すゲーム */
.mg .items { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.mg .item { font-size: 21px; padding: 16px 14px; border-radius: 12px; background: #2a2340; border: 1.5px solid rgba(255,255,255,.2); color: var(--ink); line-height: 1.4; transition: all .25s; min-height: 76px; }
.mg .item.off { opacity: .35; transform: scale(.94); background: #1a1626; border-style: dashed; text-decoration: line-through; }
.mg .counter { text-align: center; font-size: 20px; color: var(--gold); margin-top: 16px; }

/* 話を聞くゲーム（ホットスポット） */
#hotspots { z-index: 12; pointer-events: none; }
.hs { position: absolute; width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%; pointer-events: auto; cursor: pointer; background: radial-gradient(circle, rgba(255,212,138,.55), rgba(255,212,138,0) 70%); animation: pulse 1.6s ease-in-out infinite; border: none; }
.hs.done { animation: none; background: radial-gradient(circle, rgba(111,179,165,.4), rgba(111,179,165,0) 70%); }
.hs span { position: absolute; top: -34px; left: 50%; transform: translateX(-50%); white-space: nowrap; background: rgba(20,17,36,.9); color: var(--gold); font-size: 17px; padding: 3px 12px; border-radius: 8px; border: 1px solid var(--box-line); }
@keyframes pulse { 50% { transform: scale(1.15); } }
.hs-guide { position: absolute; top: 26px; left: 50%; transform: translateX(-50%); background: rgba(20,17,36,.9); padding: 10px 26px; border-radius: 12px; font-size: 21px; color: var(--ink); border: 1px solid var(--box-line); z-index: 13; }

/* ---------- エンディング ---------- */
.ending { width: 900px; text-align: center; animation: pop .8s ease; }
.ending .lbl { letter-spacing: .5em; color: var(--gold); font-size: 20px; }
.ending .ttl { font-family: var(--font-title); font-size: 58px; margin: 16px 0 26px; text-shadow: 0 0 30px rgba(255,200,120,.5); }
.ending .stats { display: flex; justify-content: center; gap: 22px; margin-bottom: 26px; }
.ending .stat { padding: 18px 26px; border-radius: 14px; background: rgba(20,17,36,.85); border: 1px solid var(--box-line); min-width: 220px; }
.ending .stat .v { font-size: 44px; font-weight: 700; color: var(--gold); }
.ending .stat .k { font-size: 16px; color: var(--ink-dim); }
.ending .msg { font-size: 22px; line-height: 1.9; background: rgba(20,17,36,.8); padding: 22px 30px; border-radius: 14px; }
.ending .btns { margin-top: 24px; display: flex; gap: 12px; justify-content: center; }
.ending .btns button { font-size: 19px; padding: 11px 26px; border-radius: 10px; background: rgba(20,17,36,.85); color: var(--ink); border: 1px solid var(--gold); }

/* 画面ゆれ・フラッシュ */
.shake { animation: shake .5s; }
@keyframes shake { 10%,90% { transform: translateX(-2px); } 20%,80% { transform: translateX(4px); } 30%,50%,70% { transform: translateX(-8px); } 40%,60% { transform: translateX(8px); } }
#flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; z-index: 25; }
#flash.on { animation: flash .9s ease; }
@keyframes flash { 0% { opacity: 0; } 15% { opacity: .9; } 100% { opacity: 0; } }

/* 大きな一言（キャッチ） */
.bigword { font-family: var(--font-title); font-size: 60px; text-align: center; line-height: 1.6; letter-spacing: .08em; padding: 0 60px; text-shadow: 0 0 30px rgba(255,200,120,.6), 0 4px 20px #000; animation: bigIn 1.2s ease; }
.bigword small { display: block; font-family: var(--font); font-size: 22px; color: var(--ink-dim); margin-top: 18px; letter-spacing: .1em; }
@keyframes bigIn { from { opacity: 0; letter-spacing: .4em; filter: blur(6px); } to { opacity: 1; filter: none; } }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01s !important; animation-iteration-count: 1 !important; transition-duration: .01s !important; }
}

.flame { transform-origin: 0 0; animation: flame .9s ease-in-out infinite alternate; }
@keyframes flame { from { transform: scaleY(1) skewX(-2deg); } to { transform: scaleY(1.08) skewX(3deg); } }

/* ひとことを書くゲーム */
.mg textarea { width: 100%; height: 120px; font-family: var(--font); font-size: 24px; padding: 14px 18px; border-radius: 12px; border: 1.5px solid var(--box-line); background: #1e1930; color: var(--ink); resize: none; line-height: 1.6; user-select: text; -webkit-user-select: text; }
.mg textarea:focus { outline: none; border-color: var(--gold); }
.mg .examples { font-size: 17px; color: var(--ink-dim); margin-top: 10px; line-height: 1.8; }
.ending .mine { margin: 0 auto 20px; max-width: 760px; padding: 16px 24px; border-radius: 14px; border: 1.5px dashed var(--gold); font-size: 22px; line-height: 1.7; }
.ending .mine small { display: block; font-size: 14px; color: var(--ink-dim); margin-bottom: 4px; letter-spacing: .2em; }

/* 縦画面のときのお願い */
#rotate { position: fixed; inset: 0; z-index: 200; background: rgba(6,5,14,.94); display: none; align-items: center; justify-content: center; text-align: center; padding: 24px; color: var(--ink); font-size: 18px; line-height: 1.9; }
#rotate b { color: var(--gold); font-size: 22px; display: block; margin-bottom: 8px; }
#rotate button { margin-top: 18px; background: none; border: 1px solid var(--box-line); color: var(--ink-dim); padding: 8px 18px; border-radius: 8px; font-size: 15px; }
@media (orientation: portrait) and (max-width: 700px) { #rotate.can { display: flex; } }
.reveal .why b { color: #9fe3d6; }
.ending .end-face { width: 120px; height: 120px; margin: 0 auto 14px; border-radius: 50%; overflow: hidden; border: 3px solid var(--gold); box-shadow: 0 0 40px rgba(255,212,138,.55); }
.ending .end-face img { width: 100%; height: 100%; object-fit: cover; }
.ending .ttl { margin: 8px 0 20px; }
.ending .mine { background: rgba(20,17,36,.85); }

/* 大きな顔（大事な場面） */
#portrait { pointer-events: none; display: flex; align-items: center; justify-content: center; padding-bottom: 200px; opacity: 0; transition: opacity .8s ease; }
#portrait.on { opacity: 1; }
#portrait .pf { width: 300px; height: 300px; border-radius: 50%; overflow: hidden; border: 4px solid var(--gold); box-shadow: 0 0 0 10px rgba(255,212,138,.12), 0 0 80px rgba(255,212,138,.5); transform: scale(.92); transition: transform 1.2s ease; }
#portrait.on .pf { transform: none; }
#portrait .pf img { width: 100%; height: 100%; object-fit: cover; }
#portrait .pf-past img { filter: sepia(.7) saturate(.6); }
#portrait .pf-sad img { filter: saturate(.5) brightness(.8); }
#modalBody .tls { border-left: 2px solid rgba(255,212,138,.35); padding-left: 18px; }
#modalBody .tl { position: relative; padding: 8px 0; display: flex; gap: 14px; }
#modalBody .tl::before { content: ""; position: absolute; left: -25px; top: 16px; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }
#modalBody .tl .d { flex: none; width: 110px; color: var(--gold); font-size: 14px; padding-top: 2px; }
#modalBody .tl.locked { opacity: .35; }
#modalBody .tl.locked::before { background: #555; }
@media (max-width: 600px) { #modalBody .tl { flex-direction: column; gap: 2px; } }
.title-buttons { margin-top: 34px; gap: 10px; display: grid; grid-template-columns: 300px 300px; }
.title-buttons button { padding: 12px; font-size: 21px; }
.title-buttons #btnNew { grid-column: 1 / 3; width: 612px; font-size: 24px; padding: 15px; border-color: var(--gold); color: var(--gold); }
.title-buttons #btnOpt { grid-column: 1 / 3; justify-self: center; width: auto; padding: 6px 20px; font-size: 16px; letter-spacing: .15em; background: none; border: none; color: var(--ink-dim); }
.title-buttons #btnOpt:hover { color: var(--gold); }
.title-sky { pointer-events: none; }
.title-inner { padding-bottom: 20px; }
.ending .credit { margin-top: 18px; font-size: 14px; color: var(--ink-dim); letter-spacing: .06em; }
/* エンディングを720pxに収める */
.ending .end-face { width: 88px; height: 88px; margin-bottom: 8px; }
.ending .lbl { font-size: 16px; }
.ending .ttl { font-size: 46px; margin: 4px 0 14px; }
.ending .stats { margin-bottom: 14px; gap: 16px; }
.ending .stat { padding: 10px 22px; min-width: 200px; }
.ending .stat .v { font-size: 34px; }
.ending .stat .k { font-size: 14px; }
.ending .mine { margin-bottom: 12px; padding: 10px 20px; font-size: 19px; }
.ending .msg { font-size: 19px; line-height: 1.8; padding: 14px 24px; background: rgba(20,17,36,.92); }
.ending .btns { margin-top: 14px; }
.ending .btns button { font-size: 17px; padding: 9px 22px; }
.ending .credit { margin-top: 10px; font-size: 13px; }
/* ライト版／じっくり版 の2つのはじめ方 */
.title-buttons #btnLight { grid-column: 1 / 3; width: 612px; font-size: 24px; padding: 14px; border-color: var(--gold); color: var(--gold); background: rgba(255,212,138,.1); }
.title-buttons #btnNew { grid-column: 1 / 3; width: 612px; font-size: 20px; padding: 10px; border-color: rgba(255,212,138,.35); color: var(--ink); background: rgba(20,18,36,.55); }
.title-buttons button small { font-size: 15px; margin-left: 12px; letter-spacing: .1em; color: var(--ink-dim); }
.ending .msg .more { display: inline-block; margin-top: 6px; font-size: 16px; color: var(--gold); }

/* 公開版 */
.title-buttons #btnNew { font-size: 24px; padding: 14px; border-color: var(--gold); color: var(--gold); background: rgba(255,212,138,.1); }
.title-buttons [hidden] { display: none !important; }
.title-buttons #btnCont { grid-column: 1 / 3; width: 612px; }
.title-buttons #btnOpt { grid-column: 1; justify-self: end; }
.title-buttons #guideLink { grid-column: 2; justify-self: start; align-self: center; color: var(--ink-dim); font-size: 16px; letter-spacing: .15em; text-decoration: none; padding: 2px 16px; }
.title-buttons #guideLink:hover { color: var(--gold); }
