/* ═══════════════════════════════════════════
   OCP CRM — $50B Design System
   Inspired by Hermes Workspace "hermes-nous"
   ═══════════════════════════════════════════ */

/* ── Design Tokens ────────────────────────── */
:root {
  /* Backgrounds — TRUE BLACK */
  --ocp-bg-deep: #000000;
  --ocp-bg-surface: #0A0A0A;
  --ocp-bg-card: #111111;
  --ocp-bg-card-hover: #1A1A1A;
  --ocp-bg-elevated: #1C1C1C;
  --ocp-bg-glass: rgba(0, 0, 0, 0.88);
  --ocp-bg-overlay: rgba(0, 0, 0, 0.95);

  /* Text */
  --ocp-text-primary: #FFE6CB;
  --ocp-text-secondary: rgba(255, 230, 203, 0.78);
  --ocp-text-muted: rgba(255, 230, 203, 0.48);
  --ocp-text-dim: rgba(255, 230, 203, 0.28);

  /* Accent — champagne gold ramp */
  --ocp-accent: #FFAC02;
  --ocp-accent-bright: #FFC94D;
  --ocp-accent-deep: #C77F00;
  --ocp-accent-secondary: #FFE6CB;
  --ocp-accent-subtle: rgba(255, 172, 2, 0.10);
  --ocp-accent-border: rgba(255, 172, 2, 0.28);
  --ocp-accent-glow: rgba(255, 172, 2, 0.18);
  --ocp-gradient-gold: linear-gradient(135deg, #FFC94D 0%, #FFAC02 45%, #D48A00 100%);

  /* Semantic */
  --ocp-success: #6EE7A0;
  --ocp-success-subtle: rgba(110, 231, 160, 0.10);
  --ocp-warning: #FFAC02;
  --ocp-warning-subtle: rgba(255, 172, 2, 0.10);
  --ocp-danger: #FF5C64;
  --ocp-danger-subtle: rgba(255, 92, 100, 0.10);
  --ocp-info: #7FB4FF;
  --ocp-info-subtle: rgba(127, 180, 255, 0.10);

  /* Borders */
  --ocp-border: rgba(255, 230, 203, 0.18);
  --ocp-border-light: rgba(255, 230, 203, 0.08);
  --ocp-border-accent: rgba(255, 172, 2, 0.28);

  /* Shadows — layered, with faint gold ambience on large surfaces */
  --ocp-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5), 0 2px 6px rgba(0, 0, 0, 0.35);
  --ocp-shadow-md: 0 2px 4px rgba(0, 0, 0, 0.45), 0 8px 20px rgba(0, 0, 0, 0.4);
  --ocp-shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.5), 0 20px 48px rgba(0, 0, 0, 0.55), 0 0 40px rgba(255, 172, 2, 0.04);
  --ocp-shadow-glow: 0 0 0 1px rgba(255, 172, 2, 0.12), 0 4px 24px rgba(255, 172, 2, 0.10);

  /* Radius */
  --ocp-radius-sm: 6px;
  --ocp-radius-md: 10px;
  --ocp-radius-lg: 14px;
  --ocp-radius-xl: 20px;
  --ocp-radius-2xl: 28px;
  --ocp-radius-full: 9999px;

  /* Typography — Fraunces (display serif) + Hanken Grotesk (UI) */
  --ocp-font-sans: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;
  --ocp-font-serif: 'Fraunces', 'EB Garamond', Georgia, serif;
  --ocp-font-mono: 'JetBrains Mono', monospace;

  /* Spacing */
  --ocp-header-h: 64px;
  --ocp-summary-h: 48px;
  --ocp-sidebar-w: 260px;

  /* ── LEGACY COMPATIBILITY ALIASES ── */
  --text-primary: var(--ocp-text-primary);
  --text-secondary: var(--ocp-text-secondary);
  --text-muted: var(--ocp-text-muted);
  --border-color: var(--ocp-border);
  --accent-gold: var(--ocp-accent);
  --bg-deep: var(--ocp-bg-deep);
  --bg-surface: var(--ocp-bg-surface);
  --bg-card: var(--ocp-bg-card);
}

/* ── Base Reset ───────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--ocp-bg-deep); scroll-behavior: smooth; }
body {
  font-family: var(--ocp-font-sans);
  font-optical-sizing: auto;
  letter-spacing: 0.005em;
  color: var(--ocp-text-primary);
  background: var(--ocp-bg-deep);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection { background: rgba(255, 172, 2, 0.30); color: #FFF4E4; }

/* ── Ambient Background Effects ───────────── */
.ocp-noise {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  opacity: 0.020;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.ocp-orb {
  position: fixed; border-radius: 50%; pointer-events: none; z-index: 0;
  filter: blur(120px); opacity: 0.07;
}
.ocp-orb--gold { width: 480px; height: 480px; background: var(--ocp-accent); top: -180px; right: -120px; }
.ocp-orb--teal { width: 360px; height: 360px; background: #1a6b6b; bottom: -120px; left: -80px; }
/* Faint gold wash along the top edge — gives every page a horizon line */
body::before {
  content: ""; position: fixed; inset: 0 0 auto 0; height: 320px;
  pointer-events: none; z-index: 0;
  background: radial-gradient(120% 100% at 50% -40%, rgba(255, 172, 2, 0.07), transparent 70%);
}

/* ── Layout ───────────────────────────────── */
.ocp-layout {
  display: flex; min-height: 100vh;
}

/* ── Sidebar ──────────────────────────────── */
.ocp-sidebar {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--ocp-sidebar-w, 260px);
  z-index: 1000;
  display: flex; flex-direction: column;
  background:
    radial-gradient(140% 50% at 0% 0%, rgba(255, 172, 2, 0.05), transparent 60%),
    var(--ocp-bg-surface);
  border-right: 1px solid var(--ocp-border);
  overflow-y: auto;
}

.ocp-sidebar-header {
  display: flex; align-items: center; gap: 10px;
  padding: 18px 16px 14px;
  border-bottom: 1px solid var(--ocp-border-light);
}
.ocp-sidebar-header .ocp-logo-icon {
  width: 32px; height: 32px; border-radius: 9px;
  display: grid; place-items: center;
  background: var(--ocp-gradient-gold);
  color: #000;
  font-family: var(--ocp-font-serif); font-size: 1.05rem; font-weight: 700;
}
.ocp-sidebar-header .ocp-logo-text {
  font-family: var(--ocp-font-serif);
  font-weight: 580; font-size: 1.02rem; letter-spacing: 0.01em;
  font-variation-settings: "opsz" 40;
  color: var(--ocp-text-primary);
}
.ocp-sidebar-header .ocp-logo-text span { color: var(--ocp-accent); font-weight: 640; font-style: italic; }

.ocp-sidebar-nav {
  flex: 1; padding: 8px 10px;
  display: flex; flex-direction: column; gap: 1px;
}

.ocp-sidebar-section {
  font-size: 0.6rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ocp-text-dim);
  padding: 16px 10px 6px;
}

.ocp-snav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: var(--ocp-radius-md);
  color: var(--ocp-text-muted); font-size: 0.84rem; font-weight: 500;
  text-decoration: none; transition: all 0.15s ease;
}
.ocp-snav-item:hover {
  color: var(--ocp-text-primary);
  background: var(--ocp-accent-subtle);
}
.ocp-snav-item.active {
  color: var(--ocp-accent);
  background: linear-gradient(90deg, rgba(255, 172, 2, 0.16), var(--ocp-accent-subtle) 60%);
  font-weight: 600;
  box-shadow: inset 2px 0 0 var(--ocp-accent);
}
.ocp-snav-item i { width: 18px; text-align: center; font-size: 0.9rem; opacity: 0.7; }
.ocp-snav-item.active i { opacity: 1; }

/* Tools sub-section (collapsible) */
.ocp-snav-sub {
  margin-left: 0; padding-left: 0;
}
.ocp-snav-sub-item {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 12px 7px 34px; border-radius: var(--ocp-radius-sm);
  color: var(--ocp-text-dim); font-size: 0.78rem; font-weight: 400;
  text-decoration: none; transition: all 0.12s ease;
}
.ocp-snav-sub-item:hover {
  color: var(--ocp-text-secondary);
  background: var(--ocp-accent-subtle);
}
.ocp-snav-sub-item.active {
  color: var(--ocp-accent);
  font-weight: 500;
}

/* Sidebar bottom (search + profile) */
.ocp-sidebar-bottom {
  padding: 10px 12px 14px;
  border-top: 1px solid var(--ocp-border-light);
  display: flex; flex-direction: column; gap: 10px;
}
.ocp-sidebar-search {
  position: relative;
}
.ocp-sidebar-search i {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  color: var(--ocp-text-dim); font-size: 0.8rem;
}
.ocp-sidebar-search input {
  width: 100%; height: 34px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-card);
  border-radius: var(--ocp-radius-md); padding: 0 10px 0 30px;
  color: var(--ocp-text-primary); font-size: 0.8rem; outline: none;
}
.ocp-sidebar-search input:focus {
  border-color: var(--ocp-accent); box-shadow: 0 0 0 2px var(--ocp-accent-glow);
}
.ocp-sidebar-profile {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 8px; border-radius: var(--ocp-radius-md);
  cursor: default;
}
.ocp-sidebar-profile:hover { background: var(--ocp-accent-subtle); }
.ocp-sidebar-profile .avatar {
  width: 28px; height: 28px; border-radius: 7px;
  display: grid; place-items: center;
  background: var(--ocp-gradient-gold);
  color: #000; font-weight: 700; font-size: 0.7rem;
}
.ocp-sidebar-profile .meta { flex: 1; }
.ocp-sidebar-profile .name { font-size: 0.8rem; font-weight: 600; color: var(--ocp-text-primary); }
.ocp-sidebar-profile .role { font-size: 0.65rem; color: var(--ocp-text-muted); }

/* ── Main Content (sidebar-aware) ─────────── */
.ocp-main {
  position: relative; z-index: 1;
  margin-left: var(--ocp-sidebar-w, 260px);
  padding: 24px 28px 36px;
  max-width: 1400px;
  min-height: 100vh;
  /* flex item: allow shrinking below content min-width so wide tables don't push the page past the viewport */
  min-width: 0;
  flex: 1;
}

/* Orchestrated page-load: top-level blocks rise in, staggered */
@keyframes ocp-rise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
.ocp-main > * { animation: ocp-rise 0.5s cubic-bezier(0.22, 1, 0.36, 1) both; }
.ocp-main > *:nth-child(1) { animation-delay: 0.03s; }
.ocp-main > *:nth-child(2) { animation-delay: 0.09s; }
.ocp-main > *:nth-child(3) { animation-delay: 0.15s; }
.ocp-main > *:nth-child(4) { animation-delay: 0.21s; }
.ocp-main > *:nth-child(5) { animation-delay: 0.27s; }
.ocp-main > *:nth-child(n+6) { animation-delay: 0.33s; }
@media (max-width: 768px) {
  .ocp-main {
    margin-left: 64px !important;
    padding: 18px 16px 36px;
  }
}

/* ── Cards & Panels ───────────────────────── */
.ocp-card {
  background:
    linear-gradient(180deg, rgba(255, 230, 203, 0.025), transparent 56px),
    var(--ocp-bg-card);
  border: 1px solid var(--ocp-border);
  border-top-color: rgba(255, 230, 203, 0.24);
  border-radius: var(--ocp-radius-xl); box-shadow: var(--ocp-shadow-sm);
  transition: border-color 0.2s ease, box-shadow 0.25s ease, transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}
.ocp-card-pad { padding: 20px; }
.ocp-card-hover:hover {
  border-color: var(--ocp-accent-border);
  box-shadow: var(--ocp-shadow-glow);
  transform: translateY(-1px);
}
.ocp-panel {
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg);
}
.ocp-panel-pad { padding: 16px; }
.ocp-glass {
  background: var(--ocp-bg-glass); backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-xl);
}

/* ── Typography ───────────────────────────── */
.ocp-eyebrow {
  color: var(--ocp-text-muted); text-transform: uppercase;
  letter-spacing: 0.16em; font-size: 0.7rem; font-weight: 600;
  display: flex; align-items: center; gap: 8px;
}
.ocp-eyebrow::before {
  content: ""; width: 18px; height: 1px; flex: none;
  background: linear-gradient(90deg, var(--ocp-accent), transparent);
}
.ocp-title {
  font-family: var(--ocp-font-serif);
  font-weight: 560; letter-spacing: -0.015em;
  font-variation-settings: "opsz" 90;
  font-size: clamp(1.6rem, 3vw, 2.35rem); line-height: 1.08;
}
.ocp-subtitle { color: var(--ocp-text-secondary); font-size: 0.92rem; line-height: 1.5; max-width: 720px; }
.ocp-section-title {
  font-size: 1.05rem; font-weight: 700; display: flex; align-items: center; gap: 8px;
}
.ocp-section-subtitle { font-size: 0.82rem; color: var(--ocp-text-muted); margin-top: 4px; }
.ocp-display {
  font-family: var(--ocp-font-serif); font-weight: 600; letter-spacing: -0.02em;
}
.ocp-numeral {
  font-variant-numeric: lining-nums tabular-nums; letter-spacing: -0.02em;
}

