/* Starlight Princess Slot — "Castle in the Clouds": the game's own day sky, cloud edges, crown gold and free-spins pink */

@font-face { font-family: "Rounded"; src: url("fonts/m-plus-rounded-1c-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("fonts/figtree-400-800.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }

:root {
  --page: #ffffff;
  --sky-band: #e7efff;
  --dawn-band: #fdedf7;
  --night: #1a3299;
  --ink: #1d2760;
  --ink-strong: #131b4f;
  --muted: #4c5687;
  --faint: #5f6894;
  --royal: #2453d8;
  --royal-deep: #183aa8;
  --sky: #5c8ff5;
  --sky-pale: #eef3ff;
  --pink: #ec4fa6;
  --pink-ink: #c42b80;
  --lilac: #8a5cf0;
  --gold: #ffc83d;
  --gold-deep: #ffab1a;
  --gold-ink: #9a6400;
  --mint: #0c8a64;
  --line: #d9e2fb;
  --line-soft: #e7ecfb;
  --panel: #ffffff;
  --panel-2: #f2f6ff;
  --shadow: 0 12px 34px rgba(30, 70, 200, .10);
  --radius: 20px;
  --gutter: clamp(16px, 4vw, 40px);
  --head: "Rounded", "Figtree", system-ui, sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body { margin: 0; min-height: 100vh; overflow-x: hidden; font: 17px/1.65 var(--body); color: var(--ink); background: var(--page); }
img, svg, video, iframe { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--royal); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--pink-ink); }
:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; border-radius: 6px; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { font-family: var(--head); font-weight: 800; line-height: 1.15; margin: 0 0 .5em; letter-spacing: .005em; color: var(--ink-strong); }
h1 { font-size: clamp(38px, 6vw, 66px); }
h2 { font-size: clamp(27px, 3.4vw, 38px); }
h3 { font-size: clamp(20px, 2.1vw, 23px); }
h4 { font-size: 18px; }
ul, ol { padding-left: 1.25em; }
li { margin: .25em 0; }
strong, b { font-weight: 700; color: var(--ink-strong); }
small { font-size: .85em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 32px 0; }
table { border-collapse: collapse; width: 100%; }
.shell { width: min(1180px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.slim { width: min(1180px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.slim > * { max-width: 820px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--gold); color: var(--ink-strong); padding: 10px 16px; border-radius: 10px; font-weight: 800; }
.skip:focus { top: 12px; }
.muted { color: var(--muted); }
.gold { color: var(--gold-ink); }

/* Dark places (footer, game cards, demo cover) flip the text tokens to white. */
.colophon, .window, .demo-start, .invite { --ink: #ffffff; --ink-strong: #ffffff; --muted: #dbe3ff; --faint: #b4c1f0; --line: rgba(255, 255, 255, .22); --line-soft: rgba(255, 255, 255, .14); }

/* Cloud edge: a row of round bumps in --c, drawn on a pseudo element that sits on a section's top or bottom edge. */
.scene::after, main > .band::before, .colophon::before {
  content: ""; position: absolute; left: 0; right: 0; height: 30px; pointer-events: none;
  background:
    radial-gradient(circle at 50% 100%, var(--c) 0 21px, transparent 22px) 0 100% / 62px 26px repeat-x,
    radial-gradient(circle at 50% 100%, var(--c) 0 29px, transparent 30px) 34px 100% / 118px 30px repeat-x,
    linear-gradient(var(--c), var(--c)) 0 100% / 100% 7px no-repeat;
}

/* ---------- masthead ---------- */
.masthead { padding: 12px 0 0; position: relative; z-index: 20; background: #fff; }
.masthead-row { display: flex; align-items: center; gap: 18px; }
.mark { display: flex; align-items: center; gap: 10px; color: var(--ink-strong); text-decoration: none; font: 800 19px/1.05 var(--head); }
.mark svg { width: 38px; height: 38px; flex: none; filter: drop-shadow(0 3px 6px rgba(255, 150, 40, .35)); }
.mark small { display: block; font: 700 11px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--pink-ink); margin-top: 4px; }
.mark:hover { color: var(--royal); }
.topnav { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }
.topnav a { color: var(--royal-deep); text-decoration: none; font-weight: 800; font-size: 15px; padding: 8px 14px; border-radius: 99px; background: var(--sky-pale); border: 2px solid #d6e1ff; }
.topnav a:hover { border-color: var(--royal); color: var(--royal); }
.topnav a[aria-current="page"] { background: var(--royal); border-color: var(--royal); color: #fff; }
.masthead-play { flex: none; }
.menu-btn { display: none; margin-left: auto; align-items: center; gap: 8px; font: 800 15px/1 var(--body); color: #fff; background: var(--royal); border: 0; border-radius: 99px; padding: 11px 17px; cursor: pointer; box-shadow: 0 6px 16px rgba(36, 83, 216, .3); }
.menu-btn svg { width: 18px; height: 18px; }
.orbit { display: flex; gap: 10px; padding: 12px 0 15px; overflow-x: auto; scrollbar-width: none; margin: 0; list-style: none; }
.orbit::-webkit-scrollbar { display: none; }
.orbit li { margin: 0; flex: none; }
.orbit a { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--royal-deep); font-weight: 800; font-size: 14px; padding: 4px 16px 4px 4px; border-radius: 99px; background: #fff; border: 2px solid #cddafd; box-shadow: 0 3px 0 #cddafd; transition: transform .15s, box-shadow .15s; }
.orbit a:hover { border-color: var(--royal); box-shadow: 0 3px 0 var(--royal); color: var(--royal); transform: translateY(-1px); }
.orbit a[aria-current="page"] { border-color: var(--gold-deep); background: #fff7df; box-shadow: 0 3px 0 var(--gold-deep); }
.orbit img { width: 42px; height: 42px; object-fit: contain; border-radius: 50%; background: #fff; padding: 3px; box-shadow: 0 2px 6px rgba(30, 70, 200, .12); }

/* mobile sheet (popover) */
.sheet { margin: auto 0 0; width: 100%; max-width: none; max-height: 86vh; overflow: auto; border: 0; border-radius: 26px 26px 0 0; padding: 20px var(--gutter) 28px; background: #fff; color: var(--ink); box-shadow: 0 -20px 50px rgba(20, 40, 120, .25); }
.sheet::backdrop { background: rgba(16, 32, 110, .5); }
.sheet h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .12em; color: var(--pink-ink); margin: 18px 0 8px; font-family: var(--body); }
.sheet ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.sheet li { margin: 0; }
.sheet a { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; padding: 9px 10px; border-radius: 14px; background: var(--sky-pale); font-weight: 700; font-size: 15px; }
.sheet a img { width: 34px; height: 34px; object-fit: contain; }
.sheet-close { float: right; font: 800 14px/1 var(--body); color: #fff; background: var(--royal); border: 0; border-radius: 99px; padding: 10px 14px; cursor: pointer; }

/* ---------- breadcrumbs ---------- */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 4px 0 12px; font-size: 14px; color: var(--faint); }
.crumbs li { margin: 0; }
.crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--faint); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--royal); }

/* ---------- hero (scene): the game's sky, a cloud card for the words ---------- */
.scene {
  --c: var(--page);
  position: relative; isolation: isolate; overflow: hidden; padding: 40px 0 84px;
  background: #3a6fe6 url("/media/bg-starlight-princess.webp") center 38% / cover no-repeat;
  background-image: image-set(url("/media/bg-starlight-princess.avif") type("image/avif"), url("/media/bg-starlight-princess.webp") type("image/webp"));
}
.scene:has(+ .band) { --c: var(--sky-band); }
.scene::after { bottom: -1px; z-index: 2; }
.scene-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 34px; align-items: center; }
.scene-copy, .scene > .shell:not(.scene-grid) {
  position: relative; padding: clamp(22px, 3.2vw, 36px); border-radius: 30px;
  background: linear-gradient(90deg, #ff7cc0, #ffc83d 50%, #7aa7ff) top / 100% 6px no-repeat, rgba(255, 255, 255, .93);
  box-shadow: 0 26px 60px rgba(14, 36, 140, .28), inset 0 0 0 1px rgba(255, 255, 255, .9);
  backdrop-filter: blur(8px) saturate(1.2);
}
.scene > .shell:not(.scene-grid) { width: min(880px, 100% - 2 * var(--gutter)); }
.scene-copy > :last-child, .scene > .shell > :last-child { margin-bottom: 0; }
.kicker { display: flex; flex-wrap: wrap; gap: 4px 0; font-weight: 800; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--pink-ink); margin: 0 0 6px; }
.kicker span + span::before { content: "✦"; margin: 0 10px; color: var(--gold-deep); }
.scene h1 { margin: 6px 0 14px; }
.shine { background: linear-gradient(95deg, #f0479f 0%, #a24ff0 48%, #2f62e6 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.intro-text { font-size: 19px; color: var(--muted); max-width: 36em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; padding: 0; list-style: none; }
.chips li { margin: 0; padding: 8px 14px; border-radius: 16px; background: var(--sky-pale); border: 1px solid #d6e1ff; font-size: 14px; color: var(--muted); }
.chips b { display: block; font: 800 20px/1.15 var(--head); color: var(--royal-deep); }
.scene-art { position: relative; justify-self: center; text-align: center; }
.scene-art::before { content: ""; position: absolute; inset: 6% -8% 0; border-radius: 50%; z-index: -1; background: radial-gradient(circle, rgba(255, 255, 255, .75), rgba(255, 214, 240, .35) 42%, transparent 68%); }
.scene-art img { max-height: 560px; width: auto; margin-inline: auto; filter: drop-shadow(0 22px 28px rgba(16, 36, 130, .35)); }
.scene-art.logo-art img { max-height: 300px; }
.scene.edition { padding: 40px 0 84px; }
.scene.edition .backdrop { position: absolute; inset: 0; z-index: -1; }
.scene.edition .backdrop picture { display: block; height: 100%; }
.scene.edition .backdrop img { width: 100%; height: 100%; object-fit: cover; }
.whatsnew { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 8px; }
.whatsnew li { margin: 0; padding: 10px 14px 10px 44px; position: relative; background: var(--sky-pale); border-radius: 16px; }
.whatsnew li::before { content: "✦"; position: absolute; left: 16px; top: 9px; color: var(--gold-deep); font-size: 18px; }

/* ---------- buttons ---------- */
.ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.cta { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 54px; padding: 14px 26px; border-radius: 99px; font: 800 17px/1.1 var(--body); text-decoration: none; cursor: pointer; border: 0; transition: transform .12s, box-shadow .12s, filter .12s; }
.cta:active { transform: translateY(3px); }
.cta-gold { background: linear-gradient(180deg, #ffe88f 0%, var(--gold) 42%, var(--gold-deep) 100%); color: var(--ink-strong); box-shadow: inset 0 2px 0 rgba(255, 255, 255, .75), 0 5px 0 #d98700, 0 12px 26px rgba(255, 150, 10, .4); }
.cta-gold:hover { color: var(--ink-strong); filter: brightness(1.06); }
.cta-gold:active { box-shadow: inset 0 2px 0 rgba(255, 255, 255, .75), 0 2px 0 #d98700, 0 6px 14px rgba(255, 150, 10, .35); }
.cta-ghost { background: linear-gradient(180deg, #4c7df2, var(--royal)); color: #fff; box-shadow: inset 0 2px 0 rgba(255, 255, 255, .3), 0 5px 0 #15318f, 0 12px 24px rgba(36, 83, 216, .3); }
.cta-ghost:hover { color: #fff; filter: brightness(1.08); }
.cta-ghost:active { box-shadow: inset 0 2px 0 rgba(255, 255, 255, .3), 0 2px 0 #15318f; }
.cta-small { min-height: 44px; padding: 10px 18px; font-size: 15px; }
.cta svg { width: 18px; height: 18px; flex: none; }

/* ---------- bands & panels ---------- */
.band { padding: 52px 0; position: relative; }
.band-tight { padding: 24px 0; }
/* The hero is a <header>, so the bands count from 1: sky, white, dawn pink, sky... */
main > .band:nth-of-type(3n+1) { --c: var(--sky-band); background: var(--sky-band); }
main > .band:nth-of-type(3n+2) { --c: var(--page); background: var(--page); }
main > .band:nth-of-type(3n+3) { --c: var(--dawn-band); background: linear-gradient(180deg, var(--dawn-band), #f3ecff); }
main > .band::before { top: -29px; }
main > .scene + .band::before { display: none; }
.band > .shell > h2, .band > .slim > h2 { margin-bottom: 6px; }
.sub { color: var(--muted); margin: 0 0 24px; max-width: 48em; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.pad { padding: clamp(18px, 3vw, 28px); }
.copy { max-width: 46em; }
.copy h2 { margin-top: 1.6em; }
.copy h3 { margin-top: 1.4em; }
.copy > :first-child { margin-top: 0; }
.remark { padding: 14px 18px; border-radius: 16px; background: #fff; border: 2px solid #c9d8ff; border-left-width: 6px; color: var(--ink); margin: 0 0 1.2em; }
.remark-warm { background: #fffaf0; border-color: #ffd98a; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.cols-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }

/* 60-second cards */
.minute { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; list-style: none; margin: 0; padding: 0; }
.minute li { margin: 0; padding: 18px; }
.minute img { width: 60px; height: 60px; object-fit: contain; margin-bottom: 8px; }
.minute b { display: block; font: 800 18px/1.2 var(--head); margin-bottom: 4px; color: var(--ink-strong); }
.minute span { color: var(--muted); font-size: 15px; display: block; }

/* ---------- edition layout with sticky spec card ---------- */
.edition-grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 32px; align-items: start; padding-top: 10px; margin-bottom: 36px; }
.edition-main { min-width: 0; }
.edition-main > section { padding: 28px 0; border-top: 2px dotted var(--line); }
.edition-main > section:first-child { border-top: 0; padding-top: 0; }
.spec-card { position: sticky; top: 16px; }
.spec-card details > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.spec-card details > summary::-webkit-details-marker { display: none; }
.spec-card details > summary::after { content: "▾"; color: var(--royal); transition: transform .2s; }
.spec-card details[open] > summary::after { transform: rotate(180deg); }
.spec-card h2 { font-size: 20px; margin: 0; }
.spec-logo { width: 190px; margin: 4px auto 10px; }
.spec { margin: 12px 0 16px; display: grid; grid-template-columns: auto 1fr; gap: 0; font-size: 15px; }
.spec dt { color: var(--muted); padding: 7px 10px 7px 0; border-top: 1px solid var(--line-soft); }
.spec dd { margin: 0; padding: 7px 0; border-top: 1px solid var(--line-soft); text-align: right; font-weight: 700; color: var(--ink-strong); }
.spec-card .cta { width: 100%; margin-top: 8px; }

/* ---------- demo facade ---------- */
.demo { position: relative; border-radius: var(--radius); overflow: hidden; border: 4px solid #fff; background: #102066; aspect-ratio: 1200 / 831; box-shadow: 0 0 0 1px var(--line), 0 18px 40px rgba(20, 50, 160, .18); }
.demo picture, .demo img { width: 100%; height: 100%; object-fit: cover; }
.demo-start { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; text-decoration: none; color: #fff; background: radial-gradient(circle at center, rgba(16, 32, 110, .15), rgba(16, 32, 110, .7)); }
.demo-start .play-disc { width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(180deg, #ffe58a, var(--gold) 45%, var(--gold-deep)); color: var(--ink-strong); box-shadow: 0 0 0 10px rgba(255, 255, 255, .25), 0 18px 40px rgba(0, 0, 0, .4); transition: transform .2s; }
.demo-start .play-disc svg { width: 36px; height: 36px; margin-left: 5px; }
.demo-start:hover { color: #fff; }
.demo-start:hover .play-disc { transform: scale(1.06); }
.demo-start b { font: 800 20px/1.2 var(--head); text-shadow: 0 2px 10px rgba(0, 0, 0, .6); }
.demo-start span { font-size: 14px; color: #eef1ff; text-shadow: 0 2px 8px rgba(0, 0, 0, .7); }
.demo iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.demo-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-top: 10px; font-size: 14px; color: var(--faint); }
.demo-bar button { font: 800 14px/1 var(--body); color: var(--royal-deep); background: #fff; border: 2px solid var(--royal); border-radius: 99px; padding: 9px 15px; cursor: pointer; box-shadow: 0 3px 0 var(--royal); }
.demo-bar button[hidden] { display: none; }
.demo-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); gap: 22px 28px; }

/* ---------- replay ---------- */
.replay { padding: clamp(14px, 2.4vw, 22px); }
.replay-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 22px; align-items: center; }
.board { display: grid; grid-template-columns: repeat(var(--cols, 6), minmax(0, 1fr)); gap: 4px; padding: 10px; border-radius: 18px; background: linear-gradient(180deg, #7a46e2, #4524a6); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .25), 0 10px 26px rgba(70, 36, 166, .3); }
.board.pachi { --cols: 3; max-width: 420px; margin-inline: auto; }
.cell { aspect-ratio: 1; display: grid; place-items: center; border-radius: 10px; background: rgba(255, 255, 255, .1); position: relative; transition: background .25s, transform .25s, opacity .25s; }
.cell img { width: 86%; height: auto; }
.cell.win { background: rgba(140, 220, 255, .38); box-shadow: inset 0 0 0 2px #bff3ff; }
.cell.gone { opacity: .25; transform: scale(.85); }
.cell em { position: absolute; inset: auto 0 6%; text-align: center; font: 800 clamp(11px, 1.4vw, 16px)/1 var(--head); font-style: normal; color: #fff; text-shadow: 0 2px 0 #1c0b45, 0 0 6px #1c0b45; }
.cell.mini { background: rgba(10, 6, 40, .4); }
.replay-meta dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0 0 14px; }
.replay-meta dt { color: var(--muted); }
.replay-meta dd { margin: 0; font: 800 20px/1.2 var(--head); color: var(--ink-strong); }
.replay-meta .stage { font-weight: 700; color: var(--pink-ink); min-height: 1.6em; margin: 0 0 10px; }
.meter { height: 10px; border-radius: 99px; background: #e4eaff; overflow: hidden; margin: 4px 0 14px; }
.meter i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--pink), var(--gold)); transition: width .3s; }
.controls { display: flex; flex-wrap: wrap; gap: 8px; }
.controls button { font: 800 15px/1 var(--body); padding: 12px 18px; border-radius: 99px; border: 2px solid var(--royal); background: #fff; color: var(--royal-deep); cursor: pointer; box-shadow: 0 3px 0 var(--royal); }
.controls button:hover { background: var(--sky-pale); }
.controls button:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--royal); }
.controls button.primary { background: linear-gradient(180deg, #ffe88f, var(--gold) 42%, var(--gold-deep)); color: var(--ink-strong); border-color: #d98700; box-shadow: 0 3px 0 #d98700; }
.replay-log { margin-top: 16px; }
.replay-log summary { cursor: pointer; font-weight: 700; color: var(--royal); }
.no-js .controls, .no-js .replay-meta .meter { display: none; }

/* ---------- tables ---------- */
.scroll { overflow-x: auto; margin: 0 0 1.4em; border-radius: 18px; border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow); }
.ledger { font-size: 15px; min-width: 520px; }
.ledger caption { text-align: left; padding: 13px 16px; font: 800 17px/1.3 var(--head); color: var(--ink-strong); background: #fff; caption-side: top; }
.ledger th, .ledger td { padding: 10px 16px; text-align: left; border-top: 1px solid var(--line-soft); vertical-align: middle; }
.ledger thead th { background: var(--royal); color: #fff; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; border-top: 0; }
.ledger tbody tr:nth-child(even) { background: #f7f9ff; }
.ledger tbody tr:hover { background: #fff6fb; }
.ledger td.digits, .ledger th.digits { text-align: right; font-variant-numeric: tabular-nums; }
.ledger .glyph { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.ledger .glyph img { width: 40px; height: 40px; }
.ledger tr.best td { background: #fff4d6; }
.bet-input { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 12px; }
.bet-input label { font-weight: 700; }
input[type="number"], select { font: 700 16px/1.2 var(--body); color: var(--ink-strong); background: #fff; border: 2px solid #c9d7ff; border-radius: 12px; padding: 9px 12px; min-width: 0; }
input[type="number"]:focus, select:focus { border-color: var(--royal); outline: 0; }
input[type="number"] { width: 120px; }

/* ---------- lab tiles & charts ---------- */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; list-style: none; padding: 0; margin: 0 0 18px; }
.tiles li { margin: 0; padding: 18px 16px; text-align: center; }
.tiles b { display: block; font: 800 32px/1.05 var(--head); color: var(--pink-ink); margin-bottom: 6px; }
.tiles span { color: var(--muted); font-size: 14px; display: block; }
.graph { margin: 0 0 1.4em; padding: 14px 14px 10px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
.graph svg { width: 100%; height: auto; display: block; }
.graph figcaption, figure figcaption { font-size: 14px; color: var(--muted); margin-top: 8px; }
.bargraph text { fill: var(--muted); font: 600 12px var(--body); }
.bargraph .v { fill: var(--ink-strong); font-weight: 800; }

/* ---------- figures ---------- */
figure { margin: 0 0 1.4em; }
.frame { border-radius: 18px; overflow: hidden; border: 4px solid #fff; background: #102066; box-shadow: 0 0 0 1px var(--line), 0 14px 32px rgba(20, 50, 160, .16); }
.frame img { width: 100%; }
.frames { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.frames-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.handsets { display: flex; gap: 16px; overflow-x: auto; padding: 4px 2px 10px; }
.handsets figure { flex: 0 0 min(230px, 60%); margin: 0; }
.handsets .frame { border-radius: 26px; border: 5px solid var(--ink-strong); }

/* ---------- family windows ---------- */
.windows { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; list-style: none; padding: 0; margin: 0; }
.windows li { margin: 0; display: flex; }
.window { flex: 1; position: relative; display: grid; grid-template-rows: 150px 1fr auto; min-height: 310px; padding: 28px 16px 16px; color: #fff; text-decoration: none; border-radius: 120px 120px var(--radius) var(--radius); overflow: hidden; border: 4px solid #fff; isolation: isolate; box-shadow: 0 16px 34px rgba(20, 50, 160, .22); transition: transform .2s; }
.window > picture.bg, .window > picture.bg img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.window::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14, 26, 90, 0) 30%, rgba(14, 26, 90, .86)); }
.window > picture.wlogo { display: flex; align-items: center; justify-content: center; margin: 0 0 8px; }
.window .wlogo img { width: auto; max-width: 84%; max-height: 132px; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .4)); }
.window b { display: flex; align-items: flex-end; padding-top: 8px; font: 800 17px/1.2 var(--head); }
.window small { display: block; min-height: 3em; color: #e6ebff; font-size: 13px; line-height: 1.5; }
.window > picture.wlogo { height: 150px; }
.window:hover { color: #fff; transform: translateY(-3px); border-color: var(--gold); }

/* ---------- verdict ---------- */
.judgement { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.judgement h3 { display: flex; align-items: center; gap: 10px; }
.judgement ul { list-style: none; padding: 0; margin: 0; }
.judgement li { padding-left: 26px; position: relative; margin: .5em 0; }
.judgement .love { border-top: 5px solid var(--pink); }
.judgement .nope { border-top: 5px solid #9aa6d6; }
.judgement .love li::before { content: "♥"; position: absolute; left: 0; color: var(--pink); }
.judgement .nope li::before { content: "✕"; position: absolute; left: 2px; color: var(--faint); }
.rating { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: 16px; }
.rating-num { font: 800 54px/1 var(--head); color: var(--pink-ink); }
.rating-num small { font-size: 22px; color: var(--muted); }
.rating-list { list-style: none; padding: 0; margin: 0; flex: 1; min-width: 240px; display: grid; gap: 6px; }
.rating-list li { display: grid; grid-template-columns: 150px 1fr 34px; align-items: center; gap: 10px; margin: 0; font-size: 14px; color: var(--muted); }
.rating-list .track { height: 9px; border-radius: 99px; background: #e4eaff; overflow: hidden; }
.rating-list .track i { display: block; height: 100%; background: linear-gradient(90deg, var(--pink), var(--gold)); }
.rating-list b { text-align: right; color: var(--ink-strong); }

/* ---------- questions ---------- */
.qa details { border-bottom: 2px dotted var(--line); }
.qa summary { cursor: pointer; list-style: none; padding: 16px 40px 16px 0; position: relative; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; position: absolute; right: 4px; top: 13px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: var(--royal); color: #fff; font: 800 18px/1 var(--head); }
.qa details[open] summary::after { content: "–"; background: var(--pink); }
.qa summary h3 { display: inline; font-size: 18px; font-family: var(--body); font-weight: 700; }
.qa .answer { padding: 0 0 16px; color: var(--muted); }
.qa .answer p:last-child { margin: 0; }

/* ---------- hearts atlas ---------- */
.hearts { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; list-style: none; padding: 0; margin: 0 0 1.4em; }
.hearts li { margin: 0; text-align: center; padding: 12px 8px; }
.hearts .heart { position: relative; display: block; width: 76px; margin: 0 auto 6px; }
.hearts .heart em { position: absolute; inset: auto 0 22%; font: 800 17px/1 var(--head); font-style: normal; color: #fff; text-shadow: 0 2px 0 #1c0b45, 0 0 6px #1c0b45; }
.hearts small { display: block; color: var(--muted); }

/* ---------- tools ---------- */
.tool.panel { padding: clamp(18px, 3vw, 28px); }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin: 0 0 18px; }
.fields label { display: grid; gap: 6px; font-weight: 700; font-size: 15px; }
.fields input, .fields select { width: 100%; }
.out { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; list-style: none; padding: 0; margin: 0; }
.out li { margin: 0; padding: 14px; border-radius: 16px; background: var(--panel-2); }
.out b { display: block; font: 800 24px/1.1 var(--head); color: var(--royal-deep); }
.out span { font-size: 14px; color: var(--muted); }
.chips-pick { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.chips-pick button { font: 800 14px/1 var(--body); padding: 9px 12px; border-radius: 99px; border: 2px solid var(--royal); background: #fff; color: var(--royal-deep); cursor: pointer; box-shadow: 0 2px 0 var(--royal); }
.chips-pick button:hover { border-color: var(--pink); color: var(--pink-ink); }
.sim-track { display: grid; grid-template-columns: repeat(15, minmax(0, 1fr)); gap: 4px; margin: 14px 0; }
.sim-track span { aspect-ratio: 1; border-radius: 8px; background: var(--panel-2); display: grid; place-items: center; font: 800 11px/1 var(--body); color: var(--muted); }
.sim-track span.hit { background: var(--pink); color: #fff; }
.sim-track span.pay { background: var(--sky); color: #fff; }
.histo { display: grid; grid-template-columns: repeat(auto-fit, minmax(60px, 1fr)); align-items: end; gap: 6px; height: 170px; margin: 16px 0 4px; }
.histo div { display: grid; align-content: end; justify-items: center; gap: 4px; height: 100%; font-size: 12px; color: var(--muted); }
.histo i { display: block; width: 100%; border-radius: 8px 8px 2px 2px; background: linear-gradient(180deg, var(--gold), var(--pink)); min-height: 2px; }
.quiz fieldset { border: 2px solid var(--line); border-radius: 16px; padding: 14px 16px; margin: 0 0 12px; background: #fff; }
.quiz legend { font-weight: 800; padding: 0 6px; color: var(--ink-strong); }
.quiz label { display: flex; align-items: center; gap: 8px; margin: 6px 0; cursor: pointer; }
.quiz input { accent-color: var(--royal); width: 18px; height: 18px; }
.quiz-result { margin-top: 14px; }
.quiz-result[hidden] { display: none; }

/* ---------- glossary, myths, timeline ---------- */
.terms dt { font: 800 20px/1.2 var(--head); margin-top: 22px; color: var(--royal-deep); }
.terms dd { margin: 6px 0 0; color: var(--muted); }
.myth { padding: 20px 22px; margin: 0 0 16px; }
.myth h3 { margin-bottom: 8px; }
.myth .tag { display: inline-block; font: 800 12px/1 var(--body); letter-spacing: .08em; text-transform: uppercase; padding: 6px 10px; border-radius: 99px; margin-bottom: 10px; }
.myth .false { background: #fde3f1; color: var(--pink-ink); }
.myth .true { background: #ddf6ec; color: var(--mint); }
.myth .half { background: #fff1cc; color: var(--gold-ink); }
.line-time { list-style: none; padding: 0; margin: 0 0 1.4em; position: relative; }
.line-time::before { content: ""; position: absolute; left: 21px; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: linear-gradient(var(--gold), var(--pink), var(--royal)); }
.line-time li { position: relative; padding: 0 0 22px 62px; margin: 0; }
.line-time li::before { content: ""; position: absolute; left: 13px; top: 5px; width: 19px; height: 19px; border-radius: 50%; background: #fff; border: 4px solid var(--gold-deep); }
.line-time time { font-weight: 800; color: var(--pink-ink); display: block; }
.line-time b { font: 800 19px/1.25 var(--head); }

/* ---------- play-for-real strip ---------- */
.invite { position: relative; overflow: hidden; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px 22px; align-items: center; margin: 28px 0 6px; padding: 18px 22px; border-radius: 26px; color: #fff; background: radial-gradient(1.5px 1.5px at 18% 30%, #fff 50%, transparent 51%) 0 0 / 120px 90px, radial-gradient(1px 1px at 70% 60%, #ffe7a0 50%, transparent 51%) 0 0 / 150px 110px, linear-gradient(115deg, #1f48c9 0%, #6b4ae6 52%, #d64aa8 100%); box-shadow: 0 18px 38px rgba(36, 70, 200, .3); }
.slim > .invite { max-width: 820px; }
.invite-logo img { width: 120px; filter: drop-shadow(0 6px 12px rgba(0, 0, 0, .35)); }
.invite-copy p { margin: 0; color: #e8ebff; font-size: 14px; }
.invite-copy .invite-line { margin-bottom: 4px; font: 800 21px/1.2 var(--head); color: #fff; }
.invite-buttons { display: flex; flex-wrap: wrap; gap: 12px 10px; justify-content: flex-end; }
.invite .cta-ghost { background: #fff; color: var(--royal-deep); box-shadow: 0 5px 0 #b9c8f5, 0 10px 20px rgba(0, 0, 0, .15); }
.invite .cta-ghost:hover { color: var(--royal); }
.edition-main .invite { grid-template-columns: auto minmax(0, 1fr); }
.edition-main .invite-buttons { grid-column: 1 / -1; justify-content: flex-start; }

/* ---------- partner casino ---------- */
.partner { display: grid; grid-template-columns: auto 1fr auto; gap: 18px; align-items: center; padding: 20px 22px; border: 2px solid #ffd98a; }
.partner img { width: 74px; height: 74px; }
.partner h3 { margin: 0 0 4px; }
.partner p { margin: 0; color: var(--muted); }

/* ---------- colophon (footer): the sky after dusk ---------- */
.colophon { --c: var(--night); position: relative; margin-top: 64px; padding: 44px 0 120px; background: linear-gradient(180deg, var(--night), #13226e); color: var(--muted); font-size: 15px; }
.colophon::before { top: -29px; }
.colophon-grid { display: grid; grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr)); gap: 24px; }
.colophon h2 { font: 800 13px/1.2 var(--body); text-transform: uppercase; letter-spacing: .12em; color: #ffd36b; margin: 0 0 10px; }
.colophon ul { list-style: none; padding: 0; margin: 0; }
.colophon li { margin: 0 0 6px; }
.colophon a { color: #fff; text-decoration: none; }
.colophon a:hover { color: #ffd36b; }
.colophon .fine-print { margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line-soft); display: flex; flex-wrap: wrap; gap: 10px 22px; font-size: 13px; color: var(--faint); }
.age { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 2px solid #ff8cc8; color: #ff8cc8; font: 800 13px/1 var(--body); flex: none; }
.colophon .about { display: flex; gap: 12px; align-items: flex-start; }
.colophon .mark { color: #fff; }

/* ---------- mobile dock & toast ---------- */
.dock { display: none; }
.toast { position: fixed; left: 16px; bottom: 16px; z-index: 40; max-width: 360px; padding: 14px 16px; border-radius: 18px; background: #fff; border: 1px solid var(--line); box-shadow: 0 18px 40px rgba(20, 40, 120, .22); font-size: 14px; color: var(--muted); }
.toast p { margin: 0 0 10px; }
.toast[hidden] { display: none; }

/* ---------- 404 ---------- */
.lost { text-align: center; padding: 60px 0; }
.lost .big { font: 800 clamp(80px, 16vw, 170px)/1 var(--head); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .edition-grid { grid-template-columns: minmax(0, 1fr) 290px; gap: 24px; }
  .minute { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .colophon-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .colophon-grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  .topnav { display: none; }
  .menu-btn { display: inline-flex; margin-left: 8px; }
  .masthead-play { margin-left: auto; }
  .invite { grid-template-columns: auto minmax(0, 1fr); }
  .invite-buttons { grid-column: 1 / -1; justify-content: flex-start; }
  .orbit { padding: 10px 0; }
  .scene { padding: 22px 0 70px; background-image: image-set(url("/media/bg-starlight-princess-800.avif") type("image/avif"), url("/media/bg-starlight-princess-800.webp") type("image/webp")); }
  .scene.edition { padding: 22px 0 70px; }
  .scene-grid, .replay-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .scene-art { order: -1; }
  .scene-art img { max-height: 340px; }
  .scene-art.logo-art img { max-height: 200px; }
  .edition-grid { grid-template-columns: minmax(0, 1fr); }
  .spec-card { position: static; order: -1; }
  .windows, .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .judgement { grid-template-columns: minmax(0, 1fr); }
  .cols-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
  .dock { position: fixed; left: 10px; right: 10px; bottom: 10px; z-index: 30; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; padding: 6px; border-radius: 22px; background: rgba(255, 255, 255, .95); border: 1px solid var(--line); box-shadow: 0 10px 34px rgba(20, 40, 120, .28); backdrop-filter: blur(8px); }
  .dock a, .dock button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 52px; border-radius: 16px; font: 800 13px/1 var(--body); color: var(--royal-deep); text-decoration: none; background: transparent; border: 0; cursor: pointer; }
  .dock svg { width: 22px; height: 22px; }
  .dock .play { background: linear-gradient(180deg, #ffe58a, var(--gold) 45%, var(--gold-deep)); color: var(--ink-strong); }
  .toast { left: 10px; right: 10px; bottom: 82px; max-width: none; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .intro-text { font-size: 17px; }
  .scene-copy, .scene > .shell:not(.scene-grid) { border-radius: 24px; }
  .kicker { font-size: 12px; letter-spacing: .06em; }
  .masthead-row { gap: 10px; }
  .mark { font-size: 17px; }
  .mark svg { width: 32px; height: 32px; }
  .menu-btn { padding: 11px 13px; }
  .menu-btn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .cta { min-height: 52px; padding: 13px 22px; font-size: 16px; }
  .cta-small { min-height: 42px; padding: 9px 15px; font-size: 15px; }
  .ctas .cta { flex: 1 1 100%; }
  .invite { padding: 16px; gap: 12px 14px; }
  .invite-logo img { width: 84px; }
  .invite-copy .invite-line { font-size: 18px; }
  .invite-buttons .cta { flex: 1 1 140px; }
  .kicker span + span::before { margin: 0 7px; }
  .chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }  .minute { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .minute li { padding: 14px; }
  .frames, .frames-3 { grid-template-columns: minmax(0, 1fr); }
  .tiles b { font-size: 26px; }
  .demo { aspect-ratio: 3 / 4; }
  .demo.is-live { aspect-ratio: 9 / 16; }
  .colophon-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .partner { grid-template-columns: auto 1fr; }
  .partner .cta { grid-column: 1 / -1; }
  .rating-list li { grid-template-columns: 120px 1fr 30px; }
  .window { min-height: 250px; grid-template-rows: 104px 1fr auto; padding: 20px 12px 12px; border-radius: 80px 80px var(--radius) var(--radius); }
  .window > picture.wlogo { height: 104px; }
  .window .wlogo img { max-height: 92px; max-width: 92%; }
  .window b { font-size: 15px; }
  .window small { min-height: 0; font-size: 12px; }
  .sim-track { grid-template-columns: repeat(8, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
.pct-0 { width: 0; } .pct-10 { width: 10%; } .pct-20 { width: 20%; } .pct-30 { width: 30%; } .pct-40 { width: 40%; } .pct-50 { width: 50%; }
.pct-60 { width: 60%; } .pct-70 { width: 70%; } .pct-80 { width: 80%; } .pct-90 { width: 90%; } .pct-100 { width: 100%; }
.lost .slim > * { margin-inline: auto; }
.lost .ctas { justify-content: center; }
