/* =========================================================================
   BDO Grind Tracker — design system
   Obsidian base, ember + violet accents (Zephyros lava / Primordial pigment).
   Hand-written: no build step, so deploying to shared hosting is a file copy.
   ========================================================================= */

:root {
    /* Surfaces, darkest to lightest */
    --bg:            #0a0c11;
    --surface:       #11141c;
    --surface-2:     #171b25;
    --surface-3:     #1e2330;
    --border:        #262c3a;
    --border-soft:   #1c212c;

    /* Text */
    --text:          #e7eaf2;
    --text-muted:    #939bb0;
    --text-dim:      #626b81;

    /* Accents */
    --ember:         #ff7a33;
    --ember-dim:     #c2531a;
    --ember-glow:    rgba(255, 122, 51, 0.14);
    --violet:        #a882ff;
    --violet-glow:   rgba(168, 130, 255, 0.14);
    --gold:          #f0c04a;

    /* Semantics */
    --positive:      #38d996;
    --negative:      #ff5f75;
    --warning:       #f2b544;
    --info:          #56b6f0;

    /* Tier colours, used consistently across every comparison surface */
    --tier-casual:   #7b8398;
    --tier-high:     #56b6f0;
    --tier-top:      #a882ff;
    --tier-you:      #ff7a33;
    --tier-community:#38d996;

    --radius:        10px;
    --radius-sm:     6px;
    --radius-lg:     16px;

    --shadow:        0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.7);
    --shadow-lg:     0 24px 60px -20px rgba(0,0,0,.85);

    --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    --mono: "JetBrains Mono", "Cascadia Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

    --header-h: 58px;
    --sidebar-w: 232px;
}

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

html, body { height: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 14px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* A quiet ember bloom behind the page so flat dark does not read as dead. */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(900px 500px at 12% -8%, rgba(255,122,51,.055), transparent 60%),
        radial-gradient(760px 460px at 88% 4%, rgba(168,130,255,.05), transparent 62%);
    z-index: 0;
}

h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.011em; line-height: 1.25; }
h1 { font-size: 22px; }
h2 { font-size: 16px; }
h3 { font-size: 14px; }

p { margin: 0 0 12px; }
p:last-child { margin-bottom: 0; }

a { color: var(--ember); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }

hr { border: 0; border-top: 1px solid var(--border-soft); margin: 20px 0; }

/* Every number in the app aligns in its column. */
.num, td.num, th.num, .stat-value, input[type="number"] {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1;
}

.mono { font-family: var(--mono); }

/* =========================================================================
   Layout shell
   ========================================================================= */

.shell { position: relative; z-index: 1; min-height: 100%; }

.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    height: var(--header-h);
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 20px;
    background: rgba(10, 12, 17, 0.86);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-soft);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 650;
    font-size: 15px;
    color: var(--text);
    letter-spacing: -0.02em;
    white-space: nowrap;
}
.brand:hover { text-decoration: none; }

.brand-mark {
    width: 26px; height: 26px;
    display: grid; place-items: center;
    border-radius: 7px;
    background: linear-gradient(150deg, var(--ember), #d0431a 70%);
    box-shadow: 0 0 0 1px rgba(255,122,51,.3), 0 4px 14px -4px rgba(255,122,51,.55);
    font-size: 13px;
    color: #1a0800;
    font-weight: 800;
}

.topbar-spacer { flex: 1; }

.topbar-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 12.5px;
    color: var(--text-muted);
}

.ap-chip {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 4px 10px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface-2);
    font-variant-numeric: tabular-nums;
    font-size: 12px;
    white-space: nowrap;
}
.ap-chip strong { color: var(--text); font-weight: 600; }
.ap-chip .sep { color: var(--text-dim); }

.layout {
    display: grid;
    grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
    align-items: start;
}

.sidebar {
    position: sticky;
    top: var(--header-h);
    height: calc(100vh - var(--header-h));
    overflow-y: auto;
    padding: 18px 12px 32px;
    border-right: 1px solid var(--border-soft);
}

.nav-group + .nav-group { margin-top: 20px; }

.nav-label {
    padding: 0 10px 7px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: var(--text-dim);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 10px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 13.5px;
    font-weight: 500;
    transition: background .12s ease, color .12s ease;
}
.nav-item:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.nav-item.is-active {
    background: linear-gradient(90deg, var(--ember-glow), transparent 85%);
    color: var(--text);
    box-shadow: inset 2px 0 0 var(--ember);
}
.nav-item .nav-icon { width: 16px; text-align: center; opacity: .8; font-size: 13px; }
.nav-item .nav-badge {
    margin-left: auto;
    min-width: 18px;
    padding: 1px 6px;
    border-radius: 999px;
    background: var(--ember);
    color: #180700;
    font-size: 10.5px;
    font-weight: 700;
    text-align: center;
}