/* ── Stat Cards ───────────────────────────── */
.ocp-stat {
  display: block; text-decoration: none; color: inherit;
  background:
    linear-gradient(180deg, rgba(255, 230, 203, 0.025), transparent 56px),
    var(--ocp-bg-card);
  border: 1px solid var(--ocp-border);
  border-top-color: rgba(255, 230, 203, 0.24);
  border-radius: var(--ocp-radius-xl); padding: 18px 20px;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1); position: relative; overflow: hidden;
}
.ocp-stat::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 2px;
  background: var(--ocp-gradient-gold);
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.ocp-stat:hover {
  border-color: var(--ocp-accent-border); transform: translateY(-2px);
  box-shadow: var(--ocp-shadow-glow);
}
.ocp-stat:hover::after { transform: scaleX(1); }
.ocp-stat-icon {
  width: 40px; height: 40px; border-radius: var(--ocp-radius-md);
  display: grid; place-items: center; margin-bottom: 12px; font-size: 1rem;
}
.ocp-stat-icon--gold { background: var(--ocp-accent-subtle); color: var(--ocp-accent); }
.ocp-stat-icon--green { background: var(--ocp-success-subtle); color: var(--ocp-success); }
.ocp-stat-icon--blue { background: var(--ocp-info-subtle); color: var(--ocp-info); }
.ocp-stat-icon--red { background: var(--ocp-danger-subtle); color: var(--ocp-danger); }
.ocp-stat-label {
  font-size: 0.72rem; color: var(--ocp-text-muted); text-transform: uppercase;
  letter-spacing: 0.06em; font-weight: 600; margin-bottom: 4px;
}
.ocp-stat-value {
  font-family: var(--ocp-font-serif);
  font-size: 1.95rem; font-weight: 540; letter-spacing: -0.01em; line-height: 1.05;
  font-variation-settings: "opsz" 60;
  font-variant-numeric: lining-nums tabular-nums;
}
.ocp-stat-change { display: flex; align-items: center; gap: 5px; font-size: 0.78rem; color: var(--ocp-success); margin-top: 8px; }

/* ── Badges ───────────────────────────────── */
.ocp-badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px;
  border-radius: var(--ocp-radius-full); font-size: 0.65rem;
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
  white-space: nowrap; border: 1px solid transparent;
}
.ocp-badge--gold { background: var(--ocp-accent-subtle); color: var(--ocp-accent); border-color: rgba(255, 172, 2, 0.22); }
.ocp-badge--green { background: var(--ocp-success-subtle); color: var(--ocp-success); border-color: rgba(110, 231, 160, 0.22); }
.ocp-badge--blue { background: var(--ocp-info-subtle); color: var(--ocp-info); border-color: rgba(127, 180, 255, 0.22); }
.ocp-badge--red { background: var(--ocp-danger-subtle); color: var(--ocp-danger); border-color: rgba(255, 92, 100, 0.22); }

/* ── Buttons ──────────────────────────────── */
.ocp-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px;
  border-radius: var(--ocp-radius-md); font-size: 0.84rem; font-weight: 600;
  text-decoration: none; border: 1px solid var(--ocp-border);
  background: var(--ocp-bg-card); color: var(--ocp-text-secondary);
  cursor: pointer; transition: all 0.15s; font-family: inherit; line-height: 1;
}
.ocp-btn:hover { border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.ocp-btn:active { transform: translateY(1px); }
.ocp-btn--primary {
  background: var(--ocp-gradient-gold); color: #1A0F00;
  border-color: transparent; font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 2px 8px rgba(255, 172, 2, 0.18);
}
.ocp-btn--primary:hover {
  filter: brightness(1.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 4px 16px rgba(255, 172, 2, 0.30);
}
.ocp-btn--ghost {
  background: transparent; border-color: transparent; color: var(--ocp-text-muted);
}
.ocp-btn--ghost:hover { background: var(--ocp-accent-subtle); color: var(--ocp-accent); }
.ocp-btn--success {
  background: rgba(16, 185, 129, 0.12); color: #34d399;
  border-color: rgba(16, 185, 129, 0.25);
}
.ocp-btn--success:hover { background: rgba(16, 185, 129, 0.20); color: #6ee7b7; border-color: rgba(16, 185, 129, 0.40); }
.ocp-btn--danger {
  background: rgba(239, 68, 68, 0.12); color: #f87171;
  border-color: rgba(239, 68, 68, 0.25);
}
.ocp-btn--danger:hover { background: rgba(239, 68, 68, 0.20); color: #fca5a5; border-color: rgba(239, 68, 68, 0.40); }
.ocp-btn--sm { padding: 5px 10px; font-size: 0.78rem; border-radius: var(--ocp-radius-sm); }
.ocp-btn--xs { padding: 3px 8px; font-size: 0.72rem; border-radius: var(--ocp-radius-sm); }
.summary-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.summary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 34px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid var(--ocp-border);
  background: var(--ocp-bg-card);
  color: var(--ocp-text-secondary);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: var(--ocp-shadow-sm);
}
.summary-btn:hover {
  border-color: var(--ocp-accent-border);
  color: var(--ocp-accent);
  background: var(--ocp-bg-card-hover);
  box-shadow: var(--ocp-shadow-glow);
}
.summary-btn.primary {
  border-color: transparent;
  background: var(--ocp-gradient-gold);
  color: #1A0F00;
}
.summary-btn.primary:hover {
  color: #1A0F00;
  opacity: 0.95;
}
.summary-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--ocp-accent-glow);
}
.summary-btn:disabled,
.summary-btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}
.summary-btn i { font-size: 0.9em; }

/* ── Inbox Workbench ──────────────────────── */
#inbox-workbench .inbox-disclosure > summary {
  list-style: none;
}
#inbox-workbench .inbox-disclosure > summary::-webkit-details-marker {
  display: none;
}
#inbox-workbench .inbox-disclosure-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 24px;
  cursor: pointer;
  user-select: none;
}
#inbox-workbench .inbox-disclosure > summary:focus-visible {
  outline: none;
  border-radius: var(--ocp-radius-md);
  box-shadow: 0 0 0 3px var(--ocp-accent-glow);
}
#inbox-workbench .inbox-disclosure-icon {
  margin-left: auto;
  color: var(--ocp-text-muted);
  font-size: 0.7rem;
  transition: color 0.15s ease, transform 0.15s ease;
}
#inbox-workbench .inbox-disclosure[open] > summary .inbox-disclosure-icon {
  color: var(--ocp-accent);
  transform: rotate(90deg);
}

/* ── Form Elements ────────────────────────── */
.ocp-input {
  width: 100%; height: 40px; padding: 0 14px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-md); color: var(--ocp-text-primary);
  font-size: 0.88rem; outline: none; transition: all 0.2s;
  font-family: inherit;
}
.ocp-input::placeholder { color: var(--ocp-text-dim); }
.ocp-input:focus { border-color: var(--ocp-accent); box-shadow: 0 0 0 3px var(--ocp-accent-glow); }
.ocp-textarea {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-md); color: var(--ocp-text-primary);
  font-size: 0.88rem; outline: none; transition: all 0.2s;
  font-family: inherit; resize: vertical; min-height: 80px;
}
.ocp-textarea::placeholder { color: var(--ocp-text-dim); }
.ocp-textarea:focus { border-color: var(--ocp-accent); box-shadow: 0 0 0 3px var(--ocp-accent-glow); }
.ocp-select {
  width: 100%; height: 40px; padding: 0 14px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-md); color: var(--ocp-text-primary);
  font-size: 0.88rem; outline: none; cursor: pointer; font-family: inherit;
  appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='rgba(255,230,203,0.48)' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.ocp-label { display: block; font-size: 0.82rem; font-weight: 600; color: var(--ocp-text-secondary); margin-bottom: 6px; }

/* ── Tables ───────────────────────────────── */
.ocp-table-wrap {
  overflow-x: auto; border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-lg);
}
.ocp-table {
  width: 100%; border-collapse: collapse; font-size: 0.85rem;
}
.ocp-table th {
  text-align: left; padding: 10px 14px; font-weight: 500; font-size: 0.68rem;
  font-family: var(--ocp-font-mono);
  color: var(--ocp-text-muted); text-transform: uppercase; letter-spacing: 0.10em;
  background: var(--ocp-bg-surface); border-bottom: 1px solid var(--ocp-border);
}
.ocp-table td {
  padding: 10px 14px; border-bottom: 1px solid var(--ocp-border-light);
  color: var(--ocp-text-secondary);
  font-variant-numeric: lining-nums tabular-nums;
}
.ocp-table tr:last-child td { border-bottom: none; }
.ocp-table tbody tr { transition: background 0.12s ease; }
.ocp-table tr:hover td { background: var(--ocp-accent-subtle); }
.ocp-table tr:hover td:first-child { box-shadow: inset 2px 0 0 var(--ocp-accent); }

/* ── Alerts / Status Rows ─────────────────── */
.ocp-alert {
  border-radius: var(--ocp-radius-lg); padding: 12px 14px;
  border: 1px solid var(--ocp-border); background: rgba(6, 40, 42, 0.5);
  display: flex; align-items: flex-start; gap: 10px;
}
.ocp-alert--info { border-color: rgba(96, 165, 250, 0.25); background: rgba(30, 64, 175, 0.12); }
.ocp-alert--warn { border-color: rgba(255, 172, 2, 0.25); background: rgba(113, 63, 18, 0.10); }
.ocp-alert--danger { border-color: rgba(251, 44, 54, 0.25); background: rgba(127, 29, 29, 0.12); }
.ocp-alert--success { border-color: rgba(143, 255, 137, 0.20); background: rgba(20, 83, 45, 0.12); }

/* ── Empty State ──────────────────────────── */
.ocp-empty {
  text-align: center; padding: 32px 20px; border: 1px dashed var(--ocp-border);
  border-radius: var(--ocp-radius-xl); color: var(--ocp-text-muted);
  font-size: 0.9rem; background: var(--ocp-bg-surface);
}
.ocp-empty i { font-size: 2rem; display: block; margin-bottom: 12px; opacity: 0.5; }

/* ── Progress / Health Bars ──────────────── */
.ocp-bar {
  height: 8px; border-radius: var(--ocp-radius-full); background: var(--ocp-bg-surface);
  border: 1px solid var(--ocp-border-light); overflow: hidden;
}
.ocp-bar-fill {
  height: 100%; border-radius: inherit;
  background: linear-gradient(90deg, var(--ocp-accent-bright), var(--ocp-accent-deep));
  min-width: 2%; transition: width 0.5s ease;
}

