/* Site theme: dark frame, light reading.
   Tokens, the site header and footer, buttons and the dark / light bands.
   Loaded after chrome.css (fonts + brand lockup) by the marketing pages and
   the public board. The ops console keeps chrome.css alone. */

:root {
    --ink-950: #060a12;
    --ink-900: #0b1220;
    --ink-800: #111a2c;
    --ink-700: #1a2539;
    --ink-line: rgba(255, 255, 255, .09);
    --ink-line-strong: rgba(255, 255, 255, .16);
    --on-ink: #e7ecf4;
    --on-ink-muted: #95a3b8;

    --page: #eef1f5;
    --page-2: #e4e9f0;
    --card: #ffffff;
    --line: #dbe1ea;
    --line-strong: #c3ccd9;
    --text: #1d2939;
    --text-strong: #0b1220;
    --muted: #56657a;

    /* One accent: bright amber / gold. Never green or red, which the board
       keeps for odds moving up / down and for live. */
    --brand: #f5a623;
    --brand-strong: #e08e0b;
    --brand-text: #9a5806;
    --brand-ink: #1b1204;
    --brand-soft: #fff3d9;
    --brand-glow: rgba(245, 166, 35, .28);

    --live: #e11d38;
    --up: #059669;
    /* --up as small text or behind white text: 4.5:1 on white (--up is 3.8:1). */
    --up-text: #047857;
    --down: #c0262d;

    --radius: 12px;
    --radius-sm: 8px;
    --shadow-card: 0 1px 2px rgba(11, 18, 32, .05), 0 10px 28px rgba(11, 18, 32, .07);
    --shadow-lift: 0 24px 60px rgba(6, 10, 18, .35);
    --container: 1180px;
    --top-h: 64px;
    --font-display: "Space Grotesk", "Segoe UI", sans-serif;
    --font-body: Manrope, "Segoe UI", sans-serif;
    --font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 10px;
    border: 1px solid transparent;
    font-family: var(--font-body);
    font-size: .95rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.01em;
    white-space: nowrap;
    cursor: pointer;
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.btn--sm { padding: 9px 15px; font-size: .86rem; }
.btn--lg { padding: 15px 26px; font-size: 1.02rem; }

.btn--brand { background: var(--brand); color: var(--brand-ink); box-shadow: 0 8px 22px var(--brand-glow); }
.btn--brand:hover { background: #ffb53d; color: var(--brand-ink); }

.btn--ghost-dark { background: rgba(255, 255, 255, .05); color: var(--on-ink); border-color: var(--ink-line-strong); }
.btn--ghost-dark:hover { background: rgba(255, 255, 255, .1); color: #fff; border-color: rgba(255, 255, 255, .3); }

.btn--ghost { background: var(--card); color: var(--text-strong); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--text-strong); color: var(--text-strong); }

.btn--ink { background: var(--ink-900); color: #fff; }
.btn--ink:hover { background: var(--ink-700); color: #fff; }

.btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }

/* ---------- Bands ---------- */
.band { position: relative; padding-block: clamp(56px, 4rem + 3vw, 104px); }
.band--tight { padding-block: clamp(36px, 2rem + 2vw, 60px); }
.band--light { background: var(--page); color: var(--text); }
.band--white { background: var(--card); color: var(--text); }
.band--dark {
    background:
        radial-gradient(900px 420px at 85% -10%, rgba(245, 166, 35, .10), transparent 60%),
        radial-gradient(700px 380px at -5% 110%, rgba(59, 130, 246, .08), transparent 60%),
        var(--ink-900);
    color: var(--on-ink);
}
.band--dark h1, .band--dark h2, .band--dark h3, .band--dark h4 { color: #fff; }
.band--dark .muted, .band--dark .lede { color: var(--on-ink-muted); }
.band--dark .eyebrow { color: var(--brand); }

/* ---------- Site header (dark) ---------- */
.site-top {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(9, 14, 25, .94);
    backdrop-filter: saturate(1.4) blur(14px);
    -webkit-backdrop-filter: saturate(1.4) blur(14px);
    border-bottom: 1px solid var(--ink-line);
    color: var(--on-ink);
}
.site-top__inner {
    width: min(var(--container), 100% - 32px);
    margin-inline: auto;
    min-height: var(--top-h);
    display: flex;
    align-items: center;
    gap: 28px;
}
.site-top--wide .site-top__inner { width: min(1520px, 100% - 32px); }

.site-top .brand,
.site-top .brand__title { color: #fff; }
.site-top .brand__sub { color: var(--on-ink-muted); }
.site-top .brand__mark { box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }

.site-nav { display: flex; align-items: center; gap: 2px; margin-right: auto; }
.site-nav a {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 13px;
    border-radius: 8px;
    color: #c9d3e1;
    font-family: var(--font-body);
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
    transition: color .15s ease, background .15s ease;
}
.site-nav a:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.site-nav a[aria-current="page"] { color: #fff; }
.site-nav a[aria-current="page"]::after {
    content: "";
    position: absolute;
    left: 13px;
    right: 13px;
    bottom: 3px;
    height: 2px;
    border-radius: 2px;
    background: var(--brand);
}

.live-pip {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-radius: 50%;
    background: var(--live);
    box-shadow: 0 0 0 0 rgba(225, 29, 56, .5);
    animation: live-pip 1.6s ease-out infinite;
}
@keyframes live-pip {
    0% { box-shadow: 0 0 0 0 rgba(225, 29, 56, .5); }
    70% { box-shadow: 0 0 0 7px rgba(225, 29, 56, 0); }
    100% { box-shadow: 0 0 0 0 rgba(225, 29, 56, 0); }
}
.live-count {
    min-width: 22px;
    padding: 1px 7px;
    border-radius: 999px;
    background: var(--live);
    color: #fff;
    font-size: .7rem;
    font-weight: 800;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.site-top__cta { display: flex; align-items: center; gap: 10px; }
/* Log in beside Start free for guests; signed in, the account menu below. */
.site-top__login { color: var(--on-ink, #e2e8f0); font-weight: 700; font-size: .92rem; text-decoration: none; opacity: .85; white-space: nowrap; }
.site-top__login:hover { opacity: 1; color: #fff; }
/* Language switcher (growth-plan task 1): only on selling pages, only once another language is live. */
.lang-switch { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: .84rem; }
.lang-switch a { color: var(--on-ink-muted, #94a3b8); text-decoration: none; white-space: nowrap; }
.lang-switch a:hover, .lang-switch a[aria-current] { color: #fff; }
.lang-switch a[aria-current] { font-weight: 700; }

/* Account menu (signed in): initials button, white card under it. */
.acct { position: relative; }
.acct > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 4px; padding: 3px 6px 3px 3px; border-radius: 999px; border: 1px solid var(--ink-line-strong); color: var(--on-ink-muted); transition: border-color .15s, background .15s; }
.acct > summary::-webkit-details-marker { display: none; }
.acct > summary:hover, .acct[open] > summary { border-color: rgba(245, 166, 35, .55); background: rgba(255, 255, 255, .05); color: #fff; }
.acct > summary:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.acct__chev { display: grid; transition: transform .15s; }
.acct[open] .acct__chev { transform: rotate(180deg); }
.acct__avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto; background: linear-gradient(135deg, #2a3954, #1a2539); color: #fff; font-family: var(--font-display); font-weight: 700; font-size: .82rem; letter-spacing: .02em; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); }
.acct__avatar--pro { background: linear-gradient(135deg, #ffc35a, var(--brand-strong)); color: var(--brand-ink); box-shadow: none; }
.acct__avatar--lg { width: 42px; height: 42px; font-size: .95rem; }
.acct__panel { position: absolute; right: 0; top: calc(100% + 10px); z-index: 60; width: min(300px, calc(100vw - 24px)); padding: 8px; border-radius: 14px; background: #fff; color: var(--text); border: 1px solid var(--line); box-shadow: 0 24px 50px rgba(6, 10, 18, .28); display: grid; gap: 4px; }
.acct__who { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 8px 12px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.acct__id { display: grid; min-width: 0; line-height: 1.3; }
.acct__id strong, .acct__id small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct__id strong { color: var(--text-strong); font-size: .92rem; }
.acct__id small { color: var(--muted); font-size: .78rem; }
.acct__plan { padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 800; background: var(--page); border: 1px solid var(--line); color: var(--muted); }
.acct__plan--pro { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.acct > summary { padding: 6px 10px; gap: 8px; }
.acct__glyph { display: grid; place-items: center; color: var(--on-ink-muted); }
.acct__glyph--pro { color: var(--brand); }
.acct__label { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .86rem; font-weight: 700; color: #fff; }
.acct__protag { padding: 1px 7px; border-radius: 999px; background: var(--brand); color: var(--brand-ink); font-size: .66rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.acct > summary:has(.acct__protag) { border-color: rgba(245, 166, 35, .55); background: rgba(245, 166, 35, .1); }
@media (max-width: 720px) { .acct__label { display: none; } }
.acct__tile { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--ink-900); color: #fff; }
.acct__tile--pro { background: linear-gradient(135deg, #ffc35a, var(--brand-strong)); color: var(--brand-ink); }
.acct__pro { display: grid; gap: 4px; margin: 4px 0; padding: 10px 12px; border-radius: 10px; background: linear-gradient(160deg, var(--brand-soft), #fff); border: 1px solid #f3cf8a; color: #6b3f05; font-size: .82rem; text-decoration: none; }
.acct__pro strong { display: block; font-size: .9rem; color: var(--brand-text); }
.acct__pro small { color: var(--muted); font-size: .76rem; font-weight: 700; }
.acct__pro:hover { border-color: var(--brand); }
.acct__links { display: grid; }
.acct__links a, .acct__out button { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--text); font: inherit; font-weight: 700; font-size: .9rem; text-decoration: none; }
.acct__links a svg, .acct__out button svg { color: var(--muted); }
.acct__links a:hover, .acct__links a[aria-current="page"] { background: var(--page); color: var(--text-strong); }
.acct__upgrade { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 4px 0; padding: 10px 12px; border-radius: 10px; background: var(--brand-soft); border: 1px solid #f3cf8a; color: #6b3f05; font-size: .82rem; text-decoration: none; }
.acct__upgrade strong { display: block; font-size: .9rem; color: var(--brand-text); }
.acct__upgrade:hover { border-color: var(--brand); }
.acct__out { margin: 0; padding-top: 4px; border-top: 1px solid var(--line); }
.acct__out button { width: 100%; background: none; border: 0; cursor: pointer; color: var(--down); }
.acct__out button svg { color: var(--down); }
.acct__out button:hover { background: #fdecec; }

.site-menu { display: none; }
.site-menu > summary {
    list-style: none;
    cursor: pointer;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    border: 1px solid var(--ink-line-strong);
    display: grid;
    place-items: center;
    color: #fff;
}
.site-menu > summary::-webkit-details-marker { display: none; }
.site-menu__panel {
    /* Anchored to the sticky header bar, full width under it. */
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    display: grid;
    gap: 2px;
    padding: 12px 16px 20px;
    background: var(--ink-900);
    border-bottom: 1px solid var(--ink-line);
    box-shadow: 0 24px 40px rgba(0, 0, 0, .35);
}
.site-menu__panel a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border-radius: 8px;
    color: var(--on-ink);
    font-weight: 600;
    text-decoration: none;
}
.site-menu__panel a:hover,
.site-menu__panel a[aria-current="page"] { background: rgba(255, 255, 255, .06); color: #fff; }
.site-menu__panel .btn { margin-top: 10px; justify-content: center; }
/* The menu's link colours must not reach its Start free button (light text on amber was 1.7:1). */
.site-menu__panel a.btn--brand { background: var(--brand); color: var(--brand-ink); }
.site-menu__panel a.btn--brand:hover { background: #ffb53d; color: var(--brand-ink); }

@media (max-width: 920px) {
    .site-nav,
    .site-top__cta > .btn,
    .site-top__cta > .site-top__login,
    .site-top__cta > .lang-switch { display: none; }
    .site-menu { display: block; }
    .site-top__inner { justify-content: space-between; }
}
@media (max-width: 560px) {
    .site-top .brand__sub { display: none; }
}

/* ---------- Site footer (dark) ---------- */
.site-foot {
    background: var(--ink-950);
    color: var(--on-ink-muted);
    padding: 40px 0 24px;
    font-family: var(--font-body);
    font-size: .92rem;
    border-top: 1px solid var(--ink-line);
}
.site-foot__inner { width: min(var(--container), 100% - 32px); margin-inline: auto; }
.site-foot--wide .site-foot__inner { width: min(1520px, 100% - 32px); }
.site-foot .brand,
.site-foot .brand__title { color: #fff; }
.site-foot .brand__sub { color: var(--on-ink-muted); }
.site-foot__grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 28px 24px;
}
/* The brand sits on its own row above the six link columns. */
.site-foot__brand { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; }
.site-foot__note { margin: 0; max-width: 60ch; line-height: 1.5; }
.site-foot__head {
    margin: 0 0 12px;
    color: #fff;
    font-family: var(--font-display);
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.site-foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-foot a { color: var(--on-ink-muted); text-decoration: none; overflow-wrap: anywhere; }
.site-foot__grid > * { min-width: 0; }
.site-foot a:hover { color: #fff; }
.site-foot__bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    margin-top: 32px;
    padding-top: 18px;
    border-top: 1px solid var(--ink-line);
    font-size: .84rem;
}
/* Slim footer on the board and event pages. */
.site-foot--slim { margin-top: 48px; padding: 18px 0 22px; font-size: .84rem; }
.site-foot__slim { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px; }
.site-foot__slim nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }

@media (max-width: 1000px) {
    .site-foot__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .site-foot { padding-top: 32px; }
    .site-foot__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