.main { padding: 24px 28px 72px; min-width: 0; }

.page-head {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.page-head .page-title-group { min-width: 0; }
.page-head .page-sub { color: var(--text-muted); font-size: 13px; margin-top: 3px; }
.page-head .page-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

/* =========================================================================
   Cards, panels, grids
   ========================================================================= */

.card {
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border-soft);
}
.card-head h2 { font-size: 13.5px; }
.card-head .card-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.card-head .card-hint { margin-left: auto; font-size: 12px; color: var(--text-dim); }

.card-body { padding: 16px; }
.card-body.tight { padding: 0; }

.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.sidebar-right { grid-template-columns: minmax(0, 1fr) 320px; }

/* =========================================================================
   Stat tiles
   ========================================================================= */

.stat {
    position: relative;
    padding: 14px 16px 15px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius);
    overflow: hidden;
}
.stat::after {
    content: "";
    position: absolute; left: 0; top: 0; bottom: 0;
    width: 2px;
    background: var(--accent, var(--border));
    opacity: .85;
}
.stat.accent-ember  { --accent: var(--ember); }
.stat.accent-violet { --accent: var(--violet); }
.stat.accent-gold   { --accent: var(--gold); }
.stat.accent-green  { --accent: var(--positive); }

.stat-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--text-dim);
}
.stat-value {
    margin-top: 5px;
    font-size: 25px;
    font-weight: 660;
    letter-spacing: -0.025em;
    line-height: 1.1;
}
.stat-value .unit { font-size: 15px; color: var(--text-muted); font-weight: 500; margin-left: 1px; }
.stat-foot { margin-top: 5px; font-size: 12px; color: var(--text-muted); }

/* =========================================================================
   Tables
   ========================================================================= */

.table-wrap { overflow-x: auto; }

table.data {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 13px;
}

table.data th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--surface-2);
    padding: 9px 12px;
    text-align: left;
    font-size: 11px;
    font-weight: 650;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--text-dim);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
table.data th.num, table.data td.num { text-align: right; }
table.data th a { color: inherit; }
table.data th a:hover { color: var(--text); }

table.data td {
    padding: 9px 12px;
    border-bottom: 1px solid var(--border-soft);
    vertical-align: middle;
}
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr { transition: background .1s ease; }
table.data tbody tr:hover { background: var(--surface-2); }
table.data tbody tr.is-highlight { background: linear-gradient(90deg, var(--ember-glow), transparent 70%); }
table.data tbody tr.is-muted td { color: var(--text-dim); }

table.data td.item-name { font-weight: 500; }
table.data .row-sub { display: block; font-size: 11.5px; color: var(--text-dim); }

table.compact td, table.compact th { padding: 6px 10px; }

.empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-dim);
}
.empty .empty-title { color: var(--text-muted); font-weight: 550; margin-bottom: 4px; }

/* =========================================================================
   Badges, pills, tags
   ========================================================================= */

