/* The brand of every signed-in page, defined once: the homepage's light theme (core/static/core/home.css) as the
   studio uses it. Red, ink, white and ivory; League Spartan for display (uppercase), Lora for text, a monospace for
   clocks and numbers (fonts self-hosted in ./fonts, SIL OFL 1.1). No dark theme: every page is light.

   What lives here (core/tests/test_brand.py checks it):
   1. the tokens (:root): the studio's names and values (studio/static/studio/studio.css keeps a copy until it imports
      this file; the test fails if the two disagree), the colour-coded statuses (--st-*) with their icons (--ico-*),
      and the old core/app.css names (--fg, --card, --err, --ok, --warn-bg, --warn-fg) for the templates' inline styles;
   2. the base elements (box sizing, body, links, headings, the blue focus ring);
   3. the shared header (core/templates/core/_header.html: .top, .top-row, .brand, .logo, .nav, .signout,
      .linkbtn, .qinfo), the account bar (core/_account_bar.html: .acct ...), the clock's state chip on every page
      (.meter-chip[data-status]: the account bar and Studio time, one colour per status), the small button (.btn-xs),
      the status badges (.badge.queued / .running / .check / .hold / .done / .failed / .blocked / .cancelled) and the
      status line (static/studio/status.js: .vstatus, .vs-*, the "ready" notice .vs-note): defined here only, so
      every page gets the same header, chips, badges and status line (studio.css, clock.css and library.css keep no
      copy; core/tests/test_brand.py checks it);
   4. br-* components for any page: buttons (.br-btn, .br-btn-red / -sec / -ghost / -danger, .br-btn-sm), cards
      (.br-card), chips (.br-chip), tabs (.br-tabs, .br-tab), fields and inputs (.br-field, .br-input), tables
      (.br-table, .br-table-scroll), messages (.br-msg), headings (.br-eyebrow, .br-h1, .br-h2, .br-lead), the
      footer (.br-footer) and helpers (.br-wrap, .br-skip, .br-sr);
   5. the pages built on core/templates/base.html (body.app: account, billing, Studio time, legal, sign-in): their
      plain class names (.card, .btn, .btn-outline, .msg, .muted, .price, tables, forms ...) in the brand look.
   Text colours pass WCAG AA (4.5:1) on every surface they are used on; statuses pair colour with an icon and a label.
   Phones: 375 px wide without sideways scrolling (the menu scrolls inside its own row). */

@font-face { font-family: "League Spartan"; src: url("fonts/LeagueSpartan-VF.f29fcc807045.ttf") format("truetype");
  font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Lora"; src: url("fonts/Lora-VF.e71368f22122.ttf") format("truetype");
  font-weight: 400 700; font-style: normal; font-display: swap; }

