/* jox.byek.games
 *
 * The page is the game's Home screen stretched into a website: a slow biome
 * gradient behind everything, bubbles rising, the cube hopping in the hero,
 * glass cards in front. Platform colours are the only saturated colours; the
 * rest is porcelain white on deep atmosphere.
 */
:root {
    --mint: #8FE8CC;
    --lilac: #CDB0F8;
    --yellow: #F9D94B;
    --coral: #F2705E;
    --player: #121217;

    --ink: #F4F6FA;
    --ink-soft: rgba(244, 246, 250, .68);
    --ink-faint: rgba(244, 246, 250, .42);
    --glass: rgba(255, 255, 255, .07);
    --glass-strong: rgba(255, 255, 255, .11);
    --line: rgba(255, 255, 255, .13);
    --line-strong: rgba(255, 255, 255, .26);
    --radius: 26px;
    --accent: var(--mint);
    --font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Helvetica, Arial, sans-serif;
}
[data-mode="flow"] { --accent: #E79A74; }
[data-mode="shift"] { --accent: var(--lilac); }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; }
body {
    margin: 0;
    background: #071B26;
    color: var(--ink);
    font: 17px/1.6 var(--font);
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    min-height: 100svh;
}
a { color: inherit; }
img, video { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }

/* ---- Sky: three biome gradients that cross-fade, two aurora bands, haze, grain ---- */
.sky { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.biome {
    position: absolute; inset: 0;
    opacity: 0;
    transition: opacity 2.2s ease-in-out;
}
.biome.is-on { opacity: 1; }
.biome-rise  { background: linear-gradient(180deg, #071B26 0%, #12515C 55%, #3FA39A 100%); }
.biome-flow  { background: linear-gradient(180deg, #2A1534 0%, #A24D5C 55%, #E79A74 100%); }
.biome-shift { background: linear-gradient(180deg, #0D0A24 0%, #3B2A7A 55%, #7B64CF 100%); }

.aurora {
    position: absolute;
    left: -30%; right: -30%;
    height: 42vh;
    filter: blur(60px);
    opacity: .5;
    mix-blend-mode: screen;
    will-change: transform;
}
.aurora-a {
    top: 18%;
    background: radial-gradient(60% 55% at 40% 50%, rgba(255,255,255,.22), transparent 70%);
    animation: aurora-a 26s ease-in-out infinite alternate;
}
.aurora-b {
    top: 48%;
    background: radial-gradient(55% 50% at 60% 50%, rgba(255,255,255,.16), transparent 70%);
    animation: aurora-b 34s ease-in-out infinite alternate;
}
@keyframes aurora-a { from { transform: translate3d(-6%, 0, 0) rotate(-3deg); } to { transform: translate3d(8%, 4%, 0) rotate(2deg); } }
@keyframes aurora-b { from { transform: translate3d(7%, 2%, 0) rotate(2deg); } to { transform: translate3d(-8%, -3%, 0) rotate(-3deg); } }

.haze {
    position: absolute; inset: 0;
    background: radial-gradient(120% 60% at 50% 100%, rgba(255,255,255,.14), transparent 60%);
}
.grain {
    position: absolute; inset: 0;
    opacity: .055;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0'/></filter><rect width='160' height='160' filter='url(%23n)'/></svg>");
    background-size: 160px 160px;
}
.bubbles { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

/* ---- Top bar ---- */
.top {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: calc(14px + env(safe-area-inset-top)) clamp(18px, 4vw, 40px) 14px;
    pointer-events: none;
}
.top > * { pointer-events: auto; }
.top-logo img { width: 118px; height: auto; opacity: .9; }
.top-nav { display: flex; gap: 8px; }
.top-link {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--ink);
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(10, 14, 20, .32);
    border: 1px solid var(--line);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: background .2s, border-color .2s;
}
.top-link:hover { background: rgba(255,255,255,.14); border-color: var(--line-strong); }

/* ---- Hero ---- */
/* Like the game's Home: the cube plays in the upper band, the words sit below
 * it. On wide screens the words move left and the corridor runs on the right. */
.hero {
    position: relative;
    z-index: 1;
    min-height: 100svh;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: end;
    justify-items: center;
    padding: calc(90px + env(safe-area-inset-top)) 20px calc(72px + env(safe-area-inset-bottom));
    overflow: hidden;
}
@media (min-width: 900px) and (min-aspect-ratio: 1/1) {
    .hero { align-items: center; justify-items: start; padding-left: clamp(40px, 8vw, 140px); }
    .hero-inner { text-align: left; }
    .hero .badges { justify-content: flex-start; }
    .hero .wordmark { text-indent: 0; }
    .hero .tagline, .hero .soon-label { text-indent: 0; }
    .hero .lede { margin-left: 0; }
}
.stage { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-scrim {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(5,10,16,.25), transparent 28%, transparent 52%, rgba(5,10,16,.62) 78%, rgba(5,10,16,.7));
    pointer-events: none;
}
@media (min-width: 900px) and (min-aspect-ratio: 1/1) {
    .hero-scrim { background: linear-gradient(90deg, rgba(5,10,16,.62), rgba(5,10,16,.35) 40%, transparent 62%), linear-gradient(180deg, rgba(5,10,16,.2), transparent 30%); }
}
.hero-inner { position: relative; text-align: center; width: 100%; max-width: 640px; }
.eyebrow {
    font-size: 12px;
    letter-spacing: .34em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--ink-soft);
    margin-bottom: 26px;
}
.featured {
    display: inline-flex; align-items: center; gap: 10px;
    height: 48px; padding: 0 14px;
    border-radius: 9px;
    color: #F9D94B;
    background: linear-gradient(180deg, rgba(255,255,255,.12), rgba(255,255,255,.05));
    border: 1px solid rgba(249,217,75,.42);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.2);
    text-align: left;
}
.featured .laurel { flex: none; width: 17px; height: 34px; filter: drop-shadow(0 0 8px rgba(249,217,75,.35)); }
.featured .laurel.is-flipped { transform: scaleX(-1); }
.featured-text { color: var(--ink); }
.featured-title { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; line-height: 1.2; }
.featured-sub { margin: 3px 0 0; font-size: 10.5px; letter-spacing: .02em; color: var(--ink-soft); font-weight: 500; line-height: 1.2; }
.story {
    margin: 18px auto 0; max-width: 32em;
    font-size: clamp(14px, 1.9vw, 16px); line-height: 1.55;
    color: var(--ink-soft);
}
@media (min-width: 900px) and (min-aspect-ratio: 1/1) { .hero .story { margin-left: 0; } }
.wordmark {
    font-size: clamp(54px, 13vw, 150px);
    line-height: .9;
    font-weight: 300;
    letter-spacing: .24em;
    text-indent: .24em;
    white-space: nowrap;
    margin: 0;
    animation: breathe 7s ease-in-out infinite;
}
.wordmark.small { font-size: clamp(42px, 8vw, 72px); animation: none; }
.shimmer {
    background: linear-gradient(100deg, #fff 0%, #fff 38%, rgba(255,255,255,.55) 50%, #fff 62%, #fff 100%);
    background-size: 240% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 6.5s ease-in-out infinite;
    text-shadow: none;
}
@keyframes shimmer { 0%, 35% { background-position: 120% 0; } 65%, 100% { background-position: -120% 0; } }
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.018); } }
.tagline {
    margin-top: 32px;
    font-size: clamp(13px, 2.1vw, 17px);
    letter-spacing: .32em;
    text-indent: .32em;
    text-transform: uppercase;
    font-weight: 600;
}
.lede {
    margin: 22px auto 0;
    max-width: 30em;
    font-size: clamp(17px, 2.3vw, 21px);
    line-height: 1.5;
    color: var(--ink-soft);
    font-weight: 400;
}

.store { margin-top: 42px; }
.soon-label {
    font-size: 12px;
    letter-spacing: .3em;
    text-indent: .3em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--ink-soft);
    margin-bottom: 14px;
}
.badges { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.badge {
    display: inline-block;
    text-decoration: none;
    border-radius: 9px;
    transition: transform .2s ease, opacity .2s;
}
.badge svg { display: block; width: 160px; height: 48px; }
.badge-bg { fill: #0b0d12; stroke: rgba(255,255,255,.6); stroke-width: 1; }
.badge-ink { fill: #fff; }
.badge-small { fill: #fff; font: 600 9.5px/1 var(--font); letter-spacing: .02em; }
.badge-big { fill: #fff; font: 600 18px/1 var(--font); letter-spacing: -.01em; }
.badge:hover { transform: translateY(-2px); }
.badge.is-soon { opacity: .62; cursor: default; }
.badge.is-soon:hover { transform: none; }
.badge.is-soon .badge-small { font-size: 8.6px; }
.testflight {
    display: inline-block;
    margin-top: 14px;
    font-size: 14px;
    font-weight: 600;
    color: var(--ink-soft);
}

.scroll-hint {
    position: absolute;
    bottom: calc(22px + env(safe-area-inset-bottom));
    left: 50%;
    transform: translateX(-50%);
    width: 22px; height: 36px;
    border: 1.5px solid rgba(255,255,255,.4);
    border-radius: 12px;
    opacity: .7;
}
.scroll-hint span {
    position: absolute; left: 50%; top: 7px;
    width: 3px; height: 7px; margin-left: -1.5px;
    border-radius: 2px;
    background: #fff;
    animation: wheel 2.2s ease-in-out infinite;
}
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }

/* ---- Sections ---- */
main { position: relative; z-index: 1; }
.section { position: relative; padding: clamp(72px, 10vw, 128px) 0; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 clamp(20px, 4vw, 40px); }
.kicker {
    display: flex; align-items: center; gap: 10px;
    font-size: 12px;
    letter-spacing: .28em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--ink-soft);
    margin-bottom: 16px;
}
.kicker.small { margin-bottom: 12px; font-size: 11px; }
.kicker .dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--mint);
    box-shadow: 0 0 0 0 rgba(143,232,204,.6);
    animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(143,232,204,.6); } 100% { box-shadow: 0 0 0 12px rgba(143,232,204,0); } }
h2 {
    font-size: clamp(32px, 5vw, 54px);
    line-height: 1.04;
    letter-spacing: -.025em;
    font-weight: 700;
    max-width: 16em;
}
.section-lede {
    margin-top: 16px;
    font-size: clamp(17px, 2vw, 20px);
    color: var(--ink-soft);
    max-width: 34em;
}

.cards { display: grid; gap: 16px; margin-top: 44px; }
.cards.three { grid-template-columns: 1fr; }
.cards.four { grid-template-columns: 1fr 1fr; }
.cards.feature { grid-template-columns: 1fr; }
@media (min-width: 720px) {
    .cards.three { grid-template-columns: repeat(3, 1fr); }
    .cards.four { grid-template-columns: repeat(4, 1fr); }
    .cards.feature { grid-template-columns: repeat(2, 1fr); }
    .card.wide { grid-column: span 2; }
}
@media (min-width: 980px) {
    .cards.feature { grid-template-columns: repeat(3, 1fr); }
}

.card {
    position: relative;
    padding: 26px;
    border-radius: var(--radius);
    background: var(--glass);
    border: 1px solid var(--line);
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 20px 50px -30px rgba(0,0,0,.6);
    overflow: hidden;
}
.card::before {
    /* the lit top edge of a JoxSurface */
    content: "";
    position: absolute; left: 12%; right: 12%; top: 0; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent);
}
.card h3 { font-size: 20px; font-weight: 700; letter-spacing: -.01em; margin-top: 18px; }
.card h3 small { font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-faint); margin-left: 8px; }
.card p { margin-top: 8px; color: var(--ink-soft); font-size: 16px; }
.card .mono { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-faint); margin-top: 16px; font-weight: 600; }
.ico { width: 40px; height: 40px; color: var(--accent); }
.glyph { width: 84px; height: 84px; }
.glyph .hop { animation: hop 1.8s cubic-bezier(.3,0,.2,1) infinite; transform-origin: center; }
.dir-rise .glyph .hop { animation-name: hop-rise; }
.dir-flow .glyph .hop { animation-name: hop-flow; }
.dir-shift .glyph .hop { animation-name: hop-shift; }
@keyframes hop-rise { 0%, 20% { transform: translate(0, 0); } 50% { transform: translate(0, -26px) scale(.96, 1.06); } 60%, 100% { transform: translate(0, -22px); } }
@keyframes hop-flow { 0%, 20% { transform: translate(0, 0); } 35% { transform: translate(12px, -14px); } 50% { transform: translate(24px, 0) scale(1.04, .94); } 60%, 100% { transform: translate(24px, 0); } }
@keyframes hop-shift { 0%, 20% { transform: translate(0, 0); } 35% { transform: translate(12px, -22px); } 50% { transform: translate(22px, -22px) scale(1.02, .96); } 60%, 100% { transform: translate(22px, -22px); } }