/* ── Deals / Pipeline Boards ──────────────── */
.deals-page {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.deals-hero {
  padding: 18px;
  background: radial-gradient(circle at 20% 0%, rgba(255, 172, 2, 0.12), transparent 34%), rgba(20, 25, 33, 0.94);
}
.deals-hero-grid {
  display: flex;
  justify-content: space-between;
  gap: 0.9rem;
  align-items: center;
  flex-wrap: wrap;
}
.deals-hero-copy { max-width: 48rem; }
.deals-kicker {
  color: var(--ocp-text-secondary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 0.72rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}
.deals-title {
  margin-top: 0.4rem;
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -0.05em;
}
.deals-subtitle {
  margin-top: 0.55rem;
  color: var(--ocp-text-secondary);
  font-size: 0.96rem;
  line-height: 1.45;
}
.deals-hero-meta {
  margin-top: 0.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.deals-hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.4rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 172, 2, 0.18);
  background: rgba(255, 172, 2, 0.08);
  color: var(--ocp-text-secondary);
  font-size: 0.74rem;
  font-weight: 700;
}
.deals-hero-chip i { color: var(--ocp-accent); }
.deals-hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
  min-width: max-content;
}
.deals-hero-link {
  color: var(--ocp-text-secondary);
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  padding: 0.45rem 0.72rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  transition: all 0.15s ease;
}
.deals-hero-link:hover {
  color: var(--ocp-text-primary);
  border-color: rgba(255, 172, 2, 0.18);
  background: rgba(255, 172, 2, 0.08);
}
.deals-pipeline-switcher {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.deals-pipeline-tabs {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding: 0.3rem;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--ocp-border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  scrollbar-width: none;
}
.deals-pipeline-tabs::-webkit-scrollbar {
  display: none;
}
.deals-pipeline-tab {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ocp-text-secondary);
  border-radius: 13px;
  height: 38px;
  padding: 0 0.9rem 0 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.deals-pipeline-tab:hover,
.deals-pipeline-tab.active,
.deals-pipeline-tab[aria-pressed="true"] {
  color: var(--ocp-text-primary);
  border-color: rgba(255, 172, 2, 0.16);
  background: rgba(255, 172, 2, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.deals-pipeline-tab:focus-visible {
  outline: 2px solid rgba(255, 172, 2, 0.45);
  outline-offset: 2px;
}
.deals-tab-count {
  min-width: 1.65rem;
  padding: 0.14rem 0.35rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ocp-text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.68rem;
  font-weight: 900;
  text-align: center;
}
.deals-pipeline-panels {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.deals-pipeline-panel { display: none; }
.deals-pipeline-panel.active { display: block; }
.pipeline-section {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.pipeline-section + .pipeline-section {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.pipeline-section-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 0.2rem;
}
.pipeline-section-copy { max-width: 52rem; }
.pipeline-section-title {
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--ocp-text-primary);
}
.pipeline-section-subtitle {
  margin-top: 0.35rem;
  color: var(--ocp-text-secondary);
  font-size: 0.92rem;
  line-height: 1.45;
}
.pipeline-section-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  background: rgba(212, 168, 83, 0.12);
  color: var(--ocp-accent);
  font-size: 0.72rem;
  font-weight: 900;
  text-align: center;
}
.pipeline-board,
.pipeline-board-scroll {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 1fr);
  gap: 0.85rem;
  overflow-x: auto;
  padding: 0.25rem 0 0.75rem;
  min-height: 20rem;
  align-items: stretch;
  scroll-snap-type: x proximity;
  position: relative;
}
.pipeline-board-empty { min-height: 15rem; }
.pipeline-board::before,
.pipeline-board-scroll::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  right: 0.5rem;
  top: 1.2rem;
  height: 2px;
  background: linear-gradient(90deg, rgba(212, 168, 83, 0.08), rgba(212, 168, 83, 0.38), rgba(212, 168, 83, 0.08));
  pointer-events: none;
  opacity: 0.65;
}
.pipeline-column {
  min-width: 280px;
  max-width: none;
  flex: 1 0 280px;
  scroll-snap-align: start;
  position: relative;
  background: linear-gradient(180deg, rgba(20, 25, 33, 0.97), rgba(13, 17, 23, 0.99));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 0.85rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
}
.pipeline-column::after {
  content: '';
  position: absolute;
  top: 1.12rem;
  right: -0.5rem;
  width: 1rem;
  height: 2px;
  background: linear-gradient(90deg, rgba(212, 168, 83, 0.36), transparent);
  pointer-events: none;
}
.pipeline-column:last-child::after { display: none; }
.pipeline-column-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 0.6rem;
  margin-bottom: 0.7rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ocp-text-secondary);
}
.pipeline-column-count {
  color: var(--ocp-accent);
  background: rgba(212, 168, 83, 0.12);
  border: 1px solid rgba(212, 168, 83, 0.18);
  min-width: 2rem;
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
  text-align: center;
}
.pipeline-deal-card {
  display: block;
  padding: 9px 11px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.07);
  margin-bottom: 7px;
  text-decoration: none;
  color: inherit;
  transition: all 0.18s ease;
}
.pipeline-deal-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(212, 168, 83, 0.3);
}
.pipeline-deal-name {
  font-weight: 700;
  font-size: 0.86rem;
  line-height: 1.22;
  margin-bottom: 3px;
}
.pipeline-deal-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
}
.pipeline-badge {
  font-size: 0.58rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 5px;
  border-radius: var(--ocp-radius-full);
  letter-spacing: 0.04em;
}
.pipeline-badge-dc { background: rgba(96, 165, 250, 0.12); color: var(--ocp-info); }
.pipeline-badge-mf { background: rgba(143, 255, 137, 0.12); color: var(--ocp-success); }
.pipeline-badge-land { background: var(--ocp-accent-subtle); color: var(--ocp-accent); }
.pipeline-badge-opportunity { background: var(--ocp-danger-subtle); color: var(--ocp-danger); }
.pipeline-badge-financing { background: rgba(6, 182, 212, 0.12); color: #22d3ee; }
.pipeline-badge-rentals, .pipeline-badge-rental { background: rgba(244, 114, 182, 0.12); color: #f472b6; }
.pipeline-badge-retail { background: rgba(251, 191, 36, 0.12); color: #fbbf24; }
.pipeline-badge-industrial { background: rgba(148, 163, 184, 0.15); color: #9ca3af; }
.pipeline-badge-commercial { background: rgba(168, 85, 247, 0.12); color: #c084fc; }
.pipeline-badge-gold { background: rgba(250, 204, 21, 0.15); color: #facc15; }
.pipeline-badge-bank-reo { background: rgba(59, 130, 246, 0.14); color: #93c5fd; }
.pipeline-badge-distress { background: rgba(248, 113, 113, 0.14); color: #fca5a5; }
.pipeline-badge-pre-ipo { background: rgba(34, 197, 94, 0.12); color: #86efac; }
.pipeline-badge-residential { background: rgba(244, 114, 182, 0.12); color: #f9a8d4; }
.pipeline-badge-deal { background: rgba(148, 163, 184, 0.10); color: #94a3b8; }
.pipeline-fee { font-size: 0.8rem; font-weight: 700; color: var(--ocp-accent); }
.pipeline-fs { font-size: 0.58rem; font-weight: 700; background: rgba(139, 92, 246, 0.15); color: #a78bfa; padding: 1px 5px; border-radius: 4px; letter-spacing: 0.03em; }
.pipeline-stage-timer { font-size: 0.65rem; margin-top: 3px; font-weight: 500; }
/* Pipeline card component (FB/Sourced/Intake panels) */
.pipeline-card {
  background: var(--ocp-bg-elevated);
  border: 1px solid var(--ocp-border);
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.pipeline-card:hover {
  border-color: var(--ocp-accent-border);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.pipeline-card-body { display: flex; flex-direction: column; gap: 4px; }
.pipeline-card-name {
  font-size: 13px; font-weight: 600; color: var(--ocp-text-primary);
  line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pipeline-card-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pipeline-card-footer {
  font-size: 11px; color: var(--ocp-text-dim); line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pipeline-card-source-badge {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 9px; font-weight: 700; text-transform: uppercase;
  padding: 1px 5px; border-radius: 3px; letter-spacing: 0.3px;
}
.pipeline-card-email-badge { color: var(--ocp-text-muted); font-size: 10px; margin-left: auto; }
.pipeline-card-stage-badge {
  font-size: 9px; font-weight: 600; padding: 1px 5px; border-radius: 3px;
  background: var(--ocp-bg-elevated); color: var(--ocp-text-muted);
}
/* Staleness color coding */
.staleness-stale { border-left: 3px solid rgba(248, 113, 113, 0.6) !important; }
.staleness-warn { border-left: 3px solid rgba(251, 191, 36, 0.5) !important; }
.staleness-fresh { border-left: 3px solid transparent; }
/* Pipeline velocity bars */
.pipeline-velo-bar { height: 8px; border-radius: 4px; background: var(--ocp-accent); min-width: 3px; transition: width 0.6s ease; }
.pipeline-velo-bar--intake { background: #64748b; }
.pipeline-velo-bar--review { background: #f59e0b; }
.pipeline-velo-bar--active { background: #3b82f6; }
.pipeline-velo-bar--late { background: #10b981; }
.pipeline-deal-location { font-size: 0.7rem; color: var(--ocp-text-dim); margin-bottom: 1px; }

/* Source badges on pipeline cards */
.pipeline-source-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 1px 5px;
  border-radius: 3px;
  letter-spacing: 0.3px;
  line-height: 1.2;
}
.pipeline-source-badge .fa-facebook,
.pipeline-source-badge .fa-envelope,
.pipeline-source-badge .fa-user { font-size: 8px; }
.fb-badge { background: #1877f2; color: #fff; }
.email-badge { background: #22c55e; color: #fff; }
.broker-badge { background: #6366f1; color: #fff; }
.pipeline-deal-next { font-size: 0.7rem; color: var(--ocp-text-muted); line-height: 1.3; }
.pipeline-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  text-align: center;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.025));
  border-radius: 18px;
  color: var(--ocp-text-secondary);
}
.pipeline-empty-state {
  width: min(100%, 24rem);
  justify-self: center;
  padding: 1rem 1.05rem;
}
.pipeline-empty-hero { min-height: 12rem; }
.pipeline-empty-icon {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 172, 2, 0.10);
  color: var(--ocp-accent);
  border: 1px solid rgba(255, 172, 2, 0.20);
  box-shadow: 0 0 0 4px rgba(255, 172, 2, 0.03);
}
.pipeline-empty-icon i { font-size: 1rem; }
.pipeline-empty-copy { display: grid; gap: 0.25rem; }
.pipeline-empty-title {
  color: var(--ocp-text-primary);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.pipeline-empty-body {
  color: var(--ocp-text-secondary);
  font-size: 0.78rem;
  line-height: 1.45;
  max-width: 18rem;
}

@media (max-width: 1280px) {
  .deals-hero-actions { align-items: flex-start; }
}
@media (max-width: 768px) {
  .deals-title { font-size: 1.65rem; }
  .deals-hero-actions { width: 100%; min-width: 0; align-items: flex-start; }
  .deals-pipeline-tab,
  .pipeline-section-chip { width: 100%; justify-content: center; }
}

/* ── Opportunity Cards ────────────────────── */
.opportunity-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.opportunity-card {
  display: block; text-decoration: none; color: inherit;
  background: var(--ocp-bg-card); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-xl); padding: 16px;
  transition: all 0.2s ease; position: relative; overflow: hidden;
}
.opportunity-card:hover { border-color: var(--ocp-accent-border); transform: translateY(-2px); box-shadow: var(--ocp-shadow-glow); }
.opportunity-card.hot { border-left: 3px solid var(--ocp-accent); }
.opportunity-card.watch { border-left: 3px solid rgba(251, 191, 36, 0.6); }
.opp-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.opp-top strong { color: var(--ocp-accent); font-size: 1.1rem; font-weight: 700; }
.opp-name { font-weight: 700; font-size: 1rem; line-height: 1.25; margin-bottom: 4px; }
.opp-meta { color: var(--ocp-text-muted); font-size: 0.8rem; margin-bottom: 8px; }
.opp-money { color: var(--ocp-success); font-weight: 700; font-size: 1.05rem; margin-bottom: 6px; }
.opp-next { color: var(--ocp-text-secondary); font-size: 0.82rem; line-height: 1.35; }

/* ── Battle Plan Items ────────────────────── */
.battle-item {
  display: grid; grid-template-columns: 60px 1fr auto; gap: 12px; align-items: center;
  border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-xl);
  padding: 12px 14px; background: var(--ocp-bg-surface);
  text-decoration: none; color: inherit; transition: all 0.18s ease;
}
.battle-item:hover { border-color: var(--ocp-accent-border); background: var(--ocp-bg-card); }
.battle-priority {
  font-weight: 700; font-size: 0.8rem; text-align: center;
  padding: 6px; border-radius: var(--ocp-radius-md);
  background: rgba(255, 230, 203, 0.05);
}
.battle-item.red .battle-priority { color: #fecaca; background: rgba(127, 29, 29, 0.35); }
.battle-item.yellow .battle-priority { color: #fde68a; background: rgba(113, 63, 18, 0.30); }
.battle-item.blue .battle-priority { color: #bfdbfe; background: rgba(30, 64, 175, 0.25); }
.battle-kicker { color: var(--ocp-text-muted); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.battle-title { font-weight: 700; margin-top: 2px; font-size: 0.9rem; }
.battle-detail { color: var(--ocp-text-secondary); font-size: 0.82rem; margin-top: 2px; }
.battle-cta { color: var(--ocp-accent); font-weight: 700; font-size: 0.8rem; white-space: nowrap; }

/* ── Stage Health ─────────────────────────── */
.stage-health-list { display: flex; flex-direction: column; gap: 10px; }
.stage-health {
  display: grid; grid-template-columns: 130px 1fr 180px; gap: 10px; align-items: center;
  text-decoration: none; color: inherit; padding: 4px 0;
}
.stage-health-name { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ocp-text-secondary); font-size: 0.85rem; }
.stage-health-name span { width: 8px; height: 8px; border-radius: var(--ocp-radius-full); background: var(--ocp-success); flex-shrink: 0; }
.stage-health.yellow .stage-health-name span { background: var(--ocp-warning); }
.stage-health.red .stage-health-name span { background: var(--ocp-danger); }
.stage-health-bar { height: 10px; border-radius: var(--ocp-radius-full); background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border-light); overflow: hidden; }
.stage-health-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--ocp-accent-bright), var(--ocp-accent-deep)); min-width: 2%; border-radius: inherit; }
.stage-health-metrics { text-align: right; font-size: 0.85rem; }
.stage-health-metrics b { font-weight: 700; }
.stage-health-metrics small { display: block; color: var(--ocp-text-muted); font-size: 0.7rem; }

/* ── Intel / Data Rows ────────────────────── */
.intel-row {
  display: block; text-decoration: none; color: inherit;
  border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-lg);
  padding: 12px 14px; background: var(--ocp-bg-surface);
  transition: all 0.15s ease;
}
.intel-row:hover { border-color: var(--ocp-accent-border); background: var(--ocp-bg-card); }
.intel-row.red { border-color: rgba(251, 44, 54, 0.20); }
.intel-row.yellow { border-color: rgba(255, 172, 2, 0.18); }
.intel-row.blue { border-color: rgba(96, 165, 250, 0.16); }
.intel-type { color: var(--ocp-text-muted); font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.intel-title { font-weight: 700; margin-top: 2px; font-size: 0.92rem; }
.intel-detail { color: var(--ocp-text-secondary); font-size: 0.82rem; margin-top: 2px; line-height: 1.35; }

/* ── Quality / DC Grids ───────────────────── */
.quality-score { display: flex; align-items: baseline; gap: 8px; }
.quality-score span { font-size: 2.8rem; font-weight: 800; color: var(--ocp-success); line-height: 1; font-family: var(--ocp-font-serif); }
.quality-score small { color: var(--ocp-text-muted); font-weight: 600; text-transform: uppercase; font-size: 0.72rem; letter-spacing: 0.04em; }
.quality-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.quality-grid a, .dc-strip > * {
  display: block; text-decoration: none; color: inherit;
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg); padding: 12px; transition: all 0.15s ease;
}
.quality-grid a:hover, .dc-strip > *:hover { border-color: var(--ocp-accent-border); }
.quality-grid strong, .dc-strip strong { display: block; font-size: 1.3rem; font-weight: 800; color: var(--ocp-accent); }
.quality-grid span, .dc-strip span { color: var(--ocp-text-muted); font-size: 0.72rem; font-weight: 600; text-transform: uppercase; }
.dc-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.dc-strip .danger strong { color: var(--ocp-danger); }
.node-row { display: flex; justify-content: space-between; gap: 10px; align-items: center; border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-lg); padding: 10px 12px; background: var(--ocp-bg-surface); }
.node-row small { display: block; color: var(--ocp-text-muted); font-size: 0.72rem; margin-top: 2px; }
.node-row span { color: var(--ocp-info); font-weight: 700; }

/* ── Chat / Boardroom ─────────────────────── */
.ocp-chat-shell {
  background: linear-gradient(180deg, rgba(3, 26, 26, 0.96), rgba(6, 40, 42, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 230, 203, 0.04), var(--ocp-shadow-lg);
}
.ocp-chat-row { display: flex; width: 100%; align-items: flex-end; gap: 8px; }
.ocp-chat-row--user { justify-content: flex-end; }
.ocp-chat-row--agent { justify-content: flex-start; }
.ocp-chat-bubble-wrap { max-width: min(76%, 720px); }
.ocp-chat-bubble {
  display: inline-block; max-width: 100%;
  border-radius: 20px; padding: 10px 14px;
  font-size: 0.92rem; line-height: 1.4; white-space: pre-wrap; word-break: break-word;
  border: 1px solid rgba(255, 230, 203, 0.06);
}
.ocp-chat-row--user .ocp-chat-bubble {
  color: #fff; background: linear-gradient(180deg, #FFAC02 0%, #d48a00 100%);
  border-bottom-right-radius: 4px; border-color: transparent;
  box-shadow: 0 8px 20px rgba(255, 172, 2, 0.20);
}
.ocp-chat-row--agent .ocp-chat-bubble {
  color: var(--ocp-text-primary);
  background: linear-gradient(180deg, var(--ocp-bg-card), var(--ocp-bg-surface));
  border-bottom-left-radius: 4px;
}
.ocp-chat-meta { margin: 0 6px 4px; font-size: 0.65rem; line-height: 1; color: var(--ocp-text-muted); }
.ocp-chat-row--user .ocp-chat-meta { text-align: right; }

/* ── Typing Animation ─────────────────────── */
.ocp-typing-dot {
  display: inline-block; width: 7px; height: 7px; border-radius: var(--ocp-radius-full);
  background: var(--ocp-text-muted); margin-right: 3px;
  animation: ocpTypingBounce 1.1s infinite ease-in-out;
}
.ocp-typing-dot:nth-child(2) { animation-delay: 0.15s; }
.ocp-typing-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes ocpTypingBounce {
  0%, 80%, 100% { opacity: 0.35; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}

/* ── Tabs ─────────────────────────────────── */
.ocp-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--ocp-border); margin-bottom: 20px; overflow-x: auto; }
.ocp-tab {
  padding: 10px 18px; font-size: 0.85rem; font-weight: 600;
  color: var(--ocp-text-muted); border-bottom: 2px solid transparent;
  cursor: pointer; transition: all 0.15s; white-space: nowrap;
  background: transparent; border-top: none; border-left: none; border-right: none;
  font-family: inherit;
}
.ocp-tab:hover { color: var(--ocp-text-primary); }
.ocp-tab.active { color: var(--ocp-accent); border-bottom-color: var(--ocp-accent); }
.ocp-tabs.command-tabs-sticky {
  position: sticky;
  top: calc(var(--ocp-header-h) + 10px);
  z-index: 30;
  padding-top: 4px;
  margin-bottom: 18px;
  backdrop-filter: blur(14px);
  background: linear-gradient(180deg, rgba(3, 26, 26, 0.96) 0%, rgba(3, 26, 26, 0.82) 100%);
}

/* ── Filters / Toolbar ────────────────────── */
.ocp-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ocp-filter-pill {
  display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px;
  border-radius: var(--ocp-radius-full); border: 1px solid var(--ocp-border);
  background: var(--ocp-bg-surface); font-size: 0.8rem; color: var(--ocp-text-secondary);
  cursor: pointer; transition: all 0.12s; text-decoration: none;
}
.ocp-filter-pill:hover { border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.ocp-filter-pill.active { background: var(--ocp-accent-subtle); border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.ocp-filter-pill:focus-visible { outline: 2px solid var(--ocp-accent); outline-offset: 2px; }

/* Approval filter toolbar */
.approval-filter-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
}
.approval-filter-cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg);
  background: var(--ocp-bg-surface);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}
.approval-filter-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 230, 203, 0.05);
  color: var(--ocp-text-muted);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.approval-filter-cluster .filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.filter-pill:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: 2px;
}
.filter-pill.active,
.filter-pill[aria-pressed="true"] {
  background: var(--ocp-accent-subtle);
  border-color: var(--ocp-accent-border);
  color: var(--ocp-accent);
  box-shadow: 0 0 0 1px var(--ocp-accent-border) inset;
}

/* ── Modal / Overlay ──────────────────────── */
.ocp-overlay {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(3, 26, 26, 0.80); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.ocp-modal {
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-xl); padding: 24px;
  max-width: 520px; width: 100%; box-shadow: var(--ocp-shadow-lg);
  max-height: 90vh; overflow-y: auto;
}

/* ── Links ────────────────────────────────── */
.ocp-link { color: var(--ocp-accent); text-decoration: none; transition: all 0.12s; }
.ocp-link:hover { text-decoration: underline; opacity: 0.85; }

/* ── Bot Button ───────────────────────────── */
.ocp-bot-btn {
  position: fixed; right: 24px; bottom: 24px; z-index: 1100;
  width: 50px; height: 50px; border-radius: var(--ocp-radius-full);
  display: grid; place-items: center;
  background: var(--ocp-gradient-gold);
  color: #1A0F00; font-size: 1.2rem;
  box-shadow: 0 12px 32px rgba(255, 172, 2, 0.25);
  text-decoration: none; transition: all 0.2s ease;
}
.ocp-bot-btn:hover { transform: scale(1.05) translateY(-2px); box-shadow: 0 16px 40px rgba(255, 172, 2, 0.35); }

/* ── Responsive ───────────────────────────── */
@media (max-width: 1200px) {
  .ocp-search input { width: 180px; }
  .ocp-nav-item { padding: 6px 10px; font-size: 0.82rem; }
  .opportunity-grid { grid-template-columns: repeat(2, 1fr); }
  .pipeline-column { min-width: 240px; max-width: 240px; }
}

@media (max-width: 1024px) {
  .ocp-header-right { gap: 6px; }
  .ocp-nav { gap: 0; }
  .ocp-nav-item { padding: 6px 8px; font-size: 0.78rem; }
  .ocp-user-meta { display: none; }
  .stage-health { grid-template-columns: 1fr; gap: 4px; }
  .stage-health-metrics { text-align: left; }
  .dc-strip { grid-template-columns: repeat(2, 1fr); }
  .quality-grid { grid-template-columns: repeat(2, 1fr); }
  .pipeline-board .pipeline-column,
  .pipeline-board-scroll .pipeline-column { min-width: 220px; max-width: 220px; }
}

@media (max-width: 768px) {
  :root { --ocp-header-h: 56px; --ocp-summary-h: auto; --ocp-sidebar-w: 0; }
  .ocp-header { padding: 0 12px; gap: 8px; }
  .ocp-nav { flex-wrap: wrap; overflow-x: auto; gap: 2px; }
  .ocp-nav-item { font-size: 0.75rem; padding: 5px 8px; }
  .ocp-search { display: none; }
  .ocp-header-right { gap: 4px; }
  .ocp-summary-strip { flex-wrap: wrap; padding: 6px 12px; gap: 8px; overflow-x: auto; }
  .summary-pill { font-size: 0.72rem; }
  .summary-actions { margin-left: 0; }
  .ocp-main { padding: calc(var(--ocp-header-h) + 60px) 14px 24px; }
  .ocp-card-pad { padding: 14px; }
  .opportunity-grid { grid-template-columns: 1fr; }
  .pipeline-column { min-width: 200px; max-width: 260px; }
  .battle-item { grid-template-columns: 1fr; gap: 6px; }
  .hero-scorecard { grid-template-columns: repeat(2, 1fr); }
  .hero-scorecard div { padding: 10px; }
  .hero-scorecard div span { font-size: 1.2rem; }
  .ocp-stat-value { font-size: 1.4rem; }
  .ocp-bot-btn { width: 44px; height: 44px; font-size: 1rem; right: 16px; bottom: 16px; }
  .grid-cols-1.xl\\:grid-cols-\\[1\\.15fr_\\.85fr\\],
  .grid-cols-1.xl\\:grid-cols-\\[\\.9fr_1\\.1fr\\],
  .grid-cols-1.xl\\:grid-cols-\\[1\\.1fr_\\.9fr\\],
  .grid-cols-1.xl\\:grid-cols-\\[1\\.35fr_\\.65fr\\] { grid-template-columns: 1fr !important; }
}

@media (max-width: 480px) {
  .ocp-logo-text { font-size: 0.9rem; }
  .ocp-nav-item { font-size: 0.7rem; padding: 4px 6px; }
  .ocp-main { padding: calc(var(--ocp-header-h) + 50px) 10px 20px; }
  .quality-grid { grid-template-columns: 1fr; }
  .dc-strip { grid-template-columns: 1fr; }
}

/* ═══ Backward Compatibility — old class names ═══ */
.stat-card { background: var(--ocp-bg-card); border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-xl); padding: 22px; position: relative; overflow: hidden; transition: all 0.25s ease; text-decoration: none; color: inherit; }
.stat-card:hover { border-color: var(--ocp-accent-border); transform: translateY(-2px); box-shadow: var(--ocp-shadow-glow); }
.stat-icon { width: 46px; height: 46px; border-radius: var(--ocp-radius-md); display: grid; place-items: center; margin-bottom: 14px; font-size: 1.15rem; }
.stat-label { font-size: .78rem; color: var(--ocp-text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .8px; font-weight: 600; }
.stat-value { font-size: 1.9rem; font-weight: 800; letter-spacing: -.03em; }
.stat-change { display: flex; align-items: center; gap: 5px; font-size: .8rem; color: var(--ocp-success); margin-top: 8px; }
.stat-icon.gold { background: var(--ocp-accent-subtle); color: var(--ocp-accent); }
.stat-icon.green { background: var(--ocp-success-subtle); color: var(--ocp-success); }
.stat-icon.blue { background: var(--ocp-info-subtle); color: var(--ocp-info); }
.stat-icon.orange { background: var(--ocp-warning-subtle); color: var(--ocp-warning); }
.alert-row { border-radius: var(--ocp-radius-lg); padding: 13px 15px; border: 1px solid var(--ocp-border); background: rgba(6,40,42,0.5); }
.alert-row.red { border-color: rgba(251,44,54,0.25); background: rgba(127,29,29,0.12); }
.alert-row.yellow { border-color: rgba(255,172,2,0.22); background: rgba(113,63,18,0.08); }
.alert-row.blue { border-color: rgba(96,165,250,0.18); background: rgba(30,64,175,0.08); }

/* ═══ Inline-to-External Migration ═══ */
/* Moved from base.html <style> block */

/* ── Hero Command ──────────────────────────── */

/* ── Pending badge (header count badge) ───── */
.pending-badge {
  display: inline-flex; align-items: center;
  padding: 3px 12px; border-radius: var(--ocp-radius-full);
  font-size: 0.72rem; font-weight: 700;
  background: var(--ocp-accent-subtle);
  color: var(--ocp-accent);
  border: 1px solid var(--ocp-accent-border);
  white-space: nowrap;
}

.hero-command {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  background: radial-gradient(circle at 20% 0%, rgba(255,172,2,0.10), transparent 34%);
}
.hero-scorecard { display: grid; grid-template-columns: repeat(2, minmax(110px, 1fr)); gap: 10px; min-width: 280px; }
.hero-scorecard > * { background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-lg); padding: 14px; }
.hero-scorecard span { display: block; font-size: 1.7rem; font-weight: 800; color: var(--ocp-accent); font-family: var(--ocp-font-serif); }
.hero-scorecard small { color: var(--ocp-text-muted); text-transform: uppercase; font-size: 0.65rem; font-weight: 700; letter-spacing: 0.06em; }
.hero-scorecard .danger span { color: var(--ocp-danger); }
.money-tile { min-height: 170px; }
.risk-tile { border-color: rgba(251,44,54,0.20); }

/* Follow-up board polish */
.followup-lane-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: linear-gradient(180deg, rgba(3, 26, 26, 0.96) 0%, rgba(3, 26, 26, 0.82) 100%);
  backdrop-filter: blur(12px);
}
.followup-lane-header h2 {
  letter-spacing: 0.12em;
}
.obligation-card {
  position: relative;
  overflow: hidden;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.obligation-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--ocp-shadow-md);
}
.obligation-card:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: 2px;
}

/* ── Command Tab Panels ──────────────────── */
.command-tab-panel {
  animation: cmdTabFadeIn 0.25s ease-out;
}
.command-tab-panel[style*="display: none"] {
  animation: none;
}
@keyframes cmdTabFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Focus-visible accessibility ─────────── */
*:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ── Popover (detail panels, tooltip-like) ── */
.ocp-popover {
  position: absolute; z-index: 1050;
  background: var(--ocp-bg-elevated);
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-md);
  padding: 12px 16px;
  box-shadow: var(--ocp-shadow-md);
  max-width: 320px;
  font-size: 0.82rem;
  color: var(--ocp-text-secondary);
}

/* ── Cmd+K Palette ─────────────────────────── */

/* ── Approval Queue Sections ──────────────── */
.approval-section {
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg);
  background: var(--ocp-bg-card);
  overflow: hidden;
}
.approval-section-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  background: var(--ocp-bg-surface);
  border-bottom: 1px solid var(--ocp-border-light);
}
.approval-section-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.88rem; font-weight: 600;
  color: var(--ocp-text-primary);
}
.section-icon { font-size: 0.85rem; }
.section-icon--required { color: var(--ocp-danger); }
.section-icon--info { color: var(--ocp-warning); }
.section-icon--recent { color: var(--ocp-text-muted); }
.section-count {
  font-size: 0.7rem; font-weight: 700;
  padding: 1px 8px; border-radius: var(--ocp-radius-full);
  background: var(--ocp-accent-subtle);
  color: var(--ocp-accent);
}
.approval-section-body {
  padding: 16px;
}

/* ── Command Row Patterns (deadlines, activity, intel) ── */
.cmd-row {
  display: block; padding: 10px 14px;
  border-radius: var(--ocp-radius-md);
  border: 1px solid var(--ocp-border-light);
  background: var(--ocp-bg-surface);
  text-decoration: none;
  transition: all 0.15s;
}
.cmd-row:hover { border-color: var(--ocp-accent-border); background: var(--ocp-accent-subtle); }
.cmd-row-type {
  font-size: 0.65rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--ocp-text-muted);
}
.cmd-row-title {
  font-size: 0.88rem; font-weight: 600;
  color: var(--ocp-text-primary);
  margin-top: 2px;
}
.cmd-row-detail {
  font-size: 0.78rem; color: var(--ocp-text-dim);
  margin-top: 1px;
}
.cmd-row--warning .cmd-row-title { color: var(--ocp-warning); }
.cmd-row--danger  .cmd-row-title { color: var(--ocp-danger); }
.cmd-row--info    .cmd-row-title { color: var(--ocp-info); }

/* ── Command Leads Triage Surface ─────────── */
.command-leads-shell { min-width: 0; }
.lead-mission-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}
.lead-mission-tile {
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--ocp-border-light);
  border-radius: var(--ocp-radius-md);
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.015));
}
.lead-mission-tile span {
  display: block;
  color: var(--ocp-text-primary);
  font-size: 1.2rem;
  line-height: 1.1;
  font-weight: 800;
}
.lead-mission-tile small {
  display: block;
  margin-top: 4px;
  color: var(--ocp-text-muted);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.lead-mission-tile--warn { border-color: rgba(245, 158, 11, 0.28); }
.lead-mission-tile--danger { border-color: rgba(239, 68, 68, 0.28); }
.lead-mission-tile--info { border-color: rgba(56, 189, 248, 0.28); }
.lead-command-toolbar {
  display: grid;
  gap: 12px;
}
.lead-filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}
.lead-filter-row .filter-pill {
  flex: 0 0 auto;
  text-decoration: none;
}
.lead-filter-row .filter-pill span {
  opacity: 0.7;
  margin-left: 4px;
}
.lead-search-form {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(520px, 100%);
  padding: 8px 12px;
  border: 1px solid var(--ocp-border-light);
  border-radius: var(--ocp-radius-full);
  background: var(--ocp-bg-surface);
  color: var(--ocp-text-muted);
}
.lead-search-form input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ocp-text-primary);
  font: inherit;
}
.lead-search-form input::placeholder { color: var(--ocp-text-dim); }
.lead-command-table { min-width: 1080px; }
.lead-command-table td { vertical-align: top; }
.lead-command-table td:nth-child(3) { min-width: 220px; }
.lead-command-table td:nth-child(9) { min-width: 210px; max-width: 320px; }
.lead-subtitle {
  margin-top: 2px;
  color: var(--ocp-text-muted);
  font-size: 0.72rem;
  line-height: 1.35;
}
.lead-gap-list {
  display: inline-flex;
  margin-top: 5px;
  padding: 2px 7px;
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: var(--ocp-radius-full);
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.08);
  font-size: 0.65rem;
}
.lead-status-chip {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: var(--ocp-radius-full);
  border: 1px solid var(--ocp-border-light);
  color: var(--ocp-text-secondary);
  background: rgba(148, 163, 184, 0.08);
  font-size: 0.7rem;
}
.lead-stale-note {
  margin-top: 2px;
  color: var(--ocp-warning);
  font-size: 0.68rem;
}
.lead-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.lead-work-hero {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ocp-border-light);
}
.lead-work-action {
  padding: 12px;
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: var(--ocp-radius-md);
  background: rgba(245, 158, 11, 0.06);
}
.lead-work-action-title,
.lead-work-section h4,
.lead-work-form label span {
  display: block;
  margin-bottom: 5px;
  color: var(--ocp-text-muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.lead-work-action p { margin: 0; color: var(--ocp-text-primary); font-weight: 700; }
.lead-work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.lead-work-grid div {
  padding: 10px;
  border: 1px solid var(--ocp-border-light);
  border-radius: var(--ocp-radius-md);
  background: var(--ocp-bg-surface-2);
}
.lead-work-grid span { display: block; color: var(--ocp-text-muted); font-size: 0.68rem; }
.lead-work-grid strong { color: var(--ocp-text-primary); font-size: 0.85rem; }
.lead-work-checklist { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.lead-work-checklist li {
  padding: 10px;
  border: 1px solid var(--ocp-border-light);
  border-radius: var(--ocp-radius-md);
  background: rgba(148, 163, 184, 0.06);
}
.lead-work-checklist strong { display: block; color: var(--ocp-text-primary); font-size: 0.83rem; }
.lead-work-checklist span { color: var(--ocp-text-muted); font-size: 0.75rem; line-height: 1.35; }
.lead-work-form { display: grid; gap: 12px; }
.lead-work-form input,
.lead-work-form textarea {
  width: 100%;
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-md);
  background: var(--ocp-bg-surface-2);
  color: var(--ocp-text-primary);
  padding: 9px 10px;
  font: inherit;
}
.lead-work-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.lead-work-actions { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
@media (max-width: 760px) {
  .lead-work-form-row { grid-template-columns: 1fr; }
  .lead-work-actions { flex-direction: column; align-items: stretch; }
}
.lead-mobile-list { display: none; }
.lead-mobile-card {
  padding: 14px;
  border: 1px solid var(--ocp-border-light);
  border-radius: var(--ocp-radius-md);
  background: var(--ocp-bg-surface);
}
.lead-mobile-card + .lead-mobile-card { margin-top: 10px; }
.lead-mobile-card h3 {
  margin: 10px 0 4px;
  font-size: 0.95rem;
  color: var(--ocp-text-primary);
}
.lead-mobile-card p {
  margin: 0 0 10px;
  color: var(--ocp-text-muted);
  font-size: 0.78rem;
}
.lead-mobile-card dl { display: grid; gap: 8px; margin: 0; }
.lead-mobile-card dt {
  color: var(--ocp-text-muted);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.lead-mobile-card dd {
  margin: 0;
  color: var(--ocp-text-secondary);
  font-size: 0.82rem;
}
@media (max-width: 1100px) {
  .lead-mission-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .lead-mission-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lead-command-table-wrap { display: none; }
  .lead-mobile-list { display: block; }
}

/* ── Intel Filter Pills (promoted from inline) ── */
.intel-filter-pill {
  padding: 3px 10px;
  border-radius: var(--ocp-radius-full);
  font-size: 0.68rem;
  border: 1px solid var(--ocp-border);
  color: var(--ocp-text-dim);
  cursor: pointer;
  transition: all 0.15s;
  background: transparent;
  font-family: inherit;
  white-space: nowrap;
}
.intel-filter-pill:hover { border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.intel-filter-pill.active {
  background: var(--ocp-accent-subtle);
  border-color: var(--ocp-accent-border);
  color: var(--ocp-accent);
}
#cmd-palette-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.75); backdrop-filter: blur(12px);
  display: none; align-items: flex-start; justify-content: center;
  padding-top: 12vh;
}
#cmd-palette-overlay.open { display: flex; }
#cmd-palette {
  width: min(620px, 92vw);
  background: var(--ocp-bg-surface);
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-xl);
  box-shadow: 0 32px 64px rgba(0,0,0,0.6);
  overflow: hidden;
  animation: cmdSlideIn 0.15s ease-out;
}
@keyframes cmdSlideIn {
  from { opacity: 0; transform: translateY(-16px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
#cmd-palette input {
  width: 100%; height: 52px; padding: 0 18px;
  background: transparent; border: none; outline: none;
  color: var(--ocp-text-primary); font-size: 1rem; font-family: inherit;
  border-bottom: 1px solid var(--ocp-border);
}
#cmd-palette input::placeholder { color: var(--ocp-text-dim); }
#cmd-results { max-height: 380px; overflow-y: auto; padding: 6px; }
.cmd-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: var(--ocp-radius-md);
  cursor: pointer; color: var(--ocp-text-secondary); font-size: 0.88rem;
  transition: all 0.1s;
}
.cmd-item:hover, .cmd-item.selected { background: var(--ocp-accent-subtle); color: var(--ocp-accent); }
.cmd-item i { width: 20px; text-align: center; font-size: 0.9rem; opacity: 0.6; }
.cmd-item kbd {
  margin-left: auto; font-size: 0.65rem; padding: 2px 6px;
  border-radius: 4px; background: rgba(255,230,203,0.08);
  color: var(--ocp-text-dim); font-family: inherit;
}
.cmd-section-title {
  padding: 8px 14px 4px; font-size: 0.65rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--ocp-text-dim);
}

/* ── FAB (Floating Action Button) ──────────── */
.ocp-fab {
  position: fixed; right: 24px; bottom: 88px; z-index: 1099;
  width: 48px; height: 48px; border-radius: var(--ocp-radius-full);
  display: grid; place-items: center;
  background: var(--ocp-gradient-gold);
  color: #1A0F00; font-size: 1.1rem; border: none; cursor: pointer;
  box-shadow: 0 8px 24px rgba(255,172,2,0.25);
  transition: all 0.2s ease;
}
.ocp-fab:hover { transform: scale(1.08) translateY(-2px); box-shadow: 0 12px 32px rgba(255,172,2,0.35); }
.ocp-fab-menu {
  position: fixed; right: 24px; bottom: 148px; z-index: 1098;
  display: none; flex-direction: column; gap: 6px;
}
.ocp-fab-menu.open { display: flex; }
.ocp-fab-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; border-radius: var(--ocp-radius-lg);
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  color: var(--ocp-text-secondary); font-size: 0.84rem; font-weight: 500;
  cursor: pointer; text-decoration: none; transition: all 0.15s;
  box-shadow: var(--ocp-shadow-md);
  animation: fabSlideIn 0.12s ease-out backwards;
}
.ocp-fab-item:nth-child(1) { animation-delay: 0.02s; }
.ocp-fab-item:nth-child(2) { animation-delay: 0.04s; }
.ocp-fab-item:nth-child(3) { animation-delay: 0.06s; }
.ocp-fab-item:nth-child(4) { animation-delay: 0.08s; }
.ocp-fab-item:hover { border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.ocp-fab-item i { width: 18px; text-align: center; }
@keyframes fabSlideIn {
  from { opacity: 0; transform: translateY(8px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Side-sheet detail panel ───────────────── */
.ocp-side-sheet-overlay {
  position: fixed; inset: 0; z-index: 3000;
  background: rgba(0,0,0,0.55); backdrop-filter: blur(4px);
  display: none;
}
.ocp-side-sheet-overlay.open { display: block; }
.ocp-side-sheet {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 3001;
  width: min(520px, 88vw);
  background: var(--ocp-bg-surface);
  border-left: 1px solid var(--ocp-border);
  box-shadow: -8px 0 32px rgba(0,0,0,0.4);
  display: none; flex-direction: column;
  animation: sideSheetIn 0.2s ease-out;
}
.ocp-side-sheet.open { display: flex; }
@keyframes sideSheetIn {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}
.ocp-side-sheet-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--ocp-border);
}
.ocp-side-sheet-body { flex: 1; overflow-y: auto; padding: 20px; }

/* ── Keyboard shortcuts toast ──────────────── */
.ocp-shortcuts-toast {
  position: fixed; bottom: 160px; left: 50%; transform: translateX(-50%);
  z-index: 9980;
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-xl); padding: 20px 24px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.5); min-width: 360px;
  display: none;
}
.ocp-shortcuts-toast.open { display: block; animation: cmdSlideIn 0.15s ease-out; }
.shortcut-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 20px; margin-top: 10px; }
.shortcut-row { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; font-size: 0.85rem; }
.shortcut-row kbd {
  font-size: 0.72rem; padding: 3px 8px; border-radius: 5px;
  background: rgba(255,230,203,0.08); border: 1px solid var(--ocp-border-light);
  color: var(--ocp-text-muted); font-family: inherit;
}
.shortcut-row span { color: var(--ocp-text-secondary); }

