:root {
    color-scheme: light;
    --page: #f4f7f9;
    --surface: #ffffff;
    --surface-soft: #eef3f6;
    --surface-raised: #ffffff;
    --ink: #14212b;
    --ink-soft: #394956;
    --muted: #687782;
    --line: #d8e0e5;
    --line-strong: #bcc8d0;
    --nav: #07141d;
    --nav-soft: #102430;
    --green: #079b75;
    --green-hover: #067c5e;
    --green-soft: #e8f7f2;
    --cyan: #087f9e;
    --cyan-soft: #e9f5f8;
    --amber: #9a6500;
    --amber-soft: #fff5dc;
    --red: #b83243;
    --red-soft: #fff0f2;
    --shadow: 0 14px 38px rgba(21, 40, 53, .1);
    --shadow-small: 0 5px 16px rgba(21, 40, 53, .08);
}

html[data-theme="dark"] {
    color-scheme: dark;
    --page: #0e151b;
    --surface: #151f27;
    --surface-soft: #1c2933;
    --surface-raised: #19252e;
    --ink: #eef4f6;
    --ink-soft: #c4d0d6;
    --muted: #9aabb5;
    --line: #2d3d47;
    --line-strong: #465b68;
    --nav: #050b10;
    --nav-soft: #0d1c25;
    --green: #19c596;
    --green-hover: #45d5ae;
    --green-soft: #15382f;
    --cyan: #58bed7;
    --cyan-soft: #17343e;
    --amber: #efbd59;
    --amber-soft: #392e17;
    --red: #ff8994;
    --red-soft: #3a2027;
    --shadow: 0 14px 38px rgba(0, 0, 0, .34);
    --shadow-small: 0 5px 16px rgba(0, 0, 0, .24);
}

@media (prefers-color-scheme: dark) {
    html[data-theme="auto"] {
        color-scheme: dark;
        --page: #0e151b;
        --surface: #151f27;
        --surface-soft: #1c2933;
        --surface-raised: #19252e;
        --ink: #eef4f6;
        --ink-soft: #c4d0d6;
        --muted: #9aabb5;
        --line: #2d3d47;
        --line-strong: #465b68;
        --nav: #050b10;
        --nav-soft: #0d1c25;
        --green: #19c596;
        --green-hover: #45d5ae;
        --green-soft: #15382f;
        --cyan: #58bed7;
        --cyan-soft: #17343e;
        --amber: #efbd59;
        --amber-soft: #392e17;
        --red: #ff8994;
        --red-soft: #3a2027;
        --shadow: 0 14px 38px rgba(0, 0, 0, .34);
        --shadow-small: 0 5px 16px rgba(0, 0, 0, .24);
    }

    html[data-theme="auto"] input:-webkit-autofill,
    html[data-theme="auto"] input:-webkit-autofill:hover,
    html[data-theme="auto"] input:-webkit-autofill:focus {
        -webkit-text-fill-color: var(--ink);
        box-shadow: 0 0 0 1000px var(--surface) inset;
        caret-color: var(--ink);
    }
}

* { box-sizing: border-box; }

html { min-width: 320px; scroll-behavior: smooth; }

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    background: var(--page);
    color: var(--ink);
    font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    letter-spacing: 0;
}

body.drawer-open { overflow: hidden; }

a { color: var(--cyan); text-underline-offset: 3px; }
a:hover { color: var(--green-hover); }
button, input, select, textarea { letter-spacing: 0; }
button, summary, a { -webkit-tap-highlight-color: transparent; }
img, svg { max-width: 100%; }
.icon, [data-lucide] { width: 1em; height: 1em; flex: 0 0 auto; stroke-width: 2; }

:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--cyan) 38%, transparent);
    outline-offset: 2px;
}

.wrap { width: min(1120px, calc(100% - 32px)); margin-inline: auto; }
.muted { color: var(--muted); }
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 200; padding: 9px 13px; border-radius: 6px; background: var(--surface); color: var(--ink); transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