/* platform tiles: an isometric block in the platform's colour */
.plat .block { height: 96px; display: grid; place-items: center; perspective: 600px; }
.tile {
    position: relative;
    display: block;
    width: 84px; height: 84px;
    transform: rotateX(58deg) rotateZ(45deg);
    transform-style: preserve-3d;
    background: var(--c);
    border-radius: 6px;
    box-shadow:
        -7px 7px 0 0 var(--d),
        -14px 14px 0 0 color-mix(in srgb, var(--d) 75%, #000);
    animation: tile-float 4.5s ease-in-out infinite;
}
.tile.size-m { width: 68px; height: 68px; }
.tile.size-s { width: 52px; height: 52px; }
.tile::after {
    content: "";
    position: absolute; inset: 0;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(255,255,255,.4), transparent 55%);
}
.tile .gem {
    position: absolute; left: 50%; top: 50%;
    width: 16px; height: 16px;
    margin: -8px 0 0 -8px;
    background: #FFF4B8;
    transform: rotate(45deg) translateZ(14px);
    box-shadow: 0 0 18px rgba(249,217,75,.9);
}
.tile .fuse {
    position: absolute; inset: 8px;
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,.85);
    border-right-color: transparent;
    border-bottom-color: transparent;
    animation: fuse 5s linear infinite;
}
@keyframes fuse { to { transform: rotate(-360deg); } }
@keyframes tile-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -5px; } }
.plat .pts { font-size: 30px; font-weight: 300; letter-spacing: -.02em; color: var(--ink); margin-top: 2px; }
.plat .pts span { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-faint); font-weight: 600; margin-left: 4px; }
.plat h3 { color: var(--c); }

