/* ⚡ フラッシュ暗算アドベンチャー：羊皮紙・金の ボタン・木の 札 を コードで 描く（絵は 背景と キャラだけ） */
:root { --navy: #16305c; --gold: #d4a017; --gold2: #f3cf5c; --parch: #f6e7c1; --parch2: #ead08f; --wood: #7a4a1f; --ink: #3a2a14; --red: #c0392b; --green: #1f8a4c; }
* { box-sizing: border-box; }
html, body { margin: 0; }
body.adv { background: radial-gradient(ellipse at top, #2a4f8c, #0f2244 70%); color: var(--ink); min-height: 100vh;
  font-family: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "BIZ UDPGothic", "Meiryo", sans-serif; -webkit-tap-highlight-color: transparent; }
.hidden { display: none !important; }
.wrap { max-width: 880px; margin: 0 auto; padding: 12px 12px 30px; }
button { font-family: inherit; }

/* 共通の 部品 */
.parch { background: linear-gradient(180deg, var(--parch), var(--parch2)); border: 3px solid var(--wood); border-radius: 16px;
  box-shadow: inset 0 0 0 3px #f9efd4, inset 0 0 24px rgba(122,74,31,.35), 0 8px 24px rgba(0,0,0,.35); }
.gbtn { display: inline-block; font-weight: 900; font-size: 22px; padding: 14px 40px; border: 3px solid #8a5a0c; border-radius: 999px; cursor: pointer;
  background: linear-gradient(180deg, #ffe38a, var(--gold2) 40%, var(--gold)); color: #4a2c00; box-shadow: 0 5px 0 #8a5a0c, 0 8px 18px rgba(0,0,0,.3);
  text-shadow: 0 1px 0 #fff3c4; touch-action: manipulation; text-decoration: none; }
.gbtn:active { transform: translateY(4px); box-shadow: 0 1px 0 #8a5a0c; }
.gbtn.sm { font-size: 16px; padding: 10px 22px; }
.gbtn.ghost { background: linear-gradient(180deg, #fffaf0, #efe2c2); }
.wbtn { font-weight: 800; font-size: 14px; padding: 8px 14px; border-radius: 12px; border: 2px solid #5a3510; background: linear-gradient(180deg, #a86a32, var(--wood)); color: #fff4dc; cursor: pointer; }
.ribbon { display: inline-block; background: linear-gradient(180deg, #2f5da8, var(--navy)); color: #fff; font-weight: 900; padding: 6px 18px; border-radius: 10px; border: 2px solid #f3cf5c; box-shadow: 0 3px 0 #0b1a33; }
.shake { animation: shake .35s; }
@keyframes shake { 20% { transform: translateX(-6px); } 40% { transform: translateX(6px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(4px); } }

/* ① タイトル */
.ti { position: relative; border-radius: 20px; overflow: hidden; min-height: min(78vh, 560px); background: url(../assets/adventure/title.jpg) 30% center/cover; box-shadow: 0 10px 30px rgba(0,0,0,.4); }
.ti::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,25,60,.05), rgba(10,25,60,.55)); }
.ti-in { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; padding: 26px 14px; text-align: center; }
.logo { font-size: clamp(40px, 11vw, 76px); font-weight: 900; line-height: .95; letter-spacing: 1px;
  background: linear-gradient(180deg, #fff6c9, #ffd84a 45%, #d99a0b 55%, #ffe38a); -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-text-stroke: 2px #6b3d00; filter: drop-shadow(0 4px 0 #3d2200) drop-shadow(0 8px 14px rgba(0,0,0,.45)); }
.logo-ja { color: #fff; font-weight: 900; font-size: 16px; margin-top: 6px; text-shadow: 0 2px 4px rgba(0,0,0,.6); }
.ti-sub { margin: 10px 0 0; }
.ti-chars { display: flex; align-items: flex-end; justify-content: center; gap: 4px; margin: 14px 0 6px; }
.ti-chars .hero { height: min(34vw, 190px); filter: drop-shadow(0 6px 8px rgba(0,0,0,.4)); animation: bob 2.4s ease-in-out infinite; }
.ti-chars .solo { height: min(30vw, 170px); filter: drop-shadow(0 6px 8px rgba(0,0,0,.4)); animation: bob 2.4s ease-in-out .6s infinite; }
@keyframes bob { 50% { transform: translateY(-8px); } }
.ti-snd { color: #fff; font-size: 14px; margin-top: 12px; display: inline-flex; gap: 6px; align-items: center; text-shadow: 0 1px 3px #000; }

/* ② おはなし */
.st { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px; }
.st-row { display: flex; align-items: flex-end; gap: 10px; width: 100%; }
.st-king { width: min(40vw, 220px); filter: drop-shadow(0 6px 10px rgba(0,0,0,.4)); }
.st-bub { flex: 1; padding: 24px 16px 14px; font-size: 17px; line-height: 1.8; font-weight: 800; position: relative; }
.st-name { position: absolute; top: -16px; left: 14px; font-size: 13px; }

/* ③ マップ */
.mp-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.mp-lead { color: #fff; font-weight: 800; font-size: 14px; text-shadow: 0 1px 3px #000; margin: 4px 0 10px; }
.mp-board { position: relative; width: 100%; aspect-ratio: 3 / 2; border-radius: 20px; overflow: hidden; border: 4px solid var(--wood);
  background: url(../assets/adventure/map.jpg) center/cover, #2a7fc0; box-shadow: inset 0 0 30px rgba(0,0,0,.3), 0 10px 30px rgba(0,0,0,.4); }
.mp-path { position: absolute; inset: 0; width: 100%; height: 100%; }
.mp-path polyline { fill: none; stroke: #fff6d6; stroke-width: .9; stroke-dasharray: 2 1.6; stroke-linecap: round; opacity: .9; }
.mp-spot { position: absolute; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 2px; background: none; border: none; cursor: pointer; padding: 0; }
.mp-pic { width: clamp(64px, 16vw, 110px); aspect-ratio: 1; border-radius: 50%; background: center/cover; border: 4px solid #ffe38a; box-shadow: 0 0 0 3px var(--wood), 0 6px 14px rgba(0,0,0,.45); }
.mp-spot.locked .mp-pic { filter: grayscale(.85) brightness(.7); border-color: #bbb; }
.mp-name { background: linear-gradient(180deg, var(--parch), var(--parch2)); border: 2px solid var(--wood); border-radius: 10px; padding: 2px 8px; font-weight: 900; font-size: clamp(11px, 2.8vw, 14px); white-space: nowrap; color: var(--ink); }
.mp-name b { display: inline-block; background: var(--navy); color: #fff; border-radius: 50%; width: 1.5em; height: 1.5em; line-height: 1.5em; text-align: center; margin-right: 4px; }
/* せまい 画面では 🔒 だけ（「まえの 場所の ボスを たおすと ひらく」は 押すと 下に 出る）。長い 文が 地図から はみ出して 名前に かぶっていた（2026-10-03 点検 A19） */
@media (max-width: 640px) { .mp-lk { display: none; } }
.mp-msg { text-align: center; margin: 8px 0 0; min-height: 1.4em; }
.mp-stars { font-size: 11px; font-weight: 800; color: #fff; text-shadow: 0 1px 3px #000; white-space: nowrap; }

/* ④ ステージ（町の 絵の 道の 上に 札・2026-09-28） */
.sg-wrap { position: relative; }
.sg-map { position: relative; width: 100%; aspect-ratio: 3 / 2; border-radius: 20px; overflow: hidden; border: 4px solid var(--wood);
  background: 50% 50% / cover no-repeat, #2a7fc0; box-shadow: 0 10px 30px rgba(0,0,0,.45); }   /* 絵は 場所ごとに JS が 入れる（area.stg） */
.sg-map.wide { aspect-ratio: 16 / 9; }   /* 専用の 絵が まだ ない 場所（クエストの 横長の 背景） */
.sg-road { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.sg-road polyline { fill: none; stroke: #fff6d6; stroke-width: 1.1; stroke-dasharray: 1.6 1.4; stroke-linecap: round; opacity: .95; filter: drop-shadow(0 0 2px rgba(0,0,0,.7)); vector-effect: non-scaling-stroke; stroke-width: 5px; }
.sg-head-w { position: absolute; top: 2.5%; left: 2.5%; right: 26%; display: flex; justify-content: space-between; align-items: flex-start; pointer-events: none; }
.sg-titlebox { max-width: 44%; padding: 8px 12px 7px; text-align: center; }
.sg-titlebox .sg-title { white-space: nowrap; font-size: clamp(15px, 2.1vw, 24px); padding: 4px 14px; }
.sg-sub { font-size: clamp(9px, 1.05vw, 13px); font-weight: 800; color: #6b4a1a; margin-top: 4px; }
.sg-head-w > * { pointer-events: auto; }
.sg-head-n { display: none; }
.sg-title { font-size: clamp(18px, 2.6vw, 26px); }
.sg-cell { position: absolute; transform: translate(-50%, -50%); width: 5.6%; min-width: 46px; background: none; border: none; padding: 0; cursor: pointer; color: #fff; }
.sg-lab { position: absolute; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; align-items: flex-start; gap: 2px; white-space: nowrap; }
.sg-cell.lab-r .sg-lab { left: 108%; }
.sg-cell.lab-l .sg-lab { right: 108%; align-items: flex-end; }
.sg-ring { width: 100%; aspect-ratio: 1; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 30%, #5f9df0, #1f4a9a 70%); border: 4px solid #ffe38a; box-shadow: 0 0 0 3px #2b4c8c, 0 5px 10px rgba(0,0,0,.5); }
.sg-ring b { font-size: clamp(18px, 2vw, 28px); font-weight: 900; color: #fff; text-shadow: 0 2px 0 #12305c; }
.sg-ring img { height: 72%; filter: drop-shadow(0 0 6px #d9a6ff); }
.sg-star { background: rgba(10,25,60,.85); border-radius: 999px; padding: 1px 6px; font-size: clamp(10px, 1.2vw, 13px); color: #ffd23f; letter-spacing: -1px; line-height: 1.3; }
.sg-star i { color: #7d8aa8; font-style: normal; }
.sg-cell small { font-size: clamp(9px, 1vw, 12px); font-weight: 900; color: #fff; background: rgba(10,25,60,.85); border-radius: 999px; padding: 1px 7px; white-space: nowrap; line-height: 1.3; }
.sg-cell.locked .sg-ring { background: radial-gradient(circle at 35% 30%, #8f8f8f, #4a4a4a 70%); border-color: #bdbdbd; box-shadow: 0 0 0 3px #333, 0 4px 8px rgba(0,0,0,.5); }
.sg-cell.locked .sg-ring b { font-size: clamp(14px, 1.5vw, 20px); }
.sg-cell.done .sg-ring { background: radial-gradient(circle at 35% 30%, #ffe27a, #d99a0b 70%); border-color: #fff6c9; box-shadow: 0 0 0 3px #a06a00, 0 5px 10px rgba(0,0,0,.5); }
.sg-cell.done .sg-ring b { color: #4a2c00; text-shadow: 0 1px 0 #fff3c4; }
.sg-cell.next .sg-ring { animation: glow 1.4s ease-in-out infinite; }
@keyframes glow { 50% { box-shadow: 0 0 0 3px #2b4c8c, 0 0 28px 10px rgba(255,230,120,.95); } }
.sg-cell.boss .sg-ring { background: radial-gradient(circle at 35% 30%, #b04cff, #4a1a80 70%); border-color: #ffd23f; box-shadow: 0 0 0 3px #2a0d4a, 0 5px 10px rgba(0,0,0,.5); }
.sg-side { position: absolute; top: 2.5%; right: 2%; width: 23%; display: flex; flex-direction: column; gap: 2.2%; }
.sd { padding: 20px 8px 8px; text-align: center; position: relative; font-size: clamp(10px, 1.1vw, 14px); line-height: 1.45; }
.sd-h { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: clamp(10px, 1.2vw, 14px); padding: 3px 10px; }
.sd-h.dark { background: linear-gradient(180deg, #2b3f66, #14213d); } .sd-h.red { background: linear-gradient(180deg, #d9532b, #a8331a); }
.sd-big { font-size: clamp(20px, 2.4vw, 32px); font-weight: 900; color: var(--ink); }
.sd-stars { font-size: clamp(16px, 2vw, 26px); color: #f2b705; text-shadow: 0 1px 0 #8a5a0c; } .sd-stars i { color: #cdbb8f; font-style: normal; text-shadow: none; }
.sd-sub { font-weight: 800; color: #6b4a1a; margin: 0 0 4px; }
.sd .gbtn.sm { font-size: clamp(13px, 1.5vw, 17px); padding: 8px 14px; }
.sd-row { display: flex; align-items: center; gap: 6px; text-align: left; font-weight: 800; }
.sd-row img { width: 26%; }
.sd-dots { display: flex; gap: 3px; margin-top: 4px; } .sd-dots i { flex: 1; height: 8px; border-radius: 4px; background: #cdbb8f; } .sd-dots i.on { background: linear-gradient(90deg, #ffd23f, #e8a200); }
.sd-ms { list-style: none; margin: 0; padding: 0; text-align: left; font-weight: 800; }
.sd-ms li { display: flex; gap: 5px; align-items: center; padding: 2px 0; color: #7a5a2a; } .sd-ms li.on { color: var(--ink); }
.sd-gift { font-weight: 900; color: var(--green); margin-top: 4px; }
.sd-streak { padding: 6px 8px; font-weight: 900; color: #7a2a0a; background: linear-gradient(180deg, #ffe0b8, #f2b56a); }
.sd-fire { letter-spacing: 1px; } .sd-fire i { font-style: normal; filter: grayscale(1) opacity(.45); } .sd-fire i.on { filter: none; }
.sg-msg { font-size: 12px; font-weight: 800; margin: 0; color: #ffe38a; text-shadow: 0 1px 3px #000; text-align: center; }
@media (max-width: 760px) {
  /* 2026-10-03 点検 A19：スマホで 札の 字が 9〜10px だった */
  .sg-star { font-size: 11px; }
  .sg-cell small { font-size: 11px; }
  .sg-head-w { display: none; }
  .sg-head-n { display: flex; }
  .sg-map { aspect-ratio: auto; height: min(74vh, 620px); }
  .sg-cell { width: 9.5%; min-width: 44px; }
  .sg-side { position: static; width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 10px; margin-top: 18px; }
  .sd { font-size: 13px; } .sd-h { font-size: 12px; } .sd-big { font-size: 26px; }
  .sg-msg { grid-column: 1 / -1; }
}

/* ⑤ プレイ */
.pl-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 8px; color: #fff; }
.pl-chip { background: rgba(10,25,60,.75); border: 2px solid #f3cf5c; border-radius: 12px; padding: 4px 10px; font-weight: 900; font-size: 14px; white-space: nowrap; }
.pl-chip b { font-size: 18px; color: #ffe38a; }
.pl-scene { position: relative; aspect-ratio: 16 / 10; border-radius: 18px; overflow: hidden; border: 4px solid var(--wood); box-shadow: 0 10px 30px rgba(0,0,0,.45); background: #0f2244; }
.pl-bg { position: absolute; inset: 0; background: center/cover; transition: opacity .6s; }
.pl-scene.boss::after { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 40%, rgba(0,0,0,0), rgba(20,0,40,.35)); pointer-events: none; }
.pl-scene.flash::before { content: ""; position: absolute; inset: 0; z-index: 5; background: radial-gradient(circle, rgba(255,240,170,.75), transparent 70%); animation: fade .6s forwards; pointer-events: none; }
@keyframes fade { to { opacity: 0; } }
.pl-stage { position: absolute; top: 8px; left: 8px; z-index: 3; }
.pl-quit { position: absolute; top: 8px; right: 8px; z-index: 6; font-size: 12px; padding: 6px 10px; }
.pl-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 3; }
.pl-plaque { min-width: 44%; min-height: 40%; display: flex; align-items: center; justify-content: center; border-radius: 16px; font-weight: 900; font-variant-numeric: tabular-nums;
  font-size: clamp(56px, 16vw, 120px); color: #4a2c00; background: linear-gradient(180deg, #fff7dc, #f3d98f); border: 5px solid #b07a22;
  box-shadow: 0 0 0 4px #ffe9a8, 0 0 30px rgba(255,210,90,.8), 0 10px 20px rgba(0,0,0,.4); }
.pl-plaque.sig { background: rgba(10,25,60,.8); border-color: #2d4675; box-shadow: 0 10px 20px rgba(0,0,0,.4); }
.pl-plaque.ask { color: #b07a22; }
.pl-plaque.pop { animation: pop .12s ease-out; }
@keyframes pop { from { transform: scale(.85); } to { transform: scale(1); } }
.pl-cap { color: #fff; font-weight: 900; text-shadow: 0 2px 4px #000; margin-top: 6px; min-height: 20px; }
.sig3 { display: flex; gap: 12px; padding: 10px 14px; }
.sig3 i { width: clamp(38px, 10vw, 58px); aspect-ratio: 1; border-radius: 50%; background: #2b3a55; display: block; }
.sig3 i.r.on { background: #ff4d4d; box-shadow: 0 0 20px #ff4d4d; } .sig3 i.y.on { background: #ffd23f; box-shadow: 0 0 20px #ffd23f; } .sig3 i.g.on { background: #3ee07a; box-shadow: 0 0 24px #3ee07a; }
.pl-hero { position: absolute; left: 2%; bottom: 0; height: 46%; z-index: 4; filter: drop-shadow(0 4px 6px rgba(0,0,0,.5)); }
.pl-solo { position: absolute; right: 2%; bottom: 0; height: 40%; z-index: 4; filter: drop-shadow(0 4px 6px rgba(0,0,0,.5)); }
.pl-boss { position: absolute; top: 6%; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; flex-direction: column; align-items: center; width: 40%; }
.pl-boss img { height: min(30vw, 190px); max-width: 60vw; object-fit: contain; filter: drop-shadow(0 0 16px rgba(190,90,255,.9)); animation: bob 2s ease-in-out infinite; }
.pl-boss img.hit { animation: hit .45s; }
@keyframes hit { 0% { filter: brightness(3); transform: translateX(0); } 30% { transform: translateX(-10px) rotate(-8deg); } 60% { transform: translateX(10px) rotate(6deg); } 100% { filter: drop-shadow(0 0 16px rgba(190,90,255,.9)); } }
.pl-hp { width: 100%; height: 10px; background: #2a1440; border: 2px solid #c9a2ff; border-radius: 6px; overflow: hidden; }
.pl-hp i { display: block; height: 100%; background: linear-gradient(90deg, #ff4d88, #ff9a3c); transition: width .4s; }
.pl-scene.boss .pl-center { justify-content: flex-end; padding-bottom: 6%; }
.pl-scene.boss .pl-plaque { min-height: 34%; font-size: clamp(48px, 13vw, 100px); }
.pl-banner { position: absolute; top: 40%; left: 50%; z-index: 7; transform: translate(-50%, -50%) scale(.6); opacity: 0; font-size: clamp(34px, 9vw, 64px); font-weight: 900; white-space: nowrap; pointer-events: none;
  -webkit-text-stroke: 2px #5a2d00; }
.pl-banner.ok { color: #ffd84a; text-shadow: 0 4px 0 #8a4b00, 0 0 24px rgba(255,210,80,.9); }
.pl-banner.ng { color: #9fd3ff; -webkit-text-stroke: 2px #12305c; text-shadow: 0 4px 0 #0b1a33; }
.pl-banner.show { animation: ban 1s forwards; }
@keyframes ban { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.5); } 20% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); } 35% { transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -70%) scale(1); } }
.pl-fx { position: absolute; inset: 0; z-index: 6; pointer-events: none; overflow: hidden; }
.fx { position: absolute; font-size: 26px; animation: fx 1.1s ease-out forwards; }
@keyframes fx { 0% { transform: translate(0, 0) scale(.6); opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)) scale(1.1) rotate(200deg); opacity: 0; } }
.pl-timerbox { height: 10px; background: rgba(255,255,255,.25); border-radius: 6px; overflow: hidden; margin: 8px 2px 0; }
.pl-timer { height: 100%; width: 100%; background: linear-gradient(90deg, #3ee07a, #ffd23f, #ff6b4d); }
.pl-ask { padding: 10px 10px 12px; margin-top: 10px; text-align: center; }
.pl-q { font-size: 20px; font-weight: 900; margin-bottom: 8px; }
.pl-choices { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pl-ch { position: relative; font-size: clamp(24px, 6.5vw, 36px); font-weight: 900; padding: 12px 4px; border-radius: 14px; border: 3px solid #b07a22; background: linear-gradient(180deg, #ffffff, #f4ecd8);
  color: var(--navy); box-shadow: 0 4px 0 #8a5a0c; cursor: pointer; font-variant-numeric: tabular-nums; touch-action: manipulation; }
.pl-ch small { position: absolute; top: 3px; left: 7px; font-size: 11px; color: #b09a70; }
.pl-ch:active { transform: translateY(3px); box-shadow: 0 1px 0 #8a5a0c; }
.pl-ch.right { background: linear-gradient(180deg, #d9ffe6, #8fe3ad); border-color: var(--green); }
.pl-ch.bad { background: linear-gradient(180deg, #ffe0dc, #ffb0a6); border-color: var(--red); }
.pl-review { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px; margin-top: 10px; min-height: 8px; }
.pl-review .rv { background: linear-gradient(180deg, #fff7dc, #f3d98f); border: 2px solid #b07a22; border-radius: 8px; padding: 2px 8px; font-weight: 900; font-size: 18px; color: #4a2c00; }
.pl-review .rv.ans { background: linear-gradient(180deg, #d9ffe6, #8fe3ad); border-color: var(--green); }
.pl-review i { font-style: normal; font-weight: 900; color: #6b4a1a; }
@media (max-width: 560px) { .pl-choices { grid-template-columns: repeat(2, 1fr); } }
/* スマホ（せまい 画面）：プレイ画面を 画面いっぱいに して 数を 大きく（2026-09-28 ユーザー「スマホだと 小さくて 没入感が ない」） */
@media (max-width: 640px) {
  body.adv.playing { overflow: hidden; }
  body.adv.playing .foot { display: none; }
  #scPlay { position: fixed; inset: 0; z-index: 50; display: flex; flex-direction: column; background: radial-gradient(ellipse at top, #2a4f8c, #0f2244 70%);
    padding: calc(6px + env(safe-area-inset-top)) 6px calc(6px + env(safe-area-inset-bottom)); }
  #scPlay .pl-top { margin: 0 0 6px; }
  #scPlay .pl-scene { flex: 1; min-height: 0; aspect-ratio: auto; border-radius: 14px; border-width: 3px; }
  #scPlay .pl-plaque { min-width: 72%; min-height: 30%; font-size: min(34vw, 30vh); border-radius: 22px; }
  #scPlay .pl-scene.boss .pl-plaque { min-height: 26%; font-size: min(26vw, 22vh); }
  #scPlay .pl-cap { font-size: 18px; }
  #scPlay .sig3 i { width: 16vw; }
  #scPlay .pl-hero { height: 30%; }
  #scPlay .pl-solo { height: 26%; }
  #scPlay .pl-boss { width: 60%; top: 3%; }
  #scPlay .pl-boss img { height: min(46vw, 24vh); max-width: 70vw; }
  #scPlay .pl-banner { font-size: 12vw; }
  #scPlay .pl-scene.boss .pl-center { justify-content: center; padding: 30% 0 0; }
  #scPlay .pl-scene.boss .pl-hero { height: 22%; }
  #scPlay .pl-scene.boss .pl-solo { height: 19%; }
  #scPlay .pl-timerbox { margin: 6px 2px 0; }
  #scPlay .pl-ask { margin-top: 6px; padding: 8px 8px 10px; }
  #scPlay .pl-q { font-size: 18px; margin-bottom: 6px; }
  #scPlay .pl-choices { gap: 8px; }
  #scPlay .pl-ch { font-size: 34px; padding: 14px 4px; }
  #scPlay .pl-review { margin-top: 6px; }
  #scPlay .pl-review .rv { font-size: 16px; }
}

/* ⑥ 結果 */
.rs { padding: 18px 14px; text-align: center; position: relative; }
.rs-title { font-size: clamp(28px, 7vw, 42px); font-weight: 900; margin: 0; -webkit-text-stroke: 1px #5a2d00; }
.rs-title.ok { color: #e8a200; text-shadow: 0 3px 0 #7a4300; }
.rs-title.ng { color: #2f5da8; -webkit-text-stroke: 1px #0b1a33; }
.rs-mid { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 10px 0; flex-wrap: wrap; }
.rs-chest { width: 110px; filter: drop-shadow(0 6px 8px rgba(0,0,0,.35)); }
.rs-rank { width: 96px; height: 96px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 60px; font-weight: 900; color: #fff;
  border: 5px solid #f3cf5c; box-shadow: 0 0 0 4px #8a5a0c, 0 6px 14px rgba(0,0,0,.35); }
.rs-rank.rS { background: radial-gradient(circle at 35% 30%, #fff1a8, #e0a800 60%, #a06a00); color: #6b3d00; }
.rs-rank.rA { background: radial-gradient(circle at 35% 30%, #ffd1d1, #e0503c 60%, #8f2518); }
.rs-rank.rB { background: radial-gradient(circle at 35% 30%, #cfe4ff, #3f74c0 60%, #1f4486); }
.rs-rank.rC { background: radial-gradient(circle at 35% 30%, #e6e6e6, #8a8a8a 60%, #555); }
.rs-solo { width: 110px; }
.rs-stars { font-size: 36px; color: #f2b705; letter-spacing: 2px; text-shadow: 0 2px 0 #8a5a0c; }
.rs-stars i { color: #cdbb8f; font-style: normal; text-shadow: none; }
.rs-rows { margin: 8px auto; border-collapse: collapse; min-width: 240px; font-size: 16px; }
.rs-rows th { text-align: left; padding: 4px 12px; color: #7a5a2a; font-weight: 800; }
.rs-rows td { text-align: right; padding: 4px 12px; font-weight: 900; font-variant-numeric: tabular-nums; }
.rs-rows b { font-size: 24px; color: var(--navy); }
.rs-done { font-weight: 900; color: var(--green); min-height: 4px; }
.rs-btns { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 10px; }
.rs-cta { display: block; margin: 16px auto 4px; padding: 12px 14px; border-radius: 14px; background: var(--navy); color: #fff; font-weight: 900; text-decoration: none; font-size: 15px; }
.rs-note { font-size: 12px; color: #7a5a2a; }
.ti-contest { display: inline-block; margin-top: 8px; background: rgba(10,25,60,.8); color: #ffe38a; border: 2px solid #f3cf5c; border-radius: 999px; padding: 4px 14px; font-weight: 900; font-size: 13px; text-decoration: none; }
.rs-code { margin: 8px auto; padding: 8px 12px; background: #fffaf0; border: 2px dashed #d4a017; border-radius: 12px; font-weight: 800; max-width: 420px; }
.rs-code b { font-size: 22px; letter-spacing: 2px; color: #16305c; }
.ti-cont { color: #ffe38a; font-weight: 900; font-size: 13px; text-shadow: 0 1px 3px #000; margin: 6px 0 0; min-height: 1.2em; }
/* 上の 青い 所の「メイン画面に もどる」（2026-09-29） */
.topbar { margin: 0 0 10px; }
.home-btn { display: inline-block; font-weight: 900; font-size: 15px; padding: 9px 16px; border-radius: 999px; text-decoration: none;
  background: #fff; color: var(--navy); border: 2px solid #f3cf5c; box-shadow: 0 3px 0 #0b1a33, 0 6px 14px rgba(0,0,0,.3); touch-action: manipulation; }
.home-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #0b1a33; }
body.adv.playing .topbar { display: none; }
.foot { text-align: center; color: #c9d6ee; font-size: 12px; margin-top: 14px; }
.foot a { color: #c9d6ee; }
.pl-hero.jump { animation: jump .5s ease-out; }
@keyframes jump { 40% { transform: translateY(-22%); } 100% { transform: translateY(0); } }
.pl-hero.shake { animation: shake .4s; }
/* マップの ピン（新しい 地図・2026-09-28） */
.mp-pin { font-size: clamp(22px, 5.5vw, 34px); line-height: 1; filter: drop-shadow(0 3px 3px rgba(0,0,0,.5)); }
.mp-spot.now .mp-pin { animation: bob 1.6s ease-in-out infinite; }
.mp-spot.locked .mp-name { filter: grayscale(.6); opacity: .85; }
.mp-spot.open .mp-name { box-shadow: 0 0 0 3px #ffe38a, 0 0 16px rgba(255,220,100,.9); }
