:root {
  /* Blush — warm wine-black base, soft pink + maroon + cream (streetwear re-theme) */
  --bg: #14090d;
  --panel: #1f1116;
  --panel-2: #2a1820;
  --line: #3a2531;
  --text: #fceaf0;
  --muted: #c295a5;

  /* Aliases used by the Bijlee module (kept in sync with the theme) */
  --surface: var(--panel-2);
  --border: var(--line);
  --subtle: var(--muted);

  /* Blush accents */
  --accent: #ff8fb3;
  --accent-alpha: rgba(255, 143, 179, 0.16);
  --cream: #ffe0d0;

  --danger: #ff5c78;
  --danger-alpha: rgba(255, 92, 120, 0.16);

  --green: #4bd39a;
  --green-alpha: rgba(75, 211, 154, 0.15);

  --blue: #6aa8ff;
  --blue-alpha: rgba(106, 168, 255, 0.15);

  --purple: #c58bff;
  --purple-alpha: rgba(197, 139, 255, 0.15);

  --orange: #ff9d5c;
  --orange-alpha: rgba(255, 157, 92, 0.15);

  --yellow: #ffc24b;
  --yellow-alpha: rgba(255, 194, 75, 0.15);

  --gray: #a08791;
  --gray-alpha: rgba(160, 135, 145, 0.16);

  /* Elevations */
  --shadow: 0 10px 30px -18px rgba(0, 0, 0, 0.85);
  --shadow-hover: 0 16px 34px -14px rgba(255, 143, 179, 0.3);
  --font-display: "Anton", "Arial Narrow", "Helvetica Neue", sans-serif;
  --font-ui: "Inter", system-ui, sans-serif;
  --font-data: "Space Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { background: var(--bg); color: var(--text); }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  overflow: hidden;
}
button, input, select, textarea { font: inherit; transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); }
button { cursor: pointer; }

.login-shell {
  display: none;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 0%, rgba(45, 212, 191, 0.12), transparent 36%),
    var(--bg);
}
body.auth-locked { overflow: hidden; }
body.auth-locked .login-shell { display: grid; }
body.auth-locked .sidebar,
body.auth-locked .app-shell { display: none; }
.login-card {
  width: min(420px, 100%);
  display: grid;
  gap: 18px;
  padding: 28px;
  background: rgba(26, 23, 20, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  box-shadow: var(--shadow);
}
.login-brand {
  height: auto;
  margin-bottom: 8px;
}
.login-error {
  min-height: 18px;
  color: var(--danger);
  font-family: var(--font-data);
  font-size: 12px;
}
.login-submit { width: 100%; }
.faceid-btn { width: 100%; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; background: var(--accent-alpha); color: var(--accent); border: 1px solid var(--accent); font-weight: 600; }
.faceid-btn:hover { background: var(--accent); color: #05140f; transform: translateY(-1px); }
.faceid-btn svg { flex-shrink: 0; }

/* ── Custom Scrollbars ─────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); }

/* ── Sidebar ───────────────────────────────────────────────────────────── */
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 220px;
  padding: 24px 16px;
  border-right: 1px solid rgba(255, 255, 255, 0.03);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  z-index: 10;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  color: var(--accent);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0;
  text-shadow: 0 0 16px var(--accent-alpha);
}
.brand-mark { font-size: 17px; }
.nav-stack { display: grid; gap: 6px; margin-top: 36px; }
.nav-link {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--muted);
  padding: 13px 14px;
  text-align: left;
  border-radius: 10px;
  font-weight: 500;
}
.nav-link:hover { color: var(--text); background: var(--panel-2); }
.nav-link.active {
  color: var(--accent);
  background: var(--accent-alpha);
  font-weight: 700;
}
.nav-link:active { transform: scale(0.97); }

.new-deal-btn {
  margin-top: auto;
  border: none;
  background: var(--accent);
  color: #050505;
  padding: 15px 14px;
  border-radius: 10px;
  font-weight: 800;
  box-shadow: 0 4px 14px var(--accent-alpha);
}
.new-deal-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(45, 212, 191, 0.35); }
.new-deal-btn:active { transform: scale(0.96) !important; }

/* ── Layout & Typography ───────────────────────────────────────────────── */
.app-shell { margin-left: 220px; height: 100vh; overflow-y: auto; padding: 32px; }
.view { max-width: 1600px; margin: 0 auto; }
.hidden { display: none !important; }

.view-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 24px; }
.eyebrow { color: var(--accent); font-family: var(--font-data); font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(34px, 5vw, 64px); line-height: .95; letter-spacing: -1px; }
h2 { font-size: 24px; letter-spacing: -0.5px; }
h3 { font-size: 16px; }
.subtle { color: var(--muted); }
.mono { font-family: var(--font-data); }

