/* ATS Edge — shared styles.
   Palette and typography follow the parent site so the section reads as part
   of it rather than as a bolted-on app. */

:root {
    --primary: #c8102e;
    --primary-glow: rgba(200, 16, 46, 0.4);
    --secondary: #00ff88;
    --accent: #f5d130;
    --bg: #0a0a0a;
    --surface: #111111;
    --surface2: #1a1a1a;
    --surface3: #222222;
    --text: #e8e8e8;
    --text-dim: #888;
    --border: #2a2a2a;

    --elite: #00ff88;
    --strong: #7dd3fc;
    --play: #f5d130;
    --lean: #fb923c;
    --pass: #6b7280;
    --win: #00ff88;
    --loss: #ef4444;
    --push: #9ca3af;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

h1, h2, h3, .display {
    font-family: 'Space Grotesk', system-ui, sans-serif;
    letter-spacing: -0.02em;
}

.wrap { max-width: 1240px; margin: 0 auto; padding: 0 22px; }

/* ── header ─────────────────────────────────────────────────────────────── */

.topbar {
    border-bottom: 1px solid var(--border);
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(10px);
    position: sticky; top: 0; z-index: 50;
}
.topbar-inner {
    display: flex; align-items: center; gap: 26px;
    height: 62px;
}
.brand {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700; font-size: 17px; letter-spacing: -0.03em;
    display: flex; align-items: center; gap: 9px; white-space: nowrap;
}
.brand-mark {
    width: 26px; height: 26px; border-radius: 6px;
    background: linear-gradient(135deg, var(--primary), #7a0a1c);
    display: grid; place-items: center; font-size: 13px; color: #fff;
}
.nav { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; }
.nav a {
    padding: 7px 13px; border-radius: 7px; font-size: 12.5px;
    color: var(--text-dim); transition: all .16s; white-space: nowrap;
}
.nav a:hover { color: var(--text); background: var(--surface2); }
.nav a.active { color: var(--text); background: var(--surface2); box-shadow: inset 0 0 0 1px var(--border); }
.nav a.home-link { color: var(--primary); }

/* ── page head ──────────────────────────────────────────────────────────── */

.page-head { padding: 40px 0 18px; }
.page-head h1 { font-size: clamp(27px, 4.4vw, 44px); font-weight: 700; }
.page-head .sub { color: var(--text-dim); font-size: 13.5px; margin-top: 9px; max-width: 74ch; }
.stamp {
    display: inline-flex; align-items: center; gap: 7px; margin-top: 14px;
    font-size: 11.5px; color: var(--text-dim);
    border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--secondary); }
.dot.stale { background: var(--lean); }

/* ── notices ────────────────────────────────────────────────────────────── */

.notice {
    border: 1px solid var(--border); border-left: 3px solid var(--accent);
    background: var(--surface); border-radius: 8px;
    padding: 15px 18px; margin: 20px 0; font-size: 13px; color: #cfcfcf;
}
.notice strong { color: var(--accent); font-weight: 500; }
.notice.warn { border-left-color: var(--lean); }
.notice.warn strong { color: var(--lean); }

/* ── pick cards ─────────────────────────────────────────────────────────── */

.cards { display: grid; gap: 16px; margin: 8px 0 40px; }

.pick {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 12px; overflow: hidden; transition: border-color .18s, transform .18s;
    display: block;
}
.pick:hover { border-color: #3a3a3a; transform: translateY(-1px); }
.pick-top { display: flex; align-items: stretch; }

.rankbox {
    width: 62px; flex: 0 0 62px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    background: var(--surface2); border-right: 1px solid var(--border);
    font-family: 'Space Grotesk', sans-serif;
}
.rankbox .n { font-size: 27px; font-weight: 700; line-height: 1; }
.rankbox .lbl { font-size: 8.5px; color: var(--text-dim); letter-spacing: .13em; margin-top: 4px; }

.pick-body { flex: 1; padding: 16px 18px; min-width: 0; }
.pick-meta {
    display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
    font-size: 11px; color: var(--text-dim); margin-bottom: 7px;
}
.tag {
    border: 1px solid var(--border); border-radius: 5px; padding: 2px 7px;
    font-size: 10px; letter-spacing: .05em; text-transform: uppercase;
}
.selection {
    font-family: 'Space Grotesk', sans-serif; font-size: 21px; font-weight: 700;
    letter-spacing: -0.02em; margin-bottom: 3px; word-break: break-word;
}
.matchup { font-size: 12.5px; color: var(--text-dim); }

.conf {
    padding: 5px 12px; border-radius: 6px; font-size: 11px; font-weight: 700;
    letter-spacing: .07em; white-space: nowrap; align-self: flex-start;
}
.conf-elite  { background: rgba(0,255,136,.13); color: var(--elite); box-shadow: inset 0 0 0 1px rgba(0,255,136,.3); }
.conf-strong { background: rgba(125,211,252,.13); color: var(--strong); box-shadow: inset 0 0 0 1px rgba(125,211,252,.3); }
.conf-play   { background: rgba(245,209,48,.13); color: var(--play); box-shadow: inset 0 0 0 1px rgba(245,209,48,.3); }
.conf-lean   { background: rgba(251,146,60,.13); color: var(--lean); box-shadow: inset 0 0 0 1px rgba(251,146,60,.3); }
.conf-pass   { background: rgba(107,114,128,.13); color: var(--pass); box-shadow: inset 0 0 0 1px rgba(107,114,128,.3); }

.scorebox {
    flex: 0 0 96px; border-left: 1px solid var(--border); background: var(--surface2);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.scorebox .val { font-family: 'Space Grotesk', sans-serif; font-size: 26px; font-weight: 700; line-height: 1; }
.scorebox .cap { font-size: 8.5px; color: var(--text-dim); letter-spacing: .13em; margin-top: 5px; }

.metrics {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
    border-top: 1px solid var(--border);
}
.metric { padding: 11px 14px; border-right: 1px solid var(--border); }
.metric:last-child { border-right: none; }
.metric .k { font-size: 9.5px; color: var(--text-dim); letter-spacing: .1em; text-transform: uppercase; }
.metric .v { font-family: 'Space Grotesk', sans-serif; font-size: 15.5px; font-weight: 600; margin-top: 3px; }
.pos { color: var(--secondary); }
.neg { color: var(--loss); }

.linefoot {
    border-top: 1px solid var(--border); padding: 9px 16px;
    font-size: 10.5px; color: var(--text-dim);
    display: flex; gap: 14px; flex-wrap: wrap; align-items: center;
}

/* ── reasons ────────────────────────────────────────────────────────────── */

.reasons { border-top: 1px solid var(--border); padding: 4px 0; }
.reason { padding: 11px 18px; border-bottom: 1px solid rgba(42,42,42,.5); }
.reason:last-child { border-bottom: none; }
.reason .rl {
    font-size: 9.5px; letter-spacing: .13em; color: var(--accent);
    text-transform: uppercase; margin-bottom: 4px;
}
.reason .rt { font-size: 12.5px; color: #c9c9c9; }

/* ── tables ─────────────────────────────────────────────────────────────── */

.panel {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 11px; overflow: hidden; margin-bottom: 22px;
}
.panel-head {
    padding: 14px 18px; border-bottom: 1px solid var(--border);
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    flex-wrap: wrap;
}
.panel-head h2 { font-size: 15px; font-weight: 600; }
.panel-head .hint { font-size: 11px; color: var(--text-dim); }

.tablewrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
thead th {
    text-align: left; padding: 10px 14px; font-size: 10px; letter-spacing: .1em;
    text-transform: uppercase; color: var(--text-dim); font-weight: 500;
    border-bottom: 1px solid var(--border); white-space: nowrap;
    background: var(--surface2); position: sticky; top: 0;
}
tbody td { padding: 10px 14px; border-bottom: 1px solid rgba(42,42,42,.55); white-space: nowrap; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: rgba(255,255,255,.022); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td.wide { white-space: normal; min-width: 190px; }

.res { font-weight: 700; font-size: 11px; letter-spacing: .06em; }
.res-WIN { color: var(--win); }
.res-LOSS { color: var(--loss); }
.res-PUSH { color: var(--push); }
.res-PENDING { color: var(--text-dim); }

/* ── stat tiles ─────────────────────────────────────────────────────────── */

.tiles {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
    gap: 12px; margin-bottom: 22px;
}
.tile {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 10px; padding: 15px 16px;
}
.tile .k { font-size: 9.5px; letter-spacing: .11em; color: var(--text-dim); text-transform: uppercase; }
.tile .v {
    font-family: 'Space Grotesk', sans-serif; font-size: 25px; font-weight: 700;
    margin-top: 6px; line-height: 1;
}
.tile .s { font-size: 11px; color: var(--text-dim); margin-top: 5px; }

/* ── controls ───────────────────────────────────────────────────────────── */

.controls { display: flex; gap: 9px; flex-wrap: wrap; margin-bottom: 18px; }
select, input[type="search"], input[type="date"], button.btn {
    background: var(--surface2); border: 1px solid var(--border); color: var(--text);
    border-radius: 7px; padding: 8px 11px; font-family: inherit; font-size: 12px;
}
select:focus, input:focus { outline: none; border-color: #3d3d3d; }
button.btn { cursor: pointer; }
button.btn:hover { background: var(--surface3); }

/* ── charts ─────────────────────────────────────────────────────────────── */

.chart { width: 100%; height: 230px; display: block; }
.chart-wrap { padding: 16px 18px; }

/* ── misc ───────────────────────────────────────────────────────────────── */

.empty { padding: 44px 24px; text-align: center; color: var(--text-dim); font-size: 13px; }
.muted { color: var(--text-dim); }
.small { font-size: 11.5px; }
.mono { font-variant-numeric: tabular-nums; }

.prose { max-width: 78ch; font-size: 13.5px; color: #c6c6c6; }
.prose h2 { font-size: 19px; color: var(--text); margin: 30px 0 11px; }
.prose h3 { font-size: 14.5px; color: var(--text); margin: 22px 0 8px; }
.prose p { margin-bottom: 13px; }
.prose ul { margin: 0 0 13px 20px; }
.prose li { margin-bottom: 6px; }
.prose code {
    background: var(--surface2); padding: 1.5px 5px; border-radius: 4px;
    font-size: 12px; color: var(--accent);
}
.prose strong { color: var(--text); font-weight: 500; }
/* Tables and health panels carry more columns than the reading measure allows,
   so let them use the full container width instead of being clipped by it. */
.prose .panel, .prose .tiles { max-width: none; width: 100%; }

footer {
    border-top: 1px solid var(--border); margin-top: 46px; padding: 22px 0 34px;
    font-size: 11.5px; color: var(--text-dim);
}
footer a { color: var(--text-dim); text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 720px) {
    .topbar-inner { height: auto; padding: 11px 0; flex-wrap: wrap; gap: 10px; }
    .nav { margin-left: 0; width: 100%; }
    .pick-top { flex-wrap: wrap; }
    .scorebox { flex: 1 0 100%; border-left: none; border-top: 1px solid var(--border); flex-direction: row; gap: 9px; padding: 9px; }
    .scorebox .cap { margin-top: 0; }
    .rankbox { width: 46px; flex: 0 0 46px; }
    .selection { font-size: 17px; }
}
