/* Inspecta console. Builds on inspecta.css tokens. */
:root { --l1: #BA8A00; --l2: #4A8AD8; }
body.app { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; background: var(--bg); }
.small { font-size: 12.5px; }
.accent { color: var(--accent); }
.link { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* Sidebar */
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 20px 14px; background: #0A0B0D; border-right: 1px solid var(--line); }
.side-brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 24px; color: var(--ink); }
.side-brand span { font-family: var(--font-display); font-stretch: 118%; font-weight: 700; font-size: 20px; line-height: 1; }
.side-nav { display: grid; gap: 2px; }
.side-nav a { position: relative; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 6px; font-size: 15px; font-weight: 500; color: var(--muted); transition: background-color var(--t-fast) ease, color var(--t-fast) ease; }
@media (hover: hover) and (pointer: fine) { .side-nav a:hover { background: rgba(236,233,226,.05); color: var(--ink); } }
.side-nav a[aria-current='page'] { background: rgba(236,233,226,.08); color: var(--ink); }
.side-nav a[aria-current='page']::before { content: ''; position: absolute; left: -14px; top: 10px; bottom: 10px; width: 3px; background: var(--accent); }
.side-badge { margin-left: auto; min-width: 22px; height: 20px; padding: 0 6px; border-radius: 4px; background: var(--accent); color: var(--accent-ink); font-size: 11px; display: grid; place-items: center; font-weight: 600; }
.side-badge[data-zero] { background: rgba(236,233,226,.1); color: var(--muted); }
.side-foot { margin-top: auto; display: grid; gap: 16px; padding: 0 6px; }
.side-org { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 8px; background: var(--surface); border: 1px solid var(--line); font-size: 14px; }
.side-org .muted { font-size: 12.5px; }
.org-dot { width: 32px; height: 32px; border-radius: 6px; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); font-size: 11px; font-weight: 600; flex: none; }
.side-db { padding-left: 6px; color: var(--muted); }