/* ── Glass hover effect ────────────────────── */
.ocp-glass-hover {
  transition: all 0.25s ease;
}
.ocp-glass-hover:hover {
  background: rgba(255, 172, 2, 0.03);
  border-color: var(--ocp-accent-border);
  box-shadow: 0 0 24px rgba(255,172,2,0.05);
}

/* ── Sidebar mobile collapse ───────────────── */
@media (max-width: 768px) {
  .ocp-sidebar { width: 64px !important; }
  .ocp-sidebar .ocp-logo-text,
  .ocp-sidebar .ocp-snav-item span,
  .ocp-sidebar .ocp-sidebar-section,
  .ocp-sidebar .ocp-snav-sub,
  .ocp-sidebar .meta,
  .ocp-sidebar .ocp-sidebar-search { display: none !important; }
  .ocp-sidebar .ocp-snav-item { justify-content: center; padding: 9px; }
  .ocp-sidebar .ocp-sidebar-profile { justify-content: center; }
  .ocp-sidebar-header { justify-content: center; }
}

/* ── Scrollbar styling ─────────────────────── */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 230, 203, 0.15); border-radius: 999px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 230, 203, 0.25); background-clip: content-box; }
* { scrollbar-width: thin; scrollbar-color: rgba(255, 230, 203, 0.15) transparent; }
.code-panel { background: rgba(3,26,26,0.5); border: 1px solid var(--ocp-border); border-radius: var(--ocp-radius-lg); padding: 16px; color: var(--ocp-text-secondary); overflow: auto; font-family: var(--ocp-font-mono); font-size: 0.85rem; }

