/* app.css — VPP dashboard. Design system lifted from the Vintesh CRM (app.css
   tokens, topbar, buttons, pills). Don't add top-level color tokens without
   checking this block first. */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;450;500;600;700&family=Instrument+Serif:ital@0;1&display=swap');

:root {
  color-scheme: dark;

  --bg-0: #07070b;
  --bg-1: #0d0c14;
  --bg-2: #15131f;

  --surface-0: rgba(255, 255, 255, 0.035);
  --surface-1: rgba(255, 255, 255, 0.055);
  --surface-2: rgba(255, 255, 255, 0.082);
  --surface-solid: #12111b;

  --text-0: #fbfaf7;
  --text-1: rgba(251, 250, 247, 0.78);
  --text-2: rgba(251, 250, 247, 0.56);
  --text-3: rgba(251, 250, 247, 0.36);

  --cream: #f5efe3;
  --champagne: #d8c8a7;
  --lavender: #b9b0d4;
  --violet: #7d67c8;
  --indigo: #181530;

  --line-0: rgba(255, 255, 255, 0.075);
  --line-1: rgba(255, 255, 255, 0.12);
  --line-2: rgba(216, 200, 167, 0.22);

  --good: #86d9a3;
  --warn: #e1bf72;
  --bad: #e28a8f;
  --blue: #9db7e8;
  --teal: #92dacb;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.38);
  --shadow-md: 0 18px 44px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 34px 80px rgba(0, 0, 0, 0.48);

  --radius-xs: 10px;
  --radius-sm: 14px;
  --radius-md: 18px;
  --radius-lg: 26px;
  --radius-pill: 999px;

  --ease: cubic-bezier(.2,.8,.2,1);
  --max: 1440px;
}

/* ========= BASE ========= */
* { box-sizing: border-box; }
/* Scrollbars: thin, no track, a faint thumb that warms to champagne on hover. Inner panels (the
   sidebars, boards) keep theirs invisible until the pointer is over them. Firefox + Chrome read the
   standard properties; Safari reads the ::-webkit ones. */
* { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.14) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track, ::-webkit-scrollbar-corner { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.13); border: 3px solid transparent; border-radius: 999px; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(216,200,167,.38); }
.side, .kb-col-body { scrollbar-color: transparent transparent; }
.side:hover, .kb-col-body:hover { scrollbar-color: rgba(216,200,167,.26) transparent; }
.side::-webkit-scrollbar-thumb, .kb-col-body::-webkit-scrollbar-thumb { background-color: transparent; }
.side:hover::-webkit-scrollbar-thumb, .kb-col-body:hover::-webkit-scrollbar-thumb { background-color: rgba(216,200,167,.26); }
html { min-height: 100%; background: var(--bg-0); text-rendering: geometricPrecision; -webkit-font-smoothing: antialiased; }
body {
  margin: 0; min-height: 100vh; color: var(--text-0);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400; letter-spacing: -0.018em; overflow-x: hidden;
  background: var(--bg-0); position: relative; isolation: isolate;
}
.bg-fixed {
  position: fixed; inset: 0; z-index: -3; pointer-events: none;
  background:
    radial-gradient(circle at 14% -8%, rgba(125, 103, 200, 0.32), transparent 30rem),
    radial-gradient(circle at 92% 4%, rgba(216, 200, 167, 0.11), transparent 28rem),
    radial-gradient(circle at 50% 112%, rgba(72, 52, 137, 0.24), transparent 34rem),
    linear-gradient(180deg, #08080d 0%, #0d0c14 46%, #07070b 100%);
}
a { color: inherit; }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; }
h1 { font-family: "Instrument Serif", Georgia, serif; font-weight: 400; font-size: 34px; letter-spacing: -0.01em; }
h2 { font-size: 17px; font-weight: 600; }
p { margin: 0; }
.muted { color: var(--text-2); }
.muted a { color: var(--text-1); }

/* ========= TOPBAR ========= */
.topbar {
  position: sticky; top: 0; z-index: 100; display: flex; align-items: center; gap: 22px;
  min-height: 76px; padding: 14px clamp(18px, 3vw, 44px);
  background: rgba(7, 7, 11, 0.68); border-bottom: 1px solid var(--line-0);
  backdrop-filter: blur(26px) saturate(145%); -webkit-backdrop-filter: blur(26px) saturate(145%);
}
.brand { min-width: 96px; color: var(--text-0); text-decoration: none; font-weight: 700; letter-spacing: .08em; font-size: 15px; }
.nav-links {
  position: relative; flex: 1; display: flex; align-items: center; gap: 6px; padding: 5px;
  max-width: max-content; background: rgba(255,255,255,.035); border: 1px solid var(--line-0); border-radius: var(--radius-pill);
  overflow-x: auto; scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }
.nav-link {
  position: relative; z-index: 1;
  padding: 8px 14px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 500; color: var(--text-2);
  text-decoration: none; white-space: nowrap; transition: color .3s ease, background .2s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.nav-link:hover { color: var(--text-0); }
.nav-link.is-active { color: #100f16; background: linear-gradient(180deg, #f5efe3, #cdbf9f); }
.nav-link:focus { outline: none; }
.nav-link:focus-visible { outline: 2px solid var(--champagne); outline-offset: 2px; }
/* The liquid pill (ported from the Vintesh CRM): one cream indicator slides and stretches behind
   whichever link is active. Until JS has placed it, the active link paints its own background. */
.seg-indicator {
  position: absolute; z-index: 0; top: 5px; left: 5px; height: calc(100% - 10px); width: 0;
  border-radius: var(--radius-pill); pointer-events: none; opacity: 0;
  background: linear-gradient(180deg, #f5efe3, #cdbf9f);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.68), 0 6px 14px rgba(216,200,167,.18);
  transform: translateX(0); will-change: transform, width;
  transition: transform .42s cubic-bezier(.2,.8,.2,1), width .35s ease, opacity .25s ease;
}
.seg-indicator.no-anim { transition: none; }
.nav-links.has-active .seg-indicator { opacity: 1; }
.nav-links.has-active .nav-link.is-active { background: transparent; }
.user-menu { position: relative; margin-left: auto; }
.user-menu-pop {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 200px; padding: 6px;
  background: var(--surface-solid); border: 1px solid var(--line-1); border-radius: var(--radius-sm); box-shadow: var(--shadow-md);
}
.user-menu-item { display: block; padding: 10px 12px; border-radius: var(--radius-xs); color: var(--text-1); text-decoration: none; font-size: 13px; }
.user-menu-item:hover { color: var(--text-0); background: var(--surface-1); }

/* ========= LAYOUT ========= */
.main { max-width: var(--max); margin: 0 auto; padding: 28px clamp(18px, 3vw, 44px) 80px; }
.page-head { margin: 8px 0 22px; }
.page-head .muted { margin-top: 6px; font-size: 14px; }
.card {
  background: var(--surface-0); border: 1px solid var(--line-0); border-radius: var(--radius-md);
  padding: 22px 24px; box-shadow: var(--shadow-sm);
}
.card + .card { margin-top: 14px; }
.empty { text-align: center; padding: 56px 24px; }
.empty h2 { margin-bottom: 6px; }
.empty .muted { max-width: 52ch; margin: 0 auto; font-size: 14px; }
.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px 24px; margin: 0 0 16px; }
.kv dt { font-size: 11px; color: var(--text-3); font-weight: 600; margin-bottom: 4px; }
.kv dd { margin: 0; font-size: 15px; }

/* ========= BUTTONS ========= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 38px; padding: 0 14px;
  color: var(--text-1); text-decoration: none; text-align: center; font-family: inherit; font-size: 12px; font-weight: 660; letter-spacing: .005em;
  cursor: pointer; border: 1px solid var(--line-0); border-radius: var(--radius-pill); background: rgba(255,255,255,.034);
  transition: transform .2s var(--ease), background .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}
.btn:hover { color: var(--text-0); transform: translateY(-1px); border-color: rgba(216,200,167,.26); background: rgba(216,200,167,.075); box-shadow: 0 10px 24px rgba(0,0,0,.20); }
.btn:focus-visible { outline: 2px solid var(--champagne); outline-offset: 2px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn[disabled]:hover { transform: none; box-shadow: none; }
.btn-gold {
  color: #100f16; border-color: rgba(216,200,167,.48); background: linear-gradient(180deg, #f5efe3, #cdbf9f);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.68), 0 10px 26px rgba(216,200,167,.10);
}
.btn-gold:hover { color: #050509; background: linear-gradient(180deg, #fff8ee, #d8c8a7); }
.btn-secondary { color: var(--text-2); background: rgba(255,255,255,.028); }
.btn-secondary:hover { color: var(--text-0); background: rgba(255,255,255,.06); box-shadow: none; }
.btn-block { width: 100%; min-height: 48px; font-size: 13px; }

/* ========= PILLS (quote status) ========= */
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: var(--radius-pill); font-size: 11px; font-weight: 600; border: 1px solid var(--line-1); color: var(--text-1); background: var(--surface-1); }
.pill-draft { color: var(--text-2); }
.pill-sent, .pill-viewed { color: var(--blue); border-color: rgba(157,183,232,.3); background: rgba(157,183,232,.08); }
.pill-accepted, .pill-delivered { color: var(--good); border-color: rgba(134,217,163,.3); background: rgba(134,217,163,.08); }
.pill-in_production { color: var(--warn); border-color: rgba(225,191,114,.3); background: rgba(225,191,114,.08); }
.pill-lost, .pill-superseded { color: var(--bad); border-color: rgba(226,138,143,.3); background: rgba(226,138,143,.08); }

/* ========= FORMS ========= */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 11px; font-weight: 600; color: var(--text-3); }
input, select, textarea {
  width: 100%; min-height: 44px; padding: 0 14px; color: var(--text-0); font-family: inherit; font-size: 14px;
  background: rgba(0,0,0,.22); border: 1px solid var(--line-0); border-radius: var(--radius-sm); outline: none;
  transition: border-color .2s var(--ease), background .2s var(--ease), box-shadow .2s var(--ease);
}
textarea { min-height: 96px; padding: 12px 14px; resize: vertical; }
input::placeholder { color: var(--text-3); }
input:focus, select:focus, textarea:focus { border-color: rgba(216,200,167,.50); background: rgba(255,255,255,.044); box-shadow: 0 0 0 4px rgba(216,200,167,.075); }
input:-webkit-autofill { -webkit-text-fill-color: var(--text-0); -webkit-box-shadow: 0 0 0 1000px var(--bg-2) inset; caret-color: var(--text-0); }
.alert { padding: 10px 12px; border-radius: var(--radius-xs); font-size: 13px; margin: 0 0 14px; border: 1px solid; }
.alert-bad { color: var(--bad); border-color: rgba(226,138,143,.3); background: rgba(226,138,143,.08); }
.alert-good { color: var(--good); border-color: rgba(134,217,163,.3); background: rgba(134,217,163,.08); }

