/*! AgentVerge by VergeKits — styles.css */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/Inter-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/Inter-500.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/Inter-600.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/Inter-700.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 800; font-display: swap; src: url("fonts/Inter-800.woff2") format("woff2"); }

:root {
  --font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable", "Segoe UI", Roboto, sans-serif;
  --serif: "New York", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --bg: #F6F3EE; --surface: #FFFFFF; --raised: #EFEBE3; --hair: rgba(28,25,23,.08); --hair2: rgba(28,25,23,.14);
  --text: #1C1917; --text2: #57534E; --text3: #6B655F; --charcoal: #1C1917; --navy: #1E3A5F; --navy-text: #1E3A5F; --navy-tint: rgba(30,58,95,.08);
  --gold: #C9973A; --gold-text: #8A6416; --gold-tint: rgba(201,151,58,.14);
  --pos: #1FA67A; --pos-text: #12704F; --pos-tint: rgba(31,166,122,.12);
  --warn: #E9A23B; --warn-text: #8A5300; --warn-tint: rgba(233,162,59,.16);
  --bad: #D9534F; --bad-text: #A9302C; --bad-tint: rgba(217,83,79,.12);
  --neutral: #8B95A7; --neutral-text: #4E5767; --neutral-tint: rgba(139,149,167,.16);
  --info: #3B82C4; --info-text: #23609A; --info-tint: rgba(59,130,196,.12);
  --primary: #1E3A5F; --primary-text: #FFFFFF; --primary-hover: #17304F;
  --shadow: 0 1px 2px rgba(28,25,23,.04), 0 8px 24px -12px rgba(28,25,23,.14);
  --shadow-lg: 0 2px 6px rgba(28,25,23,.06), 0 24px 60px -20px rgba(28,25,23,.28);
  --sidebar: #1C1917; --sidebar-text: #D6D3CE; --sidebar-muted: #A8A29E;
  --tabbar: #FFFFFF; --input: #FFFFFF; --focus: #1E3A5F;
  --r1: 10px; --r2: 14px; --r3: 20px;
  --c1: #1E3A5F; --c2: #C9973A; --c3: #1FA67A; --c4: #8B95A7; --c5: #3B82C4; --c6: #B5654A;
  --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px); --sal: env(safe-area-inset-left, 0px); --sar: env(safe-area-inset-right, 0px);
  --tabh: 64px;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #0C0F14; --surface: #141A22; --raised: #1C2430; --hair: rgba(243,241,236,.08); --hair2: rgba(243,241,236,.16);
  --text: #F3F1EC; --text2: #A8A29E; --text3: #9A948E; --navy-text: #9DBDE3; --navy-tint: rgba(157,189,227,.12);
  --gold-text: #E6B85C; --gold-tint: rgba(230,184,92,.14);
  --pos-text: #5BD3A6; --pos-tint: rgba(31,166,122,.18); --warn-text: #F2BE6B; --warn-tint: rgba(233,162,59,.18);
  --bad-text: #FF8F8A; --bad-tint: rgba(217,83,79,.2); --neutral-text: #B5BDCB; --neutral-tint: rgba(139,149,167,.2);
  --info-text: #8CBDEB; --info-tint: rgba(59,130,196,.2);
  --primary: #E6B85C; --primary-text: #1C1917; --primary-hover: #F0C772;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 30px -14px rgba(0,0,0,.6); --shadow-lg: 0 24px 70px -20px rgba(0,0,0,.75);
  --sidebar: #090C10; --tabbar: #141A22; --input: #0F141B; --focus: #E6B85C;
  --c1: #7FA6D6; --c2: #E6B85C; --c3: #3CC795; --c4: #A0AABB; --c5: #5BA2E0; --c6: #E08A6A;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; height: 100%; overscroll-behavior-y: none; }
