/* ==========================================================================
   Invitty CRM — design system
   Brand: Teal #066B76, Deep teal #055762, Ink #142B3D, Mint #7FE6DB (matches invitty.com)
   Type: Inter (UI), Space Grotesk (display)
   ========================================================================== */

:root {
  --orange: #066B76;
  --flame: #055762;
  --brand: #066B76;
  --grad: #066B76;
  --peach: #D3E9EC;
  --cream: #EEF5F7;
  --blue: #52A2FF;
  --green: #12A877;
  --red: #E5484D;
  --amber: #E9A23B;
  --violet: #8B5CF6;

  --bg: #F6F3EF;
  --surface: #FFFFFF;
  --surface-2: #FAF7F3;
  --surface-3: #F2EDE6;
  --line: #EAE3DA;
  --line-strong: #DCD3C8;
  --ink: #142B3D;
  --text: #142B3D;
  --muted: #687075;
  --faint: #9AA1A5;
  --sidebar: #142B3D;
  --sidebar-2: #0F2230;
  --sidebar-text: #C9D0D3;
  --focus: 0 0 0 3px rgba(6, 107, 118, .28);
  --shadow-sm: 0 1px 2px rgba(20, 43, 61, .06);
  --shadow: 0 1px 2px rgba(20, 43, 61, .05), 0 6px 18px rgba(20, 43, 61, .06);
  --shadow-lg: 0 18px 50px rgba(30, 36, 40, .18);
  --radius: 14px;
  --radius-sm: 10px;
  --tint-orange: #E9F4F5;
  --tint-blue: #EAF3FF;
  --tint-green: #E7F7F0;
  --tint-red: #FDEDEE;
  --tint-violet: #F1ECFE;
  --tint-slate: #EEF1F3;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --sb-w: 252px;
  color-scheme: light;
}