/* ================================================================ 1. tokens */
:root {
  /* brand (the homepage's :root) */
  --red: #D9292D; --red-dark: #B81F23; --ink: #000000; --white: #FFFFFF; --ivory: #FBF9F4;
  --pink: #FDF2F2; --pink-2: #F9E0E1; --pink-line: #F1C4C6;
  --font-display: "League Spartan", "Arial Narrow", Arial, sans-serif;
  --font-body: Lora, Georgia, "Times New Roman", serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* surfaces, lines, text */
  --bg: var(--ivory); --panel: var(--white); --panel-2: var(--ivory); --panel-3: #F3F1EB; --panel-4: #E7E4DC;
  --line: #E5E7EB; --line-2: #D1D5DB;
  --line-3: #868C96;          /* 3:1 on white and ivory: the edge of inputs and controls (WCAG 1.4.11) */
  --text: #111111; --text-2: #374151;
  --muted: #5F6672;           /* the homepage's #6B7280 drops under 4.5:1 on the ivory fills; this one passes on all */
  --dim: var(--muted);
  --accent: var(--red); --accent-2: var(--red-dark);
  --accent-ink: var(--red-dark);   /* red text and links: 4.5:1 on white, ivory and pink (--red is not on pink) */
  --accent-soft: var(--pink); --accent-line: var(--pink-line);
  /* focus: a blue no status, selection or error uses, 6.7:1 on white, 6.4:1 on ivory and pink */
  --focus: #1D4ED8; --focus-ring: rgba(29,78,216,.25);
  --good: #166534; --good-soft: #E8F5EC; --good-line: #A9D9B7;
  --warn: #92400E; --warn-soft: #FEF3C7; --warn-line: #F2CF7E; --warn-ink: #78350F;
  --bad: #B91C1C; --bad-soft: #FEF2F2; --bad-line: #F3B4B4; --bad-ink: #7F1D1D;
  --violet: #5B21B6; --violet-soft: #F5F3FF; --violet-line: #DDD6FE;
  --shadow-1: 0 1px 2px rgba(17,24,39,.05);
  --edge-shade: rgba(17,24,39,.2);   /* the phone menu's "more this way" shadow */
  --shadow-2: 0 18px 48px rgba(17,24,39,.18);
  --shadow-lift: 0 10px 24px rgba(17,24,39,.08);   /* a card under the pointer */
  --scrim: rgba(17,24,39,.45);       /* behind a dialog */
  --glass: rgba(255,255,255,.94);    /* the sticky header, chips over pictures */
  /* a video's dark well and what sits on it (My videos' cards and player) */
  --screen: #111111; --screen-2: #374151;
  --on-video: rgba(0,0,0,.78);       /* the duration chip over a thumbnail */
  --scrim-video: rgba(0,0,0,.72);    /* behind the video player */
  --shadow-video: 0 4px 16px rgba(0,0,0,.35);   /* the play button over a thumbnail */
  --shadow-player: 0 24px 64px rgba(0,0,0,.4);
  --r: 12px; --r-md: 8px; --r-sm: 6px;
  --r-btn: 4px; --r-card: 8px;       /* the homepage's button and card radii */
  --hdr: 56px;

  /* statuses: -fg text and icon on -bg fill (4.5:1 or better), -line the edge, -bar a card's left stripe */
  --st-queued-fg: #1E3A5F; --st-queued-bg: #EEF3F9; --st-queued-line: #C5D3E4; --st-queued-bar: #5B7A9D;
  --st-render-fg: var(--red-dark); --st-render-bg: var(--pink); --st-render-line: var(--pink-line); --st-render-bar: var(--red);
  --st-check-fg: #92400E; --st-check-bg: #FEF3C7; --st-check-line: #F2CF7E; --st-check-bar: #D97706;
  --st-done-fg: #166534; --st-done-bg: #E8F5EC; --st-done-line: #A9D9B7; --st-done-bar: #16A34A;
  --st-fail-fg: #7F1D1D; --st-fail-bg: #FEE2E2; --st-fail-line: #E9A0A0; --st-fail-bar: #991B1B;
  --st-cancel-fg: #4B5563; --st-cancel-bg: #F3F4F6; --st-cancel-line: #D1D5DB; --st-cancel-bar: #9CA3AF;
  /* failed and blocked: a hatched stripe and square badges, so they never read as the brand red (rendering) */
  --st-fail-stripe: repeating-linear-gradient(-45deg, var(--st-fail-bar) 0 4px, var(--st-fail-line) 4px 8px);

  /* status icons, drawn in currentColor through a mask */
  --ico-dot: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='4'/%3E%3C/svg%3E");
  --ico-ring: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2'%3E%3Ccircle cx='8' cy='8' r='5'/%3E%3C/svg%3E");
  --ico-queued: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='8' cy='8' r='6'/%3E%3Cpath d='M8 4.8V8l2.2 1.4'/%3E%3C/svg%3E");
  --ico-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 1 2.5 3.2v4.3c0 3.4 2.3 6.2 5.5 7.5 3.2-1.3 5.5-4.1 5.5-7.5V3.2z'/%3E%3C/svg%3E");
  --ico-hold: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='3.5' y='2.5' width='3' height='11' rx='1'/%3E%3Crect x='9.5' y='2.5' width='3' height='11' rx='1'/%3E%3C/svg%3E");
  --ico-done: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m2.8 8.6 3.3 3.2 7.1-7.4'/%3E%3C/svg%3E");
  --ico-fail: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect x='6.6' y='1.5' width='2.8' height='9' rx='1.4'/%3E%3Ccircle cx='8' cy='13.2' r='1.6'/%3E%3C/svg%3E");
  --ico-blocked: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2.2'%3E%3Ccircle cx='8' cy='8' r='6'/%3E%3Cpath d='M3.8 12.2 12.2 3.8'/%3E%3C/svg%3E");
  --ico-cancel: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m4 4 8 8M12 4l-8 8'/%3E%3C/svg%3E");

  /* the old core/app.css names, still used by inline styles in templates (account, fleet): the brand values */
  --fg: var(--text); --card: var(--panel); --err: var(--bad); --ok: var(--good);
  --warn-bg: var(--warn-soft); --warn-fg: var(--warn-ink); --accent-fg: var(--white);
  color-scheme: light;
}

/* ================================================================ 2. base elements */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; background-color: var(--bg); color: var(--text-2); font-family: var(--font-body); line-height: 1.55; }
a { color: var(--accent-ink); }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--text); }