.service-bar { min-height: 34px; border-bottom: 1px solid rgba(255, 255, 255, .09); background: var(--nav); }
.service-nav { display: flex; min-height: 34px; align-items: center; gap: 3px; }
.service-label { margin-right: auto; color: #7f929f; font-size: .68rem; font-weight: 750; text-transform: uppercase; }
.service-nav a { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; border-radius: 5px; color: #aebec8; font-size: .72rem; font-weight: 700; text-decoration: none; }
.service-nav a:hover, .service-nav a.is-current { background: rgba(255, 255, 255, .08); color: #fff; }
.service-nav a span { color: #f2c562; font-size: .62rem; text-transform: uppercase; }

.appbar { position: sticky; top: 0; z-index: 70; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 96%, transparent); box-shadow: 0 2px 10px rgba(16, 35, 47, .05); backdrop-filter: blur(12px); }
.appbar-inner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 20px; width: min(1180px, calc(100% - 32px)); min-height: 68px; margin-inline: auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; color: var(--ink); text-decoration: none; }
.brand-mark { display: grid; width: 34px; height: 34px; place-items: center; border: 1px solid color-mix(in srgb, var(--green) 38%, var(--line)); border-radius: 7px; background: var(--green-soft); color: var(--green); }
.brand-mark svg { width: 20px; height: 20px; }
.brand-copy { display: grid; line-height: 1.05; }
.brand-name { font-size: 1rem; font-weight: 850; }
.brand-product { color: var(--green); font-size: .65rem; font-weight: 850; text-transform: uppercase; }

.appnav { display: flex; min-width: 0; align-items: center; gap: 4px; }
.appnav-link, .nav-dropdown summary { display: inline-flex; min-height: 40px; align-items: center; gap: 7px; padding: 8px 10px; border: 1px solid transparent; border-radius: 6px; color: var(--ink-soft); font-size: .82rem; font-weight: 750; text-decoration: none; cursor: pointer; list-style: none; user-select: none; }
.appnav-link:hover, .appnav-link.is-active, .nav-dropdown summary:hover, .nav-dropdown[open] summary, .nav-dropdown.is-active summary { border-color: var(--line); background: var(--surface-soft); color: var(--ink); }
.nav-dropdown { position: relative; }
.nav-dropdown summary::-webkit-details-marker { display: none; }
.nav-dropdown summary::after { width: 6px; height: 6px; margin-left: 2px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; content: ""; transform: translateY(-2px) rotate(45deg); transition: transform .14s ease; }
.nav-dropdown[open] summary::after { transform: translateY(2px) rotate(225deg); }
.nav-dropdown-panel { position: absolute; top: calc(100% + 9px); left: 0; z-index: 85; display: grid; width: 294px; max-height: min(620px, calc(100vh - 118px)); padding: 7px; overflow-y: auto; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); box-shadow: var(--shadow); }
.nav-dropdown-account .nav-dropdown-panel { right: 0; left: auto; }
.nav-dropdown-panel a { display: grid; gap: 1px; padding: 9px 10px; border-radius: 5px; color: var(--ink); text-decoration: none; }
.nav-dropdown-panel a:hover, .nav-dropdown-panel a.is-current { background: var(--green-soft); color: var(--green-hover); }
.nav-dropdown-panel strong { font-size: .82rem; }
.nav-dropdown-panel small { color: var(--muted); font-size: .7rem; }
.nav-group-label { padding: 8px 10px 4px; color: var(--muted); font-size: .63rem; font-weight: 850; text-transform: uppercase; }
.nav-group-label:not(:first-child) { margin-top: 4px; border-top: 1px solid var(--line); }

.balance-chip { display: flex; min-width: 0; max-width: 230px; align-items: center; gap: 9px; padding: 7px 11px; border: 1px solid color-mix(in srgb, var(--green) 35%, var(--line)); border-radius: 7px; background: var(--green-soft); color: var(--green-hover); text-decoration: none; }
.balance-chip > svg { width: 18px; height: 18px; }
.balance-chip span { display: grid; min-width: 0; line-height: 1.15; }
.balance-chip small { color: var(--muted); font-size: .61rem; font-weight: 750; text-transform: uppercase; }
.balance-chip strong { overflow: hidden; font-size: .76rem; font-variant-numeric: tabular-nums; text-overflow: ellipsis; white-space: nowrap; }
.balance-chip:hover { border-color: var(--green); background: color-mix(in srgb, var(--green-soft) 80%, var(--surface)); }
.guest-nav { display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.guest-nav > a:not(.btn) { color: var(--muted); font-size: .78rem; font-weight: 700; text-decoration: none; }

.icon-btn { display: inline-grid; width: 40px; height: 40px; place-items: center; padding: 0; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--ink); cursor: pointer; }
.icon-btn:hover { border-color: var(--line-strong); background: var(--surface-soft); }
.mobile-menu-toggle { display: none; }
.mobile-nav-backdrop { position: fixed; inset: 0; z-index: 98; background: rgba(2, 10, 15, .6); }
.mobile-nav-backdrop[hidden] { display: none; }
.mobile-drawer { position: fixed; top: 0; right: 0; z-index: 99; width: min(350px, calc(100% - 42px)); height: 100dvh; overflow-y: auto; border-left: 1px solid var(--line); background: var(--surface); box-shadow: -16px 0 42px rgba(0, 0, 0, .24); transform: translateX(105%); visibility: hidden; transition: transform .18s ease, visibility .18s; }
.mobile-drawer[aria-hidden="false"] { transform: translateX(0); visibility: visible; }
.mobile-drawer-head { position: sticky; top: 0; z-index: 2; display: flex; min-height: 64px; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 15px; border-bottom: 1px solid var(--line); background: var(--surface); }
.mobile-balance { display: grid; gap: 2px; margin: 14px; padding: 12px 13px; overflow: hidden; border: 1px solid color-mix(in srgb, var(--green) 35%, var(--line)); border-radius: 7px; background: var(--green-soft); color: var(--green-hover); text-decoration: none; }
.mobile-balance small { color: var(--muted); font-size: .68rem; text-transform: uppercase; }
.mobile-balance strong { overflow-wrap: anywhere; font-size: 1rem; font-variant-numeric: tabular-nums; }
.mobile-nav-links { display: grid; padding: 0 10px 20px; }
.mobile-nav-links > span { margin-top: 8px; padding: 9px 8px 4px; border-top: 1px solid var(--line); color: var(--muted); font-size: .64rem; font-weight: 850; text-transform: uppercase; }
.mobile-nav-links > span:first-child { border-top: 0; }
.mobile-nav-links a { display: flex; min-height: 42px; align-items: center; gap: 10px; padding: 9px; border-radius: 6px; color: var(--ink-soft); font-size: .84rem; font-weight: 700; text-decoration: none; }
.mobile-nav-links a:hover { background: var(--surface-soft); color: var(--ink); }

.app-main { min-height: calc(100vh - 206px); padding-block: 30px 62px; }
h1, h2, h3 { margin-top: 0; color: var(--ink); letter-spacing: 0; }
h1 { margin-bottom: 9px; font-size: 2rem; line-height: 1.16; }
h2 { margin-bottom: 11px; font-size: 1.2rem; line-height: 1.25; }
h3 { margin-bottom: 7px; font-size: .98rem; }
p { margin-top: 0; }
.page-header { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 24px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.page-header > div { min-width: 0; }
.page-header p { max-width: 720px; margin: 0; color: var(--muted); }
.eyebrow, .auth-kicker { display: block; margin-bottom: 5px; color: var(--green); font-size: .68rem; font-weight: 850; text-transform: uppercase; }
.section-header { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 30px 0 12px; }
.section-header h2, .section-header p { margin: 0; }
.section-tabs { position: sticky; top: 78px; z-index: 20; display: flex; gap: 4px; margin: 0 0 18px; padding: 5px; overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: color-mix(in srgb, var(--surface) 95%, transparent); box-shadow: var(--shadow-small); backdrop-filter: blur(10px); }
.section-tabs a { display: inline-flex; min-height: 36px; flex: 0 0 auto; align-items: center; gap: 6px; padding: 7px 10px; border-radius: 5px; color: var(--ink-soft); font-size: .75rem; font-weight: 750; text-decoration: none; }
.section-tabs a:hover { background: var(--surface-soft); color: var(--ink); }
[id] { scroll-margin-top: 136px; }

.card { margin: 0 0 16px; padding: 22px 0; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; box-shadow: none; }
.card:first-child, .page-header + .card { border-top: 0; padding-top: 0; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 13px; }
.grid > .card, .grid > .box, .feature-card, .box { padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-small); }
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin-block: 18px 26px; border-block: 1px solid var(--line); }
.metric, .metric-card { min-width: 0; padding: 15px 16px; border-right: 1px solid var(--line); background: transparent; }
.metric:last-child, .metric-card:last-child { border-right: 0; }
.metric span, .metric-card span { display: block; color: var(--muted); font-size: .72rem; }
.metric strong, .metric-card strong { display: block; margin: 4px 0 2px; overflow-wrap: anywhere; color: var(--ink); font-size: 1.3rem; font-variant-numeric: tabular-nums; line-height: 1.25; }
.metric-label { display: flex !important; align-items: center; gap: 6px; }
.metric-label svg { color: var(--cyan); }
.metric-card-primary { background: var(--green-soft); }
.metric-email { font-size: .96rem !important; }