body { margin: 0; min-height: 100%; background: var(--bg); color: var(--text); font: 400 16px/1.5 var(--font); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; overscroll-behavior-y: none; -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--navy-text); }
img { max-width: 100%; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
h1 { font-size: 28px; font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: 18px; font-weight: 700; }
h3 { font-size: 16px; font-weight: 700; }
p { margin: 0 0 8px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.serif { font-family: var(--serif); }
.muted { color: var(--text2); }
.small { font-size: 14px; }
.tiny { font-size: 12px; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.row-flex { display: flex; align-items: center; gap: 12px; }
.wrap { flex-wrap: wrap; }
.stack > * + * { margin-top: 16px; }
.hide { display: none !important; }
svg.i { width: 22px; height: 22px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
svg.i.s { width: 18px; height: 18px; }
svg.i.l { width: 28px; height: 28px; }

/* ---------- splash ---------- */
#splash { position: fixed; inset: 0; display: grid; place-items: center; background: #0C0F14; z-index: 50; transition: opacity .3s; }
#splash img { width: 96px; height: 96px; border-radius: 50%; box-shadow: 0 0 0 2px rgba(201,151,58,.6), 0 20px 50px -10px rgba(201,151,58,.45); }
#splash.out { opacity: 0; pointer-events: none; }

/* ---------- layout ---------- */
.app { min-height: 100vh; min-height: 100dvh; }
.sidebar { display: none; }
.main { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px; padding: calc(var(--sat) + 10px) calc(16px + var(--sar)) 10px calc(16px + var(--sal)); background: var(--bg); border-bottom: 1px solid transparent; transition: border-color .2s; }
.topbar.scrolled { border-bottom-color: var(--hair); }
.topbar .brand { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; text-decoration: none; color: inherit; }
.topbar .brand img { width: 36px; height: 36px; border-radius: 50%; flex: none; box-shadow: 0 0 0 1.5px rgba(201,151,58,.55); }
.topbar .brand b { font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
.topbar .brand small { display: block; font-size: 12px; color: var(--text2); line-height: 1.1; }
.topbar .search { display: none; }
.saved { font-size: 12px; color: var(--text3); display: inline-flex; align-items: center; gap: 4px; opacity: 0; transition: opacity .3s; white-space: nowrap; }
.saved.on { opacity: 1; }
.saved svg { width: 14px; height: 14px; color: var(--pos); }
.view { padding: 8px calc(16px + var(--sar)) calc(var(--tabh) + var(--sab) + 32px) calc(16px + var(--sal)); max-width: 1320px; margin: 0 auto; outline: none; }
.view.has-toast { padding-bottom: calc(var(--tabh) + var(--sab) + 110px); }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 8px 0 18px; }
.page-head h1 { font-size: 26px; }
.page-head .sub { color: var(--text2); font-size: 15px; margin-top: 4px; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--text2); text-decoration: none; font-weight: 600; font-size: 14px; min-height: 44px; padding-right: 8px; }

/* ---------- banner wrap ---------- */
.banner-wrap { padding: 0 calc(16px + var(--sar)) 0 calc(16px + var(--sal)); max-width: 1320px; margin: 0 auto; }
.banner-wrap:empty { display: none; }
.badge[hidden] { display: none !important; }

/* ---------- tab bar (solid, never translucent) ---------- */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--bg); padding: 6px calc(10px + var(--sar)) calc(var(--sab) + 8px) calc(10px + var(--sal)); }
.tabbar .bar { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)) 58px; align-items: center; height: var(--tabh); background: var(--tabbar); border: 1px solid var(--hair); border-radius: 22px; box-shadow: var(--shadow-lg); max-width: 560px; margin: 0 auto; padding: 0 4px; }
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 52px; min-width: 44px; border: 0; background: none; color: var(--text2); text-decoration: none; font-size: 11.5px; font-weight: 600; letter-spacing: .01em; border-radius: 14px; white-space: nowrap; }
.tab svg { width: 24px; height: 24px; }
.tab[aria-current="page"] { color: var(--navy-text); }
.tab[aria-current="page"] svg { stroke-width: 2; }
.tab[aria-current="page"]::after { content: ""; width: 18px; height: 3px; border-radius: 3px; background: var(--gold); margin-top: 1px; }
.tab-add { width: 52px; height: 52px; border-radius: 18px; border: 0; justify-self: center; display: grid; place-items: center; color: #1C1917; background: linear-gradient(140deg, #E8C277, #C9973A 60%, #B5832A); box-shadow: 0 10px 24px -10px rgba(201,151,58,.9); transition: transform .14s; cursor: pointer; }
.tab-add svg { width: 26px; height: 26px; stroke-width: 2.2; }
.tab-add:active { transform: scale(.94); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--hair2); background: var(--surface); color: var(--text); font-weight: 650; font-size: 15px; cursor: pointer; text-decoration: none; white-space: normal; text-align: center; line-height: 1.2; transition: transform .14s, background .14s, border-color .14s; }
.btn:active { transform: scale(.98); }
.btn:hover { border-color: var(--gold); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: var(--primary-text); }
.btn.primary:hover { background: var(--primary-hover); }
.btn.gold { background: linear-gradient(140deg, #E8C277, #C9973A); border-color: #C9973A; color: #1C1917; }
.btn.danger { color: var(--bad-text); }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--raised); }
.btn.sm { min-height: 44px; padding: 0 12px; font-size: 14px; }
.btn.block { width: 100%; }
.btn svg { width: 18px; height: 18px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 12px; border: 1px solid transparent; background: transparent; color: var(--text2); cursor: pointer; flex: none; text-decoration: none; }
.icon-btn:hover { background: var(--raised); color: var(--text); }
.icon-btn.bordered { border-color: var(--hair2); background: var(--surface); }

/* ---------- cards ---------- */
.card { background: var(--surface); border: 1px solid var(--hair); border-radius: var(--r3); box-shadow: var(--shadow); padding: 18px; position: relative; }
.card.flat { box-shadow: none; }
.card.pad0 { padding: 0; overflow: hidden; }
.card-h { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; min-height: 28px; }
.card-h h2 { font-size: 17px; }
.card-h a, .link { color: var(--navy-text); font-weight: 650; font-size: 14px; text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.link-card { display: block; color: inherit; text-decoration: none; transition: transform .14s; }
.link-card::after, .kpi.link::after { content: ""; position: absolute; left: 18px; right: 18px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--gold); transform: scaleX(0); transition: transform .24s; }
.link-card:hover::after, .link-card:focus-visible::after, .kpi.link:hover::after, .kpi.link:focus-visible::after { transform: scaleX(1); }
.grid { display: grid; gap: 16px; }
.grid > *, .stack > * { min-width: 0; }
.g2 { grid-template-columns: 1fr; }
.g3 { grid-template-columns: 1fr; }