/* ================================================================ 3. the shared header, account bar, badges */
.top {
  position: sticky; top: 0; z-index: 20; padding: 0 24px;
  background: var(--glass); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.top-row { display: flex; align-items: center; gap: 14px; min-height: 52px; }
.brand { display: flex; align-items: center; gap: 10px; flex: none; color: var(--ink); font: 800 19px/1 var(--font-display); letter-spacing: -.01em; text-decoration: none; }
.brand:hover { text-decoration: none; color: var(--ink); }
.logo { width: 28px; height: 28px; border-radius: 6px; display: grid; place-items: center; background: var(--red); color: var(--white); }
.nav { display: flex; gap: 2px; flex: none; }
.nav a { padding: 6px 11px 5px; border-radius: 99px; color: var(--text-2); font: 600 12.5px/1.3 var(--font-display); letter-spacing: .06em; text-transform: uppercase; text-decoration: none; }
.nav a:hover { color: var(--ink); background: var(--panel-3); text-decoration: none; }
/* the page you are on ("page") or the section it belongs to ("true"): the selected style, a red edge on pink */
.nav a[aria-current] { color: var(--accent-ink); background: var(--pink); box-shadow: inset 0 0 0 1px var(--pink-line); }
/* the queue-info slot: static/studio/status.js puts the counts and a My videos link here on a page without its own
   status line (Projects, My videos' header on phones is hidden like the rest of it) */
.qinfo { margin-left: auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.qinfo b { color: var(--ink); font-weight: 700; font-family: var(--font-mono); }
.qinfo .vs-link { display: inline-flex; align-items: center; gap: 4px 6px; max-width: 100%; color: var(--text-2); font: 600 12.5px/1.3 var(--font-display); text-decoration: none; }
.qinfo a.vs-link:hover { text-decoration: none; color: var(--ink); }
.qinfo .vs-go { color: var(--accent-ink); margin-left: 4px; }
.qinfo a.vs-link:hover .vs-go { text-decoration: underline; text-underline-offset: 2px; }
.signout { margin: 0; flex: none; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--muted); cursor: pointer; font: 600 13px/1.4 var(--font-display); text-decoration: none; }
.linkbtn:hover { color: var(--ink); text-decoration: underline; }

/* the account bar: the studio clock (meter/static/meter/clock.js) or the read-only balance */
.acct { display: flex; flex-direction: column; gap: 3px; padding: 2px 0 9px; }
.acct [hidden] { display: none !important; }
.acct-main { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.acct-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.acct-sub { display: flex; gap: 6px 14px; flex-wrap: wrap; align-items: center; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
/* the clock's state chip: the label says the state, the icon and colour repeat it. The size is the account bar's here
   (meter/static/meter/clock.css makes Studio time's bigger); the status colours below are the only ones, for every
   page: running green; rendering red with a live dot; the queue slate; paused, parked, waiting and the safety check
   amber; a free place green; out of time square red (meter texts.CLOCK) */
.meter-chip {
  --ico: var(--ico-dot);
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 11px 3px 8px; border-radius: 99px;
  font: 650 12.5px/1.4 var(--font-display); background: var(--st-cancel-bg); color: var(--st-cancel-fg); border: 1px solid var(--st-cancel-line);
}
.meter-chip::before {
  content: ""; flex: none; width: 10px; height: 10px; background: currentColor;
  -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat;
}
.meter-chip[data-status="running"] { background: var(--st-done-bg); color: var(--st-done-fg); border-color: var(--st-done-line); }
.meter-chip[data-status="pay_per_render"], .meter-chip[data-status="render_waiting"] {
  background: var(--st-queued-bg); color: var(--st-queued-fg); border-color: var(--st-queued-line); }
.meter-chip[data-status="render_waiting"] { --ico: var(--ico-queued); }
.meter-chip[data-status="rendering"], .meter-chip[data-status="render_charging"],
.meter-chip[data-status="render_running"], .meter-chip[data-status="render_dedicated"] {
  background: var(--st-render-bg); color: var(--st-render-fg); border-color: var(--st-render-line); }
.meter-chip[data-status="rendering"]::before, .meter-chip[data-status="render_charging"]::before,
.meter-chip[data-status="render_running"]::before, .meter-chip[data-status="render_dedicated"]::before {
  -webkit-mask: none; mask: none; width: 8px; height: 8px; margin: 0 1px; border-radius: 50%; background: var(--st-render-bar);
  animation: live 1.6s ease-out infinite;
}
.meter-chip[data-status^="paused"], .meter-chip[data-status="parked"], .meter-chip[data-status="waiting_room"],
.meter-chip[data-status="render_checking"], .meter-chip[data-status="render_paused"] {
  --ico: var(--ico-hold); background: var(--st-check-bg); color: var(--st-check-fg); border-color: var(--st-check-line); }
.meter-chip[data-status="paused_safety"], .meter-chip[data-status="render_checking"] { --ico: var(--ico-check); }
.meter-chip[data-status="waiting_room"] { --ico: var(--ico-queued); }
.meter-chip[data-status="slot_ready"] { --ico: var(--ico-done); background: var(--st-done-bg); color: var(--st-done-fg); border-color: var(--st-done-line); }
.meter-chip[data-status="out_of_time"], .meter-chip[data-status="finishing"], .meter-chip[data-status="account_hold"] {
  --ico: var(--ico-fail); border-radius: 4px; background: var(--st-fail-bg); color: var(--st-fail-fg); border-color: var(--st-fail-line); }
.acct .meter-time { font-family: var(--font-mono); font-variant-numeric: tabular-nums; font-size: 19px; font-weight: 700; letter-spacing: .01em; color: var(--ink); }
.acct .meter-warning { color: var(--warn); font-weight: 600; }
.acct .meter-error { color: var(--bad); font-weight: 600; }
.acct .meter-waiting { display: inline-flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.acct .meter-waiting label { display: inline-flex; gap: 6px; align-items: center; cursor: pointer; color: var(--text-2); }
.addtime { border-color: var(--accent-ink) !important; color: var(--accent-ink) !important; }
.addtime:hover { background: var(--pink) !important; }

/* the small button (the account bar, the studio's cards and tools) */
.btn-xs {
  display: inline-flex; align-items: center; gap: 5px; min-height: 32px; padding: 6px 10px; white-space: nowrap; cursor: pointer;
  border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--panel); color: var(--text);
  font: 600 12.5px/1.2 var(--font-display); text-decoration: none; transition: border-color .15s, color .15s, background .15s;
}
.btn-xs:hover { border-color: var(--ink); color: var(--ink); text-decoration: none; }
.btn-xs.primary { background: var(--pink); border-color: var(--pink-line); color: var(--red-dark); }
.btn-xs.primary:hover { background: var(--pink-2); border-color: var(--red); color: var(--red-dark); }
.btn-xs.ghost { background: transparent; }
.btn-xs:disabled { opacity: .5; cursor: default; }
.btn-xs:disabled:hover { border-color: var(--line-2); }
.btn-xs svg { width: 13px; height: 13px; flex: none; }

/* status badges: the icon is ::before, so a status is never colour alone; failed / blocked are square, the rest pills */
.badge {
  --ico: var(--ico-dot);
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px 2px 7px; border-radius: 99px;
  border: 1px solid var(--st-cancel-line); background: var(--st-cancel-bg); color: var(--st-cancel-fg);
  font: 700 11px/1.45 var(--font-display); letter-spacing: .06em; text-transform: uppercase; white-space: nowrap;
}
.badge::before {
  content: ""; flex: none; width: 10px; height: 10px; background: currentColor;
  -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat;
}
.badge.queued { --ico: var(--ico-queued); background: var(--st-queued-bg); color: var(--st-queued-fg); border-color: var(--st-queued-line); }
.badge.running { background: var(--st-render-bg); color: var(--st-render-fg); border-color: var(--st-render-line); }
/* rendering: a live dot that pulses (a still dot with reduced motion) */
.badge.running::before {
  -webkit-mask: none; mask: none; width: 8px; height: 8px; margin: 0 1px; border-radius: 50%; background: var(--st-render-bar);
  animation: live 1.6s ease-out infinite;
}
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(217,41,45,.5); } 70%, 100% { box-shadow: 0 0 0 6px rgba(217,41,45,0); } }
.badge.check { --ico: var(--ico-check); background: var(--st-check-bg); color: var(--st-check-fg); border-color: var(--st-check-line); }
.badge.hold { --ico: var(--ico-hold); background: var(--st-check-bg); color: var(--st-check-fg); border-color: var(--st-check-line); }
.badge.done { --ico: var(--ico-done); background: var(--st-done-bg); color: var(--st-done-fg); border-color: var(--st-done-line); }
.badge.failed, .badge.blocked { --ico: var(--ico-fail); border-radius: 4px; background: var(--st-fail-bg); color: var(--st-fail-fg); border-color: var(--st-fail-line); }
.badge.blocked { --ico: var(--ico-blocked); }
.badge.cancelled { --ico: var(--ico-cancel); }

/* the status line (static/studio/status.js; docs/saas/FEATURE_REQUESTS.md items 3 and 4): the counts, one short row per
   video in progress (Cancel while it waits, the time left once it renders) and a link to My videos; Create puts it under
   the composer (studio.css places it), My videos at the top of the list */
.vstatus { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-1); }
.vs-line { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; padding: 9px 12px 9px 16px; }
.vs-counts { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; min-height: 32px; font: 600 13.5px/1.35 var(--font-display); color: var(--text-2); }
.vs-counts:empty::before { content: "Your videos"; color: var(--muted); }
.vs-c { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.vs-c b { font: 700 14px/1 var(--font-mono); color: var(--ink); font-variant-numeric: tabular-nums; }
.vs-c.run b { color: var(--st-render-fg); }
.vs-sep { color: var(--line-3); }
.vs-eta { font: 500 12.5px/1.3 var(--font-mono); color: var(--st-render-fg); font-variant-numeric: tabular-nums; }
.vs-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--st-render-bar); animation: live 1.6s ease-out infinite; }
.vs-lib { font: 650 13px/1.3 var(--font-display); color: var(--accent-ink); white-space: nowrap; }
.vs-rows { list-style: none; margin: 0; padding: 0 12px 6px 16px; border-top: 1px solid var(--line); }
.vs-row {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 4px 10px;
  min-height: 40px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px;
}
.vs-row:last-child { border-bottom: 0; }
.vs-what { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); }
.vs-what b { font: 650 13px/1.3 var(--font-display); color: var(--text); }
.vs-title { color: var(--muted); }
.vs-left { font: 500 12px/1.3 var(--font-mono); color: var(--text-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.vs-row[data-s="running"] .vs-left { color: var(--st-render-fg); }
.vs-acts { display: flex; justify-content: flex-end; min-width: 0; }
.vs-nocancel { font: 500 12px/1.3 var(--font-display); color: var(--muted); white-space: nowrap; }
.vs-more { padding: 6px 0 4px; font: 600 12.5px/1.3 var(--font-display); }
/* the row's Cancel (status.js: .act.danger): the studio cards' quiet action button, wherever the line is */
.vs-acts .act { padding: 5px 9px; border: 0; border-radius: var(--r-sm); background: none; color: var(--text-2);
  font: 600 12.5px/1.3 var(--font-display); cursor: pointer; }
.vs-acts .act:hover { background: var(--panel-3); color: var(--ink); }
.vs-acts .act.danger:hover { color: var(--bad-ink); background: var(--bad-soft); }
.vs-acts .act:disabled { opacity: .5; cursor: default; }
/* a Projects take in progress (stories/static/stories/projects.js): its stage, then Cancel or the time left */
.vs-take { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.vs-take-live:empty { display: none; }
/* the "ready" notice (status.js): a corner card, apart from a page's own toast */
.vs-note {
  position: fixed; right: 20px; bottom: 20px; z-index: 60; display: flex; align-items: center; gap: 6px 12px;
  max-width: min(92vw, 440px); padding: 12px 10px 12px 16px; border-radius: var(--r-md);
  background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--st-done-bar); box-shadow: var(--shadow-2);
  color: var(--text); font-size: 13.5px;
}
.vs-note.bad { border-left-color: var(--st-fail-bar); }
.vs-note-t { flex: 1 1 auto; min-width: 0; }
.vs-note-a { font: 650 13px/1.3 var(--font-display); color: var(--accent-ink); white-space: nowrap; }
.vs-note-x { flex: none; width: 28px; height: 28px; border: 0; border-radius: var(--r-sm); background: none; color: var(--muted); font-size: 18px; line-height: 1; cursor: pointer; }
.vs-note-x:hover { background: var(--panel-3); color: var(--ink); }

/* ================================================================ 4. br-* components */
.br-wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 40px; }
.br-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0; }
.br-skip { position: absolute; left: 16px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: var(--r-btn);
  background: var(--ink); color: var(--white) !important; font: 600 14px/1.2 var(--font-display); text-decoration: none; }
