/**
 * Scoreboard.ing App — /app/ dashboard, sign in, sign up
 *
 * @version 1.7.2
 * CHANGELOG
 * 1.7.2 (2026-10-30) - LED numbers use bundled DSEG7 Classic (was Digital-7,
 *                      which only showed on computers that had it installed).
 * 1.5.0 (2026-10-29) - Sponsor rows, report page, danger button, textarea,
 *                      game picker, print styles.
 * 1.4.1 (2026-10-28) - Multi-color stat cards (amber/green/blue) like the
 *                      original dashboard mockup.
 * 1.3.0 (2026-10-28) - New. Layout from dashboard.html / signup.html mockups,
 *                      rebuilt on the navy + green brand tokens.
 */

@font-face {
    font-family: 'DSEG7 Classic';
    src: url('../fonts/DSEG7Classic-Bold.woff2') format('woff2');
    font-weight: 400 900;
    font-display: swap;
}

:root {
    --bg:        #111827;
    --surface:   #1E293B;
    --surface-2: #172033;
    --border:    #334155;
    --green:     #178508;
    --green-hi:  #1e9e0b;
    --led:       #3fd42a;
    --amber:     #FFB000;
    --blue:      #38bdf8;
    --red:       #ef4444;
    --text:      #ffffff;
    --muted:     #94a3b8;
    --body:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --mono:      'DM Mono', ui-monospace, monospace;
    --ledfont:   'DSEG7 Classic', 'DM Mono', ui-monospace, monospace;
    --radius:    12px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body.bsb-app {
    background: var(--bg);
    color: var(--text);
    font: 15px/1.55 var(--body);
    -webkit-font-smoothing: antialiased;
}
a { color: var(--led); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0; line-height: 1.2; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.led {
    font-family: var(--ledfont);
    color: var(--led);
    text-shadow: 0 0 10px rgba(23, 133, 8, 0.75);
}
.led.is-dim { color: var(--border); text-shadow: none; }

/* ---------- Logo ---------- */
.app-logo { font-weight: 800; font-size: 20px; color: #fff; letter-spacing: -0.02em; }
.app-logo:hover { text-decoration: none; }
.app-logo b { color: var(--green); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    font: 600 14px/1 var(--body);
    padding: 12px 18px;
    border-radius: 8px;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none !important;
    transition: background .15s, border-color .15s, transform .15s;
    white-space: nowrap;
}
.btn-green { background: var(--green); color: #fff; }
.btn-green:hover { background: var(--green-hi); }
.btn-ghost { background: transparent; color: #fff; border-color: var(--border); }
.btn-ghost:hover { border-color: var(--muted); }
.btn-sm { padding: 8px 12px; font-size: 13px; }
.btn-block { width: 100%; }
.icon-btn {
    width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--border); border-radius: 8px; color: #fff;
}
.icon-btn:hover { border-color: var(--green); text-decoration: none; }

/* ---------- Notices ---------- */
.notice {
    padding: 12px 16px; border-radius: 8px; margin: 0 0 18px;
    border: 1px solid var(--border); background: var(--surface);
}
.notice-ok    { border-color: rgba(63, 212, 42, .4); background: rgba(23, 133, 8, .12); }
.notice-warn  { border-color: rgba(255, 176, 0, .45); background: rgba(255, 176, 0, .08); }
.notice-error { border-color: rgba(239, 68, 68, .5); background: rgba(239, 68, 68, .1); }
.tag {
    display: inline-block; font: 500 10px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em;
    padding: 4px 6px; border-radius: 4px; background: rgba(255, 176, 0, .15); color: var(--amber); font-style: normal;
}

/* ---------- App shell ---------- */
.app-side {
    position: fixed; inset: 0 auto 0 0; width: 240px;
    background: var(--surface-2);
    border-right: 1px solid var(--border);
    display: flex; flex-direction: column;
    padding: 22px 14px;
    z-index: 20;
}
.app-side .app-logo { padding: 0 8px; }
.app-logo-sub { padding: 2px 8px 0; font: 500 10px var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.app-nav { margin-top: 26px; display: flex; flex-direction: column; gap: 4px; }
.app-nav a {
    color: #cbd5e1; padding: 10px 12px; border-radius: 8px; border: 1px solid transparent; font-weight: 500;
}
.app-nav a:hover { background: var(--surface); text-decoration: none; }
.app-nav a.is-active { background: rgba(23, 133, 8, .14); border-color: rgba(23, 133, 8, .5); color: #fff; }
.app-side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 14px; }

.plan-card {
    display: block; padding: 14px; border-radius: 10px; color: #fff;
    background: var(--bg); border: 1px solid var(--border); border-top: 3px solid var(--green);
}
.plan-card:hover { text-decoration: none; border-color: var(--green); }
.plan-card-label { font: 500 10px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.plan-card-name { font-weight: 800; font-size: 18px; margin: 2px 0; color: var(--led); }
.plan-card-meta { font-size: 12px; color: var(--muted); }
.plan-card-bar { margin-top: 10px; height: 4px; border-radius: 4px; background: var(--border); overflow: hidden; }
.plan-card-bar span { display: block; height: 100%; background: var(--green); }

.app-user { display: flex; align-items: center; gap: 10px; padding: 0 4px; }
.app-avatar {
    width: 36px; height: 36px; border-radius: 50%; background: var(--green); color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; flex: none;
}
.app-user-text { min-width: 0; flex: 1; }
.app-user-name { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-user-team { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-signout { font-size: 12px; color: var(--muted); }

.app-main { margin-left: 240px; min-height: 100vh; }
.app-top {
    display: flex; align-items: center; gap: 16px;
    padding: 18px 32px; border-bottom: 1px solid var(--border);
    position: sticky; top: 0; background: rgba(17, 24, 39, .92); backdrop-filter: blur(8px); z-index: 10;
}
.app-title { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.app-subtitle { font: 400 12px var(--mono); color: var(--muted); margin-top: 2px; }
.app-top-actions { margin-left: auto; display: flex; gap: 10px; }
.app-menu-btn { display: none; background: none; border: 1px solid var(--border); color: #fff; border-radius: 8px; width: 40px; height: 40px; font-size: 18px; cursor: pointer; }
.app-content { padding: 28px 32px 60px; max-width: 1200px; }

/* ---------- Stat cards ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 22px; }
.stat {
    background: var(--surface); border: 1px solid var(--border); border-top: 3px solid var(--green);
    border-radius: var(--radius); padding: 18px 20px;
}
.stat-label { font: 500 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.stat-value { font-size: 44px; line-height: 1.1; margin: 8px 0 4px; }
.stat-value small { font-size: 22px; color: var(--muted); text-shadow: none; }
.stat-foot { font-size: 12px; color: var(--muted); }

/* 1.4.1 — each card gets its own color (top bar, number, glow) */
.stat-amber { border-top-color: var(--amber); }
.stat-amber .stat-value.led { color: var(--amber); text-shadow: 0 0 12px rgba(255, 176, 0, .55); }
.stat-green { border-top-color: var(--green); }
.stat-green .stat-value.led { color: var(--led); text-shadow: 0 0 12px rgba(23, 133, 8, .75); }
.stat-blue { border-top-color: var(--blue); }
.stat-blue .stat-value.led { color: var(--blue); text-shadow: 0 0 12px rgba(56, 189, 248, .55); }
.stat .stat-value.led.is-dim { color: var(--border); text-shadow: none; }

/* ---------- Panels ---------- */
.panel-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; }
.panel {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    margin-bottom: 18px; overflow: hidden;
}
.panel-head {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.panel-head h2 { font: 500 12px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: #cbd5e1; }
.panel-head a { font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.panel-body { padding: 20px; }
.panel-body + .panel-head { border-top: 1px solid var(--border); }
.panel-body.is-locked { opacity: .85; }
.panel-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 20px; border-top: 1px solid var(--border); background: var(--surface-2); }
.empty { padding: 34px 20px; text-align: center; color: var(--muted); }
.empty .btn { margin: 6px 4px 0; }

/* ---------- Game rows ---------- */
.game-list { padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.game-row {
    display: flex; align-items: center; gap: 14px;
    padding: 12px 14px; border-radius: 10px; background: var(--bg); border: 1px solid var(--border);
}
.game-row.is-live { border-color: rgba(23, 133, 8, .6); }
.game-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); flex: none; }
.game-row.is-live .game-dot { background: var(--led); box-shadow: 0 0 8px var(--led); }
.game-row.is-upcoming .game-dot { background: var(--amber); }
.game-main { flex: 1; min-width: 0; }
.game-name { color: #fff; font-weight: 600; }
.game-meta { font-size: 12px; color: var(--muted); margin-top: 2px; }
.game-score { font-size: 28px; min-width: 64px; text-align: right; }
.game-row.is-final .game-score { color: #fff; text-shadow: none; }

/* ---------- Quick actions ---------- */
.quick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 14px; }
.quick a {
    display: flex; flex-direction: column; gap: 4px; padding: 18px 14px; text-align: center;
    background: var(--bg); border: 1px solid var(--border); border-radius: 10px; color: #fff;
}
.quick a:hover { border-color: var(--green); text-decoration: none; }
.quick span { font-size: 12px; color: var(--muted); }

/* ---------- Forms ---------- */
.form-label { font: 500 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; flex: 1; min-width: 0; }
.field > span { font-size: 13px; font-weight: 600; color: #cbd5e1; display: flex; justify-content: space-between; }
.field small { font-size: 12px; color: var(--muted); }
.field-link { font-weight: 500; }
.field-row { display: flex; gap: 14px; }
input[type="text"], input[type="email"], input[type="password"], input[type="datetime-local"], select {
    width: 100%; padding: 11px 12px; border-radius: 8px;
    border: 1px solid var(--border); background: var(--bg); color: #fff;
    font: 15px var(--body);
}
input:focus, select:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(23, 133, 8, .25); }
input[type="color"] { width: 64px; height: 40px; border: 1px solid var(--border); background: var(--bg); border-radius: 8px; padding: 3px; }
input[type="file"] { color: var(--muted); font-size: 13px; }
input::-webkit-calendar-picker-indicator { filter: invert(1); }
.check { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; color: #cbd5e1; font-size: 14px; }
.check-sm { font-size: 12px; margin: 0; }
.check input { accent-color: var(--green); width: 16px; height: 16px; }
.thumb { width: 56px; height: 56px; object-fit: contain; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; }
.hp { position: absolute; left: -9999px; }
.form-fine { font-size: 12px; color: var(--muted); margin: 12px 0 0; text-align: center; }

/* ---------- Share box ---------- */
.share {
    display: flex; gap: 20px; align-items: center;
    background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--green);
    border-radius: var(--radius); padding: 18px; margin-bottom: 18px;
}
.share-qr img { display: block; background: #fff; padding: 8px; border-radius: 8px; }
.share-body { flex: 1; min-width: 0; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { font-family: var(--mono); font-size: 13px; }
.share-links { margin-top: 10px; font-size: 13px; color: var(--muted); }

/* ---------- Billing ---------- */
.plan-now-name { font-size: 26px; font-weight: 800; color: var(--led); }
.price-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 10px; }
.price-card {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px;
}
.price-card.is-featured { border-color: var(--green); box-shadow: 0 0 0 1px var(--green), 0 10px 30px rgba(23, 133, 8, .15); }
.price-name { font: 500 12px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: #cbd5e1; }
.price-amount { font-size: 54px; line-height: 1.1; margin: 8px 0 2px; }
.price-amount small { font-size: 16px; color: var(--muted); text-shadow: none; font-family: var(--body); }
.paypal-slot { margin-top: 16px; min-height: 50px; }
.ticks { list-style: none; padding: 0; margin: 16px 0; }
.ticks li { position: relative; padding-left: 24px; margin-bottom: 8px; color: #cbd5e1; }
.ticks li::before { content: '✓'; position: absolute; left: 0; color: var(--led); font-weight: 800; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font: 500 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 12px 20px; }
.table td { padding: 12px 20px; border-top: 1px solid var(--border); }

/* ---------- Welcome ---------- */
.hero-card {
    text-align: center; padding: 40px 24px; margin-bottom: 18px;
    background: radial-gradient(circle at 50% 0%, rgba(23, 133, 8, .25), transparent 60%), var(--surface);
    border: 1px solid var(--border); border-radius: var(--radius);
}
.hero-check {
    width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 16px;
    display: flex; align-items: center; justify-content: center;
    background: var(--green); font-size: 30px; font-weight: 800; box-shadow: 0 0 30px rgba(23, 133, 8, .6);
}
.hero-card h2 { font-size: 26px; margin-bottom: 8px; }
.hero-card p { color: #cbd5e1; margin: 0; }
.steps { margin: 0; padding: 20px 20px 20px 44px; }
.steps li { margin-bottom: 12px; color: #cbd5e1; }
.steps b { color: #fff; }

/* ---------- Auth pages ---------- */
.auth-nav { display: flex; align-items: center; justify-content: space-between; padding: 20px 32px; border-bottom: 1px solid var(--border); }
.auth-switch { color: var(--muted); font-size: 14px; }
.auth-switch b { color: var(--led); }
.auth-main { padding: 48px 24px 80px; }
.auth-card {
    background: var(--surface); border: 1px solid var(--border); border-top: 4px solid var(--green);
    border-radius: var(--radius); padding: 30px;
}
.auth-card-narrow { max-width: 420px; margin: 0 auto; }
.auth-card h1, .auth-card h2 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.auth-lead { color: var(--muted); margin: 0 0 22px; }
.auth-split { display: grid; grid-template-columns: 1fr 480px; gap: 56px; max-width: 1080px; margin: 0 auto; align-items: start; }
.auth-pitch h1 { font-size: 46px; font-weight: 800; letter-spacing: -0.03em; margin: 18px 0 16px; }
.auth-pitch h1 em { font-style: normal; color: var(--led); }
.auth-pitch > p { color: #cbd5e1; font-size: 17px; max-width: 520px; }
.pill {
    display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px;
    border: 1px solid rgba(23, 133, 8, .5); background: rgba(23, 133, 8, .12);
    font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--led);
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); }

.plan-pick { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.plan-option {
    display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer;
    border: 1px solid var(--border); border-radius: 10px; background: var(--bg);
}
.plan-option:has(input:checked) { border-color: var(--green); box-shadow: 0 0 0 1px var(--green); }
.plan-option input { accent-color: var(--green); width: 16px; height: 16px; }
.plan-option-body { flex: 1; display: flex; flex-direction: column; }
.plan-option-name { font-weight: 700; }
.plan-option-desc { font-size: 12px; color: var(--muted); }
.plan-option-price { font: 500 18px var(--mono); color: var(--led); white-space: nowrap; }
.plan-option-price small { font-size: 11px; color: var(--muted); }

/* ---------- Mobile ---------- */
@media (max-width: 1000px) {
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .panel-grid, .auth-split { grid-template-columns: 1fr; }
    .auth-pitch h1 { font-size: 34px; }
}
@media (max-width: 800px) {
    .app-side { transform: translateX(-100%); transition: transform .2s; }
    body.nav-open .app-side { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .5); }
    .app-main { margin-left: 0; }
    .app-menu-btn { display: inline-block; }
    .app-top { padding: 14px 16px; }
    .app-content { padding: 20px 16px 50px; }
    .field-row, .price-grid { flex-direction: column; display: flex; gap: 0; }
    .price-grid { gap: 16px; }
    .share { flex-direction: column; align-items: stretch; }
    .share-qr { align-self: center; }
    .stat-value { font-size: 36px; }
    .table { display: block; overflow-x: auto; white-space: nowrap; }
}
@media (max-width: 480px) {
    .stat-grid { grid-template-columns: 1fr; }
    .app-top .btn { padding: 10px 12px; font-size: 13px; }
    .auth-card { padding: 22px; }
}


/* ============================================
   1.5.0 — SPONSORS
   ============================================ */
.tag-green { background: rgba(23, 133, 8, .2); color: var(--led); }
.game-meta .tag { margin-left: 6px; vertical-align: 1px; }
.sponsor-thumb {
    width: 44px; height: 44px; flex: none; border-radius: 8px; background: #fff;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.sponsor-thumb img { max-width: 40px; max-height: 40px; object-fit: contain; }
.sponsor-thumb span { font-weight: 800; color: var(--bg); }
.sponsor-nums { display: flex; gap: 16px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.sponsor-nums b { color: #fff; font-weight: 500; }
textarea {
    width: 100%; padding: 11px 12px; border-radius: 8px; border: 1px solid var(--border);
    background: var(--bg); color: #fff; font: 15px var(--body); resize: vertical;
}
textarea:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(23, 133, 8, .25); }
.check span b { color: #fff; }
.check { align-items: flex-start; }
.check input { margin-top: 3px; flex: none; }
.pick-list {
    margin: 4px 0 18px 26px; padding: 12px; max-height: 220px; overflow: auto;
    background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
}
.pick-list .check { margin-bottom: 8px; }
.public-optin { margin-top: 10px; padding-top: 16px; border-top: 1px solid var(--border); }
.btn-danger { background: transparent; color: #fca5a5; border-color: rgba(239, 68, 68, .5); }
.btn-danger:hover { background: rgba(239, 68, 68, .12); }
.danger-zone { display: flex; justify-content: flex-end; margin: -6px 0 30px; }

/* Sponsor report */
.report-main { max-width: 1000px; margin: 0 auto; padding: 32px 24px 60px; }
.report-head { display: flex; gap: 20px; align-items: center; margin-bottom: 24px; }
.report-head h1 { font-size: 34px; font-weight: 800; letter-spacing: -0.02em; margin: 4px 0; }
.report-logo { width: 96px; height: 96px; object-fit: contain; background: #fff; border-radius: 12px; padding: 8px; }

@media (max-width: 800px) {
    .sponsor-row { flex-wrap: wrap; }
    .sponsor-nums { width: 100%; order: 3; padding-left: 58px; }
}
@media print {
    .no-print { display: none !important; }
    body.bsb-report { background: #fff; color: #111; }
    .bsb-report .stat, .bsb-report .panel { background: #fff; border-color: #ccc; break-inside: avoid; }
    .bsb-report .muted, .bsb-report .stat-foot, .bsb-report .table th { color: #555; }
    .bsb-report .led { text-shadow: none !important; }
    .bsb-report .stat-green .led { color: #178508; }
    .bsb-report .stat-blue .led { color: #0369a1; }
    .bsb-report .stat-amber .led { color: #b45309; }
    .bsb-report .panel-head h2, .bsb-report .report-head h1 { color: #111; }
    .bsb-report .auth-nav { border-color: #ccc; }
    .bsb-report .app-logo { color: #111; }
}
a.stat-link { display: block; color: inherit; }
a.stat-link:hover { text-decoration: none; transform: translateY(-2px); }
a.stat-link { transition: transform .15s; }
