/* GaLazo Minecraft Modu — page styles (self-contained, no framework) */

/* ---------- Fonts (self-hosted, Poppins like the main site) ---------- */
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-400-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-400-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/poppins-600-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/poppins-600-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/poppins-700-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/poppins-700-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 800; font-display: swap; src: url('fonts/poppins-800-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 800; font-display: swap; src: url('fonts/poppins-800-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
/* Pixel digits (Jersey 10) for the countdown only — subset: 0-9 and ":" */
@font-face { font-family: 'GaLazo Pixel'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/jersey10-digits.woff2') format('woff2'); unicode-range: U+0030-003A; }

/* ---------- Tokens ---------- */
:root {
    --bg: #f4f2ec;
    --surface: #ffffff;
    --surface-muted: #f7f5f0;
    --ink: #17191c;
    --ink-soft: #4b5057;
    --ink-faint: #656a71;
    --line: #e4dfd4;
    --line-strong: #cbc4b4;

    --night: #121519;
    --night-raised: #1b1f25;
    --night-line: #2d333c;
    --night-ink: #f3f4f6;
    --night-soft: #b8bfc8;

    --grass: #3c8527;
    --grass-hover: #347520;
    --grass-border: #2d661d;
    --grass-edge: #1f4a13;
    --grass-tint: #eef6e8;
    --grass-line: #cfe4c2;
    --grass-ink: #2a6119;

    --honey: #ffc93c;
    --honey-tint: #fff6dc;
    --honey-line: #f0d68c;
    --honey-ink: #5c4300;

    --youtube: #e1251b;
    --instagram: #d6246e;
    --whatsapp: #1b9e4b;
    --focus: #1d5fd6;

    --radius-sm: 4px;
    --radius: 8px;
    --radius-lg: 12px;

    --font: 'Poppins', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    --font-pixel: 'GaLazo Pixel', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
    --font-mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, 'Liberation Mono', monospace;

    --gutter: 16px;
    --pad-left: max(var(--gutter), env(safe-area-inset-left));
    --pad-right: max(var(--gutter), env(safe-area-inset-right));
}

@media (min-width: 600px) {
    :root { --gutter: 24px; }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 16px;
}

body {
    margin: 0;
    min-width: 320px;
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-wrap: break-word;
    -webkit-tap-highlight-color: transparent;
}

h1, h2, h3, p, figure, dl, dd { margin: 0; }
img { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }

.wrap {
    width: 100%;
    max-width: 1080px;
    margin-inline: auto;
    padding-left: var(--pad-left);
    padding-right: var(--pad-right);
}

.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.icon { width: 1.25em; height: 1.25em; flex: none; }
.icon--sm { width: 1em; height: 1em; }
.icon--youtube { color: var(--youtube); }

:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
}
.site-header :focus-visible,
.hero :focus-visible,
.site-footer :focus-visible,
.lightbox :focus-visible { outline-color: var(--honey); }

.skip-link {
    position: absolute;
    top: -60px;
    left: 12px;
    z-index: 50;
    padding: 10px 14px;
    border-radius: var(--radius);
    background: var(--honey);
    color: #1c1500;
    font-weight: 700;
    text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Buttons (blocky, with a pressable bottom edge) ---------- */
.btn {
    --btn-bg: var(--surface);
    --btn-bg-hover: var(--surface-muted);
    --btn-ink: var(--ink);
    --btn-border: var(--line-strong);
    --btn-edge: #b3ab99;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    margin-bottom: 4px;
    padding: 10px 18px;
    border: 2px solid var(--btn-border);
    border-radius: var(--radius);
    background: var(--btn-bg);
    color: var(--btn-ink);
    box-shadow: 0 4px 0 var(--btn-edge);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    user-select: none;
    transition: background-color .15s ease, transform .06s ease, box-shadow .06s ease;
}
.btn:hover { background: var(--btn-bg-hover); }
.btn:active:not([disabled]) { transform: translateY(2px); box-shadow: 0 2px 0 var(--btn-edge); }
.btn[disabled] { cursor: not-allowed; opacity: .65; }

.btn--primary {
    --btn-bg: var(--grass);
    --btn-bg-hover: var(--grass-hover);
    --btn-ink: #ffffff;
    --btn-border: var(--grass-border);
    --btn-edge: var(--grass-edge);
}
.btn--secondary { --btn-edge: #bcb4a2; }
.btn--sm { min-height: 44px; padding: 8px 14px; font-size: .9375rem; }
.btn--lg { min-height: 56px; padding: 12px 22px; font-size: 1.0625rem; }
.btn--download {
    width: 100%;
    min-height: 64px;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: .04em;
}

.icon-btn {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    flex: none;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink);
    cursor: pointer;
}
.icon-btn:hover { background: var(--surface-muted); }
.icon-btn--dark {
    border-color: rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .08);
    color: #ffffff;
}
.icon-btn--dark:hover { background: rgba(255, 255, 255, .16); }
.icon-btn[disabled] { opacity: .3; cursor: default; }

.text-link {
    font-weight: 700;
    color: var(--grass-ink);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Inventory-slot style icon box */
.slot {
    position: relative;
    display: inline-grid;
    place-items: center;
    width: 48px;
    height: 48px;
    flex: none;
    border: 2px solid;
    border-color: #c3bcac #fdfcf9 #fdfcf9 #c3bcac;
    border-radius: var(--radius-sm);
    background: #ece9e0;
    color: var(--ink-soft);
}
.slot .icon { width: 26px; height: 26px; }
.slot--small { width: 40px; height: 40px; }
.slot--small .icon { width: 22px; height: 22px; }
.slot--youtube { color: var(--youtube); }
.slot--instagram { color: var(--instagram); }
.slot--whatsapp { color: var(--whatsapp); }
.slot__check {
    position: absolute;
    right: -7px;
    bottom: -7px;
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border: 2px solid var(--surface);
    border-radius: var(--radius-sm);
    background: var(--grass);
    color: #ffffff;
}
.slot__check .icon { width: 13px; height: 13px; }

.card {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
}
.card-title { font-size: 1.0625rem; font-weight: 700; }

/* ---------- Header ---------- */
.site-header {
    padding-top: env(safe-area-inset-top);
    background: var(--night);
    color: var(--night-ink);
}
.header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 60px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -.01em;
    text-decoration: none;
}
.brand__icon { width: 30px; height: 30px; color: var(--youtube); }
.header-link {
    padding: 10px 2px;
    color: var(--night-soft);
    font-size: .9375rem;
    font-weight: 600;
    text-decoration: none;
}
.header-link:hover { color: #ffffff; }
.header-actions { display: flex; align-items: center; gap: 14px; }

/* Language: a native select (the phone's own picker) under a compact "TR ▾" label */
.lang-picker {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 0 10px;
    border: 1px solid var(--night-line);
    border-radius: var(--radius);
    background: var(--night-raised);
    color: var(--night-ink);
    font-size: .875rem;
    font-weight: 700;
    letter-spacing: .04em;
    cursor: pointer;
}
.lang-picker:hover { border-color: #46505c; }
.lang-picker:focus-within { outline: 3px solid var(--honey); outline-offset: 2px; }
.lang-picker__chevron { opacity: .7; }
.lang-picker__select {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
    font-size: 16px; /* no zoom-in on focus in iOS Safari */
}
@media (max-width: 359px) {
    .header-link { display: none; } /* the GaLazo logo links home as well */
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    padding: 12px 0 52px;
    background: var(--night);
    color: var(--night-ink);
}
.hero__grid { display: grid; gap: 20px; }
.hero__cover { width: 100%; max-width: 440px; }
@supports (height: 1svh) {
    .hero__cover { max-width: min(440px, 50svh); }
}

.cover-button {
    position: relative;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    border-radius: var(--radius);
    background: none;
    cursor: zoom-in;
}
.cover-frame {
    display: block;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--night-raised);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 8px 8px 0 rgba(0, 0, 0, .4);
}
.cover-frame img { width: 100%; height: 100%; object-fit: contain; }
.cover-chip {
    position: absolute;
    right: 10px;
    bottom: 10px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 6px;
    background: rgba(18, 21, 25, .85);
    color: #ffffff;
    font-size: .8125rem;
    font-weight: 700;
}

.release-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    border-radius: 6px;
    background: var(--honey);
    color: #241a00;
    font-size: .8125rem;
    font-weight: 800;
    letter-spacing: .06em;
    line-height: 1.4;
}
.release-badge__pixel { width: 8px; height: 8px; background: currentColor; }
.release-badge.is-live { background: var(--grass); color: #ffffff; }
.release-badge.is-live .release-badge__pixel { animation: pixel-blink 1.2s steps(1, end) infinite; }
@keyframes pixel-blink { 50% { opacity: 0; } }

.hero__title {
    margin-top: 14px;
    font-size: clamp(2.125rem, 1.5rem + 3.2vw, 3.5rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -.025em;
}
.hero__subtitle {
    margin-top: 8px;
    color: var(--night-soft);
    font-size: clamp(1.0625rem, .95rem + .6vw, 1.375rem);
    font-weight: 600;
}
.hero__release { margin-top: 20px; }
/* min-height: reserved before mod.js fills in the visitor's local time */
.release-when { min-height: 1.5em; margin-top: 12px; color: var(--night-soft); font-size: .9375rem; }
.hero__cta { margin-top: 20px; }

.grass-edge {
    position: absolute;
    right: 0;
    bottom: -8px;
    left: 0;
    z-index: 1;
    height: 16px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='16' shape-rendering='crispEdges'%3E%3Cpath fill='%235aa036' d='M0 0h96v8H0z'/%3E%3Cpath fill='%2367b141' d='M4 0h4v4H4zM24 0h8v4h-8zM52 0h4v4h-4zM76 0h8v4h-8z'/%3E%3Cpath fill='%234b8a2c' d='M0 8h12v4H0zM20 8h4v4h-4zM32 8h8v4h-8zM48 8h16v4H48zM72 8h4v4h-4zM84 8h8v4h-8zM4 12h4v4H4zM36 12h4v4h-4zM52 12h8v4h-8zM84 12h4v4h-4z'/%3E%3C/svg%3E") repeat-x left top / 96px 16px;
    pointer-events: none;
}

@media (min-width: 720px) {
    .hero { padding: 32px 0 72px; }
    .hero__grid {
        grid-template-columns: minmax(260px, 340px) 1fr;
        align-items: center;
        gap: 36px;
    }
    .hero__cover { max-width: none; }
    .hero__title { font-size: clamp(2.375rem, 1.2rem + 2.6vw, 3.5rem); }
    .hero__grid--no-cover { grid-template-columns: 1fr; max-width: 760px; }
}
@media (min-width: 1000px) {
    .hero { padding: 40px 0 80px; }
    .hero__grid { grid-template-columns: minmax(300px, 440px) 1fr; gap: 56px; }
}

/* ---------- Countdown ---------- */
.countdown {
    display: flex;
    align-items: stretch;
    gap: 6px;
    max-width: 420px;
}
.countdown__unit {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    padding: 10px 4px 8px;
    border: 1px solid var(--night-line);
    border-radius: var(--radius);
    background: var(--night-raised);
}
.countdown__value {
    font-family: var(--font-pixel);
    font-size: clamp(2.375rem, 1.95rem + 1.8vw, 3.125rem);
    font-weight: 400;
    line-height: .9;
    letter-spacing: .03em;
}
.countdown__label {
    margin-top: 6px;
    color: var(--night-soft);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .06em;
    line-height: 1.2;
}
.countdown__sep {
    align-self: center;
    padding-bottom: 18px;
    color: var(--night-soft);
    font-family: var(--font-pixel);
    font-size: 1.75rem;
    font-weight: 400;
    line-height: 1;
}
.countdown--light .countdown__unit { border-color: var(--grass-line); background: var(--surface); }
.countdown--light .countdown__value { color: var(--ink); }
.countdown--light .countdown__label,
.countdown--light .countdown__sep { color: var(--ink-faint); }

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section + .section { padding-top: 0; }
.section--download { padding-top: 8px; }

.eyebrow {
    color: var(--grass-ink);
    font-size: .8125rem;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
}
.section-title {
    max-width: 24ch;
    margin-top: 6px;
    font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -.015em;
}
.section-title--wide { max-width: 30ch; }
.section-intro { max-width: 62ch; margin-top: 10px; color: var(--ink-soft); }

@media (min-width: 768px) {
    .section { padding: 80px 0; }
    .section--download { padding-top: 8px; }
}

/* About */
.about { max-width: 66ch; margin-top: 14px; }
.about__text { color: var(--ink-soft); font-size: 1.0625rem; }
.note {
    display: flex;
    gap: 10px;
    margin-top: 18px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink-soft);
    font-size: .9375rem;
}
.note__icon { margin-top: 2px; color: var(--ink-faint); }

/* Gallery strip (images 2-5) */
.gallery { margin-top: 32px; }
.gallery__title { font-size: 1rem; font-weight: 700; }
.gallery__strip {
    display: flex;
    gap: 12px;
    margin: 12px calc(-1 * var(--pad-right)) 0 calc(-1 * var(--pad-left));
    padding: 4px var(--pad-right) 10px var(--pad-left);
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-padding-inline: var(--pad-left);
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
}
.thumb {
    flex: none;
    height: 136px;
    padding: 0;
    overflow: hidden;
    border: 2px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    cursor: zoom-in;
    scroll-snap-align: start;
}
.thumb img { width: auto; height: 100%; max-width: none; }
@media (min-width: 768px) {
    .thumb { height: 168px; }
}

/* ---------- Picture guide (swipe strip on phones, grid from 900px) ---------- */
.guide {
    display: flex;
    gap: 14px;
    margin: 20px calc(-1 * var(--pad-right)) 0 calc(-1 * var(--pad-left));
    padding: 4px var(--pad-right) 14px var(--pad-left);
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-padding-inline: var(--pad-left);
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    list-style: none;
}
.guide__item {
    display: flex;
    flex: 0 0 min(84vw, 420px);
    scroll-snap-align: start;
}
/* The whole card opens the picture: the button's ::after covers it */
.guide-card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
    cursor: zoom-in;
    transition: border-color .15s ease;
}
.guide-card:hover { border-color: var(--line-strong); }
.guide-card__media {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: var(--night-raised);
    cursor: inherit;
}
.guide-card__media::after { content: ''; position: absolute; inset: 0; }
.guide-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.guide-card:hover .guide-card__media img { transform: scale(1.03); }
.guide-card__num {
    position: absolute;
    top: 8px;
    left: 8px;
    display: grid;
    place-items: center;
    min-width: 30px;
    height: 30px;
    padding: 0 6px;
    border-radius: var(--radius-sm);
    background: var(--honey);
    color: #241a00;
    box-shadow: 0 3px 0 rgba(0, 0, 0, .35);
    font-family: var(--font-pixel);
    font-size: 1.375rem;
    line-height: 1;
}
.guide-card__body { display: grid; align-content: start; gap: 6px; padding: 14px 16px 16px; }
.guide-card__title { font-size: 1.0625rem; font-weight: 800; line-height: 1.3; }
/* Long explanations are cut after 4 lines here; the full text is in the enlarged view */
.guide-card__text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    color: var(--ink-soft);
    font-size: .9375rem;
    line-height: 1.55;
}
@media (min-width: 900px) {
    .guide {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 20px;
        margin: 24px 0 0;
        padding: 0;
        overflow: visible;
    }
}