/* Main */
.main { min-width: 0; padding: 0 clamp(16px, 3vw, 36px) 40px; }
.demo-bar { margin: 0 calc(-1 * clamp(16px, 3vw, 36px)) 18px; padding: 8px 16px; text-align: center; font-size: 11px; letter-spacing: .06em; color: var(--accent-ink); background: repeating-linear-gradient(-45deg, var(--accent) 0 12px, #F2B800 12px 24px); }
.top { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.top-kicker { font-size: 11.5px; color: var(--muted); }
.top-title { font-family: var(--font-display); font-stretch: 112%; font-weight: 650; font-size: 38px; line-height: 1.1; letter-spacing: -.02em; }
.seg { display: flex; padding: 3px; border-radius: 7px; background: var(--surface); border: 1px solid var(--line-2); }
.seg button { padding: 8px 14px; border-radius: 5px; font-size: 14px; font-weight: 600; color: var(--muted); white-space: nowrap; transition: background-color var(--t-fast) ease, color var(--t-fast) ease; }
.seg button span { font-weight: 400; margin-left: 4px; }
.seg button[aria-pressed='true'] { background: var(--accent); color: var(--accent-ink); }
.seg[data-dim] { opacity: .5; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13.5px; }

.view[data-entering] { animation: viewIn 360ms var(--ease-out); }
@keyframes viewIn { from { opacity: 0; transform: translateY(8px); } }

.box { padding: 18px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.box-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.box-head h2 { font-family: var(--font-ui); font-stretch: 100%; font-size: 16px; font-weight: 600; letter-spacing: 0; max-width: none; line-height: 1.3; }
.count { min-width: 26px; height: 22px; padding: 0 7px; border-radius: 4px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 12px; }
.empty { padding: 28px 12px; text-align: center; color: var(--muted); font-size: 14.5px; }

/* Live */
.live-grid { display: grid; grid-template-columns: 1fr 360px; gap: 12px; align-items: start; }
.feed-box { padding: 0; overflow: hidden; }
.feed-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; font-size: 14px; color: var(--ink-2); }
.feed-head-r { display: flex; align-items: center; gap: 12px; }
.feed-wrap { background: #0A0B0D; }
canvas.app-feed { width: 100%; height: 380px; }
.feed-stats { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; border-top: 1px solid var(--line); }
.feed-stats div { padding: 12px 14px; border-right: 1px solid var(--line); }
.feed-stats div:last-child { border-right: 0; }
.feed-stats dt { font-size: 12.5px; color: var(--muted); }
.feed-stats dd { margin: 0; font-size: 19px; font-weight: 500; }
.feed-stats dd.flag { color: var(--accent); }
.feed-cfg { padding: 10px 14px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }
.feed-cfg b { color: var(--ink); font-weight: 500; }
.dot-live[data-paused] { background: var(--muted); }
.dot-live[data-paused]::after { display: none; }

.queue { display: grid; gap: 8px; }
.q { display: grid; grid-template-columns: 72px 1fr; gap: 12px; padding: 8px; border-radius: 8px; background: var(--bg-2); border: 1px solid var(--line); transition: opacity 320ms var(--ease-out), transform 320ms var(--ease-out), filter 320ms var(--ease-out); }
.q[data-enter] { opacity: 0; transform: translateY(-8px); filter: blur(3px); }
.q[data-leave] { opacity: 0; transform: translateX(16px); }
.q-img { width: 72px; height: 72px; border-radius: 5px; cursor: pointer; }
.q-t { font-weight: 600; font-size: 15px; line-height: 1.25; }
.q-m { font-size: 11px; color: var(--muted); margin-top: 2px; }
.q-m b { color: var(--accent); font-weight: 500; }
.q-tag { display: inline-block; margin-left: 6px; padding: 1px 6px; border-radius: 3px; font-size: 10.5px; background: rgba(74,138,216,.16); color: #9CC0EA; font-weight: 500; vertical-align: 1px; }
.q-act { display: flex; gap: 6px; margin-top: 8px; }
.q-act .btn { height: 30px; padding: 0 10px; font-size: 13px; flex: 1; }

/* Filters + gallery */
.filters { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 13px; border-radius: 6px; border: 1px solid var(--line-2); font-size: 14px; font-weight: 500; transition: background-color var(--t-fast) ease, color var(--t-fast) ease, border-color var(--t-fast) ease, transform var(--t-press) var(--ease-out); }
.chip:active { transform: scale(.97); }
.chip b { font-weight: 400; color: var(--muted); font-size: 12px; font-family: var(--font-mono); }
.chip[aria-pressed='true'] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chip[aria-pressed='true'] b { color: rgba(14,16,18,.6); }
.selects { display: flex; gap: 8px; flex-wrap: wrap; }
.sel { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 4px 0 12px; border-radius: 6px; border: 1px solid var(--line-2); font-size: 13px; color: var(--muted); }
.sel select, .set-row select { background: var(--surface); border: 0; color: var(--ink); font-size: 14px; padding: 6px 6px; border-radius: 4px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.g { display: flex; flex-direction: column; border-radius: 8px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.g-img { display: block; width: 100%; padding: 0; cursor: pointer; }
.g-img canvas { width: 100%; height: 150px; }
.g-body { padding: 10px 12px 12px; display: grid; gap: 4px; flex: 1; }
.g-t { font-weight: 600; font-size: 15px; }
.g-m { font-size: 11px; color: var(--muted); }
.g-m b { color: var(--accent); font-weight: 500; }
.g-dec { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.g .q-act { margin-top: 8px; }
.p-conf { background: var(--accent-soft); color: var(--accent); }
.p-pend { background: transparent; border: 1px dashed var(--line-2); color: var(--ink-2); }

/* Dashboard */
.sample-note { font-size: 11px; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 10px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 10px; }
.kpi { padding: 16px 18px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.kpi p { font-size: 13.5px; color: var(--muted); }
.kpi b { display: block; font-family: var(--font-display); font-stretch: 108%; font-weight: 600; font-size: 34px; line-height: 1.15; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.kpi span { font-size: 12.5px; color: var(--muted); }
.dash-2 { display: grid; grid-template-columns: 1.7fr 1fr; gap: 10px; margin-bottom: 10px; }
.dash-2b { grid-template-columns: 1fr 1.3fr; }
.legend { display: flex; gap: 14px; font-size: 13px; color: var(--ink-2); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.lg-1 { background: var(--l1); }
.lg-2 { background: var(--l2); }

.hchart { position: relative; height: 230px; display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; align-items: end; padding: 0 0 38px; }
.hchart::before { content: ''; position: absolute; inset: 0 0 38px; background: repeating-linear-gradient(to top, transparent 0 calc(25% - 1px), var(--line) calc(25% - 1px) 25%); pointer-events: none; }
.hcol { position: relative; height: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 2px; cursor: default; }
.hcol i { flex: 1; max-width: 16px; border-radius: 4px 4px 0 0; transform-origin: bottom; transition: transform 700ms var(--ease-out), opacity var(--t-fast) ease; }
.hcol .b1 { background: var(--l1); }
.hcol .b2 { background: var(--l2); }
.hcol[data-pre] i { transform: scaleY(.02); }
.hcol > span { position: absolute; bottom: -20px; left: 0; right: 0; text-align: center; font-family: var(--font-mono); font-size: 10px; color: var(--muted); }
.hshift { position: absolute; bottom: 0; height: 14px; border-top: 1px solid var(--line-2); font-family: var(--font-mono); font-size: 10px; color: var(--muted); text-align: center; line-height: 14px; }
.tip { position: absolute; bottom: calc(100% + 8px); left: 50%; z-index: 3; transform: translate(-50%, 4px); opacity: 0; pointer-events: none; white-space: nowrap; padding: 7px 10px; border-radius: 6px; background: var(--ink); color: var(--bg); font-size: 12.5px; line-height: 1.45; transition: opacity 150ms ease, transform 150ms var(--ease-out); }
.tip i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.hcol:nth-child(-n+2) .tip { left: 0; transform: translate(0, 4px); }
.hcol:nth-last-child(-n+4) .tip { left: auto; right: 0; transform: translate(0, 4px); }
@media (hover: hover) and (pointer: fine) {
  .hchart:hover .hcol i { opacity: .45; }
  .hchart .hcol:hover i { opacity: 1; }
  .hcol:hover .tip { opacity: 1; transform: translate(-50%, 0); }
  .hcol:nth-child(-n+2):hover .tip, .hcol:nth-last-child(-n+4):hover .tip { transform: translate(0, 0); }
}
.hcol:focus-visible .tip { opacity: 1; transform: translate(-50%, 0); }
.tbl { margin-top: 12px; font-size: 13.5px; }
.tbl summary { cursor: pointer; color: var(--muted); width: max-content; }
.tbl-wrap { overflow-x: auto; margin-top: 8px; }
.tbl table { border-collapse: collapse; font-size: 13px; min-width: 100%; }
.tbl th, .tbl td { padding: 6px 10px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
.tbl th:first-child, .tbl td:first-child { text-align: left; }
.tbl th { color: var(--muted); font-weight: 500; }

.shifts { display: grid; gap: 14px; }
.shift h3 { font-size: 14px; font-weight: 600; margin-bottom: 6px; display: flex; justify-content: space-between; }
.shift h3 span { font-weight: 400; color: var(--muted); font-size: 12.5px; }
.srow { display: grid; grid-template-columns: 52px 1fr 40px; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.sbar { height: 10px; border-radius: 0 3px 3px 0; background: rgba(236,233,226,.05); overflow: hidden; }
.sbar i { display: block; height: 100%; border-radius: 0 3px 3px 0; transform-origin: left; transform: scaleX(var(--w)); transition: transform 800ms var(--ease-out); }
.sbar[data-pre] i { transform: scaleX(0); }
.srow b { color: var(--ink); font-weight: 500; text-align: right; font-family: var(--font-mono); font-size: 12px; }

.types { display: grid; gap: 12px; }
.types li { display: grid; grid-template-columns: 1fr auto; gap: 5px 10px; font-size: 14.5px; }
.types li .sbar { grid-column: 1 / -1; height: 8px; }
.types .sbar i { background: var(--accent); }
.types b { font-family: var(--font-mono); font-size: 12px; font-weight: 500; }
.types small { color: var(--muted); font-size: 12px; margin-left: 6px; }

.trend { position: relative; }
.trend svg { width: 100%; height: 220px; overflow: visible; }
.trend .grid line { stroke: var(--line); }
.trend .ax text { fill: var(--muted); font-family: var(--font-mono); font-size: 10px; }
.trend path.ln { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.trend .hair { stroke: var(--line-2); }
.trend .dot { stroke: var(--surface); stroke-width: 2; }
.trend .ttip { position: absolute; top: 0; pointer-events: none; padding: 7px 10px; border-radius: 6px; background: var(--ink); color: var(--bg); font-size: 12.5px; line-height: 1.45; white-space: nowrap; opacity: 0; transition: opacity 120ms ease; }
.trend .ttip i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.trend[data-hover] .ttip { opacity: 1; }

/* Training */
.round-box { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 12px; border-color: rgba(255,198,26,.35); }
.round-title { font-family: var(--font-display); font-stretch: 110%; font-weight: 650; font-size: 22px; letter-spacing: -.01em; margin: 4px 0; max-width: none; }
.round-sub { font-size: 14.5px; max-width: 64ch; }
.round-sub b { color: var(--ink); font-weight: 500; }
.train-lines { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tline h2 { font-size: 16px; }
.trows { display: grid; }
.trow { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.trow:first-child { border-top: 0; padding-top: 2px; }
.trow-t { font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.trow-n { grid-column: 1 / -1; display: flex; gap: 16px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.trow-n b { color: var(--ink); font-weight: 500; font-family: var(--font-mono); font-size: 12px; }
.prog { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: rgba(236,233,226,.06); overflow: hidden; }
.prog i { display: block; height: 100%; background: var(--ok); transform-origin: left; transform: scaleX(var(--p)); transition: transform 900ms var(--ease-out); }
.prog.learning i { background: var(--accent); }
.prog[data-pre] i { transform: scaleX(0); }
.p-ready { background: var(--ok-soft); color: var(--ok); }
.p-learn { background: var(--accent-soft); color: var(--accent); }
.trow .btn { height: 30px; padding: 0 10px; font-size: 13px; align-self: start; }
.good-row { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; margin-bottom: 8px; border-radius: 6px; background: var(--bg-2); font-size: 13.5px; color: var(--muted); }
.good-row b { color: var(--ink); font-family: var(--font-mono); font-weight: 500; font-size: 12.5px; }
.train-note { margin-top: 12px; font-size: 13.5px; color: var(--muted); max-width: 80ch; }
.train-note b { color: var(--ink-2); font-weight: 600; }

/* Settings */
.settings { display: grid; gap: 12px; max-width: 860px; }
.radios { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.radio { position: relative; cursor: pointer; }
.radio input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.r-card { display: grid; gap: 4px; height: 100%; padding: 14px; border-radius: 8px; border: 1px solid var(--line-2); font-size: 13.5px; color: var(--muted); transition: border-color var(--t-fast) ease, background-color var(--t-fast) ease; }
.r-card b { color: var(--ink); font-size: 15px; }
.radio input:checked + .r-card { border-color: var(--accent); background: var(--accent-soft); }
.radio input:focus-visible + .r-card { outline: 2px solid var(--accent); outline-offset: 2px; }
.th-val { font-size: 18px; color: var(--accent); }
.range { width: 100%; accent-color: var(--accent); height: 28px; }
.range-ends { display: flex; justify-content: space-between; }
.th-help { margin-top: 10px; font-size: 14px; }
.th-preview { margin-top: 10px; padding: 10px 12px; border-radius: 6px; background: var(--bg-2); font-size: 14px; color: var(--ink-2); }
.set-rows { display: grid; }
.set-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); cursor: pointer; }
.set-row:first-child { border-top: 0; padding-top: 0; }
.set-row > span { display: grid; gap: 2px; font-size: 15px; }
.set-row b { font-weight: 500; }
.set-row select { border: 1px solid var(--line-2); }
.switch { appearance: none; -webkit-appearance: none; flex: none; width: 42px; height: 24px; margin: 0; border-radius: 999px; background: rgba(236,233,226,.14); position: relative; cursor: pointer; transition: background-color var(--t-fast) ease; }
.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--ink); transition: transform var(--t-ui) var(--ease-out); }
.switch:checked { background: var(--accent); }
.switch:checked::after { transform: translateX(18px); background: var(--accent-ink); }
.set-actions { display: flex; gap: 8px; }

.demo-note { margin-top: 28px; display: flex; justify-content: center; align-items: center; gap: 10px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; text-align: center; }

/* Drawer */
.drawer-scrim { position: fixed; inset: 0; z-index: 80; background: rgba(0,0,0,.55); opacity: 0; transition: opacity 280ms ease; }
.drawer-scrim[data-open] { opacity: 1; }
.drawer { position: fixed; z-index: 90; top: 0; right: 0; bottom: 0; width: min(520px, 100%); display: flex; flex-direction: column; background: var(--surface); border-left: 1px solid var(--line-2); box-shadow: -30px 0 80px -30px rgba(0,0,0,.8); transform: translateX(100%); transition: transform 420ms var(--ease-drawer); visibility: hidden; }
.drawer[data-open] { transform: none; visibility: visible; }
.drawer:not([data-open]) { transition: transform 260ms var(--ease-out), visibility 0s 260ms; }
.dr-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.dr-title { font-family: var(--font-display); font-stretch: 110%; font-weight: 650; font-size: 24px; letter-spacing: -.01em; }
.icon-btn { width: 36px; height: 36px; border-radius: 6px; display: grid; place-items: center; color: var(--ink-2); flex: none; transition: background-color var(--t-fast) ease, transform var(--t-press) var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .icon-btn:hover { background: rgba(236,233,226,.06); } }
.icon-btn:active { transform: scale(.97); }
.dr-body { flex: 1; overflow: auto; padding: 18px 20px; display: grid; gap: 18px; align-content: start; }
.dr-imgs { display: grid; grid-template-columns: 1.4fr 1fr; gap: 8px; }
.dr-imgs canvas { width: 100%; aspect-ratio: 1; border-radius: 6px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0; }
.fields div { padding: 10px 12px; border-radius: 6px; border: 1px solid var(--line); }
.fields dt { font-size: 12px; color: var(--muted); }
.fields dd { margin: 2px 0 0; font-size: 14.5px; font-weight: 500; }
.dr-h { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.hist { display: grid; gap: 8px; }
.hist li { position: relative; padding-left: 20px; font-size: 14px; color: var(--ink-2); }
.hist li::before { content: ''; position: absolute; left: 3px; top: 7px; width: 8px; height: 8px; background: var(--accent); }
.hist li span { display: block; font-size: 11px; color: var(--muted); }
.dr-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 14px 20px; border-top: 1px solid var(--line); }
.dr-foot[hidden] { display: none; }

/* Responsive */
@media (max-width: 1240px) {
  .live-grid { grid-template-columns: 1fr 320px; }
  .train-lines { grid-template-columns: 1fr; }
}
@media (max-width: 1100px) {
  .live-grid, .dash-2, .dash-2b { grid-template-columns: 1fr; }
}
@media (max-width: 980px) {
  body.app { grid-template-columns: 1fr; padding-bottom: 76px; }
  .side { position: fixed; z-index: 60; top: auto; bottom: 0; left: 0; right: 0; height: auto; flex-direction: row; padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); border-right: 0; border-top: 1px solid var(--line-2); }
  .side-brand, .side-foot { display: none; }
  .side-nav { grid-auto-flow: column; grid-auto-columns: 1fr; width: 100%; }
  .side-nav a { flex-direction: column; gap: 3px; padding: 7px 2px; font-size: 11.5px; }
  .side-nav a[aria-current='page']::before { left: 25%; right: 25%; top: -7px; bottom: auto; width: auto; height: 3px; }
  .side-badge { position: absolute; top: 2px; right: calc(50% - 24px); min-width: 18px; height: 16px; font-size: 10px; padding: 0 4px; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 680px) {
  .top-title { font-size: 30px; }
  .top-actions, .seg { width: 100%; }
  .seg button { flex: 1; padding: 8px 6px; font-size: 13.5px; }
  .seg button span { display: none; }
  canvas.app-feed { height: 250px; }
  .feed-stats { grid-template-columns: repeat(2, 1fr); }
  .feed-stats div:nth-child(2) { border-right: 0; }
  .feed-stats div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .feed-stats dd { font-size: 17px; }
  .radios { grid-template-columns: 1fr; }
  .kpi b { font-size: 28px; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .g-img canvas { height: 120px; }
  .g-body { padding: 8px 10px 10px; }
  .g-t { font-size: 14px; }
  .g .q-act { flex-direction: column; }
  .hchart { gap: 3px; }
  .hcol > span { font-size: 9px; }
  .fields { grid-template-columns: 1fr; }
  .filters, .selects, .sel { width: 100%; }
  .sel select { flex: 1; min-width: 0; }
  .demo-bar { font-size: 10px; letter-spacing: .02em; }
}
.seg[hidden] { display: none; }
@media (max-width: 980px) { .toasts { bottom: calc(84px + env(safe-area-inset-bottom)); left: 12px; right: 12px; } .toast { max-width: none; } }
.trend:not([data-hover]) .dot, .trend:not([data-hover]) .hair { opacity: 0; }