/* platform colours and kinds */
.subhead { margin-top: 56px; font-size: clamp(20px, 2.4vw, 26px); font-weight: 700; letter-spacing: -.01em; }
.subnote { margin-top: 6px; color: var(--ink-soft); font-size: 16px; max-width: 34em; }
.chips { list-style: none; margin: 22px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.chips li {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 8px 16px 8px 10px;
    border-radius: 999px;
    background: var(--glass); border: 1px solid var(--line);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.chips i { width: 18px; height: 18px; border-radius: 6px; background: var(--c); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 0 0 1px rgba(0,0,0,.15); }
.chips .n { font-size: 14px; font-weight: 600; letter-spacing: .02em; }
.chips .v { font-size: 14px; font-weight: 300; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.kind .tile { animation-name: tile-float; }
.kind .tile .whirl {
    position: absolute; inset: 14%;
    border-radius: 50%;
    border: 4px solid rgba(255,255,255,.85);
    border-right-color: transparent;
    animation: spin-up 3s cubic-bezier(.6,0,.9,.4) infinite;
}
@keyframes spin-up { to { transform: rotate(540deg); } }
.kind .tile .layers {
    position: absolute; inset: 0; border-radius: inherit;
    background: repeating-linear-gradient(0deg, transparent 0 33%, rgba(0,0,0,.14) 33% 36%);
}
.kind .tile .crack {
    position: absolute; inset: 0; border-radius: inherit;
    background:
        linear-gradient(115deg, transparent 47%, rgba(255,255,255,.9) 48% 49%, transparent 50%),
        linear-gradient(35deg, transparent 58%, rgba(255,255,255,.8) 59% 60%, transparent 61%),
        linear-gradient(160deg, transparent 30%, rgba(255,255,255,.7) 31% 32%, transparent 33%);
}
.kind-glass .tile { opacity: .82; }
.kind-ghost .tile { animation: tile-float 4.5s ease-in-out infinite, ghost-fade 3.2s ease-in-out infinite; }
@keyframes ghost-fade { 0%, 45% { opacity: 1; } 60%, 85% { opacity: .22; } 100% { opacity: 1; } }

/* ---- Gallery ---- */
.gallery {
    display: flex;
    gap: 22px;
    margin-top: 44px;
    padding: 10px clamp(20px, calc((100vw - 1080px) / 2 + 40px), 50vw) 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.gallery::-webkit-scrollbar { display: none; }
.phone { flex: 0 0 auto; width: 232px; margin: 0; scroll-snap-align: center; }
.phone .screen {
    position: relative;
    aspect-ratio: 1179 / 2556;
    border-radius: 38px;
    padding: 9px;
    background: linear-gradient(160deg, #2a2d36, #0b0d12 60%);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.25), 0 30px 60px -30px rgba(0,0,0,.8);
}
.phone .screen img, .phone .screen video {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: 30px;
    background: #0b0d12;
}
.phone .screen::after {
    /* the notch */
    content: "";
    position: absolute; left: 50%; top: 18px;
    width: 72px; height: 20px; margin-left: -36px;
    border-radius: 12px;
    background: #0b0d12;
}
.phone figcaption { margin-top: 14px; font-size: 14px; color: var(--ink-soft); text-align: center; padding: 0 6px; }

/* ---- Live ---- */
.stats-note { margin-top: 18px; font-size: 14px; color: var(--ink-faint); }
.totals {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 40px;
}
@media (min-width: 640px) { .totals { grid-template-columns: repeat(3, 1fr); } }
.total {
    padding: 22px 22px 20px;
    border-radius: 22px;
    background: var(--glass);
    border: 1px solid var(--line);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.14);
    min-width: 0;
}
.total .num {
    display: block;
    font-size: clamp(30px, 5vw, 44px);
    line-height: 1.1;
    font-weight: 300;
    letter-spacing: -.03em;
    font-variant-numeric: tabular-nums;
    min-height: 1.1em;
}
.total .num.is-placeholder { font-size: 15px; font-weight: 500; color: var(--ink-faint); letter-spacing: .02em; line-height: 1.5; padding-top: .8em; }
.total .lbl { display: block; margin-top: 8px; font-size: 12px; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; color: var(--ink-soft); }

.live-grid { display: grid; gap: 16px; margin-top: 16px; grid-template-columns: 1fr; }
@media (min-width: 860px) { .live-grid { grid-template-columns: 1fr 1fr 1.3fr; } }
.daily-number { font-size: 56px; font-weight: 300; letter-spacing: -.04em; line-height: 1; margin-top: 8px; }
.daily-meta { color: var(--ink-soft); margin-top: 10px; font-size: 15px; }
.list { list-style: none; margin: 10px 0 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); min-height: 52px; }
.list li:first-child { border-top: 0; }
.list .empty { color: var(--ink-faint); font-size: 14px; }
.list .rank { width: 22px; font-size: 13px; font-weight: 600; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.list .avatar {
    width: 34px; height: 34px; border-radius: 10px; flex: none;
    background: var(--a, var(--lilac));
    color: #121217;
    display: grid; place-items: center;
    font-size: 13px; font-weight: 700;
    overflow: hidden;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.5);
}
.list .avatar img { width: 100%; height: 100%; object-fit: cover; }
.list .who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.list .name { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list .country { font-size: 12px; color: var(--ink-faint); letter-spacing: .08em; }
.list .score { font-size: 18px; font-weight: 300; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.list .score small { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-faint); margin-left: 4px; font-weight: 600; }
.list li.me-top .rank { color: var(--accent); }
.boards-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.tabs { display: flex; gap: 4px; padding: 3px; border-radius: 999px; background: rgba(0,0,0,.25); border: 1px solid var(--line); }
.tab {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--ink-soft);
    font: 700 11px/1 var(--font);
    letter-spacing: .14em;
    text-transform: uppercase;
    padding: 8px 12px;
    border-radius: 999px;
    cursor: pointer;
    transition: background .2s, color .2s;
}
.tab.is-on { background: rgba(255,255,255,.9); color: #121217; }

/* ---- CTA + footer ---- */
.cta .wrap { text-align: center; display: flex; flex-direction: column; align-items: center; }
.cta-title { margin-top: 26px; font-size: clamp(26px, 4vw, 40px); font-weight: 700; letter-spacing: -.02em; }
.pill {
    display: inline-block;
    margin-top: 30px;
    padding: 16px 28px;
    border-radius: 999px;
    background: rgba(255,255,255,.92);
    color: #121217;
    text-decoration: none;
    font-weight: 700;
    letter-spacing: .02em;
    box-shadow: 0 0 0 1px rgba(255,255,255,.2), 0 0 40px -6px color-mix(in srgb, var(--accent) 60%, transparent);
    transition: transform .2s;
}
.pill:hover { transform: translateY(-2px); }

.foot { position: relative; z-index: 1; padding: 40px 0 calc(110px + env(safe-area-inset-bottom)); background: linear-gradient(180deg, transparent, rgba(5,8,14,.55)); }
.foot-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; border-top: 1px solid var(--line); padding-top: 28px; font-size: 14px; color: var(--ink-soft); }
.foot-inner img { width: 110px; height: auto; opacity: .7; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.foot-links a { text-decoration: none; color: var(--ink-soft); }
.foot-links a:hover { color: var(--ink); }
.copy { margin-left: auto; font-size: 12px; letter-spacing: .08em; color: var(--ink-faint); }

/* ---- Music toggle ---- */
.music {
    position: fixed;
    right: calc(16px + env(safe-area-inset-right));
    bottom: calc(16px + env(safe-area-inset-bottom));
    z-index: 30;
    display: flex; align-items: center; gap: 12px;
    padding: 10px 16px 10px 12px;
    border-radius: 999px;
    border: 1px solid var(--line-strong);
    background: rgba(12, 16, 24, .55);
    color: var(--ink);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    cursor: pointer;
    font-family: var(--font);
    text-align: left;
    box-shadow: 0 10px 30px -10px rgba(0,0,0,.6);
    transition: background .2s, transform .2s;
}
.music:hover { background: rgba(255,255,255,.14); transform: translateY(-1px); }
.music .eq { display: flex; align-items: flex-end; gap: 2px; width: 18px; height: 16px; }
.music .eq i { flex: 1; height: 30%; background: var(--ink); border-radius: 1px; transform-origin: bottom; transition: height .3s; }
.music[aria-pressed="true"] .eq i { animation: eq 1.1s ease-in-out infinite; }
.music[aria-pressed="true"] .eq i:nth-child(2) { animation-delay: -.25s; }
.music[aria-pressed="true"] .eq i:nth-child(3) { animation-delay: -.6s; }
.music[aria-pressed="true"] .eq i:nth-child(4) { animation-delay: -.9s; }
@keyframes eq { 0%, 100% { height: 30%; } 50% { height: 100%; } }
.music-text { display: flex; flex-direction: column; line-height: 1.15; }
.music-title { font-size: 13px; font-weight: 600; }
.music-sub { font-size: 11px; color: var(--ink-faint); }
@media (max-width: 480px) { .music-sub { display: none; } }

/* `?preview=1` pins the hero to a fixed height so a tall headless-browser
 * screenshot shows the whole page in one image. Nothing else changes. */
.preview .hero { min-height: 880px; }

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .aurora, .wordmark, .shimmer, .glyph .hop, .tile, .tile .fuse, .scroll-hint span, .kicker .dot, .kind .tile .whirl { animation: none !important; }
    .biome { transition: none; }
    .bubbles { display: none; }
    .music[aria-pressed="true"] .eq i { animation: none; height: 70%; }
}

/* Boards name the player and place them: an initials tile, their name, their country. */
.tabs-kind { align-self: flex-start; width: max-content; margin-top: 10px; }

/* ----------------------------------------------------------------- documents
   Privacy, terms and support: one column of quiet text on the same dark ground
   as the front page, wide enough to read and no wider. */
.doc-body { background: #071B26; }
.doc { padding: 96px 0 40px; }
.doc-wrap { max-width: 760px; }
.doc-back { display: inline-block; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); text-decoration: none; }
.doc-back:hover { color: var(--accent); }
.doc-title { font-size: clamp(40px, 8vw, 68px); font-weight: 300; letter-spacing: -.03em; margin-top: 18px; }
.doc-updated { color: var(--ink-faint); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; margin-top: 10px; }
.doc-intro { color: var(--ink-soft); font-size: 19px; line-height: 1.6; margin-top: 22px; max-width: 62ch; }
.doc-section { margin-top: 44px; border-top: 1px solid var(--line); padding-top: 26px; }
.doc-section h2 { font-size: 22px; font-weight: 600; letter-spacing: -.01em; }
.doc-section p { color: var(--ink-soft); line-height: 1.7; margin-top: 14px; max-width: 68ch; }
.doc-section ul { margin: 14px 0 0 18px; padding: 0; color: var(--ink-soft); line-height: 1.7; max-width: 68ch; }
.doc-section li { margin-top: 8px; }
.doc-section a { color: var(--accent); }
.doc-section strong { color: var(--ink); font-weight: 600; }
.doc-mail { font-size: 22px; letter-spacing: -.01em; }
@media (max-width: 720px) { .doc { padding-top: 64px; } }

/* The language picker: one quiet row under the footer links, the current one lit. */
.foot-langs { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 10px; }
.foot-langs a { font-size: 13px; color: var(--ink-faint); text-decoration: none; }
.foot-langs a:hover { color: var(--ink-soft); }
.foot-langs a.is-on { color: var(--accent); }
.doc-note { margin-top: 18px; padding: 14px 18px; border-radius: 16px; background: rgba(255,255,255,.05); border: 1px solid var(--line); color: var(--ink-faint); font-size: 14px; line-height: 1.6; max-width: 62ch; }

/* ------------------------------------------------------------ language menu
   A flag and the language's own name, opening a list of the rest. <details> so
   it works with no JavaScript and closes on Escape by itself. */
.lang-menu { position: relative; }
.lang-menu > summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; }
.lang-menu > summary::-webkit-details-marker { display: none; }
.lang-flag { font-size: 16px; line-height: 1; }
.lang-caret { font-size: 10px; opacity: .6; }
.lang-menu[open] > summary .lang-caret { transform: rotate(180deg); display: inline-block; }
.lang-list {
    position: absolute; right: 0; top: calc(100% + 10px); z-index: 40;
    display: grid; gap: 2px; padding: 8px; min-width: 190px;
    background: rgba(12, 28, 38, .96); backdrop-filter: blur(14px);
    border: 1px solid var(--line); border-radius: 18px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, .45);
}
.lang-list a {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 12px; border-radius: 12px;
    font-size: 14px; color: var(--ink-soft); text-decoration: none;
}
.lang-list a:hover { background: rgba(255, 255, 255, .08); color: var(--ink); }
.lang-list a.is-on { color: var(--accent); }
.doc-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
@media (max-width: 560px) { .lang-menu > summary .lang-name { display: none; } }

/* ---------------------------------------------------------------- the eighteen badges, and the cube finishes */

/* The eighteen, as the game draws them: the PNGs under /assets/badges are rendered from the same
   GDScript the app runs, so the web can never drift away from what a player actually earns. */
.trophies {
    list-style: none; margin: 44px 0 0; padding: 0;
    display: grid; gap: 20px 14px;
    grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 560px) { .trophies { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .trophies { grid-template-columns: repeat(6, 1fr); } }
.trophies li { display: flex; flex-direction: column; align-items: center; text-align: center; }
.trophies img { width: 100%; max-width: 104px; height: auto; }
.trophies .n { margin-top: 12px; font-size: 14px; font-weight: 700; letter-spacing: .01em; }
.trophies .v { margin-top: 4px; font-size: 13px; font-weight: 300; line-height: 1.45; color: var(--ink-soft); }

.cube-note { margin-top: 64px; max-width: 46em; }
.cube-note h3 { font-size: clamp(20px, 2.4vw, 26px); font-weight: 700; letter-spacing: -.01em; }
.cube-note p { margin-top: 10px; color: var(--ink-soft); font-size: 16px; line-height: 1.6; }
.cube-note .kicker { margin-top: 28px; }

/* A finish is drawn as SVG (see cubeSwatch in boot.php), so the chip only has to make room. */
.chips.cubes svg.cube { display: block; width: 26px; height: 26px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.35)); }
.chips.cubes li { padding-left: 12px; }

