/* ArbPlay — mobile-first design system */

:root {
    --bg: #0a0a0a;
    --bg-card: #111111;
    --bg-elevated: #161616;
    --bg-hover: #1c1c1c;
    --accent: #2ecc8a;
    --accent-dim: rgba(46, 204, 138, 0.12);
    --accent-border: rgba(46, 204, 138, 0.28);
    --red: #e85d6a;
    --red-dim: rgba(232, 93, 106, 0.12);
    --text: #f2f2f2;
    --text-secondary: #a3a3a3;
    --text-muted: #666666;
    --border: #222222;
    --border-light: #2a2a2a;
    --radius: 12px;
    --radius-lg: 16px;
    --header-h: 52px;
    --bottom-nav-h: 56px;
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --safe-left: env(safe-area-inset-left, 0px);
    --safe-right: env(safe-area-inset-right, 0px);
    --tap-min: 48px;
    --font-base: 16px;
    --sidebar-w: 240px;
    --brand-accent: #00d68f;
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: var(--font-base);
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

input, select, textarea {
    font: inherit;
    color: inherit;
}

img, svg {
    display: block;
    max-width: 100%;
}

/* Typography */
.serif {
    font-family: 'Instrument Serif', Georgia, serif;
}

.mono {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-variant-numeric: tabular-nums;
}

/* Brand wordmark (shared: landing + dashboard) */
.brand,
.lp-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--brand-text, var(--text));
    text-decoration: none;
    font-family: 'Geist', 'Inter', system-ui, sans-serif;
    font-weight: 600;
    font-size: 1.0625rem;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.brand-text,
.lp-brand-text {
    font-feature-settings: 'ss01';
}

.brand-dot,
.lp-brand-dot {
    width: 10px;
    height: 10px;
    border-radius: 3px;
    background: var(--brand-accent);
    box-shadow: 0 0 0 4px rgba(0, 214, 143, 0.12);
    flex-shrink: 0;
}

.brand-sm,
.lp-brand-sm {
    font-size: 0.9375rem;
}

.brand-sm .brand-dot,
.lp-brand-sm .lp-brand-dot {
    width: 8px;
    height: 8px;
    border-radius: 2px;
    box-shadow: 0 0 0 3px rgba(0, 214, 143, 0.12);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: var(--tap-min);
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    transition: background 0.15s, border-color 0.15s, opacity 0.15s;
    border: 1px solid transparent;
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--accent);
    color: #041208;
}

.btn-primary:active {
    opacity: 0.88;
}

.btn-ghost {
    background: transparent;
    border-color: var(--border-light);
    color: var(--text);
}

.btn-ghost:active {
    background: var(--bg-hover);
}

.btn-danger {
    background: #ef4444;
    color: #fff;
}

.btn-danger:active {
    opacity: 0.88;
}

.btn-sm {
    min-height: var(--tap-min);
    padding: 0.625rem 1rem;
    font-size: 0.9375rem;
}

.btn-block {
    width: 100%;
}

.hidden {
    display: none !important;
}

/* ═══════════════════════════════════════
   LANDING
   ═══════════════════════════════════════ */

.lp-body {
    /* Refined palette scoped to landing only; dashboard keeps existing tokens above. */
    --lp-bg: #0a0b0d;
    --lp-bg-elevated: #111317;
    --lp-bg-card: #15181d;
    --lp-border: #20242b;
    --lp-border-strong: #2a2f37;
    --lp-text: #f5f5f7;
    --lp-text-muted: #a0a4ad;
    --lp-text-dim: #6b7079;
    --lp-accent: #00d68f;
    --lp-accent-hover: #1ee3a0;
    --lp-accent-soft: rgba(0, 214, 143, 0.12);
    --lp-accent-line: rgba(0, 214, 143, 0.28);
    --brand-text: var(--lp-text);
    --lp-positive: #00d68f;
    --lp-negative: #ff5a6e;
    --lp-nav-h: 64px;
    --lp-radius-sm: 10px;
    --lp-radius: 14px;
    --lp-radius-lg: 20px;

    font-family: 'Inter', 'Geist', system-ui, -apple-system, sans-serif;
    font-feature-settings: 'ss01', 'cv11';
    background: var(--lp-bg);
    color: var(--lp-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.lp {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--lp-bg);
}

.lp::before {
    content: '';
    position: absolute;
    inset: 0 0 auto 0;
    height: 720px;
    pointer-events: none;
    background:
        radial-gradient(ellipse 60% 50% at 50% 0%, rgba(0, 214, 143, 0.10), transparent 60%),
        radial-gradient(ellipse 40% 30% at 80% 10%, rgba(0, 214, 143, 0.05), transparent 70%);
    z-index: 0;
}

.lp > * {
    position: relative;
    z-index: 1;
}

/* ── Nav ─────────────────────────── */
.lp-nav {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    height: calc(var(--lp-nav-h) + var(--safe-top));
    padding: var(--safe-top) calc(1.25rem + var(--safe-right)) 0 calc(1.25rem + var(--safe-left));
    background: transparent;
    transition: background 0.2s ease, border-color 0.2s ease, backdrop-filter 0.2s ease;
    border-bottom: 1px solid transparent;
}

.lp-nav.is-scrolled {
    background: rgba(10, 11, 13, 0.78);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom-color: var(--lp-border);
}

.lp-nav-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* ── Buttons (scoped) ─────────────── */
.lp-btn {
    --btn-h: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: var(--btn-h);
    padding: 0 1.1rem;
    border-radius: var(--lp-radius-sm);
    border: 1px solid transparent;
    font-family: inherit;
    font-weight: 600;
    font-size: 0.9375rem;
    letter-spacing: -0.005em;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.05s ease;
    text-decoration: none;
    white-space: nowrap;
}

.lp-btn:active { transform: translateY(1px); }
.lp-btn:disabled { opacity: 0.55; cursor: not-allowed; }

.lp-btn-primary {
    background: var(--lp-accent);
    color: #04130b;
    border-color: var(--lp-accent);
}

.lp-btn-primary:hover {
    background: var(--lp-accent-hover);
    border-color: var(--lp-accent-hover);
}

.lp-btn-ghost {
    background: transparent;
    color: var(--lp-text);
    border-color: var(--lp-border-strong);
}

.lp-btn-ghost:hover {
    background: var(--lp-bg-elevated);
    border-color: #383e48;
}

.lp-btn-sm {
    --btn-h: 38px;
    padding: 0 0.875rem;
    font-size: 0.875rem;
}

.lp-btn-lg {
    --btn-h: 52px;
    padding: 0 1.4rem;
    font-size: 1rem;
}

.lp-btn-block {
    width: 100%;
}

.lp-link {
    background: none;
    border: none;
    padding: 0;
    color: var(--lp-accent);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

.lp-link:hover { color: var(--lp-accent-hover); }

.lp-hidden { display: none !important; }

/* ── Section scaffolding ──────────── */
.lp-section {
    padding: 4.5rem 1.25rem;
}

.lp-section-alt {
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.012));
    border-top: 1px solid var(--lp-border);
    border-bottom: 1px solid var(--lp-border);
}