/* ═══ Page Transition Loading Bar ═══ */
.ocp-loading-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100000;
  height: 3px; pointer-events: none;
  background: linear-gradient(90deg, var(--ocp-accent), #d48a00, var(--ocp-accent));
  background-size: 200% 100%;
  animation: ocpLoadingSlide 1.4s ease infinite;
  opacity: 0; transition: opacity 0.2s;
}
.ocp-loading-bar.active { opacity: 1; }
@keyframes ocpLoadingSlide {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ═══ Skeleton Loading Shimmer ═══ */
.ocp-skeleton {
  background: linear-gradient(90deg,
    rgba(255,230,203,0.04) 25%,
    rgba(255,230,203,0.10) 50%,
    rgba(255,230,203,0.04) 75%
  );
  background-size: 200% 100%;
  animation: ocpShimmer 1.5s ease infinite;
  border-radius: var(--ocp-radius-md);
}
.ocp-skeleton-line { height: 12px; margin-bottom: 8px; width: 100%; }
.ocp-skeleton-line:nth-child(2) { width: 75%; }
.ocp-skeleton-line:nth-child(3) { width: 60%; }
.ocp-skeleton-card { height: 80px; margin-bottom: 10px; }
.ocp-skeleton-stat { height: 100px; border-radius: var(--ocp-radius-xl); }
@keyframes ocpShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── Title icon color helpers (replaces inline style=\"color:var(--ocp-*)\") ─── */
.ocp-title-icon { color: var(--ocp-accent); }
.ocp-title-icon-accent { color: var(--ocp-accent); }
.ocp-title-icon-info { color: var(--ocp-info); }
.ocp-title-icon-success { color: var(--ocp-success); }
.ocp-title-icon-danger { color: var(--ocp-danger); }
.ocp-title-icon-warning { color: var(--ocp-warning); }
.ocp-title-icon-muted { color: var(--ocp-text-muted); }

/* ── Small link (replaces inline style=\"font-size:0.78rem\") ─── */
.ocp-link-sm { color: var(--ocp-accent); text-decoration: none; font-size: 0.78rem; transition: all 0.12s; }
.ocp-link-sm:hover { text-decoration: underline; opacity: 0.85; }

/* ── Money text color helpers (replaces inline style=\"color:var(--ocp-*)\") ─── */
.ocp-money-success { color: var(--ocp-success); }
.ocp-money-info { color: var(--ocp-info); }
.ocp-money-danger { color: var(--ocp-danger); }

/* ── Enhanced empty state ──────────────────── */
.ocp-empty-actionable {
  text-align: center; padding: 40px 24px;
  border: 1px dashed var(--ocp-border);
  border-radius: var(--ocp-radius-xl);
  background: var(--ocp-bg-surface);
}
.ocp-empty-actionable i {
  font-size: 2.4rem; display: block; margin-bottom: 14px;
  color: var(--ocp-text-dim);
}
.ocp-empty-actionable h3 {
  font-size: 1.1rem; font-weight: 700; color: var(--ocp-text-secondary); margin-bottom: 6px;
}
.ocp-empty-actionable p {
  font-size: 0.88rem; color: var(--ocp-text-muted); margin-bottom: 16px; max-width: 320px; margin-left: auto; margin-right: auto;
}
.ocp-empty-actionable .ocp-empty-actions {
  display: flex; gap: 8px; justify-content: center; flex-wrap: wrap;
}

/* ── Zero-state hero count (when kpi shows 0) ─── */
.ocp-zero-state .ocp-stat-value { font-size: 1.4rem; opacity: 0.4; }
.ocp-zero-state .ocp-stat-label { opacity: 0.5; }

/* ── Tab badge count (replaces inline Tailwind) ─── */
.ocp-badge-tab-count {
  display: inline-block; margin-left: 0.375rem;
  font-size: 0.75rem; padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
  background: var(--ocp-accent-subtle);
  color: var(--ocp-accent);
  line-height: 1.2;
}

/* ── Compact stat variant (for KPI row) ─── */
.ocp-stat--compact { padding: 14px 16px; }
.ocp-stat-value--sm { font-size: 1.5rem !important; }
.ocp-stat-change--sm { font-size: 0.72rem !important; }
.ocp-stat--danger-border { border-color: rgba(251,44,54,0.2) !important; }

/* ── Sidebar Collapsible Sections ──────────── */
.ocp-sidebar-collapsible {
  margin-bottom: 2px;
}

.ocp-sidebar-section {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  border: 0;
  background: transparent;
  font-family: inherit;
  line-height: 1.2;
  text-align: left;
  cursor: pointer;
  user-select: none;
  padding: 8px 14px 6px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ocp-text-dim);
  transition: color 0.12s;
}
.ocp-sidebar-section:hover,
.ocp-sidebar-section:focus-visible {
  color: var(--ocp-text-secondary);
}
.ocp-sidebar-section:focus-visible {
  outline: 1px solid var(--ocp-accent-border);
  outline-offset: -1px;
  border-radius: var(--ocp-radius-sm);
}

.section-chevron {
  font-size: 8px;
  transition: transform 0.2s ease;
  opacity: 0.5;
}
.ocp-sidebar-section.collapsed .section-chevron {
  transform: rotate(-90deg);
}

.ocp-sidebar-subitems {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-height: 500px;
  transition: max-height 0.25s ease, opacity 0.2s ease;
  opacity: 1;
}
.ocp-sidebar-subitems.collapsed {
  display: none;
  max-height: 0;
  opacity: 0;
  pointer-events: none;
}

/* ═══════════════════════════════════════════
   Approval Queue — Command Center Tab
   ═══════════════════════════════════════════ */

/* Pending count badge */
.pending-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: rgba(255, 172, 2, 0.12);
  color: var(--ocp-accent);
  border: 1px solid rgba(255, 172, 2, 0.25);
}