.br-skip:focus { top: 12px; }

/* headings and text */
.br-eyebrow { margin: 0 0 8px; font: 700 13px/1.3 var(--font-display); letter-spacing: .16em; text-transform: uppercase; color: var(--accent-ink); }
.br-h1 { margin: 0; font: 800 44px/1 var(--font-display); letter-spacing: -.01em; text-transform: uppercase; color: var(--ink); overflow-wrap: anywhere; }
.br-h2 { margin: 0; font: 700 24px/1.1 var(--font-display); text-transform: uppercase; color: var(--ink); }
.br-lead { margin: 12px 0 0; font-size: 17px; color: var(--text-2); }
.br-note { margin: 0; font-size: 14px; color: var(--muted); }
/* the price per rendered hour (core/_price.html): the regular price struck through while the launch price is on */
.br-was { color: var(--muted); font-size: .8em; font-weight: 500; text-decoration-thickness: 2px; }
.br-price-unit { font: 400 14px/1.4 var(--font-body); color: var(--muted); }
.br-price-note { display: block; margin-top: 2px; font: 400 14px/1.4 var(--font-body); color: var(--muted); }

/* buttons (the homepage's hp-btn): red for the main action, outlined ink for the next one, ghost for the rest */
.br-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 22px;
  border: 1px solid transparent; border-radius: var(--r-btn); cursor: pointer; text-align: center; white-space: nowrap;
  font: 600 14px/1.1 var(--font-display); letter-spacing: .05em; text-transform: uppercase; text-decoration: none;
  transition: background .15s, color .15s, border-color .15s; }