/* ========= CARDS: HEADS, TABLES, TOKENS ========= */
.card-head { margin-bottom: 16px; }
.card-head .muted { margin-top: 4px; font-size: 13px; max-width: 72ch; }
code { font-family: "SF Mono", Menlo, Consolas, monospace; font-size: 12px; color: var(--champagne); }
.table { width: 100%; border-collapse: collapse; font-size: 13px; margin: 0 0 18px; }
.table th { text-align: left; font-size: 11px; font-weight: 600; color: var(--text-3); padding: 0 12px 10px 0; border-bottom: 1px solid var(--line-0); }
.table td { padding: 11px 12px 11px 0; border-bottom: 1px solid var(--line-0); vertical-align: middle; color: var(--text-1); }
.table tr:last-child td { border-bottom: 0; }
.table tr.is-revoked td { color: var(--text-3); }
.table .row-actions { text-align: right; padding-right: 0; white-space: nowrap; }
.table .btn { min-height: 32px; padding: 0 12px; font-size: 11px; }
.token-form { display: grid; grid-template-columns: minmax(200px, 1fr) minmax(220px, 1.2fr) auto; gap: 14px; align-items: end; padding-top: 4px; }
.token-form .field { margin-bottom: 0; }
.token-form .btn { min-height: 44px; }
.token-plain { display: flex; gap: 12px; align-items: center; padding: 14px 16px; margin: 0 0 16px; background: rgba(0,0,0,.28); border: 1px solid var(--line-2); border-radius: var(--radius-sm); }
.token-plain code { flex: 1; word-break: break-all; font-size: 13px; color: var(--text-0); }
.alert strong { color: inherit; }
@media (max-width: 720px) { .token-form { grid-template-columns: 1fr; } #tokens-list .table th:nth-child(3), #tokens-list .table td:nth-child(3) { display: none; } }

/* ========= SUPPLIERS (price sheets) ========= */
.tiny { font-size: 11px; color: var(--text-3); }
h3 { font-size: 13px; font-weight: 600; color: var(--text-2); }
.page-suppliers, .page-catalog, .page-clients, .page-quotes, .page-builder, .page-po-list { font-variant-numeric: tabular-nums; }
.page-suppliers .head, .page-catalog .head, .page-clients .head, .page-quotes .head, .page-builder .head, .page-po-list .head, .page-settings .head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 24px; margin: 8px 0 18px; }
.page-suppliers .head .muted, .page-catalog .head .muted, .page-clients .head .muted, .page-quotes .head .muted, .page-builder .head .muted, .page-po-list .head .muted, .page-settings .head .muted { margin-top: 6px; font-size: 14px; max-width: 64ch; }
.head-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.mult { display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 14px; border: 1px solid var(--line-2); border-radius: var(--radius-pill); background: rgba(216,200,167,.06); }
.mult label { font-size: 12px; font-weight: 600; color: var(--champagne); white-space: nowrap; }
.mult input { width: 78px; min-height: 32px; padding: 0 8px; text-align: center; font-weight: 600; border-radius: var(--radius-pill); }
.mult select { width: auto; min-height: 32px; font-size: 12.5px; padding: 0 30px 0 12px; border-radius: var(--radius-pill); }
.page-suppliers select, .page-catalog select, .page-clients select, .page-quotes select, .page-builder select, .page-po-list select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 16px) 50%, calc(100% - 11px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 30px; }
.page-suppliers input, .page-suppliers select, .page-suppliers textarea, .page-catalog input, .page-catalog select, .page-catalog textarea, .page-clients input, .page-clients select, .page-clients textarea, .page-quotes input, .page-quotes select, .page-builder input, .page-builder select, .page-builder textarea, .page-po-list input, .page-po-list select { min-height: 38px; padding: 0 12px; font-size: 13.5px; border-radius: var(--radius-xs); }
.page-suppliers textarea, .page-catalog textarea, .page-clients textarea, .page-builder textarea { min-height: 64px; padding: 9px 12px; }
.page-suppliers input[type=number], .page-catalog input[type=number] { -moz-appearance: textfield; }
.page-suppliers input[type=number]::-webkit-inner-spin-button, .page-catalog input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; }
.page-suppliers .field, .page-catalog .field, .page-clients .field, .page-quotes .field, .page-builder .field, .page-po-list .field { margin-bottom: 0; }
.page-suppliers .field label, .page-catalog .field label, .page-clients .field label, .page-quotes .field label, .page-builder .field label, .page-po-list .field label { margin-bottom: 5px; }
.money, .pct { position: relative; }
.money input { padding-left: 24px; }
.pct input { padding-right: 28px; }
.money::before { content: "$"; position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); font-size: 13px; pointer-events: none; }
.pct::after { content: "%"; position: absolute; right: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); font-size: 13px; pointer-events: none; }
.note { padding: 12px 14px; border-radius: var(--radius-xs); background: rgba(216,200,167,.07); border: 1px solid var(--line-2); color: var(--text-1); font-size: 13px; line-height: 1.5; margin: 0 0 16px; }
.note b { color: var(--champagne); }
.layout { display: grid; grid-template-columns: 300px 1fr; gap: 18px; align-items: start; }
@media (max-width: 980px) { .layout { grid-template-columns: 1fr; } }
.side { padding: 10px; position: sticky; top: 92px; max-height: calc(100vh - 110px); overflow-y: auto; }
.side-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 12px; }
.sup { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 12px 12px; border-radius: var(--radius-xs); cursor: pointer; color: var(--text-1); }
.sup:hover { background: var(--surface-1); color: var(--text-0); }
.sup.on { background: rgba(216,200,167,.10); color: var(--text-0); outline: 1px solid var(--line-2); }
.sup b { font-weight: 600; font-size: 13.5px; }
.sup .sub { grid-column: 1 / -1; font-size: 12px; color: var(--text-3); }
.review-dot { display: inline-block; width: 6px; height: 6px; margin: 0 4px 1px 0; border-radius: 50%; background: var(--warn); }
.pill-review { color: var(--warn); border-color: rgba(225,191,114,.3); background: rgba(225,191,114,.08); }
.pill-alibaba { color: var(--warn); border-color: rgba(225,191,114,.3); background: rgba(225,191,114,.08); }
.pill-direct { color: var(--good); border-color: rgba(134,217,163,.3); background: rgba(134,217,163,.08); }
.pill-agent { color: var(--blue); border-color: rgba(157,183,232,.3); background: rgba(157,183,232,.08); }
.panel { padding: 22px 24px; }
.panel + .panel { margin-top: 16px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-title { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.panel-actions { display: flex; gap: 8px; flex-shrink: 0; }
.save-state { min-width: 48px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px 14px; }
.grid .wide { grid-column: 1 / -1; }
.btn-sm { min-height: 30px; padding: 0 11px; font-size: 11.5px; }
.btn-danger:hover { color: var(--bad); border-color: rgba(226,138,143,.35); background: rgba(226,138,143,.08); }
.sheet { background: var(--surface-1); border: 1px solid var(--line-1); border-radius: var(--radius-sm); padding: 16px 18px; }
.sheet + .sheet { margin-top: 12px; }
.sheet-top { display: grid; grid-template-columns: 1fr 110px 150px auto; gap: 10px; align-items: end; margin-bottom: 12px; }
.sheet-top .field:first-child input { font-weight: 600; font-size: 15px; }
.sheet-flags { display: flex; align-items: center; gap: 8px; padding-bottom: 2px; }
@media (max-width: 720px) { .sheet-top { grid-template-columns: 1fr 1fr; } .sheet-top .field:first-child { grid-column: 1 / -1; } }
.tiers { width: 100%; border-collapse: collapse; margin: 6px 0 4px; }
.tiers th { text-align: left; font-size: 11px; font-weight: 600; color: var(--text-3); padding: 6px 8px; border-bottom: 1px solid var(--line-0); }
.tiers th.r, .tiers td.r, .table th.r, .table td.r { text-align: right; }
.tiers td { padding: 5px 8px; border-bottom: 1px solid var(--line-0); vertical-align: middle; }
.tiers td input { min-height: 34px; }
.tiers td.r { font-size: 14px; white-space: nowrap; }
.tiers td.price { font-weight: 700; color: var(--cream); font-size: 15px; }
.m-good { color: var(--good); } .m-warn { color: var(--warn); } .m-bad { color: var(--bad); }
.tiers .x { width: 34px; text-align: center; }
.x button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line-0); background: transparent; color: var(--text-3); cursor: pointer; font: inherit; }
.x button:hover { color: var(--bad); border-color: rgba(226,138,143,.4); }
.sheet-foot { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin-top: 10px; }
.sheet-foot .tiny { flex: 1 1 260px; }
.calc-sample { color: var(--cream); font-weight: 600; }
.pay-table td { font-size: 13px; }
.pay-table td:first-child { white-space: nowrap; }
.pay-form .note-field { grid-column: span 2; }
.pay-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px 14px; align-items: end; }
.pay-form .btn { min-height: 38px; }
.report { margin: 0; padding: 14px 16px; background: rgba(0,0,0,.28); border: 1px solid var(--line-0); border-radius: var(--radius-xs); font-family: "SF Mono", Menlo, Consolas, monospace; font-size: 12px; line-height: 1.55; color: var(--text-1); white-space: pre-wrap; max-height: 420px; overflow: auto; }
.import-panel { margin-bottom: 18px; }

/* ========= CLIENTS ========= */
#cli-search { width: 260px; min-height: 36px; border-radius: var(--radius-pill); padding: 0 16px; }
.new-panel { margin-bottom: 18px; border-color: var(--line-2); }
.panel-actions .btn-sm { min-height: 32px; }
.reach-links { display: inline-flex; gap: 8px; }

/* ========= QUOTES: LIST + BUILDER ========= */
.empty-hero { position: relative; padding: 78px 24px 70px; overflow: hidden; }
.empty-hero::before {          /* a pool of light under the button — the page's own gradient, focused */
  content: ""; position: absolute; left: 50%; top: 58%; width: 560px; height: 320px; transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(216,200,167,.13), rgba(125,103,200,.07) 45%, transparent 70%);
  pointer-events: none;
}
.empty-hero > * { position: relative; }
.empty-hero h2 { font-family: "Instrument Serif", Georgia, serif; font-weight: 400; font-size: 30px; letter-spacing: -.01em; margin-bottom: 10px; }
.empty-hero .muted { max-width: 46ch; margin: 0 auto; font-size: 14.5px; line-height: 1.6; }
.empty-hero .hero-fine { margin-top: 18px; color: var(--text-3); }
/* The "start a quote" moment: an aurora ring (champagne → lavender → violet) turning slowly behind
   the button, a blurred copy of it as the glow, five glints that twinkle at rest and burst on hover,
   a sheen across the face on hover. All CSS; reduced-motion gets the plain button. */
/* ========= "Start a quote" — the hero CTA (built in Astra, wired in here) =========
   Layered pill: a conic aurora rotating inside a blurred mask (the glow) and a crisp
   1.5px copy of it (the edge), a cream face with its own sheen, three ambient glints,
   and a star burst on click built in JS. All motion is transform/opacity. Tokens are
   the app's own — the palette never leaves champagne → lavender → violet → cream. */
.quote-cta {
  --duration: 420ms;
  --ease-cta: cubic-bezier(.2, .8, .2, 1);
  --lift: 0px;
  --scale: 1;
  --aura-opacity: .36;
  --aura-scale: 1;
  --edge-opacity: .42;
  --polish-opacity: 0;
  --label-scale: 1;
  --arrow-x: 0px;

  position: relative; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; gap: 15px;
  box-sizing: border-box; min-width: 244px; height: 62px; margin-top: 36px; padding: 0 38px;
  border: 0; border-radius: 999px; background: transparent; color: #100f16;
  font: 600 16px/1 "Inter", sans-serif; letter-spacing: -.015em; white-space: nowrap;
  cursor: pointer; appearance: none; -webkit-appearance: none;
  -webkit-tap-highlight-color: transparent; touch-action: manipulation;
  transform: translateY(var(--lift)) scale(var(--scale));
  transition: transform var(--duration) var(--ease-cta);
}
.quote-cta *, .quote-cta *::before, .quote-cta *::after { box-sizing: border-box; pointer-events: none; }

.quote-cta__aura, .quote-cta__edge {
  position: absolute; inset: -5px; z-index: 0; overflow: hidden; border-radius: inherit;
  opacity: var(--aura-opacity); filter: blur(16px); transform: scale(var(--aura-scale));
  transition: opacity var(--duration) var(--ease-cta), transform var(--duration) var(--ease-cta);
}
.quote-cta__aura::before, .quote-cta__edge::before {
  content: ""; position: absolute; width: 340px; height: 340px; left: calc(50% - 170px); top: calc(50% - 170px);
  background: conic-gradient(from 35deg, var(--champagne), var(--lavender) 25%, var(--violet) 46%, var(--lavender) 60%, var(--cream) 78%, var(--champagne));
  animation: quote-orbit 18s linear infinite;
}
.quote-cta__edge { inset: -1px; opacity: var(--edge-opacity); filter: blur(1.5px); transform: none; }

.quote-cta__face {
  position: absolute; inset: 0; z-index: 1; overflow: hidden; border-radius: inherit;
  background: linear-gradient(112deg, var(--cream) 7%, var(--champagne) 75%, var(--cream) 150%);
  box-shadow: inset 0 1px 0 rgba(251,250,247,.78), inset 0 -2px 1px rgba(216,200,167,.65), 0 9px 22px rgba(7,7,11,.38);
}
.quote-cta__face::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: linear-gradient(105deg, var(--cream), transparent 80%);
  opacity: var(--polish-opacity); transition: opacity var(--duration) var(--ease-cta);
}
.quote-cta__sheen {
  position: absolute; width: 72px; height: 160px; left: calc(50% - 36px); top: calc(50% - 80px);
  background: linear-gradient(90deg, transparent, rgba(251,250,247,.6) 50%, transparent);
  opacity: 0; transform: translateX(-190px) rotate(24deg);
}
.quote-cta__press-light {
  position: absolute; inset: -9px; z-index: 0; border-radius: inherit;
  background: var(--cream); filter: blur(16px); opacity: 0;
}
.quote-cta__label, .quote-cta__arrow { position: relative; z-index: 2; transition: transform var(--duration) var(--ease-cta); }
.quote-cta__label { transform: scaleX(var(--label-scale)); }
.quote-cta__arrow { display: block; width: 19px; height: 19px; flex: 0 0 19px; transform: translateX(var(--arrow-x)); }

.quote-cta__glint {
  position: absolute; z-index: 0; width: 7px; height: 7px; background: var(--cream);
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
  opacity: 0; animation: quote-glint 8.4s ease-in-out infinite;
}
.quote-cta__glint--one   { left: 26px; top: -14px; animation-delay: -1s; }
.quote-cta__glint--two   { right: -16px; top: 34px; width: 5px; height: 5px; background: var(--lavender); animation-delay: -3.8s; }
.quote-cta__glint--three { right: 54px; bottom: -15px; width: 6px; height: 6px; background: var(--champagne); animation-delay: -6.6s; }

/* Click stars can leave the pill without creating page overflow. */
.quote-cta__stars {
  position: absolute; z-index: 3; left: 50%; top: 50%;
  width: min(660px, calc(100vw - 32px)); height: 340px; overflow: hidden; transform: translate(-50%, -50%);
}
.quote-cta__burst { position: absolute; inset: 0; }
.quote-cta__star {
  position: absolute; left: calc(50% - var(--star-size) / 2); top: calc(50% - var(--star-size) / 2);
  width: var(--star-size); height: var(--star-size); opacity: 0; filter: drop-shadow(0 0 4px currentColor);
  animation: quote-star-flight var(--star-time) cubic-bezier(.16, .7, .25, 1) var(--star-delay) both;
}
.quote-cta__star::before {
  content: ""; position: absolute; inset: 0; background: currentColor;
  clip-path: polygon(50% 0, 62% 37%, 100% 50%, 62% 63%, 50% 100%, 38% 63%, 0 50%, 38% 37%);
}

@media (hover: hover) and (pointer: fine) {
  .quote-cta:hover {
    --lift: -3px; --scale: 1.035; --aura-opacity: .68; --aura-scale: 1.085;
    --edge-opacity: .66; --polish-opacity: .34; --label-scale: 1.015; --arrow-x: 4px;
  }
  .quote-cta:hover .quote-cta__sheen { animation: quote-sheen 850ms var(--ease-cta) both; }
}
.quote-cta:focus-visible { outline: 2px solid var(--champagne); outline-offset: 7px; }
.quote-cta:active {
  --duration: 120ms; --lift: 1px; --scale: .97; --aura-opacity: .78;
  --aura-scale: 1.025; --polish-opacity: .18; --label-scale: 1; --arrow-x: 2px;
}
.quote-cta:active .quote-cta__press-light { animation: quote-press 460ms ease-out both; }

