/* The design system's palette, type and metrics live in docs/design and are
   copied into wwwroot at build. Order matters: Bootstrap (linked from
   App.razor) → tokens → overrides → the rules in this file. */
@import url("fairkey-tokens.css");
@import url("fairkey-overrides.css");

:root {
    --navy: var(--fk-blue-deep);
    --teal: var(--fk-teal);
    --teal-600: var(--fk-teal-dark);
    --gold: var(--fk-teal);               /* the old gold has no successor */
    --maroon: var(--fk-ink-soft);
    --bg: var(--fk-ground);
    --surface: var(--fk-surface);
    --border: var(--fk-rule);
    --text: var(--fk-ink);
    --muted: var(--fk-muted);
    --ok: var(--fk-teal-dark);
    --watch: var(--fk-warn-ink);
    --warn: var(--fk-warn-ink);
    --bad: var(--fk-danger-ink);
    --shadow: var(--fk-shadow);
    --radius: 0;
    --fk-ink-900: var(--fk-ink);
    --fk-slate-700: var(--fk-blue-deep);
    --fk-slate-500: var(--fk-blue-gray);
    --fk-slate-400: var(--fk-muted);
    --fk-slate-300: var(--fk-muted-light);
    --fk-slate-100: var(--fk-rule);
    --fk-slate-050: var(--fk-surface-sunken);
    --fk-paper: var(--fk-ground);
    --fk-white: var(--fk-surface);
    --fk-teal-500: var(--fk-teal);
    --fk-teal-700: var(--fk-teal-dark);
    --fk-teal-050: var(--fk-teal-wash);
    --fk-signal-good: var(--fk-teal-dark);
    --fk-signal-good-tint: var(--fk-teal-pale);
    --fk-signal-attention: var(--fk-warn-ink);
    --fk-signal-attention-tint: var(--fk-warn-bg);
    --fk-signal-overdue: var(--fk-danger-ink);
    --fk-signal-overdue-tint: var(--fk-danger-bg);
    --fk-serif: var(--fk-font-display);
    --fk-sans: var(--fk-font-ui);
    --fk-rule-band: 2px solid var(--fk-rule-strong);
    --fk-rule-active: 3px solid var(--fk-teal);
    --fk-space-12: var(--fk-space-8);
    --fk-space-16: 64px;
    --fk-space-24: 96px;
}

/* Rents and ledger figures: display serif, tabular, so columns line up. */
.fk-figure { font-family: var(--fk-font-display); font-weight: 500; font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; }

*, *::before, *::after { box-sizing: border-box; }