/* ---------- Unlock card ---------- */
/* Keep the download column at a calm reading width on large screens */
.section--download .card,
.section--download .outro { max-width: 760px; }

.unlock { margin-top: 24px; padding: 18px 16px; }
@media (min-width: 600px) {
    .unlock { padding: 24px 28px; }
}
.progress__label {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 10px;
    font-size: 1.0625rem;
    font-weight: 800;
}
.progress__done { color: var(--grass-ink); }

/* XP-bar style progress: one segment per step */
.xp {
    display: flex;
    gap: 2px;
    height: 16px;
    margin-top: 10px;
    padding: 0;
    border: 2px solid #1c2024;
    border-radius: 3px;
    background: #1c2024;
}
.xp__seg {
    flex: 1 1 0;
    background: #353b42;
    transition: background-color .3s ease;
}
.xp__seg.is-on { background: linear-gradient(#a5e46c 0 4px, #73bd3b 4px 100%); }

.tasks {
    display: grid;
    gap: 10px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
}
.task {
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
}
.task.is-done { border-color: var(--grass-line); background: #f7fbf4; }
.task.is-done .task__text { display: none; }
.task__row { display: flex; align-items: flex-start; gap: 14px; }
.task__body { flex: 1; min-width: 0; }
.task__title { font-size: 1rem; font-weight: 700; line-height: 1.35; }
.task__text { margin-top: 2px; color: var(--ink-soft); font-size: .9375rem; line-height: 1.5; }
.task__status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
    font-size: .875rem;
    font-weight: 700;
}
.task__status--done { color: var(--grass-ink); }

@media (min-width: 600px) {
    .task { padding: 16px 18px; }
}

/* Gate: what happens with the download right now */
.gate {
    margin-top: 18px;
    padding: 18px 16px;
    border-radius: var(--radius);
    text-align: center;
}
.gate:empty { display: none; }
.gate__icon { display: inline-grid; margin-bottom: 6px; }
.gate__icon .icon { width: 28px; height: 28px; }
.gate__title { font-size: 1.25rem; font-weight: 800; line-height: 1.3; }
.gate__text { max-width: 46ch; margin: 6px auto 0; }
.gate__label {
    margin-top: 16px;
    color: var(--grass-ink);
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.gate .countdown { margin: 8px auto 0; }
.gate .btn--download { margin-top: 14px; }
.btn--start { width: 100%; max-width: 360px; margin-top: 14px; }
.gate .gate__error + .gate__text { margin-top: 10px; }
.gate__subtle { margin-top: 10px; color: var(--ink-faint); font-size: .875rem; }
.gate__error { margin-top: 10px; color: #9b1c13; font-weight: 600; }

.gate--locked {
    border: 2px dashed var(--line-strong);
    background: var(--surface-muted);
    color: var(--ink-soft);
}
.gate--locked .gate__title { color: var(--ink); font-size: 1.0625rem; }
.gate--ready, .gate--download {
    border: 1px solid var(--grass-line);
    background: var(--grass-tint);
}
.gate--ready .gate__title, .gate--download .gate__title { color: var(--grass-ink); }
.gate--waiting {
    border: 1px solid var(--honey-line);
    background: var(--honey-tint);
    color: var(--honey-ink);
}
.gate--waiting .gate__title { color: #3d2c00; font-size: 1.0625rem; }

.platform-note {
    margin-top: 12px;
    color: var(--ink-faint);
    font-size: .875rem;
    text-align: center;
}
.noscript { margin-top: 16px; font-weight: 600; }

/* ---------- Maintenance (maintenance: true in mod-config.js) ---------- */
.maintenance-banner {
    border-bottom: 1px solid var(--honey-line);
    background: var(--honey-tint);
    color: var(--honey-ink);
}
.maintenance-banner__inner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding-top: 14px;
    padding-bottom: 14px;
}
.maintenance-banner__icon {
    display: inline-grid;
    flex: none;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius);
    background: var(--honey);
    color: #3d2c00;
}
.maintenance-banner__icon .icon { width: 20px; height: 20px; }
.maintenance-banner__title { color: #3d2c00; font-weight: 800; line-height: 1.35; }
.maintenance-banner__text { max-width: 72ch; margin-top: 2px; font-size: .9375rem; line-height: 1.5; }

.maintenance {
    margin-top: 24px;
    padding: 24px 18px;
    text-align: center;
}
@media (min-width: 600px) {
    .maintenance { padding: 32px 36px; }
}
.maintenance .slot { margin-bottom: 12px; color: #8a6400; }
.maintenance__title { font-size: 1.25rem; font-weight: 800; line-height: 1.3; }
.maintenance__text { max-width: 52ch; margin: 8px auto 0; color: var(--ink-soft); }
.maintenance__thanks { margin-top: 14px; font-weight: 700; }

/* APK details */
.apk-info { margin-top: 16px; padding: 18px 16px; }
@media (min-width: 600px) {
    .apk-info { padding: 22px 28px; }
}
.apk-info__list {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 8px 16px;
    margin-top: 12px;
}
.apk-info__list dt { color: var(--ink-faint); }
.apk-info__list dd { font-weight: 600; }
.apk-info__note { margin-top: 12px; color: var(--ink-soft); font-size: .9375rem; }
.sha { margin-top: 14px; }
.sha__label { color: var(--ink-faint); }
.sha__row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    margin-top: 6px;
}
.sha__value {
    flex: 1 1 240px;
    min-width: 0;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface-muted);
    font-family: var(--font-mono);
    font-size: .8125rem;
    line-height: 1.5;
    word-break: break-all;
}

/* Installation notes */
.install { margin-top: 16px; }
.install__summary {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 64px;
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    cursor: pointer;
    list-style: none;
}
.install__summary::-webkit-details-marker { display: none; }
.install__title { font-size: 1.0625rem; font-weight: 700; }
.install__chevron { margin-left: auto; transition: transform .2s ease; }
.install[open] .install__chevron { transform: rotate(180deg); }
.install__body {
    display: grid;
    gap: 10px;
    padding: 0 16px 18px;
    color: var(--ink-soft);
}
@media (min-width: 600px) {
    .install__summary { padding: 12px 28px; }
    .install__body { padding: 0 28px 22px 82px; }
}

.outro {
    margin-top: 40px;
    font-size: clamp(1.375rem, 1.2rem + .8vw, 1.75rem);
    font-weight: 800;
    text-align: center;
}

/* ---------- Help, bug report, creators ---------- */
.support { display: grid; gap: 16px; }
@media (min-width: 720px) {
    .support { grid-template-columns: 1fr 1fr; }
}
.support__card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 20px 18px;
}
.support__card .btn { margin-top: 6px; }
.support__title { font-size: 1.25rem; font-weight: 800; line-height: 1.3; }
.support__text { color: var(--ink-soft); }

.creator {
    display: grid;
    gap: 18px;
    padding: 20px 18px;
}
.creator__text { display: grid; gap: 8px; }
.creator__text p { color: var(--ink-soft); }
@media (min-width: 720px) {
    .creator { grid-template-columns: 1fr auto; align-items: center; gap: 32px; padding: 26px 28px; }
}
.handle { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.handle__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 48px;
    margin-bottom: 4px;
    padding: 10px 16px;
    border-radius: var(--radius);
    background: var(--night);
    color: #ffffff;
    font-weight: 700;
    text-decoration: none;
}
.handle__link:hover { background: #22272e; }

/* ---------- Footer ---------- */
.site-footer {
    padding: 36px 0 calc(28px + env(safe-area-inset-bottom));
    background: var(--night);
    color: var(--night-soft);
    font-size: .9375rem;
}
.footer__top { display: grid; gap: 20px; }
.footer__tagline { margin-top: 6px; }
.footer__social { display: flex; flex-wrap: wrap; gap: 8px; }
.footer__social a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 8px 14px;
    border: 1px solid var(--night-line);
    border-radius: var(--radius);
    color: var(--night-ink);
    font-weight: 600;
    text-decoration: none;
}
.footer__social a:hover { background: var(--night-raised); }
.footer__legal {
    display: grid;
    gap: 8px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--night-line);
    font-size: .8125rem;
}
.footer__legal a { color: var(--night-ink); }
@media (min-width: 720px) {
    .footer__top { grid-template-columns: 1fr auto; align-items: center; }
}

/* ---------- Dialogs ---------- */
html.has-modal { overflow: hidden; }
dialog { padding: 0; border: 0; }

.lightbox {
    width: 100%;
    max-width: 100%;
    height: 100%;
    max-height: 100%;
    margin: 0;
    overflow: hidden;
    background: #0b0d10;
    color: #ffffff;
}
.lightbox[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.lightbox::backdrop { background: #0b0d10; }
.lightbox__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: calc(10px + env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left));
}
.lightbox__counter { font-weight: 700; font-variant-numeric: tabular-nums; }
.lightbox__stage {
    position: relative;
    min-height: 0;
    overflow: hidden;
    touch-action: pan-y pinch-zoom;
}
.lightbox__rail {
    display: flex;
    height: 100%;
    transition: transform .32s cubic-bezier(.2, .75, .25, 1);
    will-change: transform;
}
/* Picture and caption centred together; the picture shrinks when space is short */
.lightbox__slide {
    display: flex;
    flex: 0 0 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 0;
    height: 100%;
    padding: 4px 12px;
}
.lightbox__caption {
    flex: none;
    max-width: 68ch;
    margin-top: 12px;
    color: #d9dde2;
    font-size: .9375rem;
    line-height: 1.5;
    text-align: center;
}
.lightbox__caption strong { display: block; color: #ffffff; font-size: 1rem; font-weight: 800; }
.lightbox__slide img {
    flex: 0 1 auto;
    width: auto;
    height: auto;
    min-height: 0;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    user-select: none;
    -webkit-user-drag: none;
}
.lightbox__nav {
    display: flex;
    justify-content: center;
    gap: 24px;
    padding: 10px 12px calc(14px + env(safe-area-inset-bottom));
}
@media (min-width: 768px) {
    .lightbox__slide { padding: 8px 88px 24px; }
    .lightbox__nav {
        position: absolute;
        top: 50%;
        right: 0;
        left: 0;
        justify-content: space-between;
        padding: 0 24px;
        transform: translateY(-50%);
        pointer-events: none;
    }
    .lightbox__nav .icon-btn { width: 52px; height: 52px; pointer-events: auto; }
}

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }
}