.br-btn:hover { text-decoration: none; }
.br-btn-red, a.br-btn-red { background: var(--red); border-color: var(--red); color: var(--white); }
.br-btn-red:hover, a.br-btn-red:hover { background: var(--red-dark); border-color: var(--red-dark); color: var(--white); }
.br-btn-sec, a.br-btn-sec { background: var(--white); border-color: var(--ink); color: var(--ink); }
.br-btn-sec:hover, a.br-btn-sec:hover { background: var(--ink); color: var(--white); }
.br-btn-ghost, a.br-btn-ghost { background: transparent; border-color: var(--line-2); color: var(--text-2); }
.br-btn-ghost:hover, a.br-btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.br-btn-danger, a.br-btn-danger { background: var(--white); border-color: var(--bad); color: var(--bad); }
.br-btn-danger:hover, a.br-btn-danger:hover { background: var(--bad); color: var(--white); }
.br-btn-sm { min-height: 36px; padding: 0 14px; font-size: 13px; }
.br-btn:disabled, .br-btn[aria-disabled="true"] { opacity: .45; cursor: default; }

/* cards */
.br-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-card); padding: 20px; }
.br-card.br-flush { padding: 0; overflow: hidden; }
a.br-card { display: block; color: inherit; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
a.br-card:hover { border-color: var(--ink); box-shadow: var(--shadow-lift); }

/* chips: small labels (not statuses: those are .badge) */
/* Pricing v3: the three plan cards (core/_plan_cards.html, the Day Pass highlighted) and the FAQ (core/_faq.html) */
.br-plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 24px 0 12px; }
.br-plan { display: flex; flex-direction: column; gap: 12px; padding: 20px; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--r-card); }
.br-plan-on { background: var(--pink); border-color: var(--red); box-shadow: inset 0 0 0 1px var(--red); }
.br-plan-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.br-plan-name { margin: 0; font: 700 19px/1.2 var(--font-display); }
.br-plan-tag { padding: 3px 10px 2px; border-radius: 99px; background: var(--ink); color: var(--white);
  font: 700 11px/1.5 var(--font-display); letter-spacing: .12em; text-transform: uppercase; }
.br-plan-on .br-plan-tag { background: var(--red); }
.br-plan-price { margin: 0; }
.br-plan-price strong { font: 800 36px/1 var(--font-display); color: var(--text); }
.br-plan-unit { font: 400 14px/1.4 var(--font-body); color: var(--muted); }
.br-plan-sub { margin: 0; font-weight: 600; }
.br-plan-list { margin: 0; padding-left: 18px; display: grid; gap: 6px; font-size: 14px; }
.br-plan-packs { margin: 0; font-size: 13px; color: var(--muted); }
.br-plan-was { color: var(--muted); }
.br-plan-cta { margin: auto 0 0; padding-top: 6px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.br-plan-link { color: var(--accent-ink); font-weight: 600; }
.br-faq details { padding: 14px 0; border-top: 1px solid var(--line); }
.br-faq details:last-child { border-bottom: 1px solid var(--line); }
.br-faq summary { cursor: pointer; font: 700 16px/1.35 var(--font-display); color: var(--text); }
.br-faq p { margin: 8px 0 0; }

.br-chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 99px; white-space: nowrap;
  border: 1px solid var(--line); background: var(--ivory); color: var(--text-2);
  font: 700 11px/1.5 var(--font-display); letter-spacing: .08em; text-transform: uppercase; }
.br-chip-red { background: var(--red); border-color: var(--red); color: var(--white); }
.br-chip-ink { background: var(--ink); border-color: var(--ink); color: var(--white); }
.br-chip-soft { background: var(--pink); border-color: var(--pink-2); color: var(--red-dark); }

/* tabs (filters, sub-navigation): pills; the current one has the selected style, a red edge on pink */
.br-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; padding: 0; list-style: none; }
.br-tab { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 18px; border: 1px solid var(--line);
  border-radius: 99px; background: var(--white); color: var(--ink); text-decoration: none;
  font: 600 14px/1.2 var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.br-tab:hover { border-color: var(--ink); color: var(--ink); text-decoration: none; }
.br-tab[aria-current], .br-tab[aria-selected="true"] { background: var(--pink); border-color: var(--red); color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--red); }
.br-count { font: 500 12px/1 var(--font-mono); letter-spacing: 0; color: var(--muted); }

/* fields and inputs */
.br-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.br-field > label, .br-field > span { font: 650 14px/1.35 var(--font-display); color: var(--text); }
.br-input { width: 100%; padding: 10px 12px; border: 1px solid var(--line-3); border-radius: var(--r-sm); background: var(--panel);
  color: var(--text); transition: border-color .15s, box-shadow .15s; }
.br-input::placeholder { color: var(--muted); opacity: 1; }
.br-input:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px var(--focus-ring); }

/* tables */
.br-table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.br-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.br-table th { padding: 10px 12px; text-align: left; vertical-align: bottom; border-bottom: 1px solid var(--line-2); color: var(--muted);
  font: 700 12px/1.3 var(--font-display); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.br-table td { padding: 10px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); overflow-wrap: break-word; }