.lp-section-inner {
    max-width: 1100px;
    margin: 0 auto;
}

.lp-section-head {
    margin-bottom: 2.5rem;
    max-width: 640px;
}

.lp-section-head-center {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.lp-kicker {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--lp-accent);
    margin-bottom: 0.875rem;
}

.lp-section h2 {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: clamp(1.625rem, 3.5vw, 2.125rem);
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.2;
    color: var(--lp-text);
}

.lp-section-lede {
    margin-top: 0.875rem;
    color: var(--lp-text-muted);
    font-size: 1rem;
}

/* ── Hero ─────────────────────────── */
.lp-hero {
    padding: 2.5rem 1.25rem 4rem;
}

.lp-hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2.75rem;
}

.lp-hero-copy {
    max-width: 620px;
}

.lp-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.75rem 0.375rem 0.5rem;
    border: 1px solid var(--lp-border-strong);
    background: var(--lp-accent-soft);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--lp-text-muted);
    margin-bottom: 1.5rem;
}

.lp-eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--lp-accent);
    box-shadow: 0 0 0 3px rgba(0, 214, 143, 0.18);
    animation: lp-live-pulse 2s ease-in-out infinite;
}

.lp-headline {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: clamp(2.25rem, 6.5vw, 3.75rem);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1.04;
    color: var(--lp-text);
    margin-bottom: 1.25rem;
}

.lp-sub {
    font-size: 1.0625rem;
    color: var(--lp-text-muted);
    max-width: 52ch;
    margin-bottom: 1.75rem;
}

.lp-cta-row {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 1rem;
}

.lp-trust {
    font-size: 0.8125rem;
    color: var(--lp-text-dim);
}

/* ── Hero preview ────────────────── */
.lp-hero-visual {
    position: relative;
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
}

.lp-preview-glow {
    position: absolute;
    inset: 12% -10% -10% -10%;
    background: radial-gradient(60% 60% at 50% 50%, rgba(0, 214, 143, 0.18), transparent 70%);
    filter: blur(40px);
    z-index: 0;
    pointer-events: none;
}

.lp-preview {
    position: relative;
    z-index: 1;
    background: linear-gradient(180deg, var(--lp-bg-card) 0%, var(--lp-bg-elevated) 100%);
    border: 1px solid var(--lp-border-strong);
    border-radius: var(--lp-radius-lg);
    padding: 1.125rem;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.03) inset,
        0 30px 60px -25px rgba(0, 0, 0, 0.6);
}

.lp-preview-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 0.875rem;
    margin-bottom: 0.875rem;
    border-bottom: 1px solid var(--lp-border);
    font-size: 0.8125rem;
}

.lp-live {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 600;
    color: var(--lp-text);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.6875rem;
}

.lp-live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--lp-accent);
    box-shadow: 0 0 0 3px rgba(0, 214, 143, 0.2);
    animation: lp-live-pulse 1.8s ease-in-out infinite;
}

.lp-preview-meta {
    color: var(--lp-text-dim);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.lp-preview-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.lp-preview-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.7rem 0.875rem;
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius-sm);
}

.lp-preview-event {
    min-width: 0;
}

.lp-preview-teams {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--lp-text);
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-preview-market {
    font-size: 0.75rem;
    color: var(--lp-text-dim);
    margin-top: 0.15rem;
}

.lp-preview-num {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-variant-numeric: tabular-nums;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--lp-positive);
    padding: 0.25rem 0.5rem;
    background: var(--lp-accent-soft);
    border-radius: 6px;
    white-space: nowrap;
}

.lp-preview-num--strong {
    font-weight: 600;
}

.lp-flash {
    animation: lp-flash 0.7s ease-out;
}

@keyframes lp-flash {
    0% { background: rgba(0, 214, 143, 0.35); color: #c5ffe6; }
    100% { background: var(--lp-accent-soft); color: var(--lp-positive); }
}

@keyframes lp-live-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.55; transform: scale(0.92); }
}

.lp-preview-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.875rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--lp-border);
    font-size: 0.75rem;
    color: var(--lp-text-dim);
}

.lp-preview-foot-time {
    color: var(--lp-text-muted);
    font-family: 'JetBrains Mono', ui-monospace, monospace;
}

/* ── Value props ─────────────────── */
.lp-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1rem;
}

.lp-grid-3 {
    grid-template-columns: 1fr;
}

.lp-card {
    padding: 1.5rem;
    background: var(--lp-bg-card);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius);
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.lp-card:hover {
    border-color: var(--lp-border-strong);
    background: var(--lp-bg-elevated);
}

.lp-card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--lp-accent-soft);
    color: var(--lp-accent);
    margin-bottom: 1rem;
}

.lp-card-icon svg {
    width: 20px;
    height: 20px;
}

.lp-card h3 {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: 1.0625rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    color: var(--lp-text);
    margin-bottom: 0.375rem;
}

.lp-card p {
    color: var(--lp-text-muted);
    font-size: 0.9375rem;
    line-height: 1.55;
}

/* ── Steps ────────────────────────── */
.lp-steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr;
}

.lp-step {
    padding: 1.5rem;
    background: var(--lp-bg-card);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius);
}

.lp-step-num {
    display: inline-block;
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--lp-accent);
    margin-bottom: 0.75rem;
    letter-spacing: 0.05em;
}

.lp-step h3 {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: 1.0625rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    color: var(--lp-text);
    margin-bottom: 0.375rem;
}

.lp-step p {
    color: var(--lp-text-muted);
    font-size: 0.9375rem;
}