.quick-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.quick-link { display: flex; min-height: 142px; flex-direction: column; padding: 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); text-decoration: none; transition: border-color .14s ease, transform .14s ease, box-shadow .14s ease; }
.quick-link:hover { border-color: color-mix(in srgb, var(--green) 46%, var(--line)); box-shadow: var(--shadow-small); transform: translateY(-1px); }
.quick-link > svg { width: 22px; height: 22px; margin-bottom: 14px; color: var(--cyan); }
.quick-link strong { margin-bottom: 4px; }
.quick-link span { color: var(--muted); font-size: .8rem; }
.quick-link b { display: flex; align-items: center; gap: 5px; margin-top: auto; padding-top: 16px; color: var(--green-hover); font-size: .76rem; }
.quick-link-accent { border-color: color-mix(in srgb, var(--green) 38%, var(--line)); background: var(--green-soft); }

.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; align-items: end; }
form p { margin-bottom: 15px; }
label, legend { display: block; margin: 0 0 6px; color: var(--ink-soft); font-size: .78rem; font-weight: 750; }
input, select, textarea { width: 100%; min-height: 43px; padding: 10px 11px; border: 1px solid var(--line-strong); border-radius: 7px; outline: none; background: var(--surface); color: var(--ink); font: inherit; }
input::placeholder, textarea::placeholder { color: color-mix(in srgb, var(--muted) 78%, transparent); }
input:focus, select:focus, textarea:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px color-mix(in srgb, var(--cyan) 16%, transparent); }
input:disabled, select:disabled, textarea:disabled { opacity: .62; cursor: not-allowed; }
textarea { min-height: 100px; resize: vertical; }
fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
code, pre { font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace; }
code { padding: 2px 5px; border-radius: 4px; background: var(--surface-soft); color: var(--ink-soft); overflow-wrap: anywhere; }
pre { max-width: 100%; padding: 13px; overflow: auto; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-soft); color: var(--ink); }

