/* AMS Hive Command Center — AMS working brand: white-led, AMS gold, deep charcoal. */
:root {
  --gold: #B98532; --gold-deep: #94681F; --gold-soft: #F4EBDC; --gold-line: #E6D3B0; --gold-bright: #D0A04C;
  --ink: #231F20; --ink-2: #4A4441; --muted: #7A716A; --faint: #A39A92;
  --canvas: #F7F5F1; --surface: #FFFFFF; --surface-2: #FBFAF7; --line: #E8E2D8; --line-2: #F0EBE3;
  --good: #2E7D4F; --good-bg: #E7F3EC; --warn: #A86A00; --warn-bg: #FBF0DA; --crit: #B3261E; --crit-bg: #FBE7E5; --info: #3D5A80; --info-bg: #E8EEF6;
  --neg: #6B625C;
  --r: 14px; --r-sm: 9px; --shadow: 0 1px 2px rgba(35,31,32,.04), 0 6px 24px rgba(35,31,32,.05);
  --sidebar: 264px;
  --font: Inter, "Segoe UI", Arial, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font); background: var(--canvas); color: var(--ink); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--gold-deep); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: 26px; } h2 { font-size: 18px; } h3 { font-size: 15px; } h4 { font-size: 13px; }
p { margin: 0 0 8px; }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; }
.noscript { padding: 40px; text-align: center; }
.boot { min-height: 100vh; display: grid; place-items: center; }
.boot-mark img { width: 120px; opacity: .9; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .45; } }