/* The launch list. The one thing a visitor can do before the game is out. */
.notify { margin: 30px auto 0; max-width: 520px; text-align: left; }
.notify-label { margin: 0 0 12px; font-weight: 600; color: var(--ink); text-align: center; }
.notify-row { display: flex; flex-wrap: wrap; gap: 10px; }
.notify-row input[type="email"] {
    flex: 1 1 220px;
    min-width: 0;
    padding: 15px 18px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(255,255,255,.06);
    color: var(--ink);
    font: inherit;
}
.notify-row input[type="email"]::placeholder { color: var(--ink-soft); }
.notify-row input[type="email"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.notify-row .pill { margin-top: 0; flex: 0 0 auto; border: 0; cursor: pointer; font: inherit; font-weight: 700; }
.notify-row .pill[disabled] { opacity: .55; cursor: default; transform: none; }
.notify-consent {
    display: flex; align-items: flex-start; gap: 10px;
    margin-top: 14px; font-size: 13px; line-height: 1.5; color: var(--ink-soft);
}
.notify-consent input { margin-top: 3px; accent-color: var(--accent); flex: 0 0 auto; }
.notify-consent a { color: var(--ink); }
.notify-pot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notify-note { min-height: 20px; margin: 12px 0 0; font-size: 14px; color: var(--ink-soft); }
.notify-note.is-ok { color: var(--accent); }
.notify-note.is-bad { color: #ff9f9f; }
.notify.is-done .notify-row, .notify.is-done .notify-consent { display: none; }
.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* The Product Hunt badge, its own line under the store badges. */
.ph-badge { display: inline-block; margin-top: 20px; border-radius: 10px; }
.ph-badge img { display: block; width: 250px; height: 54px; }
.ph-badge:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