.btn { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 8px; padding: 9px 15px; border: 1px solid transparent; border-radius: 7px; background: var(--green); color: #fff; font: inherit; font-size: .87rem; font-weight: 800; text-align: center; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--green-hover); color: #fff; }
.btn-small { min-height: 35px; padding: 6px 11px; font-size: .76rem; }
.btn-block { width: 100%; }
.btn-secondary { border-color: var(--line-strong); background: var(--surface); color: var(--ink); }
.btn-secondary:hover { background: var(--surface-soft); color: var(--ink); }
.btn-danger { border-color: color-mix(in srgb, var(--red) 42%, var(--line)); background: var(--red-soft); color: var(--red); }
.btn-danger:hover { background: color-mix(in srgb, var(--red-soft) 80%, var(--red)); color: var(--red); }
.btn-ghost-dark { border-color: rgba(255, 255, 255, .28); background: rgba(4, 15, 20, .48); color: #fff; }
.btn-ghost-dark:hover { background: rgba(4, 15, 20, .72); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

.alert { margin-bottom: 16px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 7px; font-size: .86rem; }
.alert-success { border-color: color-mix(in srgb, var(--green) 38%, var(--line)); background: var(--green-soft); color: var(--green-hover); }
.alert-error { border-color: color-mix(in srgb, var(--red) 38%, var(--line)); background: var(--red-soft); color: var(--red); }
.alert-info { border-color: color-mix(in srgb, var(--cyan) 35%, var(--line)); background: var(--cyan-soft); color: var(--cyan); }
.alert-warning { border-color: color-mix(in srgb, var(--amber) 40%, var(--line)); background: var(--amber-soft); color: var(--amber); }
.status-badge, .pill { display: inline-flex; width: fit-content; align-items: center; gap: 6px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-soft); color: var(--ink-soft); font-size: .68rem; font-weight: 800; }
.status-badge-warning { border-color: rgba(245, 194, 91, .48); background: rgba(36, 26, 9, .68); color: #ffd88c; }
.pill-success { border-color: color-mix(in srgb, var(--green) 32%, var(--line)); background: var(--green-soft); color: var(--green-hover); }

.toggle-row { display: flex; align-items: center; gap: 11px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-soft); cursor: pointer; }
.toggle-input { position: absolute; width: 1px !important; height: 1px !important; opacity: 0; }
.toggle-control { position: relative; width: 44px; height: 24px; flex: 0 0 auto; border: 1px solid var(--line-strong); border-radius: 999px; background: color-mix(in srgb, var(--line-strong) 72%, var(--surface)); }
.toggle-control::after { position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); content: ""; transition: transform .16s ease; }
.toggle-input:focus-visible + .toggle-control { outline: 3px solid color-mix(in srgb, var(--cyan) 28%, transparent); outline-offset: 2px; }
.toggle-input:checked + .toggle-control { border-color: var(--green); background: var(--green); }
.toggle-input:checked + .toggle-control::after { transform: translateX(20px); }
.toggle-copy { display: grid; min-width: 0; }
.toggle-copy small { color: var(--muted); }

.table-wrap { max-width: 100%; overflow-x: auto; border-block: 1px solid var(--line); }
table { width: 100%; min-width: 620px; border-collapse: collapse; background: transparent; font-variant-numeric: tabular-nums; }
th, td { padding: 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { position: sticky; top: 0; z-index: 1; background: var(--page); color: var(--muted); font-size: .66rem; font-weight: 850; text-transform: uppercase; }
tbody tr:hover { background: color-mix(in srgb, var(--surface-soft) 55%, transparent); }
tbody tr:last-child td { border-bottom: 0; }

.feature-card { display: flex; min-height: 215px; flex-direction: column; }
.feature-card .feature-actions { margin-top: auto; padding-top: 14px; }
.ad-slot { display: grid; max-width: 100%; min-height: 72px; margin: 16px 0; padding: 8px; place-items: center; overflow: auto; border-block: 1px dashed var(--line-strong); background: var(--surface-soft); }
.sponsored-label { display: block; margin-bottom: 6px; color: var(--muted); font-size: .62rem; font-weight: 750; text-align: center; text-transform: uppercase; }
.smart-ad-section { margin: 28px 0; }
.smart-ad-grid { display: grid; gap: 12px; }
.smart-ad-frame { display: block; width: 100%; height: 110px; border: 0; background: transparent; }
.smart-ad-frame[hidden] { display: none; }

.offerwall-shell { display: grid; min-width: 0; padding: 18px; place-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-soft); }
.offerwall-frame { width: min(360px, 100%); min-width: 0; max-width: 100%; height: 360px; border: 0; border-radius: 8px; background: #fff; box-shadow: var(--shadow-small); }
.offerwall-status-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 18px; border-block: 1px solid var(--line); }
.offerwall-status-strip > div { display: flex; min-width: 0; align-items: center; gap: 10px; padding: 12px 14px; border-right: 1px solid var(--line); }
.offerwall-status-strip > div:last-child { border-right: 0; }
.offerwall-status-strip > div > svg { width: 20px; height: 20px; color: var(--cyan); }
.offerwall-status-strip span { display: grid; min-width: 0; color: var(--muted); font-size: .68rem; }
.offerwall-status-strip strong { overflow-wrap: anywhere; color: var(--ink); font-size: .84rem; }
.countdown { color: var(--amber); font-variant-numeric: tabular-nums; font-weight: 750; }
.captcha-fallback { max-width: 100%; margin: 13px 0; overflow: hidden; }
.captcha-status { margin: 7px 0 0; font-size: .74rem; }
.captcha-status:empty { display: none; }
.cf-turnstile, .h-captcha { max-width: 100%; overflow: hidden; }

.currency-selector, .preference-selector { margin: 17px 0 0; }
.currency-choice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.currency-choice, .preference-choice { position: relative; min-width: 0; margin: 0; cursor: pointer; }
.currency-choice-input, .preference-choice input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.currency-choice-content { display: grid; min-height: 148px; padding: 13px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface-soft); transition: border-color .14s ease, background .14s ease; }
.currency-choice:hover .currency-choice-content { border-color: color-mix(in srgb, var(--green) 46%, var(--line)); }
.currency-choice-input:focus-visible + .currency-choice-content, .preference-choice input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--cyan) 22%, transparent); outline-offset: 2px; }
.currency-choice-input:checked + .currency-choice-content, .preference-choice input:checked + span { border-color: var(--green); background: var(--green-soft); box-shadow: inset 0 0 0 1px var(--green); }
.currency-choice-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.currency-choice-head strong { color: var(--ink); font-size: 1rem; }
.currency-choice-head small { color: var(--muted); font-size: .67rem; text-align: right; }
.currency-choice-amount { align-self: center; overflow-wrap: anywhere; color: var(--ink); font-size: .96rem; font-weight: 800; }
.currency-choice-meta { color: var(--green-hover); font-size: .74rem; font-weight: 800; }
.currency-choice-minimum, .cache-note { color: var(--muted); font-size: .68rem; }
.currency-choice.is-disabled { cursor: not-allowed; }
.currency-choice.is-disabled .currency-choice-content { opacity: .52; background: var(--surface); }
.cache-note { margin: 9px 0 0; }
.preference-choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.preference-choice > span { display: grid; min-height: 76px; gap: 3px; padding: 12px 13px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface-soft); }
.preference-choice strong { color: var(--ink); }
.preference-choice small { color: var(--muted); font-weight: 500; }