/* messages: a stripe on the left repeats the colour, the text says what happened */
.br-msg { margin: 0 0 12px; padding: 12px 16px; border: 1px solid var(--line); border-left: 4px solid var(--line-3);
  border-radius: var(--r-md); background: var(--panel); color: var(--text-2); }
.br-msg-ok { border-color: var(--good-line); border-left-color: var(--good); background: var(--good-soft); color: var(--good); }
.br-msg-warn { border-color: var(--warn-line); border-left-color: var(--warn); background: var(--warn-soft); color: var(--warn-ink); }
.br-msg-error { border-color: var(--bad-line); border-left-color: var(--bad); background: var(--bad-soft); color: var(--bad-ink); }

/* footer */
.br-footer { margin-top: auto; border-top: 1px solid var(--line); background: var(--white); padding: 20px 0 28px; font-size: 13px; color: var(--muted); }
.br-footer p { margin: 4px 0; }
.br-footer a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.br-footer a:hover { color: var(--ink); }

/* the signed-out header of the public pages (core/_public_header.html): the homepage's header (core/home.css .hp-header) */
.br-pub { position: sticky; top: 0; z-index: 20; background: var(--white); border-bottom: 1px solid var(--line); }
.br-pub-row { display: flex; align-items: center; gap: 16px; min-height: 68px; max-width: 1280px; margin: 0 auto; padding: 0 40px; }
.br-pub a { text-decoration: none; }
a.br-pub-logo { display: flex; align-items: center; gap: 10px; flex: none; color: var(--ink); }
a.br-pub-logo:hover { color: var(--ink); text-decoration: none; }
.br-pub-word { font: 800 22px/1 var(--font-display); letter-spacing: -.01em; white-space: nowrap; }
.br-red { color: var(--red); }
a.br-pub-section { font: 700 13px/1 var(--font-display); letter-spacing: .14em; text-transform: uppercase; color: var(--accent-ink);
  padding: 4px 10px; border-left: 1px solid var(--line); }
.br-pub-links { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.br-pub-links a:not(.br-btn) { font: 600 13px/1 var(--font-display); letter-spacing: .06em; text-transform: uppercase; color: var(--ink);
  padding: 12px 10px; }
.br-pub-links a:not(.br-btn):hover { color: var(--accent-ink); }
@media (max-width: 900px) { .br-pub-row { padding: 0 24px; } }
@media (max-width: 600px) {
  .br-pub-row { padding: 0 16px; gap: 8px; min-height: 60px; }
  .br-pub-word { font-size: 18px; }
  .br-pub-row a.br-pub-section, .br-pub-links a.br-pub-more { display: none; }
  .br-pub-links { gap: 2px; white-space: nowrap; }
  .br-pub-links a { min-height: 44px; display: inline-flex; align-items: center; }
  .br-pub-links .br-btn-sm { padding: 0 12px; }
}
@media (max-width: 420px) { .br-pub-word { display: none; } }

/* ================================================================ 5. pages on core/templates/base.html */
body.app { display: flex; flex-direction: column; font-size: 16px; }
.app .wrap { width: 100%; max-width: 60rem; margin: 0 auto; padding: 0 24px; }
.app .main { flex: 1 0 auto; padding-top: 36px; padding-bottom: 56px; }
.app .top-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 4px 8px; margin-left: auto; }
.app .top-actions a { color: var(--text-2); font: 600 13px/1.4 var(--font-display); letter-spacing: .06em;
  text-transform: uppercase; text-decoration: none; padding: 6px 8px; }
.app .top-actions a:hover { color: var(--ink); text-decoration: underline; }
.app .top-cta { flex: none; }
.app .env-banner { background: var(--warn-soft); color: var(--warn-ink); text-align: center; font-size: 13px; padding: 4px 16px; }
.app .draft-banner { background: var(--warn-soft); color: var(--warn-ink); border: 1px solid var(--warn-line); padding: 10px 14px;
  border-radius: var(--r-md); margin: 0 0 1rem; font-weight: 600; }

/* text */
.app h1 { margin: 0 0 16px; font: 800 40px/1.04 var(--font-display); letter-spacing: -.01em; text-transform: uppercase; color: var(--ink); overflow-wrap: anywhere; }
.app h2 { margin: 0 0 10px; font: 700 20px/1.2 var(--font-display); letter-spacing: .02em; text-transform: uppercase; color: var(--ink); }
.app h3 { margin: 1em 0 8px; font: 700 16px/1.3 var(--font-display); color: var(--text); }
.app p { margin: 0 0 .75rem; }
/* links in the text are underlined (not told by colour alone); buttons, tabs and cards are not */
.app .main a:where(:not(.btn, .br-btn, .br-tab, .br-card, .btn-xs)) { text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px; }
.app .main a:where(:not(.btn, .br-btn, .br-tab, .br-card, .btn-xs)):hover { color: var(--ink); }
.app .muted { color: var(--muted); }
.app .lead { font-size: 17px; color: var(--text-2); }
.app .hero { padding: 8px 0 20px; }
.app .bullets { padding-left: 1.2rem; list-style: disc; }
.app .bullets li + li { margin-top: 4px; }
.app code { font-family: var(--font-mono); font-size: .88em; background: var(--pink); color: var(--ink); padding: 1px 5px;
  border-radius: 4px; overflow-wrap: anywhere; }
.app pre { overflow-x: auto; max-width: 100%; }
.app pre code { background: none; padding: 0; }
.app .legal-doc { white-space: pre-wrap; overflow-wrap: anywhere; }