.badge {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
    border: 1px solid transparent;
    white-space: nowrap;
}
.badge--ember    { background: var(--ember-glow);  color: #ffa877; border-color: rgba(255,122,51,.28); }
.badge--violet   { background: var(--violet-glow); color: #c4aaff; border-color: rgba(168,130,255,.28); }
.badge--green    { background: rgba(56,217,150,.12); color: #6fe7b8; border-color: rgba(56,217,150,.26); }
.badge--red      { background: rgba(255,95,117,.12); color: #ff8b9c; border-color: rgba(255,95,117,.26); }
.badge--amber    { background: rgba(242,181,68,.12); color: #f5cd7c; border-color: rgba(242,181,68,.26); }
.badge--blue     { background: rgba(86,182,240,.12); color: #8ccdf5; border-color: rgba(86,182,240,.26); }
.badge--neutral  { background: var(--surface-3); color: var(--text-muted); border-color: var(--border); }

.badge--dot::before {
    content: "";
    width: 5px; height: 5px; border-radius: 50%;
    background: currentColor;
}

.tag-row { display: flex; flex-wrap: wrap; gap: 5px; }

.delta { font-variant-numeric: tabular-nums; font-weight: 600; font-size: 12.5px; }
.delta--up   { color: var(--positive); }
.delta--down { color: var(--negative); }
.delta--flat { color: var(--text-muted); }
.delta--none { color: var(--text-dim); }

.silver { color: var(--gold); font-variant-numeric: tabular-nums; font-weight: 550; }
.silver-dim { color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* Marks a value derived from an estimated price rather than a real snapshot. */
.estimated {
    border-bottom: 1px dashed var(--warning);
    cursor: help;
}

/* =========================================================================
   Forms
   ========================================================================= */

.field { margin-bottom: 14px; }
.field:last-child { margin-bottom: 0; }

label, .label {
    display: block;
    margin-bottom: 5px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
}
.label-hint { font-weight: 400; color: var(--text-dim); }

input[type="text"], input[type="email"], input[type="password"], input[type="number"],
input[type="date"], input[type="time"], input[type="search"], select, textarea {
    width: 100%;
    padding: 8px 11px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 13.5px;
    transition: border-color .12s ease, box-shadow .12s ease, background .12s ease;
    appearance: none;
}
textarea { min-height: 76px; resize: vertical; line-height: 1.5; }

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--ember-dim);
    background: var(--surface-3);
    box-shadow: 0 0 0 3px var(--ember-glow);
}

input::placeholder, textarea::placeholder { color: var(--text-dim); }

input:disabled, select:disabled, textarea:disabled {
    opacity: .55;
    cursor: not-allowed;
}

select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23939bb0' stroke-width='2.2' stroke-linecap='round'%3e%3cpath d='M6 9l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 9px center;
    background-size: 15px;
    padding-right: 30px;
}

.checkbox {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 0;
}
.checkbox input[type="checkbox"] {
    width: 16px; height: 16px;
    margin: 0;
    accent-color: var(--ember);
    cursor: pointer;
}

.field-row { display: flex; gap: 12px; flex-wrap: wrap; }
.field-row > .field { flex: 1 1 150px; margin-bottom: 0; }

.help { margin-top: 5px; font-size: 12px; color: var(--text-dim); line-height: 1.45; }

fieldset { border: 0; padding: 0; margin: 0; }

/* =========================================================================
   Buttons
   ========================================================================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface-2);
    color: var(--text);
    font-family: inherit;
    font-size: 13px;
    font-weight: 550;
    line-height: 1.2;
    cursor: pointer;
    white-space: nowrap;
    transition: background .12s ease, border-color .12s ease, transform .06s ease;
}
.btn:hover { background: var(--surface-3); border-color: #333a4b; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--ember-glow); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.btn--primary {
    background: linear-gradient(160deg, var(--ember), #dd5a1f);
    border-color: transparent;
    color: #1a0800;
    font-weight: 650;
    box-shadow: 0 4px 16px -6px rgba(255,122,51,.6);
}
.btn--primary:hover { background: linear-gradient(160deg, #ff8b4a, #e8632a); border-color: transparent; }

.btn--ghost { background: transparent; border-color: transparent; color: var(--text-muted); }
.btn--ghost:hover { background: var(--surface-2); color: var(--text); }

.btn--danger { border-color: rgba(255,95,117,.35); color: #ff8b9c; background: rgba(255,95,117,.08); }
.btn--danger:hover { background: rgba(255,95,117,.16); border-color: rgba(255,95,117,.5); }

.btn--sm { padding: 5px 10px; font-size: 12px; }
.btn--block { width: 100%; }

.btn-group { display: inline-flex; }
.btn-group .btn { border-radius: 0; margin-left: -1px; }
.btn-group .btn:first-child { border-radius: var(--radius-sm) 0 0 var(--radius-sm); margin-left: 0; }
.btn-group .btn:last-child { border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.btn-group .btn.is-active { background: var(--surface-3); color: var(--text); border-color: var(--ember-dim); z-index: 1; }

/* =========================================================================
   Segmented control (price basis, scope switchers)
   ========================================================================= */

.segmented {
    display: inline-flex;
    padding: 3px;
    gap: 2px;
    background: var(--surface-2);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
}
.segmented a, .segmented button {
    padding: 4px 11px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-size: 12.5px;
    font-weight: 550;
    cursor: pointer;
}
.segmented a:hover, .segmented button:hover { color: var(--text); text-decoration: none; }
.segmented .is-active { background: var(--surface-3); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.35); }

/* =========================================================================
   Spot picker
   ========================================================================= */

.pick-group + .pick-group { margin-top: 18px; }

.pick-group-head {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 8px;
}

.spot-pick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 8px;
}

.spot-pick {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 9px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface-2);
    color: var(--text);
    transition: background .12s ease, border-color .12s ease, transform .06s ease;
}
.spot-pick:hover {
    background: var(--surface-3);
    border-color: var(--ember-dim);
    text-decoration: none;
    transform: translateY(-1px);
}
.spot-pick.is-current {
    border-color: var(--ember);
    background: var(--ember-glow);
}

.spot-pick-name { font-size: 13.5px; font-weight: 550; line-height: 1.3; }
.spot-pick-meta { font-size: 11.5px; color: var(--text-dim); font-variant-numeric: tabular-nums; }

.pick-more > summary {
    cursor: pointer;
    padding: 8px 0;
    font-size: 13px;
    color: var(--text-muted);
    user-select: none;
}
.pick-more > summary:hover { color: var(--text); }
.pick-more[open] > summary { color: var(--text); margin-bottom: 4px; }

/* =========================================================================
   Flash messages
   ========================================================================= */

.flashes { display: grid; gap: 8px; margin-bottom: 18px; }

.flash {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface-2);
    font-size: 13px;
}
.flash--success { border-color: rgba(56,217,150,.3);  background: rgba(56,217,150,.08);  color: #8fecc4; }
.flash--error   { border-color: rgba(255,95,117,.32); background: rgba(255,95,117,.08); color: #ffa3b0; }
.flash--warning { border-color: rgba(242,181,68,.3);  background: rgba(242,181,68,.08);  color: #f7d795; }
.flash--info    { border-color: rgba(86,182,240,.3);  background: rgba(86,182,240,.08);  color: #a5d9f7; }

/* =========================================================================
   Auth pages
   ========================================================================= */

.auth-wrap {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 40px 20px;
}

.auth-card {
    width: 100%;
    max-width: 400px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 30px 28px 26px;
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 22px;
}
.auth-brand .brand-mark { width: 32px; height: 32px; border-radius: 9px; font-size: 15px; }
.auth-brand .auth-brand-text { font-size: 16px; font-weight: 650; letter-spacing: -0.02em; }
.auth-brand .auth-brand-sub { font-size: 12px; color: var(--text-dim); }

.auth-card h1 { font-size: 19px; margin-bottom: 5px; }
.auth-lede { color: var(--text-muted); font-size: 13px; margin-bottom: 20px; }

.auth-foot {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border-soft);
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
}

.notice {
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface-2);
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.55;
}
.notice--ember { border-color: rgba(255,122,51,.28); background: var(--ember-glow); color: #ffbd96; }

/* =========================================================================
   Misc utilities
   ========================================================================= */

.muted { color: var(--text-muted); }
.dim   { color: var(--text-dim); }
.small { font-size: 12px; }
.tiny  { font-size: 11px; }
.strong { font-weight: 650; }
.right { text-align: right; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.stack   { display: grid; gap: 16px; }
.stack-sm{ display: grid; gap: 8px; }
.row     { display: flex; align-items: center; gap: 10px; }
.row-wrap{ display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.spacer  { flex: 1; }

.mt-0 { margin-top: 0; }
.mt-8 { margin-top: 8px; }
.mt-16{ margin-top: 16px; }
.mt-24{ margin-top: 24px; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-16{ margin-bottom: 16px; }

/* Thin horizontal bar used to compare a value against a baseline inline. */
.meter {
    position: relative;
    height: 5px;
    border-radius: 3px;
    background: var(--surface-3);
    overflow: hidden;
    min-width: 60px;
}
.meter > span {
    position: absolute;
    inset: 0 auto 0 0;
    border-radius: 3px;
    background: var(--ember);
}
.meter.is-over > span { background: var(--positive); }
.meter.is-under > span { background: var(--negative); }

/* Scrollbars — the default light ones are jarring on this palette. */
* { scrollbar-width: thin; scrollbar-color: #2c3342 transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: #2c3342; border-radius: 6px; border: 2px solid var(--bg); }
*::-webkit-scrollbar-thumb:hover { background: #3a4256; }

/* =========================================================================
   Responsive
   ========================================================================= */

@media (max-width: 1100px) {
    .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .grid.sidebar-right { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 860px) {
    .layout { grid-template-columns: 1fr; }
    .sidebar {
        position: static;
        height: auto;
        border-right: 0;
        border-bottom: 1px solid var(--border-soft);
        padding: 12px;
        display: flex;
        gap: 6px;
        overflow-x: auto;
    }
    .nav-group { display: flex; gap: 6px; }
    .nav-group + .nav-group { margin-top: 0; }
    .nav-label { display: none; }
    .nav-item { white-space: nowrap; }
    .main { padding: 18px 16px 60px; }
    .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
    .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: minmax(0, 1fr); }
    .topbar-meta .ap-chip { display: none; }
    .stat-value { font-size: 21px; }
}

@media print {
    .sidebar, .topbar, .page-actions { display: none; }
    body { background: #fff; color: #000; }
}