/* ── Pricing ──────────────────────── */
.lp-price {
    max-width: 480px;
    margin: 0 auto;
    padding: 1.75rem;
    background: var(--lp-bg-card);
    border: 1px solid var(--lp-border-strong);
    border-radius: var(--lp-radius-lg);
    position: relative;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.03) inset,
        0 30px 60px -30px rgba(0, 0, 0, 0.7);
}

.lp-price::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(180deg, rgba(0, 214, 143, 0.4), transparent 40%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
}

.lp-price-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1.25rem;
    margin-bottom: 1.25rem;
    border-bottom: 1px solid var(--lp-border);
}

.lp-price-name {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--lp-text);
    margin-bottom: 0.25rem;
}

.lp-price-tag {
    font-size: 0.8125rem;
    color: var(--lp-text-dim);
}

.lp-price-amount {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    color: var(--lp-text);
}

.lp-price-value {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 600;
    letter-spacing: -0.03em;
}

.lp-price-period {
    font-size: 0.875rem;
    color: var(--lp-text-muted);
}

.lp-price-list {
    list-style: none;
    margin: 0 0 1.5rem;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.lp-price-list li {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    color: var(--lp-text);
    font-size: 0.9375rem;
}

.lp-price-list svg {
    width: 16px;
    height: 16px;
    color: var(--lp-accent);
    flex-shrink: 0;
}

.lp-price-foot {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--lp-text-dim);
    margin-top: 0.875rem;
}

/* ── Footer ───────────────────────── */
.lp-footer {
    border-top: 1px solid var(--lp-border);
    padding: 2rem 1.25rem calc(2rem + var(--safe-bottom));
}

.lp-footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
}

.lp-footer-copy {
    font-size: 0.8125rem;
    color: var(--lp-text-dim);
}

.lp-footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 1.25rem;
    font-size: 0.8125rem;
}

.lp-footer-links a {
    color: var(--lp-text-muted);
    text-decoration: none;
    transition: color 0.15s ease;
}

.lp-footer-links a:hover {
    color: var(--lp-text);
}

/* ── Auth modal / sheet ───────────── */
.lp-sheet-backdrop {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: rgba(0, 0, 0, 0.66);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.lp-sheet-backdrop.open {
    opacity: 1;
    visibility: visible;
}

.lp-auth {
    position: fixed;
    z-index: 101;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: 92vh;
    background: var(--lp-bg-elevated);
    border-top: 1px solid var(--lp-border-strong);
    border-radius: var(--lp-radius-lg) var(--lp-radius-lg) 0 0;
    padding: 0 1.25rem calc(1.5rem + var(--safe-bottom));
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.lp-auth.open {
    transform: translateY(0);
}

.lp-auth-handle {
    width: 40px;
    height: 4px;
    background: var(--lp-border-strong);
    border-radius: 999px;
    margin: 0.75rem auto 1rem;
}

.lp-auth-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.lp-auth-head h2 {
    font-family: 'Geist', 'Inter', sans-serif;
    font-size: 1.375rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--lp-text);
}

.lp-auth-head p {
    color: var(--lp-text-muted);
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.lp-auth-close {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--lp-border);
    background: transparent;
    color: var(--lp-text-muted);
    border-radius: 10px;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease, color 0.15s ease;
}

.lp-auth-close:hover {
    background: var(--lp-bg-card);
    color: var(--lp-text);
}

.lp-auth-close svg {
    width: 18px;
    height: 18px;
}

.lp-field {
    margin-bottom: 1rem;
}

.lp-field label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--lp-text-muted);
    margin-bottom: 0.4rem;
}

.lp-field input {
    width: 100%;
    min-height: 48px;
    padding: 0.75rem 0.875rem;
    background: var(--lp-bg);
    border: 1px solid var(--lp-border-strong);
    border-radius: var(--lp-radius-sm);
    color: var(--lp-text);
    font-size: 16px; /* avoid iOS auto-zoom */
    font-family: inherit;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.lp-field input::placeholder {
    color: var(--lp-text-dim);
}

.lp-field input:focus {
    outline: none;
    border-color: var(--lp-accent);
    background: var(--lp-bg-card);
}

.lp-form-error {
    display: none;
    padding: 0.75rem 0.875rem;
    margin-bottom: 1rem;
    background: rgba(255, 90, 110, 0.1);
    border: 1px solid rgba(255, 90, 110, 0.3);
    border-radius: var(--lp-radius-sm);
    color: var(--lp-negative);
    font-size: 0.875rem;
}

.lp-form-error.visible {
    display: block;
}

.lp-auth-foot {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.9375rem;
    color: var(--lp-text-muted);
}

.lp-auth-note {
    text-align: center;
    margin-top: 0.875rem;
    font-size: 0.8125rem;
    color: var(--lp-text-dim);
}

/* ── Toasts ───────────────────────── */
.lp-toast-stack {
    position: fixed;
    top: calc(1rem + var(--safe-top));
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: min(90vw, 360px);
    pointer-events: none;
}

.lp-toast {
    padding: 0.875rem 1rem;
    background: var(--lp-bg-elevated);
    border: 1px solid var(--lp-border-strong);
    border-radius: var(--lp-radius-sm);
    font-size: 0.875rem;
    color: var(--lp-text);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease;
}

.lp-toast-success {
    border-color: var(--lp-accent-line);
}

.lp-toast-error {
    border-color: rgba(255, 90, 110, 0.35);
}

/* ── Responsive: tablet / desktop ── */
@media (min-width: 720px) {
    .lp-section {
        padding: 6rem 2rem;
    }

    .lp-hero {
        padding: 4rem 2rem 6rem;
    }

    .lp-hero-inner {
        flex-direction: row;
        align-items: center;
        gap: 3rem;
    }

    .lp-hero-copy {
        flex: 1.1;
    }

    .lp-hero-visual {
        flex: 1;
        max-width: 480px;
        margin: 0;
    }

    .lp-cta-row {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
    }

    .lp-grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }

    .lp-steps {
        grid-template-columns: repeat(3, 1fr);
    }

    .lp-footer-inner {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .lp-auth {
        left: 50%;
        right: auto;
        bottom: auto;
        top: 50%;
        width: min(440px, calc(100vw - 2rem));
        max-height: 88vh;
        border: 1px solid var(--lp-border-strong);
        border-radius: var(--lp-radius-lg);
        padding: 1.5rem 1.25rem 1.5rem;
        transform: translate(-50%, -45%) scale(0.97);
        opacity: 0;
        visibility: hidden;
    }

    .lp-auth.open {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
        visibility: visible;
    }

    .lp-auth-handle {
        display: none;
    }
}

@media (min-width: 960px) {
    .lp-headline {
        font-size: clamp(2.5rem, 4.8vw, 4.25rem);
    }
}

/* ═══════════════════════════════════════
   DASHBOARD
   ═══════════════════════════════════════ */

.dash {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
}

/* Sticky header — mobile */
.dash-header {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    min-height: var(--header-h);
    padding: calc(0.5rem + var(--safe-top)) calc(1rem + var(--safe-right)) 0.5rem calc(1rem + var(--safe-left));
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    flex-shrink: 0;
}

.live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--text-muted);
    flex-shrink: 0;
}