.level-progress { margin-top: 14px; }
.level-progress-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 7px; color: var(--muted); font-size: .74rem; }
.level-progress-track { height: 8px; overflow: hidden; border-radius: 999px; background: var(--line); }
.level-progress-fill { height: 100%; border-radius: inherit; background: var(--green); }

.admin-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.admin-form-grid .field-wide { grid-column: 1 / -1; }
.toggle-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.contest-prize-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.is-admin-page .app-main { width: min(1360px, calc(100% - 32px)); }
.is-admin-page .card { padding-block: 18px; }
.is-admin-page .row { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.is-admin-page input, .is-admin-page select { min-height: 39px; padding-block: 8px; }
.is-admin-page th, .is-admin-page td { padding: 8px; font-size: .78rem; }
.admin-feature-section { padding-block: 18px; border-top: 1px solid var(--line); }
.admin-feature-section > h2 { margin-bottom: 13px; }
.admin-section-tabs { top: 78px; }
.danger-section { border-top-color: color-mix(in srgb, var(--red) 45%, var(--line)); }

.claim-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr); gap: 22px; align-items: start; }
.claim-layout > .card { padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-small); }
.claim-summary { display: grid; gap: 11px; }
.claim-summary-row { display: flex; justify-content: space-between; gap: 15px; padding-bottom: 9px; border-bottom: 1px solid var(--line); }
.claim-summary-row:last-child { padding-bottom: 0; border-bottom: 0; }
.claim-summary-row span { color: var(--muted); }