/* ── Grids & Cards ─────────────────────────────────────────────────────── */
.grid { display: grid; gap: 16px; }
.stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.two-col { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

.card, .panel {
  background: var(--panel);
  border: none;
  border-radius: 16px;
  box-shadow: var(--shadow);
  transition: all 0.25s ease;
}
.card { padding: 20px; }
.panel { padding: 24px; }

.stat-value { margin-top: 14px; font-family: var(--font-data); font-size: 32px; font-weight: 500; color: var(--text); }
.stat-card { width: 100%; text-align: left; color: var(--text); cursor: pointer; }
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.stat-card:active { transform: scale(0.98); }

/* ── Inputs & Buttons ──────────────────────────────────────────────────── */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; }
.btn { border: none; background: var(--panel-2); color: var(--text); min-height: 40px; padding: 10px 16px; border-radius: 10px; font-weight: 500; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
.btn:hover { background: #2a2520; color: var(--accent); }
.btn:active { transform: scale(0.95); }

.btn.primary { background: var(--accent); color: #050505; font-weight: 700; box-shadow: 0 4px 16px var(--accent-alpha); }
.btn.primary:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(45, 212, 191, 0.3); }

.btn.danger { color: var(--danger); background: var(--danger-alpha); box-shadow: none; }
.btn.danger:hover { background: var(--danger); color: #050505; transform: translateY(-2px); }
.btn.icon { min-width: 40px; padding-inline: 10px; font-family: var(--font-data); border-radius: 10px; }

input, select, textarea {
  width: 100%; min-height: 42px; background: var(--bg); color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.05); border-radius: 10px; padding: 10px 14px; outline: none;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-alpha); }
select option { background-color: var(--panel-2); color: var(--text); font-weight: 500; }

label { display: grid; gap: 8px; color: var(--muted); font-family: var(--font-data); font-size: 12px; text-transform: uppercase; }

/* ── Badges & Status Pills ─────────────────────────────────────────────── */
.quick-status { width: max-content; min-width: 180px; min-height: 36px; border-radius: 999px; font-family: var(--font-data); font-size: 13px; font-weight: 600; border: 1px solid transparent; }
.quick-status.gray { background: var(--gray-alpha); color: var(--text); }
.quick-status.blue { background: var(--blue-alpha); color: var(--blue); }
.quick-status.orange { background: var(--orange-alpha); color: var(--orange); }
.quick-status.purple { background: var(--purple-alpha); color: var(--purple); }
.quick-status.green { background: var(--green-alpha); color: var(--green); }
.quick-status.yellow { background: var(--yellow-alpha); color: var(--yellow); }
.quick-status.red { background: var(--danger-alpha); color: var(--danger); }

.badge { display: inline-flex; align-items: center; min-height: 28px; padding: 4px 10px; border-radius: 999px; font-family: var(--font-data); font-size: 12px; font-weight: 600; white-space: nowrap; }
.badge.gray { background: var(--gray-alpha); color: var(--text); }
.badge.blue { background: var(--blue-alpha); color: var(--blue); }
.badge.orange { background: var(--orange-alpha); color: var(--orange); }
.badge.purple { background: var(--purple-alpha); color: var(--purple); }
.badge.green { background: var(--green-alpha); color: var(--green); }
.badge.yellow { background: var(--yellow-alpha); color: var(--yellow); }
.badge.red { background: var(--danger-alpha); color: var(--danger); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: none; background: var(--panel-2); color: var(--muted); border-radius: 999px; padding: 9px 16px; font-family: var(--font-data); font-size: 12px; transition: all 0.2s; cursor: pointer; }
.chip.active { color: #050505; background: var(--accent); font-weight: 700; box-shadow: 0 4px 12px var(--accent-alpha); }
.chip:active { transform: scale(0.95); }

/* ── Forms & Inner Panels ──────────────────────────────────────────────── */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.hot-field { border-color: var(--green) !important; box-shadow: 0 0 0 3px var(--green-alpha) !important; }

.inline-panel, .poc-row, .mini-date-picker, .mini-item, .note, .delivery-deal, .deal-card, .delivery-card { background: var(--panel-2); border: none; border-radius: 12px; box-shadow: 0 4px 12px rgba(0,0,0,0.2); }
.inline-panel { grid-column: 1 / -1; display: grid; gap: 16px; padding: 18px; }
.poc-stack { display: grid; gap: 12px; }
.poc-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)) auto; gap: 12px; align-items: end; padding: 16px; }
.poc-row .wide { grid-column: span 2; }