.live-dot.on {
    background: var(--accent);
    box-shadow: 0 0 8px rgba(46, 204, 138, 0.5);
    animation: pulse 2s ease-in-out infinite;
}

.live-dot.err {
    background: var(--red);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.header-best {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--accent);
    padding: 0.25rem 0.5rem;
    background: var(--accent-dim);
    border-radius: 6px;
}

.header-best.empty {
    color: var(--text-muted);
    background: transparent;
}

/* Trial banners */
.trial-bar {
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--accent-dim);
    border-bottom: 1px solid var(--accent-border);
    font-size: 0.9375rem;
}

.trial-bar.expired {
    background: var(--red-dim);
    border-color: rgba(232, 93, 106, 0.3);
}

.trial-bar.visible {
    display: flex;
}

/* Main content area */
.dash-body {
    flex: 1;
    display: flex;
    min-height: 0;
}

.dash-sidebar {
    display: none;
}

.dash-content {
    flex: 1;
    min-width: 0;
    padding: 0 0 calc(var(--bottom-nav-h) + var(--safe-bottom) + 1rem);
}

.feed-status {
    padding: 0.75rem 1rem 0;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.mobile-filter-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem 1rem 0;
}

.mobile-filter-summary span {
    padding: 0.375rem 0.625rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-secondary);
    background: var(--bg-card);
    font-size: 0.8125rem;
}

.desk-header {
    display: none;
}

/* Loading & empty */
.state-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 3rem 1.5rem;
    text-align: center;
    color: var(--text-secondary);
}

.state-block h3 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--text);
}

.spinner {
    width: 28px;
    height: 28px;
    border: 2px solid var(--border-light);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Mobile card feed */
.arb-feed {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
}

.arb-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem;
    transition: border-color 0.2s;
}

.arb-card.new-row {
    animation: card-in 0.35s ease-out;
}

@keyframes card-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
}

.card-row-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.sport-badge {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 0.25rem 0.5rem;
    background: var(--bg-hover);
    border-radius: 4px;
    color: var(--text-secondary);
}

.card-time {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.card-event {
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 0.25rem;
    word-break: break-word;
}

.card-market {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.875rem;
}

.card-diff-hero {
    display: flex;
    align-items: baseline;
    gap: 0.375rem;
    margin-bottom: 1rem;
}

.diff-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.75rem;
    font-weight: 500;
    line-height: 1;
}

.diff-value.pos {
    color: var(--accent);
}

.diff-value.neg {
    color: var(--red);
}

.diff-value.medium {
    opacity: 0.92;
}

.diff-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.card-legs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.625rem;
}

.leg-block {
    padding: 0.75rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--bg);
}

.leg-block.back {
    border-color: rgba(46, 204, 138, 0.15);
}

.leg-block.lay {
    border-color: rgba(232, 93, 106, 0.12);
}