.brand-band { position: relative; isolation: isolate; min-height: 330px; margin-bottom: 0; overflow: hidden; border-radius: 8px 8px 0 0; background: #081820 url("moneyrain-rain-v1.webp") center / cover no-repeat; color: #fff; }
.brand-band::before { position: absolute; inset: 0; z-index: -1; background: rgba(2, 13, 18, .66); content: ""; }
.brand-band-content { display: flex; width: min(660px, 100%); min-height: inherit; flex-direction: column; align-items: flex-start; justify-content: center; padding: 44px; }
.brand-band h1, .brand-band h2 { color: #fff; }
.brand-band h1 { max-width: 620px; margin: 14px 0 12px; font-size: 2.7rem; line-height: 1.08; }
.brand-band p { max-width: 590px; margin-bottom: 21px; color: #d9e5e8; font-size: 1rem; }
.brand-points { display: flex; flex-wrap: wrap; gap: 9px 16px; }
.brand-points span { display: inline-flex; align-items: center; gap: 7px; color: #eef7f6; font-size: .78rem; font-weight: 700; }

.auth-brand-band { min-height: 360px; }
.public-stat-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 34px; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 8px 8px; background: var(--surface); }
.public-stat-strip > div { min-width: 0; padding: 14px 17px; border-right: 1px solid var(--line); }
.public-stat-strip > div:last-child { border-right: 0; }
.public-stat-strip span { display: block; color: var(--muted); font-size: .68rem; }
.public-stat-strip strong { display: block; overflow-wrap: anywhere; color: var(--ink); font-size: 1rem; font-variant-numeric: tabular-nums; }
.auth-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(250px, .55fr); gap: 22px; width: min(880px, 100%); margin: 0 auto; align-items: start; }
.auth-panel { padding: 24px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-small); }
.auth-panel h2 { margin-bottom: 5px; font-size: 1.45rem; }
.auth-segments { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: -10px -10px 22px; padding: 4px; border-radius: 7px; background: var(--surface-soft); }
.auth-segments a { display: inline-flex; min-height: 40px; align-items: center; justify-content: center; gap: 7px; padding: 8px; border: 1px solid transparent; border-radius: 5px; color: var(--muted); font-size: .8rem; font-weight: 800; text-decoration: none; }
.auth-segments a.is-active { border-color: var(--line); background: var(--surface); color: var(--ink); box-shadow: 0 1px 4px rgba(10, 28, 39, .08); }
.auth-form { margin-top: 19px; }
.auth-secondary-form { margin-top: 9px; }
.auth-text-link { display: block; margin-top: 14px; font-size: .78rem; font-weight: 700; text-align: center; }
.auth-legal { margin: 13px 0 0; color: var(--muted); font-size: .72rem; }
.auth-trust-panel { padding: 22px 0 22px 22px; border-left: 1px solid var(--line); }
.trust-icon { display: grid; width: 42px; height: 42px; margin-bottom: 15px; place-items: center; border: 1px solid color-mix(in srgb, var(--green) 38%, var(--line)); border-radius: 8px; background: var(--green-soft); color: var(--green); }
.trust-icon svg { width: 23px; height: 23px; }
.auth-trust-panel p { color: var(--muted); font-size: .83rem; }
.trust-list { display: grid; gap: 9px; margin-top: 17px; }
.trust-list span { display: flex; align-items: center; gap: 8px; color: var(--ink-soft); font-size: .78rem; font-weight: 700; }
.trust-list svg { color: var(--green); }
.utility-panel { width: min(540px, 100%); margin: 34px auto; padding: 25px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-small); }
.utility-panel h1 { font-size: 1.55rem; }
.utility-panel .trust-icon { margin-bottom: 18px; }
.utility-icon-warning { border-color: color-mix(in srgb, var(--amber) 38%, var(--line)); background: var(--amber-soft); color: var(--amber); }
.legal-page { width: min(820px, 100%); padding-left: 22px; border-left: 3px solid var(--line); color: var(--ink-soft); }
.legal-page p { margin-bottom: 18px; }
.legal-page p:last-child { margin-bottom: 0; }