html, body {
    margin: 0;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { color: var(--navy); margin: 0; letter-spacing: -.01em; }

/* ---------- Shell ---------- */
.app-shell { display: flex; min-height: 100vh; }

.sidebar {
    width: 236px;
    flex: 0 0 236px;
    background: var(--fk-teal);
    color: var(--fk-slate-100);
    padding: 1.1rem .75rem 2rem;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.brand { display: flex; align-items: center; gap: .6rem; padding: 0 .5rem 1.25rem; }
.brand-logo { width: 36px; height: 36px; flex: none; }
.brand-text strong { display: block; color: #fff; font-size: .95rem; }
.brand-text small { color: var(--fk-slate-300); font-size: .72rem; }

.nav-groups { display: flex; flex-direction: column; gap: 1px; }
.nav-group-label {
    margin: 1rem .6rem .3rem;
    font-size: .66rem; font-weight: 700; letter-spacing: .12em;
    text-transform: uppercase; color: #A8CFCD;
}
.nav-item {
    display: flex; align-items: center; gap: .55rem;
    padding: .45rem .6rem; border-radius: 0;
    color: var(--fk-slate-100); font-size: .85rem;
}
.nav-item:hover { background: rgba(255,255,255,.07); text-decoration: none; color: #fff; }
.nav-item.active { background: #0E5352; border-left: 3px solid var(--fk-cream); color: #fff; font-weight: 600; }
.nav-item .nav-ico { width: 18px; height: 18px; flex: none; opacity: .85; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

/* Phone/tablet drawer pieces (MainLayout); the ≤900px block shows them. */
.fk-hamburger, .fk-drawer-head, .fk-drawer-backdrop { display: none; }

.topbar {
    display: flex; align-items: center; justify-content: space-between;
    height: 52px; padding: 0 1.5rem;
    background: var(--surface); border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 10;
}
.topbar-title { font-weight: 700; color: var(--navy); letter-spacing: .02em; }

.sync-pill {
    display: inline-flex; align-items: center; gap: .45rem;
    padding: .28rem .7rem; border-radius: 0;
    background: var(--fk-teal-050); color: var(--teal-600);
    font-size: .76rem; font-weight: 600;
}
.sync-pill-warn { background: var(--fk-signal-attention-tint); color: var(--warn); }
.sync-dot { width: 7px; height: 7px; border-radius: 0; background: var(--ok); }

/* Breadcrumb + sync strip under the topbar. */
.fk-crumbs { display: flex; align-items: center; gap: 10px; padding-top: 10px; padding-bottom: 10px; padding-inline: 1.5rem; border-bottom: 1px solid var(--fk-rule); }
.fk-crumbs-sep { color: var(--fk-muted-light); }
.fk-crumbs-sync { margin-left: auto; font-size: var(--fk-size-small); color: var(--fk-muted-light); }

.content { padding: 1.5rem; max-width: 1500px; width: 100%; }

/* ---------- Page header ---------- */
.page-header {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 1rem; margin-bottom: 1.25rem;
}
.page-header h1 { font-size: 1.5rem; }
.page-subtitle { margin: .3rem 0 0; color: var(--muted); }
.page-actions { display: flex; gap: .5rem; }

.btn {
    display: inline-flex; align-items: center; padding: .4rem .85rem;
    border: 1px solid var(--border); border-radius: 0;
    background: var(--surface); color: var(--navy); font-weight: 600; font-size: .82rem;
}
.btn:hover { border-color: var(--teal); text-decoration: none; }

/* ---------- Stats ---------- */
.stat-grid {
    display: grid; gap: .75rem; margin-bottom: 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(178px, 1fr));
}
/* A card is drawn with a rule, not lifted with a shadow. The tone rides on
   the left edge at the system's active-rule weight. */
.stat-card {
    background: var(--fk-white); border: var(--fk-rule);
    border-left: 3px solid var(--fk-slate-300);
    border-radius: 0; padding: var(--fk-space-3) var(--fk-space-4);
}
.stat-label {
    font-family: var(--fk-sans); font-size: .6875rem; font-weight: 700;
    letter-spacing: .16em; text-transform: uppercase; color: var(--fk-slate-400);
}
/* The figure is the one place a serif is allowed at operational size, set
   tabular so a column of them lines up. */
.stat-value {
    font-family: var(--fk-serif); font-size: 1.875rem; font-weight: 500;
    color: var(--fk-ink-900); line-height: 1.1; margin-top: var(--fk-space-1);
    font-variant-numeric: tabular-nums;
}
.stat-caption { font-size: .8125rem; color: var(--fk-slate-400); margin-top: var(--fk-space-1); }

/* ---------- Panels ---------- */
.panel {
    border: 1px solid var(--fk-border-card); background: var(--fk-surface);
    padding: 1rem 1.1rem; margin-bottom: 1.25rem;
}
.panel-head {
    display: flex; align-items: center; justify-content: space-between;
    border-bottom: 1px solid var(--fk-rule);
    font-size: var(--fk-size-label); letter-spacing: var(--fk-track-label);
    text-transform: uppercase; color: var(--fk-blue-deep);
    padding: 12px 18px;
}
/* The head's own 11px label size governs; the h2 does not out-size it. */
.panel-head h2 { font-size: inherit; }
.panel-head a { font-size: .8rem; font-weight: 600; }
.panel-note { margin: .7rem 0 0; font-size: .78rem; color: var(--muted); }
.panel-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); }

/* ---------- Tables ---------- */
.grid {
    width: 100%; border-collapse: collapse; background: var(--surface);
    border: 1px solid var(--border); border-radius: 0;
    overflow: hidden; box-shadow: var(--shadow); margin-bottom: 1.25rem;
}
.panel .grid { border: 0; box-shadow: none; margin-bottom: 0; }

.grid th, .grid td { padding: .5rem .7rem; text-align: left; border-bottom: 1px solid var(--border); }
.grid thead th {
    background: var(--fk-slate-050); color: var(--navy);
    font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
    white-space: nowrap;
}
.grid tbody tr:hover { background: var(--fk-teal-050); }
.grid tbody tr:last-child td { border-bottom: 0; }
.grid tfoot th {
    background: var(--fk-slate-050); color: var(--navy); font-weight: 750;
    border-top: 2px solid var(--border); border-bottom: 0;
}
.grid.compact th, .grid.compact td { padding: .38rem .6rem; font-size: .83rem; }
/* A table wider than the screen scrolls inside this box, not the whole page (same rule as lease app.css). */
.table-responsive { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; margin-bottom: 1.25rem; }
.table-responsive > .grid { margin-bottom: 0; }
.panel .table-responsive { margin-bottom: 0; } /* as .panel .grid above */

.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.strong { font-weight: 700; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; }
.pos { color: var(--ok); }
.neg { color: var(--bad); }
.row-vacant { background: var(--fk-signal-attention-tint); }

/* ---------- Chips ---------- */
.chip {
    display: inline-block; font-weight: 700; white-space: nowrap;
    border: 1px solid var(--fk-rule); background: var(--fk-surface-sunken);
    color: var(--fk-ink-soft); font-size: var(--fk-size-small); padding: 3px 8px;
}
.chip-ok    { background: var(--fk-signal-good-tint); color: var(--ok); }
.chip-info  { background: var(--fk-teal-050); color: var(--teal-600); }
.chip-watch { background: var(--fk-signal-attention-tint); color: var(--watch); }
.chip-warn  { background: var(--fk-signal-attention-tint); color: var(--warn); }
.chip-bad   { background: var(--fk-signal-overdue-tint); color: var(--bad); }
.chip-worst { background: var(--bad); color: #fff; }
.chip-muted { background: var(--fk-slate-050); color: var(--muted); }

/* ---------- Ageing bars ---------- */
.aging { display: flex; flex-direction: column; gap: .4rem; }
.aging-row { display: grid; grid-template-columns: 62px 1fr 92px; align-items: center; gap: .6rem; }
.aging-label { font-size: .76rem; font-weight: 600; color: var(--muted); }
.aging-track { height: 16px; background: var(--fk-slate-050); border-radius: 0; overflow: hidden; }
.aging-fill { height: 100%; border-radius: 0; min-width: 2px; transition: width .3s ease; }
.aging-amount { text-align: right; font-size: .82rem; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ---------- Toolbar ---------- */
.toolbar {
    display: flex; gap: 10px; align-items: center;
    padding: 10px 0; border-bottom: 1px solid var(--fk-rule);
    flex-wrap: wrap;
}
.search {
    flex: 1 1 260px; max-width: 400px; padding: .42rem .7rem;
    border: 1px solid var(--border); border-radius: 0; font: inherit; background: var(--surface);
}
.search:focus { outline: 0; border-color: var(--teal); box-shadow: none; }
.check { display: inline-flex; align-items: center; gap: .35rem; font-size: .82rem; color: var(--muted); }
.toolbar-count { margin-left: auto; font-size: .78rem; color: var(--muted); }

.loading, .empty { padding: 2rem; text-align: center; color: var(--muted); }

#blazor-error-ui {
    display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
    padding: .7rem 1.25rem; background: var(--fk-signal-overdue-tint); color: var(--bad); box-shadow: none;
}

@media (max-width: 900px) {
    .app-shell { flex-direction: column; }
    /* The shared overrides hide .sidebar outright in favor of .fk-tabbar; the
       hub keeps the brand row visible above the tab bar and only drops the
       nav links, so override display back on and hide just .nav-groups. */
    .sidebar { display: block; width: 100%; flex: none; height: auto; position: static; }
    /* The nav links become a left side drawer, opened by the topbar
       hamburger (js/nav-drawer.js toggles .nav-open on .app-shell).
       visibility: hidden keeps the closed drawer's links out of the tab order. */
    .nav-groups {
        position: fixed; top: 0; bottom: 0; left: 0; z-index: 60;
        width: min(300px, 85vw);
        padding: 0 .75rem calc(1.5rem + env(safe-area-inset-bottom, 0px));
        background: var(--fk-teal);
        overflow-y: auto; overscroll-behavior: contain;
        transform: translateX(-100%); visibility: hidden;
        transition: transform .2s ease, visibility 0s linear .2s;
    }
    .app-shell.nav-open .nav-groups {
        transform: none; visibility: visible;
        transition: transform .2s ease;
        box-shadow: 4px 0 24px rgba(0,0,0,.25);
    }
    .fk-drawer-head {
        display: flex; align-items: center; justify-content: space-between;
        position: sticky; top: 0; z-index: 1;
        margin: 0 -.75rem .25rem; padding: .5rem .5rem .5rem 1.35rem;
        background: var(--fk-teal); border-bottom: 1px solid rgba(255,255,255,.12);
    }
    .fk-drawer-title { color: #fff; font-weight: 700; font-size: .95rem; }
    .fk-drawer-close {
        display: grid; place-items: center; width: 44px; height: 44px;
        border: 0; background: transparent; color: #fff; cursor: pointer;
    }
    .nav-groups .nav-item { min-height: 44px; }
    .fk-drawer-backdrop {
        display: block; position: fixed; inset: 0; z-index: 55;
        background: rgba(0,0,0,.45);
        opacity: 0; pointer-events: none; transition: opacity .2s ease;
    }
    .app-shell.nav-open .fk-drawer-backdrop { opacity: 1; pointer-events: auto; }
    body:has(.app-shell.nav-open) { overflow: hidden; }
    .fk-hamburger {
        display: grid; place-items: center; flex: none;
        width: 44px; height: 44px; margin-left: -.75rem; margin-right: .25rem;
        border: 0; background: transparent; color: var(--navy); cursor: pointer;
    }
    .topbar { justify-content: flex-start; }
    .topbar-meta { margin-left: auto; }
    /* minmax(0, 1fr): a plain 1fr track grows to its widest table; the table scrolls in its own box instead. */
    .panel-grid { grid-template-columns: minmax(0, 1fr); }
    .panel-grid > * { min-width: 0; }
    /* Keeps the last row of page content clear of the fixed .fk-tabbar. */
    .content { padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- Auth ---------- */
.user-chip {
    display: inline-flex; align-items: center; gap: .45rem;
    padding: .22rem .6rem .22rem .25rem; border-radius: 0;
    background: var(--fk-teal-050); color: var(--teal-600);
    font-size: .76rem; font-weight: 600; max-width: 260px;
}
.user-avatar {
    display: grid; place-items: center; flex: 0 0 auto;
    width: 22px; height: 22px; border-radius: 0;
    background: var(--teal); color: #fff; font-size: .7rem; font-weight: 700;
}
.user-email { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.signout-link { font-size: .76rem; font-weight: 600; color: var(--muted); }
.signout-link:hover { color: var(--maroon); }

.topbar-meta { display: flex; align-items: center; gap: .75rem; }

.auth-card {
    max-width: 460px; margin: 4rem auto; padding: 2.25rem 2rem;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 0; box-shadow: var(--shadow); text-align: center;
}
.auth-icon { font-size: 2.25rem; line-height: 1; margin-bottom: .75rem; }
.auth-card h1 { font-size: 1.35rem; margin-bottom: .6rem; }
.auth-card p { color: var(--muted); margin: 0 0 1.35rem; }
.btn-primary {
    background: var(--teal); border-color: var(--teal); color: #fff;
}
.btn-primary:hover { background: var(--teal-600); border-color: var(--teal-600); color: #fff; }

@media (max-width: 900px) {
    .user-email { display: none; }
}

/* ---------- Admin editing grids ---------- */
.admin-note { margin-bottom: 1.25rem; }
.admin-note p { margin: 0; font-size: .88rem; }
.cell-input {
    width: 100%; min-width: 6rem; font: inherit;
    border: 1px solid var(--fk-border-input); padding: 6px 8px;
    background: var(--fk-surface);
}
.cell-input:focus { outline: 0; border-color: var(--teal); }
.cell-input.num { text-align: right; }
.row-actions { display: flex; gap: .35rem; white-space: nowrap; }

/* ---------- Water rates ---------- */
.water-rates .rates-subhead { margin: 1rem 0 .5rem; font-size: .95rem; }
.water-rates .tariff-list .chip { margin: 0 .2rem .2rem 0; }
/* Blocks and meter charges side by side, stacking on narrow screens. */
/* align-items: start, or the three block rows stretch to the eleven meter rows' height. */
.water-rates .rates-editors { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); align-items: start; margin-bottom: .6rem; }

/* ---------- Water sparkline ---------- */
.spark {
    display: flex; align-items: flex-end; gap: 2px;
    height: 140px; padding: .5rem .25rem 0;
    background: linear-gradient(to top, var(--fk-teal-050) 0 1px, transparent 1px);
}
.spark-bar { flex: 1 1 0; min-width: 2px; border-radius: 0; background: var(--teal); }
.spark-bar:hover { filter: brightness(1.25); }
.spark-axis {
    display: flex; justify-content: space-between;
    margin-top: .3rem; font-size: .74rem; color: var(--muted);
}
.muted-row td { opacity: .55; }

/* ---------- Staff help page ---------- */
.help-topic { margin-bottom: 1.1rem; }
.help-route { font-size: .75rem; background: var(--bg); border: 1px solid var(--border); border-radius: 0; padding: .1rem .45rem; margin-left: .4rem; color: var(--teal-600); }
.help-summary { margin: 0 0 .55rem; color: var(--text); }
.help-functions { margin: 0; padding-left: 1.2rem; color: var(--text); }
.help-functions li { margin-bottom: .25rem; font-size: .88rem; }
.help-undocumented { border-left: 4px solid var(--watch); }
/* Long route lists wrap under the title instead of pushing the page wide. */
.help-topic .panel-head { flex-wrap: wrap; gap: .4rem; }
.help-topic .panel-head > span { display: flex; flex-wrap: wrap; gap: .3rem; min-width: 0; }
.help-route { overflow-wrap: anywhere; }

/* ---------- Print (itemized statements) ----------
   Staff print deposit settlements and tenant statements straight from the
   page, so drop the app chrome and anything marked .no-print and let the
   panels flow as plain paper. */
@media print {
    .sidebar, .topbar, #blazor-error-ui, .no-print { display: none !important; }
    .app-shell { display: block; }
    .main, .content { display: block; margin: 0; padding: 0; overflow: visible; }
    body { background: #fff; color: #000; }
    .panel { border: 0; box-shadow: none; padding: 0; margin: 0 0 1rem; page-break-inside: avoid; }
    .grid { page-break-inside: auto; }
    .table-responsive { overflow: visible; }
    .grid tr { page-break-inside: avoid; }
    .chip { border: 1px solid var(--fk-slate-400); color: #000; background: transparent; }
    a[href]::after { content: ""; }
}

/* ---------- Mailings: multi-column label fields ---------- */
.label-fields { display: flex; flex-direction: column; gap: 10px; padding: 10px 0; }
.label-field {
    display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap;
}
.label-field-caption {
    flex: 0 0 11rem; font-size: .82rem; color: var(--muted);
}
.label-field-columns { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.label-field-join { white-space: nowrap; }
/* Wide enough to show a delimiter of a few characters, and no wider — a space is
   the usual value and an input sized for a column name would look like a mistake. */
.join-input { width: 5rem; text-align: center; }
.btn-icon { padding: .28rem .5rem; font-size: .78rem; line-height: 1; }

/* ---------- Mailings: generation progress ---------- */
.mailing-progress {
    display: flex; gap: 10px; align-items: center;
    padding: 8px 0; font-size: .82rem; color: var(--muted);
    font-variant-numeric: tabular-nums;
}
.mailing-progress progress { width: 14rem; height: .6rem; }

@media (max-width: 640px) {
    .label-field-caption { flex-basis: 100%; }
    .mailing-progress progress { width: 100%; }
}

/* ---- Shared staff widget (Moonreign.StaffTools) -------------------------------
   The widget reads only --st-* properties; this maps them onto the Fairkey tokens. Flat and right-angled like the
   rest of the product: the radii are --fk-radius, the only rounding is the disc itself (--st-shape: disc). */
:root {
  --st-shape: disc;
  --st-ink: var(--fk-ink);
  --st-muted: var(--fk-muted);
  --st-surface: var(--fk-surface);
  --st-field: var(--fk-surface-alt);
  --st-rule: var(--fk-rule);
  --st-rule-strong: var(--fk-rule-strong);
  --st-border-input: var(--fk-border-input);
  --st-accent: var(--fk-teal);
  --st-accent-ink: var(--fk-teal);
  --st-accent-hover-ink: var(--fk-teal-dark);
  --st-on-accent: var(--fk-surface);
  --st-error-ink: var(--fk-danger-ink);
  --st-error-rule: var(--fk-danger-ink);
  --st-radius: var(--fk-radius);
  --st-viewas-radius: var(--fk-radius);
}

/* The view-as pill rests above the widget's disc group instead of under it. The group sits at the package's bottom
   offset (1rem plus --st-bottom-clearance); its cells are 2 x 30px with an 8px gap, and 2 x --st-hit-min below 900px
   (staff-tools.css). The pill keeps its centring: the drag writes translate(-50% + dx).
   The package's view-as.css loads after this file and sets the same rule (bottom: 16px), so the selector carries the
   [data-st-viewas-pill] attribute to win on specificity, not on source order. */
.st-viewas-pill[data-st-viewas-pill] {
  bottom: calc(var(--st-bottom-clearance, 0px) + 1rem + 2 * 30px + 8px + 12px + env(safe-area-inset-bottom, 0px));
}

/* The blocked-write toast sits 6rem (a pill height plus a gap) above the lifted pill, so Stop is never covered.
   The package puts it at 84px for a pill at 16px. [data-st-viewas-toast][role] outranks both the package rule and
   its scoped copy (.st-viewas-toast[b-x], 0,2,0). */
.st-viewas-toast[data-st-viewas-toast][role="status"] {
  bottom: calc(var(--st-bottom-clearance, 0px) + 1rem + 2 * 30px + 8px + 12px + 6rem + env(safe-area-inset-bottom, 0px));
}

@media (max-width: 900px) {
  .st-viewas-pill[data-st-viewas-pill] {
    bottom: calc(var(--st-bottom-clearance, 0px) + 1rem + 2 * var(--st-hit-min, 44px) + 8px + 12px + env(safe-area-inset-bottom, 0px));
  }
  .st-viewas-toast[data-st-viewas-toast][role="status"] {
    bottom: calc(var(--st-bottom-clearance, 0px) + 1rem + 2 * var(--st-hit-min, 44px) + 8px + 12px + 6rem + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 900px) {
  /* The bottom tab bar (.fk-tabbar, 76px: --fk-tabbar-height in fairkey-tokens.css, identical to the
     waitlist and lease copies) is fixed to the same edge as the disc group, so lift the group above it. The token is
     used directly: app.css imports fairkey-tokens.css (line 4), so the var resolves on every page. */
  body:has(.fk-tabbar) {
    --st-bottom-clearance: var(--fk-tabbar-height);
  }
}