/* cards and numbers */
.app .card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-card); padding: 24px; margin: 16px 0; min-width: 0; }
.app .card.danger { border-color: var(--bad-line); box-shadow: inset 4px 0 0 var(--bad); }
.app .price, .app .balance { margin: .1rem 0 .6rem; font: 700 32px/1.15 var(--font-mono); font-variant-numeric: tabular-nums; color: var(--ink); overflow-wrap: anywhere; }
.app .grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 16px; }
.app .facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 18px; margin: 0; }
.app .facts dt { color: var(--muted); }
.app .facts dd { margin: 0; overflow-wrap: anywhere; }
.app .actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* buttons: red for the main action (and every submit button in the page; not the header's sign out), outlined ink
   for the others */
.app .btn, .app .main button[type=submit]:where(:not(.linklike, .linkbtn)) {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 22px;
  border: 1px solid var(--red); border-radius: var(--r-btn); background: var(--red); color: var(--white); cursor: pointer;
  font: 600 14px/1.1 var(--font-display); letter-spacing: .05em; text-transform: uppercase; text-decoration: none; text-align: center;
  transition: background .15s, color .15s, border-color .15s;
}
.app .btn:hover, .app .main button[type=submit]:where(:not(.linklike, .linkbtn)):hover { background: var(--red-dark); border-color: var(--red-dark); color: var(--white); text-decoration: none; }
.app .btn-sm { min-height: 36px; padding: 0 14px; font-size: 13px; }
.app .btn-outline, .app button.btn-outline[type=submit] { background: var(--white); color: var(--ink); border-color: var(--ink); }
.app .btn-outline:hover, .app button.btn-outline[type=submit]:hover { background: var(--ink); color: var(--white); border-color: var(--ink); }
.app .btn-danger, .app button.btn-danger[type=submit] { background: var(--bad); border-color: var(--bad); color: var(--white); }
.app .btn-danger:hover, .app button.btn-danger[type=submit]:hover { background: var(--bad-ink); border-color: var(--bad-ink); }
.app button:disabled, .app .btn[aria-disabled="true"] { opacity: .5; cursor: default; }
.app .linklike { background: none; border: 0; padding: 0; color: var(--accent-ink); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.app .linklike:hover { color: var(--ink); }

/* forms */
.app form p { margin: 0 0 14px; }
.app label { display: block; margin-bottom: 4px; font: 650 14px/1.35 var(--font-display); color: var(--text); }
.app input[type=text], .app input[type=email], .app input[type=password], .app input[type=number], .app input[type=tel],
.app input[type=url], .app input[type=search], .app input:not([type]), .app select, .app textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line-3); border-radius: var(--r-sm); background: var(--panel); color: var(--text);
  font: inherit; transition: border-color .15s, box-shadow .15s; }
.app input::placeholder, .app textarea::placeholder { color: var(--muted); opacity: 1; }
.app input:focus, .app select:focus, .app textarea:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px var(--focus-ring); }
.app input[type=checkbox], .app input[type=radio] { width: 18px; height: 18px; margin: 3px 8px 0 0; flex: none; accent-color: var(--red); }
.app input[type=checkbox]:focus-visible, .app input[type=radio]:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.app fieldset { border: 0; margin: 0 0 12px; padding: 0; min-width: 0; }
.app .check { display: flex; gap: 8px; align-items: flex-start; margin: 10px 0; }
.app .check label { display: inline; margin: 0; font: inherit; color: var(--text-2); }
.app .errorlist { color: var(--bad); list-style: none; padding: 0; margin: 4px 0; font-weight: 600; }
.app .helptext { color: var(--muted); font-size: 14px; }
.app .auth-card { max-width: 30rem; margin: 0 auto; }
/* phone: country-code picker + number side by side, even at 375px (accounts/_phone_fields.html) */
.app .phone-row { display: grid; grid-template-columns: minmax(0, 9.5rem) minmax(0, 1fr); gap: 8px; }
.app .phone-row select, .app .phone-row input { min-width: 0; }
.app .phone { margin: 0 0 14px; }
.app .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.app .auth-main { max-width: 32rem; }
.app .steps { display: flex; gap: 6px 18px; flex-wrap: wrap; list-style: none; padding: 0; margin: 0 0 1rem; counter-reset: step;
  font: 600 13px/1.4 var(--font-display); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.app .steps li { counter-increment: step; }
.app .steps li::before { content: counter(step) ". "; }
.app .steps li.on { color: var(--accent-ink); }

/* messages */
.app .messages { list-style: none; padding: 0; margin: 0 0 16px; }
.app .msg { margin: 0 0 8px; padding: 12px 16px; border: 1px solid var(--line); border-left: 4px solid var(--line-3);
  border-radius: var(--r-md); background: var(--panel); color: var(--text-2); }
.app .msg-success { border-color: var(--good-line); border-left-color: var(--good); background: var(--good-soft); color: var(--good); }
.app .msg-warning, .app .msg.meter-warning { border-color: var(--warn-line); border-left-color: var(--warn); background: var(--warn-soft); color: var(--warn-ink); }
.app .msg-error { border-color: var(--bad-line); border-left-color: var(--bad); background: var(--bad-soft); color: var(--bad-ink); }

/* tables */
.app .table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.app table { width: 100%; border-collapse: collapse; }
.app table th { padding: 8px 10px; text-align: left; vertical-align: bottom; border-bottom: 1px solid var(--line-2); color: var(--muted);
  font: 700 12px/1.3 var(--font-display); letter-spacing: .08em; text-transform: uppercase; }
.app table td { padding: 8px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); overflow-wrap: break-word; }
.app .acct-table { font-size: 14px; }

/* the account pages (accounts/layout.html): the sub-navigation is the tabs; small labels are chips */
.app .subnav { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 20px; padding: 0; list-style: none; }
.app .subnav a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border: 1px solid var(--line);
  border-radius: 99px; background: var(--white); color: var(--ink); text-decoration: none;
  font: 600 13px/1.2 var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.app .subnav a:hover { border-color: var(--ink); color: var(--ink); }