/* ---------- utility ---------- */
.eyebrow { font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); font-weight: 600; margin: 0 0 6px; }
.muted { color: var(--muted); } .faint { color: var(--faint); } .small { font-size: 12px; } .xs { font-size: 11px; }
.num { font-variant-numeric: tabular-nums; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; } .row.end { justify-content: flex-end; }
.stack > * + * { margin-top: 14px; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-main { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.hidden { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.mt { margin-top: 18px; } .mt-s { margin-top: 8px; }

/* ---------- buttons & inputs ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; border: 1px solid transparent; background: var(--gold); color: #fff; border-radius: var(--r-sm); padding: 9px 14px; font-weight: 600; font-size: 13px; cursor: pointer; text-decoration: none; transition: background .15s, box-shadow .15s; }
.btn:hover { background: var(--gold-deep); text-decoration: none; }
.btn:focus-visible, .input:focus-visible, .nav a:focus-visible, .chip:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: var(--surface-2); border-color: var(--gold-line); }
.btn.dark { background: var(--ink); } .btn.dark:hover { background: #000; }
.btn.danger { background: transparent; color: var(--crit); border-color: #EBC9C6; }
.btn.sm { padding: 6px 10px; font-size: 12px; }
.btn.block { width: 100%; justify-content: center; padding: 12px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.input, select.input, textarea.input { width: 100%; padding: 10px 12px; border: 1px solid #DDD5CA; border-radius: var(--r-sm); background: #fff; }
.input:focus { border-color: var(--gold); outline: none; box-shadow: 0 0 0 3px rgba(185,133,50,.15); }
label.lbl { display: block; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin: 0 0 6px; }
.field { margin-bottom: 14px; }
.check { display: inline-flex; gap: 6px; align-items: center; font-size: 12.5px; margin: 0 12px 6px 0; cursor: pointer; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r-sm); background: #fff; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 7px; cursor: pointer; font-size: 12.5px; color: var(--ink-2); }
.seg button.on { background: var(--ink); color: #fff; }

/* ---------- login ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.auth-brand { background: var(--ink); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.auth-brand::after { content: ""; position: absolute; inset: auto -20% -40% auto; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(208,160,76,.22), transparent 65%); }
.auth-brand img { width: min(360px, 80%); position: relative; z-index: 1; }
.auth-brand h2 { font-size: 30px; font-weight: 600; max-width: 420px; line-height: 1.2; position: relative; z-index: 1; }
.auth-brand .eyebrow { color: var(--gold-bright); }
.auth-brand .tag { color: #CFC7BF; font-size: 13px; max-width: 420px; position: relative; z-index: 1; }
.auth-panel { display: grid; place-items: center; padding: 32px 20px; }
.auth-card { width: min(420px, 100%); }
.auth-card .mark { width: 92px; display: block; margin-bottom: 18px; }
.auth-card h1 { font-size: 24px; margin-bottom: 4px; }
.auth-card .sub { color: var(--muted); margin-bottom: 24px; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; margin: 18px 0; }
.divider::before, .divider::after { content: ""; height: 1px; background: var(--line); flex: 1; }
.telemetry { margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 11px; color: var(--faint); line-height: 1.6; }
.err { background: var(--crit-bg); color: var(--crit); border-radius: var(--r-sm); padding: 10px 12px; font-size: 13px; margin-bottom: 14px; }
.ok { background: var(--good-bg); color: var(--good); border-radius: var(--r-sm); padding: 10px 12px; font-size: 13px; margin-bottom: 14px; }
.qr { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 12px; display: inline-block; }
.qr svg { display: block; width: 188px; height: 188px; }
.secret { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; background: var(--surface-2); border: 1px dashed var(--gold-line); padding: 8px 10px; border-radius: 8px; word-break: break-all; }
.code-input { letter-spacing: .5em; font-size: 22px; text-align: center; font-variant-numeric: tabular-nums; }

/* ---------- shell ---------- */
.shell { display: flex; min-height: 100vh; }
.sidebar { width: var(--sidebar); background: #fff; border-right: 1px solid var(--line); position: fixed; inset: 0 auto 0 0; display: flex; flex-direction: column; z-index: 30; transition: transform .2s; }
.sidebar .brand { padding: 22px 22px 12px; border-bottom: 1px solid var(--line-2); }
.sidebar .brand img { width: 128px; display: block; }
.sidebar .brand .product { font-size: 10.5px; letter-spacing: .2em; color: var(--gold); font-weight: 700; margin-top: 10px; }
.nav { padding: 10px 12px; overflow-y: auto; flex: 1; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 8.5px 10px; border-radius: 9px; color: var(--ink-2); font-size: 13.2px; font-weight: 500; text-decoration: none; }
.nav a svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; opacity: .8; }
.nav a:hover { background: var(--surface-2); color: var(--ink); }
.nav a.on { background: var(--gold-soft); color: var(--gold-deep); font-weight: 600; }
.nav a.on svg { opacity: 1; }
.nav .badge { margin-left: auto; }
.nav .sep { height: 1px; background: var(--line-2); margin: 8px 10px; }
.sidebar .me { border-top: 1px solid var(--line-2); padding: 14px 18px; display: flex; gap: 10px; align-items: center; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: var(--gold-bright); display: grid; place-items: center; font-weight: 700; font-size: 12px; letter-spacing: .04em; flex: none; }
.me .who { min-width: 0; } .me .who b { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .me .who span { font-size: 11px; color: var(--muted); }
.main { margin-left: var(--sidebar); flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(247,245,241,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); padding: 12px 32px; display: flex; align-items: center; gap: 14px; }
.topbar .crumb { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); font-weight: 600; }
.topbar .title { font-size: 17px; font-weight: 600; }
.topbar .spacer { flex: 1; }
.iconbtn { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; cursor: pointer; position: relative; color: var(--ink); }
.iconbtn svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.7; }
.iconbtn .dot { position: absolute; top: -5px; right: -5px; min-width: 18px; height: 18px; border-radius: 9px; background: var(--crit); color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; padding: 0 4px; }
.menu-toggle { display: none; }
.content { padding: 26px 32px 40px; flex: 1; width: 100%; max-width: 1480px; }
.footer { padding: 18px 32px 26px; color: var(--faint); font-size: 11px; display: flex; gap: 10px; flex-wrap: wrap; justify-content: space-between; border-top: 1px solid var(--line); }
.scrim { display: none; }
.mockbar { background: repeating-linear-gradient(135deg, #FFF8EA, #FFF8EA 12px, #FCF2DD 12px, #FCF2DD 24px); border-bottom: 1px solid var(--gold-line); color: #7A5512; font-size: 12px; padding: 7px 32px; display: flex; gap: 8px; align-items: center; }
.mockbar b { font-weight: 700; letter-spacing: .06em; }

/* ---------- cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow); min-width: 0; }
.card.flat { box-shadow: none; }
.card-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-h h2 { font-size: 15.5px; }
.card-h .sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.section-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 28px 0 12px; flex-wrap: wrap; }
.section-h:first-child { margin-top: 0; }
.page-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-h p { color: var(--muted); margin: 4px 0 0; max-width: 720px; }
.hero { background: var(--ink); color: #fff; border-radius: 18px; padding: 28px 30px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; right: -120px; top: -160px; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(circle, rgba(208,160,76,.20), transparent 65%); pointer-events: none; }
.hero h1 { font-size: 30px; margin: 4px 0 8px; }
.hero p { color: #D8D3CD; max-width: 760px; margin: 0; }
.hero .eyebrow { color: var(--gold-bright); }
.hero-stats { display: flex; gap: 0; position: relative; z-index: 1; }
.hero-stats div { padding: 0 22px; border-left: 1px solid #4A4441; text-align: center; }
.hero-stats strong { display: block; font-size: 34px; color: var(--gold-bright); font-weight: 600; line-height: 1.1; }
.hero-stats span { font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: #BFB6AD; }

/* stat tiles */
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.tile .k { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.tile .v { font-size: 25px; font-weight: 600; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.2; }
.tile .v.neg { color: var(--crit); }
.tile .d { font-size: 12px; color: var(--muted); }
.tile .src { margin-top: auto; padding-top: 8px; }

/* source attribution chip */
.src { display: inline-flex; align-items: center; gap: 6px; font-size: 10.5px; color: var(--faint); flex-wrap: wrap; }
.src .fr { display: inline-flex; align-items: center; gap: 4px; }
.src .fr::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--faint); }
.src .fr.fresh::before { background: var(--good); } .src .fr.stale::before { background: var(--warn); } .src .fr.expired::before, .src .fr.never::before { background: var(--crit); }
.sample { font-size: 9.5px; font-weight: 700; letter-spacing: .1em; color: #8A6116; background: #FCF2DD; border: 1px solid var(--gold-line); padding: 0 5px; border-radius: 4px; }

/* pills & badges */
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.pill.green, .pill.good, .pill.healthy, .pill.done, .pill.on_track, .pill.fresh { background: var(--good-bg); color: var(--good); }
.pill.amber, .pill.warning, .pill.at_risk, .pill.degraded, .pill.stale, .pill.high, .pill.in_progress { background: var(--warn-bg); color: var(--warn); }
.pill.red, .pill.critical, .pill.slipped, .pill.blocked, .pill.down, .pill.expired { background: var(--crit-bg); color: var(--crit); }
.pill.info, .pill.unconfigured, .pill.pending, .pill.never, .pill.normal, .pill.open { background: var(--info-bg); color: var(--info); }
.pill.gold { background: var(--gold-soft); color: var(--gold-deep); }
.pill.dark { background: var(--ink); color: #fff; }
.pill.ams_owned { background: var(--ink); color: var(--gold-bright); }
.pill.joint_venture { background: var(--gold-soft); color: var(--gold-deep); }
.pill.authorized_project { background: #fff; color: var(--ink-2); border: 1px solid var(--line); }
.rag { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.rag.green { background: var(--good); } .rag.amber { background: #D99A1E; } .rag.red { background: var(--crit); } .rag.unknown { background: var(--faint); }
.badge { background: var(--crit); color: #fff; font-size: 10px; font-weight: 700; border-radius: 9px; padding: 1px 6px; }

/* business cards */
.biz { display: flex; flex-direction: column; gap: 12px; cursor: default; }
.biz .top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.biz h3 { font-size: 18px; }
.biz .meta { font-size: 12px; color: var(--muted); }
.biz .kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.biz .kpi { background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 10px; padding: 9px 10px; min-width: 0; }
.biz .kpi .l { font-size: 10.5px; color: var(--muted); line-height: 1.3; }
.biz .kpi .n { font-weight: 600; font-size: 15px; font-variant-numeric: tabular-nums; }
.biz .next { font-size: 12.5px; border-top: 1px solid var(--line-2); padding-top: 10px; }
.biz .actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }

/* launch cards */
.launch { display: flex; flex-direction: column; gap: 10px; position: relative; }
.launch .kind { font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.launch h3 { font-size: 17px; }
.launch p { color: var(--muted); font-size: 13px; min-height: 38px; }
.launch .foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: auto; }

/* lists */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; gap: 12px; align-items: flex-start; padding: 11px 0; border-bottom: 1px solid var(--line-2); }
.list li:last-child { border-bottom: 0; }
.list .grow { flex: 1; min-width: 0; }
.list .t { font-weight: 500; }
.list .s { font-size: 12px; color: var(--muted); }
.empty { color: var(--faint); font-size: 13px; padding: 14px 0; text-align: center; }
.datebox { width: 44px; flex: none; text-align: center; border: 1px solid var(--line); border-radius: 9px; padding: 4px 0; background: #fff; }
.datebox b { display: block; font-size: 16px; line-height: 1.1; } .datebox span { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); font-weight: 700; }

/* tables */
.table-wrap { overflow-x: auto; margin: 0 -4px; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th { text-align: left; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface-2); }
.table td { padding: 10px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.table tr:hover td { background: #FDFCFA; }
.table td.num, .table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table.claims th { width: 160px; text-transform: none; letter-spacing: 0; font-size: 12px; background: transparent; }
.table.claims td { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; word-break: break-all; }

/* progress */
.bar { height: 6px; border-radius: 3px; background: var(--line-2); overflow: hidden; min-width: 60px; }
.bar > i { display: block; height: 100%; background: var(--gold); border-radius: 3px; }
.band { position: relative; height: 10px; border-radius: 5px; background: var(--line-2); margin: 10px 0 4px; }
.band .zone { position: absolute; top: 0; bottom: 0; background: var(--gold-soft); border-left: 2px solid var(--gold-line); border-right: 2px solid var(--gold-line); }
.band .mark { position: absolute; top: -4px; width: 4px; height: 18px; border-radius: 2px; background: var(--ink); transform: translateX(-2px); }

/* charts */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid line { stroke: var(--line-2); stroke-width: 1; }
.chart .axis text { fill: var(--faint); font-size: 10.5px; }
.chart .line { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: url(#goldfade); }
.chart .pt { fill: #fff; stroke: var(--gold); stroke-width: 2; }
.chart .pos { fill: var(--gold); } .chart .negb { fill: var(--neg); }
.chart .zero { stroke: var(--ink-2); stroke-width: 1; }
.chart .hit { fill: transparent; cursor: crosshair; }
.chart .hit:hover + .hl, .chart .hl { pointer-events: none; }
.legend { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.tip { position: fixed; z-index: 100; background: var(--ink); color: #fff; font-size: 12px; padding: 7px 10px; border-radius: 8px; pointer-events: none; max-width: 280px; box-shadow: 0 6px 20px rgba(0,0,0,.18); }
.tip b { color: var(--gold-bright); font-weight: 600; }

/* indicators */
.ind { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.ind:last-child { border-bottom: 0; }
.ind .ico { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: none; font-size: 12px; font-weight: 700; }
.ind .ico.good { background: var(--good-bg); color: var(--good); } .ind .ico.warning { background: var(--warn-bg); color: var(--warn); } .ind .ico.critical { background: var(--crit-bg); color: var(--crit); }

/* tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs button { border: 0; background: none; padding: 10px 14px; cursor: pointer; color: var(--muted); font-weight: 500; border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs button.on { color: var(--ink); border-bottom-color: var(--gold); font-weight: 600; }

/* media */
.asset { display: flex; flex-direction: column; gap: 8px; }
.asset .thumb { height: 110px; border-radius: 10px; background: linear-gradient(135deg, var(--gold-soft), #fff); border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--gold); }
.asset .thumb svg { width: 34px; height: 34px; stroke: currentColor; fill: none; stroke-width: 1.5; }

/* dirham glyph */
.dh { display: inline-block; width: .78em; height: .7em; margin-right: .12em; vertical-align: -.02em; }
.dh svg { width: 100%; height: 100%; display: block; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; }

/* toast & modal */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 10px; z-index: 120; font-size: 13px; box-shadow: 0 10px 30px rgba(0,0,0,.2); max-width: 92vw; }
.toast.err-t { background: var(--crit); }
.modal-bg { position: fixed; inset: 0; background: rgba(35,31,32,.45); z-index: 90; display: grid; place-items: center; padding: 16px; }
.modal { background: #fff; border-radius: 16px; width: min(640px, 100%); max-height: 90vh; overflow: auto; padding: 24px; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal h2 { margin-bottom: 14px; }
.modal .foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.caps { display: flex; flex-wrap: wrap; }
.mem { border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 10px; }

/* sandbox */
.sandbox { display: grid; place-items: center; min-height: 100vh; padding: 20px; }
.sandbox-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 32px; width: min(720px, 100%); box-shadow: var(--shadow); }
.sandbox-mark { width: 90px; margin-bottom: 14px; }
.sandbox h1 { margin-bottom: 10px; }

/* print */
@media print {
  .sidebar, .topbar, .mockbar, .footer, .no-print, .scrim { display: none !important; }
  .main { margin: 0; } .content { padding: 0; } body { background: #fff; } .card { box-shadow: none; break-inside: avoid; }
}

/* ---------- responsive ---------- */
@media (max-width: 1200px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-main { grid-template-columns: 1fr; } }
@media (max-width: 980px) {
  .sidebar { transform: translateX(-100%); box-shadow: 0 0 40px rgba(0,0,0,.2); }
  .shell.open .sidebar { transform: none; }
  .shell.open .scrim { display: block; position: fixed; inset: 0; background: rgba(35,31,32,.35); z-index: 25; }
  .main { margin-left: 0; }
  .menu-toggle { display: grid; }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .auth { grid-template-columns: 1fr; } .auth-brand { padding: 28px 24px; gap: 18px; } .auth-brand h2 { font-size: 22px; } .auth-brand img { width: 220px; }
  .topbar, .content, .footer, .mockbar { padding-left: 16px; padding-right: 16px; }
  .hero { grid-template-columns: 1fr; } .hero-stats div:first-child { border-left: 0; padding-left: 0; }
}
@media (max-width: 640px) {
  .g2, .g3, .g4 { grid-template-columns: 1fr; }
  .hero { padding: 22px; } .hero h1 { font-size: 24px; }
  .hero-stats strong { font-size: 26px; } .hero-stats div { padding: 0 14px; }
  .topbar .crumb { display: none; }
  .tile .v { font-size: 22px; }
  .auth-brand .tag { display: none; }
}
.legend i.lg-pos { background: var(--gold); } .legend i.lg-neg { background: var(--neg); }
select.sm-sel { padding: 5px 8px; font-size: 12.5px; width: auto; }
code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; background: var(--surface-2); padding: 1px 5px; border-radius: 4px; border: 1px solid var(--line-2); }
.band .zone { background: rgba(185,133,50,.32); }
.table td .src { min-width: 150px; }