.development-shell { width: min(1040px, calc(100% - 32px)); min-height: calc(100vh - 34px); margin-inline: auto; padding-block: 54px; }
.brand-band-development { min-height: 520px; border-radius: 8px; box-shadow: var(--shadow); }
.development-meta { display: flex; justify-content: center; gap: 12px 28px; padding: 18px; color: var(--muted); font-size: .76rem; }
.development-meta span { display: inline-flex; align-items: center; gap: 7px; }

.public-footer { padding: 22px 0; border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: .76rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.footer-brand { display: inline-flex; align-items: center; gap: 7px; color: var(--ink-soft); font-weight: 800; }
.footer-links { display: flex; gap: 12px; flex-wrap: wrap; }
.public-footer a { color: var(--muted); text-decoration: none; }
.public-footer a:hover { color: var(--cyan); }

html[data-theme="dark"] input:-webkit-autofill,
html[data-theme="dark"] input:-webkit-autofill:hover,
html[data-theme="dark"] input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--ink);
    box-shadow: 0 0 0 1000px var(--surface) inset;
    caret-color: var(--ink);
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

@media (max-width: 1020px) {
    .appbar-inner { gap: 10px; }
    .appnav-link, .nav-dropdown summary { padding-inline: 8px; }
    .balance-chip { max-width: 186px; }
}