.leg-side-label {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.leg-book {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-bottom: 0.375rem;
    word-break: break-word;
}

.leg-odds {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.375rem;
    font-weight: 500;
    line-height: 1.1;
}

.leg-extra {
    font-size: 0.6875rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.odds-flash {
    animation: odds-flash 0.6s ease-out;
}

@keyframes odds-flash {
    0% { background: rgba(46, 204, 138, 0.25); border-radius: 4px; }
    100% { background: transparent; }
}

/* Desktop table — hidden on mobile */
.desk-table-wrap {
    display: none;
}

/* Bottom nav */
.bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 40;
    display: flex;
    align-items: stretch;
    min-height: calc(var(--bottom-nav-h) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    background: rgba(14, 14, 14, 0.96);
    backdrop-filter: blur(16px);
    border-top: 1px solid var(--border);
}

.bottom-bar-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.125rem;
    min-height: var(--bottom-nav-h);
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    transition: color 0.15s;
}

.bottom-bar-item svg {
    width: 22px;
    height: 22px;
}

.bottom-bar-item.active {
    color: var(--accent);
}

.bottom-bar-item:active {
    background: var(--bg-hover);
}

/* Bottom sheets — filter & account */
.sheet-backdrop {
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

.sheet-backdrop.open {
    opacity: 1;
    visibility: visible;
}

.sheet-handle {
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: var(--border-light, rgba(255, 255, 255, 0.18));
    margin: 0.25rem auto 1.25rem;
}

.bottom-sheet {
    position: fixed;
    z-index: 90;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: 85vh;
    background: var(--bg-elevated);
    border-top: 1px solid var(--border-light);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 1rem 1.25rem calc(var(--bottom-nav-h) + var(--safe-bottom) + 1rem);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.bottom-sheet.open {
    transform: translateY(0);
}

.sheet-title {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.375rem;
    font-weight: 400;
    margin-bottom: 1.25rem;
}

.filter-section {
    margin-bottom: 1.5rem;
}

.filter-label {
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.625rem;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.chip {
    min-height: var(--tap-min);
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-light);
    border-radius: 999px;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.chip.active {
    background: var(--accent-dim);
    border-color: var(--accent-border);
    color: var(--accent);
}

.sport-chip {
    --sport-stripe: var(--text-muted);
}

.sport-chip.sport-soccer { --sport-stripe: #9a9a9a; }
.sport-chip.sport-tennis { --sport-stripe: #9dcc3a; }
.sport-chip.sport-basketball { --sport-stripe: #e07b39; }
.sport-chip.sport-other { --sport-stripe: #555555; }

.sport-chip.active {
    background: var(--accent-dim);
    border-color: var(--sport-stripe);
    color: var(--accent);
}

.chip:active {
    background: var(--bg-hover);
}

.feed-group-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.feed-select + .feed-group-list {
    margin-top: 0.75rem;
}

.feed-chip {
    width: 100%;
    min-height: var(--tap-min);
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.125rem;
    text-align: left;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.feed-chip.active {
    border-color: var(--accent-border);
    background: var(--accent-dim);
}

.feed-chip strong {
    font-size: 0.9375rem;
}

.feed-chip span {
    color: var(--text-muted);
    font-size: 0.8125rem;
}

.feed-hint {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.min-diff-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.min-diff-row input[type="range"] {
    flex: 1;
    min-height: var(--tap-min);
    accent-color: var(--accent);
}

.min-diff-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1rem;
    min-width: 3.5rem;
    text-align: right;
}

.min-diff-val.pos {
    color: var(--accent);
}

.min-diff-val.neg {
    color: var(--red);
}

.min-diff-val.is-zero {
    color: var(--text-secondary);
}

/* Account sheet */
.account-profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0.5rem 0 1.5rem;
}

.account-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--accent-dim);
    border: 1px solid var(--accent-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.75rem;
    color: var(--accent);
    margin-bottom: 0.75rem;
}

.account-name {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.account-plan {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.account-actions {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.account-email,
.account-lastlogin {
    color: var(--text-secondary);
    font-size: 0.8125rem;
    margin-top: 0.25rem;
}

.account-lastlogin {
    font-size: 0.75rem;
    margin-top: 0.2rem;
}

.account-verify-banner {
    background: rgba(234, 179, 8, 0.12);
    border: 1px solid rgba(234, 179, 8, 0.4);
    color: #eab308;
    border-radius: var(--radius);
    padding: 0.6rem 0.75rem;
    font-size: 0.82rem;
    margin-bottom: 0.75rem;
}

.account-verify-banner .btn {
    margin-top: 0.5rem;
}

.account-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.account-form.hidden,
#accountActionsMain.hidden {
    display: none !important;
}

.account-form .form-input {
    width: 100%;
}

.account-form-error {
    color: var(--danger, #ef4444);
    font-size: 0.82rem;
}

.account-form-error.hidden {
    display: none;
}

.account-form-note {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin: 0;
}

.pw-wrap {
    position: relative;
    width: 100%;
}

.pw-wrap .form-input {
    padding-right: 3.4rem;
}

.pw-toggle {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: 0;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.25rem;
}

.pw-toggle:hover {
    color: var(--text);
}

/* Keep autofill readable on dark account inputs */
.account-form input:-webkit-autofill,
.account-form input:-webkit-autofill:hover,
.account-form input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px var(--bg) inset;
    -webkit-text-fill-color: var(--text);
    caret-color: var(--text);
    transition: background-color 9999s ease-out;
}

.sidebar-user-row-btn {
    width: 100%;
    text-align: left;
    background: none;
    border: 0;
    cursor: pointer;
    padding: 0;
}

.sidebar-user-row-btn:hover .sidebar-user-name {
    color: var(--accent);
}

/* Desktop layout */
@media (min-width: 768px) {
    .dash-header {
        display: none;
    }

    .bottom-bar {
        display: none;
    }

    .dash-content {
        padding-bottom: 2rem;
    }

    .dash-sidebar {
        display: flex;
        flex-direction: column;
        width: var(--sidebar-w);
        flex-shrink: 0;
        padding: 1.5rem 1.25rem;
        border-right: 1px solid var(--border);
        background: var(--bg-card);
        min-height: 100vh;
        max-height: 100vh;
        position: sticky;
        top: 0;
        align-self: flex-start;
        overflow-y: auto;
    }

    .sidebar-brand {
        font-size: 1.1875rem;
        margin-bottom: 2rem;
    }

    .sidebar-brand .brand-dot {
        width: 11px;
        height: 11px;
        border-radius: 3px;
        box-shadow: 0 0 0 4px rgba(0, 214, 143, 0.12);
    }

    .sidebar-section {
        margin-bottom: 1.75rem;
    }

    .sidebar-status {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-size: 0.875rem;
        color: var(--text-secondary);
        margin-bottom: 1.5rem;
    }

    .sidebar-user {
        margin-top: auto;
        padding-top: 1.5rem;
        border-top: 1px solid var(--border);
    }

    .sidebar-user-row {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        margin-bottom: 0.75rem;
    }

    .sidebar-user-row .account-avatar {
        width: 40px;
        height: 40px;
        font-size: 1.125rem;
        margin-bottom: 0;
    }

    .sidebar-user-name {
        font-weight: 600;
        font-size: 0.9375rem;
    }

    .sidebar-user-plan {
        font-size: 0.8125rem;
        color: var(--text-muted);
    }

    .feed-status {
        display: none;
    }

    .desk-header {
        display: flex;
        align-items: baseline;
        justify-content: space-between;
        gap: 1rem;
        padding: 1.5rem 1.5rem 0;
    }

    .desk-header h1 {
        font-family: 'Instrument Serif', Georgia, serif;
        font-size: 1.75rem;
        font-weight: 400;
    }

    .desk-stats {
        display: flex;
        gap: 1.5rem;
        font-size: 0.875rem;
        color: var(--text-secondary);
    }

    .desk-stats strong {
        color: var(--text);
        font-family: 'JetBrains Mono', monospace;
    }

    .desk-stats .accent {
        color: var(--accent);
    }

    .arb-feed {
        display: none;
    }

    .desk-table-wrap {
        display: block;
        padding: 1rem 1.5rem 0;
        overflow-x: auto;
    }

    .arb-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.875rem;
    }

    .arb-table th {
        text-align: left;
        padding: 0.625rem 0.75rem;
        font-size: 0.6875rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        color: var(--text-muted);
        border-bottom: 1px solid var(--border);
        white-space: nowrap;
    }

    .arb-table td {
        padding: 0.75rem;
        border-bottom: 1px solid var(--border);
        vertical-align: middle;
    }

    .arb-table tr:hover td {
        background: var(--bg-hover);
    }

    .arb-table .game-cell {
        max-width: 220px;
        font-weight: 500;
    }

    .arb-table .diff-cell {
        font-family: 'JetBrains Mono', monospace;
        font-weight: 500;
    }

    .arb-table .diff-cell.pos {
        color: var(--accent);
    }

    .arb-table .diff-cell.neg {
        color: var(--red);
    }

    .arb-table .diff-cell.medium {
        opacity: 0.92;
    }

    .arb-table tr.sport-stripe td:first-child {
        box-shadow: inset 3px 0 0 var(--sport-stripe, var(--text-muted));
    }

    .arb-table tr.sport-soccer {
        --sport-stripe: #9a9a9a;
    }

    .arb-table tr.sport-tennis {
        --sport-stripe: #9dcc3a;
    }

    .arb-table tr.sport-basketball {
        --sport-stripe: #e07b39;
    }

    .arb-table tr.sport-other {
        --sport-stripe: #555555;
    }

    .bottom-sheet {
        left: auto;
        right: 1.5rem;
        bottom: 1.5rem;
        width: 360px;
        max-height: 70vh;
        border-radius: var(--radius-lg);
        border: 1px solid var(--border-light);
        padding-bottom: 1.5rem;
        transform: translateY(calc(100% + 2rem));
    }

    .bottom-sheet.open {
        transform: translateY(0);
    }

    .trial-bar {
        padding-left: calc(var(--sidebar-w) + 1rem);
    }
}

.feed-select {
    width: 100%;
    min-height: var(--tap-min);
    padding: 0.625rem 0.75rem;
    font-size: 0.9375rem;
    font-family: inherit;
    color: var(--text);
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    appearance: none;
    cursor: pointer;
}

.feed-select:focus {
    outline: 2px solid var(--accent-dim);
    border-color: var(--accent);
}

.leg-link {
    display: inline-block;
    margin-top: 0.35rem;
    font-size: 0.8125rem;
    color: var(--accent);
    text-decoration: none;
}

.leg-link:hover {
    text-decoration: underline;
}

/* ── Filter label inline actions / hints ── */
.filter-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filter-hint {
    margin-left: auto;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6875rem;
    color: var(--accent);
    text-transform: none;
    letter-spacing: 0;
}

.filter-action {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    border: 1px solid var(--border-light);
    background: transparent;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.filter-action:hover {
    color: var(--text);
    background: var(--bg-hover);
}

.filter-action + .filter-action {
    margin-left: -0.25rem;
}

/* ── Bookmaker multi-select grid ── */
.bookmaker-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
}

.book-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    min-height: 78px;
    padding: 0.5rem 0.5rem 0.6rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: border-color 0.15s, background 0.15s, transform 0.05s;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}

.book-card:active {
    transform: scale(0.98);
}

.book-card.active {
    border-color: var(--accent-border);
    background: var(--accent-dim);
}

.book-card-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 40px;
}

.book-logo {
    max-height: 40px;
    max-width: 100%;
    object-fit: contain;
    filter: none;
}

.book-initial {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--bg-hover);
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.book-card-name {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.book-card.active .book-card-name {
    color: var(--accent);
    font-weight: 600;
}

/* ── Merged feed warning banner ── */
.feed-warning {
    margin: 0.5rem 1rem 0;
    padding: 0.625rem 0.875rem;
    border-radius: var(--radius);
    background: rgba(255, 184, 0, 0.08);
    border: 1px solid rgba(255, 184, 0, 0.25);
    color: #f4c761;
    font-size: 0.8125rem;
    line-height: 1.35;
}

/* ── Logo inside back-leg / table cell ── */
.leg-book {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.leg-book-logo {
    width: 22px;
    height: 22px;
    object-fit: contain;
    border-radius: 4px;
    background: #fff1;
    flex-shrink: 0;
}

.cell-book {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.book-link {
    color: inherit;
    text-decoration: none;
}

.book-link:hover {
    color: var(--accent);
    text-decoration: underline;
}

.cell-book-logo {
    width: 18px;
    height: 18px;
    object-fit: contain;
    border-radius: 3px;
    flex-shrink: 0;
}

.back-odds-usd {
    font-size: 0.75em;
    color: var(--text-muted);
    font-weight: 400;
    margin-left: 0.25rem;
}

.desk-subtitle {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    margin-top: 0.15rem;
    letter-spacing: 0.02em;
}

@media (min-width: 768px) {
    .bookmaker-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.45rem;
    }

    .book-card {
        min-height: 72px;
        padding: 0.45rem 0.4rem 0.5rem;
    }

    .book-card-visual {
        height: 34px;
    }

    .book-logo {
        max-height: 34px;
    }

    .book-initial {
        width: 34px;
        height: 34px;
        font-size: 1.05rem;
    }

    .feed-warning {
        margin: 0.5rem 1.5rem 0;
    }
}

/* ═══════════════════════════════════════
   NOTIFICATIONS — bell, panel, toasts, alerts page
   ═══════════════════════════════════════ */

.bell-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    color: var(--text-secondary);
    transition: background 0.15s, color 0.15s;
}

.bell-btn:hover,
.bell-btn:focus-visible {
    background: var(--bg-hover);
    color: var(--text);
    outline: none;
}

.bell-btn svg {
    width: 22px;
    height: 22px;
}

.bell-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: var(--red);
    color: #fff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: 999px;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.bell-badge.show {
    display: inline-flex;
}

/* Notification sheet/panel */
.notif-panel {
    position: fixed;
    z-index: 95;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: 85vh;
    background: var(--bg-elevated);
    border-top: 1px solid var(--border-light);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 0 1rem calc(var(--bottom-nav-h) + var(--safe-bottom) + 1rem);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
    display: flex;
    flex-direction: column;
}

.notif-panel.open {
    transform: translateY(0);
}

.notif-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0.25rem 0.5rem;
    position: sticky;
    top: 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    z-index: 1;
}

.notif-head h2 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.375rem;
    font-weight: 400;
    margin: 0;
}

.notif-head-actions {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.notif-icon-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 0.625rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
}

.notif-icon-btn:hover { background: var(--bg-hover); color: var(--text); }
.notif-icon-btn svg { width: 14px; height: 14px; }

.notif-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 0 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.notif-empty {
    padding: 3rem 1rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.notif-day {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-top: 0.75rem;
    padding: 0 0.25rem;
}

.notif-day:first-child { margin-top: 0; }

.notif-item {
    padding: 0.75rem 0.875rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.notif-item.unread {
    border-color: var(--accent-border);
    background: linear-gradient(180deg, var(--accent-dim), var(--bg-card) 70%);
}

.notif-item-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
}

.notif-item-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.notif-item-arb {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--accent);
}

.notif-item-event {
    font-size: 0.9375rem;
    color: var(--text);
    font-weight: 500;
}

.notif-item-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: center;
}

.notif-item-legs {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.notif-item-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.15rem;
}

.notif-item-time {
    font-size: 0.6875rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.notif-item-link {
    font-size: 0.8125rem;
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
}

.notif-item-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
    justify-content: flex-end;
}

.notif-item-no-link {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.notif-item-link:hover { text-decoration: underline; }

@media (min-width: 768px) {
    .notif-panel {
        left: auto;
        right: 1.5rem;
        bottom: auto;
        top: 5rem;
        width: 420px;
        max-height: calc(100vh - 7rem);
        border-radius: var(--radius-lg);
        border: 1px solid var(--border-light);
        padding: 0 1rem 1rem;
        transform: translateY(-1rem) scale(0.96);
        opacity: 0;
        visibility: hidden;
        transition: transform 0.18s ease, opacity 0.18s ease, visibility 0.18s;
        box-shadow: 0 24px 50px -18px rgba(0, 0, 0, 0.65);
    }
    .notif-panel.open {
        transform: translateY(0) scale(1);
        opacity: 1;
        visibility: visible;
    }
}

/* Toasts */
.toast-stack {
    position: fixed;
    z-index: 80;
    bottom: calc(var(--bottom-nav-h) + var(--safe-bottom) + 0.75rem);
    left: 0.75rem;
    right: 0.75rem;
    display: flex;
    flex-direction: column-reverse;
    gap: 0.5rem;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    background: var(--bg-card);
    border: 1px solid var(--accent-border);
    border-radius: var(--radius);
    padding: 0.75rem 0.875rem;
    box-shadow: 0 12px 32px -10px rgba(0, 0, 0, 0.55);
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    animation: toast-in 0.22s ease-out;
}

.toast.leaving { animation: toast-out 0.18s ease-in forwards; }

@keyframes toast-in {
    from { transform: translateY(12px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes toast-out {
    to { transform: translateY(6px); opacity: 0; }
}

.toast-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
}

.toast-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.toast-arb {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    color: var(--accent);
}

.toast-event {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text);
}

.toast-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

@media (min-width: 768px) {
    .toast-stack {
        bottom: 1.25rem;
        right: 1.25rem;
        left: auto;
        width: 360px;
    }
}

/* Alerts page */
.alerts-page {
    max-width: 760px;
    margin: 0 auto;
    padding: 1.25rem 1rem calc(var(--bottom-nav-h) + var(--safe-bottom) + 1.5rem);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.alerts-page header.page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.alerts-page header.page-head h1 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.75rem;
    font-weight: 400;
}

.alerts-page .page-back {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.alerts-page .page-back:hover { color: var(--text); }

.telegram-card {
    padding: 1rem 1rem 0.875rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.telegram-card-top {
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.telegram-card-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #229ED9;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-family: 'Instrument Serif', Georgia, serif;
}

.telegram-card-title {
    font-weight: 600;
    font-size: 0.9375rem;
}

.telegram-card-status {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.telegram-card.linked .telegram-card-status { color: var(--accent); }
.telegram-card-status .code {
    font-family: 'JetBrains Mono', monospace;
    padding: 0.1rem 0.4rem;
    background: var(--bg-hover);
    border-radius: 6px;
    font-size: 0.8125rem;
    color: var(--text);
    margin-left: 0.25rem;
}

.telegram-card-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.alert-card {
    padding: 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.alert-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.alert-card-name {
    font-size: 1.0625rem;
    font-weight: 600;
}

.alert-card-summary {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.45;
}

.alert-card-summary .chip-tag {
    display: inline-block;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: var(--bg-hover);
    color: var(--text-secondary);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6875rem;
    margin: 0 0.25rem 0.15rem 0;
}

.alert-card-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.alert-card-actions .btn-sm { min-height: 38px; padding: 0.4rem 0.75rem; font-size: 0.8125rem; }
.alert-card-actions .btn-danger {
    background: var(--red-dim);
    border-color: rgba(232, 93, 106, 0.3);
    color: #ff7a86;
}
.alert-card-actions .btn-danger:hover { background: rgba(232, 93, 106, 0.22); }

.alert-empty {
    padding: 3rem 1rem;
    text-align: center;
    color: var(--text-muted);
    background: var(--bg-card);
    border: 1px dashed var(--border-light);
    border-radius: var(--radius-lg);
}

/* Switch */
.switch {
    --w: 38px;
    --h: 22px;
    position: relative;
    display: inline-block;
    width: var(--w);
    height: var(--h);
    flex-shrink: 0;
}
.switch input { display: none; }
.switch-track {
    position: absolute;
    inset: 0;
    background: var(--border-light);
    border-radius: 999px;
    transition: background 0.15s;
}
.switch-thumb {
    position: absolute;
    top: 2px;
    left: 2px;
    width: calc(var(--h) - 4px);
    height: calc(var(--h) - 4px);
    background: var(--text);
    border-radius: 50%;
    transition: transform 0.15s, background 0.15s;
}
.switch input:checked + .switch-track {
    background: var(--accent);
}
.switch input:checked + .switch-track .switch-thumb {
    transform: translateX(calc(var(--w) - var(--h)));
    background: #041208;
}

/* Modal */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
}
.modal-backdrop.open { opacity: 1; pointer-events: auto; }

.modal {
    position: fixed;
    z-index: 101;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    pointer-events: none;
    visibility: hidden;
}

.modal.open {
    visibility: visible;
}

.modal-card {
    width: 100%;
    max-height: 92vh;
    background: var(--bg-elevated);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    border: 1px solid var(--border-light);
    padding: 1.25rem 1rem calc(var(--safe-bottom) + 1rem);
    transform: translateY(100%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    pointer-events: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
}

.modal.open .modal-card {
    transform: translateY(0);
    pointer-events: auto;
}

.modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-head h2 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.375rem;
    font-weight: 400;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}
.modal-close:hover { background: var(--bg-hover); color: var(--text); }

.form-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-field label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.form-input,
.form-number {
    min-height: var(--tap-min);
    padding: 0.625rem 0.75rem;
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    color: var(--text);
    font-family: inherit;
    font-size: 0.9375rem;
}

.form-input::placeholder,
.form-number::placeholder {
    color: var(--text-muted);
    opacity: 1;
}

.form-input:focus, .form-number:focus {
    outline: 2px solid var(--accent-dim);
    border-color: var(--accent);
}

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.625rem;
}

.segmented {
    display: inline-flex;
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: 999px;
    padding: 0.2rem;
    width: 100%;
}

.segmented button {
    flex: 1;
    min-height: 36px;
    padding: 0 0.625rem;
    border-radius: 999px;
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 500;
    transition: background 0.12s, color 0.12s;
}

.segmented button.active {
    background: var(--accent);
    color: #041208;
}

.chip-multi {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.chip-toggle {
    min-height: 36px;
    padding: 0.35rem 0.875rem;
    border: 1px solid var(--border-light);
    border-radius: 999px;
    color: var(--text-secondary);
    font-size: 0.8125rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: transparent;
}

.chip-toggle.active {
    border-color: var(--accent-border);
    background: var(--accent-dim);
    color: var(--accent);
}

.chip-toggle img {
    width: 16px;
    height: 16px;
    object-fit: contain;
    border-radius: 3px;
    background: #fff1;
}

.form-checkbox-row {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 0.5rem 0;
}

.form-checkbox-row label {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.9375rem;
    color: var(--text);
    text-transform: none;
    letter-spacing: 0;
    font-weight: 500;
    cursor: pointer;
}

.form-checkbox-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
}

.form-checkbox-row .hint,
.form-field .hint {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.form-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 0.5rem;
    flex-wrap: wrap;
}

.form-error {
    font-size: 0.8125rem;
    color: var(--red);
    background: var(--red-dim);
    border: 1px solid rgba(232, 93, 106, 0.3);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius);
}

/* Trial / upsell card */
.upsell-card {
    padding: 2rem 1.25rem;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--accent-border);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
}

.upsell-card h2 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.5rem;
    font-weight: 400;
}

.upsell-card p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    max-width: 38ch;
}

/* Desktop modal centring */
@media (min-width: 768px) {
    .modal { align-items: center; }
    .modal-card {
        max-width: 520px;
        border-radius: var(--radius-lg);
        transform: translateY(20px) scale(0.96);
        opacity: 0;
        transition: transform 0.18s ease, opacity 0.18s ease;
        padding-bottom: 1.25rem;
    }
    .modal.open .modal-card {
        transform: translateY(0) scale(1);
        opacity: 1;
        pointer-events: auto;
    }
}

/* Header bell layout adjustments */
.header-bell-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.dash-top-nav {
    display: none;
}

@media (min-width: 768px) {
    .dash-top-nav {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        margin-left: auto;
        padding: 0.75rem 1.25rem 0 0;
    }
    .dash-top-nav a,
    .dash-top-nav button {
        font-size: 0.875rem;
        color: var(--text-secondary);
        padding: 0.45rem 0.75rem;
        border-radius: var(--radius);
        text-decoration: none;
        transition: background 0.12s, color 0.12s;
    }
    .dash-top-nav a:hover,
    .dash-top-nav button:hover { background: var(--bg-hover); color: var(--text); }
    .dash-top-nav a.active { color: var(--accent); }
}

/* ── Admin panel ── */
.admin-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1rem 3rem;
}

.admin-page .page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.admin-page .page-head h1 {
    font-family: 'Instrument Serif', Georgia, serif;
    font-size: 1.75rem;
    font-weight: 400;
}

.admin-subtitle {
    margin: 0.25rem 0 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.admin-stat {
    background: var(--bg-elevated, var(--bg));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.875rem 1rem;
    text-align: center;
}

.admin-stat-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--accent);
}

.admin-stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.admin-filters {
    margin-bottom: 1rem;
}

.admin-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--bg-elevated, var(--bg));
}