/* Approval cards */
.approval-card {
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg, 16px);
  background: var(--ocp-bg-card);
  transition: border-color 0.15s ease, opacity 0.3s ease;
}
.approval-card:hover {
  border-color: var(--ocp-accent-border);
}

.approval-card-inner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
}

.approval-card-main {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

.approval-checkbox-wrap {
  display: flex;
  align-items: center;
  padding-top: 4px;
  flex-shrink: 0;
}
.approval-checkbox-wrap input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--ocp-accent);
  cursor: pointer;
  border-radius: 4px;
}

.approval-card-body {
  flex: 1;
  min-width: 0;
}

.approval-card-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.approval-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ocp-text-primary);
  line-height: 1.3;
  margin: 0 0 4px;
  word-break: break-word;
}

.approval-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}

.meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  color: var(--ocp-text-muted);
  background: var(--ocp-bg-elevated);
  border: 1px solid var(--ocp-border);
}

.approval-card-expiry {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--ocp-text-dim);
  margin-top: 2px;
}

.approval-card-actions {
  display: flex;
  flex-shrink: 0;
  gap: 6px;
  align-items: center;
}

.approval-card-footer {
  padding: 8px 16px;
  border-top: 1px solid var(--ocp-border);
}

/* Badges */
.vertical-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.05em;
  background: var(--ocp-bg-elevated);
  color: var(--ocp-text-muted);
  border: 1px solid var(--ocp-border);
}
.vertical-badge--data_center { background: rgba(59, 130, 246, 0.12); color: #60a5fa; border-color: rgba(59, 130, 246, 0.25); }
.vertical-badge--multifamily { background: rgba(16, 185, 129, 0.12); color: #34d399; border-color: rgba(16, 185, 129, 0.25); }
.vertical-badge--financing { background: rgba(245, 158, 11, 0.12); color: #fbbf24; border-color: rgba(245, 158, 11, 0.25); }
.vertical-badge--gold { background: rgba(234, 179, 8, 0.12); color: #fde047; border-color: rgba(234, 179, 8, 0.25); }
.vertical-badge--self_storage { background: rgba(139, 92, 246, 0.12); color: #a78bfa; border-color: rgba(139, 92, 246, 0.25); }
.vertical-badge--land { background: rgba(34, 197, 94, 0.12); color: #4ade80; border-color: rgba(34, 197, 94, 0.25); }
.vertical-badge--pre_ipo { background: rgba(236, 72, 153, 0.12); color: #f472b6; border-color: rgba(236, 72, 153, 0.25); }
.vertical-badge--rental { background: rgba(251, 146, 60, 0.12); color: #fb923c; border-color: rgba(251, 146, 60, 0.25); }
.vertical-badge--unknown { background: rgba(100, 116, 139, 0.12); color: #94a3b8; border-color: rgba(100, 116, 139, 0.25); }

.tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.tier-badge--gate_required {
  background: rgba(239, 68, 68, 0.10);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.20);
}
.tier-badge--gate_notification {
  background: rgba(234, 179, 8, 0.10);
  color: #fbbf24;
  border: 1px solid rgba(234, 179, 8, 0.20);
}
.tier-badge--auto_execute {
  background: rgba(34, 197, 94, 0.10);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.20);
}

.priority-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.priority-badge--critical {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.30);
}
.priority-badge--high {
  background: rgba(249, 115, 22, 0.12);
  color: #fb923c;
  border: 1px solid rgba(249, 115, 22, 0.25);
}
.priority-red {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.30);
}
.priority-yellow {
  background: rgba(245, 158, 11, 0.14);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.28);
}
.priority-blue {
  background: rgba(59, 130, 246, 0.13);
  color: #93c5fd;
  border: 1px solid rgba(59, 130, 246, 0.25);
}
.priority-green {
  background: rgba(34, 197, 94, 0.12);
  color: #86efac;
  border: 1px solid rgba(34, 197, 94, 0.24);
}

.action-type-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
  color: var(--ocp-text-muted);
  background: var(--ocp-bg-elevated);
  border: 1px solid var(--ocp-border);
}

.score-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  color: var(--ocp-accent);
  background: var(--ocp-accent-subtle);
  border: 1px solid var(--ocp-accent-border);
}

/* ══════════════════════════════════════
   PLATFORM DISCOVERY CARD SYSTEM
   ══════════════════════════════════════ */

.platform-card {
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg);
  background: var(--ocp-bg-card);
  overflow: hidden;
  transition: border-color 0.15s;
}
.platform-card:hover { border-color: var(--ocp-accent-border); }

.platform-card-inner {
  display: flex; gap: 0;
}

.platform-card-body {
  flex: 1; min-width: 0;
  padding: 16px;
}

/* ── Header: title + url + badges ── */
.platform-card-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; margin-bottom: 10px;
}
.platform-card-title-group { flex: 1; min-width: 0; }
.platform-card-title {
  font-size: 1rem; font-weight: 700; color: var(--ocp-text-primary);
  margin: 0; line-height: 1.3;
}
.platform-card-url {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 0.72rem; color: var(--ocp-text-dim);
  text-decoration: none; transition: color 0.12s;
  margin-top: 3px;
}
.platform-card-url:hover { color: var(--ocp-accent); }

.platform-card-badges {
  display: flex; flex-wrap: wrap; gap: 4px;
  align-items: center; flex-shrink: 0;
}

/* ── Type badge ── */
.platform-type-badge {
  display: inline-flex; align-items: center;
  padding: 2px 8px; border-radius: var(--ocp-radius-full);
  font-size: 0.62rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--ocp-accent-subtle); color: var(--ocp-accent);
  border: 1px solid var(--ocp-accent-border);
}