/* ---------- KPIs ---------- */
.hello { margin: 6px 0 16px; }
.hello h1 { font-size: 26px; }
.hello .date { color: var(--text2); font-size: 15px; margin-top: 2px; }
.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.kpi { background: var(--surface); border: 1px solid var(--hair); border-radius: var(--r2); box-shadow: var(--shadow); padding: 14px 14px 12px; position: relative; min-width: 0; color: inherit; text-decoration: none; display: block; }
.kpi .l { font-size: 12.5px; font-weight: 650; color: var(--text2); display: flex; align-items: center; gap: 6px; min-height: 18px; }
.kpi .l svg { width: 16px; height: 16px; color: var(--gold-text); }
.kpi .v { font-family: var(--serif); font-size: 24px; font-weight: 700; letter-spacing: -.01em; margin-top: 6px; line-height: 1.1; white-space: nowrap; overflow: hidden; text-overflow: clip; }
.kpi .s { font-size: 12.5px; color: var(--text2); margin-top: 4px; }
.kpi.hero { grid-column: 1 / -1; background: linear-gradient(135deg, #1C1917, #2A2420 60%, #1E3A5F 140%); color: #F3F1EC; border-color: transparent; padding: 18px; }
.kpi.hero .l { color: #D9C9A6; }
.kpi.hero .l svg { color: #E6B85C; }
.kpi.hero .v { font-size: 38px; color: #fff; }
.kpi.hero .s { color: #CFC8BE; }
.kpi.hero .split { display: flex; gap: 22px; margin-top: 12px; flex-wrap: wrap; }
.kpi.hero .split div b { display: block; font-family: var(--serif); font-size: 20px; color: #E6B85C; font-weight: 700; }
.kpi.hero .split div span { font-size: 12.5px; color: #CFC8BE; }
.meter { height: 8px; border-radius: 8px; background: var(--raised); overflow: hidden; margin-top: 10px; }
.meter i { display: block; height: 100%; width: 100%; border-radius: 8px; background: linear-gradient(90deg, #C9973A, #E6B85C); transform-origin: left; transform: scaleX(var(--p, 0)); transition: transform .7s cubic-bezier(.2,.8,.2,1); }
.meter.navy i { background: linear-gradient(90deg, #1E3A5F, #3B6EA8); }
[data-theme="dark"] .meter.navy i { background: linear-gradient(90deg, #5C86BC, #9DBDE3); }
.ring { --p: 0; width: 120px; height: 120px; position: relative; flex: none; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .track { stroke: var(--raised); }
.ring .fill { stroke: var(--gold); stroke-linecap: round; transition: stroke-dashoffset .7s cubic-bezier(.2,.8,.2,1); }
.ring .c { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.ring .c b { font-family: var(--serif); font-size: 24px; display: block; line-height: 1; }
.ring .c span { font-size: 12px; color: var(--text2); }

/* ---------- pipeline strip ---------- */
.pipe { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pipe a { display: block; text-decoration: none; color: inherit; border-radius: var(--r1); background: var(--navy-tint); padding: 10px 10px 9px; min-height: 64px; position: relative; overflow: hidden; }
.pipe a b { display: block; font-family: var(--serif); font-size: 22px; line-height: 1.1; color: var(--navy-text); }
.pipe a span { display: block; font-size: 12px; font-weight: 650; color: var(--text2); line-height: 1.25; }
.pipe a small { display: block; font-size: 11.5px; color: var(--gold-text); font-weight: 650; margin-top: 2px; }
.pipe a.on { background: var(--navy); }
.pipe a.on b, .pipe a.on span { color: #fff; }
.pipe a.on small { color: #F2CF86; }
[data-theme="dark"] .pipe a.on { background: #2B4A72; }

/* ---------- lists ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; min-height: 60px; border-top: 1px solid var(--hair); color: inherit; text-decoration: none; background: var(--surface); position: relative; }
.list > li:first-child > .item, .list > .item:first-child { border-top: 0; }
a.item:hover, button.item:hover { background: var(--raised); }
button.item { width: 100%; border-left: 0; border-right: 0; border-bottom: 0; text-align: left; cursor: pointer; font: inherit; }
.item .t { flex: 1; min-width: 0; }
.item .t b { display: block; font-weight: 650; font-size: 15.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item .t small.wrap2, .item .t b.wrap2 { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.item .t small { display: block; color: var(--text2); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item .r { text-align: right; flex: none; }
.item .r b { display: block; font-weight: 700; font-size: 15px; }
.item .r small { display: block; color: var(--text2); font-size: 12.5px; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 750; font-size: 14px; flex: none; background: var(--navy-tint); color: var(--navy-text); }
.avatar.gold { background: var(--gold-tint); color: var(--gold-text); }
.ic-tile { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--gold-tint); color: var(--gold-text); }
.ic-tile.navy { background: var(--navy-tint); color: var(--navy-text); }
.ic-tile.red { background: var(--bad-tint); color: var(--bad-text); }
.ic-tile.amber { background: var(--warn-tint); color: var(--warn-text); }
.ic-tile.green { background: var(--pos-tint); color: var(--pos-text); }
.ic-tile.info { background: var(--info-tint); color: var(--info-text); }

/* ---------- chips ---------- */
.chip { max-width: 100%; display: inline-flex; align-items: center; gap: 5px; min-height: 26px; padding: 3px 10px; border-radius: 13px; font-size: 12.5px; font-weight: 700; line-height: 1.25; white-space: nowrap; background: var(--neutral-tint); color: var(--neutral-text); }
.chip svg { width: 14px; height: 14px; }
.chip.green { background: var(--pos-tint); color: var(--pos-text); }
.chip.amber { background: var(--warn-tint); color: var(--warn-text); }
.chip.red { background: var(--bad-tint); color: var(--bad-text); }
.chip.navy { background: var(--navy-tint); color: var(--navy-text); }
.chip.gold { background: var(--gold-tint); color: var(--gold-text); }
.chip.info { background: var(--info-tint); color: var(--info-text); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chips .chip { white-space: normal; }
.big-num { font-family: var(--serif); font-size: clamp(26px, 8vw, 34px); font-weight: 700; line-height: 1.1; }
.filter-bar { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 10px; margin: 0 -2px 6px; scrollbar-width: none; }
.filter-bar::-webkit-scrollbar { display: none; }
.fchip { flex: none; min-height: 44px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--hair2); background: var(--surface); font-size: 14px; font-weight: 650; color: var(--text2); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.fchip[aria-pressed="true"], .fchip[aria-current="page"] { background: var(--navy); color: #fff; border-color: var(--navy); }
[data-theme="dark"] .fchip[aria-pressed="true"], .fchip[aria-current="page"] { background: #2B4A72; border-color: #2B4A72; }
.fchip .n { font-size: 12px; opacity: .8; }

/* ---------- countdown chips (key dates) ---------- */
.kd { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-top: 1px solid var(--hair); min-height: 60px; }
.kd:first-child { border-top: 0; }
.cd { width: 58px; flex: none; text-align: center; border-radius: 12px; padding: 6px 4px; background: var(--neutral-tint); color: var(--neutral-text); }
.cd b { display: block; font-family: var(--serif); font-size: 20px; line-height: 1.05; }
.cd span { display: block; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.cd.amber { background: var(--warn-tint); color: var(--warn-text); }
.cd.red { background: var(--bad-tint); color: var(--bad-text); }
.cd.green { background: var(--pos-tint); color: var(--pos-text); }
.cd.navy { background: var(--navy-tint); color: var(--navy-text); }
.check { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border: 0; background: none; cursor: pointer; padding: 0; }
.check i { width: 24px; height: 24px; border-radius: 8px; border: 2px solid var(--hair2); display: grid; place-items: center; transition: background .14s, border-color .14s; }
.check[aria-checked="true"] i { background: var(--pos); border-color: var(--pos); }
.check[aria-checked="true"] i::after { content: ""; width: 10px; height: 6px; border: 2.4px solid #fff; border-top: 0; border-right: 0; transform: translateY(-1px) rotate(-45deg); }
.done-text { text-decoration: line-through; color: var(--text3); }

/* ---------- forms ---------- */
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 12px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; grid-column: 1 / -1; }
.field.half { grid-column: span 1; }
.field > label, .lbl { font-size: 13.5px; font-weight: 650; color: var(--text2); }
.field .hint { font-size: 12.5px; color: var(--text3); }
.field .err { font-size: 13px; color: var(--bad-text); font-weight: 600; }
.input, .select, textarea.input { width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--hair2); background: var(--input); color: var(--text); font-size: 16px; outline: none; transition: border-color .14s, box-shadow .14s; }
textarea.input { padding: 12px 14px; min-height: 96px; resize: vertical; line-height: 1.45; }
.input:focus, .select:focus { border-color: var(--focus); box-shadow: 0 0 0 4px var(--navy-tint); }
.input.bad, .select.bad { border-color: var(--bad); }
.select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238B95A7' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.affix { position: relative; display: flex; align-items: center; }
.affix .input { padding-left: 40px; }
.affix .input.sfx { padding-left: 14px; padding-right: 40px; }
.affix > span { position: absolute; left: 14px; color: var(--text3); font-weight: 600; pointer-events: none; font-size: 15px; }
.affix > span.sfx { left: auto; right: 14px; }
input[type="date"].input { min-width: 0; padding: 0 10px; font-size: 15px; -webkit-appearance: none; appearance: none; display: flex; align-items: center; }
input[type="date"]::-webkit-date-and-time-value { text-align: left; }
.seg { display: inline-flex; padding: 3px; gap: 3px; border-radius: 12px; background: var(--raised); flex-wrap: wrap; max-width: 100%; }
.seg button, .seg a { min-height: 40px; padding: 0 14px; border: 0; border-radius: 9px; background: transparent; color: var(--text2); font-weight: 650; font-size: 14px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; white-space: nowrap; }
.seg [aria-pressed="true"], .seg [aria-current="page"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.seg.full { display: flex; }
.seg.full > * { flex: 1; justify-content: center; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; cursor: pointer; }
.switch input { appearance: none; -webkit-appearance: none; width: 50px; height: 30px; border-radius: 30px; background: var(--hair2); position: relative; flex: none; cursor: pointer; transition: background .2s; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform .2s; }
.switch input:checked { background: var(--pos); }
.switch input:checked::after { transform: translateX(20px); }
.searchbox { position: relative; }
.searchbox svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text3); width: 18px; height: 18px; }
.searchbox .input { padding-left: 42px; }

/* ---------- tables ---------- */
.tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--text2); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--hair2); white-space: nowrap; }
.tbl td { padding: 11px 12px; border-bottom: 1px solid var(--hair); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num, .tbl th.num { text-align: right; }
.tbl tr.total td { font-weight: 800; border-top: 2px solid var(--text); }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--raised); }
.calc-lines { width: 100%; border-collapse: collapse; }
.calc-lines td { padding: 9px 0; border-bottom: 1px dashed var(--hair2); font-size: 15px; }
.calc-lines td.num { text-align: right; }
.calc-lines tr.sub td { font-weight: 700; border-bottom-style: solid; }
.calc-lines tr.minus td.num { color: var(--bad-text); }
.calc-lines tr.big td { font-size: 18px; font-weight: 800; border-bottom: 0; padding-top: 14px; }
.calc-lines tr.big td.num { font-family: var(--serif); font-size: 26px; color: var(--pos-text); }
.calc-lines tr.post td { color: var(--pos-text); }

/* ---------- empty states ---------- */
.empty { text-align: center; padding: 36px 16px; }
.empty svg.art { width: 120px; height: 96px; margin: 0 auto 12px; display: block; }
.empty h3 { font-size: 17px; margin-bottom: 6px; }
.empty p { color: var(--text2); max-width: 340px; margin: 0 auto 16px; }

/* ---------- banners ---------- */
.banner { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r2); background: var(--gold-tint); color: var(--text); margin: 4px 0 16px; flex-wrap: wrap; }
.banner .t { flex: 1; min-width: 200px; font-size: 14.5px; }
.banner .t b { display: block; }
.banner.navy { background: var(--navy-tint); }
.banner.red { background: var(--bad-tint); }

/* ---------- sheets (dialogs) ---------- */
.backdrop { position: fixed; inset: 0; background: rgba(12,15,20,.52); z-index: 60; opacity: 0; transition: opacity .24s; }
.backdrop.in { opacity: 1; }
.sheet { position: fixed; z-index: 61; left: 0; right: 0; bottom: 0; max-height: calc(100dvh - var(--sat) - 24px); max-height: calc(100vh - var(--sat) - 24px); display: flex; flex-direction: column; background: var(--surface); border-radius: 22px 22px 0 0; box-shadow: var(--shadow-lg); transform: translateY(100%); transition: transform .24s cubic-bezier(.2,.8,.2,1); }
@supports (height: 100dvh) { .sheet { max-height: calc(100dvh - var(--sat) - 24px); } }
.sheet.in { transform: none; }
.sheet-h { display: flex; align-items: center; gap: 8px; padding: 10px 10px 8px 20px; border-bottom: 1px solid var(--hair); min-height: 60px; }
.sheet-h h2 { flex: 1; font-size: 18px; min-width: 0; }
.sheet-b { padding: 16px 20px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; flex: 1; }
.sheet-f { display: flex; gap: 10px; padding: 12px 20px calc(12px + var(--sab)); border-top: 1px solid var(--hair); background: var(--surface); flex-wrap: wrap; }
.sheet-f .btn { flex: 1; }
.sheet-f .btn.danger { flex: 0 0 auto; }
.menu-list { display: grid; gap: 8px; }
.menu-list button, .menu-list a { display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 8px 14px; border-radius: 14px; border: 1px solid var(--hair); background: var(--surface); text-align: left; cursor: pointer; text-decoration: none; color: inherit; font-weight: 650; font-size: 16px; }
.menu-list button:hover, .menu-list a:hover { border-color: var(--gold); }
.menu-list small { display: block; font-weight: 400; font-size: 13px; color: var(--text2); }

/* ---------- toasts ---------- */
#toasts { position: fixed; z-index: 80; left: 12px; right: 12px; bottom: calc(var(--tabh) + var(--sab) + 26px); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
body.sheet-open #toasts { bottom: auto; top: calc(var(--sat) + 8px); left: 64px; right: 64px; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; max-width: 460px; width: 100%; min-height: 52px; padding: 6px 6px 6px 16px; border-radius: 14px; background: #1C1917; color: #F3F1EC; box-shadow: 0 16px 40px -12px rgba(0,0,0,.5); font-size: 14.5px; animation: toast-in .24s cubic-bezier(.2,.8,.2,1); }
[data-theme="dark"] .toast { background: #2A3240; }
.toast .m { flex: 1; min-width: 0; }
.toast button { min-height: 40px; padding: 0 12px; border-radius: 10px; border: 0; background: rgba(230,184,92,.16); color: #E6B85C; font-weight: 750; cursor: pointer; }
.toast.out { opacity: 0; transform: translateY(8px); transition: opacity .2s, transform .2s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
body.shot #toasts { display: none; }

/* ---------- charts ---------- */
.chart { position: relative; }
.chart svg.plot { width: 100%; height: auto; display: block; overflow: visible; }
.chart .axis text { fill: var(--text3); font-size: 11px; font-family: var(--font); }
.chart .grid line { stroke: var(--hair); }
.chart .bar { transform-box: fill-box; transform-origin: bottom; animation: grow .7s cubic-bezier(.2,.8,.2,1) both; }
.chart .hbar { transform-box: fill-box; transform-origin: left; animation: growx .7s cubic-bezier(.2,.8,.2,1) both; }
.chart .line { stroke-dasharray: var(--len, 2000); stroke-dashoffset: var(--len, 2000); animation: draw .7s ease-out forwards; }
.chart .area { animation: fade .7s ease-out both; }
.chart .lbl-v { fill: var(--text2); font-size: 11px; font-weight: 650; }
@keyframes grow { from { transform: scaleY(0); } }
@keyframes growx { from { transform: scaleX(0); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade { from { opacity: 0; } }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--text2); margin-top: 8px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.legend i.hatch { background-image: repeating-linear-gradient(45deg, currentColor 0 2px, transparent 2px 4px) !important; }
.chart-tbl-toggle { font-size: 13px; }
.funnel { display: grid; gap: 8px; }
.funnel .f { display: grid; grid-template-columns: 110px 1fr 52px; align-items: center; gap: 10px; font-size: 14px; }
.funnel .f .b { height: 28px; border-radius: 8px; background: var(--navy-tint); overflow: hidden; }
.funnel .f .b i { display: block; height: 100%; background: linear-gradient(90deg, var(--c1), var(--c5)); transform-origin: left; animation: growx .7s cubic-bezier(.2,.8,.2,1) both; border-radius: 8px; }
.funnel .f b { text-align: right; font-family: var(--serif); font-size: 18px; }
.donut-wrap { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }

/* ---------- pipeline board ---------- */
.board { display: grid; grid-template-columns: 1fr; gap: 12px; }
.col { background: var(--raised); border-radius: var(--r2); padding: 10px; min-width: 0; }
.col-h { display: flex; align-items: center; justify-content: space-between; padding: 4px 6px 10px; gap: 6px; }
.col-h b { font-size: 14px; }
.col-h small { font-size: 12px; color: var(--gold-text); font-weight: 700; }
.mini { display: block; background: var(--surface); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; border: 1px solid var(--hair); text-decoration: none; color: inherit; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.mini b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini small { display: block; font-size: 12.5px; color: var(--text2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini:hover { border-color: var(--gold); }

/* ---------- deal header ---------- */
.deal-hero { background: linear-gradient(135deg, #1C1917, #26211D 55%, #1E3A5F 160%); color: #F3F1EC; border-radius: var(--r3); padding: 18px; box-shadow: var(--shadow-lg); }
.deal-hero h1 { font-size: 22px; color: #fff; }
.deal-hero .meta { color: #CFC8BE; font-size: 14px; margin-top: 4px; }
.deal-hero .figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.deal-hero .figs div { min-width: 0; }
.deal-hero .figs span { display: block; font-size: 12px; color: #CFC8BE; font-weight: 600; }
.deal-hero .figs b { display: block; font-family: var(--serif); font-size: 19px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.deal-hero .figs b.g { color: #E6B85C; }
.deal-hero .chip { background: rgba(230,184,92,.18); color: #F2CF86; }
.deal-hero .chip.navy { background: rgba(157,189,227,.18); color: #C7DBF2; }
.deal-actions { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 14px 0 6px; }
.deal-actions a, .deal-actions button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 64px; border-radius: 14px; border: 1px solid var(--hair); background: var(--surface); font-size: 12.5px; font-weight: 650; text-decoration: none; color: var(--text); cursor: pointer; padding: 6px 4px; text-align: center; line-height: 1.2; }
.deal-actions svg { color: var(--gold-text); }
.deal-actions a:hover, .deal-actions button:hover { border-color: var(--gold); }
.subnav { margin: 14px 0; overflow-x: auto; scrollbar-width: none; }
.subnav::-webkit-scrollbar { display: none; }
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.photos figure { margin: 0; border-radius: 12px; overflow: hidden; background: var(--raised); position: relative; aspect-ratio: 4 / 3; }
.photos img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photos figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 10px 6px; font-size: 12px; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.65)); }
.photos .del { position: absolute; top: 4px; right: 4px; background: rgba(0,0,0,.55); color: #fff; }

/* ---------- open house sign-in (kiosk) ---------- */
.kiosk { position: fixed; inset: 0; z-index: 55; background: #F6F3EE; color: #1C1917; overflow: auto; padding: calc(var(--sat) + 20px) 20px calc(var(--sab) + 20px); }
[data-theme="dark"] .kiosk { background: #0C0F14; color: #F3F1EC; }
.kiosk .inner { max-width: 560px; margin: 0 auto; }
.kiosk .k-head { text-align: center; margin-bottom: 18px; }
.kiosk .k-head img { width: 64px; height: 64px; border-radius: 50%; }
.kiosk .k-head h1 { font-family: var(--serif); font-size: 30px; margin-top: 10px; }
.kiosk .k-head p { color: var(--text2); }
.kiosk .exit { position: absolute; top: calc(var(--sat) + 10px); right: 12px; }

/* ---------- documents (screen preview + print) ---------- */
.doc-bar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.paper-wrap { overflow-x: auto; padding-bottom: 8px; }
.doc { background: #fff; color: #1C1917; width: 100%; max-width: 816px; margin: 0 auto; padding: 44px 48px; border-radius: 6px; box-shadow: 0 2px 4px rgba(0,0,0,.06), 0 24px 60px -24px rgba(0,0,0,.35); font-size: 13.5px; line-height: 1.45; color-scheme: light; }
.doc.a4 { max-width: 794px; }
.doc .dh { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; border-bottom: 2px solid #1C1917; padding-bottom: 16px; margin-bottom: 18px; }
.doc .dh .who { display: flex; gap: 12px; align-items: center; }
.doc .dh .who img { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; }
.doc .dh .who img.round { border-radius: 50%; }
.doc .dh .who b { display: block; font-size: 16px; }
.doc .dh .who span { display: block; color: #57534E; font-size: 12.5px; }
.doc .dt { text-align: right; }
.doc .dt h1 { font-family: var(--serif); font-size: 26px; font-weight: 700; letter-spacing: -.01em; color: #1C1917; }
.doc .dt .meta { color: #57534E; font-size: 12.5px; margin-top: 4px; }
.doc .dt .meta b { color: #1C1917; }
.doc h2 { font-family: var(--serif); font-size: 17px; margin: 18px 0 8px; color: #1E3A5F; }
.doc table { width: 100%; border-collapse: collapse; font-size: 13px; }
.doc th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: #57534E; border-bottom: 1.5px solid #1C1917; padding: 7px 6px; }
.doc td { padding: 7px 6px; border-bottom: 1px solid #E7E2D9; }
.doc td.num, .doc th.num { text-align: right; white-space: nowrap; }
.doc tr.sub td { font-weight: 700; background: #F6F3EE; }
.doc tr.grand td { font-weight: 800; font-size: 15px; border-top: 2px solid #1C1917; border-bottom: 0; background: #F3EBDA; }
.doc tr.minus td.num::before { content: ""; }
.doc .boxes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 14px 0; }
.doc .box { border: 1px solid #E7E2D9; border-radius: 8px; padding: 10px 12px; }
.doc .box span { display: block; font-size: 11px; color: #57534E; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.doc .box b { display: block; font-family: var(--serif); font-size: 19px; margin-top: 2px; }
.doc .box.gold { border-color: #C9973A; background: #FBF5E9; }
.doc .two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.doc .note { font-size: 11.5px; color: #57534E; border-top: 1px solid #E7E2D9; margin-top: 22px; padding-top: 10px; }
.doc .stamp { display: inline-block; border: 2px solid; border-radius: 6px; padding: 2px 10px; font-weight: 800; letter-spacing: .08em; font-size: 12px; text-transform: uppercase; }
.doc .stamp.paid { color: #12704F; } .doc .stamp.due { color: #A9302C; } .doc .stamp.part { color: #8A5300; }
.doc .goldline { height: 3px; background: linear-gradient(90deg, #C9973A, #E6B85C); margin: -18px 0 18px; }
#print-root { display: none; }

/* ---------- settings / misc ---------- */
.set-group { margin-bottom: 18px; }
.set-group > h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--text2); margin: 0 0 8px 4px; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; font-size: 14.5px; }
.kv dt { color: var(--text2); }
.kv dd { margin: 0; text-align: right; font-weight: 650; min-width: 0; overflow-wrap: anywhere; }
.storage-bar { height: 10px; border-radius: 10px; background: var(--raised); overflow: hidden; }
.storage-bar i { display: block; height: 100%; background: var(--navy); width: 100%; transform-origin: left; transform: scaleX(var(--p, 0)); }
.test { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-top: 1px solid var(--hair); }
.test:first-child { border-top: 0; }
.test .t { flex: 1; min-width: 0; }
.test .t b { font-weight: 600; font-size: 14.5px; display: block; }
.test .t small { color: var(--text2); font-size: 13px; }
.search-results { position: absolute; top: 100%; left: 0; right: 0; margin-top: 6px; background: var(--surface); border: 1px solid var(--hair2); border-radius: var(--r2); box-shadow: var(--shadow-lg); max-height: 60vh; overflow: auto; z-index: 40; }
.search-results .item { min-height: 52px; }
.logo-v { width: 44px; height: 44px; border-radius: 50%; }
.about-hero { text-align: center; padding: 26px 16px; }
.about-hero img { width: 104px; height: 104px; border-radius: 50%; box-shadow: 0 0 0 2px rgba(201,151,58,.55), 0 18px 44px -12px rgba(201,151,58,.6); }
.disclaimer { font-size: 13px; color: var(--text2); padding: 12px 14px; border-radius: var(--r1); background: var(--raised); }
.onb { max-width: 520px; margin: 0 auto; padding-top: 10px; }
.onb .steps { display: flex; gap: 6px; margin: 4px 0 18px; }
.onb .steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--hair2); }
.onb .steps i.on { background: var(--gold); }
.choice { display: grid; gap: 12px; }
.choice button { display: flex; gap: 14px; align-items: center; text-align: left; padding: 16px; border-radius: var(--r2); border: 1.5px solid var(--hair2); background: var(--surface); cursor: pointer; min-height: 76px; }
.choice button:hover { border-color: var(--gold); }
.choice b { display: block; font-size: 16px; }
.choice small { display: block; color: var(--text2); font-size: 14px; }
.count-up { display: inline-block; }

/* ---------- breakpoints ---------- */
@media (min-width: 400px) {
  .kpi .v { font-size: 26px; }
}
@media (min-width: 600px) {
  .g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pipe { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: min(640px, calc(100vw - 32px)); border-radius: 22px; transform: translate(-50%, -46%) scale(.98); opacity: 0; transition: transform .24s cubic-bezier(.2,.8,.2,1), opacity .24s; max-height: min(860px, calc(100vh - 48px)); }
  .sheet.in { transform: translate(-50%, -50%); opacity: 1; }
  .sheet.wide { width: min(880px, calc(100vw - 32px)); }
  .sheet-f { padding-bottom: 12px; }
  .deal-actions { grid-template-columns: repeat(4, minmax(0, 120px)); }
}
@media (min-width: 900px) {
  :root { --tabh: 0px; }
  .app { display: grid; grid-template-columns: 248px minmax(0, 1fr); }
  .sidebar { display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; background: var(--sidebar); color: var(--sidebar-text); padding: 18px 12px 110px; overflow-y: auto; scrollbar-width: thin; }
  .sidebar .sb-brand { display: flex; align-items: center; gap: 12px; padding: 4px 8px 18px; text-decoration: none; color: inherit; }
  .sidebar .sb-brand img { width: 44px; height: 44px; border-radius: 50%; box-shadow: 0 0 0 1.5px rgba(201,151,58,.6); }
  .sidebar .sb-brand b { display: block; font-size: 18px; color: #fff; font-weight: 800; letter-spacing: -.01em; }
  .sidebar .sb-brand small { display: block; font-size: 11px; color: #E6B85C; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; }
  .sidebar nav a { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; border-radius: 12px; color: var(--sidebar-text); text-decoration: none; font-weight: 600; font-size: 14.5px; position: relative; }
  .sidebar nav a svg { color: var(--sidebar-muted); width: 20px; height: 20px; }
  .sidebar nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
  .sidebar nav a[aria-current="page"] { background: rgba(230,184,92,.12); color: #fff; }
  .sidebar nav a[aria-current="page"] svg { color: #E6B85C; }
  .sidebar nav a[aria-current="page"]::before { content: ""; position: absolute; left: -12px; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: #E6B85C; }
  .sidebar nav a .badge { margin-left: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: #E6B85C; color: #1C1917; font-size: 12px; font-weight: 800; display: grid; place-items: center; }
  .sidebar .sb-sep { height: 1px; background: rgba(255,255,255,.08); margin: 10px 8px; }
  .sidebar .sb-foot { margin-top: auto; padding: 14px 8px 0; font-size: 12px; color: var(--sidebar-muted); }
  .topbar { padding: 14px 28px; }
  .topbar .brand { display: none; }
  .topbar .search { display: block; flex: 1; max-width: 520px; position: relative; }
  .topbar .spacer { flex: 1; }
  .tabbar { display: none; }
  .view { padding: 8px 28px 48px; }
  .banner-wrap { padding: 8px 28px 0; }
  .view.has-toast { padding-bottom: 48px; }
  #toasts { left: 16px; right: auto; width: 216px; bottom: 16px; align-items: stretch; }
  body.sheet-open #toasts { top: auto; bottom: 16px; left: 16px; right: auto; }
  .toast { flex-wrap: wrap; padding: 10px 12px; }
  .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
  .kpi.hero { grid-column: span 2; grid-row: span 2; display: flex; flex-direction: column; justify-content: space-between; align-items: stretch; text-align: left; }
  .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .board { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .home-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
  .detail-grid { grid-template-columns: minmax(0, 1.5fr) minmax(320px, 1fr); align-items: start; }
  .mobile-only { display: none !important; }
  .page-head h1 { font-size: 30px; }
}
@media (max-width: 899.98px) { .desk-only { display: none !important; } .first-mobile { order: -1; } }
@media (min-width: 900px) { .sticky-desk { position: sticky; top: 84px; } }
@media (min-width: 1280px) {
  .board { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .kpis.k8 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1800px) { .view { max-width: 1560px; } }
@media (max-width: 360px) {
  .kpi .v { font-size: 21px; }
  .kpi.hero .v { font-size: 32px; }
  .tab { font-size: 11px; }
  .deal-hero .figs b { font-size: 16px; }
  .form { grid-template-columns: 1fr; }
  .field.half { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0ms !important; transition-duration: .001ms !important; }
}
body.shot *, body.shot *::before, body.shot *::after { animation: none !important; transition: none !important; }
body.shot .chart .line { stroke-dashoffset: 0; }

/* ---------- print ---------- */
@media print {
  html, body { background: #fff !important; color: #1C1917 !important; }
  body > *:not(#print-root) { display: none !important; }
  #print-root { display: block !important; }
  #print-root .doc { box-shadow: none; border-radius: 0; padding: 0; max-width: none; width: 100%; }
  .doc tr, .doc .box { break-inside: avoid; page-break-inside: avoid; }
  .doc h2 { break-after: avoid; page-break-after: avoid; }
  .doc .pb { break-before: page; page-break-before: always; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