[data-theme="dark"] {
  --bg: #141819;
  --surface: #1C2225;
  --surface-2: #20272A;
  --surface-3: #283034;
  --line: #142B3D;
  --line-strong: #3A4448;
  --text: #E9EDEE;
  --muted: #A2AAAE;
  --faint: #737D82;
  --sidebar: #111516;
  --sidebar-2: #0C0F10;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, .5);
  --tint-orange: rgba(6, 107, 118, .14);
  --tint-blue: rgba(82, 162, 255, .14);
  --tint-green: rgba(18, 168, 119, .16);
  --tint-red: rgba(229, 72, 77, .16);
  --tint-violet: rgba(139, 92, 246, .16);
  --tint-slate: rgba(148, 163, 184, .14);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.45;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'cv11', 'ss01';
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
img { max-width: 100%; }
::selection { background: rgba(6, 107, 118, .25); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 8px; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 12.5px; }
.nowrap { white-space: nowrap; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hidden { display: none !important; }
.grow { flex: 1; min-width: 0; }
.row { display: flex; align-items: center; gap: 10px; }
.row.wrap { flex-wrap: wrap; }
.col { display: flex; flex-direction: column; gap: 10px; }
.between { justify-content: space-between; }
.right { margin-left: auto; }
.mt { margin-top: 16px; }
.mb { margin-bottom: 16px; }
.icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon.sm { width: 15px; height: 15px; }
.icon.lg { width: 22px; height: 22px; }

/* ---------- boot ---------- */
.booting { min-height: 100vh; display: grid; place-items: center; }
.boot { display: grid; place-items: center; gap: 18px; }
.boot-bar { width: 120px; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; position: relative; }
.boot-bar::after { content: ''; position: absolute; inset: 0; width: 40%; background: var(--grad); animation: boot 1s ease-in-out infinite; }
@keyframes boot { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }

/* ---------- login ---------- */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.login-art {
  position: relative; overflow: hidden; color: #fff; padding: 48px;
  background: radial-gradient(1200px 600px at -10% 110%, rgba(6, 107, 118, .55), transparent 60%),
              radial-gradient(900px 500px at 120% -10%, rgba(6, 107, 118, .35), transparent 60%), #142B3D;
  display: flex; flex-direction: column; justify-content: space-between;
}
.login-art img { width: 210px; }
.login-art h2 { font-family: var(--display); font-weight: 400; font-size: 40px; line-height: 1.15; margin: 0 0 14px; letter-spacing: -.01em; max-width: 460px; }
.login-art p { color: #C9D0D3; max-width: 420px; font-size: 15px; line-height: 1.6; }
.login-art .lines { position: absolute; right: -60px; bottom: -40px; width: 520px; opacity: .14; }
.login-feats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 460px; }
.login-feats div { display: flex; gap: 10px; align-items: center; color: #E3E7E9; font-size: 13.5px; }
.login-feats .icon { color: var(--orange); }
.login-form { display: grid; place-items: center; padding: 40px 24px; background: var(--surface); }
.login-card { width: 100%; max-width: 380px; }
.login-card h1 { font-size: 26px; margin: 0 0 6px; letter-spacing: -.02em; }
.login-card .muted { margin: 0 0 28px; }
.login-mobile-logo { display: none; height: 30px; margin-bottom: 28px; }
@media (max-width: 880px) {
  .login { grid-template-columns: 1fr; }
  .login-art { display: none; }
  .login-mobile-logo { display: block; }
}

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--sb-w) 1fr; min-height: 100vh; transition: grid-template-columns .2s ease; }
.shell.collapsed { --sb-w: 76px; }
.sidebar {
  position: sticky; top: 0; height: 100vh; background: var(--sidebar); color: var(--sidebar-text);
  display: flex; flex-direction: column; z-index: 40; overflow: hidden;
}
.sb-head { display: flex; align-items: center; gap: 10px; padding: 18px 18px 14px; min-height: 68px; }
.sb-head .logo-full { height: 28px; }
.sb-head .logo-mark { height: 32px; display: none; }
.collapsed .sb-head { justify-content: center; padding: 18px 8px 14px; }
.collapsed .sb-head .logo-full { display: none; }
.collapsed .sb-head .logo-mark { display: block; }
.sb-nav { flex: 1; overflow-y: auto; padding: 6px 12px 12px; scrollbar-width: thin; scrollbar-color: #3a4448 transparent; }
.sb-group { font-size: 10.5px; text-transform: uppercase; letter-spacing: .1em; color: #7F8A8F; padding: 16px 10px 6px; white-space: nowrap; }
.collapsed .sb-group { visibility: hidden; height: 12px; padding: 0; }
.sb-link {
  display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 10px; color: var(--sidebar-text);
  font-weight: 500; position: relative; white-space: nowrap; transition: background .15s, color .15s; margin: 1px 0;
}
.sb-link:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.sb-link.active { background: rgba(6, 107, 118, .14); color: #fff; }
.sb-link.active::before { content: ''; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--grad); }
.sb-link.active .icon { color: var(--orange); }
.sb-link .count { margin-left: auto; background: var(--flame); color: #fff; font-size: 11px; font-weight: 600; min-width: 20px; height: 20px; border-radius: 10px; display: grid; place-items: center; padding: 0 6px; }
.collapsed .sb-link { justify-content: center; padding: 10px; }
.collapsed .sb-link span:not(.count) { display: none; }
.collapsed .sb-link .count { position: absolute; top: 2px; right: 4px; min-width: 16px; height: 16px; font-size: 10px; padding: 0 4px; }
.sb-foot { padding: 12px; border-top: 1px solid rgba(255, 255, 255, .06); }
.sb-user { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; cursor: pointer; width: 100%; background: none; border: 0; text-align: left; color: var(--sidebar-text); }
.sb-user:hover { background: rgba(255, 255, 255, .06); }
.sb-user .who { min-width: 0; }
.sb-user .who b { display: block; color: #fff; font-size: 13px; font-weight: 600; }
.sb-user .who small { font-size: 11.5px; color: #8E989D; text-transform: capitalize; }
.collapsed .sb-user .who, .collapsed .sb-user > .icon { display: none; }
.collapsed .sb-user { justify-content: center; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px; padding: 12px 28px;
  background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid transparent; min-height: 64px;
}
.topbar.scrolled { border-bottom-color: var(--line); }
.tb-title { min-width: 0; }
.tb-title h1 { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: -.015em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-title .crumb { font-size: 12px; color: var(--muted); }
.searchbtn {
  margin-left: auto; display: flex; align-items: center; gap: 10px; min-width: 260px; padding: 8px 12px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--line); color: var(--faint); cursor: pointer; box-shadow: var(--shadow-sm);
}
.searchbtn:hover { border-color: var(--line-strong); }
.searchbtn kbd { margin-left: auto; }
kbd { font-family: var(--font); font-size: 11px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line); background: var(--surface-2); color: var(--muted); }
.page { padding: 8px 28px 48px; max-width: 1600px; width: 100%; }
.page.full { max-width: none; }
.btn.menu-toggle { display: none; }
.sb-scrim { display: none; }

@media (max-width: 1080px) {
  .searchbtn { min-width: 0; }
  .searchbtn span, .searchbtn kbd { display: none; }
}
@media (max-width: 860px) {
  .shell, .shell.collapsed { grid-template-columns: 1fr; --sb-w: 268px; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 268px; transform: translateX(-100%); transition: transform .22s ease; }
  .shell.nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
  .shell.nav-open .sb-scrim { display: block; position: fixed; inset: 0; background: rgba(0, 0, 0, .35); z-index: 35; }
  .collapsed .sb-link span:not(.count), .collapsed .sb-group, .collapsed .sb-user .who { display: revert; visibility: visible; }
  .btn.menu-toggle { display: inline-flex; }
  .topbar { padding: 10px 16px; gap: 8px; }
  .page { padding: 4px 16px 40px; }
  .tb-title h1 { font-size: 17px; }
  .tb-title .crumb { display: none; }
  .hide-sm { display: none !important; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 15px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface); color: var(--text); font-weight: 600; font-size: 13.5px;
  cursor: pointer; white-space: nowrap; transition: transform .06s, box-shadow .15s, background .15s, border-color .15s; box-shadow: var(--shadow-sm);
}
.btn:hover { border-color: var(--line-strong); background: var(--surface-2); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.primary { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 1px 2px rgba(6, 107, 118, .3), 0 4px 12px rgba(6, 107, 118, .22); }
.btn.primary:hover { filter: brightness(1.04); }
.btn.dark { background: var(--ink); color: #fff; border-color: var(--ink); }
[data-theme="dark"] .btn.dark { background: #E9EDEE; color: #1C2225; border-color: #E9EDEE; }
.btn.ghost { background: transparent; border-color: transparent; box-shadow: none; }
.btn.ghost:hover { background: var(--surface-3); }
.btn.danger { color: var(--red); }
.btn.danger:hover { background: var(--tint-red); border-color: rgba(229, 72, 77, .35); }
.btn.danger.solid { background: var(--red); color: #fff; border-color: var(--red); }
.btn.sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 8px; }
.btn.xs { height: 26px; padding: 0 8px; font-size: 12px; border-radius: 7px; gap: 5px; }
.btn.icon-only { width: 38px; padding: 0; }
.btn.sm.icon-only { width: 32px; }
.btn.xs.icon-only { width: 26px; }
.btn.loading { pointer-events: none; position: relative; color: transparent !important; }
.btn.loading::after { content: ''; position: absolute; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-color: rgba(255,255,255,.9) rgba(255,255,255,.9) transparent transparent; animation: spin .7s linear infinite; }
.btn:not(.primary):not(.dark).loading::after { border-color: var(--orange) var(--orange) transparent transparent; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn-group { display: inline-flex; }
.btn-group .btn { border-radius: 0; margin-left: -1px; }
.btn-group .btn:first-child { border-radius: 10px 0 0 10px; margin: 0; }
.btn-group .btn:last-child { border-radius: 0 10px 10px 0; }

/* segmented */
.seg { display: inline-flex; background: var(--surface-3); border-radius: 10px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 8px; font-weight: 600; font-size: 12.5px; color: var(--muted); cursor: pointer; display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

/* tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 20px; overflow-x: auto; scrollbar-width: none; }
.tabs button { border: 0; background: none; padding: 10px 14px; font-weight: 600; color: var(--muted); cursor: pointer; position: relative; white-space: nowrap; display: inline-flex; gap: 8px; align-items: center; }
.tabs button:hover { color: var(--text); }
.tabs button.on { color: var(--text); }
.tabs button.on::after { content: ''; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--grad); }
.tabs .pill { background: var(--surface-3); color: var(--muted); font-size: 11px; padding: 1px 7px; border-radius: 10px; }

/* ---------- cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-h { display: flex; align-items: center; gap: 10px; padding: 16px 18px 0; }
.card-h h3 { margin: 0; font-size: 14.5px; font-weight: 650; letter-spacing: -.005em; }
.card-h .sub { color: var(--muted); font-size: 12.5px; }
.card-b { padding: 16px 18px 18px; }
.card-b.flush { padding: 8px 0 4px; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-main { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
@media (max-width: 1200px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-main { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }

.page-head { display: flex; align-items: flex-end; gap: 12px; margin: 10px 0 18px; flex-wrap: wrap; }
.page-head h2 { font-family: var(--display); font-weight: 400; font-size: 26px; margin: 0; letter-spacing: -.01em; }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* KPI tiles */
.kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
@media (max-width: 1440px) { .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.kpis.k4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpis.k3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpis.k2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 1200px) { .kpis.k4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) { .kpis, .kpis.k3, .kpis.k4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .kpi { padding: 13px 12px 12px; } .kpi .k-val { font-size: 20px; } .page-head h2 { font-size: 22px; } }
.kpi { position: relative; padding: 16px 16px 14px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); overflow: hidden; min-width: 0; }
.kpi .k-top { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12.5px; font-weight: 600; }
.kpi .k-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.kpi .k-val { font-size: 23px; font-weight: 700; letter-spacing: -.02em; margin: 12px 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi .k-val small { font-size: 12px; font-weight: 600; color: var(--muted); margin-right: 3px; letter-spacing: 0; }
.kpi .k-sub { font-size: 12px; color: var(--muted); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.kpi.hero { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 8px 24px rgba(6, 107, 118, .25); }
.kpi.hero .k-top, .kpi.hero .k-sub, .kpi.hero .k-val small { color: rgba(255, 255, 255, .85); }
.kpi.hero .k-ic { background: rgba(255, 255, 255, .2) !important; color: #fff !important; }
.kpi.hero .delta { background: rgba(255, 255, 255, .2); color: #fff; }
.kpi.clickable { cursor: pointer; transition: transform .12s, box-shadow .15s; }
.kpi.clickable:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.delta { display: inline-flex; align-items: center; gap: 2px; font-size: 11.5px; font-weight: 700; padding: 2px 6px; border-radius: 6px; }
.delta.up { background: var(--tint-green); color: var(--green); }
.delta.down { background: var(--tint-red); color: var(--red); }
.delta.flat { background: var(--tint-slate); color: var(--muted); }
.ic-orange { background: var(--tint-orange); color: var(--flame); }
.ic-blue { background: var(--tint-blue); color: var(--blue); }
.ic-green { background: var(--tint-green); color: var(--green); }
.ic-red { background: var(--tint-red); color: var(--red); }
.ic-violet { background: var(--tint-violet); color: var(--violet); }
.ic-slate { background: var(--tint-slate); color: var(--muted); }

.chart-box { position: relative; height: 280px; }
.chart-box.sm { height: 220px; }
.chart-box.xs { height: 180px; }

/* ---------- badges, chips, avatars ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; background: var(--tint-slate); color: var(--muted); white-space: nowrap; }
.badge.orange { background: var(--tint-orange); color: #066B76; }
.badge.blue { background: var(--tint-blue); color: #2F7FDB; }
.badge.green { background: var(--tint-green); color: var(--green); }
.badge.red { background: var(--tint-red); color: var(--red); }
.badge.violet { background: var(--tint-violet); color: var(--violet); }
[data-theme="dark"] .badge.orange { color: #7FE6DB; }
[data-theme="dark"] .badge.blue { color: #7CB8FF; }
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 8px; background: var(--surface-3); font-size: 12px; font-weight: 500; color: var(--muted); white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center; color: #fff; font-size: 11.5px; font-weight: 700; flex: none; letter-spacing: .02em; }
.avatar.sm { width: 22px; height: 22px; font-size: 9.5px; }
.avatar.lg { width: 44px; height: 44px; font-size: 15px; }
.role-admin { background: var(--tint-orange); color: #066B76; }
.role-manager { background: var(--tint-blue); color: #2F7FDB; }
.role-executive { background: var(--tint-green); color: var(--green); }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .label { font-size: 12.5px; font-weight: 600; color: var(--text); }
.field .hint { font-size: 12px; color: var(--muted); }
.field .err { font-size: 12px; color: var(--red); font-weight: 500; }
.field.invalid .input { border-color: var(--red); }
.input, select.input, textarea.input {
  width: 100%; height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface);
  color: var(--text); font: inherit; transition: border-color .15s, box-shadow .15s;
}
textarea.input { height: auto; min-height: 90px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
select.input { appearance: none; padding-right: 32px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23889196' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 11px center; }
.input:hover { border-color: var(--line-strong); }
.input:focus { outline: none; border-color: var(--orange); box-shadow: var(--focus); }
.input::placeholder { color: var(--faint); }
.input.sm { height: 32px; font-size: 13px; border-radius: 8px; }
.input-icon { position: relative; }
.input-icon .icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.input-icon .input { padding-left: 36px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid .span2 { grid-column: 1 / -1; }
.form-section { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 700; grid-column: 1 / -1; margin-top: 6px; padding-top: 10px; border-top: 1px dashed var(--line); }
.form-section:first-child { border: 0; padding-top: 0; margin-top: 0; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; font-weight: 500; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch .track { width: 36px; height: 20px; border-radius: 20px; background: var(--line-strong); position: relative; transition: background .15s; flex: none; }
.switch .track::after { content: ''; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .15s; }
.switch input:checked + .track { background: var(--orange); }
.switch input:checked + .track::after { transform: translateX(16px); }
.switch input:focus-visible + .track { box-shadow: var(--focus); }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--orange); }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: separate; border-spacing: 0; }
table.tbl.wide { min-width: 860px; }
.tbl th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); font-weight: 700; padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface); position: sticky; top: 0; }
.tbl th.sortable { cursor: pointer; }
.tbl th.sortable:hover { color: var(--text); }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr { transition: background .1s; }
.tbl tbody tr.click { cursor: pointer; }
.tbl tbody tr:hover { background: var(--surface-2); }
.tbl .r { text-align: right; }
.tbl .actions { text-align: right; white-space: nowrap; width: 1%; }
.tbl .actions .btn { opacity: .0; }
.tbl tr:hover .actions .btn, .tbl .actions .btn:focus { opacity: 1; }
@media (hover: none) { .tbl .actions .btn { opacity: 1; } }
.tbl .primary-cell b { display: block; font-weight: 600; }
.tbl .primary-cell span { font-size: 12.5px; color: var(--muted); }
.tbl tfoot td { font-weight: 700; border-top: 1px solid var(--line-strong); border-bottom: 0; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .input-icon { width: 280px; max-width: 100%; }
@media (max-width: 640px) { .toolbar .input-icon { width: 100%; } }

/* ---------- empty / skeleton ---------- */
.empty { text-align: center; padding: 42px 20px; color: var(--muted); }
.empty .e-ic { width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center; margin: 0 auto 14px; background: var(--tint-orange); color: var(--flame); }
.empty h4 { margin: 0 0 6px; color: var(--text); font-size: 15px; }
.empty p { margin: 0 auto 16px; max-width: 380px; }
.skel { background: linear-gradient(90deg, var(--surface-3) 0%, var(--surface-2) 50%, var(--surface-3) 100%); background-size: 200% 100%; animation: sk 1.2s ease-in-out infinite; border-radius: 10px; }
@keyframes sk { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ---------- modal & drawer ---------- */
.overlay { position: fixed; inset: 0; background: rgba(20, 24, 26, .48); z-index: 100; display: grid; place-items: center; padding: 20px; animation: fade .15s ease; }
@keyframes fade { from { opacity: 0; } }
.modal { width: 100%; max-width: 560px; max-height: calc(100vh - 40px); background: var(--surface); border-radius: 18px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; animation: pop .18s cubic-bezier(.2, .9, .3, 1.2); }
.modal.wide { max-width: 760px; }
.modal.xl { max-width: 980px; }
.modal.narrow { max-width: 420px; }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }
.m-head { display: flex; align-items: flex-start; gap: 12px; padding: 20px 22px 6px; }
.m-head h3 { margin: 0; font-size: 17px; letter-spacing: -.01em; }
.m-head p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.m-body { padding: 14px 22px 18px; overflow-y: auto; }
.m-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 14px 22px 18px; border-top: 1px solid var(--line); align-items: center; }
.m-foot .left { margin-right: auto; }

.drawer-wrap { position: fixed; inset: 0; z-index: 90; background: rgba(20, 24, 26, .32); animation: fade .15s ease; }
.drawer { position: absolute; right: 0; top: 0; bottom: 0; width: min(720px, 100vw); background: var(--bg); box-shadow: var(--shadow-lg); display: flex; flex-direction: column; animation: slide .22s cubic-bezier(.2, .8, .2, 1); }
@keyframes slide { from { transform: translateX(40px); opacity: .4; } }
.d-head { padding: 18px 22px 14px; background: var(--surface); border-bottom: 1px solid var(--line); }
.d-body { flex: 1; overflow-y: auto; padding: 18px 22px 30px; }

/* ---------- toasts ---------- */
#toasts { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.toast { display: flex; align-items: center; gap: 10px; background: #142B3D; color: #fff; padding: 11px 14px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 500; max-width: 420px; animation: pop .2s ease; }
.toast .icon { color: var(--orange); }
.toast.error .icon { color: #FF8A8E; }
.toast.ok .icon { color: #5BE0B0; }
.toast button { background: none; border: 0; color: var(--orange); font-weight: 700; cursor: pointer; padding: 0 0 0 6px; }
@media (max-width: 640px) { #toasts { left: 16px; right: 16px; align-items: stretch; } }

/* ---------- dropdown menu ---------- */
.menu { position: fixed; z-index: 150; min-width: 200px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; animation: pop .12s ease; }
.menu button, .menu a { display: flex; width: 100%; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; border: 0; background: none; cursor: pointer; text-align: left; font-weight: 500; }
.menu button:hover, .menu a:hover { background: var(--surface-3); }
.menu .sep { height: 1px; background: var(--line); margin: 6px 0; }
.menu .danger { color: var(--red); }

/* ---------- command palette ---------- */
.palette { width: 100%; max-width: 620px; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden; align-self: start; margin-top: 10vh; animation: pop .15s ease; }
.palette .p-in { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.palette input { flex: 1; border: 0; background: none; font: inherit; font-size: 16px; color: var(--text); outline: none; box-shadow: none !important; }
.palette .p-list { max-height: 50vh; overflow-y: auto; padding: 8px; }
.palette .p-group { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); padding: 10px 10px 4px; font-weight: 700; }
.palette .p-item { display: flex; gap: 12px; align-items: center; padding: 9px 10px; border-radius: 10px; cursor: pointer; }
.palette .p-item.on, .palette .p-item:hover { background: var(--tint-orange); }
.palette .p-item .p-ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-3); color: var(--muted); flex: none; }
.palette .p-item small { display: block; color: var(--muted); font-size: 12px; }
.palette .p-foot { display: flex; gap: 14px; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--faint); }

/* ---------- Kanban ---------- */
.kanban-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 6px 0 14px; }
.kanban { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 16px; align-items: flex-start; min-height: calc(100vh - 210px); scroll-snap-type: x proximity; }
.kanban::-webkit-scrollbar { height: 10px; }
.kanban::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 10px; border: 3px solid var(--bg); }
.kcol { flex: 0 0 292px; background: var(--surface-3); border-radius: 16px; display: flex; flex-direction: column; max-height: calc(100vh - 200px); scroll-snap-align: start; }
[data-theme="dark"] .kcol { background: #181D1F; }
.kcol-h { padding: 12px 12px 10px; display: flex; flex-direction: column; gap: 8px; }
.kcol-h .t { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13.5px; }
.kcol-h .t .sw { width: 10px; height: 10px; border-radius: 3px; }
.kcol-h .t .n { color: var(--muted); font-weight: 600; background: var(--surface); border-radius: 8px; padding: 1px 7px; font-size: 12px; }
.kcol-h .v { font-size: 12.5px; color: var(--muted); font-weight: 600; display: flex; justify-content: space-between; }
.kcol-h .bar { height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.kcol-h .bar i { display: block; height: 100%; border-radius: 3px; }
.kcol-b { flex: 1; overflow-y: auto; padding: 2px 10px 10px; display: flex; flex-direction: column; gap: 8px; min-height: 80px; scrollbar-width: thin; }
.kcol-add { margin: 0 10px 10px; border: 1px dashed var(--line-strong); background: transparent; color: var(--muted); border-radius: 10px; padding: 8px; cursor: pointer; font-weight: 600; font-size: 12.5px; display: flex; gap: 6px; justify-content: center; align-items: center; }
.kcol-add:hover { color: var(--flame); border-color: var(--orange); background: var(--surface); }
.kcard { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 11px 12px; box-shadow: var(--shadow-sm); cursor: grab; user-select: none; -webkit-user-select: none; position: relative; transition: box-shadow .15s, transform .15s, border-color .15s; }
.kcard:hover { box-shadow: var(--shadow); border-color: var(--line-strong); }
.kcard:active { cursor: grabbing; }
.kcard .kc-top { display: flex; gap: 8px; align-items: flex-start; }
.kcard .kc-title { font-weight: 650; font-size: 13.5px; line-height: 1.3; flex: 1; min-width: 0; }
.kcard .kc-co { font-size: 12.5px; color: var(--muted); margin-top: 3px; display: flex; gap: 5px; align-items: center; }
.kcard .kc-val { font-weight: 700; font-size: 14px; margin-top: 10px; letter-spacing: -.01em; }
.kcard .kc-foot { display: flex; align-items: center; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.kcard .kc-foot .right { margin-left: auto; }
.kcard .star { color: var(--orange); }
.kcard.prio-high { border-left: 3px solid var(--flame); }
.kcard .due { font-size: 11.5px; font-weight: 600; display: inline-flex; align-items: center; gap: 4px; color: var(--muted); }
.kcard .due.overdue { color: var(--red); }
.kcard .due.today { color: var(--flame); }
.kcard .auto { font-size: 11px; display: inline-flex; gap: 4px; align-items: center; color: var(--blue); font-weight: 600; }
.sortable-ghost { opacity: .35; border-style: dashed; }
.sortable-chosen { box-shadow: var(--shadow-lg) !important; transform: rotate(1.2deg); }
.sortable-drag { opacity: 1 !important; }
.kcol.drop-target { outline: 2px dashed var(--orange); outline-offset: -2px; }
.k-empty { color: var(--faint); font-size: 12.5px; text-align: center; padding: 18px 6px; border: 1px dashed var(--line-strong); border-radius: 12px; }
.kcol.won .kcol-h .t { color: var(--green); }

/* lead detail */
.lead-hero { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.lead-hero h2 { margin: 0; font-size: 20px; letter-spacing: -.015em; }
.lead-hero .meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; align-items: center; }
.stage-track { display: flex; gap: 4px; margin-top: 16px; }
.stage-track button { flex: 1; border: 0; height: 30px; font-size: 11.5px; font-weight: 600; cursor: pointer; background: var(--surface-3); color: var(--muted); clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 50%, calc(100% - 9px) 100%, 0 100%, 9px 50%); padding: 0 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stage-track button:first-child { clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 50%, calc(100% - 9px) 100%, 0 100%); border-radius: 8px 0 0 8px; }
.stage-track button.done { background: var(--peach); color: #055762; }
[data-theme="dark"] .stage-track button.done { background: rgba(6, 107, 118, .25); color: #7FE6DB; }
.stage-track button.cur { background: var(--grad); color: #fff; }
.stage-track button:hover:not(.cur) { filter: brightness(.96); }
@media (max-width: 640px) { .stage-track { overflow-x: auto; } .stage-track button { flex: 0 0 auto; } }
@media (max-width: 640px) {
  .lead-hero { flex-direction: column; gap: 6px; }
  .lead-hero > div:last-child { text-align: left !important; }
  .d-head, .d-body { padding-left: 16px !important; padding-right: 16px !important; }
  .lead-hero h2 { font-size: 18px; }
}
.info-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
.info-list .k { font-size: 11.5px; color: var(--faint); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.info-list .v { margin-top: 2px; font-weight: 500; word-break: break-word; }
.info-list .v a { color: var(--flame); }
@media (max-width: 560px) { .info-list { grid-template-columns: 1fr; } }

.timeline { position: relative; display: flex; flex-direction: column; gap: 2px; }
.tl-item { display: flex; gap: 12px; padding: 10px 0; position: relative; }
.tl-item::before { content: ''; position: absolute; left: 15px; top: 40px; bottom: -6px; width: 2px; background: var(--line); }
.tl-item:last-child::before { display: none; }
.tl-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.tl-body { flex: 1; min-width: 0; }
.tl-body .who { font-size: 12px; color: var(--muted); }
.tl-body .txt { margin-top: 2px; white-space: pre-wrap; word-break: break-word; }

.composer { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px; }
.composer textarea { border: 0; width: 100%; resize: vertical; min-height: 64px; font: inherit; background: none; color: var(--text); outline: none; padding: 4px; }

/* follow-up sequence */
.seq { display: flex; flex-direction: column; gap: 8px; }
.seq-item { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.seq-item .s-ic { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex: none; font-weight: 700; font-size: 12px; }
.seq-item.sent .s-ic { background: var(--tint-green); color: var(--green); }
.seq-item.pending .s-ic { background: var(--tint-blue); color: var(--blue); }
.seq-item.cancelled .s-ic, .seq-item.failed .s-ic { background: var(--tint-slate); color: var(--muted); }
.seq-item.failed .s-ic { background: var(--tint-red); color: var(--red); }
.seq-item.cancelled { opacity: .65; }
.seq-item .s-b { flex: 1; min-width: 0; }
.seq-item .s-b b { font-size: 13px; display: block; }
.seq-item .s-b span { font-size: 12px; color: var(--muted); }
.callout { display: flex; gap: 12px; padding: 12px 14px; border-radius: 12px; background: var(--tint-orange); color: var(--text); align-items: flex-start; }
.callout .icon { color: var(--flame); margin-top: 1px; }
.callout.blue { background: var(--tint-blue); }
.callout.blue .icon { color: var(--blue); }
.callout.red { background: var(--tint-red); }
.callout.red .icon { color: var(--red); }
.callout.green { background: var(--tint-green); }
.callout.green .icon { color: var(--green); }

/* dropzone */
.drop { border: 1.5px dashed var(--line-strong); border-radius: 12px; padding: 16px; text-align: center; color: var(--muted); cursor: pointer; transition: border-color .15s, background .15s; }
.drop:hover, .drop.over { border-color: var(--orange); background: var(--tint-orange); }
.drop b { color: var(--flame); }
.file-pill { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }

/* ---------- My Day ---------- */
.hello { display: flex; align-items: center; gap: 18px; padding: 22px 24px; border-radius: 18px; color: #fff; position: relative; overflow: hidden; margin: 8px 0 18px;
  background: radial-gradient(700px 300px at 100% 0%, rgba(6, 107, 118, .55), transparent 60%), radial-gradient(600px 300px at 0% 120%, rgba(6, 107, 118, .5), transparent 60%), #142B3D; }
.hello h2 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 26px; }
.hello p { margin: 6px 0 0; color: #D7DDDF; }
.hello .hstats { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.hello .hs { background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .12); border-radius: 12px; padding: 10px 14px; min-width: 98px; }
.hello .hs b { display: block; font-size: 22px; letter-spacing: -.02em; }
.hello .hs span { font-size: 12px; color: #D7DDDF; }
.hello .hs.alert b { color: #7FE6DB; }
@media (max-width: 900px) { .hello { flex-direction: column; align-items: flex-start; } .hello .hstats { margin-left: 0; } }
.task { display: flex; align-items: flex-start; gap: 12px; padding: 11px 16px; border-bottom: 1px solid var(--line); transition: background .1s; }
.task:last-child { border-bottom: 0; }
.task:hover { background: var(--surface-2); }
.task .tick { width: 20px; height: 20px; border-radius: 6px; border: 2px solid var(--line-strong); background: none; cursor: pointer; flex: none; display: grid; place-items: center; margin-top: 1px; color: transparent; transition: all .15s; }
.task .tick:hover { border-color: var(--orange); color: var(--orange); }
.task.done .tick { background: var(--green); border-color: var(--green); color: #fff; }
.task.done .t-title { text-decoration: line-through; color: var(--faint); }
.task .t-title { font-weight: 550; }
.task .t-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; font-size: 12px; color: var(--muted); align-items: center; }
.task .t-meta .overdue { color: var(--red); font-weight: 600; }
.task .t-meta .today { color: var(--flame); font-weight: 600; }
.task .t-act { margin-left: auto; display: flex; gap: 4px; opacity: 0; }
.task:hover .t-act { opacity: 1; }
@media (hover: none) { .task .t-act { opacity: 1; } }
.sec-title { display: flex; align-items: center; gap: 8px; padding: 12px 16px 8px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--faint); }
.sec-title .n { background: var(--surface-3); border-radius: 8px; padding: 0 7px; color: var(--muted); }
.sec-title.red { color: var(--red); }
.fu { display: flex; gap: 12px; align-items: center; padding: 11px 16px; border-bottom: 1px solid var(--line); cursor: pointer; }
.fu:hover { background: var(--surface-2); }
.fu:last-child { border-bottom: 0; }
.quickadd { display: flex; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.quickadd .input { border-style: dashed; }

/* ---------- Sticky notes ---------- */
.notes-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; align-items: start; }
.note { --nb: #FDEBD3; --nt: #5B3A12; border-radius: 4px 4px 18px 4px; padding: 14px 14px 10px; min-height: 190px; display: flex; flex-direction: column; background: var(--nb); color: var(--nt);
  box-shadow: 0 1px 1px rgba(0,0,0,.05), 0 8px 18px -8px rgba(60, 40, 10, .3); position: relative; transition: transform .15s, box-shadow .15s; }
.note:hover { transform: translateY(-2px) rotate(-.3deg); box-shadow: 0 2px 2px rgba(0,0,0,.05), 0 16px 26px -10px rgba(60, 40, 10, .35); }
.note::after { content: ''; position: absolute; right: 0; bottom: 0; width: 22px; height: 22px; background: linear-gradient(135deg, rgba(0,0,0,.08) 50%, transparent 50%); border-radius: 0 0 16px 0; transform: rotate(180deg); opacity: .6; }
.note.c-peach { --nb: #FCE3C6; --nt: #5E3A10; }
.note.c-orange { --nb: #FFCB8F; --nt: #5A2E04; }
.note.c-yellow { --nb: #FFF1A8; --nt: #4E430D; }
.note.c-blue { --nb: #CFE5FF; --nt: #133A66; }
.note.c-green { --nb: #CDEFD9; --nt: #0F4A2B; }
.note.c-pink { --nb: #FBD3E2; --nt: #5E1736; }
.note.c-slate { --nb: #DDE3E6; --nt: #263035; }
[data-theme="dark"] .note { filter: saturate(.85) brightness(.92); }
.note input.n-title { border: 0; background: none; font: inherit; font-weight: 700; font-size: 14.5px; color: inherit; outline: none; padding: 0; width: 100%; }
.note textarea.n-body { border: 0; background: none; font: inherit; font-size: 13.5px; line-height: 1.55; color: inherit; outline: none; resize: none; flex: 1; min-height: 110px; padding: 6px 0 0; width: 100%; }
.note input::placeholder, .note textarea::placeholder { color: inherit; opacity: .45; }
.note .n-foot { display: flex; align-items: center; gap: 4px; margin-top: 6px; opacity: .0; transition: opacity .15s; }
.note:hover .n-foot, .note:focus-within .n-foot { opacity: 1; }
@media (hover: none) { .note .n-foot { opacity: 1; } }
.note .n-foot button { border: 0; background: rgba(255,255,255,.35); color: inherit; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; }
.note .n-foot button:hover { background: rgba(255,255,255,.65); }
.note .n-foot .saved { font-size: 11px; opacity: .6; margin-left: auto; }
.note .pin { position: absolute; top: -7px; left: 50%; transform: translateX(-50%); width: 14px; height: 14px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #4FB3BD, #055762); box-shadow: 0 2px 3px rgba(0,0,0,.3); }
.note .handle { cursor: grab; }
.swatches { display: flex; gap: 4px; }
.swatches button { width: 18px !important; height: 18px !important; border-radius: 50% !important; border: 2px solid rgba(255,255,255,.7) !important; }
.note-new { border: 2px dashed var(--line-strong); border-radius: 16px; min-height: 190px; display: grid; place-items: center; color: var(--muted); cursor: pointer; background: transparent; font-weight: 600; transition: all .15s; }
.note-new:hover { border-color: var(--orange); color: var(--flame); background: var(--tint-orange); }

/* ---------- vendors ---------- */
.vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.vcard { padding: 16px; cursor: pointer; transition: box-shadow .15s, transform .15s; display: flex; flex-direction: column; gap: 12px; }
.vcard:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.vcard .v-top { display: flex; gap: 12px; align-items: center; }
.vlogo { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; color: #fff; font-size: 15px; flex: none; background: var(--grad); }
.vcard .v-contact { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.vcard .v-contact a { display: flex; align-items: center; gap: 8px; color: var(--text); }
.vcard .v-contact a:hover { color: var(--flame); }
.vcard .v-contact .icon { color: var(--faint); }
.contact-rows { display: flex; flex-direction: column; gap: 10px; }
.contact-row { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1.3fr auto; gap: 8px; align-items: center; }
@media (max-width: 760px) { .contact-row { grid-template-columns: 1fr 1fr; } }

/* ---------- google ---------- */
.g-src { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; }
.g-src .gdot { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; }
.bar-list { display: flex; flex-direction: column; gap: 9px; }
.bar-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; font-size: 13px; }
.bar-row .lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-row .val { font-weight: 600; font-variant-numeric: tabular-nums; }
.bar-row .track { grid-column: 1 / -1; height: 6px; border-radius: 6px; background: var(--surface-3); overflow: hidden; }
.bar-row .track i { display: block; height: 100%; border-radius: 6px; background: var(--grad); }
.bar-row .track i.blue { background: linear-gradient(90deg, #52A2FF, #3B82F6); }
.sample-banner { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 12px; border: 1px dashed var(--orange); background: var(--tint-orange); margin-bottom: 16px; flex-wrap: wrap; }

/* ---------- reports ---------- */
.rep-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 18px; }
.rep-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 80px; align-self: start; }
.rep-nav button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; border: 0; background: none; text-align: left; cursor: pointer; font-weight: 600; color: var(--muted); }
.rep-nav button:hover { background: var(--surface); color: var(--text); }
.rep-nav button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.rep-nav button.on .icon { color: var(--flame); }
@media (max-width: 960px) { .rep-layout { grid-template-columns: 1fr; } .rep-nav { position: static; flex-direction: row; overflow-x: auto; } .rep-nav button { white-space: nowrap; } }

/* ---------- IAM ---------- */
.perm-table th, .perm-table td { text-align: center; }
.perm-table td:first-child, .perm-table th:first-child { text-align: left; }
.perm-table .grp td { background: var(--surface-2); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.role-card { padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.role-card h4 { margin: 0; display: flex; align-items: center; gap: 8px; font-size: 15px; }

/* integrations */
.code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; background: #0F2230; color: #E7ECEE; border-radius: 12px; padding: 14px 16px; overflow-x: auto; white-space: pre; line-height: 1.55; }
.code .c { color: #7FE6DB; }
.inline-code { font-family: ui-monospace, Menlo, monospace; font-size: 12px; background: var(--surface-3); padding: 2px 6px; border-radius: 6px; word-break: break-all; }
.secret-box { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); font-family: ui-monospace, Menlo, monospace; font-size: 13px; word-break: break-all; }

/* settings */
.set-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 20px; }
@media (max-width: 960px) { .set-layout { grid-template-columns: 1fr; } }
.stage-row { display: grid; grid-template-columns: auto 34px minmax(0, 1fr) 90px auto auto; gap: 10px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); margin-bottom: 8px; }
.stage-row .handle { cursor: grab; color: var(--faint); }
.stage-row input[type=color] { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 8px; padding: 2px; background: var(--surface); cursor: pointer; }
@media (max-width: 760px) { .stage-row { grid-template-columns: auto 34px 1fr; } .stage-row > :nth-child(n+4) { grid-column: 2 / -1; } }
.tpl { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); padding: 14px; display: flex; gap: 14px; align-items: flex-start; }
.tpl .day { width: 52px; height: 52px; border-radius: 12px; background: var(--tint-orange); color: var(--flame); display: grid; place-items: center; text-align: center; font-weight: 800; line-height: 1; flex: none; font-size: 18px; }
.tpl .day small { display: block; font-size: 10px; font-weight: 700; text-transform: uppercase; margin-top: 2px; }
.tpl.off { opacity: .55; }
.var-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.var-chips button { border: 1px solid var(--line); background: var(--surface-2); border-radius: 6px; padding: 3px 7px; font-size: 11.5px; font-family: ui-monospace, Menlo, monospace; cursor: pointer; color: var(--muted); }
.var-chips button:hover { border-color: var(--orange); color: var(--flame); }

/* misc */
.list-row { display: flex; align-items: center; gap: 12px; padding: 10px 18px; border-bottom: 1px solid var(--line); }
.list-row:last-child { border-bottom: 0; }
.list-row.click { cursor: pointer; }
.list-row.click:hover { background: var(--surface-2); }
.progress { height: 6px; background: var(--surface-3); border-radius: 6px; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--grad); border-radius: 6px; }
.dot-sep::before { content: '·'; margin: 0 4px; color: var(--faint); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.link { color: var(--flame); font-weight: 600; cursor: pointer; }
.link:hover { text-decoration: underline; }
hr.sep { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.stat-inline { display: flex; gap: 22px; flex-wrap: wrap; }
.stat-inline div b { display: block; font-size: 18px; letter-spacing: -.01em; }
.stat-inline div span { font-size: 12px; color: var(--muted); }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding: 12px 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }

@media print {
  .sidebar, .topbar, .rep-nav, .no-print, #toasts { display: none !important; }
  .shell { display: block; }
  .page { padding: 0; }
  .card { box-shadow: none; break-inside: avoid; }
  body { background: #fff; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ======================= People & HR ======================= */
.hr-hero { position: relative; overflow: hidden; border-radius: 22px; padding: 22px 22px 18px; color: #fff; margin: 8px 0 16px;
  background: radial-gradient(500px 260px at 110% -20%, rgba(255,255,255,.22), transparent 60%), #066B76;
  box-shadow: 0 14px 34px rgba(6, 107, 118, .28); }
.hr-hero .who { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.hr-hero .who .avatar { box-shadow: 0 0 0 2px rgba(255,255,255,.6); }
.hr-hero .big { font-size: 34px; font-weight: 800; letter-spacing: -.03em; margin: 14px 0 2px; font-variant-numeric: tabular-nums; }
.hr-hero .big small { font-size: 15px; font-weight: 600; opacity: .85; margin-right: 4px; }
.hr-hero .lbl { opacity: .88; font-size: 13px; }
.hr-hero .meta { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 14px; font-size: 13px; }
.hr-hero .meta b { display: block; font-size: 15px; }
.hr-hero .rings { position: absolute; right: -60px; top: -40px; width: 260px; height: 260px; border-radius: 50%; border: 26px solid rgba(255,255,255,.08); pointer-events: none; }
.hr-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px; }
.hr-actions button { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.22); color: #fff; border-radius: 14px; padding: 10px 6px; display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 600; font-size: 12px; cursor: pointer; transition: background .15s; }
.hr-actions button:hover { background: rgba(255,255,255,.26); }
.hr-actions .ic { width: 36px; height: 36px; border-radius: 50%; background: #fff; color: var(--flame); display: grid; place-items: center; }
.chip-tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 0 16px; padding: 2px; }
.chip-tabs::-webkit-scrollbar { display: none; }
.chip-tabs button { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 7px 14px; font-weight: 600; font-size: 13px; color: var(--muted); cursor: pointer; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.chip-tabs button.on { background: var(--ink); border-color: var(--ink); color: #fff; }
[data-theme="dark"] .chip-tabs button.on { background: #E9EDEE; color: #1C2225; border-color: #E9EDEE; }
.chip-tabs .dot-n { background: var(--flame); color: #fff; border-radius: 10px; font-size: 10.5px; padding: 0 6px; line-height: 17px; }
.hr-list .item { display: flex; align-items: center; gap: 12px; padding: 13px 16px; border-bottom: 1px solid var(--line); cursor: pointer; transition: background .1s; }
.hr-list .item:last-child { border-bottom: 0; }
.hr-list .item:hover { background: var(--surface-2); }
.hr-list .item .ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.hr-list .item .t { flex: 1; min-width: 0; }
.hr-list .item .t b { display: block; font-weight: 600; }
.hr-list .item .t span { font-size: 12.5px; color: var(--muted); }
.hr-list .item.done { opacity: .6; }
.hr-list .item.done .ic { background: var(--tint-green); color: var(--green); }
.bal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.bal { padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); position: relative; overflow: hidden; }
.bal .n { font-size: 26px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.bal .n small { font-size: 12px; font-weight: 600; color: var(--muted); margin-left: 3px; }
.bal .nm { font-size: 12.5px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.bal .nm i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.bal .bar { height: 5px; border-radius: 5px; background: var(--surface-3); margin-top: 10px; overflow: hidden; }
.bal .bar i { display: block; height: 100%; border-radius: 5px; }
.bal .sub { font-size: 11.5px; color: var(--faint); margin-top: 6px; }
.req { display: flex; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); align-items: flex-start; }
.req:last-child { border-bottom: 0; }
.req .date-tile { width: 50px; flex: none; text-align: center; border-radius: 12px; background: var(--surface-3); padding: 6px 0; }
.req .date-tile b { display: block; font-size: 18px; line-height: 1.1; }
.req .date-tile span { font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; }
.req .body { flex: 1; min-width: 0; }
.req .body .k { font-size: 12.5px; color: var(--muted); }
.req .acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.ins-card { position: relative; border-radius: 18px; padding: 20px; color: #fff; overflow: hidden; min-height: 190px; display: flex; flex-direction: column; justify-content: space-between;
  background: radial-gradient(400px 200px at 110% 0%, rgba(6,107,118,.45), transparent 60%), linear-gradient(135deg, #142B3D, #1B2124); box-shadow: 0 16px 30px rgba(20,24,26,.3); }
.ins-card .brand { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.ins-card .brand img { height: 22px; }
.ins-card .plan { font-size: 18px; font-weight: 700; margin-top: 10px; }
.ins-card .row2 { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; font-size: 12px; opacity: .9; }
.ins-card .row2 b { display: block; font-size: 14px; letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.ins-card .chip { background: rgba(255,255,255,.14); color: #fff; }
.cover-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px 16px; }
.cover-list div { display: flex; gap: 8px; align-items: center; font-size: 13.5px; }
.cover-list .icon { color: var(--green); }
.txn { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.txn:last-child { border-bottom: 0; }
.txn .ic { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.txn .amt { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.contract-head { border-radius: 18px; padding: 18px; background: var(--surface); border: 1px solid var(--line); }
.contract-terms { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.term { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; display: flex; gap: 10px; align-items: center; background: var(--surface-2); }
.term .icon { color: var(--flame); }
.term small { display: block; font-size: 11.5px; color: var(--muted); }
.term b { font-size: 14px; }
.party { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.party:last-child { border-bottom: 0; }
.signed-pill { margin-left: auto; padding: 6px 12px; border-radius: 10px; font-weight: 700; font-size: 12.5px; background: var(--tint-green); color: var(--green); }
.signed-pill.wait { background: var(--tint-orange); color: #066B76; }
.contract-text { white-space: pre-wrap; font-size: 13.5px; line-height: 1.65; max-height: 46vh; overflow-y: auto; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.sigpad { position: relative; border: 1.5px dashed var(--line-strong); border-radius: 12px; background: var(--surface); height: 150px; touch-action: none; cursor: crosshair; }
.sigpad canvas { width: 100%; height: 100%; display: block; border-radius: 12px; }
.sigpad .ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); pointer-events: none; font-weight: 500; }
.sigpad .clear { position: absolute; top: 8px; right: 8px; }
.sigpad .base { position: absolute; left: 18px; right: 18px; bottom: 34px; border-bottom: 1px solid var(--line-strong); pointer-events: none; }
.doc-card { display: flex; gap: 14px; padding: 14px 16px; border-bottom: 1px solid var(--line); align-items: center; }
.doc-card:last-child { border-bottom: 0; }
.doc-card .ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--tint-blue); color: var(--blue); flex: none; }
.scan-box { border: 2px dashed var(--line-strong); border-radius: 16px; padding: 22px; text-align: center; cursor: pointer; transition: all .15s; background: var(--surface-2); }
.scan-box:hover, .scan-box.over { border-color: var(--orange); background: var(--tint-orange); }
.scan-box .e-ic { width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center; margin: 0 auto 10px; background: var(--grad); color: #fff; }
.scan-preview { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); margin-bottom: 14px; }
.scan-preview img { width: 54px; height: 54px; object-fit: cover; border-radius: 8px; }
.ai-chip { display: inline-flex; gap: 4px; align-items: center; font-size: 11px; font-weight: 700; color: var(--green); background: var(--tint-green); border-radius: 6px; padding: 1px 6px; margin-left: 6px; }
.scanning { display: flex; align-items: center; gap: 12px; padding: 18px; border-radius: 14px; background: var(--tint-orange); font-weight: 600; }
.spinner { width: 20px; height: 20px; border-radius: 50%; border: 2.5px solid var(--orange); border-right-color: transparent; animation: spin .7s linear infinite; flex: none; }

/* team calendar */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--line); gap: 1px; }
.cal .dow { background: var(--surface-2); text-align: center; font-size: 11px; font-weight: 700; color: var(--faint); text-transform: uppercase; letter-spacing: .06em; padding: 8px 0; }
.cal .day { background: var(--surface); min-height: 104px; padding: 6px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cal .day.out { background: var(--surface-2); opacity: .55; }
.cal .day.weekend { background: var(--surface-2); }
.cal .day.today { box-shadow: inset 0 0 0 2px var(--orange); }
.cal .day .dn { font-size: 12px; font-weight: 700; color: var(--muted); display: flex; justify-content: space-between; }
.cal .day .hol { font-size: 10.5px; font-weight: 700; color: var(--green); background: var(--tint-green); border-radius: 5px; padding: 1px 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal .who { font-size: 11px; font-weight: 600; border-radius: 5px; padding: 2px 5px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal .who.pending { background: transparent !important; border: 1px dashed currentColor; }
@media (max-width: 760px) { .cal .day { min-height: 66px; padding: 4px; } .cal .who { font-size: 0; height: 6px; padding: 0; } .cal .day .hol { font-size: 0; height: 6px; padding: 0; } }

.payslip-row td { vertical-align: top; }
.line-editor .lrow { display: grid; grid-template-columns: 1fr 130px 34px; gap: 8px; margin-bottom: 8px; }

/* mobile bottom navigation (app-like) */
.bottom-nav { display: none; }
@media (max-width: 760px) {
  .bottom-nav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; background: color-mix(in srgb, var(--surface) 94%, transparent);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); }
  .bottom-nav a, .bottom-nav button { border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; font-weight: 600; color: var(--muted); padding: 4px 0; cursor: pointer; position: relative; }
  .bottom-nav .on { color: var(--flame); }
  .bottom-nav .fab { width: 46px; height: 46px; margin: -18px auto 0; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; box-shadow: 0 6px 16px rgba(6,107,118,.35); }
  .bottom-nav .bn-badge { position: absolute; top: 0; right: calc(50% - 18px); background: var(--flame); color: #fff; border-radius: 9px; font-size: 9.5px; min-width: 16px; height: 16px; display: grid; place-items: center; padding: 0 4px; }
  .page { padding-bottom: calc(86px + env(safe-area-inset-bottom)); }
  #toasts { bottom: calc(80px + env(safe-area-inset-bottom)); }
  .hr-hero .big { font-size: 30px; }
}

/* Workspace refresh: shared surfaces and rhythm across every module. */
:root {
  --bg: #F6F9FA;
  --surface-2: #F8FBFC;
  --surface-3: #EEF4F6;
  --line: #E1EAEE;
  --line-strong: #C9D8DF;
  --text: #142B3D;
  --muted: #465E6D;
  --faint: #6F8492;
  --sidebar: #FFFFFF;
  --sidebar-2: #FFFFFF;
  --sidebar-text: #304957;
  --grad: #066B76;
  --display: 'Space Grotesk', var(--font);
  --radius: 14px;
  --sb-w: 244px;
  --shadow-sm: 0 2px 4px rgba(24, 39, 62, .025);
  --shadow: 0 8px 24px rgba(24, 39, 62, .065);
}
[data-theme="dark"] {
  --bg: #0B1822;
  --surface: #11222E;
  --surface-2: #152835;
  --surface-3: #1B3240;
  --line: #213A49;
  --line-strong: #31505F;
  --text: #E6EEF2;
  --muted: #A3B5C0;
  --faint: #8197A4;
  --sidebar: #0E1E29;
  --sidebar-2: #0E1E29;
  --sidebar-text: #B7C8D1;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, .12);
  --shadow: 0 8px 24px rgba(0, 0, 0, .2);
}
body { line-height: 1.5; }
.sb-head { min-height: 82px; padding: 24px 24px 18px; }
.sb-head .logo-full { height: auto; width: 174px; }
.sb-workspace { display: flex; gap: 10px; align-items: center; margin: 0 16px 8px; padding: 12px; border: 1px solid #3A414E; border-radius: 10px; background: rgba(255,255,255,.025); }
.workspace-monogram { width: 30px; height: 30px; display: grid; place-items: center; background: #E3F1F2; color: #066B76; border-radius: 8px; font-weight: 800; flex: none; }
.sb-workspace > div { min-width: 0; }
.sb-workspace b { display: block; color: #EDF0F5; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-workspace small { display: block; font-size: 10px; color: #A1ABBA; margin-top: 2px; }
.collapsed .sb-workspace { display: none; }
.sb-nav { padding: 0 14px 14px; }
.sb-group { font-size: 9px; letter-spacing: .14em; font-weight: 700; color: #929DAD; padding-top: 22px; padding-bottom: 8px; }
.sb-link { font-size: 12.5px; border-radius: 8px; padding: 10px 12px; margin: 3px 0; }
.sb-link .icon { width: 17px; height: 17px; opacity: .85; }
.sb-link.active { background: #3B302B; color: #FFD2AF; }
.sb-link.active::before { left: -14px; top: 10px; bottom: 10px; background: #066B76; }
.sb-foot { background: var(--sidebar-2); padding: 14px; }
.topbar { min-height: 82px; padding: 16px 32px; background: var(--surface); border-bottom-color: var(--line); }
.tb-title h1 { font-size: 15px; letter-spacing: -.025em; }
.tb-title .crumb { font-size: 10.5px; margin-top: 2px; }
.searchbtn { background: var(--surface-2); min-width: 290px; font-size: 12px; height: 38px; box-shadow: none; }
.page { padding: 26px 32px 48px; margin: 0 auto; }
.page-head { margin: 0 0 24px; }
.page-head h2 { font-weight: 700; font-size: 27px; letter-spacing: -.045em; }
.page-head p { font-size: 12px; margin-top: 7px; }
.btn { border-radius: 8px; font-size: 12px; }
.btn.primary { box-shadow: 0 2px 4px rgba(6, 107, 118, .15); }
.btn.primary:hover { box-shadow: 0 4px 10px rgba(6, 107, 118, .22); }
.card-h { padding: 21px 22px 0; flex-wrap: wrap; }
.card-h h3 { font-size: 13px; font-weight: 700; }
.card-h .sub { font-size: 11px; }
.card-b { padding: 20px 22px 22px; }
.grid { gap: 20px; }
.mt { margin-top: 20px; }
.kpis { gap: 16px; margin-bottom: 24px; }
.kpi { padding: 20px; border-radius: 14px; }
.kpi .k-top { font-size: 11px; gap: 9px; }
.kpi .k-ic { width: 32px; height: 32px; border-radius: 10px; }
.kpi .k-val { font-size: 28px; letter-spacing: -.045em; margin: 16px 0 10px; }
.kpi .k-sub { font-size: 10.5px; min-height: 20px; }
.kpi.hero { background: #142B3D; border-color: #142B3D; box-shadow: var(--shadow-sm); }
.kpi.hero .k-ic { background: #1F4152 !important; color: #7FE6DB !important; }
.kpi.hero .delta { background: #314C44; color: #A7E7CD; }
.kpi.hero .delta.down { background: #593A3F; color: #FFBCC2; }
.kpi.hero .delta.flat { background: #424B5C; color: #E0E5EE; }
.tbl th { padding: 13px 18px; background: var(--surface-2); font-size: 10px; color: var(--muted); }
.tbl td { padding: 15px 18px; font-size: 12.5px; }
.tbl .actions .btn { opacity: .65; }
.table-wrap { border-radius: inherit; }
.toolbar { gap: 12px; margin-bottom: 20px; }
.input { border-radius: 8px; }
.input:focus { border-color: #066B76; }
.list-row { padding: 14px 22px; }
.badge { font-size: 10.5px; }
.kcol { background: var(--surface-3); border: 1px solid var(--line); border-radius: 12px; }
[data-theme="dark"] .kcol { background: var(--surface-2); }
.kcol-h { padding: 16px; }
.kcol-b { gap: 12px; }
.kcard { padding: 16px; border-radius: 10px; }
.kcard .kc-title { line-height: 1.5; }
.kcard .kc-val { margin-top: 16px; font-size: 16px; }
.kcard .kc-foot { padding-top: 12px; border-top: 1px solid var(--line); }
.progress { height: 6px; }
.dashboard-welcome { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 30px; padding: 28px 30px; border: 1px solid #D7E6EB; border-radius: 16px; background: #EEF5F7; }
.eyebrow { font-size: 9px; font-weight: 700; letter-spacing: .17em; color: #066B76; margin-bottom: 10px; }
.dashboard-welcome h2 { font-size: 29px; font-weight: 600; letter-spacing: -.045em; line-height: 1.25; margin: 0; }
.dashboard-welcome p { font-size: 12px; color: var(--muted); margin: 9px 0 0; }
.welcome-action { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-radius: 12px; border: 1px solid #D7E6EB; background: rgba(255,255,255,.55); flex-shrink: 0; transition: background .15s; }
.welcome-action:hover { background: var(--surface); }
.welcome-action b { display: block; font-size: 12px; }
.welcome-action small { display: block; color: #066B76; font-size: 11px; margin-top: 4px; }
.welcome-icon { color: #066B76; }
.dashboard-heading { align-items: center; }
.dashboard-heading h2 { font-size: 19px; letter-spacing: -.03em; }
[data-theme="dark"] .dashboard-welcome { background: #132A37; border-color: #24485A; }
[data-theme="dark"] .eyebrow, [data-theme="dark"] .welcome-action small { color: #7FE6DB; }
[data-theme="dark"] .welcome-action { background: #1A3746; border-color: #2A5568; }
[data-theme="dark"] .welcome-action:hover { background: #24485A; }
.login-art { padding: 56px; background: #142B3D; }
.login-art h2 { font-weight: 600; font-size: clamp(36px, 4.4vw, 64px); letter-spacing: -.06em; max-width: 580px; }
.login-art .eyebrow { color: #7FE6DB; margin-bottom: 24px; }
.login-art p { color: #B6C0CF; font-size: 14px; line-height: 1.8; }
.login-art .lines { opacity: .2; width: 680px; pointer-events: none; }
.login-art > div:not(.login-feats) { position: relative; }
.login-feats { border-top: 1px solid #414854; padding-top: 28px; gap: 20px; }
.login-feats div { font-size: 11px; }
.login-card h1 { font-size: 30px; letter-spacing: -.045em; }
.login-card .input { height: 46px; background-color: var(--surface-2); }
.login-card .input-icon button .icon { position: static; transform: none; }
.login-card .input-icon button { top: 10px !important; }
@media (min-width: 1441px) and (max-width: 1650px) { .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1080px) { .searchbtn { min-width: 38px; width: 38px; justify-content: center; padding: 0; } .dashboard-welcome { padding: 24px; } }
@media (max-width: 860px) {
  .topbar { min-height: 66px; padding: 12px 16px; }
  .page { padding: 20px 16px calc(90px + env(safe-area-inset-bottom)); }
  .dashboard-welcome { align-items: flex-start; flex-direction: column; gap: 20px; }
  .dashboard-welcome h2 { font-size: 26px; }
  .welcome-action { width: 100%; }
  .welcome-action > .icon { margin-left: auto; }
  .collapsed .sb-head .logo-full { display: block; }
  .collapsed .sb-head .logo-mark { display: none; }
  .collapsed .sb-workspace { display: flex; }
  .collapsed .sb-link { justify-content: flex-start; padding: 10px 12px; }
  .collapsed .sb-group { height: auto; padding: 22px 10px 8px; }
  .collapsed .sb-user { justify-content: flex-start; }
  .collapsed .sb-user > .icon { display: block; }
}
@media (max-width: 600px) {
  .kpi { padding: 14px; }
  .kpi .k-top { font-size: 10px; gap: 6px; }
  .kpi .k-ic { width: 26px; height: 26px; }
  .kpi .k-val { font-size: 23px; }
  .kpi .k-sub { font-size: 10px; }
  .card-h { padding: 18px 16px 0; }
  .card-b { padding: 16px; }
  .card-h .legend { margin-left: 0; width: 100%; }
  .page-head h2 { font-size: 23px; }
  .dashboard-heading h2 { font-size: 18px; }
  .list-row { padding: 12px 16px; }
  .input, select.input, textarea.input { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* Keep status text legible on dark surfaces. */
[data-theme="dark"] .badge.red { color: #FF979F; }
[data-theme="dark"] .badge.green { color: #68D6AD; }
[data-theme="dark"] .badge.violet { color: #BB9DF5; }

/* ================= Books ================= */
.neg { color: var(--red); }
.pos { color: var(--green); }
.co-pick { display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 0 4px 0 10px; color: var(--muted); }
.co-pick select.input { border: 0; background: transparent; box-shadow: none; height: 34px; padding-left: 2px; font-weight: 600; color: var(--text); max-width: 260px; }
.doc-editor { overflow: visible; }
.de-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 18px 6px; }
.de-grid { padding: 10px 18px 18px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.de-grid .span2 { grid-column: span 2; }
.de-lines { border-top: 1px solid var(--line); padding-top: 14px; }
.de-tbl td { padding: 6px 6px; vertical-align: top; }
.de-tbl th { padding: 8px 6px; }
.de-tbl td:first-child, .de-tbl th:first-child { padding-left: 18px; }
.de-tbl td [data-amt], .de-tbl td[data-amt] { padding-top: 13px; font-weight: 600; }
.de-tbl .input.sm { height: 34px; }
.doc-editor.hide-acct .de-acct { display: none; }
.de-foot { display: flex; gap: 24px; flex-wrap: wrap; padding: 16px 18px; border-top: 1px solid var(--line); align-items: flex-start; }
.de-totals { width: 340px; max-width: 100%; display: grid; gap: 8px; background: var(--surface-2); border-radius: 12px; padding: 14px 16px; font-size: 13.5px; }
.de-grand { border-top: 1px solid var(--line-strong); padding-top: 10px; font-size: 17px; font-weight: 700; }
.de-actions { position: sticky; bottom: 0; display: flex; gap: 8px; align-items: center; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--surface); border-radius: 0 0 var(--radius) var(--radius); z-index: 2; }
.doc-hero { display: flex; align-items: center; gap: 20px; padding: 18px; flex-wrap: wrap; }
.doc-hero .stat-inline span { display: block; font-size: 12px; color: var(--muted); }
.doc-frame { overflow: hidden; padding: 0; background: #eef0f2; }
.doc-frame iframe { width: 100%; min-height: 900px; border: 0; display: block; background: #eef0f2; }
.bank-card, .co-card, .rep-card { cursor: pointer; transition: transform .12s, box-shadow .15s; }
.bank-card:hover, .co-card:hover, .rep-card:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.bank-card.off, .co-card.off { opacity: .55; }
.rep-card b { font-size: 14.5px; }
.rep-title { display: flex; align-items: flex-end; justify-content: space-between; margin: 4px 0 14px; }
.rep-title h3 { margin: 0; font-size: 18px; }
.rep-tbl tr.b1 td { font-weight: 650; }
.rep-tbl tr.b2 td { font-weight: 750; border-top: 1.5px solid var(--line-strong); background: var(--surface-2); }
.rep-tbl td .link { cursor: pointer; }
.sec-title { padding-left: 0; }
details.card > summary { list-style: none; }
details.card > summary::-webkit-details-marker { display: none; }
label.chip { cursor: pointer; color: var(--text); }
label.chip input { margin: 0; }
@media (max-width: 1100px) { .de-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .de-grid { grid-template-columns: 1fr; }
  .de-grid .span2 { grid-column: auto; }
  .de-totals { width: 100%; }
  .de-tbl { min-width: 760px; }
  .doc-frame iframe { min-height: 600px; }
  .co-pick { width: 100%; }
  .co-pick select.input { max-width: none; width: 100%; }
}
.tbl .actions.show .btn { opacity: 1; }
.tbl td.primary-cell b { overflow-wrap: anywhere; }
@media (max-width: 760px) {
  .de-actions { bottom: calc(58px + env(safe-area-inset-bottom)); }
}
@media (max-width: 760px) {
  .de-tbl { min-width: 0; }
  .de-tbl thead { display: none; }
  .de-tbl, .de-tbl tbody { display: block; }
  .de-tbl tr[data-line] { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); position: relative; }
  .de-tbl tr[data-line] td { padding: 0 !important; border: 0; }
  .de-tbl tr[data-line] td:first-child { grid-column: 1 / -1; padding-right: 36px !important; }
  .de-tbl tr[data-line] td.de-acct { grid-column: 1 / -1; }
  .de-tbl tr[data-line] td[data-label]::before { content: attr(data-label); display: block; font-size: 11px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
  .de-tbl tr[data-line] td.de-amt { grid-column: 1 / -1; text-align: right; font-size: 15px; }
  .de-tbl tr[data-line] td.de-amt::before { content: 'Amount '; font-weight: 500; color: var(--muted); font-size: 12px; }
  .de-tbl tr[data-line] td.de-rm { position: absolute; top: 18px; right: 10px; }
  .de-actions { flex-wrap: wrap; }
  .de-actions .grow { display: none; }
  .de-actions .btn { flex: 1 1 auto; }
  .de-actions [data-cancel] { flex: 0 0 auto; }
}
/* Offer letter generator frame (Team HR) */
.offer-frame { padding: 0; overflow: hidden; }
.offer-frame iframe { display: block; width: 100%; height: calc(100vh - 250px); min-height: 640px; border: 0; background: #F3F7F8; }
@media (max-width: 760px) { .offer-frame iframe { height: calc(100vh - 210px); min-height: 520px; } }
/* Shared sticky notes */
.note .n-shared { margin-top: 6px; font-size: 11.5px; font-weight: 600; opacity: .75; display: flex; align-items: center; gap: 5px; }
.note.shared .n-owner { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; margin-bottom: 6px; }
.note.shared .n-owner .badge { margin-left: auto; background: rgba(255,255,255,.55); color: inherit; }
.note.shared div.n-title { font-weight: 700; font-size: 14.5px; }
.note .n-body.ro { white-space: pre-wrap; font-size: 13.5px; line-height: 1.55; padding: 6px 0 0; flex: 1; min-height: 80px; }
.share-list { max-height: 50vh; overflow: auto; display: grid; gap: 2px; }
.share-row { display: flex; align-items: center; gap: 10px; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.share-row .check { display: flex; align-items: center; gap: 10px; cursor: pointer; }

/* ================= Team chat ================= */
.page.full:has(.chat) { padding-bottom: 0; }
.chat { display: grid; grid-template-columns: 270px minmax(0, 1fr); height: calc(100vh - 110px); min-height: 480px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-top: 8px; }
.chat-side { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; background: var(--surface-2); }
.chat-side-h { display: flex; align-items: center; justify-content: space-between; padding: 14px 12px 8px 16px; font-size: 15px; }
.chat-filter { padding: 0 12px 8px; }
.chat-lists { flex: 1; overflow-y: auto; padding-bottom: 10px; }
.chat-side-f { padding: 8px 12px; border-top: 1px solid var(--line); }
.chat-side-f:empty { display: none; }
.chat-sec { display: flex; align-items: center; justify-content: space-between; padding: 12px 10px 4px 16px; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); }
.chat-item { display: flex; align-items: center; gap: 9px; width: 100%; border: 0; background: none; padding: 6px 14px; text-align: left; cursor: pointer; color: var(--muted); font: inherit; font-size: 13.5px; border-radius: 8px; }
.chat-lists .chat-item { width: calc(100% - 12px); margin: 0 6px; }
.chat-item:hover { background: var(--surface-3); color: var(--text); }
.chat-item.on { background: var(--tint-orange); color: var(--text); font-weight: 600; }
.chat-item.unread { color: var(--text); font-weight: 700; }
.chat-item.muted { opacity: .6; }
.chat-hash { width: 20px; text-align: center; font-weight: 700; color: var(--faint); flex: none; display: inline-grid; place-items: center; }
.chat-hash.big { font-size: 18px; }
.chat-badge { background: var(--flame); color: #fff; font-size: 11px; font-weight: 700; border-radius: 10px; padding: 1px 7px; }
.chat-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text); flex: none; }
.chat-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; position: relative; }
.chat-main.drop-on::after { content: 'Drop to attach'; position: absolute; inset: 8px; border: 2px dashed var(--orange); border-radius: 12px; background: color-mix(in srgb, var(--tint-orange) 85%, transparent); display: grid; place-items: center; font-weight: 700; color: var(--flame); z-index: 5; }
.chat-empty { display: grid; place-items: center; flex: 1; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.chat-back { display: none; }
.chat-msgs { flex: 1; overflow-y: auto; padding: 8px 0 12px; }
.chat-start { padding: 18px 20px 8px; color: var(--muted); }
.chat-more { text-align: center; padding: 8px; }
.chat-day { display: flex; align-items: center; gap: 10px; margin: 14px 20px 6px; font-size: 12px; font-weight: 700; color: var(--muted); }
.chat-day::before, .chat-day::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.chat-new { display: flex; align-items: center; gap: 10px; margin: 8px 20px; font-size: 11.5px; font-weight: 700; color: var(--red); }
.chat-new::before { content: ''; flex: 1; height: 1px; background: var(--red); opacity: .5; }
.chat-msg { position: relative; display: flex; gap: 10px; padding: 6px 20px 4px; }
.chat-msg.cont { padding-top: 1px; }
.chat-msg:hover { background: var(--surface-2); }
.chat-msg.mention { background: color-mix(in srgb, var(--tint-orange) 70%, transparent); box-shadow: inset 3px 0 0 var(--orange); }
.chat-av { width: 36px; flex: none; }
.chat-av .avatar { width: 36px; height: 36px; }
.chat-time-s { display: none; font-size: 10.5px; color: var(--faint); padding-top: 3px; }
.chat-msg.cont:hover .chat-time-s { display: block; }
.chat-body { min-width: 0; flex: 1; }
.chat-meta { display: flex; align-items: baseline; gap: 8px; }
.chat-meta span { font-size: 11.5px; color: var(--faint); }
.chat-text { line-height: 1.5; overflow-wrap: anywhere; }
.chat-text a { color: var(--blue); text-decoration: underline; }
.chat-pre { background: var(--surface-3); border-radius: 8px; padding: 8px 10px; margin: 4px 0; white-space: pre-wrap; font-size: 12.5px; }
.chat-at { background: var(--tint-blue); color: var(--blue); border-radius: 4px; padding: 0 3px; font-weight: 600; }
.chat-at.me, .chat-at.all { background: var(--tint-orange); color: var(--flame); }
.chat-img img { display: block; max-width: min(360px, 100%); max-height: 280px; border-radius: 10px; margin-top: 6px; border: 1px solid var(--line); }
.chat-attach { display: flex; align-items: center; gap: 8px; margin-top: 6px; max-width: 360px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); }
.chat-attach:hover { border-color: var(--orange); }
.chat-reacts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 5px; }
.chat-react { border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 1px 8px; font-size: 12.5px; cursor: pointer; }
.chat-react.mine { border-color: var(--orange); background: var(--tint-orange); }
.chat-tools { position: absolute; right: 16px; top: -12px; display: none; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; box-shadow: var(--shadow-sm); }
.chat-msg:hover .chat-tools { display: flex; }
.chat-tools button { border: 0; background: none; width: 30px; height: 28px; display: grid; place-items: center; cursor: pointer; color: var(--muted); }
.chat-tools button:hover { color: var(--text); background: var(--surface-3); }
.chat-picker { position: absolute; right: 16px; top: 18px; z-index: 6; display: flex; gap: 2px; padding: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.chat-picker button { border: 0; background: none; font-size: 18px; width: 34px; height: 34px; border-radius: 8px; cursor: pointer; }
.chat-picker button:hover { background: var(--surface-3); }
.chat-compose { padding: 8px 14px 10px; border-top: 1px solid var(--line); position: relative; }
.chat-box { display: flex; align-items: flex-end; gap: 8px; }
.chat-box textarea { resize: none; min-height: 40px; max-height: 180px; line-height: 1.45; padding-top: 9px; }
.chat-hint { margin-top: 4px; }
.chat-file { display: flex; align-items: center; gap: 8px; padding: 6px 10px; margin-bottom: 6px; background: var(--surface-2); border-radius: 8px; }
.chat-mention { position: absolute; bottom: calc(100% - 4px); left: 14px; right: 14px; max-width: 420px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 4px; z-index: 7; }
.chat-mention button { display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: none; padding: 7px 8px; border-radius: 8px; cursor: pointer; text-align: left; color: var(--text); }
.chat-mention button.on, .chat-mention button:hover { background: var(--tint-orange); }
.chat-join { padding: 14px; border-top: 1px solid var(--line); display: flex; gap: 10px; align-items: center; justify-content: center; }
.chat-edit textarea { width: 100%; }
.sb-link .count.mention { background: var(--flame); color: #fff; }
@media (max-width: 760px) {
  /* Pin chat between the top bar and the bottom tab bar so the message box is always visible. */
  .chat { grid-template-columns: 1fr; position: fixed; top: 66px; bottom: calc(58px + env(safe-area-inset-bottom)); left: 0; right: 0; height: auto; min-height: 0; margin: 0; border-radius: 0; border: 0; border-top: 1px solid var(--line); z-index: 2; }
  .chat .chat-main { display: none; }
  .chat.show-conv .chat-side { display: none; }
  .chat.show-conv .chat-main { display: flex; }
  .chat-back { display: inline-flex; }
  .chat-msg { padding-left: 12px; padding-right: 12px; }
  .chat-tools { display: none !important; }
  .chat-msg:active .chat-tools { display: flex !important; }
  .chat-hint { display: none; }
}
.bi-co { display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }

/* ================= Invitty theme: minimal, light, teal accent ================= */
:root {
  --ink: #142B3D;
  --tint-orange: #E9F4F5;
  --focus: 0 0 0 3px rgba(6, 107, 118, .18);
  --shadow-sm: none;
  --shadow: 0 6px 20px rgba(20, 43, 61, .06);
  --shadow-lg: 0 18px 48px rgba(20, 43, 61, .16);
}
[data-theme="dark"] {
  --orange: #4FB3BD;
  --flame: #7FE6DB;
  --grad: #0B8A95;
  --tint-orange: rgba(79, 179, 189, .14);
  --focus: 0 0 0 3px rgba(79, 179, 189, .25);
}
::selection { background: rgba(6, 107, 118, .18); }

/* light sidebar, like the invitty.com header */
.sidebar { border-right: 1px solid var(--line); }
.sb-nav { scrollbar-color: var(--line-strong) transparent; }
.sb-group { color: var(--faint); }
.sb-link { color: var(--muted); font-weight: 500; }
.sb-link:hover { background: var(--surface-3); color: var(--text); }
.sb-link.active { background: var(--tint-orange); color: var(--flame); font-weight: 600; }
.sb-link.active::before { background: var(--orange); }
.sb-link.active .icon { color: var(--orange); }
.sb-foot { background: transparent; border-top: 1px solid var(--line); }
.sb-user { color: var(--muted); }
.sb-user:hover { background: var(--surface-3); }
.sb-user .who b { color: var(--text); }
.sb-user .who small { color: var(--muted); }
.sb-workspace { border-color: var(--line); background: var(--surface-2); }
.sb-workspace b { color: var(--text); }
.sb-workspace small { color: var(--muted); }
.workspace-monogram { background: var(--tint-orange); color: var(--orange); font-family: var(--display); }
.sb-head .logo-full { width: 132px; }
.sb-head .logo-full.on-dark { display: none; }
[data-theme="dark"] .sb-head .logo-full.on-light { display: none !important; }
[data-theme="dark"] .sb-head .logo-full.on-dark { display: block; }
.collapsed [data-theme="dark"] .sb-head .logo-full.on-dark, .collapsed .sb-head .logo-full.on-dark { display: none; }
@media (max-width: 860px) {
  :root:not([data-theme="dark"]) .collapsed .sb-head .logo-full.on-dark { display: none; }
  [data-theme="dark"] .collapsed .sb-head .logo-full.on-dark { display: block; }
}

/* flat, quiet surfaces */
.topbar { background: color-mix(in srgb, var(--surface) 92%, transparent); }
.btn { border-radius: 7px; }
.btn.primary { background: var(--orange); box-shadow: none; }
.btn.primary:hover { background: #055762; box-shadow: none; filter: none; }
[data-theme="dark"] .btn.primary { background: #0B8A95; }
[data-theme="dark"] .btn.primary:hover { background: #0E9DA9; }
.input:focus { border-color: var(--orange); }
.card, .kpi { box-shadow: none; }
.kpi.hero { background: var(--ink); border-color: var(--ink); }
.kpi.hero .k-ic { background: rgba(127, 230, 219, .14) !important; color: #7FE6DB !important; }
.kpi.hero .delta { background: rgba(127, 230, 219, .16); color: #A9F0E8; }
[data-theme="dark"] .kpi.hero { background: #0F2A38; border-color: #1C3D4E; }
.page-head h2, .dashboard-welcome h2, .hello h2, .login-art h2, .login-card h1, .tb-title h1, .kpi .k-val, .hr-hero .big, .rep-title h3 {
  font-family: var(--display); font-weight: 700;
}
.dashboard-welcome { background: linear-gradient(135deg, #EEF5F7 0%, #F8FBFC 100%); border-color: var(--line); }
.eyebrow { color: var(--orange); letter-spacing: .16em; }
.welcome-action { border-color: var(--line); background: var(--surface); }
.welcome-action small, .welcome-icon { color: var(--orange); }

/* hero blocks: solid navy / teal, no glows */
.login-art { background: var(--ink); }
.login-art .eyebrow { color: #7FE6DB; }
.login-art .lines { opacity: .12; }
.login-feats .icon { color: #7FE6DB; }
.login-feats { border-top-color: rgba(255, 255, 255, .1); }
.login-art img { width: 170px; }
.hello { background: var(--ink); }
.hello .hs { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .1); }
.hr-hero { background: var(--orange); box-shadow: none; }
[data-theme="dark"] .hr-hero { background: #0B5A63; }
.hr-actions .ic { color: var(--orange); }
.ins-card { background: var(--ink); box-shadow: none; }
.vlogo { background: var(--orange); }
.scan-box .e-ic { background: var(--orange); }
.toast { background: var(--ink); }
.toast .icon, .toast button { color: #7FE6DB; }
.stage-track button.cur { background: var(--orange); }
.stage-track button.done { background: #D3E9EC; color: #055762; }
[data-theme="dark"] .stage-track button.done { background: rgba(79, 179, 189, .2); color: #7FE6DB; }
.bottom-nav .fab { background: var(--orange); box-shadow: 0 6px 16px rgba(6, 107, 118, .28); }
.sb-link .count, .chat-badge, .bottom-nav .bn-badge, .chip-tabs .dot-n { background: var(--orange); }
.badge.orange, .role-admin, .signed-pill.wait { color: var(--flame); }
.chip-tabs button.on { background: var(--ink); border-color: var(--ink); }