/* ── Status badge ── */
.platform-status-badge {
  display: inline-flex; align-items: center;
  padding: 1px 7px; border-radius: 4px;
  font-size: 0.62rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em;
}
.platform-status-badge--discovered { background: rgba(6,182,212,0.12); color: #22d3ee; border: 1px solid rgba(6,182,212,0.25); }
.platform-status-badge--evaluating  { background: rgba(245,158,11,0.12); color: #fbbf24; border: 1px solid rgba(245,158,11,0.25); }
.platform-status-badge--active     { background: rgba(34,197,94,0.12);  color: #4ade80; border: 1px solid rgba(34,197,94,0.25); }
.platform-status-badge--rejected   { background: rgba(239,68,68,0.12);  color: #f87171; border: 1px solid rgba(239,68,68,0.25); }
.platform-status-badge--dead       { background: rgba(100,116,139,0.12); color: #94a3b8; border: 1px solid rgba(100,116,139,0.25); }
.platform-status-badge--watchlist  { background: rgba(139,92,246,0.12);  color: #a78bfa; border: 1px solid rgba(139,92,246,0.25); }

/* ── Description ── */
.platform-card-desc {
  font-size: 0.82rem; color: var(--ocp-text-secondary);
  line-height: 1.5; margin: 0 0 14px;
}

/* ── Metrics row: score gauge + bars + metadata ── */
.platform-card-metrics {
  display: flex; gap: 16px; align-items: flex-start;
  flex-wrap: wrap;
}

/* Score gauge */
.platform-score-section {
  display: flex; flex-direction: column; align-items: center;
  gap: 4px; min-width: 72px;
}
.platform-score-label {
  font-size: 0.6rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--ocp-text-dim);
}
.platform-score-gauge {
  position: relative; display: flex; align-items: center; justify-content: center;
}
.platform-score-ring { display: block; }
.platform-score-arc { transition: stroke-dasharray 0.6s ease; }
.platform-score-value {
  position: absolute; font-size: 0.95rem; font-weight: 800;
  font-family: var(--ocp-font-serif);
}
.score-green  { color: var(--ocp-success); }
.score-yellow { color: var(--ocp-warning); }
.score-red    { color: var(--ocp-danger); }

/* Metric bars */
.platform-metric-bars {
  flex: 1; min-width: 200px;
  display: flex; flex-direction: column; gap: 4px;
}
.platform-metric-row {
  display: flex; align-items: center; gap: 8px;
}
.platform-metric-label {
  width: 85px; font-size: 0.65rem; color: var(--ocp-text-dim);
  text-align: right; flex-shrink: 0;
}
.platform-metric-bar-track {
  flex: 1; height: 5px; background: var(--ocp-bg-elevated);
  border-radius: 3px; overflow: hidden;
}
.platform-metric-bar-fill {
  height: 100%; border-radius: 3px;
  min-width: 3px; transition: width 0.5s ease;
}
.platform-metric-val {
  width: 28px; font-size: 0.62rem; font-weight: 700;
  color: var(--ocp-text-muted); text-align: left; flex-shrink: 0;
}

/* Metadata chips row */
.platform-card-metadata {
  display: flex; flex-wrap: wrap; gap: 4px;
  margin-top: 12px;
  min-width: 100%;
}

/* Actions column */
.platform-card-actions {
  display: flex; flex-direction: column; gap: 6px;
  padding: 16px 16px 16px 0;
  border-left: 1px solid var(--ocp-border-light);
  min-width: 120px;
  align-items: stretch;
}
.platform-card-actions form { display: block; }
.platform-card-actions .ocp-btn { width: 100%; justify-content: center; }

/* Footer */
.platform-card-footer {
  padding: 8px 16px;
  border-top: 1px solid var(--ocp-border-light);
  background: var(--ocp-bg-surface);
}

/* ── Deal samples panel ── */
.platform-card-samples {
  border-top: 1px solid var(--ocp-border);
  background: var(--ocp-bg-surface);
}
.platform-card-samples-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px 6px;
}
.platform-card-samples-list {
  padding: 0 16px 12px;
  display: flex; flex-direction: column; gap: 6px;
}
.platform-sample-item {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; padding: 6px 10px;
  border-radius: var(--ocp-radius-sm);
  background: var(--ocp-bg-elevated);
  border: 1px solid var(--ocp-border-light);
}
.platform-sample-title {
  font-size: 0.78rem; color: var(--ocp-text-primary);
  font-weight: 500; flex: 1; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.platform-sample-meta {
  display: flex; align-items: center; gap: 6px; flex-shrink: 0;
}

/* Filter pills */
.filter-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  color: var(--ocp-text-muted);
  border: 1px solid var(--ocp-border);
  transition: all 0.12s ease;
  white-space: nowrap;
}
.filter-pill:hover {
  border-color: var(--ocp-accent-border);
  color: var(--ocp-text-primary);
}
.filter-pill.active {
  background: var(--ocp-accent-subtle);
  color: var(--ocp-accent);
  border-color: var(--ocp-accent-border);
}

/* Batch actions bar */
#batch-actions-bar {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: var(--ocp-radius-lg, 16px);
  background: rgba(255, 172, 2, 0.06);
  border: 1px solid var(--ocp-accent-border);
}

/* Empty state override */
.ocp-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 32px 16px;
  font-size: 13px;
  color: var(--ocp-text-muted);
  text-align: center;
}
.ocp-empty i {
  font-size: 24px;
  opacity: 0.4;
}

/* Responsive card actions */
@media (max-width: 768px) {
  .approval-card-inner {
    flex-direction: column;
  }
  .approval-card-actions {
    width: 100%;
    justify-content: flex-end;
    padding-top: 8px;
    border-top: 1px solid var(--ocp-border);
  }
}

/* ═══════════════════════════════════════════
   UI/UX Polish Additions — May 2026
   ═══════════════════════════════════════════ */

/* ── Skip-to-Content (Accessibility) ─────── */
.ocp-skip-link {
  position: fixed; top: 0; left: 0; z-index: 10000;
  padding: 10px 20px; background: var(--ocp-accent); color: #000;
  font-weight: 700; font-size: 0.85rem; text-decoration: none;
  border-radius: 0 0 var(--ocp-radius-md) 0;
  transform: translateY(-120%); transition: transform 0.2s ease;
}
.ocp-skip-link:focus {
  transform: translateY(0);
  outline: 3px solid var(--ocp-accent); outline-offset: 2px;
}

/* ── Focus-Visible Styles ────────────────── */
:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: 2px;
  border-radius: 2px;
}
.ocp-input:focus-visible,
.ocp-textarea:focus-visible,
.ocp-select:focus-visible {
  outline: none;
  border-color: var(--ocp-accent);
  box-shadow: 0 0 0 3px var(--ocp-accent-glow);
}
.ocp-btn:focus-visible,
.summary-btn:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: 2px;
}
.ocp-snav-item:focus-visible,
.ocp-snav-sub-item:focus-visible {
  outline: 2px solid var(--ocp-accent);
  outline-offset: -2px;
  border-radius: var(--ocp-radius-md);
}

/* ── Tooltip ─────────────────────────────── */
.ocp-tooltip {
  position: relative;
}
.ocp-tooltip::after {
  content: attr(data-tooltip);
  position: absolute; bottom: calc(100% + 6px); left: 50%;
  transform: translateX(-50%);
  padding: 5px 10px; border-radius: var(--ocp-radius-sm);
  background: var(--ocp-bg-elevated); color: var(--ocp-text-primary);
  border: 1px solid var(--ocp-border);
  font-size: 0.7rem; font-weight: 500; white-space: nowrap;
  pointer-events: none; opacity: 0;
  transition: opacity 0.15s ease;
  z-index: 1100;
}
.ocp-tooltip:hover::after,
.ocp-tooltip:focus-visible::after {
  opacity: 1;
}
.ocp-tooltip--bottom::after {
  bottom: auto; top: calc(100% + 6px);
}
.ocp-tooltip--left::after {
  bottom: auto; top: 50%; left: auto; right: calc(100% + 6px);
  transform: translateY(-50%);
}

/* ── Dropdown Menu ───────────────────────── */
.ocp-dropdown {
  position: relative; display: inline-block;
}
.ocp-dropdown-menu {
  position: absolute; top: calc(100% + 4px); right: 0; min-width: 180px;
  background: var(--ocp-bg-elevated); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg); box-shadow: var(--ocp-shadow-lg);
  padding: 4px; z-index: 1100;
  opacity: 0; transform: translateY(-4px); pointer-events: none;
  transition: all 0.15s ease;
}
.ocp-dropdown-menu.open {
  opacity: 1; transform: translateY(0); pointer-events: auto;
}
.ocp-dropdown-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: var(--ocp-radius-sm);
  font-size: 0.82rem; color: var(--ocp-text-secondary);
  text-decoration: none; cursor: pointer;
  transition: all 0.1s ease;
}
.ocp-dropdown-item:hover {
  background: var(--ocp-accent-subtle); color: var(--ocp-accent);
}
.ocp-dropdown-item--danger { color: var(--ocp-danger); }
.ocp-dropdown-item--danger:hover { background: var(--ocp-danger-subtle); }
.ocp-dropdown-divider {
  height: 1px; background: var(--ocp-border-light); margin: 4px 0;
}

/* ── Breadcrumb ──────────────────────────── */
.ocp-breadcrumb {
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px;
  font-size: 0.78rem; color: var(--ocp-text-muted);
}
.ocp-breadcrumb a {
  color: var(--ocp-text-muted); text-decoration: none;
  transition: color 0.15s ease;
}
.ocp-breadcrumb a:hover { color: var(--ocp-accent); }
.ocp-breadcrumb .sep {
  color: var(--ocp-text-dim); margin: 0 2px;
  font-size: 0.65rem;
}
.ocp-breadcrumb .current {
  color: var(--ocp-text-primary); font-weight: 600;
}

/* ── Pagination ──────────────────────────── */
.ocp-pagination {
  display: flex; align-items: center; justify-content: center; gap: 4px;
  padding: 12px 0;
}
.ocp-pagination-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 32px; height: 32px; padding: 0 8px;
  border-radius: var(--ocp-radius-sm);
  border: 1px solid var(--ocp-border);
  background: var(--ocp-bg-card); color: var(--ocp-text-secondary);
  font-size: 0.78rem; font-weight: 500; cursor: pointer;
  text-decoration: none; transition: all 0.12s ease;
}
.ocp-pagination-btn:hover {
  border-color: var(--ocp-accent-border); color: var(--ocp-accent);
  background: var(--ocp-accent-subtle);
}
.ocp-pagination-btn.active {
  background: var(--ocp-accent); color: #000; border-color: var(--ocp-accent);
  font-weight: 700;
}
.ocp-pagination-btn:disabled,
.ocp-pagination-btn[aria-disabled="true"] {
  opacity: 0.3; cursor: not-allowed; pointer-events: none;
}
.ocp-pagination-info {
  font-size: 0.72rem; color: var(--ocp-text-muted);
  padding: 0 8px;
}