@media (max-width: 899px) {
    .service-bar, .appnav, .guest-nav { display: none; }
    .appbar-inner { grid-template-columns: minmax(0, 1fr) auto auto; min-height: 62px; }
    .mobile-menu-toggle { display: inline-grid; }
    .balance-chip { max-width: 196px; }
    .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .metric:nth-child(2n), .metric-card:nth-child(2n) { border-right: 0; }
    .quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .contest-prize-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .auth-layout { grid-template-columns: minmax(0, 1fr) 240px; }
    .section-tabs { top: 70px; }
    .admin-section-tabs { top: 70px; }
}

@media (max-width: 680px) {
    .wrap, .appbar-inner { width: min(100% - 24px, 1120px); }
    .app-main { padding-block: 22px 46px; }
    h1 { font-size: 1.62rem; }
    .page-header { align-items: flex-start; flex-direction: column; margin-bottom: 18px; }
    .page-header .actions { width: 100%; }
    .metric-grid, .quick-grid, .claim-layout, .admin-form-grid, .toggle-grid, .auth-layout { grid-template-columns: 1fr; }
    .metric, .metric-card { border-right: 0; border-bottom: 1px solid var(--line); }
    .metric:last-child, .metric-card:last-child { border-bottom: 0; }
    .grid { grid-template-columns: 1fr; }
    .row { grid-template-columns: 1fr; }
    .currency-choice-grid, .preference-choice-grid { grid-template-columns: 1fr; }
    .currency-choice-content { min-height: 122px; }
    .contest-prize-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .auth-trust-panel { padding: 20px 0 0; border-top: 1px solid var(--line); border-left: 0; }
    .brand-band-content { padding: 30px 24px; }
    .brand-band h1 { font-size: 2.05rem; }
    .auth-brand-band { min-height: 330px; }
    .public-stat-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .public-stat-strip > div:nth-child(2) { border-right: 0; }
    .public-stat-strip > div:nth-child(-n + 2) { border-bottom: 1px solid var(--line); }
    .development-shell { width: min(100% - 24px, 1040px); padding-block: 24px; }
    .brand-band-development { min-height: calc(100dvh - 110px); }
    .footer-inner { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 500px) {
    .brand-mark { width: 31px; height: 31px; }
    .brand-copy { display: flex; align-items: baseline; gap: 4px; }
    .brand-name { font-size: .88rem; }
    .brand-product { font-size: .57rem; }
    .balance-chip { max-width: 132px; padding: 6px 8px; }
    .balance-chip > svg, .balance-chip small { display: none; }
    .balance-chip strong { font-size: .68rem; }
    .appbar-inner { gap: 7px; }
    .icon-btn { width: 38px; height: 38px; }
    .card { padding-block: 18px; }
    .grid > .card, .grid > .box, .feature-card, .box, .claim-layout > .card { padding: 15px; }
    .auth-panel { padding: 19px; }
    .auth-segments { margin: -5px -5px 19px; }
    .brand-band { border-radius: 0; margin-inline: -12px; }
    .public-stat-strip { margin-inline: -12px; border-right: 0; border-left: 0; border-radius: 0; }
    .brand-band-content { padding: 28px 20px; }
    .brand-band h1 { font-size: 1.82rem; }
    .brand-band p { font-size: .89rem; }
    .development-shell .brand-band { margin-inline: 0; border-radius: 8px; }
    .actions .btn { flex: 1 1 auto; }
    .offerwall-shell { margin-inline: -4px; padding: 8px 4px; }
    .offerwall-frame { width: min(360px, calc(100vw - 32px)); height: 360px; }
    .offerwall-status-strip { grid-template-columns: 1fr; }
    .offerwall-status-strip > div { border-right: 0; border-bottom: 1px solid var(--line); }
    .offerwall-status-strip > div:last-child { border-bottom: 0; }
    .utility-panel { margin-block: 14px; padding: 19px; }
    .legal-page { padding-left: 14px; }
}

@media (max-width: 360px) {
    .brand-product { display: none; }
    .balance-chip { max-width: 116px; }
    .balance-chip strong { font-size: .64rem; }
    .auth-panel { padding: 16px; }
    .auth-segments a { font-size: .73rem; }
}