@keyframes quote-orbit { to { transform: rotate(360deg); } }
@keyframes quote-glint {
  0%, 32%, 100% { opacity: 0; transform: scale(.55) rotate(-12deg); }
  15% { opacity: .65; transform: scale(1) rotate(0deg); }
}
@keyframes quote-sheen {
  0% { opacity: 0; transform: translateX(-190px) rotate(24deg); }
  18% { opacity: .75; }
  70% { opacity: .5; }
  100% { opacity: 0; transform: translateX(190px) rotate(24deg); }
}
@keyframes quote-press {
  0% { opacity: 0; transform: scale(.96); }
  25% { opacity: .34; }
  100% { opacity: 0; transform: scale(1.09); }
}
@keyframes quote-star-flight {
  0% { opacity: 0; transform: translate3d(var(--star-from-x), var(--star-from-y), 0) rotate(-25deg) scale(.2); }
  12%, 45% { opacity: 1; }
  35% { transform: translate3d(calc(var(--star-to-x) * .82), calc(var(--star-to-y) * .82), 0) rotate(10deg) scale(1.1); }
  100% { opacity: 0; transform: translate3d(var(--star-to-x), var(--star-to-y), 0) rotate(var(--star-turn)) scale(.45); }
}

@media (prefers-reduced-motion: reduce) {
  .quote-cta, .quote-cta:hover, .quote-cta:active {
    --duration: 160ms; --scale: 1; --aura-opacity: .22; --aura-scale: 1;
    --edge-opacity: .3; --polish-opacity: 0; --label-scale: 1; --arrow-x: 0px;
  }
  .quote-cta *, .quote-cta *::before, .quote-cta *::after { animation: none !important; transition: none !important; }
  .quote-cta__glint, .quote-cta__sheen, .quote-cta__press-light, .quote-cta__stars { display: none; }
  @media (hover: hover) and (pointer: fine) { .quote-cta:hover { --lift: -2px; } }
  .quote-cta:active { --lift: 0px; }
}
@media (forced-colors: active) {
  .quote-cta { color: ButtonText; background: ButtonFace; border: 2px solid ButtonText; }
  .quote-cta__aura, .quote-cta__edge, .quote-cta__face, .quote-cta__glint, .quote-cta__press-light, .quote-cta__stars { display: none; }
  .quote-cta:focus-visible { outline-color: Highlight; }
}

.quotes-table .row-link { cursor: pointer; }
.quotes-table .row-link:hover td { background: var(--surface-1); }
.quotes-table td b { color: var(--text-0); }
.quotes-table .c-title, .quotes-table .c-client { max-width: 22ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Desktop PO list: Paid is right-aligned and Ship by left-aligned, so they touched — give the date room. */
@media (min-width: 561px) { .po-table td.c-valid, .po-table th:nth-child(7) { padding-left: 28px; } }
/* Phones: eight columns can't fit, and a wide table drags the whole page
   sideways. Each row becomes a card — number and status on top, then the
   client, then the two numbers she's scanning for. */
@media (max-width: 560px) {
  .quotes-table, .quotes-table tbody, .quotes-table tr, .quotes-table td { display: block; width: auto; }
  .quotes-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
  .quotes-table tr {
    position: relative; padding: 14px 15px 13px; margin-bottom: 10px;
    background: var(--surface-1); border: 1px solid var(--line-0); border-radius: var(--radius-sm);
  }
  .quotes-table tr:last-child { margin-bottom: 0; }
  .quotes-table td { padding: 0; border: 0; }
  .quotes-table .c-num { font-size: 14px; padding-right: 92px; }
  .quotes-table .c-status { position: absolute; top: 12px; right: 13px; }
  .quotes-table .c-client { margin-top: 3px; max-width: none; font-size: 13px; color: var(--text-1); }
  .quotes-table .c-title { max-width: none; white-space: normal; font-size: 12px; color: var(--text-3); }
  .quotes-table .c-title:empty { display: none; }
  .quotes-table .c-total, .quotes-table .c-due {
    display: inline-block; margin: 10px 18px 0 0; text-align: left;
    font-size: 15px; font-weight: 600; color: var(--text-0);
  }
  .quotes-table .c-total::before, .quotes-table .c-due::before,
  .quotes-table .c-valid::before {
    content: attr(data-label); display: block;
    font-size: 10px; font-weight: 500; color: var(--text-3); letter-spacing: .02em;
  }
  .quotes-table .c-valid { display: inline-block; margin: 10px 0 0; font-size: 12px; color: var(--text-2); }
  .quotes-table td.c-total, .quotes-table td.c-due { text-align: left; }   /* beat .table td.r — label and value line up */
  .quotes-table .c-updated { display: none; }   /* least useful line on a phone */
  /* List pages: view switch + New button on their own row under the intro; the status filter (List view)
     or the search (Clients) takes a full row of its own below them */
  .page-quotes .head-actions, .page-po-list .head-actions, .page-clients .head-actions { margin-left: 0; width: 100%; flex-wrap: wrap; }
  .page-quotes .head-actions .btn, .page-po-list .head-actions .btn, .page-clients .head-actions .btn { flex: 0 0 auto; margin-left: auto; }
  .page-quotes .head-actions select, .page-po-list .head-actions select, .page-clients .head-actions input[type=search] { order: 3; flex: 1 1 100%; width: 100%; min-width: 0; }
  .quotes-table .row-link:hover td { background: transparent; }
}
.qb-head { align-items: flex-start; }
.qb-crumbs { font-size: 13px; color: var(--text-2); display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.qb-crumbs a { color: var(--text-2); text-decoration: none; }
.qb-crumbs a:hover { color: var(--text-0); }
.qb-crumbs b { color: var(--text-0); }
.page-builder h1 { margin: 0; }
.page-builder .title-input { width: min(640px, 100%); min-height: 44px; padding: 0 4px; font-family: "Instrument Serif", Georgia, serif; font-size: 30px; letter-spacing: -0.01em; background: transparent; border: 1px solid transparent; border-radius: var(--radius-xs); color: var(--text-0); }
.page-builder .title-input:hover { border-color: var(--line-0); }
.page-builder .title-input:focus { background: rgba(0,0,0,.22); border-color: rgba(216,200,167,.5); box-shadow: none; }
.builder-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
@media (max-width: 1080px) { .builder-layout { grid-template-columns: 1fr; } }
.builder-side { position: sticky; top: 92px; }
.line { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding: 16px 18px; background: var(--surface-1); border: 1px solid var(--line-1); border-radius: var(--radius-sm); }
.line + .line { margin-top: 12px; }
.line-img { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.thumb { display: flex; align-items: center; justify-content: center; width: 96px; height: 96px; border-radius: var(--radius-xs); border: 1px solid var(--line-1); background: rgba(0,0,0,.28); overflow: hidden; cursor: pointer; }
.thumb.empty { border-style: dashed; padding: 0; }   /* not the generic .empty state's 56px padding — that stretched the box */
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.line-img a { color: var(--champagne); }
.line-fields { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 12px; }
.line-fields .wide2 { grid-column: span 2; }
.line-fields .wide { grid-column: 1 / -1; }
@media (max-width: 860px) { .line-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); } .line-fields .wide2 { grid-column: span 2; } }
.line-fields .price { font-weight: 700; color: var(--cream); font-size: 15px; min-height: 38px; display: flex; align-items: center; }
.line-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; }
.size-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.size-cell { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 11px; color: var(--text-3); }
.size-cell input { width: 62px; text-align: center; padding: 0 6px; }
.add-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px 14px; align-items: end; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-0); }
@media (max-width: 720px) { .add-row { grid-template-columns: 1fr; } }
/* Flex, not a fixed grid: a design charge has one field more than the others (days + amount),
   and a 7th cell in a 6-column grid wrapped underneath and collided with the labels. */