.admin-table {
    width: 100%;
    min-width: 900px;
}

.admin-empty {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem !important;
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.admin-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.admin-badge--active { background: rgba(46, 204, 113, 0.15); color: #2ecc71; }
.admin-badge--trial { background: rgba(241, 196, 15, 0.15); color: #f1c40f; }
.admin-badge--expired { background: rgba(231, 76, 60, 0.15); color: #e74c3c; }
.admin-badge--admin { background: var(--accent-dim); color: var(--accent); }

.admin-modal-card { max-width: 480px; width: 100%; }
.admin-form { display: flex; flex-direction: column; gap: 0.875rem; padding: 0 1.25rem 1.25rem; }
.admin-form-actions { display: flex; justify-content: flex-end; gap: 0.5rem; margin-top: 0.5rem; }
.admin-modal-hint { padding: 0 1.25rem; color: var(--text-secondary); font-size: 0.875rem; margin: 0 0 0.5rem; }

.form-label {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-error {
    color: #e74c3c;
    font-size: 0.8125rem;
    margin: 0;
}

@media (max-width: 767px) {
    .admin-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .admin-page { padding-bottom: 5rem; }

    /* Stacked card layout for the user table on small screens */
    .admin-table-wrap {
        overflow-x: visible;
        border: none;
        border-radius: 0;
        background: transparent;
    }

    .admin-table,
    .admin-table tbody,
    .admin-table tr,
    .admin-table td {
        display: block;
        width: 100%;
        min-width: 0;
    }

    .admin-table thead {
        display: none;
    }

    .admin-table tr {
        background: var(--bg-elevated, var(--bg));
        border: 1px solid var(--border);
        border-radius: var(--radius);
        padding: 0.5rem 0.875rem;
        margin-bottom: 0.75rem;
    }

    .admin-table td {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        padding: 0.4rem 0;
        border: none;
        text-align: right;
    }

    .admin-table td::before {
        content: attr(data-label);
        font-size: 0.6875rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.04em;
        color: var(--text-muted);
        text-align: left;
        flex-shrink: 0;
    }

    .admin-table td.admin-actions {
        justify-content: flex-end;
        flex-wrap: wrap;
        padding-top: 0.6rem;
        margin-top: 0.3rem;
        border-top: 1px solid var(--border);
    }

    .admin-table td.admin-actions::before {
        display: none;
    }

    .admin-table td.admin-empty {
        display: block;
        text-align: center;
    }

    .admin-table td.admin-empty::before {
        display: none;
    }
}