/* ── Progress Bar ────────────────────────── */
.ocp-progress {
  width: 100%; height: 6px; background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-full); overflow: hidden;
}
.ocp-progress--sm { height: 4px; }
.ocp-progress--lg { height: 10px; }
.ocp-progress-bar {
  height: 100%; border-radius: var(--ocp-radius-full);
  transition: width 0.4s ease;
  background: linear-gradient(90deg, var(--ocp-accent-bright), var(--ocp-accent-deep));
}
.ocp-progress-bar--success { background: linear-gradient(90deg, var(--ocp-success), #22c55e); }
.ocp-progress-bar--info { background: linear-gradient(90deg, var(--ocp-info), #3b82f6); }
.ocp-progress-bar--danger { background: linear-gradient(90deg, var(--ocp-danger), #ef4444); }
.ocp-progress-label {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.72rem; color: var(--ocp-text-muted); margin-bottom: 4px;
}
.ocp-progress-value {
  font-weight: 700; font-family: var(--ocp-font-mono);
  font-size: 0.7rem; color: var(--ocp-text-secondary);
}

/* ── Spinner ─────────────────────────────── */
.ocp-spinner {
  display: inline-block; width: 20px; height: 20px;
  border: 2px solid var(--ocp-border);
  border-top-color: var(--ocp-accent);
  border-radius: 50%;
  animation: ocpSpin 0.6s linear infinite;
}
.ocp-spinner--sm { width: 14px; height: 14px; border-width: 1.5px; }
.ocp-spinner--lg { width: 32px; height: 32px; border-width: 3px; }
.ocp-spinner--white { border-color: rgba(255,255,255,0.2); border-top-color: #fff; }
@keyframes ocpSpin { to { transform: rotate(360deg); } }

/* ── Shimmer Animation ───────────────────── */
@keyframes ocpShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
.ocp-shimmer {
  background: linear-gradient(90deg,
    var(--ocp-bg-card) 0%,
    var(--ocp-bg-card-hover) 40%,
    var(--ocp-bg-card) 80%
  );
  background-size: 200% 100%;
  animation: ocpShimmer 1.5s ease infinite;
  border-radius: var(--ocp-radius-sm);
}
.ocp-skeleton { height: 16px; }
.ocp-skeleton-line { height: 12px; margin-bottom: 8px; }
.ocp-skeleton-stat { height: 28px; width: 60%; margin-bottom: 12px; }
.ocp-skeleton-circle { width: 40px; height: 40px; border-radius: 50%; }

/* ── Divider ─────────────────────────────── */
.ocp-divider {
  border: none; border-top: 1px solid var(--ocp-border);
  margin: 16px 0;
}
.ocp-divider--light { border-color: var(--ocp-border-light); }
.ocp-divider--accent { border-color: var(--ocp-accent-border); }
.ocp-divider--dashed { border-style: dashed; }
.ocp-divider-label {
  display: flex; align-items: center; gap: 10px;
  color: var(--ocp-text-dim); font-size: 0.65rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em;
  margin: 16px 0;
}
.ocp-divider-label::before,
.ocp-divider-label::after {
  content: ''; flex: 1; height: 1px;
  background: var(--ocp-border-light);
}

/* ── Accordion ───────────────────────────── */
.ocp-accordion {
  border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg); overflow: hidden;
}
.ocp-accordion-item {
  border-bottom: 1px solid var(--ocp-border-light);
}
.ocp-accordion-item:last-child { border-bottom: none; }
.ocp-accordion-trigger {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  width: 100%; padding: 14px 16px;
  background: var(--ocp-bg-card); border: none; cursor: pointer;
  color: var(--ocp-text-primary); font-size: 0.88rem; font-weight: 600;
  font-family: inherit; text-align: left;
  transition: background 0.12s ease;
}
.ocp-accordion-trigger:hover { background: var(--ocp-bg-card-hover); }
.ocp-accordion-trigger i {
  font-size: 0.75rem; color: var(--ocp-text-dim);
  transition: transform 0.2s ease;
}
.ocp-accordion-trigger[aria-expanded="true"] i {
  transform: rotate(180deg);
}
.ocp-accordion-panel {
  padding: 0 16px 16px; color: var(--ocp-text-secondary);
  font-size: 0.85rem; line-height: 1.6;
}
.ocp-accordion-panel[hidden] { display: none; }

/* ── Print Styles ────────────────────────── */
@media print {
  .ocp-sidebar,
  .ocp-fab,
  .ocp-fab-menu,
  .ocp-bot-btn,
  .ocp-noise,
  .ocp-orb,
  #ocp-loading-bar,
  #cmd-palette-overlay,
  #side-sheet-overlay,
  #side-sheet,
  #shortcuts-toast,
  #inbox-badge,
  .ocp-notif-badge { display: none !important; }

  .ocp-main {
    margin-left: 0 !important; padding: 0 !important;
    max-width: none !important;
  }
  body {
    background: #fff !important; color: #000 !important;
    font-size: 12pt; line-height: 1.5;
  }
  .ocp-card, .ocp-panel, .ocp-glass {
    background: #fff !important; border: 1px solid #ccc !important;
    box-shadow: none !important; border-radius: 0 !important;
    page-break-inside: avoid;
  }
  .ocp-card *, .ocp-panel *, .ocp-glass * {
    color: #000 !important;
  }
  .ocp-table-wrap { border: 1px solid #ccc !important; }
  .ocp-table th, .ocp-table td {
    border-color: #ccc !important; color: #000 !important;
  }
  a { color: #0366d6 !important; text-decoration: underline; }
  h1, h2, h3 { page-break-after: avoid; }
  table { page-break-inside: avoid; }

  /* Show URLs after links */
  a[href^="http"]::after {
    content: " (" attr(href) ")"; font-size: 0.8em;
    color: #666 !important;
  }
  a[href^="/"]::after {
    content: " (https://crm.orlandocap.com" attr(href) ")";
    font-size: 0.8em; color: #666 !important;
  }
}

/* ── Mobile Responsiveness ────────────────── */
@media (max-width: 1024px) {
  .ocp-main {
    margin-left: 200px !important; padding: 18px 20px 32px;
  }
  .ocp-sidebar {
    width: 200px;
  }
  .ocp-sidebar-header { padding: 14px 12px 10px; }
  .ocp-sidebar-header .ocp-logo-text { display: none; }
  .ocp-snav-item { font-size: 0.78rem; padding: 8px 10px; }
  .ocp-snav-item span { display: none; }
  .ocp-snav-sub-item span { display: none; }
  .ocp-sidebar-section { font-size: 0.5rem; padding: 12px 8px 4px; }
  .ocp-sidebar-bottom { padding: 8px; }
  .ocp-sidebar-search form { display: none; }
  .ocp-sidebar-search i { left: 8px; }
  .ocp-sidebar-search input { padding: 0 8px 0 28px; }
  .ocp-sidebar-profile .meta { display: none; }
  .ocp-table th.hidden-md,
  .ocp-table td.hidden-md { display: none; }
}

@media (max-width: 768px) {
  :root { --ocp-sidebar-w: 60px; }
  .ocp-main {
    margin-left: 60px !important; padding: 14px 12px 28px;
  }
  .ocp-sidebar {
    width: 60px;
  }
  .ocp-sidebar-header { justify-content: center; padding: 12px 0 8px; }
  .ocp-sidebar-header .ocp-logo-text { display: none; }
  .ocp-sidebar-header .ocp-logo-icon { width: 28px; height: 28px; font-size: 0.85rem; }
  .ocp-snav-item {
    justify-content: center; padding: 10px 0;
    border-left: none !important;
  }
  .ocp-snav-item span,
  .ocp-snav-item.active { border-left: none; justify-content: center; }
  .ocp-snav-item i { margin: 0; }
  .ocp-sidebar-collapsible,
  .ocp-sidebar-bottom { display: none; }
  .ocp-table-wrap { border-radius: var(--ocp-radius-md); }
  .ocp-table { font-size: 0.78rem; }
  .ocp-table th, .ocp-table td { padding: 8px 10px; }
  .ocp-stat { padding: 14px; }
  .ocp-stat-value { font-size: 1.4rem; }
  #ocp-fab { bottom: 16px; right: 16px; width: 44px; height: 44px; }
}

@media (max-width: 480px) {
  .ocp-main { padding: 10px 8px 24px; }
  .ocp-table th.hidden-sm,
  .ocp-table td.hidden-sm { display: none; }
  .ocp-stat-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ═══════════════════════════════════════════════════════════════════
   Boardroom Component System (br-*)
   ═══════════════════════════════════════════════════════════════════ */
.br-header-card {
  background: radial-gradient(circle at 20% 10%, rgba(255,172,2,0.08), transparent 40%);
}
.br-chat-panel {
  background: linear-gradient(180deg, rgba(3,26,26,0.96), rgba(6,40,42,0.96));
  border-radius: 28px; border: 1px solid var(--ocp-border);
  box-shadow: inset 0 1px 0 rgba(255,230,203,0.04), var(--ocp-shadow-lg);
}
.br-message-row { display: flex; width: 100%; align-items: flex-end; gap: 8px; }
.br-message-row.user { justify-content: flex-end; }
.br-message-row.agent { justify-content: flex-start; }
.br-bubble-wrap { max-width: min(76%, 760px); }
.br-bubble {
  display: inline-block; max-width: 100%;
  border-radius: 20px; padding: 10px 14px;
  font-size: 0.92rem; line-height: 1.4;
  white-space: pre-wrap; word-break: break-word;
  border: 1px solid rgba(255,230,203,0.06);
}
.br-message-row.user .br-bubble {
  color: #1A0F00; background: linear-gradient(180deg, #FFAC02, #cc8800);
  border-bottom-right-radius: 4px; border-color: transparent;
  box-shadow: 0 8px 20px rgba(255,172,2,0.20);
}
.br-message-row.agent .br-bubble {
  color: var(--ocp-text-primary);
  background: linear-gradient(180deg, var(--ocp-bg-card), var(--ocp-bg-surface));
  border-bottom-left-radius: 4px;
}
.br-message-row.system .br-bubble {
  background: rgba(255,172,2,0.08);
  border-color: rgba(255,172,2,0.18);
}
.br-meta { margin: 0 6px 4px; font-size: 0.65rem; line-height: 1; color: var(--ocp-text-muted); }
.br-message-row.user .br-meta { text-align: right; }
.br-typing-bubble span.br-dot {
  display: inline-block; width: 7px; height: 7px; border-radius: 999px;
  background: var(--ocp-text-muted); margin-right: 3px;
  animation: brTyping 1.1s infinite ease-in-out;
}
.br-typing-bubble span.br-dot:nth-child(2) { animation-delay: 0.15s; }
.br-typing-bubble span.br-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes brTyping { 0%,80%,100%{opacity:.35;transform:translateY(0)} 40%{opacity:1;transform:translateY(-3px)} }
.br-stat-cell {
  background: var(--ocp-bg-surface); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-lg); padding: 12px; text-align: center;
}
.br-stat-cell .br-stat-value { font-size: 1.3rem; font-weight: 800; font-family: var(--ocp-font-serif); }
.br-stat-cell .br-stat-label { font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ocp-text-muted); font-weight: 700; margin-top: 2px; }
.br-section-title { font-size: 1.1rem; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.br-textarea {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-lg); color: var(--ocp-text-primary);
  font-size: 0.88rem; outline: none; transition: all 0.2s;
  font-family: inherit; resize: vertical;
}
.br-textarea:focus { border-color: var(--ocp-accent); box-shadow: 0 0 0 3px var(--ocp-accent-glow); }
.br-select {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-md); color: var(--ocp-text-primary);
  font-size: 0.85rem; outline: none; cursor: pointer; font-family: inherit;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='rgba(255,230,203,0.48)' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.br-input {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-surface);
  border-radius: var(--ocp-radius-md); color: var(--ocp-text-primary); font-size: 0.88rem; outline: none; transition: all 0.2s; font-family: inherit;
}
.br-input:focus { border-color: var(--ocp-accent); box-shadow: 0 0 0 3px var(--ocp-accent-glow); }
.br-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px;
  border-radius: var(--ocp-radius-md); font-size: 0.84rem; font-weight: 600;
  text-decoration: none; cursor: pointer; transition: all 0.15s; font-family: inherit; line-height: 1;
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-card); color: var(--ocp-text-secondary);
}
.br-btn:hover { border-color: var(--ocp-accent-border); color: var(--ocp-accent); }
.br-btn--primary {
  background: var(--ocp-gradient-gold); color: #1A0F00;
  border-color: transparent; font-weight: 700;
}
.br-btn--primary:hover { opacity: 0.9; box-shadow: var(--ocp-shadow-glow); }
.br-btn--sm { padding: 5px 10px; font-size: 0.78rem; border-radius: var(--ocp-radius-sm); }
.br-thought { border-radius: var(--ocp-radius-lg); padding: 12px; }
.br-thought--crosstalk { border: 1px solid rgba(255,172,2,0.20); background: rgba(255,172,2,0.04); }
.br-thought--activity { border: 1px solid rgba(143,255,137,0.15); background: rgba(143,255,137,0.04); }
.br-empty { text-align: center; padding: 24px 16px; border: 1px dashed var(--ocp-border); border-radius: var(--ocp-radius-xl); color: var(--ocp-text-muted); font-size: 0.88rem; background: var(--ocp-bg-surface); }
.br-section-card {
  background: var(--ocp-bg-card); border: 1px solid var(--ocp-border);
  border-radius: var(--ocp-radius-xl); padding: 20px; box-shadow: var(--ocp-shadow-sm);
}
.br-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--ocp-border); overflow-x: auto; margin-bottom: 24px; }
.br-tab {
  padding: 10px 18px; font-size: 0.85rem; font-weight: 600;
  color: var(--ocp-text-muted); border-bottom: 2px solid transparent;
  cursor: pointer; transition: all 0.15s; white-space: nowrap;
  background: transparent; border-top: none; border-left: none; border-right: none; font-family: inherit;
}
.br-tab:hover { color: var(--ocp-text-primary); }
.br-tab.active { color: var(--ocp-accent); border-bottom-color: var(--ocp-accent); }
.br-card-item {
  border-radius: var(--ocp-radius-lg); border: 1px solid var(--ocp-border);
  background: var(--ocp-bg-surface); padding: 14px;
  transition: all 0.15s ease;
}
.br-card-item:hover { border-color: var(--ocp-accent-border); }

/* ── Follow-Up Obligation Modal ── */
.obligation-modal-backdrop {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.7); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  animation: fuFadeIn 0.15s ease;
  padding: 20px;
}
.obligation-modal-card {
  background: var(--ocp-bg-surface, #0f172a);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  max-width: 580px; width: 100%; max-height: 85vh;
  overflow-y: auto;
  position: relative;
  animation: fuModalSlideIn 0.2s ease;
  box-shadow: 0 25px 60px rgba(0,0,0,0.5);
}
.obligation-modal-close {
  position: absolute; top: 12px; right: 12px;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  color: var(--ocp-text-dim); width: 32px; height: 32px; border-radius: 8px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  font-size: 14px; transition: all 0.15s; z-index: 10;
}
.obligation-modal-close:hover { background: rgba(255,255,255,0.1); color: #fff; }
.obligation-modal-header { padding: 24px 24px 16px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.obligation-modal-body { padding: 20px 24px 24px; }
@keyframes fuFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fuModalSlideIn { from { opacity: 0; transform: translateY(20px) scale(0.97); } to { opacity: 1; transform: translateY(0) scale(1); } }

/* ── Obligation Card Component ── */
.obligation-card {
  transition: all 0.15s ease;
}
.obligation-card:active {
  transform: scale(0.985);
}

/* ── Global performance & accessibility optimizations (2026-05-29) ── */
:root { color-scheme: dark; }

@supports (content-visibility: auto) {
  .ocp-card,
  .ocp-panel,
  .approval-section,
  .br-section-card,
  .br-card-item,
  .obligation-card {
    content-visibility: auto;
    contain-intrinsic-size: auto 260px;
  }
  .hero-command,
  .ocp-sidebar,
  .ocp-side-sheet,
  .ocp-side-sheet-overlay,
  #cmd-palette-overlay,
  #cmd-palette,
  .ocp-fab,
  .ocp-fab-menu,
  .ocp-bot-btn,
  .ocp-loading-bar {
    content-visibility: visible;
  }
}

button,
[role="button"],
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--ocp-accent, #ffac02);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}

/* ══ 20260706b: Battle quick actions, stale heat, micro-motion, density ══ */

/* ── Battle Plan quick actions ── */
.battle-item { align-items: start; }
.battle-link { display: block; text-decoration: none; color: inherit; }
.battle-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.battle-qa {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.02em;
  padding: 4px 10px; border-radius: var(--ocp-radius-full);
  border: 1px solid var(--ocp-border); background: var(--ocp-bg-card);
  color: var(--ocp-text-secondary); cursor: pointer;
  transition: color .15s ease, border-color .15s ease, transform .15s ease;
}
.battle-qa:hover { color: var(--ocp-accent); border-color: var(--ocp-accent-border); transform: translateY(-1px); }
.battle-qa:active { transform: translateY(0); }
.battle-qa.htmx-request { opacity: .45; pointer-events: none; }
.battle-flash {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 10px;
  padding: 6px 12px; border-radius: var(--ocp-radius-full);
  font-size: 0.78rem; font-weight: 700;
  color: var(--ocp-success); background: rgba(34, 197, 94, 0.10);
  border: 1px solid rgba(34, 197, 94, 0.25);
  animation: ocp-flash-in .25s ease both;
}
@keyframes ocp-flash-in { from { opacity: 0; transform: translateY(-4px); } }

/* ── Stale-deal heat: glow scales with days untouched ── */
.battle-heat-label { color: var(--ocp-danger); }
.battle-item.heat-1 { border-left: 3px solid rgba(251, 191, 36, 0.55); }
.battle-item.heat-2 { border-left: 3px solid rgba(248, 113, 113, 0.65); box-shadow: inset 0 0 24px rgba(127, 29, 29, 0.12); }
.battle-item.heat-3 { border-left: 3px solid rgba(239, 68, 68, 0.90); box-shadow: inset 0 0 32px rgba(127, 29, 29, 0.22), 0 0 12px rgba(239, 68, 68, 0.15); }
.staleness-warn { box-shadow: inset 0 0 18px rgba(113, 63, 18, 0.12); }
.staleness-stale { box-shadow: inset 0 0 26px rgba(127, 29, 29, 0.18), 0 0 10px rgba(239, 68, 68, 0.10); }

/* ── View transitions + micro-motion ── */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: ocp-vt-out .12s ease both; }
::view-transition-new(root) { animation: ocp-vt-in .18s ease both; }
@keyframes ocp-vt-out { to { opacity: 0; } }
@keyframes ocp-vt-in { from { opacity: 0; transform: translateY(4px); } }
.battle-item:hover, .pipeline-deal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}
.battle-item.heat-2:hover { box-shadow: inset 0 0 24px rgba(127, 29, 29, 0.12), 0 6px 18px rgba(0, 0, 0, 0.28); }
.battle-item.heat-3:hover { box-shadow: inset 0 0 32px rgba(127, 29, 29, 0.22), 0 6px 18px rgba(239, 68, 68, 0.18); }

/* ── Density pass: tighter chrome, more deals per screen ── */
.ocp-card-pad { padding: 16px 18px; }
.ocp-stat--compact { padding: 10px 14px; }
.battle-item { padding: 10px 12px; }

@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
  .battle-item:hover, .pipeline-deal-card:hover, .battle-qa:hover { transform: none; }
  .battle-flash { animation: none; }
}