.charge { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 12px 0; border-top: 1px solid var(--line-0); }
.charge:first-of-type { border-top: 0; padding-top: 0; }
/* only the label grows; the rest keep their size so a wrapped field never stretches across the row */
.charge .field { flex: 0 1 148px; min-width: 128px; }
.charge .field.wide2 { flex: 1 1 200px; min-width: 160px; }
.charge .field.tight { flex: 0 1 116px; min-width: 104px; }
.charge .field.kind { flex: 0 1 136px; min-width: 132px; }
.charge .price .tiny { font-weight: 400; }
.charge .field.act { flex: 0 0 auto; min-width: 0; }
.charge .price { font-weight: 700; color: var(--cream); min-height: 38px; display: flex; align-items: center; justify-content: flex-end; }
@media (max-width: 720px) { .charge .field, .charge .field.wide2, .charge .field.tight { flex: 1 1 100%; } }
.page-builder input[disabled], .page-builder select[disabled], .page-builder textarea[disabled] { color: var(--text-2); background: rgba(0,0,0,.12); border-color: transparent; cursor: default; }
.page-builder .is-frozen .panel-head .tiny { color: var(--warn); }
.thumb.locked { cursor: default; border-style: solid; }
.terms-preview { margin-top: 10px; padding: 12px 14px; background: rgba(0,0,0,.22); border: 1px solid var(--line-0); border-radius: var(--radius-xs); }
.terms-preview ul { margin: 6px 0 0; padding-left: 18px; font-size: 13px; color: var(--text-1); line-height: 1.5; }
.terms-preview li { margin: 3px 0; }
.terms-preview li::marker { color: var(--text-3); }
.track { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.track-step { padding: 10px 12px; border-radius: var(--radius-xs); background: rgba(255,255,255,.028); border: 1px solid var(--line-0); color: var(--text-3); }
.track-step b { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 2px; }
.track-step.done { color: var(--text-1); border-color: rgba(134,217,163,.28); background: rgba(134,217,163,.06); }
.track-step.done b { color: var(--good); }
.track-step.now { outline: 1px solid var(--line-2); }
@media (max-width: 860px) { .track { grid-template-columns: repeat(2, 1fr); } }
.totals h2 { margin-bottom: 12px; }
.trow { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 6px 0; font-size: 13.5px; color: var(--text-1); }
.trow b { font-weight: 600; color: var(--text-0); }
.trow.total b { font-size: 16px; }
.trow.due { padding: 10px 12px; margin: 4px -12px; border-radius: var(--radius-xs); background: rgba(216,200,167,.10); border: 1px solid var(--line-2); }
.trow.due b { font-size: 20px; line-height: 1.2; color: var(--cream); }
.trow b .tiny { font-size: 12px; font-weight: 500; color: var(--text-2); }   /* "of $884.50" / the paid amount next to Paid ✓ */
.trow.internal { color: var(--text-2); font-size: 12.5px; }
.trow.internal b { color: var(--text-1); font-weight: 500; }
.tsep { height: 1px; background: var(--line-0); margin: 8px 0; }
.warn { padding: 9px 11px; margin-top: 8px; border-radius: var(--radius-xs); font-size: 12.5px; line-height: 1.45; border: 1px solid var(--line-0); color: var(--text-1); background: var(--surface-1); }
.warn-bad { color: var(--bad); border-color: rgba(226,138,143,.3); background: rgba(226,138,143,.08); }
.warn-warn { color: var(--warn); border-color: rgba(225,191,114,.3); background: rgba(225,191,114,.08); }
.warn-good { color: var(--good); border-color: rgba(134,217,163,.3); background: rgba(134,217,163,.08); }
.warn-info { color: var(--text-2); }

/* ========= CATALOG ========= */
/* Grid view — the product showcase (built in Astra, wired in here).
   One native <button> per card, no nested interactive elements, so the whole
   card is clickable and keyboard-reachable. Tokens are the app's own. */
.viewswitch { display: inline-flex; padding: 3px; border: 1px solid var(--line-1); border-radius: var(--radius-pill); background: var(--surface-1); }
.viewswitch button {
  min-height: 32px; padding: 0 16px; border: 0; border-radius: var(--radius-pill); background: transparent;
  color: var(--text-2); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer;
  transition: background .2s var(--ease), color .2s var(--ease);
}
.viewswitch button:hover { color: var(--text-0); }
.viewswitch button.on { background: var(--champagne); color: #100f16; }

.category + .category { margin-top: 26px; }
.category-heading { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.category-heading h2 { margin: 0; font-size: 12px; font-weight: 550; line-height: 20px; color: var(--text-1); }
.category-count { min-width: 21px; text-align: center; font-size: 10px; line-height: 19px; border: 1px solid var(--line-0); border-radius: 6px; color: var(--text-2); }
.category-rule { flex: 1; height: 1px; background: var(--line-0); margin-left: 6px; }

.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; align-items: stretch; }
.product-card {
  position: relative; display: flex; flex-direction: column; flex: 1;
  width: 100%; min-width: 0; padding: 0; appearance: none; -webkit-appearance: none;
  border: 1px solid var(--line-0); border-radius: var(--radius-sm);
  background: var(--bg-1); color: var(--text-0); text-align: left;
  font: inherit; font-variant-numeric: tabular-nums;
  cursor: pointer; touch-action: manipulation;
  transition: transform 180ms ease, box-shadow 180ms ease;
  -webkit-tap-highlight-color: transparent;
}
.product-media { position: relative; display: block; aspect-ratio: 4/3; flex-shrink: 0; overflow: hidden; border-radius: 11px 11px 0 0; background: var(--bg-2); }
.product-photo { display: block; width: 100%; height: 100%; object-fit: cover; }
.photo-placeholder { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 12px; width: 100%; height: 100%; background: var(--bg-2); }
.placeholder-art { width: 78px; height: 78px; color: var(--lavender); stroke: currentColor; stroke-width: 1.15; stroke-linecap: round; stroke-linejoin: round; opacity: .55; fill: none; }
.placeholder-orbit { stroke: var(--line-1); stroke-dasharray: 2 5; }
.placeholder-label { font-size: 10px; color: var(--text-2); }
.review-marker {
  position: absolute; top: 10px; right: 10px; display: flex; align-items: center; gap: 6px;
  padding: 5px 8px; border: 1px solid rgba(225,191,114,.22);
  border-radius: var(--radius-pill); color: var(--warn); background: var(--bg-1);
  font-size: 9px; font-weight: 500; line-height: 12px; white-space: nowrap;
}
.review-dot { width: 4px; height: 4px; border-radius: 50%; flex-shrink: 0; background: var(--warn); }
.edit-cue {
  position: absolute; right: 10px; bottom: 10px; display: grid; place-items: center;
  width: 28px; height: 28px; border: 1px solid var(--line-1); border-radius: var(--radius-xs);
  background: var(--bg-1); color: var(--champagne); opacity: 0; transform: translateY(4px);
  transition: opacity 180ms ease, transform 180ms ease;
}
.edit-cue svg { width: 15px; height: 15px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.product-content { display: flex; flex-direction: column; flex: 1; min-width: 0; padding: 15px 15px 14px; background: var(--surface-1); border-radius: 0 0 11px 11px; }
.product-name { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; font-size: 13px; line-height: 19px; font-weight: 550; letter-spacing: -.02em; color: var(--text-0); }
.product-detail { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; margin-top: 6px; font-size: 11px; line-height: 16px; color: var(--text-2); }
.product-supplier { display: flex; align-items: center; gap: 5px; min-width: 0; margin: 13px 0 14px; font-size: 10px; line-height: 15px; color: var(--text-2); }
.product-supplier svg { width: 12px; height: 12px; flex: 0 0 12px; stroke: currentColor; stroke-width: 1.15; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.product-supplier > span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; min-width: 0; }
.supplier-missing svg { opacity: .6; }
.product-footer { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 13px; border-top: 1px solid var(--line-0); }
.price-block, .margin-block { display: flex; flex-direction: column; min-width: 0; }
.product-price { color: var(--cream); font-size: 20px; font-weight: 550; line-height: 25px; letter-spacing: -.055em; }
.price-missing { font-size: 13px; letter-spacing: -.01em; color: var(--text-2); font-weight: 400; }
.price-qualifier { font-size: 10px; line-height: 15px; color: var(--text-2); white-space: nowrap; }
.margin-block { align-items: flex-end; gap: 4px; flex-shrink: 0; }
.margin-badge { display: block; padding: 3px 8px; border-radius: var(--radius-pill); font-size: 11px; font-weight: 550; line-height: 16px; white-space: nowrap; border: 1px solid transparent; }
.margin-badge.m-good { color: var(--good); background: rgba(134,217,163,.09); border-color: rgba(134,217,163,.12); }
.margin-badge.m-warn { color: var(--warn); background: rgba(225,191,114,.09); border-color: rgba(225,191,114,.12); }
.margin-badge.m-bad  { color: var(--bad);  background: rgba(226,138,143,.09); border-color: rgba(226,138,143,.12); }
.margin-badge.m-none { color: var(--text-2); background: var(--surface-1); border-color: var(--line-0); font-weight: 400; }
.margin-label { font-size: 9px; line-height: 11px; color: var(--text-2); }
.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; }

@media (hover: hover) and (pointer: fine) {
  .product-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(7,7,11,.64), 0 0 0 1px var(--line-2); }
  .product-card:hover .edit-cue { opacity: 1; transform: translateY(0); }
}
.product-card:focus-visible { outline: 2px solid var(--champagne); outline-offset: 4px; }
.product-card:focus-visible .edit-cue { opacity: 1; transform: translateY(0); }
.product-card:active { transform: translateY(0); }

/* Phones: one column, card on its side — 5 items a screen instead of 1.5. */
@media (max-width: 560px) {
  .category-heading { margin-bottom: 12px; }
  .category + .category { margin-top: 18px; }
  .product-grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .product-card { flex-direction: row; align-items: stretch; }
  .product-media { width: 104px; height: 78px; aspect-ratio: 4/3; flex: 0 0 104px; border-radius: var(--radius-xs); margin: 10px 0 10px 10px; align-self: center; }
  .product-content { padding: 11px 12px; border-radius: 0 11px 11px 0; background: transparent; }
  .product-name { font-size: 12px; line-height: 16px; }
  .product-detail { font-size: 10px; line-height: 14px; margin-top: 3px; -webkit-line-clamp: 1; }
  .product-supplier { margin: 5px 0 7px; font-size: 9px; line-height: 12px; gap: 4px; }
  .product-supplier svg { width: 10px; height: 10px; flex-basis: 10px; }
  .product-footer { padding-top: 6px; gap: 6px; }
  .product-price { font-size: 16px; line-height: 19px; }
  .price-missing { font-size: 11px; }
  .price-qualifier { font-size: 8px; line-height: 12px; }
  .margin-badge { font-size: 10px; line-height: 14px; padding: 2px 6px; }
  .margin-block { gap: 2px; }
  .margin-label { font-size: 8px; line-height: 10px; }
  .review-marker { top: 5px; right: 5px; left: 5px; justify-content: center; padding: 3px 4px; font-size: 8px; gap: 4px; line-height: 10px; }
  .placeholder-art { width: 42px; height: 42px; }
  .photo-placeholder { gap: 3px; }
  .placeholder-label { font-size: 8px; }
  .edit-cue { width: 21px; height: 21px; right: 5px; bottom: 5px; border-radius: 5px; }
  .edit-cue svg { width: 12px; height: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .product-card, .product-card:hover, .product-card:active { transform: none; transition: none; }
  .edit-cue { transition: none; transform: none; }
}
@media (forced-colors: active) {
  .product-card { border-color: ButtonText; }
  .product-card:focus-visible { outline-color: Highlight; }
  .margin-badge, .review-marker { border-color: ButtonText; }
}


/* ========= LOGIN / STANDALONE PAGES ========= */
.page-login { display: grid; place-items: center; padding: 24px; }
.login { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 26px; }
.login-brand { text-align: center; font-weight: 700; letter-spacing: .14em; color: var(--champagne); }
.login-card { padding: 30px 28px; background: var(--surface-1); border-color: var(--line-1); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.login-card h1 { margin-bottom: 4px; }
.login-card .muted { margin-bottom: 20px; font-size: 14px; }
.login-card form { display: flex; flex-direction: column; }
.login-card .btn-block { margin-top: 6px; }
.login-card p.muted:last-child { margin: 16px 0 0; text-align: center; font-size: 13px; }

@media (max-width: 640px) {
  .topbar { gap: 12px; min-height: 64px; }
  .brand { min-width: 0; }
  .user-menu .btn { padding: 0 10px; }
  h1 { font-size: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .nav-link, .seg-indicator { transition: none; }
  .btn:hover { transform: none; }
}

/* ========= PHONES (2026-10-09) =========
   Vero runs the business from her phone. Rules of the road at phone width:
   nothing is ever wider than the screen (grid/flex children get min-width: 0,
   wide tables scroll inside their card instead of dragging the page), button
   rows wrap, every tab stays reachable, and form fields get the full width. */
.layout > *, .builder-main, .builder-side, .panel, .card { min-width: 0; }
.panel-actions { flex-wrap: wrap; }
.um-short { display: none; }
.page-builder .qb-head > div:first-child { flex: 1 1 360px; min-width: 0; }   /* the title takes the room, the buttons wrap */
@media (max-width: 720px) {
  .panel { padding: 18px 16px; }
  .panel-head { flex-wrap: wrap; }
  .panel-actions { flex-shrink: 1; }
  /* a price sheet / any data table scrolls sideways inside its own card */
  .tiers, .card .table:not(.quotes-table) { display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tiers td input { min-width: 84px; }
  .side { position: static; max-height: 46vh; }
  .builder-side { position: static; }
}
@media (max-width: 640px) {
  /* tabs get their own full-width row under the logo + account button, so all five are reachable */
  .topbar { flex-wrap: wrap; row-gap: 10px; padding-top: 10px; padding-bottom: 10px; }
  .nav-links { order: 3; flex: 1 1 100%; max-width: 100%; justify-content: space-between; }
  .nav-links { gap: 0; padding: 4px; }
  .nav-links .seg-indicator { top: 4px; left: 4px; height: calc(100% - 8px); }
  .nav-link { padding: 8px 7px; font-size: 12.5px; }   /* six tabs (POs, 2026-10-14) still fit 358px */
  .um-full { display: none; }
  .um-short { display: inline; }
}
@media (max-width: 560px) {
  .page-builder .title-input { width: 100%; font-size: 24px; }
  .page-builder .head.qb-head { flex-direction: column; align-items: stretch; gap: 12px; }
  .page-builder .qb-head .head-actions { margin-left: 0; }
  .page-builder .qb-head .head-actions .btn { flex: 1 1 auto; }
  /* a quote line: photo on top as a small strip, every field full width under it */
  .line { grid-template-columns: 1fr; gap: 12px; padding: 14px; }
  .line-img { flex-direction: row; align-items: center; gap: 12px; text-align: left; }
  .line .thumb { flex: 0 0 64px; width: 64px; height: 64px; min-height: 0; }
  .line-fields.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .line-fields.grid .wide2, .line-fields.grid .wide { grid-column: 1 / -1; }
  /* text fields get the full width; Size/Qty and Price/Total stay side by side */
  .line-fields.grid > .field:nth-child(1), .line-fields.grid > .field:nth-child(7),
  .line-fields.grid > .field:nth-child(9), .line-fields.grid > .field:nth-child(10) { grid-column: 1 / -1; }
  .track { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .sheet { padding: 14px 12px; }
  .charge .field, .charge .field.wide2, .charge .field.tight, .charge .field.kind { flex: 1 1 140px; min-width: 0; }
}

/* ========= Purchase orders (2026-10-14) ========= */
.po-span3 { grid-column: span 3; }
@media (max-width: 860px) { .po-span3 { grid-column: 1 / -1; } }
.po-title { font-size: 26px; }
.po-add { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.2fr) 90px auto; }
@media (max-width: 720px) { .po-add { grid-template-columns: 1fr; } }
.po-route { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line-0); }
.po-route select { width: auto; max-width: 52%; }
.po-mini td { cursor: pointer; }
.po-mini tr:hover td { background: var(--surface-1); }
@media (max-width: 560px) {
  .po-route { flex-direction: column; align-items: stretch; gap: 6px; }
  .po-route select { max-width: none; width: 100%; }
  /* the quote line's spans (nth-child) don't fit a PO line's fields: reset, then span the wide ones */
  .po-line .line-fields.grid > .field:nth-child(n) { grid-column: auto; }
  .po-line .line-fields.grid > .field.wide, .po-line .line-fields.grid > .field.wide2 { grid-column: 1 / -1; }
  .po-mini td:nth-child(5) { display: none; }
}
@media (max-width: 560px) {
  /* stacked head: the 360px flex-basis meant for the row became a 360px-tall gap above the buttons */
  .page-builder .qb-head > div:first-child { flex: 0 0 auto; }
}


/* ========= VIEWS: board, client cards, supplier cards (2026-10-14) ========= */
.head-actions .viewswitch { flex: 0 0 auto; }
.grid-count { margin: 0 0 12px; color: var(--text-3); }

/* ---- Board: a column per status. Desktop fits the columns on screen (scrolls sideways only if it
   must); phones get one column at a time with the next one peeking, swiped like the CRM's. ---- */
.kb { display: flex; flex-direction: column; gap: 14px; }
.kb-hint { margin: -4px 0 0; color: var(--text-3); }
.kb-hint-touch { display: none; }
@media (hover: none) and (pointer: coarse) { .kb-hint-fine { display: none; } .kb-hint-touch { display: inline; } }
.kb-cols {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(196px, 1fr); gap: 12px;
  overflow-x: auto; padding-bottom: 6px; align-items: start;
}
.kb-col {
  --col: rgba(255,255,255,.42); --glow: rgba(255,255,255,.04);
  position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 200px;
  border: 1px solid var(--line-0); border-radius: var(--radius-md); background: rgba(255,255,255,.022);
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.kb-col::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(circle at 50% 0%, var(--glow), transparent 62%); }
.kb-col-head { position: relative; display: flex; align-items: center; gap: 8px; padding: 13px 14px 11px; border-bottom: 1px solid var(--line-0); }
.kb-dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 7px; background: var(--col); box-shadow: 0 0 9px var(--col); }
.kb-col-name { flex: 1; min-width: 0; font-size: 10.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kb-col-count { font-size: 10.5px; font-weight: 650; color: var(--text-2); background: rgba(255,255,255,.06); padding: 2px 7px; border-radius: 999px; font-variant-numeric: tabular-nums; }
.kb-col-sum { font-size: 11px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.kb-col-body { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 10px; }   /* columns grow; the page scrolls */
.kb-empty { margin: 0; padding: 18px 6px; text-align: center; font-size: 11.5px; color: var(--text-3); border: 1px dashed transparent; border-radius: 12px; }
.kb-col.kb-over { border-color: var(--col); background: rgba(255,255,255,.045); }
.kb-col.kb-over .kb-empty { border-color: var(--line-1); color: var(--text-2); }

.kb-c-draft { --col: rgba(255,255,255,.42); }
.kb-c-sent { --col: var(--blue); --glow: rgba(157,183,232,.09); }
.kb-c-confirmed { --col: var(--lavender); --glow: rgba(185,176,212,.10); }
.kb-c-accepted { --col: var(--good); --glow: rgba(134,217,163,.10); }
.kb-c-in_production { --col: var(--warn); --glow: rgba(225,191,114,.09); }
.kb-c-shipped { --col: var(--teal); --glow: rgba(146,218,203,.09); }
.kb-c-delivered, .kb-c-received { --col: var(--teal); --glow: rgba(146,218,203,.10); }
.kb-c-received { --col: var(--good); --glow: rgba(134,217,163,.10); }
.kb-c-lost, .kb-c-cancelled { --col: var(--bad); --glow: rgba(226,138,143,.08); }
.kb-c-superseded { --col: rgba(255,255,255,.3); }

.kb-card {
  display: flex; flex-direction: column; gap: 5px; width: 100%; min-width: 0; padding: 11px 12px;
  appearance: none; -webkit-appearance: none; font: inherit; text-align: left; color: var(--text-1);
  border: 1px solid var(--line-0); border-radius: 12px; background: rgba(255,255,255,.04);
  cursor: pointer; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent;
  touch-action: pan-x pan-y; font-variant-numeric: tabular-nums;
  transition: border-color .15s var(--ease), background .15s var(--ease), opacity .15s var(--ease);
}
@media (hover: hover) and (pointer: fine) { .kb-card { cursor: grab; } .kb-card:hover { border-color: var(--line-1); background: rgba(255,255,255,.065); } }
.kb-card:focus-visible { outline: 2px solid var(--champagne); outline-offset: 2px; }
.kb-card-head { display: flex; align-items: flex-start; gap: 10px; min-width: 0; }
.kb-card-head b { flex: 1; min-width: 0; font-size: 13px; line-height: 17px; font-weight: 600; color: var(--text-0); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.kb-amt { flex: 0 0 auto; font-size: 13px; line-height: 17px; font-weight: 600; color: var(--cream); }
.kb-amt-tbc { font-size: 11px; font-weight: 500; color: var(--text-3); white-space: nowrap; }
.kb-card-sub { font-size: 11.5px; line-height: 16px; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.kb-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; min-width: 0; }
.kb-num { font-size: 10.5px; letter-spacing: .02em; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kb-flag { flex: 0 0 auto; font-size: 10px; font-weight: 550; color: var(--text-3); padding: 2px 7px; border-radius: 999px; border: 1px solid var(--line-0); white-space: nowrap; }
.kb-flag-seen { color: var(--blue); border-color: rgba(157,183,232,.25); background: rgba(157,183,232,.07); }
.kb-flag-good { color: var(--good); border-color: rgba(134,217,163,.22); background: rgba(134,217,163,.07); }
.kb-flag-warn { color: var(--warn); border-color: rgba(225,191,114,.25); background: rgba(225,191,114,.07); }
.kb-placeholder { opacity: .28; border-style: dashed; }
.kb-pending { opacity: .55; pointer-events: none; }
.kb-ghost {
  position: fixed; left: 0; top: 0; z-index: 1000; pointer-events: none; margin: 0;
  border-color: rgba(216,200,167,.5); background: #1b1926; box-shadow: var(--shadow-lg);
}
body.kb-dragging, body.kb-dragging * { cursor: grabbing !important; user-select: none; -webkit-user-select: none; }

.kb-closed { border: 1px solid var(--line-0); border-radius: var(--radius-md); background: rgba(255,255,255,.015); }
.kb-closed > summary {
  --col: var(--bad);
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; padding: 12px 16px; cursor: pointer; list-style: none;
  font-size: 10.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--text-2);
  border-radius: inherit; transition: background .2s var(--ease), box-shadow .2s var(--ease);
}
.kb-closed > summary::-webkit-details-marker { display: none; }
.kb-closed > summary::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid var(--text-3); border-bottom: 1.5px solid var(--text-3); transform: rotate(-45deg); transition: transform .2s var(--ease); }
.kb-closed[open] > summary::before { transform: rotate(45deg); }
.kb-closed-n { display: inline-flex; align-items: center; gap: 6px; letter-spacing: .02em; text-transform: none; font-weight: 550; font-size: 11.5px; color: var(--text-2); }
.kb-closed-drop { margin-left: auto; letter-spacing: 0; text-transform: none; font-weight: 400; color: var(--text-3); opacity: 0; transition: opacity .2s var(--ease); }
body.kb-dragging .kb-closed-drop { opacity: 1; }
.kb-closed > summary.kb-over { background: rgba(226,138,143,.07); box-shadow: inset 0 0 0 1px rgba(226,138,143,.4); }
.kb-closed-cols { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; padding: 0 12px 12px; }
.kb-closed-cols > .kb-empty { grid-column: 1 / -1; }

@media (max-width: 760px) {
  .kb-cols {
    grid-auto-columns: 84vw; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
    margin: 0 -16px; padding: 0 16px 8px; scroll-padding: 0 16px; scrollbar-width: none;
  }
  .kb-cols::-webkit-scrollbar { display: none; }
  .kb-col { scroll-snap-align: start; min-height: 0; }
  .kb-col-body { max-height: none; overflow: visible; }
  .kb-card { padding: 12px 13px; }
  .kb-card-head b, .kb-amt { font-size: 14px; }
}

/* ---- Toast ---- */
.toast {
  position: fixed; left: 50%; bottom: max(18px, env(safe-area-inset-bottom)); z-index: 1100; max-width: min(520px, calc(100vw - 32px));
  padding: 11px 16px; border-radius: 14px; border: 1px solid var(--line-1); background: rgba(22,20,32,.94);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: var(--shadow-md);
  color: var(--text-0); font-size: 13px; line-height: 18px; pointer-events: none;
  opacity: 0; transform: translate(-50%, 10px); transition: opacity .2s var(--ease), transform .25s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.bad { border-color: rgba(226,138,143,.4); color: #f3c9cb; }

/* ---- Contact cards (Clients → Grid) ---- */
.cc-grid, .sc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; align-items: stretch; }
.cc {
  position: relative; display: flex; flex-direction: column; gap: 14px; min-width: 0; padding: 16px;
  border: 1px solid var(--line-0); border-radius: var(--radius-sm); background: var(--surface-0);
  transition: border-color .18s ease, background .18s ease, transform .18s ease, box-shadow .18s ease;
}
.cc-top, .sc-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cc-avatar {
  --av: var(--champagne);
  display: grid; place-items: center; flex: 0 0 42px; width: 42px; height: 42px; border-radius: 50%;
  font-size: 14px; font-weight: 650; letter-spacing: .02em; color: var(--av);
  background: color-mix(in srgb, var(--av) 13%, transparent); border: 1px solid color-mix(in srgb, var(--av) 26%, transparent);
}
.av-lavender { --av: var(--lavender); } .av-blue { --av: var(--blue); } .av-teal { --av: var(--teal); } .av-rose { --av: #e6a9b5; }
.cc-id, .sc-id { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.cc-id h3 { margin: 0; font-size: 14.5px; font-weight: 600; line-height: 19px; letter-spacing: -.01em; }
.cc-open { all: unset; cursor: pointer; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-0); }
.cc-open::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }   /* the whole card opens the client */
.cc-open:focus-visible::after { outline: 2px solid var(--champagne); outline-offset: 3px; }
.cc-sub { font-size: 11.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cc-lang { flex: 0 0 auto; font-size: 10px; font-weight: 650; letter-spacing: .06em; color: var(--text-3); padding: 2px 6px; border: 1px solid var(--line-0); border-radius: 6px; }
.cc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line-0); min-height: 47px; align-items: center; }
.cc-reach {
  position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 0 12px;
  border: 1px solid var(--line-1); border-radius: var(--radius-pill); background: var(--surface-1);
  color: var(--text-1); font-size: 12px; font-weight: 550; text-decoration: none; -webkit-tap-highlight-color: transparent;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.cc-reach svg, .sc-fact svg, .sc-loc svg { width: 15px; height: 15px; flex: 0 0 15px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.cc-reach:hover { color: var(--text-0); border-color: var(--line-2); background: var(--surface-2); }
.cc-wa { color: var(--good); border-color: rgba(134,217,163,.28); background: rgba(134,217,163,.07); }
.cc-wa:hover { color: #a9e8be; border-color: rgba(134,217,163,.45); background: rgba(134,217,163,.11); }
.cc-grid { align-items: start; }
@media (hover: hover) and (pointer: fine) {
  .cc:hover, .sc:hover { border-color: var(--line-1); background: var(--surface-1); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(7,7,11,.5); }
}

/* ---- Supplier cards (Suppliers → Grid): the whole card is one button, like the catalog's ---- */
.sc {
  position: relative; display: flex; flex-direction: column; gap: 14px; width: 100%; min-width: 0; padding: 16px;
  appearance: none; -webkit-appearance: none; font: inherit; text-align: left; color: var(--text-1); cursor: pointer;
  border: 1px solid var(--line-0); border-radius: var(--radius-sm); background: var(--surface-0);
  -webkit-tap-highlight-color: transparent; transition: border-color .18s ease, background .18s ease, transform .18s ease, box-shadow .18s ease;
}
.sc:focus-visible { outline: 2px solid var(--champagne); outline-offset: 3px; }
.sc-name { font-size: 14.5px; font-weight: 600; line-height: 19px; color: var(--text-0); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.sc-loc { display: flex; align-items: center; gap: 5px; min-width: 0; font-size: 11.5px; color: var(--text-2); }
.sc-loc svg { width: 13px; height: 13px; flex-basis: 13px; }
.sc-loc span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-top .pill { flex: 0 0 auto; align-self: flex-start; padding: 3px 8px; font-size: 10.5px; }
.sc-products { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.sc-chip { max-width: 100%; padding: 4px 9px; border-radius: 8px; background: rgba(255,255,255,.05); border: 1px solid var(--line-0); font-size: 11.5px; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-more { color: var(--text-3); }
.sc-none { font-size: 11.5px; color: var(--text-3); }
.sc-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line-0); }
.sc-fact { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--text-2); white-space: nowrap; }
.sc-fact svg { width: 14px; height: 14px; flex-basis: 14px; color: var(--text-3); }
.sc-cur { font-weight: 650; letter-spacing: .04em; color: var(--champagne); }
.sc-pos { color: var(--blue); }
.sc-review { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-size: 10.5px; color: var(--warn); opacity: .85; white-space: nowrap; }

@media (max-width: 560px) {
  .cc-grid, .sc-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .cc, .sc { padding: 14px; gap: 12px; }
  .cc-reach { flex: 1 1 0; justify-content: center; min-height: 40px; }
}
/* Suppliers header on a phone: seven controls were wrapping into a heap. Two columns:
   view switch | New supplier, then your multiple | min profit, freight full width, export | import. */
@media (max-width: 560px) {
  .page-suppliers .head-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100%; margin-left: 0; }
  .page-suppliers .head-actions > * { min-width: 0; }
  .page-suppliers .head-actions .viewswitch { order: 1; justify-self: start; }
  .page-suppliers .head-actions .btn-gold { order: 2; justify-self: end; }
  .page-suppliers .head-actions .mult { order: 3; justify-content: space-between; padding-left: 12px; }
  .page-suppliers .head-actions .mult:has(#sup-fmode) { order: 5; grid-column: 1 / -1; }
  .page-suppliers .head-actions .mult:has(#sup-minp) { order: 4; }
  .page-suppliers .head-actions .mult label { white-space: normal; line-height: 14px; font-size: 11.5px; }
  .page-suppliers .head-actions .mult input { width: 64px; }
  .page-suppliers .head-actions .mult select { flex: 1; min-width: 0; }
  .page-suppliers .head-actions a.btn, .page-suppliers .head-actions label.btn { order: 6; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .cc, .sc, .kb-card, .toast { transition: none; }
  .cc:hover, .sc:hover { transform: none; }
}

/* pricing standard (2026-10-19): the auto-pricing bar and the price check */
.auto-bar { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.auto-bar .auto-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.price-check .check-item td { padding-top: 14px; border-bottom: 0; }
.price-check .check-item .pill { margin-left: 6px; }
.price-check td.price { color: var(--text-0, inherit); }

/* ---- Settings: the numbers (push C, 2026-10-21) ---- */
.page-settings .card { margin-bottom: 14px; }
.page-settings .card + .card { margin-top: 0; }
.page-settings .field { margin-bottom: 0; }
.page-settings .field .tiny { color: var(--text-3); line-height: 1.4; }
.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px 18px; margin: 0 0 14px; }
.set-grid input[type="number"] { max-width: 100%; }
.set-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 760px; }
.set-cats { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
.set-sub { font-size: 13px; margin: 18px 0 10px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.set-floor { margin: 0 0 4px; }
@media (max-width: 560px) { .set-grid, .set-grid-3 { grid-template-columns: 1fr 1fr; gap: 14px 12px; } }

/* ========= SETTINGS → YOUR MONTH: the instrument =========
   One material for the card: glass filling with champagne. The bar is this month's glass laid flat;
   its empty part is cut into one slot per order still to close, so the slots are the big number.
   The six glasses are the last six months on a floating plinth, every rim at the fixed costs.
   Shades below are the champagne token stepped lighter/darker for lit and shaded faces. */
.set-month { padding: 26px 28px 20px; overflow: hidden; position: relative; isolation: isolate; }
.set-month::before { content: ""; position: absolute; z-index: -1; right: -8%; top: -30%; width: 62%; height: 120%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(216,200,167,.075), transparent); }
.mo-controls { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 22px; margin: 34px 0 12px; }
.mo-goal-field { width: 170px; }
.mo-goal-field .field .tiny { display: none; }
.mo-goal-field input { min-height: 44px; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.mo {
  --liq-hi: #fffaf0; --liq-1: #d9cdb1; --liq-2: #bba987; --liq-3: #8c7956; --liq-s1: #a6936f; --liq-s2: #5d4f37;
  --rim: 196px;
}
.mo-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 620px); gap: 8px 32px; align-items: stretch; }

/* the number */
.mo-count { min-width: 0; padding: 0; display: flex; flex-direction: column; }
.mo-figure { display: flex; align-items: flex-end; gap: 6px 22px; flex-wrap: wrap; }
/* background-clip: text only paints inside the box. At line-height .74 Instrument Serif's digits (tops at .73–.745em,
   ascent .99 / descent .31) rise ~.035em above the box, and the -.055em tracking pushes a trailing 7 or 1 ~.05em past
   it — so the box gets padding the gradient can paint into, and equal negative margins keep the layout where it was. */
.mo-num {
  font-family: "Instrument Serif", Georgia, serif; font-weight: 400; font-size: clamp(150px, 19vw, 300px); line-height: .74;
  letter-spacing: -.055em; font-variant-numeric: lining-nums tabular-nums;
  padding: .16em .1em .08em .04em; margin: -.16em -.06em -.08em -.08em;
  background: linear-gradient(180deg, #fffaf0 22%, #f5efe3 45%, #cdbf9f 86%); -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: 0 0 0 transparent; filter: drop-shadow(0 18px 40px rgba(216,200,167,.16));
}
.mo.is-covered .mo-num { background-image: linear-gradient(180deg, #e7f8ec 22%, #b6e9c6 47%, var(--good) 88%); filter: drop-shadow(0 18px 40px rgba(134,217,163,.18)); }
.mo.no-goal .mo-num { display: none; }
.mo-lead { display: flex; flex-direction: column; gap: 6px; margin: 0 0 8px; max-width: 34ch; flex: 1 1 170px; min-width: 170px; }
.mo-lead b { font-size: 26px; font-weight: 600; letter-spacing: -.03em; color: var(--text-0); line-height: 1.05; }
.mo-lead span { font-size: 14px; color: var(--text-2); line-height: 1.45; }
.mo-basis { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.mo-basis .tiny { font-size: 11px; font-weight: 600; }
.mo-basis .tiny { color: var(--text-3); line-height: 1.4; }
.mo-seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: var(--radius-pill); background: rgba(255,255,255,.035); border: 1px solid var(--line-0); }
.mo-rate {
  min-height: 34px; padding: 0 14px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--text-2);
  font: 600 13px/1 Inter, sans-serif; letter-spacing: -.01em; cursor: pointer; font-variant-numeric: tabular-nums;
  transition: background .3s var(--ease), color .2s ease, box-shadow .3s var(--ease);
}
.mo-rate em { font-style: normal; font-weight: 450; opacity: .8; margin-left: 3px; }
.mo-rate:hover:not([disabled]) { color: var(--text-0); }
.mo-rate.is-on, .mo-rate.is-on:hover:not([disabled]) { color: #100f16; background: linear-gradient(180deg, #f5efe3, #cdbf9f); box-shadow: inset 0 1px 0 rgba(255,255,255,.68), 0 6px 14px rgba(216,200,167,.18); }
.mo-rate[disabled] { cursor: not-allowed; opacity: .42; }
.mo-rate:focus { outline: none; }
.mo-rate:focus-visible { outline: 2px solid var(--champagne); outline-offset: 2px; }
.mo-full { margin: 0; font-size: 13px; color: var(--text-2); max-width: 52ch; }

/* the six glasses */
.mo-stage { position: relative; height: 420px; touch-action: pan-y; align-self: end; }
.mo-fit { position: absolute; left: 0; top: 0; width: 620px; height: 390px; transform-origin: 0 0; }
.mo-float { position: absolute; inset: 0; perspective: 1500px; perspective-origin: 50% 32%; animation: moFloat 7s ease-in-out infinite alternate; }
.mo-shadow { position: absolute; left: 50%; top: 72%; width: 500px; height: 92px; margin-left: -250px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0,0,0,.62), rgba(0,0,0,.28) 55%, transparent); filter: blur(8px); animation: moShadow 7s ease-in-out infinite alternate; }
@keyframes moFloat { from { transform: translateY(5px); } to { transform: translateY(-9px); } }
@keyframes moShadow { from { transform: scale(1); opacity: .95; } to { transform: scale(.86); opacity: .62; } }
.mo-scene { position: absolute; left: 45.5%; top: 66%; width: 0; height: 0; transform-style: preserve-3d; transform: rotateX(var(--rx)) rotateY(var(--ry)); }
.mo-scene i, .mo-scene b { position: absolute; display: block; }
.mo-plinth { position: absolute; top: 0; height: 18px; transform-style: preserve-3d; }
.mo-plinth .f-top { left: 0; width: 100%; top: calc(var(--pd) / -2); height: var(--pd); transform: rotateX(90deg); border-radius: 3px;
  background: radial-gradient(120% 140% at 18% 0%, rgba(185,176,212,.10), transparent 55%), linear-gradient(180deg, #1b1826, #121019);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.07), inset 0 0 40px rgba(0,0,0,.35); }
.mo-plinth .f-front { left: 0; top: 0; width: 100%; height: 100%; transform: translateZ(calc(var(--pd) / 2));
  background: linear-gradient(180deg, #24202f, #111018 70%); box-shadow: inset 0 1px 0 rgba(245,239,227,.30); }
.mo-plinth .f-right { top: 0; height: 100%; width: var(--pd); left: calc(100% - var(--pd) / 2); transform: rotateY(90deg); background: linear-gradient(90deg, #0b0a10, #15131c); box-shadow: inset 0 1px 0 rgba(245,239,227,.12); }
.mo-pool { top: calc(var(--pd) / -2); height: var(--pd); width: 150px; margin-left: -75px; transform: rotateX(90deg) translateZ(1px);
  background: radial-gradient(closest-side, rgba(245,239,227,.26), rgba(216,200,167,.08) 55%, transparent); transition: left .6s var(--ease); }
.mo-months { position: absolute; inset: 0; }
.mo-months span { position: absolute; top: 0; width: 56px; text-align: center; font-size: calc(12px * min(var(--inv, 1), 1.3)); line-height: 18px; font-weight: 600; color: var(--text-2); letter-spacing: .01em; }
.mo-months span:last-child { color: var(--cream); }
.mo-plane { position: absolute; top: calc(-1 * var(--rim) - 62px); transform: rotateX(90deg); border-radius: 4px; pointer-events: none;
  background: rgba(216,200,167,.035); border: 1px dashed rgba(216,200,167,.34); transition: top 1.1s var(--ease); }
.mo.no-goal .mo-plane, .mo.no-goal .mo-goal-tag { opacity: 0; }
.mo-goal-tag { position: absolute; bottom: var(--rim); white-space: nowrap; transform-origin: 0 100%; font: 600 calc(12px * var(--inv, 1))/1 Inter, sans-serif; color: var(--champagne);
  transform: translate3d(0, 6px, 0) rotateY(calc(var(--ry) * -1)) rotateX(calc(var(--rx) * -1)); transition: bottom 1.1s var(--ease); }
.mo-goal-tag em { font-style: normal; font-weight: 450; color: var(--text-3); margin-left: 4px; }
.mo-glass { position: absolute; bottom: 0; width: 56px; height: 0; transform-style: preserve-3d; cursor: pointer; outline: none; }
.mo-sleeve, .mo-liq { position: absolute; bottom: 0; transform-style: preserve-3d; }
.mo-sleeve { left: 0; width: 56px; height: var(--rim); transition: height 1.1s var(--ease); }
.mo-liq { left: 4px; width: 48px; height: var(--lh, 0px); transition: height 1.25s var(--ease); }
.mo-sleeve i { background: linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.018)); border: 1px solid rgba(245,239,227,.13); }
.mo-sleeve .f-front, .mo-sleeve .f-back { left: 0; top: 0; width: 100%; height: 100%; }
.mo-sleeve .f-front { transform: translateZ(28px); }
.mo-sleeve .f-back { transform: rotateY(180deg) translateZ(28px); }
.mo-sleeve .f-right, .mo-sleeve .f-left { top: 0; height: 100%; width: 56px; }
.mo-sleeve .f-right { left: 28px; transform: rotateY(90deg); }
.mo-sleeve .f-left { left: -28px; transform: rotateY(-90deg); }
.mo-sleeve .f-top { left: 0; top: -28px; width: 100%; height: 56px; transform: rotateX(90deg); background: rgba(255,255,255,.025); border: 1.5px solid rgba(245,239,227,.46); }
.mo-glass.is-full .mo-sleeve .f-top { border-color: var(--good); box-shadow: 0 0 18px rgba(134,217,163,.45), inset 0 0 12px rgba(134,217,163,.25); }
.mo-liq .f-front { left: 0; top: 0; width: 100%; height: 100%; transform: translateZ(24px); background: linear-gradient(180deg, var(--liq-1), var(--liq-2) 48%, var(--liq-3)); box-shadow: inset 0 1px 0 rgba(255,255,255,.5); }
.mo-liq .f-right { top: 0; height: 100%; width: 48px; left: 24px; transform: rotateY(90deg); background: linear-gradient(180deg, var(--liq-s1), var(--liq-s2)); }
.mo-liq .f-top { left: 0; top: -24px; width: 100%; height: 48px; transform: rotateX(90deg); background: radial-gradient(circle at 34% 30%, var(--liq-hi), var(--liq-1) 72%); }
.mo-glass.is-empty .mo-liq { visibility: hidden; }   /* not opacity: that would flatten its 3D faces */
.mo-glass.is-cur { --liq-1: #f6eedb; --liq-2: #dccaa3; --liq-3: #ad966a; --liq-s1: #c9b68f; --liq-s2: #7d6945; }
.mo-glass.is-sel .mo-sleeve i { border-color: rgba(245,239,227,.30); }
.mo-glass:focus-visible .mo-sleeve i { border-color: var(--champagne); }
.mo-tag { position: absolute; left: -12px; width: 80px; text-align: center; bottom: calc(max(var(--rim), var(--lh, 0px)) + 18px); white-space: nowrap;
  font: 600 calc(12px * var(--inv, 1))/1 Inter, sans-serif; letter-spacing: -.01em; color: var(--text-3); font-variant-numeric: tabular-nums;
  transform: rotateY(calc(var(--ry) * -1)) rotateX(calc(var(--rx) * -1)); transition: bottom 1.1s var(--ease), color .2s ease; }
.mo-glass.is-sel .mo-tag { color: var(--cream); }
.mo-short, .mo-stage.is-small .mo-long { display: none; }
.mo-stage.is-small .mo-short { display: inline; }
.mo-readout { position: absolute; left: 0; right: 0; bottom: 0; margin: 0; text-align: center; font-size: 13px; color: var(--text-2); min-height: 20px; }
.mo-readout b { color: var(--text-0); font-weight: 600; margin-right: 2px; }

/* the bar */
.mo-meter { margin: 18px 0 0; }
.mo-meter-top, .mo-meter-foot { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 18px; flex-wrap: wrap; font-size: 13px; color: var(--text-2); }
.mo-meter-top { margin-bottom: 30px; font-size: 12px; color: var(--text-3); }
.mo-meter-top span:last-child { color: var(--champagne); font-weight: 600; font-size: 13px; }
.mo-meter-foot { margin-top: 14px; }
.mo-meter-foot b { color: var(--text-0); font-weight: 600; font-variant-numeric: tabular-nums; }
.mo-meter-foot span:nth-child(2) { display: inline-flex; align-items: center; gap: 8px; margin-right: auto; color: var(--text-3); }
.mo-swatch { width: 18px; height: 10px; border-radius: 3px; background: repeating-linear-gradient(-45deg, rgba(216,200,167,.5) 0 2px, transparent 2px 5px); }
.mo-gauge { position: relative; }
.mo-track { position: relative; height: 60px; border-radius: 999px; overflow: hidden;
  background: linear-gradient(180deg, rgba(0,0,0,.42), rgba(255,255,255,.035)); border: 1px solid var(--line-1);
  box-shadow: inset 0 2px 10px rgba(0,0,0,.55), inset 0 -1px 0 rgba(255,255,255,.06), 0 1px 0 rgba(255,255,255,.04); }
.mo-track::after { content: ""; position: absolute; left: 14px; right: 14px; top: 5px; height: 10px; border-radius: 99px; pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,0)); }
.mo-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 999px 0 0 999px;
  background: linear-gradient(180deg, #fffaf0 0%, #f2e9d4 22%, #d8c8a7 62%, #b8a27a 100%);
  box-shadow: inset 0 -6px 14px rgba(120,96,60,.35), 0 0 30px rgba(216,200,167,.22); transition: width 1.4s var(--ease); }
.mo-fill.is-moving::after { content: ""; position: absolute; right: -1px; top: 0; bottom: 0; width: 3px; border-radius: 2px; background: #fffaf0; box-shadow: 0 0 16px 3px rgba(245,239,227,.55); }
.mo.is-covered .mo-fill { border-radius: 999px; background: linear-gradient(180deg, #f2fbf4 0%, #c9efd5 30%, var(--good) 75%, #5fae7d 100%); box-shadow: inset 0 -6px 14px rgba(40,90,60,.35), 0 0 34px rgba(134,217,163,.3); }
.mo-pend { position: absolute; top: 0; bottom: 0; width: 0; background: repeating-linear-gradient(-45deg, rgba(216,200,167,.22) 0 2px, transparent 2px 7px); transition: left 1.4s var(--ease), width 1.4s var(--ease); }
.mo-notches, .mo-slots { position: absolute; inset: 0; pointer-events: none; }
.mo-slots span { position: absolute; top: 50%; transform: translate(-50%, -52%); font: italic 400 22px/1 "Instrument Serif", Georgia, serif; color: var(--text-3); animation: moIn .5s .8s both; }
@keyframes moIn { from { opacity: 0; } to { opacity: 1; } }
.mo-notches i { position: absolute; top: 12px; bottom: 12px; width: 2px; margin-left: -1px; background: rgba(7,7,11,.55); box-shadow: 2px 0 0 rgba(255,255,255,.16); border-radius: 1px; }
.mo-pace { position: absolute; top: -10px; bottom: -6px; width: 0; transition: left 1s var(--ease); pointer-events: auto; }
.mo-pace::before { content: ""; position: absolute; left: -1px; top: 0; bottom: 0; width: 2px; border-radius: 1px; background: var(--text-1); box-shadow: 0 0 0 1px rgba(7,7,11,.6); }
.mo-pace span { position: absolute; bottom: 100%; left: 0; transform: translateX(-50%); margin-bottom: 4px; font-size: 11px; font-weight: 600; color: var(--text-1); white-space: nowrap; }
.mo.no-goal .mo-gauge, .mo.no-goal .mo-meter-foot span:nth-child(3) { opacity: .35; }
.mo-how { margin: 20px 0 0; max-width: 92ch; color: var(--text-3); }

/* first paint: everything starts empty and fills to the real numbers once */
.mo.is-fresh .mo-fill, .mo.is-fresh .mo-pend { transition: none; width: 0 !important; }
.mo.is-fresh .mo-liq { height: 0 !important; transition: none; }

/* one column: this month first (number → its bar → the two numbers that drive it), the six months after */
@media (max-width: 1100px) {
  .mo-stage { max-width: 620px; width: 100%; margin: 0 auto; }
  .mo-num { font-size: clamp(168px, 30vw, 260px); }
  .mo { display: flex; flex-direction: column; }
  .mo-top, .mo-count { display: contents; }
  .mo-figure { order: 2; } .mo-meter { order: 3; margin-top: 26px; } .mo-controls { order: 4; }
  .mo-full { order: 5; } .mo-stage { order: 6; margin-top: 18px; } .mo-how { order: 7; }
}
@media (max-width: 560px) {
  .set-month { padding: 20px 16px 16px; }
  .mo-controls { margin-top: 26px; }
  .mo-goal-field, .mo-basis { width: 100%; }
  .mo-lead b { font-size: 21px; }
  .mo-seg { width: 100%; }
  .mo-rate { flex: 1 1 0; padding: 0 8px; font-size: 12.5px; }
  .mo-track { height: 46px; }
  .mo-notches i { top: 11px; bottom: 11px; }
  .mo-meter-foot { font-size: 12.5px; }
  .mo-meter-foot span:nth-child(2) { order: 3; flex: 1 1 100%; }
  .mo-readout { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .mo-float, .mo-shadow { animation: none; }
  .mo-fill, .mo-pend, .mo-liq, .mo-sleeve, .mo-plane, .mo-tag, .mo-goal-tag, .mo-pace, .mo-pool, .mo-rate { transition: none; }
  .mo-slots span { animation: none; }
}
@media (forced-colors: active) {
  .mo-num { color: CanvasText; background: none; }
  .mo-fill { background: Highlight; }
  .mo-track { border-color: CanvasText; }
}

/* ========= Payment emails (2026-10-22): the receipt column in Payments in, the form's checkbox, Settings ========= */
.pay-table .qb-receipt { white-space: normal; min-width: 150px; }
.rc { display: inline-block; font-weight: 600; color: var(--text-2); }
.rc-ok { color: var(--good); }
.rc-bad { color: var(--warn); }
.rc-none { color: var(--text-3); font-weight: 500; }
.rc-to { color: var(--text-3); overflow-wrap: anywhere; }
.qb-receipt .btn { margin-left: 6px; vertical-align: middle; }
.pay-receipt { grid-column: 1 / -1; display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--text-1); cursor: pointer; }
.pay-receipt input { width: 16px; height: 16px; min-height: 0; margin: 0; accent-color: var(--champagne); flex: 0 0 auto; }
.pay-receipt:has(input:disabled) { color: var(--text-3); cursor: default; }
.pe-status { display: flex; align-items: baseline; gap: 9px; margin: 0 0 16px; font-size: 13px; line-height: 1.5; color: var(--text-1); }
.pe-status b { color: var(--text-0); font-weight: 600; }
.pe-dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 7px; transform: translateY(-1px); background: var(--text-3); }
.pe-on .pe-dot { background: var(--good); box-shadow: 0 0 9px rgba(134,217,163,.6); }
.pe-off .pe-dot { background: var(--warn); }
.pe-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.pe-err { color: var(--bad); }
@media (max-width: 560px) {
  .pay-table thead { display: none; }
  .pay-table, .pay-table tbody, .pay-table tr, .pay-table td { display: block; width: auto; }
  .pay-table tr { display: grid; grid-template-columns: auto auto 1fr; gap: 2px 12px; padding: 10px 0; border-bottom: 1px solid var(--line-0); }
  .pay-table td { padding: 0; border: 0; }
  .pay-table td.r { text-align: right; }
  .pay-table tr { position: relative; }
  .pay-table td:nth-child(4), .pay-table td.qb-receipt { grid-column: 1 / -1; }
  .pay-table td.qb-receipt { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; padding-right: 76px; }
  .pay-table td.qb-receipt .btn { margin-left: 0; }
  .pay-table td.row-actions { position: absolute; right: 0; bottom: 10px; }
}
.pe-grid { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.pe-sub { margin: 18px 0 10px; padding-top: 16px; border-top: 1px solid var(--line-0); font-size: 13px; font-weight: 600; color: var(--text-1); }
#pe-card select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 16px) 50%, calc(100% - 11px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 30px; }

/* ========= Settings → TV (2026-10-23): connect the office screen with the code it shows ========= */
.tv-connect { display: grid; grid-template-columns: minmax(180px, 220px) minmax(180px, 1fr) auto; gap: 12px; align-items: end; margin-bottom: 14px; }
.tv-connect #tv-code { font-family: "SF Mono", Menlo, Consolas, monospace; font-size: 20px; letter-spacing: .28em; text-transform: uppercase; }
.tv-connect .btn { min-height: 44px; }
.tv-list { list-style: none; margin: 4px 0 0; padding: 0; }
.tv-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line-0); }
.tv-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tv-meta b { font-weight: 600; }
.tv-dot { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 8px; background: var(--text-3); }
.tv-dot.on { background: var(--good); box-shadow: 0 0 9px rgba(134,217,163,.6); }
.tv-actions { display: flex; gap: 6px; flex: none; }
.tv-none { margin: 0; }
.tv-flash { box-shadow: 0 0 0 1px var(--line-2), 0 0 0 6px rgba(216,200,167,.08); }
@media (max-width: 560px) {
  .tv-connect { grid-template-columns: 1fr; }
  .tv-item { flex-wrap: wrap; }
  .tv-actions { width: 100%; padding-left: 20px; }
}

/* ========= Builder → Final invoice (2026-10-26): the real freight, then the balance ========= */
.fi-status { display: flex; align-items: baseline; gap: 9px; margin: 0 0 14px; font-size: 13px; line-height: 1.5; color: var(--text-1); }
.fi-dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 7px; transform: translateY(-1px); background: var(--good); box-shadow: 0 0 9px rgba(134,217,163,.6); }
.fi-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.fi-warn { margin: 0 0 14px; font-size: 13px; line-height: 1.5; color: var(--warn); }
.fi-grid label .tiny { font-weight: 400; margin-left: 4px; }
.fi-note { grid-column: 1 / -1; }
.fi-sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin: 2px 0 16px; border: 1px solid var(--line-0); border-radius: 12px; overflow: hidden; }
.fi-sum > div { padding: 12px 16px; display: flex; flex-direction: column; gap: 2px; }
.fi-sum > div + div { border-left: 1px solid var(--line-0); }
.fi-sum span { font-size: 11.5px; color: var(--text-2); letter-spacing: .02em; }
.fi-sum b { font-size: 17px; font-weight: 600; color: var(--text-0); font-variant-numeric: tabular-nums; }
.fi-sum em { font-style: normal; font-size: 11.5px; color: var(--text-3); }
.fi-sum .fi-due b { color: var(--champagne); }
.fi-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; }
.fi-foot .pay-receipt { grid-column: auto; flex: 1 1 260px; }
@media (max-width: 560px) {
  .fi-sum { grid-template-columns: 1fr; }
  .fi-sum > div + div { border-left: 0; border-top: 1px solid var(--line-0); }
  .fi-sum > div { flex-direction: row; justify-content: space-between; align-items: baseline; }
}

/* ========= Builder → Email the quote (2026-10-26) ========= */
.qe-grid { grid-template-columns: minmax(240px, 1fr) minmax(260px, 1.4fr); align-items: start; }
.qe-grid textarea { width: 100%; min-height: 84px; resize: vertical; }
.qe-save { margin: -4px 0 14px; }
.qe-hist { list-style: none; margin: 0 0 14px; padding: 0; font-size: 12.5px; color: var(--text-2); display: grid; gap: 3px; }
@media (max-width: 760px) { .qe-grid { grid-template-columns: 1fr; } }
.qe-grid label .tiny { font-weight: 400; margin-left: 4px; }

/* ========= Builder → revisions of an accepted order (2026-10-27) ========= */
.qb-family { padding: 14px 18px; margin-bottom: 18px; }
.qb-family p { margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--text-1); }
.qb-family a { color: var(--champagne); text-underline-offset: 3px; }

/* ========= SETTINGS AS A RULEBOOK (2026-10-27) =========
   One section at a time. Prices and Orders are her rules as sentences, the number inside the sentence as a chip
   (.rn) — the label, input and hint of a form field collapsed into words she'd say. */
.set-tabs { display: flex; gap: 4px; width: max-content; max-width: 100%; margin: 0 0 16px; padding: 4px; overflow-x: auto; scrollbar-width: none;
  border: 1px solid var(--line-1); border-radius: var(--radius-pill); background: var(--surface-1); }
.set-tabs::-webkit-scrollbar { display: none; }
.set-tabs a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 18px; border-radius: var(--radius-pill); white-space: nowrap;
  color: var(--text-2); font-size: 13px; font-weight: 600; text-decoration: none; transition: background .2s var(--ease), color .2s var(--ease); -webkit-tap-highlight-color: transparent; }
.set-tabs a:hover { color: var(--text-0); }
.set-tabs a.on { background: linear-gradient(180deg, #f5efe3, #cdbf9f); color: #100f16; box-shadow: inset 0 1px 0 rgba(255,255,255,.6); }
.set-tabs a:focus { outline: none; }
.set-tabs a:focus-visible { outline: 2px solid var(--champagne); outline-offset: 2px; }
/* a reading column, not a 1440px-wide form */
.page-settings #set-body > .card, .page-settings .set-solo > .card, .page-settings > .card { max-width: 940px; }
.page-settings #set-error { max-width: 940px; }
.set-solo .card-head h2 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.set-rules { padding: 8px 28px 14px; }
.set-rules #set-auto .note { margin: 16px 0 6px; }
.rule { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, .9fr); align-items: center; gap: 24px 36px; padding: 28px 0; }
.rule + .rule, .set-more { border-top: 1px solid var(--line-0); }
.rule-copy, .rule-fields, .set-control { min-width: 0; }
.rule-text { margin: 0; max-width: 38ch; font-size: 19px; line-height: 1.5; letter-spacing: -.015em; color: var(--text-1); }
.rule-eg { margin: 10px 0 0; max-width: 78ch; font-size: 13px; line-height: 1.6; color: var(--text-2); }
.rule-eg a { color: var(--champagne); text-decoration: underline; text-decoration-color: rgba(216,200,167,.35); text-underline-offset: 3px; }
.rule-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr)); gap: 18px; align-items: start; }
.set-control { display: flex; flex-direction: column; gap: 9px; }
.set-control > label, .page-settings .field > label { color: var(--text-1); font-size: 11px; font-weight: 600; line-height: 1.5; letter-spacing: .055em; }
.set-control-hint { font-size: 11px; line-height: 1.6; color: var(--text-2); }
.rn { display: flex; align-items: center; gap: 10px; width: 100%; min-width: 0; min-height: 88px; margin: 0; padding: 18px 20px; border-radius: 14px;
  border: 1px solid var(--line-2); background: rgba(216,200,167,.045); color: var(--cream); font-size: 40px; line-height: 1.2; white-space: nowrap; cursor: text;
  transition: border-color .2s var(--ease), background .2s var(--ease); }
.rn:hover { border-color: rgba(216,200,167,.42); }
.rn:focus-within { border-color: var(--champagne); background: rgba(216,200,167,.075); outline: 2px solid var(--champagne); outline-offset: 3px; box-shadow: none; }
.rn i { flex: none; font-size: .65em; font-style: normal; color: var(--champagne); }
.rn input, .rn input:focus { flex: 1; width: 100%; min-width: 0; min-height: 0; height: 1.2em; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none;
  color: inherit; font: inherit; font-weight: 550; font-variant-numeric: tabular-nums; letter-spacing: -.035em; text-align: left; caret-color: var(--champagne); text-shadow: none; }
.rn input::placeholder { color: var(--text-3); font-weight: 500; }
.rn input::selection { background: rgba(216,200,167,.38); color: #fffaf0; }
.rn.is-saved { border-color: var(--good); }
.rn.is-bad, .rn:has(input[aria-invalid="true"]) { border-color: var(--bad); outline-color: var(--bad); }
.rn.is-off { opacity: .55; cursor: not-allowed; background: rgba(0,0,0,.14); }
.rn.is-off:hover { border-color: var(--line-2); }
.rn.is-off input { cursor: not-allowed; }

.set-more { padding: 6px 0 0; }
.set-more > summary { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 0; cursor: pointer; list-style: none;
  color: var(--text-2); font-size: 14px; font-weight: 600; }
.set-more > summary::-webkit-details-marker { display: none; }
.set-more > summary::before { content: ""; width: 7px; height: 7px; margin-right: 2px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg); transition: transform .25s var(--ease); }
.set-more[open] > summary::before { transform: rotate(45deg) translate(-2px, -1px); }
.set-more > summary:hover { color: var(--text-0); }
.set-more > summary:focus { outline: none; }
.set-more > summary:focus-visible { outline: 2px solid var(--champagne); outline-offset: 4px; border-radius: 6px; }
.set-more .rule:first-of-type { border-top: 1px solid var(--line-0); }
.rule-categories { grid-template-columns: 1fr; gap: 16px; }
.rule-cats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 0; }
.rule-cat .rn { min-height: 72px; font-size: 30px; padding: 14px 16px; }
.set-how { max-width: none; padding: 16px 0 6px; border-top: 1px solid var(--line-0); }

/* The same hierarchy carries through TV, email and Advanced. Keep native inputs, selection and scrolling. */
.page-settings .field { min-width: 0; gap: 9px; }
.page-settings .field > :is(input, select, textarea) { min-width: 0; min-height: 58px; padding: 15px 18px; border-radius: 12px; border-color: var(--line-2); background-color: rgba(216,200,167,.035); font-size: 16px; line-height: 1.45; caret-color: var(--champagne); text-shadow: none; }
.page-settings .field > :is(input, select, textarea):hover:not(:disabled) { border-color: rgba(216,200,167,.42); }
.page-settings .field > :is(input, select, textarea):focus { outline: 2px solid var(--champagne); outline-offset: 3px; border-color: var(--champagne); background-color: rgba(216,200,167,.075); box-shadow: none; }
.page-settings .field > :is(input, select, textarea):disabled { opacity: .55; cursor: not-allowed; background-color: rgba(0,0,0,.14); }
.page-settings .field > :is(input, select, textarea)[aria-invalid="true"], .page-settings .field > input:user-invalid { border-color: var(--bad); outline-color: var(--bad); }
.page-settings .field.is-saved > :is(input, select) { border-color: var(--good); }
.page-settings .field-primary > input { min-height: 88px; padding: 20px 22px; font-size: clamp(24px, 2.3vw, 30px); font-weight: 500; letter-spacing: -.025em; }
.page-settings .field .tiny { line-height: 1.6; color: var(--text-2); }
.page-settings .settings-field-error { font-size: 12px; line-height: 1.5; color: var(--bad); overflow-wrap: anywhere; }
.page-settings .pe-grid:has(.field-primary) { grid-template-columns: minmax(0, 1fr); margin: 24px 0 28px; }
.page-settings .pe-grid { gap: 22px; }
.page-settings .pe-sub { margin-top: 26px; margin-bottom: 18px; }
.page-settings .tv-connect { grid-template-columns: minmax(220px, .85fr) minmax(0, 1fr) auto; gap: 20px; margin: 28px 0; align-items: start; }
.page-settings .tv-connect #tv-code { font-size: 36px; line-height: 1.25; letter-spacing: .1em; padding: 20px; }
.page-settings .tv-connect > .btn { margin-top: 43px; min-height: 52px; padding-inline: 22px; }
.page-settings .tv-item { padding-block: 20px; }
.page-settings .tv-meta b { overflow-wrap: anywhere; }
.page-settings .token-form { gap: 20px; padding-top: 18px; }
.page-settings .token-form .btn { min-height: 58px; }

@media (max-width: 800px) {
  .rule { grid-template-columns: 1fr; gap: 18px; }
  .rule-text { max-width: 52ch; }
  .page-settings .tv-connect { grid-template-columns: 1fr 1fr; }
  .page-settings .tv-connect > .btn { grid-column: 1 / -1; min-height: 48px; margin-top: 0; justify-self: start; }
}
@media (max-width: 560px) {
  .rule-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 14px; }
  .rn { min-height: 80px; padding: 17px 18px; font-size: 34px; }
  .page-settings .tv-connect { grid-template-columns: minmax(0, 1fr); }
  .page-settings .tv-connect #tv-code { font-size: 32px; }
  .page-settings .tv-connect > .btn { width: 100%; }
  .page-settings .field-primary > input { min-height: 80px; padding: 18px; }
  .page-settings .pe-grid { grid-template-columns: minmax(0, 1fr); }
  .page-settings .tv-item { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .page-settings :is(input, select, textarea), .rn { transition: none; }
}
@media (forced-colors: active) {
  .rn { border-color: ButtonText; }
  .rn:focus-within { outline-color: Highlight; }
  .rn.is-off { opacity: 1; color: GrayText; }
}

/* ========= MONTH — the home page ========= */
.page-month .head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 24px; margin: 8px 0 18px; }
.page-month .head .muted { margin-top: 6px; font-size: 14px; }
.page-month #mon-open { margin-top: 14px; }
.page-month .set-month { padding-top: 34px; }
.mon-open { padding: 22px 24px 12px; }
.mon-open-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px 20px; }
.mon-open h2, .mon-none h2 { font-size: 15px; font-weight: 600; }
.mon-open-head .muted, .mon-none .muted { margin-top: 4px; font-size: 13px; max-width: 70ch; }
.mon-none { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 20px; padding-bottom: 22px; }
.mon-list { list-style: none; margin: 12px 0 0; padding: 0; }
.mon-list li + li { border-top: 1px solid var(--line-0); }
.mon-row { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) 210px; align-items: center; gap: 6px 22px; margin: 0 -12px; padding: 14px 12px;
  border-radius: 12px; color: inherit; text-decoration: none; transition: background .2s var(--ease); }
.mon-row:hover { background: var(--surface-1); }
.mon-row:focus { outline: none; }
.mon-row:focus-visible { outline: 2px solid var(--champagne); outline-offset: -2px; }
.mon-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.mon-who b { font-size: 15px; font-weight: 600; color: var(--text-0); }
.mon-who span, .mon-who b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mon-who span { font-size: 13px; color: var(--text-2); }
.mon-seen { display: flex; flex-direction: column; gap: 2px; font-size: 13px; color: var(--text-2); }
.mon-seen.is-seen { color: var(--text-1); }
.mon-until { font-size: 12px; color: var(--text-2); }
.mon-until.is-soon { color: var(--warn); }
.mon-money { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; text-align: right; }
.mon-money b { font-size: 16px; font-weight: 600; color: var(--cream); font-variant-numeric: tabular-nums; }
.mon-money span { font-size: 12px; color: var(--text-2); }
.mon-more { margin: 4px 0 8px; color: var(--text-3); }
.mon-more a { color: var(--champagne); }

@media (max-width: 640px) {
  .set-tabs a { padding: 0 13px; }
  .set-rules { padding: 4px 18px 10px; }
  .rule { padding: 24px 0; }
  .rule-text { font-size: 17px; line-height: 1.5; }
  .mon-open { padding: 18px 16px 8px; }
  .mon-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "who money" "seen seen"; gap: 6px 14px; align-items: start; }
  .mon-who { grid-area: who; } .mon-money { grid-area: money; } .mon-money span { max-width: 9.5em; }
  .mon-seen { grid-area: seen; flex-direction: row; flex-wrap: wrap; gap: 2px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .set-tabs a, .rn, .set-more > summary::before, .mon-row { transition: none; }
}

/* ========= QUOTE BUILDER — primary entry fields =========
   Quote-specific classes keep the shared purchase-order editor and secondary controls compact. */
.page-builder:not(.page-po) .qb-title-field { max-width: 760px; gap: 10px; margin: 16px 0 12px; }
.page-builder:not(.page-po) .qb-title-field > label,
.page-builder:not(.page-po) .qb-fields .field > label,
.page-builder:not(.page-po) .qb-field-label,
#ql-new .qb-start-primary > label { color: var(--text-1); font-size: 11px; font-weight: 600; line-height: 1.5; letter-spacing: .035em; }
.page-builder:not(.page-po) .qb-title-field .title-input { width: 100%; min-height: 92px; padding: 18px 22px; font-size: clamp(32px, 3vw, 42px); line-height: 1.2; border: 1px solid var(--line-2); border-radius: 14px; background: rgba(216,200,167,.045); text-shadow: none; }
.page-builder:not(.page-po) .qb-line { gap: 20px; padding: 22px; }
.page-builder:not(.page-po) .qb-fields { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px 16px; align-items: start; }
.page-builder:not(.page-po) .qb-fields > .field { min-width: 0; gap: 8px; }
.page-builder:not(.page-po) .qb-fields > .field > label { margin-bottom: 0; }
.page-builder:not(.page-po) .qb-fields > .qb-name { grid-column: 1 / -1; }
.page-builder:not(.page-po) .qb-fields > .qb-description { grid-column: span 3; }
.page-builder:not(.page-po) .qb-fields > .qb-qty { grid-column: 1; }
.page-builder:not(.page-po) .qb-fields > .qb-line-total { grid-column: -2 / -1; }
.page-builder:not(.page-po) .qb-primary input { min-width: 0; min-height: 76px; padding: 18px; font-size: 28px; line-height: 1.3; font-weight: 500; letter-spacing: -.025em; border-radius: 12px; border-color: var(--line-2); background: rgba(216,200,167,.035); caret-color: var(--champagne); text-shadow: none; }
.page-builder:not(.page-po) .qb-description input { min-height: 68px; padding: 17px 18px; font-size: 20px; font-weight: 400; letter-spacing: -.015em; }
.page-builder:not(.page-po) .qb-qty input,
.page-builder:not(.page-po) .qb-unit input { font-size: 30px; font-variant-numeric: tabular-nums; }
.page-builder:not(.page-po) .qb-unit .money { min-width: 0; }
.page-builder:not(.page-po) .qb-unit .money::before { left: 16px; font-size: 20px; color: var(--champagne); }
.page-builder:not(.page-po) .qb-unit input { padding-left: 38px; padding-right: 12px; }
.page-builder:not(.page-po) .qb-primary input:hover:not(:disabled) { border-color: rgba(216,200,167,.42); }
.page-builder:not(.page-po) .qb-primary input:focus { outline: 2px solid var(--champagne); outline-offset: 3px; border-color: var(--champagne); background: rgba(216,200,167,.075); box-shadow: none; }
.page-builder:not(.page-po) .qb-primary input:disabled { color: var(--text-2); background: rgba(0,0,0,.12); border-color: var(--line-0); cursor: not-allowed; }
.page-builder:not(.page-po) .qb-primary.is-saved input { border-color: var(--good); }
.page-builder:not(.page-po) .qb-primary input[aria-invalid="true"],
.page-builder:not(.page-po) .qb-primary input:user-invalid { border-color: var(--bad); outline-color: var(--bad); }
.page-builder:not(.page-po) .qb-line-total .price { min-height: 76px; padding: 18px 0; font-size: 26px; font-weight: 550; line-height: 1.3; font-variant-numeric: tabular-nums; letter-spacing: -.03em; overflow-wrap: anywhere; }
.page-builder:not(.page-po) .qb-fields .tiny { line-height: 1.5; overflow-wrap: anywhere; }
.page-builder:not(.page-po) .settings-field-error { color: var(--bad); font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
#ql-new .qb-start-primary { min-width: 0; gap: 9px; }
#ql-new .qb-start-primary :is(input, select) { min-width: 0; min-height: 64px; padding: 16px 18px; font-size: 20px; line-height: 1.4; border-radius: 12px; border-color: var(--line-2); background-color: rgba(216,200,167,.035); }
#ql-new .qb-start-primary :is(input, select):focus { outline: 2px solid var(--champagne); outline-offset: 3px; box-shadow: none; }
@media (max-width: 1280px) {
  .page-builder:not(.page-po) .qb-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-builder:not(.page-po) .qb-fields > .qb-description { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .page-builder:not(.page-po) .qb-title-field { margin-top: 12px; }
  .page-builder:not(.page-po) .qb-title-field .title-input { min-height: 84px; padding: 18px; font-size: 32px; }
  .page-builder:not(.page-po) .qb-line { padding: 16px; gap: 16px; }
  .page-builder:not(.page-po) .qb-fields { gap: 16px 12px; }
  .page-builder:not(.page-po) .qb-fields > .field:nth-child(n) { grid-column: auto; }
  .page-builder:not(.page-po) .qb-fields > .field:is(.qb-name, .qb-description, .qb-sizes, .wide, .wide2) { grid-column: 1 / -1; }
  .page-builder:not(.page-po) .qb-fields > .field.qb-qty { grid-column: 1; }
  .page-builder:not(.page-po) .qb-fields > .field.qb-line-total { grid-column: 2; }
  .page-builder:not(.page-po) .qb-primary input { min-height: 72px; padding: 16px; font-size: 24px; }
  .page-builder:not(.page-po) .qb-description input { min-height: 64px; font-size: 18px; }
  .page-builder:not(.page-po) .qb-unit input { padding-left: 30px; padding-right: 8px; }
  .page-builder:not(.page-po) .qb-unit .money::before { left: 12px; font-size: 17px; }
  .page-builder:not(.page-po) .qb-line-total .price { min-height: 72px; font-size: 23px; }
  .page-builder:not(.page-po) .field:not(.qb-primary) :is(input:not([type="checkbox"]), select, textarea) { font-size: 16px; min-height: 44px; }
  .page-builder:not(.page-po) .qb-fields .size-cell input { width: 56px; padding-inline: 4px; }
  #ql-new .qb-start-primary :is(input, select) { font-size: 18px; min-height: 60px; }
}
@media (prefers-reduced-motion: reduce) {
  .page-builder:not(.page-po) .qb-primary input, #ql-new .qb-start-primary :is(input, select) { transition: none; }
}

/* the builder's "Delete test quote" (practice runs only) — quiet, at the very bottom */
.qb-danger { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 6px 0 0; padding: 14px 4px 4px; }
.qb-danger .tiny { flex: 1 1 260px; line-height: 1.5; }