.app .subnav a.on, .app .subnav a[aria-current] { background: var(--pink); border-color: var(--red); box-shadow: inset 0 0 0 1px var(--red); }
.app .tag { display: inline-flex; align-items: center; gap: 5px; padding: 1px 9px; border-radius: 99px; white-space: nowrap;
  border: 1px solid var(--st-cancel-line); background: var(--st-cancel-bg); color: var(--st-cancel-fg);
  font: 700 11px/1.6 var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.app .tag.ok { border-color: var(--st-done-line); background: var(--st-done-bg); color: var(--st-done-fg); }
.app .tag.bad { border-color: var(--st-fail-line); background: var(--st-fail-bg); color: var(--st-fail-fg); border-radius: 4px; }

/* ================================================================ phones and motion */
@media (max-width: 900px) {
  .br-wrap { padding: 0 24px; }
  .br-h1 { font-size: 36px; }
}
@media (max-width: 640px) {
  .br-wrap { padding: 0 16px; }
  .br-h1 { font-size: 30px; }
  .br-tab { padding: 0 14px; font-size: 13px; }
  .app .wrap { padding: 0 16px; }
  .app .main { padding-top: 24px; padding-bottom: 40px; }
  .app h1 { font-size: 30px; }
  .app .card { padding: 18px 16px; }
  .app .price, .app .balance { font-size: 28px; }
  .app input[type=text], .app input[type=email], .app input[type=password], .app input[type=number], .app input[type=tel],
  .app input[type=url], .app input[type=search], .app input:not([type]), .app select, .app textarea { font-size: 16px; } /* no iOS zoom */
  .app .btn-sm, .br-btn-sm { min-height: 44px; }
  .app .subnav a { min-height: 44px; }
}
@media (max-width: 600px) {
  .top { position: static; padding: 0 16px; }
  .top-row { gap: 10px; flex-wrap: wrap; padding: 8px 0 4px; }
  .brand { font-size: 17px; }
  .qinfo { display: none; }
  .signout { margin-left: auto; }
  /* signed out: the brand and Create account on the first line, the links under them */
  .app .top-actions { order: 3; width: 100%; justify-content: flex-start; margin-left: -8px; }
  .app .top-cta { margin-left: auto; }
  /* the menu on its own line, scrolling sideways when it doesn't fit, with a soft shadow at each edge that has more
     links (the white covers scroll with the links, the shadows stay with the box): a cut-off menu shows it scrolls */
  .nav {
    order: 3; width: 100%; overflow-x: auto; overscroll-behavior-x: contain;
    background:
      linear-gradient(90deg, var(--panel) 30%, transparent) left center / 32px 100% no-repeat local,
      linear-gradient(270deg, var(--panel) 30%, transparent) right center / 32px 100% no-repeat local,
      radial-gradient(farthest-side at 0 50%, var(--edge-shade), transparent) left center / 14px 100% no-repeat scroll,
      radial-gradient(farthest-side at 100% 50%, var(--edge-shade), transparent) right center / 14px 100% no-repeat scroll;
  }
  .nav a { padding: 6px 9px 5px; white-space: nowrap; }
  /* touch targets: 44px tall on phones (WCAG 2.5.5; 2.5.8's 24px minimum holds everywhere) */
  .nav a, .linkbtn, .btn-xs, .app .top-actions a, .vs-acts .act { min-height: 44px; display: inline-flex; align-items: center; }
  .linkbtn { padding: 0 6px; }
  .vs-line { padding: 8px 12px; }
  .vs-rows { padding: 0 12px 6px; }
  .vs-row { grid-template-columns: auto minmax(0, 1fr); }
  .vs-row .vs-left { grid-column: 1 / 2; }
  .vs-row .vs-acts { grid-column: 2 / 3; }
  .vs-lib { min-height: 44px; display: inline-flex; align-items: center; }
  .vs-note { left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); max-width: none; }
  .vs-note-x { width: 44px; height: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  .badge.running::before, .meter-chip[data-status="rendering"]::before, .meter-chip[data-status="render_charging"]::before,
  .meter-chip[data-status="render_running"]::before,
  .meter-chip[data-status="render_dedicated"]::before, .vs-dot { animation: none; box-shadow: 0 0 0 2px var(--st-render-line); }
  .br-btn, .btn-xs, a.br-card, .app .btn { transition: none; }
}

/* ---------- the shared progress bar (status.js window.gwProgress): everything being made ---------- */
.gw-prog { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; min-width: 0; font-size: 13px; color: var(--text-2); }
.gw-prog-bar { flex: 1 1 100%; height: 6px; border-radius: 99px; background: var(--panel-2, #F1EEE7); overflow: hidden; position: relative; }
.gw-prog-bar i { display: block; height: 100%; border-radius: 99px; background: var(--accent, #D9292D); transition: width .6s ease; }
@keyframes gw-prog-slide { from { transform: translateX(0); } to { transform: translateX(185%); } }
.gw-prog-bar.indet i { position: absolute; inset: 0 auto 0 0; width: 35% !important; animation: gw-prog-slide 1.1s ease-in-out infinite alternate; }
.gw-prog[data-stage="ready"] .gw-prog-bar i { background: var(--ok, #1f8a4c); }
.gw-prog-t { font-weight: 700; color: var(--ink); overflow-wrap: anywhere; }
.gw-prog-why { overflow-wrap: anywhere; }
.gw-prog[data-stage="failed"] .gw-prog-t { color: var(--danger, #b42318); }
.gw-prog-retry { min-height: 44px; }
@media (prefers-reduced-motion: reduce) {
  .gw-prog-bar i { transition: none; }
  .gw-prog-bar.indet i { animation: none; width: 100% !important; opacity: .45; }
}