.date-field-wrap { position: relative; display: grid; gap: 8px; }
.date-display { cursor: default; }
.date-toggle { width: max-content; }
.mini-date-picker { display: grid; gap: 8px; padding: 16px; }
.mini-date-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mini-date-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.mini-date-label, .mini-date-day { min-height: 36px; display: grid; place-items: center; border-radius: 8px; font-family: var(--font-data); font-size: 12px; }
.mini-date-label { color: var(--muted); }
.mini-date-day { background: var(--bg); color: var(--text); transition: all 0.2s; cursor: pointer; border: none; }
.mini-date-day:hover { background: var(--panel); color: var(--accent); }
.mini-date-day.other { color: var(--line); }
.mini-date-day.selected { background: var(--accent); color: #050505; font-weight: bold; }
.mini-date-day.today { box-shadow: inset 0 0 0 1px var(--accent); }
.mini-date-day:active { transform: scale(0.9); }

/* ── Kanbans & Drag Drops ──────────────────────────────────────────────── */
.kanban { display: grid; grid-template-columns: repeat(5, minmax(240px, 1fr)); gap: 16px; overflow-x: auto; padding-bottom: 12px; }
.delivery-kanban { display: grid; grid-template-columns: repeat(6, minmax(240px, 1fr)); gap: 16px; overflow-x: auto; padding-bottom: 12px; }
.lane { min-height: 360px; background: rgba(26, 23, 20, 0.4); border-radius: 16px; padding: 12px; transition: all 0.2s ease; }
.lane.drag-over { background: var(--accent-alpha); box-shadow: inset 0 0 0 2px var(--accent); }
.lane-head { display: flex; justify-content: space-between; gap: 10px; color: var(--text); font-family: var(--font-data); font-size: 13px; font-weight: 600; margin-bottom: 16px; padding: 0 4px; }

.deal-card, .delivery-card { display: grid; gap: 10px; width: 100%; margin-bottom: 12px; padding: 16px; text-align: left; user-select: none; transition: all 0.2s ease; cursor: grab; }
.deal-card strong, .delivery-card strong { color: var(--accent); font-size: 15px; letter-spacing: 0.3px; }
.deal-card:hover, .delivery-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.deal-card:active, .delivery-card:active { transform: scale(0.97); cursor: grabbing; }
.deal-card.dragging, .delivery-card.dragging { opacity: 0.5; transform: scale(0.95); box-shadow: 0 0 0 2px var(--accent); }
.deal-meta { display: flex; justify-content: space-between; gap: 8px; color: var(--muted); font-family: var(--font-data); font-size: 12px; }

/* ── Tables ────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: 12px; background: var(--panel); box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; min-width: 840px; }
th, td { padding: 16px; border-bottom: 1px solid rgba(255,255,255,0.03); text-align: left; vertical-align: middle; }
th { color: var(--muted); font-family: var(--font-data); font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
td { color: var(--text); }
tr:last-child td { border-bottom: 0; }
tr:hover td { background: rgba(255, 255, 255, 0.02); }
tr.is-done td { color: var(--muted); opacity: 0.5; text-decoration: line-through; }
.row-actions { display: flex; gap: 8px; }

/* ── Profile & Details ─────────────────────────────────────────────────── */
.artist-grid { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.profile-card { display: flex; flex-direction: column; gap: 16px; height: 100%; min-width: 0; }
.profile-top { display: flex; justify-content: space-between; gap: 14px; align-items: flex-start; }
.tag-dot { width: 14px; height: 14px; border-radius: 50%; box-shadow: 0 0 16px currentColor; flex-shrink: 0; }
.tag-purple { color: var(--purple); background: var(--purple); }
.tag-blue { color: var(--blue); background: var(--blue); }
.tag-orange { color: var(--orange); background: var(--orange); }
.tag-yellow { color: var(--yellow); background: var(--yellow); }
.tag-red { color: var(--danger); background: var(--danger); }
.tag-green { color: var(--green); background: var(--green); }
.tag-gray { color: var(--gray); background: var(--gray); }
.artist-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.profile-card .badge-row { margin-top: auto; display: flex; flex-wrap: wrap; gap: 8px; }

/* FIX #10: Added missing .artist-links-section class. Previously used in HTML
   but not defined in CSS, leaving the wrapper unstyled. */
.artist-links-section { display: grid; gap: 8px; }

/* ── Glassmorphism Modals ──────────────────────────────────────────────── */
.modal-root { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, 0.4); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: grid; place-items: center; padding: 24px; }
.modal { width: min(980px, 100%); max-height: calc(100vh - 48px); overflow: auto; background: rgba(24, 21, 18, 0.85); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 20px; box-shadow: 0 32px 80px rgba(0,0,0,0.9); }
.modal.small { width: min(680px, 100%); }
.modal-head { position: sticky; top: 0; z-index: 10; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 24px; background: rgba(24, 21, 18, 0.6); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid rgba(255, 255, 255, 0.05); }
.modal-body { padding: 24px; }
.detail-layout { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 20px; }

/* ── Lists & Notes (Overflow Fixes) ────────────────────────────────────── */
.mini-list { display: grid; gap: 8px; min-width: 0; }
.mini-item { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; min-width: 0; }
.mini-item > span:first-child { flex-shrink: 0; white-space: nowrap; }
.mini-item .mono { flex: 1; min-width: 0; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notes-feed { display: grid; gap: 12px; max-height: 340px; overflow: auto; padding-right: 4px; }
.note { padding: 16px; }
.note time { display: block; margin-bottom: 8px; color: var(--accent); font-family: var(--font-data); font-size: 11px; text-transform: uppercase; }
.note-text { color: var(--text); white-space: pre-wrap; line-height: 1.6; }
.poc-detail-grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.note-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

/* ── Delivery Grid ─────────────────────────────────────────────────────── */
.delivery-grid { grid-template-columns: minmax(300px, 0.8fr) minmax(0, 1.2fr); align-items: start; }
.delivery-deal-list { display: grid; gap: 12px; }
.delivery-deal { width: 100%; text-align: left; display: grid; gap: 8px; padding: 16px; color: var(--text); transition: all 0.2s; cursor: pointer; }
.delivery-deal:active { transform: scale(0.98); }
.delivery-deal.active { box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-alpha); }

/* ── Calendar ──────────────────────────────────────────────────────────── */
.calendar-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px; background: rgba(255,255,255,0.05); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); }
.cal-label, .cal-day { background: var(--panel); min-height: 120px; padding: 12px; }
.cal-label { min-height: auto; background: var(--bg); color: var(--muted); font-family: var(--font-data); font-size: 12px; text-transform: uppercase; text-align: center; }
.cal-day { display: grid; align-content: start; gap: 8px; transition: background 0.2s; }
.cal-day:hover { background: var(--panel-2); cursor: crosshair; }
.cal-day.other { opacity: 0.4; }
.cal-day.today { background: var(--accent-alpha); }
.cal-num { color: var(--text); font-family: var(--font-data); font-size: 14px; font-weight: 700; }
.cal-tag { display: block; width: 100%; border: none; border-left: 4px solid transparent; background: var(--bg); color: var(--text); padding: 8px 10px; border-radius: 8px; text-align: left; font-family: var(--font-data); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; box-shadow: 0 2px 8px rgba(0,0,0,0.3); cursor: pointer; }
.cal-tag:hover { filter: brightness(1.2); transform: scale(1.02); }
.cal-tag:active { transform: scale(0.95); }
.cal-tag.green { border-left-color: var(--green); background: var(--green-alpha); }
.cal-tag.purple { border-left-color: var(--purple); background: var(--purple-alpha); }
.cal-tag.orange { border-left-color: var(--orange); background: var(--orange-alpha); }
.cal-tag.gray { border-left-color: var(--gray); background: var(--gray-alpha); }
.cal-tag.blue { border-left-color: var(--blue); background: var(--blue-alpha); }
.cal-tag.yellow { border-left-color: var(--yellow); background: var(--yellow-alpha); }
.cal-tag.red { border-left-color: var(--danger); background: var(--danger-alpha); }
.cal-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; padding: 10px 2px 4px; }
.cal-key { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; }
.cal-dot { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* ── Toasts ────────────────────────────────────────────────────────────── */
.toast-root { position: fixed; right: 24px; bottom: 24px; z-index: 100; display: grid; gap: 12px; }
.toast { min-width: 280px; max-width: 380px; padding: 16px; border-radius: 12px; background: rgba(24, 21, 18, 0.9); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid var(--accent); color: var(--text); box-shadow: 0 10px 40px rgba(0,0,0,0.5); font-weight: 500; animation: slideIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; }
.toast.danger { border-color: var(--danger); }
@keyframes slideIn { from { opacity: 0; transform: translateY(20px) scale(0.9); } to { opacity: 1; transform: translateY(0) scale(1); } }

/* ── Artist Links ──────────────────────────────────────────────────────── */
.artist-links { display: flex; flex-direction: column; gap: 8px; }
.artist-link-pill { display: flex; align-items: center; justify-content: space-between; background: var(--panel-2); border-radius: 10px; padding: 4px 4px 4px 12px; }
.artist-link-open { color: var(--blue); text-decoration: none; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.artist-link-open:hover { text-decoration: underline; }

/* ── Responsive ────────────────────────────────────────────────────────── */
/* Smooth momentum scrolling for any horizontally-overflowing table/kanban on touch */
.table-wrap, .kanban, .delivery-kanban { -webkit-overflow-scrolling: touch; }

/* Tablet & below: sidebar becomes a top bar, nav wraps into pills */
@media (max-width: 980px) {
  body { overflow: auto; }
  .sidebar { position: static; width: 100%; min-height: auto; border-right: 0; border-bottom: 1px solid rgba(255,255,255,0.05); padding: 16px; }
  .nav-stack { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
  .nav-link { width: auto; flex: 0 0 auto; padding: 10px 14px; }
  .new-deal-btn { margin-top: 16px; }
  .app-shell { margin-left: 0; height: auto; min-height: 100vh; padding: 16px; overflow: visible; }
  .stats-grid, .two-col, .detail-layout, .form-grid, .delivery-grid { grid-template-columns: 1fr; }
  .form-grid .span-2 { grid-column: auto; }
  .inline-panel, .poc-row .wide { grid-column: auto; }
  .poc-row { grid-template-columns: 1fr; }
  .kanban { grid-template-columns: repeat(5, 260px); }
  .delivery-kanban { grid-template-columns: repeat(6, 260px); }
}

/* Phones: tighten everything, shrink the oversized display type, make modals near-fullscreen */
@media (max-width: 600px) {
  .app-shell { padding: 12px; }
  h1 { font-size: 30px; line-height: 1.05; letter-spacing: -0.5px; }
  h2 { font-size: 20px; }
  .view-head { flex-direction: column; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
  .view-head .btn, .view-head .row-actions { width: 100%; }
  .view-head .row-actions { flex-wrap: wrap; }

  .card { padding: 16px; }
  .panel { padding: 16px; border-radius: 14px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-value { font-size: 24px; }

  /* Toolbar / search go full width and stack */
  .toolbar { gap: 8px; }
  .toolbar > input { max-width: 100% !important; width: 100%; }
  .chips { width: 100%; }

  /* Tables: smaller cells + let the touch-scroll hint breathe */
  th, td { padding: 11px 12px; font-size: 13px; }
  table { min-width: 640px; }

  /* Buttons & actions wrap instead of overflowing */
  .row-actions { flex-wrap: wrap; }
  .btn { padding: 10px 13px; }

  /* Kanban lanes fill the screen width one at a time */
  .kanban, .delivery-kanban { grid-auto-columns: 85vw; grid-template-columns: none; grid-auto-flow: column; }
  .lane { min-height: 280px; }

  /* Modals: near-fullscreen sheet */
  .modal-root { padding: 8px; }
  .modal, .modal.small { width: 100%; max-height: calc(100vh - 16px); border-radius: 16px; }
  .modal-head, .modal-body { padding: 16px; }

  /* Bijlee analytics: smaller stat tiles */
  .bijlee-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .bijlee-stat-value { font-size: 1.5rem; }

  /* The 18-column Bijlee analytics table stays readable and scrolls, never squashes */
  .bijlee-ledger .table-wrap table { min-width: 1180px; }

  /* Comfortable touch targets (44px is the iOS/Android guideline) */
  .btn, .nav-link, .nav-search { min-height: 44px; }
  .modal-head .btn.icon { min-width: 44px; min-height: 44px; }
  .nav-link { padding: 9px 12px; font-size: 14px; }
  .quick-status { min-width: 150px; }

  /* Toasts span the screen width so Undo is always tappable */
  .toast-root { right: 12px; left: 12px; bottom: 12px; }
  .toast { min-width: 0; max-width: 100%; }
}

/* ── Color hierarchy: reserve teal for interactive/primary, calm the rest ── */
.eyebrow { color: var(--muted); }
.deal-card strong, .delivery-card strong { color: var(--text); }

/* ── Sticky table headers ── */
.table-wrap thead th { position: sticky; top: 0; z-index: 2; background: var(--panel-2); }

/* ── Top loading bar ── */
#loadingBar { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: var(--accent); z-index: 200; transition: width .3s ease, opacity .35s ease; box-shadow: 0 0 10px var(--accent); pointer-events: none; }
#loadingBar.done { opacity: 0; }

/* ── Loading skeleton shimmer ── */
.skeleton { background: linear-gradient(90deg, var(--panel) 25%, var(--panel-2) 50%, var(--panel) 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 12px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.skeleton-block { height: 96px; margin-bottom: 14px; }

/* ── Global search ── */
.nav-search { width: 100%; margin-top: 16px; min-height: 40px; }
.gsearch-result { display: block; width: 100%; text-align: left; padding: 12px 14px; border-radius: 10px; background: var(--panel-2); color: var(--text); border: none; margin-bottom: 8px; cursor: pointer; transition: all .15s; }
.gsearch-result:hover { background: #2a2520; box-shadow: inset 0 0 0 1px var(--accent); }
.gsearch-kind { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--accent); font-family: var(--font-data); }

/* ── POC call / WhatsApp buttons ── */
.poc-actions { display: inline-flex; gap: 6px; flex-shrink: 0; }
.poc-icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px; background: var(--panel-2); border: 0.5px solid var(--line); color: var(--accent); text-decoration: none; transition: all 0.15s; }
.poc-icon-btn:hover { border-color: var(--accent); transform: translateY(-1px); }
.poc-icon-btn:active { transform: scale(0.94); }
.poc-icon-btn.wa { background: #25D366; color: #fff; border-color: #25D366; }
.poc-icon-btn.wa:hover { background: #1ebe5b; border-color: #1ebe5b; }

/* ── Mobile: bottom tab bar + deal card feed + swipe-to-reveal ── */
.mobile-tabbar { display: none; }
.deals-mobile { display: none; }

/* Photo & logo uploads */
.avatar-img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line); flex-shrink: 0; background: var(--panel-2); }
.logo-thumb { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; border: 1px solid var(--line); background: var(--panel-2); flex-shrink: 0; }
.upload-prev { width: 60px; height: 60px; border-radius: 12px; object-fit: cover; border: 1px solid var(--line); background: var(--panel-2); }

/* Clean mobile cards for Clients / Payments / Delivery (Bucket 10) */
.cards-mobile { display: none; }
.mcard { background: var(--panel-2); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.mcard-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.mcard-title { font-weight: 600; font-size: 15px; line-height: 1.2; min-width: 0; word-break: break-word; }
.mcard-sub { color: var(--muted); font-size: 12.5px; line-height: 1.4; word-break: break-word; }
.mcard-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; border-top: 1px solid rgba(255, 255, 255, .06); padding-top: 9px; }
.mcard-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.mcard-actions .btn { flex: 1; min-width: 88px; }
.mtab { background: none; border: none; display: flex; flex-direction: column; align-items: center; gap: 3px; color: #8a847c; font-size: 9.5px; font-family: inherit; padding: 6px 8px; min-height: 44px; cursor: pointer; }
.mtab svg { width: 22px; height: 22px; }
.mtab.active { color: var(--accent); }
.mtab:active { transform: scale(0.9); }
.mdeal { position: relative; overflow: hidden; border-radius: 16px; background: var(--panel-2); }
.mdeal-actions { position: absolute; top: 0; right: 0; bottom: 0; width: 140px; display: flex; }
.mdeal-act { flex: 1; display: flex; align-items: center; justify-content: center; text-decoration: none; color: #fff; }
.mdeal-act.call { background: var(--accent); color: #05140f; }
.mdeal-act.wa { background: #25D366; }
.mdeal-act svg { width: 22px; height: 22px; }
.mdeal-face { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; width: 100%; text-align: left; background: #1b1815; border: none; border-radius: 16px; padding: 14px; color: var(--text); cursor: pointer; font-family: inherit; transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1); }
@media (max-width: 700px) {
  .mobile-tabbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; height: 60px; padding-bottom: env(safe-area-inset-bottom); background: #161310; border-top: 0.5px solid var(--line); align-items: center; justify-content: space-around; }
  .app-shell { padding-bottom: 80px; }
  .deals-desktop, .clients-desktop, .payments-desktop, .delivery-logs-desktop { display: none; }
  .deals-mobile { display: flex; flex-direction: column; gap: 10px; }
  .cards-mobile { display: flex; flex-direction: column; gap: 10px; }

  /* App-like polish: bottom tabs replace the top sidebar; compact app headers */
  .sidebar { display: none; }
  .app-shell { margin-left: 0; padding: calc(14px + env(safe-area-inset-top)) 13px calc(84px + env(safe-area-inset-bottom)); }
  /* Mask the strip behind the translucent status bar so content never shows under the clock/notch */
  body::after { content: ""; position: fixed; top: 0; left: 0; right: 0; height: env(safe-area-inset-top); background: var(--bg); z-index: 44; pointer-events: none; }
  .view-head { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
  .view-head > div:first-child { min-width: 0; flex: 1; }
  .view-head .eyebrow { display: none; }
  .view-head h1 { font-size: 22px; line-height: 1.1; letter-spacing: -0.3px; }
  .view-head h2 { font-size: 17px; }
  .view-head p.subtle { font-size: 12px; }
  .view-head .btn, .view-head .row-actions { width: auto; }
  .panel { padding: 15px; border-radius: 18px; margin-top: 14px !important; }
  .card { border-radius: 16px; }
  .bento-tile { border-radius: 18px; }
  .table-wrap { border-radius: 14px; }
  .chip { padding: 7px 14px; }
  .panel, .card, .bento-tile, .table-wrap, .mdeal { box-shadow: none; }
}

/* ── Smart Capture ── */
.sidebar-actions { margin-top: auto; display: grid; gap: 8px; }
.sidebar-actions .new-deal-btn { margin-top: 0; }
.capture-btn { border: 1px solid var(--accent); background: var(--accent-alpha); color: var(--accent); padding: 13px 14px; border-radius: 10px; font-weight: 700; font-family: inherit; cursor: pointer; }
.capture-btn:hover { background: var(--accent); color: #05140f; transform: translateY(-1px); }
.capture-btn:active { transform: scale(0.97); }

.capture-fab { display: none; position: fixed; right: 16px; bottom: calc(74px + env(safe-area-inset-bottom)); z-index: 46; width: 54px; height: 54px; border-radius: 50%; border: none; background: var(--accent); color: #05140f; box-shadow: 0 8px 22px -6px rgba(45,212,191,.6); cursor: pointer; align-items: center; justify-content: center; }
.capture-fab svg { width: 26px; height: 26px; }
.capture-fab:active { transform: scale(0.92); }

/* ── Review queue ── */
.review-card { display: flex; flex-direction: column; gap: 10px; }
.review-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.review-quote { font-size: 13.5px; line-height: 1.55; color: var(--text); background: var(--panel-2); border-left: 3px solid var(--orange); border-radius: 0 10px 10px 0; padding: 10px 12px; white-space: pre-wrap; }
.review-what { font-size: 13px; }
.review-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.review-fields label { font-size: 11px; }

/* ── Badges on nav ── */
.nav-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 6px; border-radius: 999px; background: var(--orange); color: #2a1607; font-family: var(--font-data); font-size: 10.5px; font-weight: 700; }
.mtab-icon-wrap { position: relative; display: inline-flex; }
.tab-badge { position: absolute; top: -4px; right: -8px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--orange); color: #2a1607; font-family: var(--font-data); font-size: 10px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }

.capture-preview { margin-top: 10px; padding: 10px 12px; border-radius: 10px; font-size: 12.5px; line-height: 1.5; background: var(--panel-2); color: var(--muted); border-left: 3px solid var(--line); }
.capture-preview.ok   { background: rgba(52,211,153,.1);  border-left-color: var(--green);  color: var(--text); }
.capture-preview.warn { background: rgba(251,146,60,.1);  border-left-color: var(--orange); color: var(--text); }

.capture-item { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; background: var(--panel-2); border-radius: 12px; padding: 12px 13px; }
.capture-del { min-height: 32px; padding: 4px 11px; font-size: 17px; line-height: 1; flex-shrink: 0; }

@media (max-width: 700px) { .capture-fab { display: flex; } }

/* ── Bento dashboard ── */
.bento-grid { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: minmax(86px, auto); grid-auto-flow: dense; gap: 12px; margin-bottom: 16px; }
.bento-tile { border: 0.5px solid var(--line); border-radius: 14px; padding: 13px 15px; display: flex; flex-direction: column; justify-content: space-between; min-width: 0; overflow: hidden; background: var(--panel); color: var(--text); text-align: left; box-shadow: var(--shadow); transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease; }
button.bento-tile { cursor: pointer; font: inherit; }
.bento-tile:hover { transform: translateY(-4px); }
button.bento-tile:active { transform: translateY(-1px) scale(0.99); }
.b-2x2 { grid-column: span 2; grid-row: span 2; }
.b-wide { grid-column: span 2; }
.bento-label { font-size: 12px; color: var(--muted); letter-spacing: 0.02em; }
.bento-val { font-family: var(--font-data); font-weight: 500; line-height: 1; }
.bt-teal   { background: rgba(45,212,191,.14);  border-color: rgba(45,212,191,.42); }
.bt-teal:hover   { box-shadow: 0 12px 28px -10px rgba(45,212,191,.55); }
.bt-blue   { background: rgba(56,189,248,.14);  border-color: rgba(56,189,248,.4); }
.bt-blue:hover   { box-shadow: 0 12px 28px -10px rgba(56,189,248,.5); }
.bt-green  { background: rgba(52,211,153,.14);  border-color: rgba(52,211,153,.4); }
.bt-green:hover  { box-shadow: 0 12px 28px -10px rgba(52,211,153,.5); }
.bt-purple { background: rgba(192,132,252,.14); border-color: rgba(192,132,252,.4); }
.bt-purple:hover { box-shadow: 0 12px 28px -10px rgba(192,132,252,.5); }
.bt-amber  { background: rgba(251,146,60,.13);  border-color: rgba(251,146,60,.38); }
.bt-cta    { background: var(--accent); border-color: var(--accent); color: #05140f; align-items: center; justify-content: center; }
.bt-cta:hover    { box-shadow: 0 14px 30px -8px rgba(45,212,191,.6); }
.bento-attn { display: flex; align-items: center; gap: 6px; width: 100%; background: rgba(0,0,0,.16); border-radius: 9px; padding: 4px 6px 4px 10px; transition: background 0.15s; }
.bento-attn:hover { background: rgba(0,0,0,.3); }
.bento-attn .ba-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; background: none; border: none; color: var(--text); text-align: left; cursor: pointer; padding: 6px 0; font: inherit; }
.bento-attn .att-txt { min-width: 0; display: flex; flex-direction: column; }
.bento-attn .att-main { font-weight: 600; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ba-acts { display: flex; gap: 4px; flex-shrink: 0; }
.ba-btn { width: 27px; height: 27px; border-radius: 7px; border: 1px solid var(--line); background: var(--panel-2); color: var(--muted); cursor: pointer; font-size: 13px; line-height: 1; display: flex; align-items: center; justify-content: center; transition: color .12s, background .12s, border-color .12s; }
.ba-btn:hover { color: var(--text); border-color: var(--muted); }
.ba-btn.done:hover { background: var(--green-alpha); border-color: var(--green); color: var(--green); }
.bento-stagebar { width: 100%; border-radius: 3px 3px 0 0; transition: height 0.3s ease; }
@media (max-width: 700px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .b-2x2, .b-wide { grid-column: span 2; grid-row: auto; }
}

/* ── Deal filter controls + Bijlee compact table ── */
.deal-ctrl { width: auto; min-width: 150px; }
.bijlee-compact .col-adv { display: none; }

/* ── Bulk actions bar ── */
.bulk-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--accent-alpha); border: 1px solid var(--accent); border-radius: 10px; padding: 10px 14px; margin-bottom: 12px; }
.bulk-bar select { width: auto; min-width: 160px; min-height: 38px; }

/* ── Attention feed ── */
.attention-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.attention-item { display: flex; justify-content: space-between; gap: 10px; align-items: center; width: 100%; text-align: left; background: var(--panel-2); border: none; border-radius: 10px; padding: 12px 14px; color: var(--text); cursor: pointer; margin-bottom: 8px; }
.attention-item:hover { box-shadow: inset 0 0 0 1px var(--accent); }
.attention-flag { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* ── Toast with action (Undo) ── */
.toast { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.toast-action { flex-shrink: 0; background: var(--accent); color: #050505; border: none; border-radius: 8px; padding: 6px 12px; font-weight: 700; cursor: pointer; font-family: var(--font-ui); }
.toast.danger .toast-action { background: var(--danger); }
/* ─── Bijlee Module ──────────────────────────────────────── */
.bijlee-badge {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  border: 1px solid;
}
.bijlee-badge--idle  { color: rgba(255,255,255,0.35); border-color: rgba(255,255,255,0.15); }
.bijlee-badge--active { color: var(--accent); border-color: var(--accent); animation: bijlee-pulse 1.4s ease-in-out infinite; }
.bijlee-badge--error  { color: #f06262; border-color: #f06262; }
@keyframes bijlee-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

.bijlee-input-panel { padding: 1.25rem 1.5rem; margin-bottom: 1.5rem; }
.bijlee-input-label {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--subtle);
  margin-bottom: 0.6rem;
}
.bijlee-input-row { display: flex; align-items: center; gap: 0.5rem; }
.bijlee-at {
  font-size: 1.1rem;
  color: var(--accent);
  font-weight: 600;
  flex-shrink: 0;
}
.bijlee-handle-input {
  flex: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.65rem 1rem;
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}
.bijlee-handle-input:focus { border-color: var(--accent); }
.bijlee-scrape-btn { flex-shrink: 0; display: flex; align-items: center; gap: 0.4rem; }

.bijlee-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}
@media (max-width: 980px) { .bijlee-stats-grid { grid-template-columns: repeat(2, 1fr); } }

.bijlee-stat-card { padding: 1.25rem 1.4rem; }
.bijlee-stat-card--accent { border-color: rgba(98,240,167,0.25) !important; }
.bijlee-stat-label {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--subtle);
  margin: 0 0 0.5rem;
}
.bijlee-stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
  line-height: 1;
  letter-spacing: -1px;
}
.bijlee-stat-value--accent { color: var(--accent); }

.bijlee-er-value { color: var(--accent); font-weight: 600; }
.bijlee-ledger { padding: 1.25rem 1.5rem; }

.bijlee-btn-spinner { animation: bijlee-spin 0.9s linear infinite; font-style: normal; }
@keyframes bijlee-spin { to { transform: rotate(360deg); } }

/* ─── Bijlee: account stat minis ─────────────────────────── */
.bijlee-stat-mini {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
}
.bijlee-stat-mini-label {
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--subtle);
  margin: 0 0 4px;
}
.bijlee-stat-mini-val {
  font-family: var(--font-data);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}

/* ─── Bijlee: insight chips below post rows ──────────────── */
.bijlee-insight-row td { padding: 0 !important; border-top: 0 !important; }
.bijlee-insights-box {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 8px 12px 12px;
}
.bijlee-chip {
  background: rgba(45, 212, 191, 0.08);
  border: 1px solid rgba(45, 212, 191, 0.2);
  color: var(--subtle);
  border-radius: 6px;
  font-size: 11.5px;
  line-height: 1.45;
  padding: 5px 10px;
}

/* ─── Bijlee: algorithm intelligence rows ────────────────── */
.bijlee-intel {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.55;
}
.bijlee-intel-fire { background: rgba(34,197,94,0.1);   border-left: 3px solid #22c55e; color: var(--text); }
.bijlee-intel-good { background: rgba(99,102,241,0.1);  border-left: 3px solid #818cf8; color: var(--text); }
.bijlee-intel-warn { background: rgba(251,146,60,0.1);  border-left: 3px solid #fb923c; color: var(--text); }
.bijlee-intel-info { background: rgba(255,255,255,0.04); border-left: 3px solid rgba(255,255,255,0.15); color: var(--subtle); }

/* ─── Bijlee: benchmark cards ────────────────────────────── */
.bijlee-benchmark {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
}
.bijlee-benchmark-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
  margin: 0 0 10px;
}

/* ── Bucket 9: desktop polish ──────────────────────────────────────────────
   Bring the calm, app-like feel of the mobile pass to desktop: smaller
   headings (no 64px magazine type), flat cards defined by a hairline border
   instead of a heavy drop shadow, quieter hovers, and a steady spacing rhythm.
   Scoped to ≥701px so the already-polished phone layout is untouched. */
@media (min-width: 701px) {
  /* Headings: sized like an app, not a poster */
  h1 { font-size: clamp(26px, 2.6vw, 34px); line-height: 1.12; letter-spacing: -0.4px; }
  h2 { font-size: 20px; }
  .view-head { align-items: center; margin-bottom: 22px; }

  /* Cards & panels: flat, with a calm hairline and a soft low shadow */
  .card, .panel, .table-wrap {
    border: 1px solid var(--line);
    box-shadow: 0 12px 30px -26px rgba(0, 0, 0, 0.9);
  }

  /* Buttons sit flat; only the primary action keeps its accent lift */
  .btn { box-shadow: none; }

  /* Inner surfaces read as one system via a shared hairline, not stacked shadows */
  .inline-panel, .poc-row, .mini-item, .note,
  .delivery-deal, .deal-card, .delivery-card, .gsearch-result {
    border: 1px solid var(--line);
    box-shadow: none;
  }

  /* Kanban lanes: quiet solid fill + hairline so columns feel deliberate */
  .lane { background: var(--panel); border: 1px solid var(--line); }

  /* Hovers: a small, neutral lift — no loud teal glow on every card */
  .stat-card:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -24px rgba(0, 0, 0, 0.9); }
  .deal-card:hover, .delivery-card:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -24px rgba(0, 0, 0, 0.9); }
  .gsearch-result:hover { box-shadow: inset 0 0 0 1px var(--accent); }
}

/* ── Blush streetwear — Stage 1: poster type + print texture ──────────────── */
h1, h2, .brand { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; }
h1 { letter-spacing: 0.5px !important; }
h2 { letter-spacing: 0.4px; }
.brand { letter-spacing: 1.5px; }
.stat-value, .bento-val { font-family: var(--font-display); font-weight: 400; letter-spacing: 0.5px; }
.eyebrow, .bento-label { font-family: var(--font-data); }

/* faint halftone print wash on the working canvas + login */
.app-shell, .login-shell {
  background-image: radial-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1.3px);
  background-size: 15px 15px;
  background-attachment: fixed;
}

/* punchier calls to action */
.btn.primary, .new-deal-btn, .capture-btn, .bt-cta {
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 800;
}

/* ── Blush streetwear — Stage 2: flair layer (calm-mode toggle in Settings) ── */
body:not(.flair) .flair-only { display: none !important; }
.app-shell { position: relative; z-index: 1; }

/* faint poster wordmark fixed behind the scrolling content */
body.flair::before {
  content: "PIVOT";
  position: fixed; left: -3%; top: 33%; z-index: 0;
  pointer-events: none; white-space: nowrap;
  font-family: var(--font-display); font-size: min(42vw, 480px); line-height: 1; letter-spacing: 2px;
  color: transparent; -webkit-text-stroke: 2px rgba(255, 143, 179, 0.06);
  transform: rotate(-8deg);
}

/* next-steps ticker — readable: dark text on a soft cream bar, strong tags, calm pace */
.pv-ticker { position: relative; margin: 0 0 16px; background: var(--cream); color: #2a1016; border-radius: 10px; overflow: hidden; white-space: nowrap; display: flex; align-items: center; }
.pv-eye { flex-shrink: 0; z-index: 2; align-self: stretch; display: flex; align-items: center; background: var(--accent); color: #2a1016; font-family: var(--font-data); font-size: 10px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; padding: 0 12px; }
.pv-ticker .run { display: inline-block; padding-left: 100%; animation: pvslide 20s linear infinite; font-family: var(--font-ui); font-weight: 600; font-size: 13.5px; padding-block: 9px; }
.pv-ticker .run b { color: #8a1e33; font-weight: 800; text-transform: uppercase; font-family: var(--font-data); font-size: 11px; letter-spacing: 0.04em; margin-right: 4px; }
.pv-ticker .run .sep { color: rgba(42,16,22,0.35); margin: 0 14px; }
@keyframes pvslide { to { transform: translateX(-100%); } }
.pv-ticker:hover .run { animation-play-state: paused; }

/* sticker cluster in the dashboard header */
.pv-stk { display: inline-flex; gap: 9px; align-items: center; }
.pv-seal { width: 44px; height: 44px; border-radius: 50%; display: inline-grid; place-items: center; transform: rotate(-8deg);
  background: repeating-conic-gradient(var(--danger) 0 9deg, var(--cream) 0 18deg); border: 2px solid var(--cream); }
.pv-seal b { width: 29px; height: 29px; border-radius: 50%; background: var(--accent); color: var(--bg); display: grid; place-items: center;
  font-family: var(--font-display); font-size: 9px; line-height: 0.9; text-align: center; border: 1.5px solid var(--bg); }
.pv-icn { width: 40px; height: 40px; background: var(--cream); border-radius: 10px; display: inline-grid; place-items: center; color: var(--danger); filter: drop-shadow(2px 2px 0 rgba(0,0,0,0.3)); }

@media (prefers-reduced-motion: reduce) { .pv-ticker .run { animation: none; } }
@media (max-width: 700px) { body.flair::before { display: none; } .pv-icn, .pv-seal { display: none; } }

/* ── Dashboard capture bar ── */
.home-capture { display: flex; align-items: stretch; background: var(--panel-2); border: 2px solid var(--accent); border-radius: 14px; overflow: hidden; margin-bottom: 16px; }
.home-capture .hc-eye { display: flex; align-items: center; background: var(--accent); color: var(--bg); font-family: var(--font-data); font-size: 10px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; padding: 0 14px; flex-shrink: 0; }
.home-capture input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--text); font-family: var(--font-ui); font-size: 15px; padding: 14px; }
.home-capture input::placeholder { color: var(--muted); }
.home-capture button { flex-shrink: 0; margin: 7px; border-radius: 10px; }
@media (max-width: 700px) { .home-capture .hc-eye { display: none; } }

/* ── Live search dropdown ── */
.nav-search-wrap { position: relative; }
.gsearch-drop { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 30; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); max-height: 62vh; overflow: auto; padding: 6px; }

/* ── Mobile center Capture FAB ── */
.mtab-fab { background: var(--accent); color: var(--bg); border-radius: 16px; width: 52px; height: 52px; min-height: 52px; align-self: center; margin-top: -20px; box-shadow: 0 6px 16px -6px var(--accent); padding: 0; }
.mtab-fab svg { width: 26px; height: 26px; }
.mtab-fab:active { transform: scale(0.92); }

/* ── Closed-Won moment ── */
.won-burst { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; pointer-events: none; background: rgba(20,9,13,0.5); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); animation: wonin 0.25s ease; }
.won-burst.out { opacity: 0; transition: opacity 0.4s ease; }
.won-stamp { font-family: var(--font-display); font-size: clamp(48px, 14vw, 120px); color: var(--green); border: 6px solid var(--green); border-radius: 16px; padding: 4px 26px; transform: rotate(-8deg); letter-spacing: 3px; text-transform: uppercase; animation: wonpop 0.5s cubic-bezier(0.2,1.5,0.4,1); }
.won-sub { margin-top: 18px; font-family: var(--font-data); color: var(--cream); font-size: 14px; text-align: center; padding: 0 20px; }
.won-conf-layer { position: absolute; inset: 0; overflow: hidden; }
.won-conf { position: absolute; top: -18px; width: 9px; height: 14px; border-radius: 2px; animation: wonfall 1.9s linear forwards; }
@keyframes wonin { from { opacity: 0; } to { opacity: 1; } }
@keyframes wonpop { 0% { transform: rotate(-8deg) scale(0.3); opacity: 0; } 100% { transform: rotate(-8deg) scale(1); opacity: 1; } }
@keyframes wonfall { to { transform: translateY(110vh) rotate(400deg); } }
@media (prefers-reduced-motion: reduce) { .won-conf { display: none; } .won-stamp, .won-burst { animation: none; } }

/* ── Deliveries-in-progress rows (truncate cleanly, never overflow) ── */
.dg-row { display: flex; align-items: center; gap: 6px; width: 100%; }
.dg-open { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; text-align: left; padding: 11px 14px; }
.dg-adv { flex-shrink: 0; margin-right: 8px; font-size: 15px; }

/* ── Pipeline Kanban one-tap advance (button pinned to the card's top-right) ── */
.kc-wrap { position: relative; }
.kc-wrap .deal-card strong { padding-right: 34px; display: block; }
.kc-adv { position: absolute; top: 10px; right: 10px; font-size: 15px; z-index: 1; }
@media (hover: none) { .kc-adv { width: 32px; height: 32px; } }
.dg-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.dg-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dg-hint { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dg-right { flex-shrink: 0; display: flex; align-items: center; gap: 8px; }

/* ── Content tracker ── */
.ct-pct { font-size: 22px; font-weight: 700; color: var(--accent); font-family: var(--font-display); }
.ct-bar { height: 8px; border-radius: 999px; background: var(--panel-2); overflow: hidden; margin: 2px 0 16px; }
.ct-bar span { display: block; height: 100%; background: var(--accent); border-radius: 999px; transition: width 0.3s ease; }
.ct-summary { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.ct-stat { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; display: flex; flex-direction: column; gap: 2px; min-width: 108px; }
.ct-stat-n { font-family: var(--font-display); font-size: 22px; }
.ct-stat-l { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.ct-note-wrap { display: grid; gap: 6px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin-bottom: 16px; }
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.ct-day { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.ct-day-h { font-family: var(--font-data); font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); margin-bottom: 8px; }
.ct-item { display: flex; align-items: center; gap: 10px; padding: 8px 6px; border-radius: 8px; cursor: pointer; text-transform: none; }
.ct-item:hover { background: rgba(255,255,255,0.03); }
.ct-item input { width: 18px; height: 18px; min-height: 0; flex-shrink: 0; accent-color: var(--accent); cursor: pointer; }
.ct-item .ct-label { flex: 1; font-size: 14px; color: var(--text); }
.ct-item.done .ct-label { color: var(--muted); text-decoration: line-through; }
.ct-past { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 10px; background: var(--panel-2); }
.ct-past.cp { border-color: var(--accent); }
.ct-past summary { display: flex; justify-content: space-between; align-items: center; gap: 10px; cursor: pointer; list-style: none; }
.ct-past summary::-webkit-details-marker { display: none; }
.ct-past-wk { font-weight: 700; }
.ct-past-meta { font-size: 12px; color: var(--muted); }

