/* ═══════════════════════════════════════
   RESET & ROOT
═══════════════════════════════════════ */
:root {
  --navy:      #01243D;
  --navy-2:    #012952;
  --navy-3:    #0e3a6e;
  --navy-4:    #0a2d5a;
  --yellow:    #FFBB00;
  --yellow-d:  #cc9600;
  --yellow-m:  rgba(255,187,0,0.12);
  --yellow-b:  rgba(255,187,0,0.30);
  --green:     #37CA37;
  --green-m:   rgba(55,202,55,0.12);
  --green-b:   rgba(55,202,55,0.30);
  --blue:      #158AF6;
  --blue-m:    rgba(21,138,246,0.12);
  --blue-b:    rgba(21,138,246,0.25);
  --red-m:     rgba(220,50,50,0.12);
  --red-b:     rgba(220,50,50,0.30);
  --red:       rgba(255,90,90,0.9);
  --border:    rgba(255,255,255,0.08);
  --border2:   rgba(255,255,255,0.15);
  --w90:       rgba(255,255,255,0.90);
  --w70:       rgba(255,255,255,0.70);
  --w50:       rgba(255,255,255,0.50);
  --w30:       rgba(255,255,255,0.30);
  --w15:       rgba(255,255,255,0.06);
  --font:      'Poppins', sans-serif;
  --mono:      'JetBrains Mono', monospace;
  --sidebar-w: 248px;
  --topnav-h:  56px;

  /* ═══════════════════════════════════════
     JETPACK DESIGN SYSTEM — atmospheric tier
     ─────────────────────────────────────────
     Tokens for lighting, depth, motion, surfaces. Light source:
     directional, upper-left. See docs/DESIGN_SYSTEM.md for the
     full specification.
     ─────────────────────────────────────────
     These tokens are additive — they do not modify the legacy
     palette above. Existing surfaces remain on the old tokens
     until intentionally migrated.
  ═══════════════════════════════════════ */

  /* ── Accent colors (semantic) ─────────────────────────── */
  --accent-interactive:     #1F8CEF;      /* hover, active, focus, link */
  --accent-luminous:        #2EA0F8;      /* edge gradient starts, highlights */
  --accent-deep:            #1B5B8E;      /* gradient midpoint */
  --accent-architectural:   #C9962F;      /* restrained gold — reward/featured */

  /* ── Text ──────────────────────────────────────────────── */
  --text-primary:           #01243D;
  --text-secondary:         #5a7184;
  --text-tertiary:          #8fa3b8;

  /* ── Borders ───────────────────────────────────────────── */
  --border-quiet:           rgba(1, 36, 61, 0.07);
  --border-base:            rgba(1, 36, 61, 0.10);
  --border-strong:          rgba(1, 36, 61, 0.16);

  /* ── Surface gradients ─────────────────────────────────── */
  --surface-primary:        linear-gradient(180deg, #ffffff 0%, #fcfdff 100%);
  --surface-elevated:       linear-gradient(180deg, #ffffff 0%, #fafbfd 100%);
  --surface-canvas-base:    linear-gradient(180deg, #f5f5f7 0%, #e9eef5 100%);
  --surface-inverted:       linear-gradient(135deg, #01243D 0%, #1B3A6B 100%);
  --surface-secondary:      #ffffff;
  --surface-muted:          #f5f5f7;

  /* ── Lighting — directional gradient border ──────────── */
  /* Light at top-left (luminous), shadow at bottom-right (navy).
     Used for tactical edge tension on active elements. */
  --grad-edge-precision:    linear-gradient(135deg,
                              #2EA0F8 0%,
                              #1B5B8E 50%,
                              #01243D 100%);

  /* ── Shadow system ─────────────────────────────────────── */
  /* All shadows reference the upper-left light source. Positive
     x-offsets (drops fall bottom-right) preserve the light model. */

  /* Resting — always-on dimensional depth.
     5 layers: highlight + contact + mid + ambient + blue tint. */
  --shadow-resting:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 1px 1px -0.5px rgba(1, 36, 61, 0.06),
    1px 4px 8px -4px rgba(1, 36, 61, 0.08),
    0 14px 32px -16px rgba(1, 36, 61, 0.10),
    0 0 0 1px rgba(31, 140, 239, 0.02);

  /* Hover — cinematic 7-layer system. */
  --shadow-hover:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(1, 36, 61, 0.04),
    0 0 0 1px rgba(31, 140, 239, 0.30),
    0 2px 3px -1px rgba(1, 36, 61, 0.12),
    2px 12px 24px -12px rgba(1, 36, 61, 0.24),
    0 30px 60px -28px rgba(1, 36, 61, 0.22),
    0 0 20px -10px rgba(31, 140, 239, 0.20);

  /* Active — pressed/clicked. Tight, snap. */
  --shadow-active:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 0 0 1px rgba(31, 140, 239, 0.32),
    0 6px 14px -8px rgba(1, 36, 61, 0.22);

  /* Focus-visible — hover parity + stronger ring for a11y. */
  --shadow-focus:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(1, 36, 61, 0.04),
    0 0 0 2px rgba(31, 140, 239, 0.52),
    0 2px 3px -1px rgba(1, 36, 61, 0.12),
    2px 12px 24px -12px rgba(1, 36, 61, 0.24),
    0 30px 60px -28px rgba(1, 36, 61, 0.22),
    0 0 20px -10px rgba(31, 140, 239, 0.20);

  /* Dropdown / popover / menu — floating-but-anchored. */
  --shadow-dropdown:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 4px 8px -4px rgba(1, 36, 61, 0.16),
    0 16px 32px -16px rgba(1, 36, 61, 0.22),
    0 32px 64px -32px rgba(1, 36, 61, 0.18);

  /* Modal — heavier separation from canvas. */
  --shadow-modal:
    0 0 0 1px rgba(1, 36, 61, 0.06),
    0 8px 16px -8px rgba(1, 36, 61, 0.20),
    0 32px 64px -24px rgba(1, 36, 61, 0.32),
    0 64px 128px -48px rgba(1, 36, 61, 0.28);

  /* Backdrop — full-screen room dim behind modals.
     Apply as background-color on a fixed overlay element. */
  --shadow-overlay-bg:      rgba(1, 36, 61, 0.45);

  /* ── Motion — easing ──────────────────────────────────── */
  --ease-precision:         cubic-bezier(0.22, 1, 0.36, 1);    /* signature */
  --ease-snap:              cubic-bezier(0.4, 0, 0.6, 1);
  --ease-enter:             cubic-bezier(0.16, 1, 0.3, 1);
  --ease-exit:              cubic-bezier(0.7, 0, 0.84, 0);

  /* ── Motion — duration tiers ──────────────────────────── */
  --dur-instant:             80ms;     /* press snap-back */
  --dur-fast:               180ms;     /* micro-interactions */
  --dur-medium:             280ms;     /* transforms */
  --dur-slow:               380ms;     /* opacity, filter, recede */
  --dur-shadow:             420ms;     /* box-shadow lag (light catches up) */
  --dur-panel:              320ms;     /* panel slide-in */
  --dur-modal:              240ms;     /* modal fade */

  /* ── Motion — scale limits ────────────────────────────── */
  --scale-hover-card:       1.006;
  --scale-hover-button:     1.012;
  --scale-press:            0.998;
  --scale-recede:           0.995;

  /* ── Motion — translate limits ────────────────────────── */
  --lift-card:             -4px;
  --lift-button:           -2px;
  --lift-press:            -1px;
}
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html, body {
  width:100%; height:100%; overflow:hidden;
  font-family:var(--font);
  background:var(--navy);
  color:var(--w90);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BUTTON SYSTEM — three semantic tiers
   ─────────────────────────────────────────────────────────────────────────
   .jp-btn          — base (typography, sizing, motion)
   .jp-btn-primary  — Primary Operator: navy with subtle interior lighting.
                      The workhorse — confirm / save / send / submit.
   .jp-btn-premium  — Premium Action: celebratory gold (#FFDC86 → #E6A21C),
                      navy text. The earned-reward moment — broker
                      introductions, milestones. Used sparingly.
                      Per DESIGN_SYSTEM.md, gold is precious.
   .jp-btn-ghost    — Secondary: transparent, hairline border, calm utility.
                      Cancel / back / dismiss / quiet side actions.

   Size modifiers:  .jp-btn-sm (30px) · default (38px) · .jp-btn-lg (46px)

   All three follow Jetpack's upper-left light model: inner top-edge
   highlights, inner bottom-edge shadows, outer drop shadows that fall
   to the bottom-right. Hover lifts -1px; press settles +1px. No glow.

   References: Porsche dashboard switches, Stripe Checkout, Linear
   primary actions, Apple Pay. Never webinar-CTA gold or saturated
   startup-blue. Restraint wins.
   ═══════════════════════════════════════════════════════════════════════════ */

.jp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 38px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.005em;
  cursor: pointer;
  position: relative;
  user-select: none;
  white-space: nowrap;
  text-decoration: none;
  transition:
    transform     var(--dur-medium) var(--ease-precision),
    box-shadow    var(--dur-shadow) var(--ease-precision),
    background    var(--dur-fast)   var(--ease-precision),
    border-color  var(--dur-fast)   var(--ease-precision),
    color         var(--dur-fast)   var(--ease-precision);
}

.jp-btn:active:not(:disabled) {
  transform: translate3d(0, 1px, 0);
  transition-duration: var(--dur-fast);
}

.jp-btn:disabled,
.jp-btn[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

/* Size modifiers */
.jp-btn-sm { height: 30px; padding: 0 13px; font-size: 12px;   border-radius: 7px;  gap: 6px; }
.jp-btn-lg { height: 46px; padding: 0 24px; font-size: 13.5px; border-radius: 11px; gap: 9px; }

/* Icon-only variant — square, no padding */
.jp-btn-icon { padding: 0; width: 38px; }
.jp-btn-icon.jp-btn-sm { width: 30px; }
.jp-btn-icon.jp-btn-lg { width: 46px; }

/* ── TIER 1 — Primary Operator ────────────────────────────────────────
   Navy with a two-layer background: a subtle vertical light/dark wash
   over the deep navy gradient. Inset shadows give it a machined,
   physical-object quality. The workhorse. */
.jp-btn-primary {
  color: #041626;
  font-weight: 600;
  background: linear-gradient(
    135deg,
    #ffe89a 0%,
    #ffd35a 30%,
    #f4ad1f 60%,
    #d78500 100%
  );
  border: 0;
  outline: 0;
  box-shadow: none;
  background-clip: padding-box;
}
.jp-btn-primary::before,
.jp-btn-primary::after { content: none; display: none; }

.jp-btn-primary:hover:not(:disabled) {
  background: linear-gradient(
    135deg,
    #fff0b8 0%,
    #ffdc77 30%,
    #f7ba38 60%,
    #e89512 100%
  );
  transform: translate3d(0, -1px, 0);
}
.jp-btn-primary:focus-visible {
  outline: 3px solid rgba(4, 22, 38, 0.25);
  outline-offset: 2px;
  box-shadow: none;
}

/* ── TIER 2 — Premium Action ──────────────────────────────────────────
   Architectural gold (#C9962F family) with a warmer top stop and a
   deeper bottom stop. NAVY text — never white. Navy-on-gold is the
   single decision that separates premium from webinar-CTA. Used only
   for reward moments (broker introductions completing, etc.). */
.jp-btn-premium {
  color: #041626;
  font-weight: 600;
  background: linear-gradient(
    135deg,
    #ffe89a 0%,
    #ffd35a 30%,
    #f4ad1f 60%,
    #d78500 100%
  );
  border: 0;
  outline: 0;
  box-shadow: none;
  background-clip: padding-box;
}
.jp-btn-premium::before,
.jp-btn-premium::after { content: none; display: none; }

.jp-btn-premium:hover:not(:disabled) {
  background: linear-gradient(
    135deg,
    #fff0b8 0%,
    #ffdc77 30%,
    #f7ba38 60%,
    #e89512 100%
  );
  transform: translate3d(0, -1px, 0);
}
.jp-btn-premium:focus-visible {
  outline: 3px solid rgba(4, 22, 38, 0.25);
  outline-offset: 2px;
  box-shadow: none;
}

/* ── TIER 3 — Ghost / Secondary ───────────────────────────────────────
   Minimal weight. Transparent bg, hairline navy border, muted-navy
   text. Hover lights the border + a touch of bg tint. Calm utility. */
.jp-btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: rgba(1, 36, 61, 0.15);
}
.jp-btn-ghost:hover:not(:disabled) {
  background: rgba(1, 36, 61, 0.04);
  border-color: rgba(1, 36, 61, 0.28);
  color: var(--text-primary);
}
.jp-btn-ghost:focus-visible {
  outline: none;
  border-color: var(--accent-interactive);
  box-shadow: 0 0 0 3px rgba(31, 140, 239, 0.18);
}

/* Reduced motion — same treatment as the rest of the design system. */
@media (prefers-reduced-motion: reduce) {
  .jp-btn { transition: none; }
  .jp-btn:hover:not(:disabled),
  .jp-btn:active:not(:disabled) { transform: none; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   GLOBAL CLUSTER — Notifications · Help · What's new
   ─────────────────────────────────────────────────────────────────────────
   Lives inside #jp-topbar (transparent 48px bar at the top of #main).
   Hidden until auth boots; revealed by js/index-whats-new.js. Uses the
   Ghost button language adapted for floating context (translucent base,
   hairline border, soft backdrop blur).

   The panel dropdown is position:fixed at body level so it floats above
   any page chrome, with `top` aligned to drop just below the topbar.
   ═══════════════════════════════════════════════════════════════════════════ */

.jp-app-cluster {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.jp-cluster-btn {
  /* Locked contract: 22px icon in 26px box, navy #0c2340. */
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: transparent;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0c2340;
  cursor: pointer;
  font-family: var(--font);
  user-select: none;
  position: relative;
  padding: 0;
  transition:
    background    var(--dur-fast) var(--ease-precision),
    color         var(--dur-fast) var(--ease-precision);
}
.jp-cluster-btn:hover {
  background: rgba(12, 35, 64, 0.06);
  color: #0c2340;
}
.jp-cluster-btn:active { background: rgba(12, 35, 64, 0.10); }
.jp-cluster-btn.is-active {
  background: rgba(12, 35, 64, 0.10);
  color: #0c2340;
}
.jp-cluster-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(31, 140, 239, 0.22);
}

/* Unread dot on the Send/notifications icons — architectural gold (reward signal). */
.jp-cluster-dot {
  position: absolute;
  top: 1px;
  right: 1px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-architectural);
  border: 1.5px solid #fff;
  pointer-events: none;
  box-shadow: 0 0 0 1px rgba(201, 150, 47, 0.25);
}

/* Single panel slot — content swaps based on which icon is active.
   Position:fixed so it floats above page chrome regardless of scroll. */
.jp-cluster-panel {
  position: fixed;
  top: 56px;
  right: 24px;
  width: 380px;
  max-height: calc(100vh - 76px);
  background: #fff;
  border: 1px solid rgba(1, 36, 61, 0.08);
  border-radius: 14px;
  box-shadow:
    0 4px 18px -4px rgba(1, 36, 61, 0.12),
    0 16px 44px -12px rgba(1, 36, 61, 0.18);
  z-index: 101;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition:
    opacity   200ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.jp-cluster-panel.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.jp-cluster-panel-header {
  padding: 14px 20px;
  border-bottom: 1px solid rgba(1, 36, 61, 0.06);
  font-size: 13px;
  font-weight: 500;
  color: #01243D;
  letter-spacing: -0.005em;
  background: linear-gradient(180deg,
    rgba(1, 36, 61, 0.020) 0%,
    rgba(255, 255, 255, 0) 100%);
  flex-shrink: 0;
}
.jp-cluster-panel-body {
  padding: 6px 0;
  overflow-y: auto;
  flex: 1;
}

/* Empty state shared by the bell panel and an empty What's New */
.jp-cluster-empty {
  padding: 34px 24px;
  text-align: center;
  color: #5a7184;
  font-size: 13px;
  line-height: 1.55;
}
.jp-cluster-empty-sub {
  display: block;
  margin-top: 6px;
  font-size: 11.5px;
  color: #8fa3b8;
}

/* ── Notepad panel (Phase 4a — ClickUp-style) ─────────────────────── */
.jp-cluster-panel.jp-np-panel { width:420px; max-height: calc(100vh - 76px); }

.jp-np-header {
  display:flex; align-items:center; gap:8px;
  padding:14px 16px;
  background:#FFF4D4;
  border-bottom:1px solid rgba(1,36,61,0.06);
  flex-shrink:0;
}
.jp-np-header.is-detail { padding-left:10px; }
.jp-np-header-title {
  flex:1; min-width:0;
  font-size:15px; font-weight:700; color:#01243D;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
}
.jp-np-header-actions { display:flex; align-items:center; gap:2px; }
.jp-np-icon-btn {
  width:28px; height:28px; padding:0;
  background:transparent; border:none; cursor:pointer;
  color:#01243D;
  border-radius:6px;
  display:flex; align-items:center; justify-content:center;
  transition: background 120ms;
}
.jp-np-icon-btn:hover { background:rgba(1,36,61,0.06); }
.jp-np-search-input {
  width:180px; padding:5px 8px;
  border:1px solid rgba(1,36,61,0.15); border-radius:6px;
  font-size:12.5px; font-family:inherit; color:#01243D;
  background:#fff; outline:none;
}
.jp-np-search-input:focus { border-color:rgba(232,150,10,0.5); }

.jp-np-list-body {
  flex:1 1 auto; overflow-y:auto;
  padding:0;
}
.jp-np-row {
  display:flex; align-items:flex-start; gap:8px;
  padding:12px 16px;
  border-bottom:1px solid rgba(1,36,61,0.05);
  cursor:pointer;
  position:relative;
}
.jp-np-row:hover { background:rgba(1,36,61,0.03); }
.jp-np-row.is-pinned { background:#FFFBEB; }
.jp-np-row.is-pinned:hover { background:#FFF7D9; }
.jp-np-row-pin-mark {
  display:inline-flex; align-items:center; justify-content:center;
  width:14px; height:14px; margin-right:6px; vertical-align:-2px;
  color:#C9962F;
}
.jp-np-row-pin-mark svg { width:11px; height:11px; }
.jp-np-row-body { flex:1; min-width:0; }
.jp-np-row-title {
  font-size:14px; font-weight:600; color:#01243D;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
  line-height:1.3;
}
.jp-np-row-preview {
  margin-top:2px;
  font-size:12.5px; color:#5a7184;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
  line-height:1.3;
}
.jp-np-row-actions {
  display:flex; align-items:center; gap:2px;
  opacity:0; transition: opacity 120ms;
}
.jp-np-row:hover .jp-np-row-actions { opacity:1; }
.jp-np-row-action {
  width:28px; height:28px; padding:0;
  background:#fff; border:1px solid rgba(1,36,61,0.12); border-radius:6px;
  cursor:pointer; color:#5a7184;
  display:flex; align-items:center; justify-content:center;
  transition: background 120ms, color 120ms;
}
.jp-np-row-action:hover { background:rgba(1,36,61,0.05); color:#01243D; }
.jp-np-row-action[data-act="delete"]:hover { background:#fee2e2; color:#dc2626; border-color:rgba(220,38,38,0.25); }

.jp-np-new {
  display:flex; align-items:center; gap:8px;
  width:100%; padding:12px 16px;
  background:#fff; border:none; border-top:1px solid rgba(1,36,61,0.08);
  cursor:pointer;
  color:#5a7184; font-size:13px; font-weight:500; font-family:inherit;
  text-align:left;
  flex-shrink:0;
}
.jp-np-new:hover { background:rgba(1,36,61,0.03); color:#01243D; }
.jp-np-new svg { color:#8fa3b8; }
.jp-np-new:hover svg { color:#01243D; }

.jp-np-detail-body {
  flex:1 1 auto; overflow:hidden;
  display:flex; flex-direction:column;
  padding:0;
}
.jp-np-detail-remind {
  display:block; width:100%;
  padding:8px 16px;
  font-size:11.5px; font-weight:600; color:#E8960A;
  background:rgba(232,150,10,0.08);
  border:none; border-bottom:1px solid rgba(232,150,10,0.15);
  text-align:left; font-family:inherit;
  cursor:pointer;
}
.jp-np-detail-remind:hover { background:rgba(232,150,10,0.14); }
.jp-np-detail-linked {
  display:flex; align-items:center; gap:6px;
  width:100%; padding:8px 16px;
  background:rgba(34,116,221,0.06);
  border:none; border-bottom:1px solid rgba(34,116,221,0.15);
  cursor:pointer;
  font-size:11.5px; font-weight:600; color:#2274dd; font-family:inherit;
  text-align:left;
}
.jp-np-detail-linked:hover { background:rgba(34,116,221,0.10); }
.jp-np-detail-linked svg { width:13px; height:13px; }
.jp-np-editor {
  flex:1 1 auto;
  width:100%; box-sizing:border-box;
  padding:16px 18px;
  border:none; outline:none; resize:none;
  font-size:14px; font-family:inherit;
  color:#01243D; line-height:1.55;
  background:#fff;
}
.jp-np-detail-footer {
  display:flex; align-items:center; gap:4px;
  padding:8px 12px;
  border-top:1px solid rgba(1,36,61,0.08);
  flex-shrink:0;
  background:#fafbfc;
}
.jp-np-foot-btn {
  width:32px; height:32px; padding:0;
  background:transparent; border:none; cursor:pointer;
  color:#5a7184;
  border-radius:6px;
  display:flex; align-items:center; justify-content:center;
  transition: background 120ms, color 120ms;
}
.jp-np-foot-btn:hover { background:rgba(1,36,61,0.06); color:#01243D; }
.jp-np-foot-btn.is-on { color:#E8960A; }

.jp-np-pop {
  position:fixed; z-index:10000;
  width:180px;
  background:#fff;
  border:1px solid rgba(1,36,61,0.10);
  border-radius:8px;
  box-shadow:0 8px 24px rgba(0,0,0,0.14);
  padding:4px;
}
.jp-np-pop-item {
  display:block; width:100%; padding:8px 10px;
  background:none; border:none; cursor:pointer;
  text-align:left; color:#01243D;
  font-size:13px; font-family:inherit;
  border-radius:5px;
}
.jp-np-pop-item:hover { background:rgba(1,36,61,0.05); }
.jp-np-pop-item.is-danger { color:#dc2626; }
.jp-np-pop-item.is-danger:hover { background:#fee2e2; }

.jp-np-confirm-overlay {
  position:fixed; inset:0; z-index:10010;
  background:rgba(1,36,61,0.30);
  display:flex; align-items:center; justify-content:center;
  animation: jpNpFadeIn 140ms ease-out;
}
@keyframes jpNpFadeIn { from { opacity:0; } to { opacity:1; } }
.jp-np-confirm {
  width:340px; max-width:calc(100vw - 32px);
  background:#fff; border-radius:10px;
  box-shadow:0 24px 48px rgba(0,0,0,0.22);
  padding:20px 22px 16px;
  font-family:inherit;
}
.jp-np-confirm-title { font-size:15px; font-weight:600; color:#01243D; margin-bottom:8px; }
.jp-np-confirm-body  { font-size:12.5px; color:#5a7184; line-height:1.5; }
.jp-np-confirm-actions {
  display:flex; justify-content:flex-end; gap:8px;
  margin-top:18px;
}
.jp-np-confirm-cancel, .jp-np-confirm-ok {
  padding:8px 14px; border-radius:6px; cursor:pointer;
  font-size:12.5px; font-weight:600; font-family:inherit;
  border:1px solid rgba(1,36,61,0.12);
}
.jp-np-confirm-cancel { background:#fff; color:#01243D; }
.jp-np-confirm-cancel:hover { background:rgba(1,36,61,0.05); }
.jp-np-confirm-ok { background:#01243D; color:#fff; border-color:#01243D; }
.jp-np-confirm-ok:hover { background:#0a3050; }
.jp-np-confirm-ok.is-danger { background:#dc2626; border-color:#dc2626; }
.jp-np-confirm-ok.is-danger:hover { background:#b91c1c; }

.jp-np-empty {
  padding:40px 20px; text-align:center;
  font-size:13px; font-weight:600; color:#5a7184;
}
.jp-np-empty span {
  display:block; margin-top:6px;
  font-size:11.5px; font-weight:400; color:#8fa3b8;
}

.jp-notes-undo-toast {
  position:fixed; bottom:24px; left:50%; transform:translate(-50%, 12px);
  display:flex; align-items:center; gap:14px;
  background:#01243D; color:#fff;
  padding:10px 16px; border-radius:8px;
  font-size:12.5px; font-weight:500;
  box-shadow:0 8px 24px rgba(0,0,0,0.18);
  opacity:0; transition: opacity 180ms, transform 180ms;
  z-index:10001;
}
.jp-notes-undo-toast.show { opacity:1; transform:translate(-50%, 0); }
.jp-notes-undo-toast .jp-notes-undo-btn {
  background:transparent; border:none; cursor:pointer;
  color:#E8960A; font-weight:700; font-size:12.5px;
}

.jp-notes-remind-pop {
  position:fixed; z-index:10000;
  width:220px;
  background:#fff;
  border:1px solid rgba(1,36,61,0.10);
  border-radius:8px;
  box-shadow:0 8px 24px rgba(0,0,0,0.12);
  padding:8px;
  font-size:12.5px;
}
.jp-notes-remind-title {
  font-size:11px; font-weight:700; text-transform:uppercase;
  color:#8fa3b8; padding:4px 6px 6px; letter-spacing:0.5px;
}
.jp-notes-remind-opt {
  display:flex; align-items:center; justify-content:space-between;
  width:100%; padding:7px 8px;
  background:none; border:none; cursor:pointer;
  text-align:left; color:#01243D;
  font-size:12.5px; font-weight:500;
  border-radius:5px;
}
.jp-notes-remind-opt:hover { background:rgba(1,36,61,0.05); }
.jp-notes-remind-sub { color:#8fa3b8; font-size:11.5px; font-weight:400; margin-left:8px; }
.jp-notes-remind-custom {
  display:flex; gap:6px; align-items:center;
  margin:6px 4px 2px; padding-top:8px;
  border-top:1px solid rgba(1,36,61,0.06);
}
.jp-notes-remind-custom input {
  flex:1; min-width:0;
  padding:5px 6px; border:1px solid rgba(1,36,61,0.15); border-radius:5px;
  font-size:11.5px; font-family:inherit;
}
.jp-notes-remind-set {
  padding:5px 10px; border:none; border-radius:5px; cursor:pointer;
  background:#E8960A; color:#fff;
  font-weight:600; font-size:11.5px;
}
.jp-notes-remind-clear {
  width:100%; margin-top:6px; padding:7px;
  background:none; border:none; cursor:pointer;
  color:#dc2626; font-size:12px; font-weight:500;
  border-radius:5px;
}
.jp-notes-remind-clear:hover { background:#fee2e2; }

/* Release-note item (What's New panel) */
.jp-cluster-item {
  padding: 14px 20px;
  border-bottom: 1px solid rgba(1, 36, 61, 0.05);
}
.jp-cluster-item:last-child { border-bottom: none; }
.jp-cluster-item-date {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  font-weight: 500;
  color: #8fa3b8;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 5px;
}
.jp-cluster-item-title {
  font-size: 13px;
  font-weight: 500;
  color: #01243D;
  line-height: 1.35;
  letter-spacing: -0.005em;
  margin-bottom: 5px;
}
.jp-cluster-item-body {
  font-size: 12px;
  color: #5a7184;
  line-height: 1.6;
}
.jp-cluster-item-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.jp-cluster-item-tag.tag-feature { background: rgba(31, 140, 239, 0.10); color: var(--accent-interactive); }
.jp-cluster-item-tag.tag-fix     { background: rgba(34, 197, 94, 0.10);  color: #16a34a; }
.jp-cluster-item-tag.tag-design  { background: rgba(201, 150, 47, 0.12); color: #b87b1e; }

/* Link row (Help panel) */
.jp-cluster-link {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 20px;
  cursor: pointer;
  color: #01243D;
  text-decoration: none;
  transition: background var(--dur-fast) var(--ease-precision);
}
.jp-cluster-link + .jp-cluster-link {
  border-top: 1px solid rgba(1, 36, 61, 0.05);
}
.jp-cluster-link:hover { background: rgba(1, 36, 61, 0.03); }
.jp-cluster-link-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(1, 36, 61, 0.05);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #5a7184;
  flex-shrink: 0;
}
.jp-cluster-link-label { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.jp-cluster-link-title { font-size: 13px; font-weight: 500; letter-spacing: -0.005em; }
.jp-cluster-link-sub   { font-size: 11.5px; color: #8fa3b8; margin-top: 2px; }
.jp-cluster-link-arrow {
  color: rgba(1, 36, 61, 0.30);
  font-size: 13px;
  flex-shrink: 0;
}

/* Bell dot — red to distinguish from whatsnew gold dot */
.jp-cluster-dot-bell {
  background: #e53e3e;
  box-shadow: 0 0 0 1px rgba(229, 62, 62, 0.25);
}

/* Notification panel header row — title + mark-all-read */
.jp-notif-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px 12px;
  border-bottom: 1px solid rgba(1,36,61,0.06);
}
.jp-notif-header-title { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.jp-notif-mark-all {
  font-size: 11px; color: var(--accent-interactive);
  background: none; border: none; cursor: pointer; padding: 0;
  font-family: var(--font);
}
.jp-notif-mark-all:hover { text-decoration: underline; }

/* Individual notification row */
.jp-notif-item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(1,36,61,0.05);
  cursor: pointer; transition: background 0.12s;
  position: relative;
}
.jp-notif-item:last-child { border-bottom: none; }
.jp-notif-item:hover { background: rgba(1,36,61,0.03); }
.jp-notif-item.is-unread { background: rgba(31,140,239,0.04); }
.jp-notif-item.is-unread:hover { background: rgba(31,140,239,0.07); }
.jp-notif-unread-pip {
  position: absolute; left: 8px; top: 50%; transform: translateY(-50%);
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent-interactive); flex-shrink: 0;
}
.jp-notif-icon {
  width: 32px; height: 32px; border-radius: 8px; flex-shrink: 0;
  background: rgba(1,36,61,0.06);
  display: flex; align-items: center; justify-content: center;
  color: rgba(1,36,61,0.45);
}
.jp-notif-icon.type-referral_message  { background: rgba(31,140,239,0.10); color: var(--accent-interactive); }
.jp-notif-icon.type-license_expiring  { background: rgba(229,62,62,0.10);  color: #e53e3e; }
.jp-notif-icon.type-ai_coach_nudge    { background: rgba(201,150,47,0.12); color: #b87b1e; }
.jp-notif-content { flex: 1; min-width: 0; }
.jp-notif-title { font-size: 12.5px; font-weight: 500; color: var(--text-primary); line-height: 1.4; }
.jp-notif-body  { font-size: 11.5px; color: var(--text-secondary); margin-top: 2px; line-height: 1.45; }
.jp-notif-time  { font-size: 10.5px; color: var(--text-tertiary); margin-top: 4px; }

/* ── Bell panel v2 — matches the extension's simplified design ────── */
.jp-bell-header {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(1, 36, 61, 0.06);
  flex-shrink: 0;
}
.jp-bell-header-title {
  font-size: 13.5px; font-weight: 700; color: #01243D;
}
.jp-bell-count {
  background: #E8960A; color: #fff;
  padding: 1px 7px; border-radius: 10px;
  font-size: 10.5px; font-weight: 700; line-height: 1.4;
}
.jp-bell-overflow {
  background: none; border: none; cursor: pointer; padding: 4px 6px;
  border-radius: 6px; color: #6b7280;
  display: flex; align-items: center; justify-content: center;
}
.jp-bell-overflow:hover { background: rgba(1, 36, 61, 0.06); color: #01243D; }
.jp-bell-filter-trigger {
  margin-left: auto; display: flex; align-items: center; gap: 4px;
  padding: 4px 10px; background: none;
  border: 1px solid rgba(1, 36, 61, 0.12); border-radius: 8px;
  color: #01243D; font-size: 12px; font-weight: 600;
  cursor: pointer; line-height: 1.4; font-family: inherit;
}
.jp-bell-filter-trigger:hover { background: rgba(1, 36, 61, 0.04); border-color: rgba(1, 36, 61, 0.2); }
.jp-bell-filter-trigger svg { color: #6b7280; }

.jp-bell-body-wrap {
  padding: 0;
  /* Cap at ~7 rows (each row ≈ 70px) so the panel stays anchored
     to the bell instead of growing the full viewport height. */
  max-height: 500px;
  overflow-y: auto;
}
.jp-bell-empty {
  padding: 14px 16px; font-size: 12.5px; color: #6b7280;
  display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap;
}
.jp-bell-inline-link {
  background: none; border: none; cursor: pointer; padding: 0;
  color: #E8960A; font-size: 12.5px; font-weight: 600;
  text-decoration: underline; font-family: inherit;
}
.jp-bell-inline-link:hover { filter: brightness(0.85); }

.jp-bell-group {
  padding: 8px 14px 3px;
  font-size: 10px; font-weight: 700; color: #9ca3af;
  text-transform: uppercase; letter-spacing: 0.05em;
  background: #fff; position: sticky; top: 0; z-index: 1;
}

.jp-bell-row {
  position: relative;
  display: flex; align-items: flex-start; gap: 9px;
  padding: 9px 14px;
  border-bottom: 1px solid #f3f4f6; cursor: pointer;
  transition: background 0.1s;
  background: #fff;
}
.jp-bell-row:last-child { border-bottom: none; }
.jp-bell-row:hover { background: #fafafa; }
.jp-bell-row.is-unread { background: #fffdf6; }
.jp-bell-row.is-unread:hover { background: #fff7e3; }
.jp-bell-row.is-unread .jp-bell-title { font-weight: 700; }
.jp-bell-row.is-read .jp-bell-title { color: #4b5563; font-weight: 500; }
.jp-bell-row.is-read .jp-bell-subtext { color: #9ca3af; }
.jp-bell-row.is-completed { background: #fafafa; }
.jp-bell-row.is-completed:hover { background: #f4f4f4; }
.jp-bell-row.is-completed .jp-bell-title { color: #9ca3af; font-weight: 500; }
.jp-bell-row.is-completed .jp-bell-subtext { color: #b0b6bd; }
.jp-bell-row.is-completed .jp-bell-icon { filter: grayscale(0.6) opacity(0.65); }
.jp-bell-row.is-high-priority::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px; background: #dc2626;
}
.jp-bell-icon {
  flex-shrink: 0; padding-top: 1px;
  width: 18px; height: 18px; display: flex; align-items: center; justify-content: center;
  color: #4b5563;
}
.jp-bell-body { flex: 1; min-width: 0; }
.jp-bell-title {
  font-size: 12.5px; color: #01243D; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.jp-bell-subtext {
  font-size: 11.5px; color: #4b5563; margin-top: 1px; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.jp-bell-meta {
  font-size: 10.5px; color: #9ca3af; margin-top: 2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.jp-bell-ctx { color: #4b5563; font-weight: 500; }
.jp-bell-toggle {
  flex-shrink: 0; width: 12px; height: 12px; padding: 0;
  border: 1.5px solid #d1d5db; border-radius: 50%;
  background: #fff; cursor: pointer;
  opacity: 0; transition: opacity 0.12s, transform 0.12s;
  align-self: center; margin-left: 4px;
}
.jp-bell-row:hover .jp-bell-toggle { opacity: 1; }
.jp-bell-toggle.is-unread {
  background: #E8960A; border-color: #E8960A; opacity: 1;
}
.jp-bell-toggle:hover { transform: scale(1.2); }
.jp-bell-toggle.is-unread:hover { background: transparent; }

/* Filter / kebab popup menu (anchored to header buttons) */
.jp-bell-popup {
  position: fixed; z-index: 2147483647;
  background: #fff; border: 1px solid rgba(1, 36, 61, 0.12); border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
  padding: 4px; font-family: inherit;
}
.jp-bell-popup-item {
  display: block; width: 100%; padding: 8px 12px;
  background: none; border: none; cursor: pointer; text-align: left;
  font-size: 13px; color: #01243D; border-radius: 6px;
  font-family: inherit;
}
.jp-bell-popup-item:hover { background: rgba(1, 36, 61, 0.05); }
.jp-bell-popup-item:disabled { color: #9ca3af; cursor: default; }
.jp-bell-popup-item:disabled:hover { background: none; }
.jp-bell-popup-item.is-active { color: #E8960A; font-weight: 700; }
.jp-bell-popup-item.is-active::before { content: '✓ '; }

@media (prefers-reduced-motion: reduce) {
  .jp-cluster-btn,
  .jp-cluster-panel { transition: none; }
  .jp-cluster-btn:hover,
  .jp-cluster-btn:active { transform: none; }
}

/* Mobile / narrow viewport — panel becomes near-full-width */
@media (max-width: 540px) {
  .jp-cluster-panel {
    right: 12px;
    left: 12px;
    width: auto;
  }
}

/* ═══════════════════════════════════════
   LAYOUT SHELL
═══════════════════════════════════════ */
#app { display:flex; flex-direction:row; width:100vw; height:100vh; overflow:hidden; }

/* Top Nav */
#topnav {
  height:var(--topnav-h); min-height:var(--topnav-h);
  background:var(--navy-2);
  border-bottom:1px solid var(--border);
  display:flex; align-items:center;
  padding:0 0 0 16px;
  gap:0; flex-shrink:0;
  position:relative; z-index:100;
  width:100%; overflow:visible;
}
.brand {
  display:flex; flex-direction:column; align-items:flex-start; justify-content:center; gap:5px;
  width:var(--sidebar-w); min-width:var(--sidebar-w);
  padding:10px 16px 10px 0;
  border-right:1px solid var(--border);
  height:100%;
}
.brand-icon {
  width:30px; height:30px; border-radius:7px;
  display:flex; align-items:center; justify-content:center;
  font-size:15px; flex-shrink:0;
}
.brand-name { font-size:11px; font-weight:400; color:#fff; letter-spacing:0.04em; line-height:1.2; }
.brand-sub  { font-size:8px; color:var(--yellow); letter-spacing:0.18em; text-transform:uppercase; font-weight:400; }
.sidebar-logo {
  display:flex; align-items:center; justify-content:center;
  padding:20px 16px 14px;
  flex-shrink:0;
}
.topnav-search {
  flex:1; display:flex; align-items:center; gap:8px;
  margin:0 24px;
  background:rgba(255,255,255,0.92);
  border:1px solid rgba(255,255,255,0.6);
  border-radius:8px;
  padding:0 12px;
  height:32px;
  max-width:400px;
  transition:all 0.2s;
  box-shadow:0 2px 8px rgba(0,0,0,0.15), inset 0 1px 0 rgba(255,255,255,1);
}
.topnav-search:focus-within {
  background:rgba(255,255,255,1);
  border-color:rgba(255,255,255,0.9);
  box-shadow:0 4px 14px rgba(0,0,0,0.18), inset 0 1px 0 rgba(255,255,255,1);
}
.topnav-search-icon {
  color:rgba(1,36,61,0.35); flex-shrink:0;
}
.topnav-search-input {
  flex:1; background:transparent; border:none; outline:none;
  font-family:var(--font); font-size:11px; font-weight:400;
  color:rgba(1,36,61,0.80); letter-spacing:0.02em;
}
.topnav-search-input::placeholder { color:rgba(1,36,61,0.35); }

/* ── Sidebar logo row ────────────────────────────── */
.sidebar-logo {
  display:flex; align-items:center; gap:10px;
}
/* #sidebar-hamburger */ .__unused {
  display:flex; align-items:center; justify-content:center;
  width:32px; height:32px; flex-shrink:0;
  background:rgba(255,255,255,0.1); border:none; cursor:pointer;
  color:rgba(255,255,255,0.75); border-radius:7px;
  transition:all 0.15s;
}
/* #sidebar-hamburger */ .__unused:hover { background:rgba(255,255,255,0.2); color:#fff; }
/* Always show ☰ — never switch to ✕ on the button itself */
/* #sidebar-hamburger */ .__unused .close-icon { display:none !important; }
/* #sidebar-hamburger */ .__unused .ham-icon   { display:block !important; }

/* ── Sidebar collapse ────────────────────────────── */
#sidebar {
  transition: width 0.24s cubic-bezier(0.4,0,0.2,1),
              min-width 0.24s cubic-bezier(0.4,0,0.2,1);
}
/* ── Collapsed: icon-only rail ── */
#sidebar.sidebar-collapsed {
  width: 60px !important; min-width: 60px !important;
  overflow: visible;
}
/* Logo: hide wordmark, show icon */
#sidebar.sidebar-collapsed .sidebar-wordmark { display: none !important; }
#sidebar.sidebar-collapsed .sidebar-icon-only { display: block !important; }
#sidebar.sidebar-collapsed .sidebar-logo {
  justify-content: center; padding: 16px 0; flex-direction: column; gap: 0;
}
/* Hide settings nav */
#sidebar.sidebar-collapsed #sidebar-settings-nav { display: none !important; }

/* Nav items — icon only, centered */
#sidebar.sidebar-collapsed #sidebar-main-nav { display: flex !important; flex-direction: column; align-items: center; }
#sidebar.sidebar-collapsed .phase-sub-item,
#sidebar.sidebar-collapsed .phase-header {
  width: 44px !important; min-width: 44px !important;
  padding: 10px 0 !important;
  justify-content: center !important;
  border-radius: 10px !important;
  margin: 1px auto !important;
}
/* Hide text — font-size:0 hides text nodes, SVGs unaffected */
#sidebar.sidebar-collapsed .phase-sub-item > div,
#sidebar.sidebar-collapsed .phase-header .phase-header-left {
  font-size: 0 !important;
  gap: 0 !important;
  justify-content: center !important;
}
#sidebar.sidebar-collapsed .phase-sub-item > div svg,
#sidebar.sidebar-collapsed .phase-header .phase-header-left svg {
  width: 18px !important; height: 18px !important; flex-shrink: 0;
}
/* Hide arrow, NEW badge, item-status dots */
#sidebar.sidebar-collapsed .phase-arrow,
#sidebar.sidebar-collapsed .item-status,
#sidebar.sidebar-collapsed #sib-ai-coach > div:last-child,
#sidebar.sidebar-collapsed #sib-referral-hub > div:last-child { display: none !important; }
/* Hide phase sub-items (children) — only show top-level icons */
#sidebar.sidebar-collapsed .phase-items { display: none !important; }

/* User pill — avatar only */
#sidebar.sidebar-collapsed .sidebar-user-pill {
  width: 44px !important; margin: 4px auto 8px !important;
  padding: 6px !important; justify-content: center !important;
}
#sidebar.sidebar-collapsed .sidebar-user-info,
#sidebar.sidebar-collapsed .sidebar-status-dot { display: none !important; }
#sidebar.sidebar-collapsed .sidebar-user-avatar {
  width: 34px !important; height: 34px !important;
}
/* ☰ always visible in all states — handled above */

.topnav-right {
  margin-left:auto; padding-right:16px;
  display:flex; align-items:center; gap:10px;
}
.cred-btn {
  background:rgba(1,36,61,0.06); border:1px solid rgba(1,36,61,0.15);
  border-radius:6px; padding:5px 10px;
  color:rgba(1,36,61,0.65); font-size:10px; font-weight:400;
  font-family:var(--font); cursor:pointer; transition:all 0.2s;
  letter-spacing:0.06em; text-transform:uppercase;
}
.cred-btn:hover { border-color:var(--navy); color:var(--navy); }
.load-ghl-btn { border-color:var(--accent-b); color:var(--accent); }
.load-ghl-btn:hover { border-color:var(--accent); color:#fff; background:var(--accent-b); }
.load-ghl-btn:disabled { opacity:0.5; cursor:wait; }
.load-ghl-status { font-size:10px; font-weight:400; letter-spacing:0.04em; white-space:nowrap; }
.load-ghl-ok  { color:#4ade80; }
.load-ghl-err { color:#f87171; }
.load-ghl-warn { color:var(--yellow); }

/* GHL Sync Pill */
.ghl-sync-pill {
  display:flex; align-items:center; gap:6px;
  background:rgba(1,36,61,0.06); border:1px solid rgba(1,36,61,0.12);
  border-radius:20px; padding:5px 12px 5px 8px;
  cursor:pointer; transition:all 0.18s; font-family:var(--font);
}
.ghl-sync-pill:hover { background:rgba(1,36,61,0.10); border-color:rgba(1,36,61,0.2); }
.ghl-sync-pill:disabled { opacity:0.6; cursor:wait; }
.ghl-sync-label-prefix { font-size:11px; font-weight:400; color:rgba(1,36,61,0.45); letter-spacing:0.01em; }
.ghl-sync-icon { display:flex; align-items:center; flex-shrink:0; }
.ghl-sync-label { font-size:11px; font-weight:400; color:rgba(1,36,61,0.75); letter-spacing:0.01em; }

/* ── User Menu ───────────────────────────────────────── */
.user-menu-wrap { position:relative; }
.user-menu-btn {
  display:flex; align-items:center; gap:10px;
  background:transparent; border:none;
  padding:4px 6px;
  cursor:pointer; transition:all 0.18s;
}
.user-menu-btn:hover { opacity:0.85; }
.user-avatar {
  width:38px; height:38px; border-radius:50%;
  background:var(--yellow); color:#000;
  font-size:12px; font-weight:400; font-family:var(--font);
  display:flex; align-items:center; justify-content:center;
  flex-shrink:0; overflow:hidden; letter-spacing:0.02em;
  box-shadow:0 2px 8px rgba(0,0,0,0.3);
}
.user-name {
  font-size:13px; font-weight:400; color:rgba(1,36,61,0.85);
  font-family:var(--font); white-space:nowrap; max-width:160px;
  overflow:hidden; text-overflow:ellipsis;
  letter-spacing:0.01em;
}
.user-chevron { color:var(--w50); flex-shrink:0; transition:transform 0.18s; }
.user-dropdown {
  position:fixed;
  width:180px;
  background:linear-gradient(145deg, #013a70, #012952);
  border:1px solid rgba(255,255,255,0.12);
  border-radius:10px; overflow:hidden;
  box-shadow:0 12px 32px rgba(0,0,0,0.4);
  display:none; z-index:9999;
}
.user-dropdown.open { display:block; }
.user-dd-item {
  width:100%; display:flex; align-items:center; gap:9px;
  padding:11px 14px; background:none; border:none;
  font-family:var(--font); font-size:11px; font-weight:400;
  color:var(--w70); cursor:pointer; transition:all 0.15s;
  text-align:left;
}
.user-dd-item:hover { background:rgba(255,255,255,0.08); color:#fff; }
.user-dd-item svg { flex-shrink:0; opacity:0.6; }
.user-dd-divider { height:1px; background:rgba(255,255,255,0.08); margin:2px 0; }
.user-dd-logout { color:rgba(255,90,90,0.8); }
.user-dd-logout:hover { background:rgba(220,50,50,0.12); color:#ff8080; }

/* Body */
#body { display:flex; flex:1; overflow:hidden; min-width:0; height:100%; }

/* Right column — topnav stacked above content */
#right-col { display:flex; flex-direction:column; flex:1; overflow:hidden; min-width:0; }

/* Content row — main + right-panel side by side */
#content-row { display:flex; flex:1; overflow:hidden; min-width:0; }

/* Sidebar */
#sidebar {
  width:var(--sidebar-w); min-width:var(--sidebar-w);
  background:var(--navy-2);
  border-right:1px solid var(--border);
  display:flex; flex-direction:column;
  overflow-y:auto; overflow-x:hidden;
  flex-shrink:0;
}
#sidebar::-webkit-scrollbar { width:3px; }
#sidebar::-webkit-scrollbar-track { background:transparent; }
#sidebar::-webkit-scrollbar-thumb { background:var(--border2); border-radius:2px; }

.sidebar-section-label {
  padding:14px 16px 6px;
  font-size:8px; font-weight:400; letter-spacing:0.26em;
  color:var(--w30); text-transform:uppercase;
}
.sidebar-item {
  width:100%; text-align:left;
  background:transparent; border:none;
  border-left:3px solid transparent;
  padding:10px 16px;
  font-family:var(--font); font-size:13px; font-weight:400;
  color:var(--w50); cursor:pointer;
  transition:all 0.18s;
  display:flex; align-items:center; justify-content:space-between;
  gap:8px;
}
.sidebar-item:hover { background:var(--w15); color:var(--w90); }
.sidebar-item.active { background:var(--yellow-m); border-left-color:var(--yellow); color:#fff; }
.sidebar-item .item-status {
  width:7px; height:7px; border-radius:50%; flex-shrink:0;
  background:var(--border2);
}
.sidebar-item .item-status.done { background:var(--green); }
.sidebar-item .item-status.partial { background:var(--yellow); }

/* Main content */
#main {
  flex:1; overflow:hidden;
  min-width:0; /* critical for flex child not to overflow */
  display:flex; flex-direction:column; /* topbar above, page-content below */
  background:radial-gradient(ellipse 80% 50% at 60% 0%, rgba(14,58,110,0.25) 0%, transparent 60%),
             var(--navy);
}
#main::-webkit-scrollbar { width:4px; }
#main::-webkit-scrollbar-track { background:transparent; }
#main::-webkit-scrollbar-thumb { background:var(--border2); border-radius:2px; }

/* ── Sticky header band (locked design contract, 2026-06-15) ───────────
   Top bar + page-header slot + divider are pinned together as one
   shell-level element. The page below scrolls under it.
   The band is flex-shrink:0 inside #main (a flex column), so #page-content
   does the scrolling and the band stays put without position:sticky. */
#app-header-band {
  flex-shrink: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  z-index: 5;
}

/* Top bar — global icons only (doc, bell, help, send). 8px padding per
   locked contract. */
#jp-topbar {
  flex-shrink: 0;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: transparent;
}
#jp-topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

/* Page header slot — populated by window.renderPageHeader(). Empty slot
   collapses to zero height so the divider sits flush against the topbar
   on full-bleed pages. */
#page-header-slot:empty { display: none; }

/* Locked page header (single row): [icon] Title │ subhead   actions */
.app-page-header {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 48px;     /* matches canvas gutters */
  min-height: 56px;
}
.app-page-header-left {
  display: flex;
  align-items: center;
  gap: 0;
  min-width: 0;
  flex: 1;
}
.app-page-header-icon {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0c2340;
  flex-shrink: 0;
  margin-right: 10px;
}
.app-page-header-icon svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.5;
}
.app-page-header-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  color: #0c2340;
  letter-spacing: -0.005em;
  white-space: nowrap;
  flex-shrink: 0;
}
.app-page-header-sep {
  width: 1px;
  height: 20px;
  background: rgba(12, 35, 64, 0.15);
  margin: 0 14px;
  flex-shrink: 0;
}
.app-page-header-sub {
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.4;
  color: #6b7280;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.app-page-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  margin-left: 16px;
}
.app-page-header-actions .aph-util {
  position: relative;        /* dot indicators inside utility buttons */
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid rgba(12, 35, 64, 0.10);
  background: #fff;
  color: #6b7280;
  cursor: pointer;
  padding: 0;
  transition: border-color .15s, color .15s, background .15s;
}
.app-page-header-actions .aph-util:hover {
  border-color: rgba(12, 35, 64, 0.22);
  color: #0c2340;
}
.app-page-header-actions .aph-util svg {
  width: 16px;
  height: 16px;
  stroke-width: 1.5;
}
.app-page-header-actions .aph-search {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid rgba(12, 35, 64, 0.10);
  background: #fff;
  color: #6b7280;
  font: 400 12.5px 'Poppins', sans-serif;
  cursor: text;
}
.app-page-header-actions .aph-search svg { width: 14px; height: 14px; stroke-width: 1.5; }
.app-page-header-actions .aph-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid #c9962f;
  background: linear-gradient(180deg, #f0c454 0%, #d9a13b 100%);
  color: #041626;
  font: 500 12.5px 'Poppins', sans-serif;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(12, 35, 64, 0.08);
  transition: filter .15s, box-shadow .15s;
}
.app-page-header-actions .aph-primary:hover {
  filter: brightness(1.04);
  box-shadow: 0 2px 6px rgba(12, 35, 64, 0.12);
}
.app-page-header-actions .aph-primary svg { width: 14px; height: 14px; stroke-width: 1.75; }

/* Divider beneath the page header — 0.5px, 10px below header row, 48px
   gutters per locked contract. */
#app-header-band::after {
  content: '';
  display: block;
  height: 0.5px;
  background: rgba(12, 35, 64, 0.15);
  margin: 10px 48px 0;
}
/* Hide the divider entirely on full-bleed pages (page header is empty). */
#app-header-band:has(#page-header-slot:empty)::after { display: none; }

#page-content {
  min-width:0; width:100%;
  padding: 20px 48px 60px;  /* locked canvas: 48px L/R, content starts 20px below divider */
  flex:1;
  overflow-y: auto;
  overflow-x: hidden;
}
#page-content::-webkit-scrollbar { width:4px; }
#page-content::-webkit-scrollbar-track { background:transparent; }
#page-content::-webkit-scrollbar-thumb { background:var(--border2); border-radius:2px; }

/* ═══════════════════════════════════════
   PAGE HEADER
═══════════════════════════════════════ */
.page-header {
  padding:18px 28px 0;
  border-bottom:1px solid var(--border);
  background:var(--navy-2);
  width:100%; box-sizing:border-box;
}
.page-header-top { display:flex; align-items:center; justify-content:space-between; margin-bottom:14px; }
.page-title-row { display:flex; align-items:center; gap:10px; }
.page-icon { font-size:20px; }
.page-title { font-size:16px; font-weight:400; color:var(--w90); letter-spacing:0.02em; }
.page-sub { font-size:11px; color:var(--w50); margin-top:2px; }

/* Sub-tabs (horizontal tabs below header) */
.subtabs {
  display:flex; gap:2px; padding-top:2px;
  overflow-x:auto;
}
.subtabs::-webkit-scrollbar { display:none; }
.subtab {
  padding:9px 16px; background:transparent; border:none;
  font-family:var(--font); font-size:10px; font-weight:400;
  letter-spacing:0.1em; text-transform:uppercase;
  color:var(--w50); cursor:pointer; white-space:nowrap;
  border-bottom:2px solid transparent;
  transition:all 0.18s;
}
.subtab:hover { color:var(--w90); }
.subtab.active { color:var(--yellow); border-bottom-color:var(--yellow); }

/* ═══════════════════════════════════════
   CONTENT AREA
═══════════════════════════════════════ */
.content { padding:24px 28px; box-sizing:border-box; width:100%; }

/* Section block */
.section-block { margin-bottom:28px; }
.section-label {
  font-size:9px; font-weight:400; letter-spacing:0.26em;
  color:var(--yellow); text-transform:uppercase; margin-bottom:12px;
  display:flex; align-items:center; gap:8px;
}
.section-label::after { content:''; flex:1; height:1px; background:var(--border); }

/* Field card */
.field-card {
  background:var(--navy-2);
  border:1px solid var(--border);
  border-radius:10px; overflow:hidden;
  margin-bottom:10px;
  transition:border-color 0.2s;
  width:100%; box-sizing:border-box;
}
.field-card:focus-within { border-color:var(--yellow-b); }
.field-card.synced { border-color:var(--green-b); }
.field-card.error  { border-color:var(--red-b); }

.field-header {
  padding:11px 16px 9px;
  display:flex; justify-content:space-between; align-items:flex-start;
  border-bottom:1px solid var(--border);
  background:rgba(255,255,255,0.02);
  min-width:0; gap:8px;
}
.field-meta { flex:1; min-width:0; overflow:hidden; }
.field-name {
  font-size:11px; font-weight:400; color:#fff;
  text-transform:uppercase; letter-spacing:0.06em;
  margin-bottom:2px;
}
.field-desc { font-size:10px; color:var(--w50); line-height:1.5; }
.field-ghl-key { font-size:9px; color:var(--w30); font-family:var(--mono); margin-top:3px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

.field-actions { display:flex; align-items:center; gap:5px; flex-shrink:0; flex-wrap:wrap; justify-content:flex-end; }

.btn-ai {
  background:var(--yellow-m); border:1px solid var(--yellow-b);
  border-radius:5px; padding:5px 10px;
  color:var(--yellow); font-size:9px; font-weight:400;
  font-family:var(--font); letter-spacing:0.1em; text-transform:uppercase;
  cursor:pointer; transition:all 0.18s; white-space:nowrap;
  display:flex; align-items:center; gap:5px;
}
.btn-ai:hover { background:rgba(255,187,0,0.2); }
.btn-ai:disabled { opacity:0.4; cursor:not-allowed; }

.btn-sync {
  background:transparent; border:1px solid var(--border2);
  border-radius:5px; padding:5px 10px;
  color:var(--w50); font-size:9px; font-weight:400;
  font-family:var(--font); letter-spacing:0.08em; text-transform:uppercase;
  cursor:pointer; transition:all 0.18s; white-space:nowrap;
}
.btn-sync:hover { border-color:var(--green-b); color:var(--green); }
.btn-sync:disabled { opacity:0.4; cursor:not-allowed; }

.field-body { padding:12px 16px; }
textarea.field-input, input.field-input {
  width:100%; background:transparent; border:none;
  color:#fff; font-family:var(--mono); font-size:12px;
  outline:none; resize:none; line-height:1.7;
  box-sizing:border-box; min-width:0;
}
textarea.field-input { min-height:60px; }
input.field-input { height:28px; }
textarea.field-input::placeholder,
input.field-input::placeholder { color:var(--w30); }

.field-footer {
  padding:7px 16px;
  background:rgba(0,0,0,0.12);
  border-top:1px solid var(--border);
  display:flex; justify-content:space-between; align-items:center;
  gap:8px;
}
.field-status { font-size:9px; font-family:var(--mono); color:var(--w30); display:flex; align-items:center; gap:5px; }
.field-status.ok   { color:var(--green); }
.field-status.err  { color:var(--red); }
.field-status.busy { color:var(--yellow); }
.char-count { font-size:9px; color:var(--w30); font-family:var(--mono); }

/* AI response inline */
.ai-response {
  margin:0 16px 12px;
  padding:12px 14px;
  background:var(--blue-m); border:1px solid var(--blue-b);
  border-radius:7px; font-size:12px; color:var(--w90);
  font-family:var(--mono); line-height:1.7;
  display:none;
}
.ai-response.show { display:block; }
.ai-response-header {
  font-size:9px; font-weight:400; letter-spacing:0.16em;
  color:var(--blue); text-transform:uppercase; margin-bottom:8px;
  display:flex; justify-content:space-between; align-items:center;
}
.btn-use-ai {
  background:var(--blue-m); border:1px solid var(--blue-b);
  border-radius:4px; padding:4px 10px;
  color:var(--blue); font-size:9px; font-weight:400;
  font-family:var(--font); letter-spacing:0.1em; text-transform:uppercase;
  cursor:pointer; transition:all 0.15s;
}
.btn-use-ai:hover { background:rgba(21,138,246,0.2); }

/* ═══════════════════════════════════════
   PROGRESS BAR
═══════════════════════════════════════ */
.progress-bar-wrap {
  padding:10px 28px;
  background:var(--navy-2);
  border-bottom:1px solid var(--border);
  display:flex; align-items:center; gap:12px;
  width:100%; box-sizing:border-box;
}
.progress-bar-track {
  flex:1; height:4px; background:var(--border);
  border-radius:2px; overflow:hidden;
}
.progress-bar-fill {
  height:100%; border-radius:2px;
  background:linear-gradient(90deg, var(--yellow), var(--yellow-d));
  transition:width 0.4s;
}
.progress-label { font-size:10px; color:var(--w50); font-weight:400; white-space:nowrap; }

/* ═══════════════════════════════════════
   SOFT GATE BANNER
═══════════════════════════════════════ */
.soft-gate {
  margin:20px 28px 0;
  padding:12px 16px;
  background:rgba(255,187,0,0.08); border:1px solid var(--yellow-b);
  border-radius:8px;
  display:flex; align-items:flex-start; gap:10px;
  font-size:11px; color:var(--w70); line-height:1.6;
}
.soft-gate-icon { font-size:16px; flex-shrink:0; margin-top:1px; }
.soft-gate strong { color:var(--yellow); }

/* ═══════════════════════════════════════
   SECTION SYNC FOOTER
═══════════════════════════════════════ */
.section-sync-bar {
  margin-top:8px; padding:14px 16px;
  background:var(--navy-2); border:1px solid var(--border);
  border-radius:8px;
  display:flex; justify-content:space-between; align-items:center; gap:12px;
  flex-wrap:wrap; width:100%; box-sizing:border-box;
}
.sync-summary { font-size:11px; color:var(--w50); }
.sync-summary strong { color:#fff; }
.btn-sync-all {
  background:linear-gradient(135deg,var(--yellow),var(--yellow-d));
  border:none; border-radius:7px; padding:9px 20px;
  color:var(--navy); font-weight:400; font-size:10px;
  letter-spacing:0.12em; text-transform:uppercase;
  font-family:var(--font); cursor:pointer; transition:all 0.2s;
  box-shadow:0 3px 12px var(--yellow-m);
}
.btn-sync-all:hover { transform:translateY(-1px); box-shadow:0 5px 18px var(--yellow-m); }
.btn-sync-all:disabled { opacity:0.45; cursor:not-allowed; transform:none; }

/* ═══════════════════════════════════════
   CREDENTIALS MODAL
═══════════════════════════════════════ */
#cred-modal {
  position:fixed; inset:0; z-index:1000;
  background:rgba(1,24,45,0.96); backdrop-filter:blur(8px);
  display:flex; align-items:center; justify-content:center;
  padding:20px;
}
.cred-modal-box {
  width:100%; max-width:460px;
  background:linear-gradient(145deg, var(--navy-3), var(--navy-2));
  border:1px solid var(--border2); border-radius:14px;
  overflow:hidden;
  box-shadow:0 0 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.04) inset;
}
.cred-modal-header {
  padding:22px 26px 18px;
  border-bottom:1px solid var(--border);
  background:linear-gradient(135deg, rgba(255,187,0,0.06), transparent);
  display:flex; align-items:center; gap:12px;
}
.cred-modal-icon {
  width:40px; height:40px; border-radius:9px;
  background:linear-gradient(135deg,var(--yellow),var(--yellow-d));
  display:flex; align-items:center; justify-content:center;
  font-size:18px; flex-shrink:0;
}
.cred-modal-title { font-size:15px; font-weight:400; color:#fff; line-height:1.1; }
.cred-modal-sub   { font-size:9px; color:var(--yellow); letter-spacing:0.18em; text-transform:uppercase; font-weight:400; margin-top:3px; }
.cred-modal-body  { padding:20px 26px; display:flex; flex-direction:column; gap:14px; }

.cred-section-label {
  font-size:8px; font-weight:400; letter-spacing:0.26em;
  color:var(--yellow); text-transform:uppercase; margin-bottom:8px;
}
.cred-field { display:flex; flex-direction:column; gap:5px; }
.cred-field label { font-size:9px; font-weight:400; color:var(--w50); text-transform:uppercase; letter-spacing:0.14em; }
.cred-input-wrap { position:relative; }
.cred-input {
  width:100%; background:var(--navy);
  border:1px solid var(--border2); border-radius:7px;
  color:#fff; font-family:var(--mono); font-size:11px;
  padding:9px 36px 9px 12px; outline:none;
  transition:border-color 0.2s, box-shadow 0.2s;
}
.cred-input:focus { border-color:var(--yellow); box-shadow:0 0 0 3px var(--yellow-m); }
.cred-hint { font-size:9px; color:var(--w30); font-family:var(--mono); line-height:1.5; }
.cred-hint a { color:var(--blue); text-decoration:none; }
.eye-btn {
  position:absolute; right:10px; top:50%; transform:translateY(-50%);
  background:none; border:none; cursor:pointer;
  color:var(--w30); font-size:13px; padding:0; transition:color 0.2s;
}
.eye-btn:hover { color:var(--w70); }
.cred-divider { height:1px; background:var(--border); }
.cred-error {
  background:var(--red-m); border:1px solid var(--red-b);
  border-radius:6px; padding:9px 12px;
  font-size:10px; color:var(--red); font-family:var(--mono);
  display:none;
}
.btn-verify {
  width:100%; background:linear-gradient(135deg,var(--yellow),var(--yellow-d));
  border:none; border-radius:8px; padding:12px;
  color:var(--navy); font-weight:400; font-size:11px;
  letter-spacing:0.14em; text-transform:uppercase;
  font-family:var(--font); cursor:pointer; transition:all 0.2s;
  box-shadow:0 4px 16px var(--yellow-m);
}
.btn-verify:hover:not(:disabled) { transform:translateY(-1px); box-shadow:0 6px 22px var(--yellow-m); }
.btn-verify:disabled { opacity:0.45; cursor:not-allowed; transform:none; }
.cred-footnote { font-size:9px; color:var(--w30); text-align:center; font-family:var(--mono); }

/* ═══════════════════════════════════════
   SPINNERS & ANIMATIONS
═══════════════════════════════════════ */
@keyframes spin  { to { transform:rotate(360deg); } }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.3} }
.spinner {
  width:11px; height:11px; border-radius:50%;
  border:2px solid currentColor; border-top-color:transparent;
  animation:spin 0.7s linear infinite; display:inline-block; flex-shrink:0;
}

/* ═══════════════════════════════════════
   WELCOME / EMPTY STATE
═══════════════════════════════════════ */
.welcome-state {
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  min-height:60vh; text-align:center; padding:40px;
}
.welcome-icon { font-size:48px; margin-bottom:16px; opacity:0.4; }
.welcome-title { font-size:18px; font-weight:400; color:var(--w70); margin-bottom:8px; }
.welcome-sub { font-size:12px; color:var(--w30); max-width:320px; line-height:1.7; }

/* ═══════════════════════════════════════
   HISTORY DROPDOWN
═══════════════════════════════════════ */
.history-wrap { position:relative; display:inline-flex; }
.btn-history {
  background:transparent; border:1px solid var(--border);
  border-radius:5px; padding:4px 8px;
  color:var(--w30); font-size:9px; font-weight:400;
  font-family:var(--font); letter-spacing:0.06em;
  cursor:pointer; transition:all 0.18s; white-space:nowrap;
}
.btn-history:hover { border-color:var(--border2); color:var(--w60); }
.btn-history.has-history { color:var(--blue); border-color:var(--blue-b); background:var(--blue-m); }
.history-dropdown {
  position:absolute; right:0; bottom:calc(100% + 8px);
  width:300px; max-height:260px; overflow-y:auto;
  background:var(--navy-3); border:1px solid var(--border2);
  border-radius:9px; z-index:500;
  box-shadow:0 12px 40px rgba(0,0,0,0.6);
  display:none;
}
.history-dropdown.open { display:block; }
.history-dropdown::-webkit-scrollbar { width:3px; }
.history-dropdown::-webkit-scrollbar-thumb { background:var(--border2); border-radius:2px; }
.history-header {
  padding:9px 12px 8px;
  font-size:8px; font-weight:400; letter-spacing:0.22em;
  color:var(--yellow); text-transform:uppercase;
  border-bottom:1px solid var(--border);
  display:flex; justify-content:space-between; align-items:center;
  position:sticky; top:0; background:var(--navy-3); z-index:1;
}
.btn-clear-history {
  background:none; border:none; cursor:pointer;
  color:var(--w30); font-size:9px; font-family:var(--font);
  padding:0; transition:color 0.15s; font-weight:400; letter-spacing:0.06em;
}
.btn-clear-history:hover { color:var(--red); }
.history-empty {
  padding:14px 12px; text-align:center;
  font-size:10px; color:var(--w30); font-family:var(--mono);
}
.history-item {
  padding:9px 12px; border-bottom:1px solid var(--border);
  cursor:pointer; transition:background 0.15s;
  display:flex; flex-direction:column; gap:3px;
}
.history-item:last-child { border-bottom:none; }
.history-item:hover { background:rgba(255,255,255,0.04); }
.history-item-text {
  font-size:11px; color:var(--w80); font-family:var(--mono);
  line-height:1.5; word-break:break-word;
  display:-webkit-box; -webkit-line-clamp:2; line-clamp:2; -webkit-box-orient:vertical; overflow:hidden;
}
.history-item-meta {
  font-size:9px; color:var(--w30); font-family:var(--mono);
  display:flex; justify-content:space-between;
}
.history-item-use {
  font-size:9px; color:var(--yellow); font-weight:400;
  font-family:var(--font); letter-spacing:0.08em;
  opacity:0; transition:opacity 0.15s;
}
.history-item:hover .history-item-use { opacity:1; }

/* Save flash */
@keyframes savePulse { 0%{background:rgba(55,202,55,0.18)} 100%{background:transparent} }
.save-flash { animation:savePulse 0.7s ease-out; }

/* Sync log */
#sync-log { padding:0 28px 28px; }
.sync-log-row {
  display:flex; align-items:center; gap:8px;
  padding:6px 12px; border-radius:5px; margin-bottom:3px;
  font-size:11px; font-family:var(--mono);
}
.sync-log-row.ok   { background:var(--green-m); color:var(--green); }
.sync-log-row.err  { background:var(--red-m);   color:var(--red); }
.sync-log-row.skip { background:var(--w15);     color:var(--w50); }

/* ═══════════════════════════════════════
   LAUNCHPAD LAYOUT
═══════════════════════════════════════ */
.lp-body {
  display:flex; gap:0; height:calc(100vh - 130px);
  overflow:hidden;
}
.lp-steps-panel {
  width:200px; min-width:200px;
  background:var(--navy-4);
  border-right:1px solid var(--border);
  padding:16px 0;
  overflow-y:auto; flex-shrink:0;
}
.lp-steps-title {
  font-size:18px; font-weight:400; color:#fff;
  padding:0 16px 14px; letter-spacing:0.01em;
}
.lp-step-item {
  display:flex; align-items:flex-start; gap:10px;
  padding:10px 16px; cursor:pointer;
  transition:background 0.15s;
  border-left:3px solid transparent;
}
.lp-step-item:hover { background:rgba(255,255,255,0.05); }
.lp-step-item.active {
  background:rgba(255,255,255,0.07);
  border-left-color:var(--yellow);
}
.lp-step-num {
  width:22px; height:22px; border-radius:50%;
  border:2px solid var(--border2);
  display:flex; align-items:center; justify-content:center;
  font-size:10px; font-weight:400; color:var(--w50);
  flex-shrink:0; margin-top:1px;
}
.lp-step-item.active .lp-step-num {
  border-color:var(--yellow); color:#fff; background:rgba(255,187,0,0.15);
}
.lp-step-label {
  font-size:11px; font-weight:400; color:var(--w50);
  line-height:1.4; flex:1;
}
.lp-step-item.active .lp-step-label { color:#fff; font-weight:400; }

.lp-content-panel {
  flex:1; overflow-y:auto; padding:24px 28px;
  min-width:0;
}
.lp-content-panel::-webkit-scrollbar { width:4px; }
.lp-content-panel::-webkit-scrollbar-thumb { background:var(--border2); border-radius:2px; }

.lp-content-title {
  font-size:18px; font-weight:400; color:var(--w70);
  margin-bottom:4px; text-align:center;
}
.lp-content-sub {
  font-size:12px; color:var(--w30); font-family:var(--mono);
  text-align:center; margin-bottom:20px;
}
.lp-step-note {
  background:rgba(220,50,50,0.08); border:1px solid rgba(220,50,50,0.2);
  border-radius:7px; padding:10px 14px;
  font-size:11px; color:#ff8080; line-height:1.6;
  margin-bottom:16px; text-align:center;
}

/* LP field block */
.lp-field-block {
  margin-bottom:14px;
  background:var(--navy-2); border:1px solid var(--border);
  border-radius:8px; overflow:hidden;
  transition:border-color 0.2s;
}
.lp-field-block:focus-within { border-color:var(--yellow-b); }
.lp-field-block.synced { border-color:var(--green-b); }
.lp-field-block.error  { border-color:var(--red-b); }
.lp-field-label {
  font-size:12px; font-weight:400; color:var(--w70);
  padding:10px 14px 6px; line-height:1.4;
}
.lp-field-input-wrap { padding:0 14px 8px; }
.lp-field-input-wrap .field-input {
  background:rgba(255,255,255,0.04); border-radius:5px;
  padding:7px 10px; border:1px solid var(--border);
}
.lp-field-input-wrap .field-input:focus { outline:none; border-color:var(--yellow-b); }
.lp-field-footer {
  padding:6px 14px; background:rgba(0,0,0,0.1);
  border-top:1px solid var(--border);
  display:flex; justify-content:space-between; align-items:center;
}

/* Color picker */
.lp-color-row { display:flex; align-items:center; gap:10px; }
.lp-color-swatch {
  width:44px; height:34px; border-radius:5px; border:1px solid var(--border2);
  cursor:pointer; background:none; padding:2px;
}
.lp-color-hex { flex:1; }

/* Dropdown */
.lp-select {
  appearance:none; -webkit-appearance:none;
  background:rgba(255,255,255,0.04) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23ffffff50'/%3E%3C/svg%3E") no-repeat right 10px center;
  padding-right:28px; cursor:pointer;
}
.lp-select option { background:var(--navy-3); color:#fff; }

/* Upload zone */
.lp-upload-zone {
  border:1.5px dashed var(--border2); border-radius:7px;
  padding:14px; text-align:center; cursor:pointer;
  transition:border-color 0.2s;
}
.lp-upload-zone:hover { border-color:var(--yellow-b); }
.lp-upload-icon { font-size:22px; margin-bottom:4px; }
.lp-upload-text { font-size:12px; font-weight:400; color:var(--w70); }
.lp-upload-hint { font-size:10px; color:var(--w30); margin-top:3px; font-style:italic; }
.lp-upload-val  { font-size:10px; color:var(--green); margin-top:4px; font-family:var(--mono); }

/* Nav buttons */
.lp-nav-btns {
  display:flex; gap:10px; align-items:center;
  margin-top:20px; padding-top:16px;
  border-top:1px solid var(--border);
}
.lp-btn-back {
  background:transparent; border:1px solid var(--border2);
  border-radius:7px; padding:9px 18px;
  color:var(--w70); font-size:11px; font-weight:400;
  font-family:var(--font); cursor:pointer; transition:all 0.18s;
  letter-spacing:0.06em;
}
.lp-btn-back:hover { border-color:var(--w50); color:#fff; }
.lp-btn-save {
  background:linear-gradient(135deg,var(--yellow),var(--yellow-d));
  border:none; border-radius:7px; padding:9px 22px;
  color:var(--navy); font-weight:400; font-size:11px;
  letter-spacing:0.1em; text-transform:uppercase;
  font-family:var(--font); cursor:pointer; transition:all 0.18s;
}
.lp-btn-save:hover { transform:translateY(-1px); }
.lp-btn-next {
  background:transparent; border:1px solid var(--yellow-b);
  border-radius:7px; padding:9px 18px;
  color:var(--yellow); font-size:11px; font-weight:400;
  font-family:var(--font); cursor:pointer; transition:all 0.18s;
  letter-spacing:0.06em;
}
.lp-btn-next:hover { background:var(--yellow-m); }


/* ═══════════════════════════════════════
   NETWORK / MASTERCLASS SPLIT LAYOUT
═══════════════════════════════════════ */
.nlp-wrap {
  display:flex; flex-direction:column;
  margin:-24px -24px -60px;
  height:100vh;
  overflow:hidden;
  background:#01243D;
}
.nlp-header {
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 20px; border-bottom:1px solid rgba(255,255,255,0.08);
  background:#012952; flex-shrink:0;
}
.nlp-header-left { display:flex; align-items:center; gap:12px; }
.nlp-header-icon { font-size:22px; line-height:1; }
.nlp-header-title { font-size:15px; font-weight:400; color:rgba(255,255,255,0.90); }
.nlp-header-sub { font-size:11px; color:rgba(255,255,255,0.30); margin-top:2px; }
.nlp-split { flex:1; display:flex; overflow:hidden; }

/* Left nav panel */
.nlp-left {
  width:280px; min-width:260px; flex-shrink:0;
  background:#0a2d5a; border-right:1px solid rgba(255,255,255,0.08);
  display:flex; flex-direction:column; overflow:hidden;
}
.nlp-left-scroll {
  flex:1; overflow-y:auto; padding:10px 12px;
  display:flex; flex-direction:column; gap:6px;
  scrollbar-width:thin; scrollbar-color:rgba(255,255,255,0.15) transparent;
}
.nlp-left-scroll::-webkit-scrollbar { width:4px; }
.nlp-left-scroll::-webkit-scrollbar-thumb { background:rgba(255,255,255,0.15); border-radius:2px; }

/* Section groups */
.nlp-group { margin-bottom:2px; }
.nlp-group-header {
  display:flex; align-items:center; justify-content:space-between;
  padding:8px 10px; cursor:pointer; border-radius:6px;
  transition:background 0.15s; user-select:none;
}
.nlp-group-header:hover { background:rgba(255,255,255,0.04); }
.nlp-group-label {
  font-size:8px; font-weight:400; letter-spacing:0.14em;
  text-transform:uppercase; color:rgba(255,255,255,0.30);
}
.nlp-group-chevron { font-size:12px; color:rgba(255,255,255,0.30); transition:transform 0.2s; }
.nlp-group.open .nlp-group-chevron { transform:rotate(90deg); }
.nlp-group-cards { display:none; flex-direction:column; gap:4px; padding:0 0 6px; }
.nlp-group.open .nlp-group-cards { display:flex; }

/* Step cards */
.nlp-step-card {
  background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.08);
  border-radius:8px; padding:9px 12px; cursor:pointer;
  transition:border-color 0.15s, background 0.15s;
}
.nlp-step-card:hover { background:rgba(255,255,255,0.05); border-color:rgba(255,255,255,0.15); }
.nlp-step-card.active { border-color:rgba(255,187,0,0.40); background:rgba(255,187,0,0.10); }
.nlp-step-card.done { border-color:rgba(55,202,55,0.30); }
.nlp-step-card-top { display:flex; align-items:center; gap:8px; }
.nlp-step-num {
  width:18px; height:18px; border-radius:50%;
  border:1.5px solid rgba(255,255,255,0.15);
  display:flex; align-items:center; justify-content:center;
  font-size:9px; font-weight:400; color:rgba(255,255,255,0.30); flex-shrink:0;
}
.nlp-step-card.active .nlp-step-num { border-color:#FFBB00; color:#FFBB00; background:rgba(255,187,0,0.12); }
.nlp-step-card.done .nlp-step-num { border-color:#37CA37; color:#37CA37; }
.nlp-step-label { font-size:10px; font-weight:400; color:rgba(255,255,255,0.50); flex:1; line-height:1.3; }
.nlp-step-card.active .nlp-step-label { color:#fff; font-weight:400; }
.nlp-step-card.done .nlp-step-label { color:rgba(255,255,255,0.30); }
.nlp-step-badge {
  font-size:7px; font-weight:400; padding:2px 7px;
  border-radius:20px; margin-top:5px; margin-left:26px; display:inline-block;
}
.nlp-step-badge.empty { background:rgba(255,255,255,0.05); color:rgba(255,255,255,0.30); }
.nlp-step-badge.partial { background:rgba(255,187,0,0.12); color:#FFBB00; }
.nlp-step-badge.filled { background:rgba(55,202,55,0.12); color:#37CA37; }

/* Right content panel */
.nlp-right {
  flex:1; overflow-y:auto; padding:24px 28px; min-width:0;
  background:#01243D;
}
.nlp-right::-webkit-scrollbar { width:4px; }
.nlp-right::-webkit-scrollbar-thumb { background:rgba(255,255,255,0.15); border-radius:2px; }
.nlp-right-title {
  font-size:17px; font-weight:400; color:rgba(255,255,255,0.70);
  margin-bottom:4px; text-align:center;
}
.nlp-right-sub {
  font-size:11px; color:rgba(255,255,255,0.30); font-family:'JetBrains Mono',monospace;
  text-align:center; margin-bottom:20px;
}


/* ═══════════════════════════════════════
   LICENSE GATE
═══════════════════════════════════════ */
#license-gate {
  position:fixed; inset:0; z-index:99999;
  background:#f5f5f7;
  display:flex; align-items:center; justify-content:center;
  flex-direction:column; gap:0;
}
.lg-box {
  background:#ffffff;
  border:1px solid rgba(1,36,61,0.1);
  border-radius:16px; padding:36px 40px;
  width:100%; max-width:420px;
  display:flex; flex-direction:column; gap:18px;
  box-shadow:0 8px 40px rgba(1,36,61,0.10);
}
.lg-logo { display:flex; align-items:center; gap:12px; margin-bottom:4px; }
.lg-logo-icon { font-size:28px; }
.lg-logo-title { font-size:16px; font-weight:400; color:var(--navy); line-height:1.1; }
.lg-logo-sub { font-size:9px; color:var(--yellow); letter-spacing:0.18em; text-transform:uppercase; font-weight:400; margin-top:2px; }
.lg-heading { font-size:13px; font-weight:400; color:var(--navy); letter-spacing:0.06em; text-transform:uppercase; }
.lg-field { display:flex; flex-direction:column; gap:6px; }
.lg-field label { font-size:10px; font-weight:400; color:rgba(1,36,61,0.5); letter-spacing:0.08em; text-transform:uppercase; }
.lg-input-wrap { position:relative; display:flex; align-items:center; }
.lg-input-wrap .lg-input { padding-right:40px; }
.lg-input {
  flex:1; background:#f5f5f7; border:1px solid rgba(1,36,61,0.15);
  border-radius:8px; padding:10px 14px; color:var(--navy);
  font-size:13px; font-family:var(--font); outline:none;
  transition:border-color 0.2s; width:100%;
}
.lg-input:focus { border-color:var(--yellow); }
.lg-input::placeholder { color:rgba(1,36,61,0.3); }
.lg-eye { position:absolute; right:10px; background:none; border:none; color:rgba(1,36,61,0.30); cursor:pointer; padding:4px; display:flex; align-items:center; }
.lg-eye:hover { color:rgba(1,36,61,0.60); }
.lg-btn {
  background:linear-gradient(135deg, #ffe89a 0%, #ffd35a 30%, #f4ad1f 60%, #d78500 100%);
  color:#041626; border:none;
  border-radius:8px; padding:12px; font-size:12px;
  font-weight:600; font-family:var(--font); cursor:pointer;
  letter-spacing:0.08em; text-transform:uppercase;
  transition:all 0.2s; width:100%;
}
.lg-btn:hover { filter:brightness(1.05); transform:translateY(-1px); }
.lg-btn:disabled { opacity:0.5; cursor:wait; transform:none; filter:none; }
.lg-error { font-size:11px; color:var(--red); font-weight:400; display:none; min-height:16px; }
.lg-footer { font-size:9px; color:rgba(1,36,61,0.4); text-align:center; line-height:1.6; }
.lg-divider { border:none; border-top:1px solid rgba(1,36,61,0.08); margin:2px 0; }
/* Tier badge */
.tier-badge {
  display:inline-flex; align-items:center; gap:5px;
  padding:3px 10px; border-radius:20px; font-size:9px;
  font-weight:400; letter-spacing:0.1em; text-transform:uppercase;
}
.tier-basic  { background:rgba(21,138,246,0.15); color:var(--blue); border:1px solid var(--blue-b); }
.tier-pro    { background:rgba(255,187,0,0.12);  color:var(--yellow); border:1px solid var(--yellow-b); }
.tier-agency { background:rgba(55,202,55,0.12);  color:var(--green);  border:1px solid var(--green-b); }

/* Google OAuth button */
.lg-google-btn {
  display:flex; align-items:center; justify-content:center; gap:10px;
  width:100%; padding:11px; border-radius:8px;
  background:#f5f5f7; border:1px solid rgba(1,36,61,0.15);
  color:var(--navy); font-size:12px; font-weight:400; font-family:var(--font);
  cursor:pointer; transition:all 0.2s; letter-spacing:0.04em;
}
.lg-google-btn:hover { background:#EBF0F8; border-color:rgba(1,36,61,0.25); }
.lg-google-btn svg { flex-shrink:0; }
.lg-divider-or {
  display:flex; align-items:center; gap:10px;
  font-size:10px; color:rgba(1,36,61,0.35); margin:4px 0;
}
.lg-divider-or::before, .lg-divider-or::after {
  content:''; flex:1; height:1px; background:rgba(1,36,61,0.08);
}



/* ── Core Setup / GHL Checklist ─────────────────────── */
.cs-progress-pill {
  margin-left:auto; background:rgba(255,187,0,0.15);
  color:var(--yellow); border-radius:20px; padding:1px 7px;
  font-size:9px; font-weight:400;
}
.checklist-grid { display:flex; flex-direction:column; gap:8px; padding:0 0 40px; }
.checklist-item {
  background:rgba(255,255,255,0.03); border:1px solid var(--border);
  border-radius:10px; overflow:hidden; transition:border-color 0.2s;
}
.checklist-item.checked { border-color:var(--green-b); background:rgba(55,202,55,0.04); }
.checklist-item.expanded { border-color:var(--yellow-b); }
.checklist-item-header {
  display:flex; align-items:center; padding:12px 14px;
  cursor:pointer; gap:10px; justify-content:space-between;
}
.checklist-left { display:flex; align-items:center; gap:10px; flex:1; min-width:0; }
.checklist-checkbox {
  width:20px; height:20px; border-radius:5px; border:2px solid var(--border2);
  display:flex; align-items:center; justify-content:center;
  font-size:12px; font-weight:400; color:var(--green);
  flex-shrink:0; cursor:pointer; transition:all 0.15s;
}
.checklist-checkbox.done { background:var(--green); border-color:var(--green); color:#fff; }
.checklist-num { font-size:10px; color:var(--w30); font-weight:400; flex-shrink:0; width:16px; }
.checklist-text { min-width:0; }
.checklist-label { font-size:12px; font-weight:400; color:var(--w90); }
.checklist-sub { font-size:10px; color:var(--w50); }
.checklist-chevron { font-size:9px; color:var(--w30); flex-shrink:0; }
.checklist-body { padding:0 14px 14px 54px; border-top:1px solid var(--border); }
.checklist-desc { font-size:11px; color:var(--w60); line-height:1.6; margin:12px 0; }
.checklist-video-wrap {
  position:relative; width:100%; max-width:450px; overflow:hidden;
  border-radius:8px; margin-bottom:12px; background:#000; border:1px solid var(--border2);
}
.checklist-video-wrap iframe {
  display:block; width:100%; height:253px;
}
.checklist-actions { display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.checklist-link-btn {
  background:rgba(255,255,255,0.08); border:1px solid var(--border2);
  color:var(--w70); border-radius:6px; padding:7px 14px;
  font-size:10px; font-weight:400; font-family:var(--font);
  text-decoration:none; cursor:pointer; letter-spacing:0.04em;
  transition:all 0.2s;
}
.checklist-link-btn:hover { background:rgba(255,255,255,0.14); color:#fff; }
.checklist-done-btn {
  background:var(--green); color:#fff; border:none; border-radius:6px;
  padding:7px 14px; font-size:10px; font-weight:400; font-family:var(--font);
  cursor:pointer; letter-spacing:0.04em;
}
.checklist-complete-badge {
  font-size:10px; font-weight:400; color:var(--green);
}

/* ── Pricing Modal ─────────────────────────────────── */
#pricing-modal {
  position:fixed; inset:0; z-index:99998;
  background:rgba(1,36,61,0.5); backdrop-filter:blur(6px);
  display:none; align-items:center; justify-content:center; padding:20px;
}
#pricing-modal.open { display:flex; }
.pm-box {
  background: linear-gradient(180deg, #ffffff 0%, #fafbfd 100%);
  border: 1px solid rgba(1,36,61,0.08); border-radius:20px;
  padding:36px 32px; width:100%; max-width:600px;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.90),
    0 4px 6px -2px rgba(1,36,61,0.06),
    0 16px 40px -8px rgba(1,36,61,0.14),
    0 32px 64px -16px rgba(1,36,61,0.10);
}
.pm-header { text-align:center; margin-bottom:28px; }
.pm-title { font-size:20px; font-weight:400; color:#01243D; margin-bottom:6px; font-family:'Poppins',sans-serif; }
.pm-sub { font-size:13px; color:rgba(1,36,61,0.5); font-family:'Poppins',sans-serif; }
.pm-billing-toggle {
  display:flex; align-items:center; justify-content:center; gap:10px;
  margin-bottom:28px; font-family:'Poppins',sans-serif;
}
.pm-billing-toggle span { font-size:12px; font-weight:400; color:rgba(1,36,61,0.45); }
.pm-billing-toggle span.active { color:#01243D; }
.pm-toggle-track {
  width:44px; height:24px; background:rgba(1,36,61,0.1);
  border-radius:12px; position:relative; cursor:pointer;
  border:1px solid rgba(1,36,61,0.15); transition:background 0.2s;
}
.pm-toggle-track.annual { background:rgba(201,150,47,0.25); border-color:rgba(201,150,47,0.45); }
.pm-toggle-thumb {
  position:absolute; top:3px; left:3px; width:16px; height:16px;
  background:#01243D; border-radius:50%; transition:transform 0.2s;
}
.pm-toggle-track.annual .pm-toggle-thumb { transform:translateX(20px); }
.pm-save-badge {
  background:rgba(34,197,94,0.1); color:#15803d; border:1px solid rgba(34,197,94,0.3);
  border-radius:20px; padding:2px 8px; font-size:9px; font-weight:400; letter-spacing:0.06em;
}
/* AGENCY DISABLED - restore to re-enable agency sales
.pm-cards { display:grid; grid-template-columns:repeat(2,1fr); gap:16px; }
*/
.pm-cards { display:grid; grid-template-columns:minmax(0,320px); justify-content:center; gap:16px; }
@media(max-width:500px) { .pm-cards { grid-template-columns:1fr; } }
.pm-card {
  background:#f5f5f7; border:1px solid rgba(1,36,61,0.1);
  border-radius:14px; padding:24px 20px; display:flex; flex-direction:column; gap:14px;
  transition:border-color 0.2s;
}
.pm-card.featured {
  border-color:rgba(255,187,0,0.5); background:rgba(255,187,0,0.04);
}
.pm-card-badge {
  background:#FFBB00; color:#000; border-radius:20px;
  padding:2px 10px; font-size:9px; font-weight:400; letter-spacing:0.08em;
  align-self:flex-start; font-family:'Poppins',sans-serif;
}
.pm-card-name { font-size:15px; font-weight:400; color:#01243D; font-family:'Poppins',sans-serif; }
.pm-card-price { display:flex; align-items:baseline; gap:4px; }
.pm-card-price .amount { font-size:32px; font-weight:400; color:#01243D; font-family:'Poppins',sans-serif; }
.pm-card-price .period { font-size:12px; color:rgba(1,36,61,0.45); font-family:'Poppins',sans-serif; }
.pm-card-price .original { font-size:12px; color:rgba(1,36,61,0.3); text-decoration:line-through; margin-left:4px; }
.pm-card-desc { font-size:12px; color:rgba(1,36,61,0.55); line-height:1.6; font-family:'Poppins',sans-serif; }
.pm-card-features { display:flex; flex-direction:column; gap:8px; flex:1; }
.pm-card-feature { display:flex; align-items:center; gap:8px; font-size:12px; color:rgba(1,36,61,0.7); font-family:'Poppins',sans-serif; }
.pm-card-feature .check { color:#22c55e; font-size:13px; flex-shrink:0; }
.pm-card-feature .cross { color:rgba(1,36,61,0.25); font-size:13px; flex-shrink:0; }
.pm-card-btn {
  width:100%; padding:12px; border-radius:10px; border:none;
  font-size:12px; font-weight:400; font-family:'Poppins',sans-serif;
  cursor:pointer; letter-spacing:0.06em; text-transform:uppercase;
  transition:all 0.18s;
}
.pm-card-btn.primary {
  background: linear-gradient(135deg, #ffe89a 0%, #ffd35a 30%, #f4ad1f 60%, #d78500 100%);
  color: #041626; font-weight: 600; background-clip: padding-box;
}
.pm-card-btn.primary:hover {
  background: linear-gradient(135deg, #fff0b8 0%, #ffdc77 30%, #f7ba38 60%, #e89512 100%);
  transform: translateY(-1px);
}
.pm-card-btn.secondary { background:transparent; color:rgba(1,36,61,0.65); border:1.5px solid rgba(1,36,61,0.2); }
.pm-card-btn.secondary:hover { background:rgba(1,36,61,0.05); border-color:#01243D; color:#01243D; }
.pm-card-btn:disabled { opacity:0.5; cursor:wait; transform:none; }
.pm-card-btn.current { background:rgba(34,197,94,0.08); color:#15803d; border:1px solid rgba(34,197,94,0.25); cursor:default; }
.pm-close { position:absolute; top:16px; right:20px; background:none; border:none; color:rgba(1,36,61,0.3); font-size:20px; cursor:pointer; transition:color .15s; }
.pm-close:hover { color:#01243D; }
.pm-footer { text-align:center; margin-top:20px; font-size:11px; color:rgba(1,36,61,0.35); font-family:'Poppins',sans-serif; }

/* Locked tab overlay */
.tab-locked-overlay {
  position:absolute; inset:0; z-index:10;
  background:rgba(1,36,61,0.85); backdrop-filter:blur(2px);
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:10px; border-radius:4px;
}
.tab-locked-overlay .lock-msg { font-size:13px; font-weight:400; color:var(--w70); }
.tab-locked-overlay .lock-sub { font-size:11px; color:var(--w50); }
.tab-locked-overlay .lock-upgrade {
  background:var(--yellow); color:#000; border:none; border-radius:6px;
  padding:8px 18px; font-size:10px; font-weight:400; font-family:var(--font);
  cursor:pointer; letter-spacing:0.08em; text-transform:uppercase; margin-top:4px;
}

/* ═══════════════════════════════════════
   PHASE SIDEBAR ACCORDION
═══════════════════════════════════════ */
.phase-group { border-bottom:1px solid var(--border); }
.phase-header {
  display:flex; align-items:center; justify-content:space-between;
  padding:13px 16px;
  font-size:13px; font-weight:400; letter-spacing:0.14em;
  text-transform:uppercase; color:var(--w30);
  cursor:pointer; transition:color 0.15s;
  background:transparent; border:none;
  width:100%; font-family:var(--font);
}
.phase-header:hover { color:var(--w70); }
.phase-header.open { color:var(--yellow); }
.phase-header-left { display:flex; align-items:center; gap:9px; }
.phase-arrow { font-size:7px; transition:transform 0.2s; }
.phase-header.open .phase-arrow { transform:rotate(90deg); }
.phase-items { display:none; }
.phase-items.open { display:block; }
.phase-sub-item {
  width:100%; text-align:left;
  background:transparent; border:none;
  border-left:3px solid transparent;
  padding:9px 16px 9px 30px;
  font-family:var(--font); font-size:14px; font-weight:400;
  color:var(--w50); cursor:pointer;
  transition:all 0.15s;
  display:flex; align-items:center; justify-content:space-between;
  gap:8px;
}
.phase-sub-item:hover { background:var(--w15); color:var(--w90); }
.phase-sub-item.active { background:var(--yellow-m); border-left-color:var(--yellow); color:#fff; }
.phase-sub-item.locked { opacity:0.35; cursor:default; }

/* ═══════════════════════════════════════
   RIGHT PROGRESS PANEL
═══════════════════════════════════════ */
#right-panel {
  width:260px; min-width:260px;
  background:var(--navy-2);
  border-left:1px solid var(--border);
  display:flex; flex-direction:column;
  overflow-y:auto; flex-shrink:0;
}
#right-panel::-webkit-scrollbar { width:2px; }
#right-panel::-webkit-scrollbar-thumb { background:var(--border2); border-radius:1px; }
#right-panel-inner { padding:20px 16px; display:flex; flex-direction:column; gap:22px; height:100%; }

.rp-label {
  font-size:11px; font-weight:400; color:var(--w30);
  letter-spacing:0.2em; text-transform:uppercase; margin-bottom:14px;
}
.rp-phase-dots {
  display:flex; align-items:center; justify-content:space-between;
  position:relative; margin-bottom:18px;
}
.rp-phase-dots::before {
  content:''; position:absolute; top:16px; left:30px; right:30px;
  height:1px; background:var(--border2);
}
.rp-dot-wrap { display:flex; flex-direction:column; align-items:center; gap:6px; }
.rp-dot {
  width:32px; height:32px; border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  font-size:10px; font-weight:400;
  border:2px solid var(--border2);
  background:var(--navy); color:var(--w30);
  position:relative; z-index:1;
}
.rp-dot.active { background:var(--yellow); border-color:var(--yellow); color:#000; }
.rp-dot.done   { background:var(--green);  border-color:var(--green);  color:#fff; }
.rp-dot-label  { font-size:10px; font-weight:400; color:var(--w30); }
.rp-dot-label.active { color:var(--yellow); }

.rp-bar-row { margin-bottom:10px; }
.rp-bar-top { display:flex; justify-content:space-between; align-items:center; margin-bottom:5px; }
.rp-bar-name { font-size:15px; font-weight:400; color:var(--w70); }
.rp-bar-pct  { font-size:13px; font-weight:400; color:var(--w50); }
.rp-bar-track { height:4px; background:var(--w15); border-radius:2px; }
.rp-bar-fill  { height:100%; border-radius:2px; transition:width 0.4s; }

.rp-next-item {
  display:flex; align-items:center; gap:10px;
  padding:7px 0; border-bottom:1px solid var(--border);
  font-size:12px; color:var(--w70); line-height:1.4;
}
.rp-next-item:last-child { border-bottom:none; }
.rp-check {
  width:16px; height:16px; border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  flex-shrink:0; font-size:9px;
}
.rp-check.done    { background:var(--green); color:#fff; }
.rp-check.current { background:var(--yellow-m); border:1.5px solid var(--yellow); }
.rp-check.pending { background:var(--w15); border:1.5px solid var(--border2); }

.rp-ai-input {
  margin-top:auto;
  background:rgba(255,255,255,0.04);
  border:1px solid var(--border2); border-radius:9px;
  padding:10px 12px; display:flex; align-items:center; gap:8px;
}
.rp-ai-input input {
  flex:1; background:transparent; border:none; outline:none;
  font-family:var(--font); font-size:12px; color:var(--w70);
}
.rp-ai-input input::placeholder { color:var(--w30); }
.rp-ai-send {
  width:26px; height:26px; border-radius:5px;
  background:var(--yellow); border:none; cursor:pointer;
  display:flex; align-items:center; justify-content:center; flex-shrink:0;
}

/* ═══════════════════════════════════════
   LIGHT THEME — MAIN + RIGHT PANEL
═══════════════════════════════════════ */
#main {
  --navy:   #f5f5f7;
  --navy-2: #ffffff;
  --navy-3: #e4eaf2;
  --navy-4: #dde4ef;
  --border:  rgba(1,36,61,0.09);
  --border2: rgba(1,36,61,0.16);
  --w90: rgba(1,36,61,0.92);
  --w70: rgba(1,36,61,0.70);
  --w50: rgba(1,36,61,0.50);
  --w30: rgba(1,36,61,0.35);
  --w15: rgba(1,36,61,0.05);
  background: #f5f5f7;
}
#right-panel {
  --navy:   #f5f5f7;
  --navy-2: #ffffff;
  --navy-3: #e4eaf2;
  --border:  rgba(1,36,61,0.09);
  --border2: rgba(1,36,61,0.16);
  --w90: rgba(1,36,61,0.92);
  --w70: rgba(1,36,61,0.70);
  --w50: rgba(1,36,61,0.50);
  --w30: rgba(1,36,61,0.35);
  --w15: rgba(1,36,61,0.05);
  background: #ffffff;
  border-left: 1px solid rgba(1,36,61,0.08);
}

/* ═══════════════════════════════════════
   GLOSSY SIDEBAR — iOS STYLE
═══════════════════════════════════════ */
#sidebar {
  background: linear-gradient(175deg, #013a70 0%, #012952 40%, #01243D 100%);
  box-shadow: 2px 0 24px rgba(0,0,0,0.32), inset -1px 0 0 rgba(255,255,255,0.06);
  border-right: none;
}
.phase-header:hover { background: rgba(255,255,255,0.05); }
.phase-header.open {
  background: rgba(255,187,0,0.08);
  border-left: 3px solid var(--yellow);
}
#sidebar .phase-sub-item {
  border-radius: 8px;
  margin: 2px 8px;
  width: calc(100% - 16px);
  padding: 9px 10px 9px 14px;
  border-left: 3px solid transparent;
}
#sidebar .phase-sub-item.active {
  background: linear-gradient(135deg, rgba(255,187,0,0.2), rgba(255,187,0,0.08));
  border-left-color: var(--yellow);
  box-shadow: 0 2px 12px rgba(255,187,0,0.15), inset 0 1px 0 rgba(255,255,255,0.08);
  color: #fff;
}
#sidebar .phase-sub-item:hover:not(.locked) {
  background: rgba(255,255,255,0.07);
}
#sib-dashboard {
  margin: 8px 8px 2px !important;
  width: calc(100% - 16px) !important;
  border-radius: 8px !important;
}

/* ═══════════════════════════════════════
   GLOSSY DEPTH — iOS GLASS EFFECT
═══════════════════════════════════════ */

/* Sidebar glass depth */
#sidebar {
  background: linear-gradient(160deg,
    #0d3a6b 0%,
    #012952 35%,
    #01243D 70%,
    #001d32 100%
  );
  box-shadow:
    4px 0 32px rgba(0,0,0,0.45),
    inset -1px 0 0 rgba(255,255,255,0.07),
    inset 1px 0 0 rgba(255,255,255,0.03);
}

/* Top bar — white glossy */
#topnav {
  background: linear-gradient(180deg, #ffffff 0%, #f5f5f7 100%);
  box-shadow: 0 2px 16px rgba(1,36,61,0.10), inset 0 -1px 0 rgba(1,36,61,0.07);
  border-bottom: none;
}

/* Active phase header glow */
.phase-header.open {
  background: linear-gradient(135deg, rgba(255,187,0,0.14), rgba(255,187,0,0.04));
  color: var(--yellow);
  text-shadow: 0 0 20px rgba(255,187,0,0.4);
}

/* Active sub-item glow pill */
#sidebar .phase-sub-item.active {
  background: linear-gradient(135deg, rgba(255,187,0,0.22), rgba(255,187,0,0.06));
  box-shadow:
    0 2px 16px rgba(255,187,0,0.2),
    inset 0 1px 0 rgba(255,255,255,0.1);
  color: #fff;
  text-shadow: 0 1px 8px rgba(255,255,255,0.2);
}


/* Main content cards — elevated glass */
#main .field-card,
#main > div > div {
  border-radius: 14px;
}

/* Dashboard metric cards glass */
#page-content [style*="background:var(--navy-2)"] {
  background: #ffffff !important;
  box-shadow: 0 2px 16px rgba(1,36,61,0.08), 0 1px 4px rgba(1,36,61,0.05) !important;
  border: 0.5px solid rgba(1,36,61,0.08) !important;
  border-radius: 14px !important;
}

/* Quick start cards hover lift */
#page-content [style*="border-radius:10px"] {
  box-shadow: 0 2px 12px rgba(1,36,61,0.07);
  transition: box-shadow 0.2s, transform 0.2s !important;
}
#page-content [style*="border-radius:10px"]:hover {
  box-shadow: 0 8px 28px rgba(1,36,61,0.14) !important;
  transform: translateY(-2px) !important;
}

/* Right panel glass */
#right-panel {
  background: linear-gradient(180deg, #fafbfd 0%, #f5f7fb 100%) !important;
  box-shadow: -2px 0 20px rgba(1,36,61,0.07);
}

/* Progress bar track — soft */
.rp-bar-track {
  background: rgba(1,36,61,0.06);
  border-radius: 4px;
  height: 6px;
}
.rp-bar-fill { height: 6px; }

/* Phase dots — glass ring */
.rp-dot {
  box-shadow: 0 2px 8px rgba(0,0,0,0.15), inset 0 1px 0 rgba(255,255,255,0.1);
}
.rp-dot.active {
  box-shadow: 0 0 16px rgba(255,187,0,0.5), 0 2px 8px rgba(255,187,0,0.3);
}

/* ═══════════════════════════════════════
   SIDEBAR ROUNDED PILL CARDS — iOS STYLE
═══════════════════════════════════════ */



/* All sidebar items get padding + rounded pills */
#sidebar {
  padding: 8px 10px 16px;
}

/* Dashboard pill */
#sib-dashboard {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  width: 100% !important;
  margin: 4px 0 2px !important;
  padding: 12px 14px !important;
  border-radius: 12px !important;
  border-left: none !important;
  background: rgba(255,255,255,0.07) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.1), 0 2px 8px rgba(0,0,0,0.15) !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  color: var(--w70) !important;
  transition: all 0.18s !important;
}
#sib-dashboard:hover {
  background: rgba(255,255,255,0.11) !important;
  color: #fff !important;
}

/* Phase headers — pill style */
.phase-group {
  border-bottom: none;
  margin-bottom: 2px;
}
.phase-header {
  border-radius: 12px !important;
  padding: 12px 14px !important;
  background: rgba(255,255,255,0.05);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
  margin-bottom: 2px;
  font-size: 13px !important;
  letter-spacing: 0.06em !important;
}
.phase-header:hover {
  background: rgba(255,255,255,0.09) !important;
}
.phase-header.open {
  background: rgba(1,36,61,0.05) !important;
  box-shadow: none !important;
  color: #01243D !important;
  border-left: none !important;
}

/* Sub-items — pill style */
#sidebar .phase-sub-item {
  border-radius: 10px !important;
  border-left: none !important;
  margin: 2px 0 !important;
  width: 100% !important;
  padding: 9px 12px 9px 16px !important;
  background: transparent;
  font-size: 13px !important;
}
#sidebar .phase-sub-item:hover:not(.locked) {
  background: rgba(255,255,255,0.07) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08) !important;
}
#sidebar .phase-sub-item.active {
  background: rgba(1,36,61,0.07) !important;
  box-shadow: none !important;
  color: #01243D !important;
  border-left: none !important;
}

/* ═══════════════════════════════════════
   SIDEBAR FIXES
═══════════════════════════════════════ */

/* Dashboard — match size and uppercase to phase headers */
#sib-dashboard {
  font-size: 13px !important;
  font-weight: 400 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  padding: 12px 14px !important;
}

/* Dashboard — highlight on click same as phase items */
#sib-dashboard.active {
  background: rgba(1,36,61,0.07) !important;
  box-shadow: none !important;
  color: #01243D !important;
}

/* ═══════════════════════════════════════
   SIDEBAR FINAL FIXES
═══════════════════════════════════════ */



/* Dashboard button — match exact height/padding of phase headers */
#sib-dashboard {
  padding: 13px 14px !important;
  font-size: 11px !important;
  letter-spacing: 0.14em !important;
}

/* AI Coach — glass pill style, always visible (not just on hover) */
#sib-ai-coach {
  padding: 11px 14px !important;
  font-size: 11px !important;
  font-weight: 400 !important;
  letter-spacing: 0.06em !important;
  background: rgba(255,187,0,0.08) !important;
  border: 1px solid rgba(255,187,0,0.22) !important;
  border-radius: 8px !important;
  color: rgba(255,255,255,0.75) !important;
  box-shadow: 0 1px 8px rgba(255,187,0,0.08), inset 0 1px 0 rgba(255,255,255,0.06) !important;
  margin: 0 2px !important;
}
#sib-ai-coach:hover {
  background: rgba(255,187,0,0.16) !important;
  border-color: rgba(255,187,0,0.4) !important;
  color: #fff !important;
  box-shadow: 0 2px 14px rgba(255,187,0,0.18), inset 0 1px 0 rgba(255,255,255,0.10) !important;
}
#sib-ai-coach.active {
  background: linear-gradient(135deg, rgba(255,187,0,0.28), rgba(255,187,0,0.10)) !important;
  border-color: rgba(255,187,0,0.55) !important;
  color: #fff !important;
  box-shadow: 0 2px 18px rgba(255,187,0,0.25), inset 0 1px 0 rgba(255,255,255,0.14) !important;
}


/* ═══════════════════════════════════════
   RIGHT PANEL — PREMIUM CARD STYLE
═══════════════════════════════════════ */
#right-panel {
  background: #f5f5f7 !important;
  padding: 16px 14px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 12px !important;
  overflow-y: auto !important;
  border-left: none !important;
  box-shadow: -4px 0 20px rgba(1,36,61,0.06) !important;
}
#right-panel-inner {
  display: flex !important;
  flex-direction: column !important;
  gap: 12px !important;
  padding: 0 !important;
  height: auto !important;
}

/* ═══════════════════════════════════════
   RIGHT PANEL — FIX AI INPUT TO BOTTOM
═══════════════════════════════════════ */
#right-panel {
  height: 100vh;
}
#right-panel-inner {
  min-height: 100% !important;
  height: 100% !important;
}
#right-panel-inner > div:last-child {
  margin-top: auto !important;
}

/* ═══════════════════════════════════════
   SYNERGY PROFILE — DISPLAY-FIRST CARDS
═══════════════════════════════════════ */

/* Page header */
.syn-page-header { margin: -4px -24px 0; }
.syn-page-title  { font-size: 20px; font-weight: 400; color: #01243D; letter-spacing: -.02em; }
.syn-page-sub    { font-size: 12px; color: rgba(1,36,61,0.5); padding: 10px 24px 4px; }

/* ── Foundation group tabs (Identity / Audience / Offers / Operations) ── */
.syn-group-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(1,36,61,0.09);
  background: #ffffff;
  flex-shrink: 0;
}
.syn-group-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 8px;
  background: transparent;
  border: none;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 400;
  color: rgba(1,36,61,0.35);
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
}
.syn-group-tab:hover  { color: rgba(1,36,61,0.55); background: rgba(255,187,0,0.06); }
.syn-group-tab.active { color: #01243D; background: rgba(255,187,0,0.12); }

/* ── Foundation sub-tabs (Authority Profile / Branding / Voice etc.) ── */
.syn-subtabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(1,36,61,0.09);
  background: #ffffff;
  overflow-x: auto;
  flex-shrink: 0;
}
.syn-subtabs::-webkit-scrollbar { display: none; }
.syn-subtab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 8px;
  background: transparent;
  border: none;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 400;
  color: rgba(1,36,61,0.35);
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
}
.syn-subtab:hover  { color: rgba(1,36,61,0.55); background: rgba(1,36,61,0.04); }
.syn-subtab.active { color: #01243D; background: rgba(1,36,61,0.06); font-weight: 500; }

/* ── Completion dots on tabs ── */
.syn-gtab-dot         { width: 7px; height: 7px; border-radius: 50%; background: rgba(1,36,61,0.15); display: inline-block; flex-shrink: 0; }
.syn-gtab-dot.partial { background: #FFBB00; }
.syn-gtab-dot.done    { background: #37CA37; }

/* Card wrapper */
.syn-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(1,36,61,0.08);
  box-shadow: 0 1px 4px rgba(1,36,61,0.07), 0 2px 12px rgba(1,36,61,0.05);
  margin-bottom: 14px;
  transition: box-shadow .18s;
}
.syn-card:hover { box-shadow: 0 4px 20px rgba(1,36,61,0.11); }
.syn-card-body  { padding: 20px 22px; }
.syn-card-label { font-size: 9px; font-weight: 400; letter-spacing: .18em; color: rgba(1,36,61,0.4); text-transform: uppercase; margin-bottom: 5px; display:flex; align-items:center; justify-content:space-between; }
.syn-card-title { font-size: 15px; font-weight: 400; color: #01243D; margin-bottom: 4px; }
.syn-card-desc  { font-size: 11px; color: rgba(1,36,61,0.5); margin-bottom: 14px; line-height: 1.6; }

/* Two-column grid */
.syn-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
@media (max-width: 760px) { .syn-two-col { grid-template-columns: 1fr; } }

/* Display / Edit toggle */
.syn-edisp {
  font-size: 13px; color: #01243D !important; line-height: 1.8;
  cursor: pointer; white-space: pre-wrap; word-break: break-word;
  padding: 8px 0;
  border-radius: 6px;
  transition: opacity .15s;
}
.syn-edisp:hover { opacity: .8; }
em.syn-ph { color: rgba(1,36,61,0.3); font-style: italic; font-size: 12px; }
.syn-eedit { display: none; }

.syn-etxt {
  width: 100%; background: #fff;
  border: 1px solid rgba(1,36,61,0.20);
  border-radius: 9px; color: #01243D;
  font-family: var(--font); font-size: 12px;
  padding: 10px 13px; outline: none; resize: vertical;
  min-height: 70px; line-height: 1.65;
  transition: border-color .15s, box-shadow .15s;
}
.syn-etxt:focus { border-color: rgba(1,36,61,0.45); box-shadow: 0 0 0 3px rgba(1,36,61,0.06); }
.syn-einp {
  width: 100%; background: #fff;
  border: 1px solid rgba(1,36,61,0.20);
  border-radius: 9px; color: #01243D;
  font-family: var(--font); font-size: 12px;
  padding: 9px 13px; outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.syn-einp:focus { border-color: rgba(1,36,61,0.45); box-shadow: 0 0 0 3px rgba(1,36,61,0.06); }
.syn-eacts {
  display: flex; gap: 8px; margin-top: 8px; justify-content: flex-end;
}
.syn-e-save {
  background: linear-gradient(135deg, #ffe89a 0%, #ffd35a 30%, #f4ad1f 60%, #d78500 100%);
  color: #041626; font-weight: 600; border: none;
  border-radius: 7px; padding: 7px 18px;
  font-size: 11px; font-family: var(--font); cursor: pointer;
  transition: background .15s, transform .15s;
  background-clip: padding-box;
}
.syn-e-save:hover {
  background: linear-gradient(135deg, #fff0b8 0%, #ffdc77 30%, #f7ba38 60%, #e89512 100%);
  transform: translateY(-1px);
}
.syn-e-canc {
  background: #fff; border: 1px solid rgba(1,36,61,.18);
  border-radius: 7px; color: var(--w50);
  padding: 7px 14px; font-size: 11px; font-weight: 400;
  font-family: var(--font); cursor: pointer;
  transition: background .15s;
}
.syn-e-canc:hover { background: #f5f5f7; }

/* Card action buttons */
.syn-card-actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.syn-btn-edit {
  background: #fff; border: 1px solid rgba(1,36,61,.18);
  border-radius: 7px; color: var(--w50);
  font-size: 10px; font-weight: 400; font-family: var(--font);
  padding: 6px 13px; cursor: pointer; transition: all .15s;
}
.syn-btn-edit:hover { background: rgba(1,36,61,0.07); border-color: rgba(1,36,61,0.35); color: #01243D; }
.syn-btn-ai {
  background: rgba(1,36,61,.07); border: 1px solid rgba(1,36,61,.15);
  border-radius: 7px; color: #01243D;
  font-size: 10px; font-weight: 400; font-family: var(--font);
  padding: 6px 13px; cursor: pointer; transition: all .15s;
  display: inline-flex; align-items: center; gap: 5px;
}
.syn-btn-ai:hover { background: rgba(201,150,47,0.12); border-color: rgba(201,150,47,0.4); color: #7a5800; }
.syn-btn-sync {
  background: rgba(21,138,246,.08); border: 1px solid rgba(21,138,246,.25);
  border-radius: 7px; color: var(--blue);
  font-size: 10px; font-weight: 400; font-family: var(--font);
  padding: 6px 13px; cursor: pointer; transition: all .15s;
}
.syn-btn-sync:hover { background: var(--blue); color: #fff; }
.syn-btn-ai:disabled { opacity: .5; cursor: default; }
.syn-btn-ai:disabled:hover { background: rgba(1,36,61,.07); border-color: rgba(1,36,61,.15); color: #01243D; }

/* ── Synergy card — AI suggestion result block ── */
.syn-ai-result {
  display: none;
  margin-top: 12px;
  padding: 12px 14px;
  background: rgba(255,187,0,0.06);
  border: 1px solid rgba(255,187,0,0.40);
  border-radius: 8px;
  animation: syn-ai-fadein .2s ease;
}
.syn-ai-result.show { display: block; }
@keyframes syn-ai-fadein { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:none; } }
.syn-ai-result-header {
  font-size: 8.5px; font-weight: 400; letter-spacing: .14em;
  text-transform: uppercase; color: #b45309;
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 9px;
}
.syn-ai-result-text {
  font-size: 12px; color: #01243D;
  line-height: 1.65; font-family: var(--font);
  white-space: pre-wrap;
}
.btn-use-syn {
  background: rgba(255,187,0,0.14); border: 1px solid rgba(255,187,0,0.55);
  border-radius: 5px; padding: 4px 11px;
  color: #92400e; font-size: 8.5px; font-weight: 400;
  font-family: var(--font); letter-spacing: .07em;
  cursor: pointer; transition: all .15s; white-space: nowrap;
}
.btn-use-syn:hover { background: rgba(255,187,0,0.28); border-color: rgba(255,187,0,0.75); }

/* Hero card interactive */
.syn-hero-avatar-btn { position: relative; cursor: pointer; overflow: hidden; }
.syn-hero-avatar-overlay {
  position: absolute; inset: 0; border-radius: 11px;
  background: rgba(1,36,61,0.55); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; opacity: 0.3; transition: opacity .2s;
}
.syn-hero-avatar-btn.has-photo .syn-hero-avatar-overlay { opacity: 0; }
.syn-hero-avatar-btn:hover .syn-hero-avatar-overlay { opacity: 1; }

.syn-hero-editable { cursor: pointer; display: flex; align-items: center; gap: 6px; }
.hero-edit-hint {
  font-size: 10px; color: rgba(1,36,61,0.3);
  opacity: 0; transition: opacity .15s;
}
.syn-hero-editable:hover .hero-edit-hint { opacity: 1; }
.syn-hero-editable:hover { opacity: .8; }

/* Override var(--navy) which resolves to light grey inside #main */
.syn-hero-name { color: #01243D !important; }

.syn-hero-inline-edit {
  display: flex; align-items: center; gap: 6px; margin: 2px 0;
}
.syn-hero-inline-inp {
  border: 1.5px solid #01243D; border-radius: 6px;
  padding: 4px 10px; font-family: var(--font); font-size: 13px;
  font-weight: 400; color: #01243D; background: #fff; outline: none;
  min-width: 180px;
}
.syn-hero-inline-save {
  background: linear-gradient(135deg, #ffe89a 0%, #ffd35a 30%, #f4ad1f 60%, #d78500 100%);
  color: #041626; font-weight: 600; border: none;
  border-radius: 6px; padding: 4px 12px;
  font-size: 10px; font-family: var(--font); cursor: pointer;
  background-clip: padding-box;
}
.syn-hero-inline-cancel {
  background: transparent; color: rgba(1,36,61,0.4); border: none;
  font-size: 13px; cursor: pointer; padding: 2px 4px; line-height: 1;
}
.syn-hero-inline-cancel:hover { color: #01243D; }

/* Hero card */
.syn-hero-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(1,36,61,.08);
  box-shadow: 0 1px 4px rgba(1,36,61,.07), 0 2px 12px rgba(1,36,61,.05);
  overflow: hidden;
  margin-bottom: 16px;
}
.syn-hero-band {
  height: 4px;
  background: linear-gradient(90deg, var(--navy) 0%, #158AF6 50%, #FFBB00 100%);
}
.syn-hero-body { padding: 22px 22px 18px; }
.syn-hero-top  { display: flex; gap: 18px; align-items: flex-start; }
.syn-hero-avatar {
  width: 72px; height: 72px; border-radius: 14px;
  background: #f5f5f7; border: 3px solid #fff;
  box-shadow: 0 4px 14px rgba(1,36,61,.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; font-weight: 400; color: var(--navy);
  flex-shrink: 0;
}
.syn-hero-info { flex: 1; min-width: 0; }
.syn-hero-name { font-size: 20px; font-weight: 400; color: var(--navy); letter-spacing: -.02em; line-height: 1.15; }
.syn-hero-role { font-size: 12px; font-weight: 400; color: rgba(1,36,61,0.55); margin-top: 3px; }
.syn-hero-tagline {
  font-size: 12px; font-style: italic; color: #01243D;
  margin-top: 10px;
  border-left: 3px solid #FFBB00;
  padding: 6px 11px;
  background: rgba(255,187,0,.04);
  border-radius: 0 6px 6px 0;
  line-height: 1.5;
}
.syn-hero-foot {
  margin-top: 18px; padding-top: 14px;
  border-top: 1px solid rgba(1,36,61,.07);
  display: flex; align-items: center; gap: 12px;
}
.syn-hero-prog-wrap { flex: 1; }
.syn-hero-prog-bar {
  height: 4px; background: rgba(1,36,61,.08);
  border-radius: 2px; overflow: hidden;
}
.syn-hero-prog-fill {
  height: 100%; border-radius: 2px;
  background: linear-gradient(90deg, var(--navy), #158AF6);
  transition: width .4s;
}
.syn-hero-prog-lbl { font-size: 9px; color: rgba(1,36,61,0.4); margin-top: 4px; }
.syn-sync-all-btn {
  background: linear-gradient(135deg, #ffe89a 0%, #ffd35a 30%, #f4ad1f 60%, #d78500 100%);
  color: #041626; font-weight: 600; border: none;
  border-radius: 7px; padding: 8px 16px;
  font-size: 10px; font-family: var(--font);
  cursor: pointer; flex-shrink: 0;
  transition: background .15s, transform .15s;
  background-clip: padding-box;
}
.syn-sync-all-btn:hover {
  background: linear-gradient(135deg, #fff0b8 0%, #ffdc77 30%, #f7ba38 60%, #e89512 100%);
  transform: translateY(-1px);
}

/* Social grid */
.syn-social-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.syn-social-card {
  display: flex; align-items: center; gap: 10px;
  background: #f5f5f7; border: 1px solid rgba(1,36,61,.08);
  border-radius: 10px; padding: 10px 12px;
  transition: border-color .15s;
}
.syn-social-card:hover { border-color: rgba(1,36,61,.2); }
.syn-social-ico {
  width: 30px; height: 30px; border-radius: 7px;
  background: rgba(1,36,61,.06);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 400; color: #01243D; flex-shrink: 0;
}
.syn-social-name {
  font-size: 9px; font-weight: 400; color: rgba(1,36,61,0.4);
  text-transform: uppercase; letter-spacing: .07em; margin-bottom: 1px;
}
.syn-social-url {
  font-size: 11px; color: #01243D; font-weight: 400;
  cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-width: 130px;
}
.syn-social-url.empty { color: rgba(1,36,61,0.3); font-style: italic; font-weight: 400; }
.syn-s-edit {
  margin-left: auto; background: none; border: none;
  color: rgba(1,36,61,0.4); font-size: 11px; cursor: pointer;
  padding: 3px 5px; border-radius: 4px; transition: color .12s; flex-shrink: 0;
}
.syn-s-edit:hover { color: #01243D; }
@media (max-width: 600px) { .syn-social-grid { grid-template-columns: 1fr; } }
/* ═══════════════════════════════════════
   SYNERGY — IDEAL CLIENT COMPONENTS
═══════════════════════════════════════ */

/* Full-width card inside two-col grid */
.syn-full { grid-column: 1 / -1; }

/* Content text (pre-wrap body copy) */
.syn-content-text {
  font-size: 13px; color: #01243D !important; line-height: 1.8;
  white-space: pre-wrap; word-break: break-word;
}

/* KV list */
.syn-kv-list  { display: flex; flex-direction: column; gap: 11px; }
.syn-kv-row   { display: flex; gap: 14px; align-items: flex-start; }
.syn-kv-key   {
  font-size: 10px; font-weight: 400; text-transform: uppercase;
  letter-spacing: .08em; color: rgba(1,36,61,0.45);
  flex-shrink: 0; min-width: 110px; padding-top: 2px;
}
.syn-kv-val   { font-size: 13px; color: #01243D !important; line-height: 1.5; flex: 1; }

/* Tags */
.syn-tag-list { display: flex; flex-wrap: wrap; gap: 6px; }
.syn-tag {
  background: #f5f5f7; border: 1px solid rgba(1,36,61,.1);
  border-radius: 20px; padding: 3px 11px;
  font-size: 11px; font-weight: 400; color: #01243D;
}
.syn-tag-g { background: rgba(34,197,94,.10); border-color: rgba(34,197,94,.3); color: #15803d; }
.syn-tag-r { background: rgba(239,68,68,.08); border-color: rgba(239,68,68,.2); color: #b91c1c; }

/* Belief shift pairs */
.syn-bpair {
  display: flex; gap: 10px; align-items: stretch;
  margin-bottom: 10px;
}
.syn-bpair:last-child { margin-bottom: 0; }
.syn-b-old {
  flex: 1; padding: 10px 14px; border-radius: 9px;
  font-size: 12px; line-height: 1.5;
  background: #fff5f5; border: 1px solid #fecaca; color: #991b1b;
}
.syn-b-new {
  flex: 1; padding: 10px 14px; border-radius: 9px;
  font-size: 12px; line-height: 1.5;
  background: #f0fdf4; border: 1px solid #bbf7d0; color: #15803d;
}
.syn-b-arr {
  color: var(--w40); font-size: 16px;
  display: flex; align-items: center; flex-shrink: 0;
}
/* ═══════════════════════════════════════
   ECOSYSTEM DASHBOARD
═══════════════════════════════════════ */

/* Page-content no-padding mode for ecosystem */
#page-content.eco-fullbleed {
  padding: 0 !important;
  overflow: hidden;
  position: relative;
  height: 100%;
}

/* ── Levels ── */
.eco-level {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  background: #f5f5f7;
  transition: transform .44s cubic-bezier(.4,0,.2,1), opacity .44s cubic-bezier(.4,0,.2,1);
  will-change: transform, opacity;
}
.eco-hidden   { opacity: 0; pointer-events: none; transform: scale(.88); }
.eco-zoom-out { transform: scale(1.5); opacity: 0; pointer-events: none; }

/* ── Level header ── */
.eco-lh {
  height: 52px; padding: 0 18px;
  background: #fff; border-bottom: 1px solid #e2e8f0;
  display: flex; align-items: center; gap: 8px;
  flex-shrink: 0; flex-wrap: nowrap; overflow: hidden;
}
.eco-breadcrumb { display: flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 400; color: #8fa3b8; flex-shrink: 0; }
.eco-crumb { cursor: pointer; transition: color .12s; }
.eco-crumb:hover { color: #158AF6; }
.eco-current { font-size: 14px; color: #0f1f30; font-weight: 400; }
.eco-sep { opacity: .5; }
.eco-btn-back {
  /* Adopts the .jp-btn-ghost visual treatment while keeping the
     eco-header's compact sizing. Calm utility — same Ghost language
     used everywhere else (Cancel, Back, Refresh). */
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 30px; padding: 0 13px;
  background: transparent;
  border: 1px solid rgba(1,36,61,0.15);
  border-radius: 7px;
  color: #5a7184;
  font-size: 12px; font-weight: 500; font-family: var(--font);
  letter-spacing: -0.005em;
  cursor: pointer; flex-shrink: 0; user-select: none;
  transition:
    transform     280ms cubic-bezier(0.22, 1, 0.36, 1),
    background    var(--dur-fast) var(--ease-precision),
    border-color  var(--dur-fast) var(--ease-precision),
    color         var(--dur-fast) var(--ease-precision);
}
.eco-btn-back:hover {
  background: rgba(1,36,61,0.04);
  border-color: rgba(1,36,61,0.28);
  color: #01243D;
  transform: translate3d(0, -1px, 0);
}
.eco-btn-back:active { transform: translate3d(0, 1px, 0); }

.eco-btn-pri {
  /* Adopts the .jp-btn-primary visual treatment — the workhorse
     "Open Full Editor" action. Same machined-navy language as the
     rest of the SaaS Primary tier. */
  margin-left: auto;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 32px; padding: 0 16px;
  color: #fff;
  border: 1px solid transparent; border-radius: 8px;
  font-size: 12px; font-weight: 500; font-family: var(--font);
  letter-spacing: -0.005em;
  background:
    linear-gradient(180deg,
      rgba(255,255,255,0.07) 0%,
      rgba(255,255,255,0.00) 50%,
      rgba(0,0,0,0.10)       100%),
    linear-gradient(180deg, #013656 0%, #01243D 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.11),
    inset 0 -1px 0 rgba(0,0,0,0.22),
    0 1px 2px rgba(1,36,61,0.28),
    0 2px 6px -2px rgba(1,36,61,0.22);
  cursor: pointer; flex-shrink: 0; user-select: none;
  transition:
    transform   280ms cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow  420ms cubic-bezier(0.22, 1, 0.36, 1),
    background  var(--dur-fast) var(--ease-precision);
}
.eco-btn-pri:hover {
  background:
    linear-gradient(180deg,
      rgba(255,255,255,0.10) 0%,
      rgba(255,255,255,0.00) 50%,
      rgba(0,0,0,0.12)       100%),
    linear-gradient(180deg, #01415F 0%, #01253E 100%);
  transform: translate3d(0, -1px, 0);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.15),
    inset 0 -1px 0 rgba(0,0,0,0.24),
    0 3px 6px rgba(1,36,61,0.30),
    0 6px 14px -4px rgba(1,36,61,0.28);
}
.eco-btn-pri:active { transform: translate3d(0, 1px, 0); }
.eco-prw { display: flex; align-items: center; gap: 6px; font-size: 10px; font-weight: 400; color: #8fa3b8; }

/* ── View toggle ── */
.eco-view-toggle {
  display: flex; background: rgba(1,36,61,.05); border: 1px solid rgba(1,36,61,.09);
  border-radius: 9px; padding: 3px; gap: 2px; flex-shrink: 0;
}
.eco-vt-btn {
  padding: 5px 14px; border-radius: 7px;
  font-size: 11px; font-weight: 400; font-family: var(--font);
  border: none; cursor: pointer; transition: all .15s;
  background: transparent; color: rgba(1,36,61,.45); letter-spacing: 0.01em;
}
.eco-vt-on { background: #fff; color: #0f1f30; box-shadow: 0 1px 6px rgba(1,36,61,.12); }

/* ── Filter buttons ── */
.eco-filter-row { display: flex; align-items: center; gap: 5px; flex-shrink: 0; }
.eco-filter-btn {
  display: flex; align-items: center; gap: 5px;
  padding: 5px 12px; border-radius: 20px;
  border: 1.5px solid rgba(1,36,61,.12);
  font-size: 10.5px; font-weight: 400; font-family: var(--font);
  cursor: pointer; transition: all .16s; background: #fff;
  color: rgba(1,36,61,.55); letter-spacing: 0.01em;
}
.eco-filter-btn:hover { border-color: rgba(1,36,61,.25); color: rgba(1,36,61,.8); }
.eco-fd { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.eco-filter-on { color: #fff !important; border-color: transparent !important; }
.eco-filter-btn[data-cat="attract"].eco-filter-on { background: #16a34a; }
.eco-filter-btn[data-cat="engage"].eco-filter-on  { background: #2563eb; }
.eco-filter-btn[data-cat="convert"].eco-filter-on { background: #7c3aed; }
.eco-filter-btn[data-cat="operate"].eco-filter-on { background: #64748b; }

/* ── Map scroll area ── */
.eco-map-scroll { flex: 1; overflow: auto; padding: 16px 16px 20px; }
.eco-map-outer  { display: flex; gap: 0; width: 1042px; margin: 0 auto; }
.eco-map-labels { width: 28px; flex-shrink: 0; display: flex; flex-direction: column; }
.eco-vl {
  writing-mode: vertical-rl; transform: rotate(180deg);
  font-size: 8.5px; font-weight: 400; letter-spacing: 2.5px;
  text-transform: uppercase; display: flex;
  align-items: center; justify-content: center; user-select: none;
}
.eco-vl-op { height: 280px; color: #0891b2; background: rgba(8,145,178,.07); border-radius: 8px 0 0 0; }
.eco-vl-ss { flex: 1; color: #4a6079; background: rgba(1,36,61,.03); border-radius: 0 0 0 8px; }

.eco-map-wrap { position: relative; width: 1014px; height: 660px; flex-shrink: 0; margin: 10px auto 0; }
.eco-sec-bg   { position: absolute; left: 0; right: 0; pointer-events: none; border-radius: 0 12px 12px 0; }
.eco-sec-op   { top: 0; height: 292px; background: rgba(8,145,178,.035); border: 1px solid rgba(8,145,178,.12); border-left: none; }
.eco-sec-ss   { top: 308px; bottom: 0; background: rgba(1,36,61,.028); border: 1px solid rgba(1,36,61,.085); border-left: none; }
.eco-sec-div  { position: absolute; left: 0; right: 0; top: 300px; height: 1px; background: linear-gradient(to right,transparent,rgba(1,36,61,.12),transparent); pointer-events: none; }
.eco-map-svg  { position: absolute; top: 0; left: 0; width: 1014px; height: 660px; pointer-events: none; z-index: 1; }

/* ── Ecosystem nodes ── */
.eco-node {
  position: absolute; transform: translate(-50%,-50%);
  border-radius: 11px; border: 1.5px solid;
  padding: 10px 14px 9px; font-size: 11px; font-weight: 400;
  line-height: 1.34; text-align: center; white-space: normal;
  z-index: 2; user-select: none; box-sizing: border-box;
  transition: transform .18s, box-shadow .18s, opacity .3s, filter .3s;
}
.eco-node-primary  { font-size: 12px; font-weight: 400; padding: 11px 16px 10px; }
.eco-node-clickable { cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.eco-node-clickable:hover {
  transform: translate(-50%,-50%) translateY(-2px) scale(1.025);
  box-shadow: 0 6px 18px rgba(0,0,0,.14); z-index: 10;
}
.eco-dimmed { opacity: .1; filter: grayscale(1); }

@keyframes eco-pa { 0%,100%{box-shadow:0 0 0 0 rgba(22,163,74,.5),0 2px 8px rgba(0,0,0,.08)} 70%{box-shadow:0 0 0 10px rgba(22,163,74,0),0 2px 8px rgba(0,0,0,.08)} }
@keyframes eco-pc { 0%,100%{box-shadow:0 0 0 0 rgba(124,58,237,.5),0 2px 8px rgba(0,0,0,.08)} 70%{box-shadow:0 0 0 10px rgba(124,58,237,0),0 2px 8px rgba(0,0,0,.08)} }
.eco-pulse-a { animation: eco-pa 2.8s ease-out infinite; }
.eco-pulse-c { animation: eco-pc 2.8s ease-out 0.9s infinite; }

.eco-star-badge {
  position: absolute; top: -8px; right: -8px;
  width: 18px; height: 18px; border-radius: 999px;
  background: #FFBB00; display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 400; color: #01243D; box-shadow: 0 2px 6px rgba(0,0,0,.16);
}

/* ── Column view ── */
.eco-col-view { flex: 1; overflow: auto; padding: 16px; }
.eco-col-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; max-width: 1020px; margin: 0 auto; }
.eco-col-panel { background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; overflow: hidden; }
.eco-col-head  { padding: 11px 16px; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid #e2e8f0; font-size: 10px; font-weight: 400; letter-spacing: 2.5px; text-transform: uppercase; }
.eco-col-attract { background: rgba(22,163,74,.08);  color: #16a34a; }
.eco-col-engage  { background: rgba(37,99,235,.08);  color: #2563eb; }
.eco-col-convert { background: rgba(124,58,237,.08); color: #7c3aed; }
.eco-col-operate { background: rgba(100,116,139,.08);color: #64748b; }
.eco-col-node    { display: flex; align-items: center; gap: 10px; padding: 9px 14px; border-bottom: 1px solid #e2e8f0; transition: background .12s; }
.eco-col-node:last-child { border-bottom: none; }
.eco-col-clk { cursor: pointer; }
.eco-col-clk:hover { background: #f5f5f7; }
.eco-cni { width: 29px; height: 29px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.eco-cnl { font-size: 11px; font-weight: 400; color: #0f1f30; }
.eco-cns { font-size: 9.5px; color: #8fa3b8; margin-top: 1px; }
.eco-cnb { font-size: 9px; font-weight: 400; padding: 2px 7px; border-radius: 20px; flex-shrink: 0; }
.eco-bl  { background: rgba(22,163,74,.12);  color: #16a34a; }
.eco-bs  { background: rgba(100,116,139,.1); color: #8fa3b8; }
.eco-bn  { background: rgba(255,187,0,.15);  color: #b45309; }

/* ── L2 Blueprint Overview ──
   Three-column layout (Pages / Automation / Delivery Email). Fills the
   page vertically — cards stretch to occupy available height rather
   than floating near the top. Sidebar landing for Lead Magnet routes
   through this view first (see renderLMOverview()). */
.eco-bp-area  {
  flex: 1; overflow: auto;
  padding: 28px 36px 36px;
  display: flex; gap: 22px;
  align-items: stretch;
  min-height: 0;
}
.eco-bp-card  {
  background: #fff;
  border: 1px solid rgba(1, 36, 61, 0.07);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.04),
    0 4px 14px -6px rgba(1, 36, 61, 0.08);
}
.eco-bp-head  {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(1, 36, 61, 0.06);
  display: flex; align-items: center; gap: 11px;
  background: linear-gradient(180deg,
    rgba(1, 36, 61, 0.018) 0%,
    rgba(255, 255, 255, 0) 100%);
  flex-shrink: 0;
}
.eco-bp-icon  { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0; }
.eco-bp-title { font-size: 13.5px; font-weight: 500; color: #01243D; letter-spacing: -0.005em; }
.eco-bp-sub   { font-size: 11px; font-weight: 400; color: #8fa3b8; margin-top: 2px; }

/* Pages column — fixed width to keep the landing-page previews readable */
.eco-pg-panel { width: 280px; flex-shrink: 0; }
.eco-ptile    {
  margin: 14px;
  border: 1px solid rgba(1, 36, 61, 0.08);
  border-radius: 10px;
  overflow: hidden; cursor: pointer;
  transition:
    transform     280ms cubic-bezier(0.22, 1, 0.36, 1),
    border-color  var(--dur-fast) var(--ease-precision),
    box-shadow    420ms cubic-bezier(0.22, 1, 0.36, 1);
}
.eco-ptile:hover {
  border-color: var(--accent-interactive);
  box-shadow: 0 6px 18px -8px rgba(31, 140, 239, 0.35);
  transform: translate3d(0, -2px, 0);
}
.eco-pprev    { height: 100px; display: flex; align-items: center; justify-content: center; padding: 8px; }
.eco-ptf      { padding: 10px 13px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid rgba(1, 36, 61, 0.06); }
.eco-ptfl     { font-size: 11.5px; font-weight: 500; color: #01243D; }
.eco-ptfs     { font-size: 10px; color: #8fa3b8; margin-top: 2px; font-family: var(--font); }
.eco-ptfe     { font-size: 10.5px; font-weight: 500; color: var(--accent-interactive); }

/* Automation column — fixed width; the step list reads as a flow */
.eco-au-panel { width: 340px; flex-shrink: 0; }
.eco-au-step  { display: flex; align-items: flex-start; gap: 10px; padding: 11px 18px; border-bottom: 1px solid rgba(1, 36, 61, 0.05); transition: background var(--dur-fast) var(--ease-precision); }
.eco-au-step:last-child { border-bottom: none; }
.eco-au-clk   { cursor: pointer; }
.eco-au-clk:hover { background: rgba(31, 140, 239, 0.04); }
.eco-asi  { width: 28px; height: 28px; border-radius: 7px; display: flex; align-items: center; justify-content: center; font-size: 13px; flex-shrink: 0; margin-top: 1px; }
.eco-asl  { font-size: 12px; font-weight: 500; color: #01243D; line-height: 1.35; }
.eco-au-clk .eco-asl { color: var(--accent-interactive); }
.eco-ass  { font-size: 10.5px; color: #8fa3b8; margin-top: 2px; line-height: 1.4; }
.eco-asa  { font-size: 10px; color: var(--accent-interactive); margin-left: auto; flex-shrink: 0; font-weight: 500; }
.eco-aconn{ width: 1px; height: 14px; background: rgba(1, 36, 61, 0.08); margin: 0 18px 0 32px; }

/* Delivery Email column — flexes to fill remaining space so the preview
   has room to breathe on wider viewports */
.eco-em-panel { flex: 1; min-width: 320px; }
.eco-emb  {
  margin: 16px;
  border: 1px solid rgba(1, 36, 61, 0.06);
  border-radius: 9px;
  background: #f5f5f7;
  padding: 18px 20px;
  font-size: 12px; line-height: 1.75;
  color: #4a6079;
  flex: 1;
}
.eco-emsubj { font-size: 12px; font-weight: 500; color: #01243D; padding-bottom: 12px; margin-bottom: 12px; border-bottom: 1px solid rgba(1, 36, 61, 0.06); }
.eco-ecv  { color: var(--accent-interactive); }
.eco-elnk { color: var(--accent-interactive); font-weight: 500; text-decoration: underline; }

/* Edit Email Content button — adopts .jp-btn-primary visual treatment */
.eco-em-cta {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  margin: 0 16px 16px;
  width: calc(100% - 32px);
  height: 38px; padding: 0 18px;
  color: #fff;
  border: 1px solid transparent; border-radius: 9px;
  font-size: 13px; font-weight: 500; font-family: var(--font);
  letter-spacing: -0.005em;
  background:
    linear-gradient(180deg,
      rgba(255,255,255,0.07) 0%,
      rgba(255,255,255,0.00) 50%,
      rgba(0,0,0,0.10)       100%),
    linear-gradient(180deg, #013656 0%, #01243D 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.11),
    inset 0 -1px 0 rgba(0,0,0,0.22),
    0 1px 2px rgba(1,36,61,0.28),
    0 2px 6px -2px rgba(1,36,61,0.22);
  cursor: pointer; user-select: none;
  transition:
    transform   280ms cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow  420ms cubic-bezier(0.22, 1, 0.36, 1),
    background  var(--dur-fast) var(--ease-precision);
}
.eco-em-cta:hover {
  background:
    linear-gradient(180deg,
      rgba(255,255,255,0.10) 0%,
      rgba(255,255,255,0.00) 50%,
      rgba(0,0,0,0.12)       100%),
    linear-gradient(180deg, #01415F 0%, #01253E 100%);
  transform: translate3d(0, -1px, 0);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.15),
    inset 0 -1px 0 rgba(0,0,0,0.24),
    0 3px 6px rgba(1,36,61,0.30),
    0 6px 14px -4px rgba(1,36,61,0.28);
}
.eco-em-cta:active { transform: translate3d(0, 1px, 0); }

@media (prefers-reduced-motion: reduce) {
  .eco-btn-back, .eco-btn-pri, .eco-em-cta, .eco-ptile { transition: none; }
  .eco-btn-back:hover, .eco-btn-pri:hover, .eco-em-cta:hover,
  .eco-ptile:hover { transform: none; }
}

/* ── L3 Editor ── */
.eco-ed-stage { flex: 1; display: flex; align-items: center; justify-content: center; }
.eco-ed-card  { background: #fff; border: 1px solid #e2e8f0; border-radius: 18px; padding: 44px 48px; text-align: center; max-width: 440px; box-shadow: 0 8px 40px rgba(1,36,61,.1); }
.eco-ed-emoji { font-size: 52px; margin-bottom: 16px; display: block; }
.eco-ed-title { font-size: 20px; font-weight: 400; color: #0f1f30; margin-bottom: 8px; }
.eco-ed-desc  { font-size: 12px; color: #4a6079; line-height: 1.65; }
.eco-ed-cta   { display: inline-block; margin-top: 24px; padding: 11px 28px; background: #16a34a; color: #fff; border: none; border-radius: 9px; font-size: 12px; font-weight: 400; font-family: var(--font); cursor: pointer; }

/* ── Tooltip & Toast ── */
.eco-tooltip {
  position: fixed; background: #01243D; color: #fff;
  padding: 5px 11px; border-radius: 7px; font-size: 11px; font-weight: 400;
  font-family: var(--font); pointer-events: none; z-index: 9999;
  opacity: 0; transition: opacity .15s; white-space: nowrap;
  box-shadow: 0 3px 12px rgba(0,0,0,.25);
}
.eco-tip-on { opacity: 1; }
.eco-toast {
  position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%) translateY(12px);
  background: #01243D; color: #fff; padding: 10px 22px; border-radius: 10px;
  font-size: 12px; font-weight: 400; font-family: var(--font);
  pointer-events: none; z-index: 9998;
  opacity: 0; transition: opacity .2s, transform .2s;
  box-shadow: 0 4px 24px rgba(0,0,0,.3);
}
.eco-toast-on { opacity: 1; transform: translateX(-50%) translateY(0); }
/* ════════════════════════════════════════
   SYNERGY REDESIGN — New component styles
════════════════════════════════════════ */

/* Hero: name row + badge + companies + stats */
.syn-hero-name-row { display:flex;align-items:center;gap:8px; }
.syn-hero-badge { width:20px;height:20px;background:var(--blue,#158AF6);border-radius:50%;display:inline-flex;align-items:center;justify-content:center;font-size:10px;color:#fff;font-weight:400;flex-shrink:0; }
.syn-hero-companies { font-size:11px;color:rgba(1,36,61,0.5);margin-top:3px;font-weight:400; }
.syn-hero-stats { display:flex;background:var(--page,#f5f5f7);border-radius:10px;border:1px solid rgba(1,36,61,0.08);overflow:hidden;align-self:flex-start;margin-left:auto;flex-shrink:0; }
.syn-hero-stat { text-align:center;padding:12px 18px;border-right:1px solid rgba(1,36,61,0.08);cursor:pointer;transition:background .15s; }
.syn-hero-stat:last-child { border-right:none; }
.syn-hero-stat:hover { background:rgba(1,36,61,0.04); }
.syn-hero-stat-val { font-size:17px;font-weight:400;color:#01243D;line-height:1.1; }
.syn-hero-stat-lbl { font-size:8px;font-weight:400;color:rgba(1,36,61,0.45);text-transform:uppercase;letter-spacing:.11em;margin-top:2px; }

/* Bio tabs */
.syn-bio-tabs { display:flex;gap:0;background:rgba(1,36,61,0.05);border-radius:8px;padding:3px;width:fit-content;border:1px solid rgba(1,36,61,0.08);margin-bottom:14px; }
.syn-bio-tab { padding:5px 14px;border-radius:6px;border:none;background:none;font-size:10px;font-weight:400;font-family:var(--font);color:rgba(1,36,61,0.5);cursor:pointer;transition:all .15s; }
.syn-bio-tab.active { background:#fff;color:#01243D;box-shadow:0 1px 4px rgba(0,0,0,0.08); }

/* Identity table */
.syn-idt-table { display:grid;grid-template-columns:auto 1fr;gap:10px 20px;align-items:baseline;margin-bottom:8px; }
.syn-idt-key { font-size:9px;font-weight:400;letter-spacing:.12em;color:rgba(1,36,61,0.4);text-transform:uppercase;white-space:nowrap; }
.syn-idt-val { font-size:13px;color:#01243D;line-height:1.5;font-weight:400; }

/* Social link tiles */
.syn-link-grid { display:grid;grid-template-columns:1fr 1fr;gap:9px; }
@media (max-width:600px) { .syn-link-grid { grid-template-columns:1fr; } }
.syn-link-tile { display:flex;align-items:center;gap:11px;background:rgba(1,36,61,0.03);border:1px solid rgba(1,36,61,0.07);border-radius:10px;padding:11px 13px;transition:border-color .15s; }
.syn-link-tile:hover { border-color:rgba(1,36,61,0.18); }
.syn-link-ico { width:30px;height:30px;border-radius:7px;background:rgba(1,36,61,0.07);display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:400;flex-shrink:0; }
.syn-link-name { font-size:9px;font-weight:400;letter-spacing:.1em;text-transform:uppercase;color:rgba(1,36,61,0.45);margin-bottom:2px; }
.syn-link-val { font-size:11px;color:#01243D;font-weight:400;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px;cursor:pointer; }
.syn-link-val.empty { color:rgba(1,36,61,0.35);font-style:italic;font-weight:400; }
.syn-link-edit { margin-left:auto;background:none;border:none;color:rgba(1,36,61,0.3);cursor:pointer;font-size:12px;padding:3px 5px;border-radius:4px;transition:color .12s;flex-shrink:0; }
.syn-link-edit:hover { color:#01243D; }
.syn-link-actions { display:flex;align-items:center;gap:4px;margin-left:auto;flex-shrink:0; }
.syn-link-copy {
  background: rgba(255,187,0,0.12);
  border: 1px solid rgba(255,187,0,0.3);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 10px;
  font-weight: 400;
  color: #b45309;
  cursor: pointer;
  font-family: var(--font);
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.syn-link-copy:hover { background: rgba(255,187,0,0.22); border-color: rgba(255,187,0,0.5); }
.syn-link-copy.copied { background: rgba(55,202,55,0.12); border-color: rgba(55,202,55,0.3); color: #16a34a; }

/* Copy toast */
#jp-copy-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: #01243D;
  color: #fff;
  font-size: 12px;
  font-weight: 400;
  font-family: var(--font);
  padding: 9px 18px;
  border-radius: 20px;
  box-shadow: 0 4px 16px rgba(1,36,61,0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s, transform 0.18s;
  z-index: 9999;
  white-space: nowrap;
}
#jp-copy-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Voice trait tags */
.syn-voice-tags { display:flex;flex-wrap:wrap;gap:6px;margin-bottom:10px; }
.syn-voice-tag { padding:4px 12px;border-radius:20px;background:rgba(255,187,0,0.12);border:1px solid rgba(255,187,0,0.4);color:#92400e;font-size:11px;font-weight:400; }

/* Offer ladder */
.syn-offer-list { display:flex;flex-direction:column;gap:0; }
.syn-offer-item { padding:14px 16px;border:1px solid rgba(1,36,61,0.07);border-radius:10px;margin-bottom:8px;background:rgba(1,36,61,0.02);cursor:pointer;transition:border-color .15s; }
.syn-offer-item:last-child { margin-bottom:0; }
.syn-offer-item:hover { border-color:rgba(1,36,61,0.18); }
.syn-offer-head { display:flex;align-items:center;gap:8px;margin-bottom:3px; }
.syn-offer-name { font-size:13px;font-weight:400;color:#01243D; }
.syn-offer-badge { font-size:8px;font-weight:400;letter-spacing:.1em;text-transform:uppercase;padding:2px 7px;border-radius:10px; }
.syn-offer-badge-free { background:rgba(34,197,94,0.1);color:#15803d;border:1px solid rgba(34,197,94,0.25); }
.syn-offer-badge-flagship { background:rgba(255,187,0,0.1);color:#92400e;border:1px solid rgba(255,187,0,0.35); }
.syn-offer-price { font-size:11px;font-weight:400;color:#158AF6;margin-bottom:4px; }
.syn-offer-desc { font-size:11px;color:rgba(1,36,61,0.55);line-height:1.5; }

/* Proof testimonial list */
.syn-proof-list { display:flex;flex-direction:column;gap:8px; }
.syn-proof-item { background:rgba(1,36,61,0.02);border:1px solid rgba(1,36,61,0.07);border-left:4px solid #FFBB00;border-radius:0 10px 10px 0;padding:12px 16px; }
.syn-proof-result { font-size:13px;font-weight:400;color:#01243D;margin-bottom:3px; }
.syn-proof-attr { font-size:10px;color:rgba(1,36,61,0.5);line-height:1.4; }

/* Contact icon rows */
.syn-contact-list { display:flex;flex-direction:column;gap:0;margin-bottom:14px; }
.syn-contact-row { display:flex;align-items:flex-start;gap:11px;padding:9px 0;border-bottom:1px solid rgba(1,36,61,0.07);cursor:pointer; }
.syn-contact-row:last-child { border-bottom:none; }
.syn-contact-ico { font-size:14px;width:22px;text-align:center;flex-shrink:0;margin-top:1px; }
.syn-contact-val { font-size:12px;color:#01243D;font-weight:400;flex:1;min-width:0; }

/* Notifications table */
.syn-notif-table { display:grid;grid-template-columns:auto 1fr;gap:10px 20px;align-items:baseline;margin-bottom:12px; }
.syn-notif-key { font-size:9px;font-weight:400;letter-spacing:.12em;color:rgba(1,36,61,0.4);text-transform:uppercase;white-space:nowrap; }
.syn-notif-val { font-size:13px;color:#01243D;font-weight:400; }
.syn-notif-yes { display:inline-block;padding:3px 10px;background:rgba(34,197,94,0.1);color:#15803d;border:1px solid rgba(34,197,94,0.3);border-radius:20px;font-size:11px;font-weight:400; }

/* ═══════════════════════════════════════
   SETTINGS SIDEBAR
═══════════════════════════════════════ */

/* Main nav wrapper — flex:1 so it fills space, pushing settings btn to bottom */
#sidebar-main-nav {
  display:flex; flex-direction:column; flex:1;
}

/* Settings nav wrapper — same flex:1 treatment when visible */
#sidebar-settings-nav {
  flex-direction:column; flex:1;
}

/* ← Back button — matches phase-header style */
.settings-nav-back {
  display:flex; align-items:center; gap:8px;
  width:100%; text-align:left;
  background:transparent; border:none;
  border-bottom:1px solid rgba(255,255,255,0.06);
  padding:13px 16px;
  font-family:var(--font); font-size:11px; font-weight:400;
  letter-spacing:0.08em; text-transform:uppercase;
  color:var(--w30); cursor:pointer;
  transition:color 0.15s, background 0.15s;
  flex-shrink:0;
}
.settings-nav-back:hover { background:rgba(255,255,255,0.05); color:var(--w70); }

/* "SETTINGS" section label */
.settings-nav-label {
  padding:12px 16px 4px;
  font-size:8px; font-weight:400; letter-spacing:0.26em;
  color:var(--w30); text-transform:uppercase;
  flex-shrink:0;
}

/* Nav items — glass pill style matching #sidebar .phase-sub-item */
.settings-nav-item {
  border-radius:8px;
  margin:2px 8px;
  width:calc(100% - 16px);
  text-align:left;
  background:transparent; border:none;
  border-left:3px solid transparent;
  padding:9px 10px 9px 14px;
  font-family:var(--font); font-size:13px; font-weight:400;
  color:var(--w50); cursor:pointer;
  transition:all 0.15s;
  display:flex; align-items:center; gap:9px;
  flex-shrink:0;
}
.settings-nav-item:hover {
  background:rgba(255,255,255,0.07); color:var(--w90);
}
.settings-nav-item.active {
  background:linear-gradient(135deg, rgba(255,187,0,0.22), rgba(255,187,0,0.06));
  border-left-color:var(--yellow);
  box-shadow:0 2px 16px rgba(255,187,0,0.2), inset 0 1px 0 rgba(255,255,255,0.10);
  color:#fff;
  text-shadow:0 1px 8px rgba(255,255,255,0.2);
}
.settings-nav-item svg { flex-shrink:0; opacity:0.7; }
.settings-nav-item.active svg { opacity:1; }

/* ⚙ Settings button pinned to sidebar bottom — glass pill like #sib-dashboard */
#sidebar-settings-btn {
  border-radius:8px;
  margin:auto 8px 8px;
  width:calc(100% - 16px);
  text-align:left;
  background:transparent; border:none;
  border-left:3px solid transparent;
  padding:9px 10px 9px 14px;
  font-family:var(--font); font-size:13px; font-weight:400;
  color:var(--w50); cursor:pointer;
  transition:all 0.15s;
  display:flex; align-items:center; gap:9px;
  flex-shrink:0;
}
#sidebar-settings-btn:hover {
  background:rgba(255,255,255,0.07); color:var(--w90);
}
#sidebar-settings-btn svg { flex-shrink:0; opacity:0.7; }

/* ═══════════════════════════════════════
   SPLASH / LOADING SCREEN
═══════════════════════════════════════ */
#splash-screen {
  position:fixed; inset:0; z-index:999999;
  background: #f5f5f7;
  display:flex; flex-direction:column;
  align-items:center; justify-content:center; gap:28px;
  opacity:1; transition:opacity 0.35s ease;
}
#splash-screen.splash-hide { opacity:0; pointer-events:none; }

.splash-logo {
  max-width:200px; width:100%; height:auto;
  opacity:0; animation:splashFadeIn 0.5s ease 0.1s forwards;
}

.splash-spinner {
  width:36px; height:36px; border-radius:50%;
  border:3px solid rgba(255,187,0,0.20);
  border-top-color:#FFBB00;
  animation:splashSpin 0.75s linear infinite;
  opacity:0; animation:splashSpin 0.75s linear infinite, splashFadeIn 0.5s ease 0.3s forwards;
}

.splash-label {
  font-family:'Montserrat',sans-serif;
  font-size:11px; font-weight:400; letter-spacing:0.16em;
  text-transform:uppercase; color:rgba(255,255,255,0.30);
  opacity:0; animation:splashFadeIn 0.5s ease 0.4s forwards;
}

@keyframes splashFadeIn { to { opacity:1; } }
@keyframes splashSpin   { to { transform:rotate(360deg); } }

/* ═══════════════════════════════════════
   RIGHT PANEL COLLAPSE
═══════════════════════════════════════ */

/* Smooth width transition on the panel */
#right-panel { transition: width 0.28s cubic-bezier(0.4,0,0.2,1) !important; overflow-y: hidden !important; }

/* Toggle button — expanded state: small icon in top-right corner */
#rp-toggle {
  align-self: flex-end;
  flex-shrink: 0;
  width: 26px; height: 26px;
  border-radius: 7px;
  background: rgba(1,36,61,0.05);
  border: 1px solid rgba(1,36,61,0.10);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; padding: 0; outline: none;
  color: rgba(1,36,61,0.38);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  margin-bottom: 10px;
}
#rp-toggle:hover {
  background: rgba(1,36,61,0.09);
  border-color: rgba(1,36,61,0.22);
  color: #01243D;
}

/* Collapsed state — 28px visible strip, solid background */
#right-panel.rp-collapsed {
  width: 28px !important;
  min-width: 28px !important;
  overflow: hidden !important;
  padding: 0 !important;
  gap: 0 !important;
  background: #e8edf2 !important;
  box-shadow: -2px 0 8px rgba(1,36,61,0.08) !important;
  cursor: pointer;
}
#right-panel.rp-collapsed #right-panel-inner {
  opacity: 0;
  pointer-events: none;
}
/* Button becomes full-height clickable strip when collapsed */
#right-panel.rp-collapsed #rp-toggle {
  align-self: stretch !important;
  width: 28px !important;
  height: 100% !important;
  border-radius: 0 !important;
  border: none !important;
  border-left: 2px solid rgba(1,36,61,0.18) !important;
  margin: 0 !important;
  background: transparent !important;
  color: rgba(1,36,61,0.45) !important;
  justify-content: center !important;
}
#right-panel.rp-collapsed #rp-toggle:hover {
  background: rgba(1,36,61,0.08) !important;
  color: rgba(1,36,61,0.75) !important;
}
/* ═══════════════════════════════════════
   BRANDING — COLOR PICKERS & FONT INPUTS
═══════════════════════════════════════ */
.bc-grid { display:flex; flex-direction:column; gap:14px; margin:18px 0 4px; }

.bc-row  { display:flex; flex-direction:column; gap:5px; }
.bc-lbl  { font-size:10px; font-weight:400; text-transform:uppercase;
           letter-spacing:0.09em; color:rgba(1,36,61,0.45); }

.bc-pick { display:flex; align-items:center; gap:10px; }

.bc-swatch {
  width:52px; height:38px; flex-shrink:0; border-radius:9px; position:relative;
  border:1.5px solid rgba(1,36,61,0.14); cursor:pointer;
  transition:transform .15s, box-shadow .15s;
}
.bc-swatch:hover { transform:scale(1.06); box-shadow:0 4px 12px rgba(0,0,0,.14); }

.bc-hex {
  flex:1; height:38px; border:1.5px solid rgba(1,36,61,0.14); border-radius:9px;
  padding:0 12px; font-family:var(--font); font-size:13px; font-weight:400;
  color:#01243D; outline:none; background:#fff; transition:border-color .15s;
}
.bc-hex:focus { border-color:rgba(1,36,61,0.4); }

.bc-sync-btn {
  height:34px; padding:0 11px; font-size:10px; white-space:nowrap; flex-shrink:0;
}

/* ── Font inputs ── */
.bc-font-grid { display:flex; flex-direction:column; gap:22px; margin-top:18px; }
.bc-font-row  { display:flex; flex-direction:column; gap:6px; }
.bc-font-lbl  { font-size:10px; font-weight:400; text-transform:uppercase;
                letter-spacing:0.09em; color:rgba(1,36,61,0.45); }
.bc-font-inp  {
  width:100%; height:42px; border:1.5px solid rgba(1,36,61,0.14); border-radius:9px;
  padding:0 14px; font-family:var(--font); font-size:13px; color:#01243D; outline:none;
  box-sizing:border-box; transition:border-color .15s; background:#fff;
}
.bc-font-inp:focus { border-color:rgba(1,36,61,0.4); }
.bc-font-acts { display:flex; gap:8px; flex-wrap:wrap; margin-top:2px; }
/* ── Belief pairs ── */
.beliefs-grid { display:flex; flex-direction:column; gap:10px; margin:16px 0 4px; }
.belief-row   { display:flex; align-items:center; gap:10px; }
.belief-inp   { flex:1; height:42px; border:1.5px solid; border-radius:9px; padding:0 14px; font-family:var(--font); font-size:13px; outline:none; box-sizing:border-box; transition:border-color .15s; }
.belief-old   { border-color:rgba(220,38,38,0.28); background:rgba(220,38,38,0.04); color:#991b1b; }
.belief-old::placeholder { color:rgba(153,27,27,0.35); }
.belief-old:focus { border-color:rgba(220,38,38,0.55); }
.belief-new   { border-color:rgba(22,163,74,0.28); background:rgba(22,163,74,0.04); color:#166534; }
.belief-new::placeholder { color:rgba(22,100,52,0.35); }
.belief-new:focus { border-color:rgba(22,163,74,0.55); }
.belief-arrow { font-size:18px; color:rgba(1,36,61,0.25); flex-shrink:0; }

/* ── Proof result rows ── */
.proof-grid     { display:flex; flex-direction:column; gap:10px; margin:16px 0 4px; }
.proof-row      { display:flex; align-items:center; gap:10px; }
.proof-num      { width:22px; height:22px; border-radius:50%; background:rgba(1,36,61,0.08);
                  color:rgba(1,36,61,0.5); font-size:10px; font-weight:400; display:flex;
                  align-items:center; justify-content:center; flex-shrink:0; }
.proof-inp      { flex:1; height:42px; border:1.5px solid rgba(1,36,61,0.14); border-radius:9px;
                  padding:0 14px; font-family:var(--font); font-size:13px; color:#01243D;
                  outline:none; box-sizing:border-box; transition:border-color .15s; background:#fff; }
.proof-inp:focus { border-color:rgba(1,36,61,0.4); }
.proof-inp::placeholder { color:rgba(1,36,61,0.3); }
.proof-sync-btn { height:34px; padding:0 11px; font-size:10px; white-space:nowrap; flex-shrink:0; }

/* ── Brand colors display mode ── */
.bc-display-grid { display:flex; flex-direction:column; gap:10px; margin:14px 0 4px; }
.bc-disp-row     { display:flex; align-items:center; gap:12px; }
.bc-disp-swatch  { width:40px; height:40px; border-radius:8px; flex-shrink:0; border:1.5px solid rgba(1,36,61,0.12); }
.bc-disp-info    { display:flex; flex-direction:column; gap:2px; }
.bc-disp-lbl     { font-size:10px; font-weight:400; text-transform:uppercase; letter-spacing:0.09em; color:rgba(1,36,61,0.45); }
.bc-disp-hex     { font-size:13px; font-weight:400; color:#01243D; font-family:monospace; }

/* ── Font display icon ── */
.bc-font-icon { width:40px; height:40px; border-radius:8px; flex-shrink:0;
  background:rgba(1,36,61,0.07); border:1.5px solid rgba(1,36,61,0.12);
  display:flex; align-items:center; justify-content:center;
  font-size:14px; font-weight:400; color:rgba(1,36,61,0.45); }
.eco-imgmap-tip { color: #6B7280 !important; }
.eco-imgmap-wrap, .eco-imgmap-legend { color: #374151 !important; }
/* ── Back button hover fix ───────────────────── */
.dash-map-backbtn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 14px;
  background: transparent;
  border: 1px solid rgba(1,36,61,0.2);
  border-radius: 7px;
  font-family: var(--font); font-size: 11px; font-weight: 400;
  color: #01243D !important;
  cursor: pointer; letter-spacing: 0.03em; transition: all 0.15s;
}
.dash-map-backbtn:hover {
  background: #01243D !important;
  color: #fff !important;
  border-color: #01243D !important;
}
.dash-map-backbar {
  display: flex; align-items: center; gap: 14px;
  padding: 10px 24px;
  background: #fff;
  border-bottom: 1px solid rgba(1,36,61,0.08);
  flex-shrink: 0; position: relative; z-index: 10;
}
.dash-map-backtitle {
  font-size: 13px; font-weight: 400;
  color: #374151 !important;
}
/* ── Ecosystem image map ─────────────────────── */
.eco-imgmap-wrap {
  display: flex; flex-direction: column; align-items: center;
  padding: 16px 16px 24px; overflow-y: auto; flex: 1;
  background: #f5f5f7;
}
.eco-imgmap-img {
  max-width: 100%; height: auto; border-radius: 10px;
  box-shadow: 0 4px 24px rgba(1,36,61,0.12);
  cursor: crosshair; display: block;
}
.eco-imgmap-legend {
  margin-top: 18px; display: flex; flex-direction: column;
  align-items: center; gap: 10px;
}
.eco-imgmap-nodes {
  display: flex; gap: 10px; flex-wrap: wrap; justify-content: center;
}
.eco-imgmap-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px;
  background: #fff;
  border: 1px solid rgba(1,36,61,0.15);
  border-radius: 8px;
  font-family: var(--font); font-size: 12px; font-weight: 400;
  color: #01243D !important;
  cursor: pointer; transition: all 0.15s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.eco-imgmap-btn:hover {
  background: #01243D !important;
  color: #fff !important;
  border-color: #01243D !important;
  transform: translateY(-1px);
}
/* ═══════════════════════════════════════
   DASHBOARD 3.0
═══════════════════════════════════════ */
.dash-wrap {
  max-width: 100%;
  margin: 0;
  padding: 0 32px 40px;
  font-family: var(--font);
}

/* Header */
.dash-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
}
.dash-title {
  font-size: 26px;
  font-weight: 400;
  color: #01243D;
}
.dash-subtitle {
  font-size: 14px;
  color: #64748b;
  margin-top: 4px;
}
.dash-eco-btn {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 400;
  color: #01243D;
  cursor: pointer;
  font-family: var(--font);
  white-space: nowrap;
  flex-shrink: 0;
  transition: border-color .15s;
}
.dash-eco-btn:hover { border-color: #01243D; }

/* Top row layout */
.dash-top-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}

/* Cards */
.dash-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 24px;
}
.dash-card-right {
  border-top: 3px solid #FFBB00;
  display: flex;
  flex-direction: column;
}

/* Section labels */
.dash-section-label {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: .08em;
  color: #94a3b8;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.dash-systems-label { margin-bottom: 12px; }

/* Progress bars */
.dash-prog-row { margin-bottom: 14px; }
.dash-prog-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
}
.dash-prog-name { font-size: 13px; font-weight: 400; color: #1e293b; }
.dash-prog-pct  { font-size: 13px; color: #64748b; }
.dash-prog-track {
  height: 6px;
  background: #f5f5f7;
  border-radius: 99px;
  overflow: hidden;
}
.dash-prog-fill {
  height: 100%;
  border-radius: 99px;
  transition: width .6s ease;
}
.dash-prog-gold  { background: linear-gradient(90deg,#FFBB00,#e6a800); }
.dash-prog-blue  { background: linear-gradient(90deg,#158AF6,#0d6ecc); }
.dash-prog-green { background: linear-gradient(90deg,#37CA37,#28a028); }

/* Divider */
.dash-divider {
  height: 1px;
  background: #f5f5f7;
  margin: 18px 0 16px;
}

/* Checklist */
.dash-checklist { display: flex; flex-direction: column; gap: 2px; }
.dash-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background .12s;
}
.dash-check-item:hover { background: #f5f5f7; }
.dash-check-active { background: #fffbeb !important; }
.dash-check-dot {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  flex-shrink: 0;
  transition: border-color .15s, background .15s;
}
.dash-dot-done   { background: #FFBB00; border-color: #FFBB00; }
.dash-dot-active { border-color: #FFBB00; border-width: 2px; background: rgba(255,187,0,.15); }
.dash-check-label {
  font-size: 13px;
  color: #334155;
  font-weight: 400;
}
.dash-check-active .dash-check-label { font-weight: 400; color: #01243D; }

/* Focus Now card */
.dash-focus-icon {
  display: flex;
  align-items: center;
  margin: 8px 0 14px;
  width: 36px;
  height: 36px;
}
.dash-focus-phase {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: .08em;
  color: #FFBB00;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.dash-focus-title {
  font-size: 20px;
  font-weight: 400;
  color: #01243D;
  margin-bottom: 12px;
  line-height: 1.25;
}
.dash-focus-desc {
  font-size: 14px;
  color: #64748b;
  line-height: 1.6;
  flex: 1;
}
.dash-continue-btn {
  margin-top: 24px;
  background: #FFBB00;
  color: #01243D;
  border: none;
  border-radius: 8px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 400;
  font-family: var(--font);
  cursor: pointer;
  align-self: flex-start;
  transition: background .15s;
}
.dash-continue-btn:hover { background: #e6a800; }

/* Launchpad tiles */
.dash-lp-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.dash-lp-tile {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dash-lp-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  margin-bottom: 8px;
}
.dash-lp-name {
  font-size: 15px;
  font-weight: 400;
  color: #01243D;
}
.dash-lp-status {
  font-size: 12px;
  color: #94a3b8;
  margin-bottom: 4px;
}
.dash-lp-divider {
  height: 1px;
  background: #f5f5f7;
  margin: 12px 0 8px;
}
.dash-lp-link {
  background: none;
  border: none;
  color: #a36500;
  font-size: 13px;
  font-weight: 500;
  font-family: var(--font);
  cursor: pointer;
  padding: 0;
  text-align: left;
  transition: color .12s;
}
.dash-lp-link:hover { color: #7d4d00; }

/* ═══════════════════════════════════════
   PHASE 3 — LAUNCHPAD READINESS
═══════════════════════════════════════ */
.dash-lp-tile {
  position: relative;
  cursor: pointer;
  transition: box-shadow 0.18s, border-color 0.18s;
}
.dash-lp-tile:hover { box-shadow: 0 4px 20px rgba(1,36,61,0.1); }
.dash-lp-tile.ready-green  { border-color: rgba(55,202,55,0.35); }
.dash-lp-tile.ready-yellow { border-color: rgba(255,187,0,0.4); }
.dash-lp-tile.ready-red    { border-color: rgba(220,38,38,0.25); }

/* Traffic light badge */
.lp-ready-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.04em;
  font-family: var(--font);
  margin-bottom: 10px;
}
.lp-ready-badge.green  { background: rgba(55,202,55,0.12);  color: #16a34a; }
.lp-ready-badge.yellow { background: rgba(255,187,0,0.15);  color: #b45309; }
.lp-ready-badge.red    { background: rgba(220,38,38,0.10);  color: #dc2626; }
.lp-ready-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.green  .lp-ready-dot  { background: #37CA37; }
.yellow .lp-ready-dot  { background: #FFBB00; }
.red    .lp-ready-dot  { background: #dc2626; }

/* Checklist button */
.lp-checklist-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 400;
  font-family: var(--font);
  cursor: pointer;
  padding: 0;
  text-align: left;
  margin-top: 2px;
  transition: color 0.12s;
}
.lp-checklist-btn:hover { color: #01243D; }

/* Readiness checklist modal */
.lp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(1,36,61,0.45);
  z-index: 8000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.lp-modal {
  background: #fff;
  border-radius: 18px;
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 24px 64px rgba(1,36,61,0.28);
}
.lp-modal-head {
  padding: 22px 24px 16px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  background: #fff;
  border-radius: 18px 18px 0 0;
}
.lp-modal-title {
  font-size: 16px;
  font-weight: 400;
  color: #01243D;
}
.lp-modal-sub {
  font-size: 11px;
  color: #94a3b8;
  margin-top: 2px;
}
.lp-modal-close {
  background: none;
  border: none;
  font-size: 20px;
  color: #94a3b8;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
}
.lp-modal-close:hover { color: #01243D; }
.lp-modal-body { padding: 16px 24px 24px; }
.lp-modal-group { margin-bottom: 20px; }
.lp-modal-group-label {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 10px;
}
.lp-check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 9px;
  margin-bottom: 4px;
  cursor: pointer;
  transition: background 0.12s;
  text-decoration: none;
}
.lp-check-row:hover { background: #f5f5f7; }
.lp-check-icon {
  width: 20px; height: 20px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 10px;
}
.lp-check-icon.done   { background: rgba(55,202,55,0.15); color: #16a34a; font-weight: 400; }
.lp-check-icon.miss   { background: rgba(220,38,38,0.10); color: #dc2626; font-size: 14px; font-weight: 400; }
.lp-check-icon.opt    { background: rgba(255,187,0,0.12); color: #b45309; font-size: 14px; }
.lp-check-text { font-size: 12px; font-weight: 400; color: #01243D; flex: 1; }
.lp-check-text.done-text { color: #94a3b8; text-decoration: line-through; font-weight: 400; }
.lp-check-go {
  font-size: 10px;
  color: #158AF6;
  font-weight: 400;
  white-space: nowrap;
  flex-shrink: 0;
}
.lp-modal-launch-btn {
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg,#37CA37,#22a522);
  border: none;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 400;
  color: #fff;
  cursor: pointer;
  font-family: var(--font);
  margin-top: 8px;
  transition: opacity 0.15s;
}
.lp-modal-launch-btn:hover { opacity: 0.88; }
.lp-modal-launch-btn.not-ready {
  background: #f5f5f7;
  color: #94a3b8;
  cursor: default;
}
.lp-modal-launch-btn.not-ready:hover { opacity: 1; }

/* Override page-content background for dashboard */
#page-content:not(.eco-fullbleed) {
  background: #f5f5f7;
}
/* ═══════════════════════════════════════
   SYNERGY CARD STATUS DOTS
═══════════════════════════════════════ */
.syn-card-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.syn-card-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-left: 8px;
}
.syn-card-dot.filled  { background: #37CA37; }
.syn-card-dot.empty   { background: #cbd5e1; }
.syn-card-dot.partial { background: #FFBB00; }

/* ═══════════════════════════════════════
   PHASE 2 — TOOLTIP SYSTEM
═══════════════════════════════════════ */
.jp-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.jp-tip-btn {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #FFBB00;
  border: none;
  font-size: 9px;
  font-weight: 400;
  color: #000;
  cursor: default;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  flex-shrink: 0;
  font-family: var(--font);
  transition: opacity 0.15s;
}
.jp-tip-btn:hover { opacity: 0.8; }
.jp-tip-popup {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: auto;
  background: #01243D;
  color: #fff;
  font-size: 11px;
  font-weight: 400;
  line-height: 1.55;
  padding: 9px 12px;
  border-radius: 9px;
  width: 210px;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
  z-index: 9999;
  font-family: var(--font);
  box-shadow: 0 4px 16px rgba(1,36,61,0.25);
}
.jp-tip-popup::after {
  content: '';
  position: absolute;
  bottom: 100%;
  right: 6px;
  left: auto;
  transform: none;
  border: 5px solid transparent;
  border-bottom-color: #01243D;
}
.jp-tip:hover .jp-tip-popup { opacity: 1; }

/* ═══════════════════════════════════════
   PHASE 2 — WHAT'S NEXT CTA
═══════════════════════════════════════ */
.whats-next-cta {
  margin: 20px 0 4px;
  background: linear-gradient(135deg, rgba(255,187,0,0.07), rgba(255,187,0,0.03));
  border: 1px solid rgba(255,187,0,0.28);
  border-radius: 14px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.whats-next-left { flex: 1; min-width: 0; }
.whats-next-eyebrow {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: #cc9600;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.whats-next-label {
  font-size: 13px;
  font-weight: 400;
  color: var(--navy);
}
.whats-next-sub {
  font-size: 11px;
  color: var(--w50);
  margin-top: 2px;
  line-height: 1.5;
}
.whats-next-btn {
  background: linear-gradient(135deg,#FFBB00,#e6a800);
  border: none;
  border-radius: 9px;
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 400;
  color: #000;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  font-family: var(--font);
  box-shadow: 0 2px 10px rgba(255,187,0,0.3);
  transition: opacity 0.15s;
}
.whats-next-btn:hover { opacity: 0.88; }

/* ═══════════════════════════════════════
   PHASE 2 — SECTION EMPTY STATE
═══════════════════════════════════════ */
.syn-empty-state {
  background: #f5f5f7;
  border: 1.5px dashed rgba(1,36,61,0.13);
  border-radius: 14px;
  padding: 28px 24px;
  text-align: center;
  margin-bottom: 20px;
}
.syn-empty-icon { font-size: 30px; margin-bottom: 10px; }
.syn-empty-title {
  font-size: 14px;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 6px;
}
.syn-empty-desc {
  font-size: 12px;
  color: var(--w50);
  line-height: 1.65;
  max-width: 340px;
  margin: 0 auto 16px;
}
.syn-empty-btn {
  background: linear-gradient(135deg,#01243D,#1B3A6B);
  color: #fff;
  border: none;
  border-radius: 9px;
  padding: 10px 20px;
  font-size: 12px;
  font-weight: 400;
  cursor: pointer;
  font-family: var(--font);
  transition: opacity 0.15s;
}
.syn-empty-btn:hover { opacity: 0.88; }
/* ═══════════════════════════════════════
   CLEAN SIDEBAR — FLAT DEFAULT STATE
   Default = transparent. Glass only on
   hover and active page.
═══════════════════════════════════════ */

/* Strip all default backgrounds and shadows */
#sib-dashboard,
#sib-ai-coach,
.phase-header,
#sidebar .phase-sub-item {
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
}

/* Hover — single subtle highlight */
#sib-dashboard:hover,
#sib-ai-coach:hover,
.phase-header:hover,
#sidebar .phase-sub-item:hover:not(.locked) {
  background: rgba(255,255,255,0.07) !important;
  box-shadow: none !important;
}

/* Active / current page — yellow border, neutral gray background */
#sib-dashboard.active,
#sidebar .phase-sub-item.active {
  background: rgba(1,36,61,0.07) !important;
  border-left: 3px solid #FFBB00 !important;
  box-shadow: none !important;
  color: #01243D !important;
}

/* Phase header open state — yellow left border too */
.phase-header.open {
  border-left: 3px solid #FFBB00 !important;
  background: rgba(1,36,61,0.05) !important;
  box-shadow: none !important;
  color: #01243D !important;
}

/* Normal capitalized text — no uppercase */
#sib-dashboard,
#sib-ai-coach,
.phase-header {
  text-transform: none !important;
  letter-spacing: 0.01em !important;
  font-size: 14px !important;
  font-weight: 400 !important;
}

/* ═══════════════════════════════════════
   DARK SIDEBAR — PREMIUM NAVY GRADIENT
   Replaces the prior WHITE SIDEBAR override. Targets only the
   left rail. Everything outside #sidebar stays on the light theme.
═══════════════════════════════════════ */

/* Sidebar background — cinematic operator surface in brand-light range.
   Premium depth without going near-black at the top (which crushed the
   wordmark and gave the rail a "punished" feel).

   Layers:
     1. Soft warm-blue light source upper-center — subtle atmosphere
     2. Base linear: stays in the brand range (#004a75 at top) then
        gently deepens toward the bottom for grounding
   Edge work:
     - Strong outer drop separates the rail from the light content area
     - Inset top highlight — "lit from above"
     - Inset right edge — faint cool illumination */
#sidebar {
  background:
    radial-gradient(ellipse 100% 55% at 50% 18%, rgba(90, 160, 210, 0.16) 0%, transparent 70%),
    linear-gradient(180deg,
      #004a75 0%,
      #00456e 32%,
      #003c61 68%,
      #003252 100%
    ) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.05) !important;
  box-shadow:
    6px 0 48px rgba(0, 12, 24, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    inset -1px 0 0 rgba(140, 190, 240, 0.08) !important;
  padding: 0 8px 16px !important;
}

/* Both the wordmark (jp-sidebar-logo-v3.png) and the collapsed icon
   (index-icon.png) are pre-white assets — no default filter needed.
   index-branding.js re-applies a brightness(0) flatten when an agency
   configures a light sidebar so they stay readable on bright surfaces. */

/* Scrollbar */
#sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12) !important; }

/* Dashboard button — operator-grade hover/active */
#sib-dashboard {
  color: rgba(255,255,255,0.65) !important;
  background: transparent !important;
  box-shadow: none !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
#sib-dashboard:hover {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.95) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.10) !important;
}
#sib-dashboard.active {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.10) 0%,
    rgba(255,255,255,0.03) 100%) !important;
  border-left: 2px solid #C9962F !important;
  color: #ffffff !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    inset 0 -1px 0 rgba(0,0,0,0.20),
    0 1px 3px rgba(0,0,0,0.20) !important;
}

/* AI Coach */
#sib-ai-coach {
  color: rgba(255,255,255,0.65) !important;
  background: transparent !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
#sib-ai-coach:hover {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.95) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.10) !important;
}

/* Phase group dividers */
.phase-group {
  border-bottom: none !important;
}

/* Phase headers — Foundation, Core Setup, Launchpads, Referral Hub */
.phase-header {
  color: rgba(255,255,255,0.55) !important;
  background: transparent !important;
  box-shadow: none !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.phase-header:hover {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.92) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.10) !important;
}
.phase-header.open {
  color: #ffffff !important;
  background: linear-gradient(90deg,
    rgba(255,255,255,0.08) 0%,
    rgba(255,255,255,0.02) 100%) !important;
  border-left: 2px solid #C9962F !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    inset 0 -1px 0 rgba(0,0,0,0.20) !important;
}

/* Sub-items */
#sidebar .phase-sub-item {
  color: rgba(255,255,255,0.60) !important;
  background: transparent !important;
  box-shadow: none !important;
  border-left: 2px solid transparent !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
#sidebar .phase-sub-item:hover:not(.locked) {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.95) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.08) !important;
}
#sidebar .phase-sub-item.active {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.10) 0%,
    rgba(255,255,255,0.03) 100%) !important;
  border-left-color: #C9962F !important;
  color: #ffffff !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    inset 0 -1px 0 rgba(0,0,0,0.20),
    0 1px 3px rgba(0,0,0,0.20) !important;
}

/* Settings button at the bottom of the rail */
#sidebar-settings-btn {
  color: rgba(255,255,255,0.55) !important;
}
#sidebar-settings-btn:hover {
  background: rgba(255,255,255,0.06) !important;
  color: rgba(255,255,255,0.95) !important;
}

/* Wordmark text fallback (used when brand_name is set but no
   horizontal logo is uploaded — Phase 1.1 branding identity).
   Inline navy color was removed from index.html; CSS owns it here so
   theme can control. */
#sidebar .sidebar-wordmark-text { color: rgba(255,255,255,0.95); }

/* ═══════════════════════════════════════
   SIDEBAR FONT SIZE 16px + SETTINGS FIX
═══════════════════════════════════════ */

/* 16px across all sidebar nav items */
#sib-dashboard,
#sib-ai-coach,
.phase-header,
#sidebar .phase-sub-item,
.settings-nav-item,
#sidebar-settings-btn {
  font-size: 16px !important;
}

/* Settings nav — light text on dark navy, operator-grade hover/active */
.settings-nav-back {
  color: rgba(255,255,255,0.65) !important;
  border-bottom: 1px solid rgba(255,255,255,0.06) !important;
  background: transparent !important;
  text-transform: none !important;
  letter-spacing: 0.01em !important;
  font-size: 16px !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.settings-nav-back:hover {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.95) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.10) !important;
}
.settings-nav-label {
  color: rgba(255,255,255,0.30) !important;
  font-size: 9px !important;
  font-weight: 500 !important;
  letter-spacing: 0.24em !important;
  padding: 24px 18px 8px !important;
}
.settings-nav-item {
  color: rgba(255,255,255,0.60) !important;
  background: transparent !important;
  border-left-color: transparent !important;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.settings-nav-item:hover {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 0%,
    rgba(255,255,255,0.01) 100%) !important;
  color: rgba(255,255,255,0.95) !important;
  box-shadow: inset 2px 0 0 rgba(255,255,255,0.08) !important;
}
.settings-nav-item.active {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.10) 0%,
    rgba(255,255,255,0.03) 100%) !important;
  border-left-color: #C9962F !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    inset 0 -1px 0 rgba(0,0,0,0.20),
    0 1px 3px rgba(0,0,0,0.20) !important;
  color: #ffffff !important;
  text-shadow: none !important;
}
.settings-nav-item svg { color: rgba(255,255,255,0.55) !important; }
.settings-nav-item.active svg { color: #ffffff !important; }

/* ═══════════════════════════════════════
   SIDEBAR — ALL NORMAL WEIGHT (400)
═══════════════════════════════════════ */
#sib-dashboard,
#sib-ai-coach,
.phase-header,
#sidebar .phase-sub-item,
.settings-nav-item,
.settings-nav-back,
#sidebar-settings-btn {
  font-weight: 400 !important;
}

/* ═══════════════════════════════════════
   TOPNAV — CLEAN STATUS INDICATORS
═══════════════════════════════════════ */
.ghl-sync-pill {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 4px 6px !important;
  gap: 5px !important;
}
.ghl-sync-pill:hover {
  background: rgba(1,36,61,0.05) !important;
  border-radius: 8px !important;
}
.topnav-search { display: none !important; }

/* ═══════════════════════════════════════
   LIGHT THEME — DROPDOWN + SPLASH
═══════════════════════════════════════ */

/* User dropdown — white card */
.user-dropdown {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 8px 24px rgba(1,36,61,0.12) !important;
}
.user-dd-item {
  color: rgba(1,36,61,0.65) !important;
  font-weight: 400 !important;
}
.user-dd-item:hover {
  background: rgba(1,36,61,0.05) !important;
  color: #01243D !important;
}
.user-dd-divider { background: #e2e8f0 !important; }
.user-dd-logout { color: #dc2626 !important; }
.user-dd-logout:hover {
  background: rgba(220,38,38,0.06) !important;
  color: #b91c1c !important;
}

/* ═══════════════════════════════════════
   DASHBOARD — CLEAN SYNERGY-STYLE
═══════════════════════════════════════ */

/* Remove yellow top border from Focus card */
.dash-card-right {
  border-top: 1px solid #e2e8f0 !important;
}

/* Lighter section labels */
.dash-section-label {
  font-size: 9px !important;
  font-weight: 400 !important;
  letter-spacing: 0.12em !important;
  color: #b0bec5 !important;
}

/* Progress bar names — normal weight */
.dash-prog-name { font-weight: 400 !important; }
.dash-prog-pct  { font-weight: 400 !important; }

/* Checklist labels — normal weight */
.dash-check-label { font-weight: 400 !important; }
.dash-check-active .dash-check-label { font-weight: 400 !important; }

/* Focus phase label — softer */
.dash-focus-phase {
  color: rgba(1,36,61,0.4) !important;
  font-weight: 400 !important;
}

/* Focus title — lighter */
.dash-focus-title { font-weight: 400 !important; }

/* System tiles — match syn-card feel */
.dash-lp-tile {
  border: 1px solid rgba(1,36,61,0.08) !important;
  box-shadow: 0 1px 4px rgba(1,36,61,0.06) !important;
}
.dash-lp-name  { font-weight: 400 !important; }
.dash-lp-status { font-weight: 400 !important; }

/* Eco map button — lighter */
.dash-eco-btn { font-weight: 400 !important; }

/* ═══════════════════════════════════════
   DASHBOARD V2 — CLEAN 3-CARD LAYOUT
═══════════════════════════════════════ */
.dash-wrap {
  display: flex;
  flex-direction: column;
  height: 100%;
  /* Locked contract: canvas gutters live on #page-content (48px L/R, 20px top).
     Dashboard wrap only handles internal stack rhythm. */
  padding: 0;
  box-sizing: border-box;
  gap: 24px;
  overflow: hidden;
}
/* Legacy .dash-header retired by the locked design contract (2026-06-15).
   Title and subhead now live in the shell #page-header-slot. CSS kept inert
   in case stale templates reappear. */
.dash-header { display: none; }
.dash-title  { font-size: 26px; font-weight: 400; color: #01243D; }
.dash-subtitle { font-size: 14px; color: #94a3b8; margin-top: 2px; }

/* 3-card row */
.dash-two-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  flex: 1;
  min-height: 0;
  margin-bottom: 24px;
}

/* Base card */
.dash-v2-card {
  background: #fff;
  border: 1px solid rgba(1,36,61,0.08);
  border-radius: 14px;
  padding: 28px 28px;
  box-shadow: 0 1px 4px rgba(1,36,61,0.06);
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}
.dash-v2-ai-card {
  flex-shrink: 0;
}

/* Card title */
.dash-v2-title {
  font-size: 16px;
  font-weight: 400;
  color: #01243D;
  margin-bottom: 12px;
}

/* Progress bar */
.dash-v2-prog-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.dash-v2-prog-track {
  flex: 1;
  height: 5px;
  background: #f5f5f7;
  border-radius: 99px;
  overflow: hidden;
}
.dash-v2-prog-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 0.6s ease;
}
.dash-v2-pct {
  font-size: 13px;
  color: #94a3b8;
  font-weight: 400;
  flex-shrink: 0;
  min-width: 32px;
  text-align: right;
}

/* Divider */
.dash-v2-divider {
  height: 1px;
  background: #f5f5f7;
  margin: 0 0 12px;
}

/* Label */
.dash-v2-label {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #b0bec5;
  margin-bottom: 8px;
}

/* Checklist rows */
.dash-v2-checklist {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  overflow: hidden;
}
.dash-v2-check-row {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 6px;
  border-radius: 7px;
  cursor: pointer;
  transition: background 0.12s;
}
.dash-v2-check-row:hover { background: #f5f5f7; }
.dash-v2-check-icon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s;
}
.dash-v2-check-icon.done {
  background: #37CA37;
  border-color: #37CA37;
}
.dash-v2-check-label {
  font-size: 14px;
  color: #334155;
  font-weight: 400;
}
.dash-v2-check-label.done {
  color: #94a3b8;
  text-decoration: line-through;
}

/* Launchpad rows */
.dash-v2-lp-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.dash-v2-lp-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 6px;
  border-radius: 8px;
  border: 1px solid rgba(1,36,61,0.06);
  background: #fafafa;
}
.dash-v2-lp-left {
  display: flex;
  align-items: center;
  gap: 9px;
}
.dash-v2-lp-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dash-v2-lp-name {
  font-size: 14px;
  color: #01243D;
  font-weight: 400;
}
.dash-v2-lp-arrow {
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  border-radius: 6px;
  transition: color 0.12s, background 0.12s;
}
.dash-v2-lp-arrow:hover {
  color: #01243D;
  background: rgba(1,36,61,0.05);
}

/* AI Coach card */
.dash-v2-ai-desc {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.6;
  font-weight: 400;
}

/* Checklist modal — green done items */
.lp-check-icon.done {
  background: rgba(55,202,55,0.15) !important;
  color: #16a34a !important;
}
.lp-check-text.done-text {
  color: #16a34a !important;
  text-decoration: none !important;
  font-weight: 400 !important;
}

/* ═══════════════════════════════════════
   DASHBOARD ACTIVATION GRID (7 cards)
   ─────────────────────────────────────────
   Card visuals match settings .st-card, but the grid and the gold
   action button are self-contained here — Settings injects its own
   CSS only on first entry, and the dashboard renders before that.
═══════════════════════════════════════ */
.dash-act-wrap {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 0 0 60px;
}
.dash-act-banner {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dash-act-banner-title {
  font-size: 22px;
  font-weight: 400;
  color: #01243D;
  letter-spacing: -0.01em;
}
.dash-act-banner-sub {
  font-size: 14px;
  color: rgba(1,36,61,0.55);
  font-weight: 400;
  max-width: 720px;
  line-height: 1.5;
}

/* ── Selene widget "Open full AI Coach" link ───────────────────── */
.ai-cw-coach-link {
  margin-top: 8px;
  padding: 4px 0;
  text-align: center;
}
.ai-cw-coach-link a {
  font-size: 12px;
  color: rgba(1,36,61,0.55);
  text-decoration: none;
  font-family: var(--font);
  transition: color 180ms;
}
.ai-cw-coach-link a:hover {
  color: #01243D;
  text-decoration: underline;
}

.dash-act-progress {
  width: 100%;
}
.dash-act-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(1,36,61,0.08);
  border-radius: 99px;
  overflow: hidden;
}
.dash-act-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #f4ad1f 0%, #d78500 100%);
  border-radius: 99px;
  transition: width 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Cards — extend the settings .st-card visual but add their own
   collapsible head/body, mark icon, and status pill. */
.dash-act-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid rgba(1,36,61,0.06);
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.04),
    0 4px 12px -2px rgba(1, 36, 61, 0.06),
    0 16px 40px -8px rgba(1, 36, 61, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
  overflow: hidden;
  transition: border-color 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}
.dash-act-card.is-done {
  border-left: 3px solid #16a34a;
}
.dash-act-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 22px;
  cursor: pointer;
  user-select: none;
}
.dash-act-head-left {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
  flex: 1;
}
.dash-act-mark {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid rgba(1,36,61,0.25);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  transition: background 0.15s, border-color 0.15s;
}
.dash-act-mark.is-done {
  background: #16a34a;
  border-color: #16a34a;
}
.dash-act-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.dash-act-title {
  font-size: 15px;
  font-weight: 400;
  color: #01243D;
  letter-spacing: -0.005em;
  line-height: 1.3;
}
.dash-act-sub {
  font-size: 13px;
  font-style: italic;
  color: rgba(1,36,61,0.50);
  font-weight: 400;
  line-height: 1.4;
}
.dash-act-head-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.dash-act-pill {
  font-size: 10px;
  font-weight: 400;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
}
.dash-act-pill-todo {
  background: rgba(1,36,61,0.05);
  color: rgba(1,36,61,0.45);
  border: 1px solid rgba(1,36,61,0.10);
}
.dash-act-pill-progress {
  background: rgba(21,138,246,0.10);
  color: #1d6fce;
  border: 1px solid rgba(21,138,246,0.25);
}
.dash-act-pill-done {
  background: rgba(55,202,55,0.12);
  color: #16a34a;
  border: 1px solid rgba(55,202,55,0.30);
}
/* Pro lock badge — replaces the status pill on cards a Basic user
   doesn't have access to yet. Architectural gold #C9962F per the
   design system (NOT the celebratory CTA gradient). */
.dash-act-pill-pro {
  background: rgba(201,150,47,0.10);
  color: #C9962F;
  border: 1px solid rgba(201,150,47,0.30);
}
/* Locked card variant — text muted to ~60%, whole card clickable to
   open the pricing modal. Layout and border match the normal card so
   the upsell still reads as part of the activation grid, not separate
   marketing. */
.dash-act-card.is-locked {
  cursor: pointer;
}
.dash-act-card.is-locked .dash-act-title,
.dash-act-card.is-locked .dash-act-sub,
.dash-act-card.is-locked .dash-act-desc,
.dash-act-card.is-locked .dash-act-inline {
  opacity: 0.60;
}
.dash-act-card.is-locked .dash-act-mark {
  opacity: 0.45;
}
/* Muted gold CTA — same gradient as the normal CTA, but at lower
   opacity so it reads as "you can interact, but it's not your primary
   action right now." */
.dash-act-btn-locked {
  opacity: 0.50;
  transition: opacity 180ms cubic-bezier(0.22, 1, 0.36, 1);
}
.dash-act-btn-locked:hover {
  opacity: 0.70;
}
.dash-act-chev {
  background: transparent;
  border: 0;
  color: rgba(1,36,61,0.45);
  width: 26px;
  height: 26px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1),
              background 0.12s, color 0.12s;
}
.dash-act-chev:hover { background: rgba(1,36,61,0.05); color: #01243D; }
.dash-act-card.is-open .dash-act-chev { transform: rotate(180deg); }

/* Body — collapsed by default; expands when the card has .is-open */
.dash-act-body {
  display: none;
  padding: 0 22px 22px 64px;
}
.dash-act-card.is-open .dash-act-body { display: block; }
.dash-act-desc {
  font-size: 14px;
  color: rgba(1,36,61,0.70);
  line-height: 1.6;
  margin: 0 0 14px;
  font-weight: 400;
}
.dash-act-inline {
  font-size: 11px;
  color: rgba(1,36,61,0.55);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
  font-weight: 400;
}
.dash-act-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* 7-card stack — single column so each card sits at its natural
   height. A 2-col grid forces the un-expanded sibling to match the
   open card's height, leaving an awkward empty box. */
.dash-act-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.dash-act-grid > .dash-act-card { margin-bottom: 0; }

/* Gold gradient action button — matches the locked "Save" / "Open AI Coach"
   style on profile / settings cards. Self-contained so the dashboard
   doesn't depend on Settings' injected .st-btn-dark rules. */
.dash-act-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 38px;
  padding: 0 22px;
  border: 0;
  border-radius: 9px;
  font: 400 14px 'Poppins', sans-serif;
  letter-spacing: -0.005em;
  color: #041626;
  cursor: pointer;
  white-space: nowrap;
  background: linear-gradient(
    135deg,
    #ffe89a 0%,
    #ffd35a 30%,
    #f4ad1f 60%,
    #d78500 100%
  );
  background-clip: padding-box;
  outline: 0;
  box-shadow: none;
  transition:
    transform    280ms cubic-bezier(0.22, 1, 0.36, 1),
    background   120ms cubic-bezier(0.22, 1, 0.36, 1);
}
.dash-act-btn:hover {
  background: linear-gradient(
    135deg,
    #fff0b8 0%,
    #ffdc77 30%,
    #f7ba38 60%,
    #e89512 100%
  );
  transform: translate3d(0, -1px, 0);
}
.dash-act-btn:active { transform: translate3d(0, 1px, 0); transition-duration: 120ms; }
.dash-act-btn:focus-visible {
  outline: 3px solid rgba(4, 22, 38, 0.25);
  outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  .dash-act-btn { transition: none; }
  .dash-act-btn:hover, .dash-act-btn:active { transform: none; }
}

/* ═══════════════════════════════════════
   SIDEBAR USER PROFILE PILL
═══════════════════════════════════════ */
.sidebar-user-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  width: calc(100% - 16px);
  margin: 0 8px 8px;
  padding: 9px 12px;
  background: rgba(255,255,255,0.025);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s cubic-bezier(0.22, 1, 0.36, 1);
  flex-shrink: 0;
}
.sidebar-user-pill:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.10);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.08),
    0 2px 8px rgba(0,0,0,0.22);
}
.sidebar-user-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 400;
  font-family: 'Poppins', sans-serif;
  color: rgba(255,255,255,0.85);
  flex-shrink: 0; overflow: hidden;
}
.sidebar-user-info { flex: 1; min-width: 0; }
.sidebar-user-name {
  display: block;
  font-family: 'Poppins', sans-serif !important;
  font-size: 16px !important; font-weight: 400 !important;
  color: rgba(255,255,255,0.92) !important;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sidebar-status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #d1d5db;
  transition: background .3s;
}
.sidebar-status-dot.green  { background: #22c55e; }
.sidebar-status-dot.orange { background: #f59e0b; }
.sidebar-status-dot.red    { background: #ef4444; }

/* Remove topnav height from any calc() that referenced it */
#right-col { height: 100%; }

/* ═══════════════════════════════════════
   SIDEBAR USER POPUP MENU
═══════════════════════════════════════ */
.sidebar-user-popup {
  display: none;
  position: fixed;
  background: #fff;
  border: 1px solid rgba(1,36,61,0.1);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(1,36,61,0.14), 0 2px 8px rgba(1,36,61,0.08);
  z-index: 9999;
  overflow: hidden;
  animation: popup-up .15s ease;
}
.sidebar-user-popup.open { display: block; }
@keyframes popup-up {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.sidebar-user-popup-name {
  padding: 12px 16px 10px;
  font-size: 12px;
  font-weight: 400;
  color: rgba(1,36,61,0.45);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user-popup-divider {
  height: 1px;
  background: rgba(1,36,61,0.08);
  margin: 0 8px;
}
.sidebar-user-popup-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 16px;
  background: transparent;
  border: none;
  text-align: left;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 400;
  color: rgba(1,36,61,0.75);
  cursor: pointer;
  transition: background .12s;
}
.sidebar-user-popup-item:hover { background: rgba(1,36,61,0.05); }
.sidebar-user-popup-item svg { flex-shrink: 0; opacity: 0.55; }
.sidebar-user-popup-logout { color: #dc2626; }
.sidebar-user-popup-logout svg { opacity: 0.7; }
.sidebar-user-popup-logout:hover { background: rgba(220,38,38,0.06); }

/* Make sidebar bottom area position:relative for popup anchor */
#sidebar-main-nav { position: relative; }

/* ═══════════════════════════════════════
   SIDEBAR TOGGLE ARROW
═══════════════════════════════════════ */
#sidebar-toggle-arrow {
  position: fixed;
  bottom: 88px;
  left: calc(var(--sidebar-w) - 11px);
  width: 22px; height: 22px;
  border-radius: 50%;
  background: linear-gradient(180deg, #D9A641 0%, #C9962F 50%, #B3811E 100%);
  border: 1px solid rgba(255,255,255,0.18);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    inset 0 -1px 0 rgba(0,0,0,0.18),
    0 2px 8px rgba(201,150,47,0.35),
    0 4px 12px rgba(0,0,0,0.25);
  z-index: 200;
  transition: all 0.16s cubic-bezier(0.22, 1, 0.36, 1),
              left 0.24s cubic-bezier(0.4,0,0.2,1);
  color: rgba(0, 24, 38, 0.92);
}
#sidebar-toggle-arrow:hover {
  background: linear-gradient(180deg, #E6B954 0%, #D9A641 50%, #C28A24 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.36),
    inset 0 -1px 0 rgba(0,0,0,0.20),
    0 3px 12px rgba(201,150,47,0.45),
    0 6px 16px rgba(0,0,0,0.30);
}
#app.sidebar-is-collapsed #sidebar-toggle-arrow {
  left: calc(60px - 11px);
}
/* Phase headers must be fully clickable when collapsed */
#sidebar.sidebar-collapsed .phase-header {
  pointer-events: all !important;
  cursor: pointer !important;
}

/* ═══════════════════════════════════════
   TYPOGRAPHY FONT SELECTOR
═══════════════════════════════════════ */
.bc-font-select-wrap { display:flex; flex-direction:column; gap:6px; }
.bc-font-sel {
  width:100%; padding:9px 13px;
  border:2px solid #01243D; border-radius:9px;
  background:#fff; color:#01243D;
  font-family:var(--font); font-size:13px;
  cursor:pointer; outline:none;
  transition:border-color .15s, box-shadow .15s;
  box-shadow:0 0 0 4px rgba(1,36,61,0.04);
  appearance:auto;
}
.bc-font-sel:focus { border-color:#FFBB00; box-shadow:0 0 0 4px rgba(255,187,0,0.12); }
.bc-font-custom {
  margin-top:2px;
}
.bc-font-preview {
  font-size:15px; color:rgba(1,36,61,0.55);
  padding:6px 2px; letter-spacing:0.01em;
  border-top:1px dashed rgba(1,36,61,0.1);
  margin-top:2px;
}

/* ── Upload a font button ── */
.bc-font-upload-btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px;
  border: 1px dashed rgba(1,36,61,0.25);
  border-radius: 9px;
  font-size: 13px; font-weight: 400;
  color: rgba(1,36,61,0.6);
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  width: fit-content;
  margin-top: 2px;
  user-select: none;
}
.bc-font-upload-btn:hover {
  border-color: #01243D;
  color: #01243D;
  background: rgba(1,36,61,0.04);
}

/* ═══════════════════════════════════════
   SECTION ICONS — MATCH TEXT COLOR
   Phase headers + top-level nav icons
═══════════════════════════════════════ */
.phase-header .phase-header-left svg,
#sib-dashboard > div > svg,
#sib-ai-coach > div > span {
  color: inherit !important;
  stroke: currentColor !important;
}
/* AI Coach uses a text span ✦ instead of SVG */
#sib-ai-coach > div > span {
  color: inherit !important;
}

/* ── Remove emoji page icons from Foundation section headers ── */
.page-icon { display: none !important; }
/* ═══════════════════════════════════════
   SIDEBAR ICON SIZE — LARGER & CLEARER
═══════════════════════════════════════ */
/* Top-level items: Dashboard, AI Coach */
#sib-dashboard > div > svg,
#sib-ai-coach > div > span {
  width: 20px !important;
  height: 20px !important;
  font-size: 20px !important;
  line-height: 1 !important;
  flex-shrink: 0 !important;
}

/* Phase headers: Foundation, Launchpads, Scalability */
.phase-header .phase-header-left svg {
  width: 20px !important;
  height: 20px !important;
  flex-shrink: 0 !important;
}

/* Sub-items inside phases */
#sidebar .phase-sub-item > div > svg,
#sidebar .phase-items .phase-sub-item svg {
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0 !important;
}

/* Increase gap slightly to breathe with larger icons */
#sib-dashboard > div,
#sib-ai-coach > div:first-child,
.phase-header-left,
#sidebar .phase-sub-item > div {
  gap: 12px !important;
}

/* ── Settings nav icons ── */
.settings-nav-item svg {
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0 !important;
}
.settings-nav-back svg {
  width: 16px !important;
  height: 16px !important;
  flex-shrink: 0 !important;
}
.settings-nav-item,
.settings-nav-back {
  gap: 12px !important;
}
/* ── Referral Hub — atmospheric page + premium card system ─────────────── */
/* Tactical, calm, eased. Linear/Stripe/Superhuman-grade.                   */
/* Brand: navy #01243D · blue #1F8CEF · gold #FDBA2C (reserved for active   */
/* / featured / success — never used on hover so it stays meaningful).      */
/*                                                                          */
/* Light model: directional source from upper-left. Page atmosphere and     */
/* card gradient border both follow this so the system reads as a single    */
/* lit room rather than separate decorated elements.                        */

/* Referral-hub pages keep the canvas gutters from the locked design
   contract (#page-content: 20px / 48px / 60px). The atmospheric wrapper
   only needs a transparent background pass-through, not a padding wipe. */
#page-content:has(> .rh-page-bg) {
  background: transparent !important;
}

/* Paginated rh pages (Referrals) own their own scroll and pagination bar,
   so they go full-bleed inside #page-content — disable canvas padding +
   outer scroll so the sticky pagination bar stays anchored. */
#page-content:has(> .rh-page-bg--paginated) {
  padding: 0 !important;
  overflow: hidden !important;
}

/* ── Atmospheric page wrapper ─────────────────────────────────────────── */
/* Asymmetric directional lighting — primary diffusion is off-center upper-
   left like a window, secondary cool zone on the right, gold warmth in
   one bottom corner only. Reads as environmental, not designed.            */
.rh-page-bg {
  position: relative;
  min-height: calc(100vh - 60px);
  padding: 8px 0 80px;
  background: #f5f5f7;
}

.rh-page-bg > * { position: relative; z-index: 1; }

/* ── Card resting state ─────────────────────────────────────────────────
   Cinematic depth at rest. See docs/DESIGN_SYSTEM.md §5 for the full
   shadow specification. Transitions follow the multi-rate hierarchy rule
   (§6) — transform leads, shadow lags. */
.rh-card {
  position: relative;
  isolation: isolate;
  background: var(--surface-primary) !important;
  border-color: var(--border-quiet) !important;
  box-shadow: var(--shadow-resting);
  transition:
    transform    var(--dur-medium) var(--ease-precision),
    box-shadow   var(--dur-shadow) var(--ease-precision),
    border-color var(--dur-fast)   var(--ease-precision),
    opacity      var(--dur-slow)   var(--ease-precision),
    filter       var(--dur-slow)   var(--ease-precision);
  will-change: transform;
}

/* Card-overlay delete button — hidden until the card is hovered so it
   doesn't draw attention away from the primary content. */
.rh-card .rh-card-delete { display: none !important; }
.rh-card:hover .rh-card-delete { display: inline-flex !important; }
.rh-card .rh-card-delete:hover { background: rgba(220,38,38,0.12) !important; color: #dc2626 !important; }

.rh-card .rh-card-menu { display: none !important; }
.rh-card:hover .rh-card-menu { display: inline-flex !important; }
.rh-card .rh-card-menu:hover { background: rgba(1,36,61,0.12) !important; color: #01243D !important; }

/* Gradient border — directional precision edge. See §2 (light model). */
.rh-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: var(--grad-edge-precision);
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
          mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity var(--dur-panel) var(--ease-precision);
  pointer-events: none;
  z-index: 1;
}

/* ── Hover ───────────────────────────────────────────────────────────────
   See docs/DESIGN_SYSTEM.md §5 (shadow-hover) for the 7-layer breakdown. */
.rh-card:hover {
  transform: translate3d(0, var(--lift-card), 0) scale(var(--scale-hover-card));
  border-color: transparent !important;
  box-shadow: var(--shadow-hover);
}
.rh-card:hover::before { opacity: 1; }

/* ── Sibling recede ──────────────────────────────────────────────────────
   Inactive cards stay alive — only soft dimming, no disabled feel. */
[data-rh-grid]:has(.rh-card:hover) .rh-card:not(:hover) {
  opacity: 0.74;
  filter: saturate(0.92);
  transform: scale(var(--scale-recede));
}

/* ── Press ─────────────────────────────────────────────────────────────── */
.rh-card:active {
  transform: translate3d(0, var(--lift-press), 0) scale(var(--scale-press));
  transition:
    transform  var(--dur-instant) var(--ease-snap),
    box-shadow var(--dur-instant) var(--ease-snap);
  box-shadow: var(--shadow-active);
}

/* ── Keyboard focus ───────────────────────────────────────────────────── */
.rh-card:focus-visible {
  outline: none;
  transform: translate3d(0, var(--lift-card), 0) scale(var(--scale-hover-card));
  border-color: transparent !important;
  box-shadow: var(--shadow-focus);
}
.rh-card:focus-visible::before { opacity: 1; }

/* ── Reduced motion ─────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .rh-card,
  .rh-card::before,
  [data-rh-grid] .rh-card { transition: none; }
  .rh-card:hover,
  .rh-card:focus-visible { transform: none; }
  [data-rh-grid]:has(.rh-card:hover) .rh-card:not(:hover) { transform: none; }
}

/* ── Card grid ────────────────────────────────────────────────────────
   Three columns on desktop, dropping to two then one as the viewport
   narrows. Shared by the Referrals grid and the Directory grid (both
   carry data-rh-grid for the sibling-recede hover behavior).
─────────────────────────────────────────────────────────────────────── */
.rh-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
@media (max-width: 1180px) {
  .rh-card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .rh-card-grid { grid-template-columns: 1fr; }
}

/* Referrals page — list view (toolbar toggle alternative to the grid).
   Compact horizontal rows; same hover lift as the grid cards. */
.rh-list-row { transition: background .12s, box-shadow .12s, transform .12s; }
.rh-list-row:hover {
  background: #fafbfc;
  box-shadow: 0 6px 18px rgba(1,36,61,0.06);
  transform: translateY(-1px);
}
@media (prefers-reduced-motion: reduce) {
  .rh-list-row, .rh-list-row:hover { transition: none; transform: none; }
}

/* ═══════════════════════════════════════════════════════════════════════
   REFERRAL DETAIL VIEW
   ─────────────────────────────────────────────────────────────────────
   Two-column layout: expanded referral card on the left, Jetpack-native
   chat thread on the right. Sub-state of the Referrals page (not a
   separate route). Consumes the same atmospheric tokens as the grid so
   the room feels continuous when navigating in and out.
═══════════════════════════════════════════════════════════════════════ */

/* Static variant — neutralizes the grid card's hover lift for cards
   that are presentational (not a click target). Used by the expanded
   card in the left column. */
.rh-card.is-static { cursor: default; }
.rh-card.is-static:hover {
  transform: none;
  box-shadow: var(--shadow-resting);
  border-color: var(--border-quiet) !important;
}
.rh-card.is-static:hover::before { opacity: 0; }
.rh-card.is-static:active {
  transform: none;
  box-shadow: var(--shadow-resting);
}

/* ── Detail card zones ───────────────────────────────────────────────
   The expanded left-column card is broken into four labelled zones —
   diagram, title, sections, foot. Zones replace the prior single
   white slab and give the eye a rhythm to scan: visual → title →
   labelled sections → attribution. */

.rh-detail-diagram-zone {
  /* Subtle gradient backdrop turns the triangle area into a structural
     "diagram header" instead of a graphic floating on white. Top of
     card only — fades to white before the title zone. */
  position: relative;
  padding: 26px 24px 10px;
  background:
    linear-gradient(180deg,
      rgba(1, 36, 61, 0.035) 0%,
      rgba(1, 36, 61, 0.012) 55%,
      rgba(255, 255, 255, 0) 100%
    );
}

.rh-detail-title-zone {
  /* Hairline divider below anchors the title block to the diagram zone
     and signals the start of the labelled-sections rhythm beneath. */
  padding: 8px 24px 18px;
  text-align: center;
  border-bottom: 1px solid rgba(1, 36, 61, 0.06);
}
.rh-detail-title {
  font-size: 17.5px;
  font-weight: 400;
  color: var(--text-primary);
  font-family: var(--font);
  letter-spacing: -0.01em;
  line-height: 1.35;
}
.rh-detail-time {
  font-size: 11.5px;
  color: var(--text-tertiary);
  margin-top: 6px;
  font-family: var(--font);
}
.rh-detail-pill-row { margin-top: 10px; }

.rh-detail-section {
  /* Labelled content section. Padding tightened from the old 28px to 24px
     so the card feels denser and more operational without being cramped. */
  padding: 16px 24px;
}
.rh-detail-section + .rh-detail-section {
  border-top: 1px solid rgba(1, 36, 61, 0.05);
}
.rh-detail-section-foot {
  /* Last section — slightly more breathing room at the very bottom. */
  padding-bottom: 20px;
}

.rh-detail-section-label {
  /* Quiet uppercase label. Operator-software rhythm signal — small,
     tracking-wide, muted. The single biggest "operational" upgrade we
     get without adding visible chrome. */
  font-size: 10.5px;
  font-weight: 500;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.085em;
  font-family: var(--font);
  margin: 0 0 11px;
}

.rh-detail-party-rows {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.rh-detail-party-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}
.rh-detail-party-name {
  font-size: 13px;
  color: var(--accent-interactive);
  font-family: var(--font);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

/* Two-column grid. Collapses to single column on narrow viewports. */
.rh-detail-grid {
  display: grid;
  grid-template-columns: minmax(360px, 460px) 1fr;
  gap: 24px;
  align-items: start;
}
@media (max-width: 980px) {
  .rh-detail-grid { grid-template-columns: 1fr; }
}

.rh-detail-left {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}
.rh-detail-right { min-width: 0; }

/* Top "Back to Referrals" link — quiet, secondary, not the primary
   back action (Cancel button is). Lives above the grid. */
.rh-detail-back-top {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 12.5px;
  font-family: var(--font);
  cursor: pointer;
  padding: 4px 0;
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color var(--dur-fast) var(--ease-precision);
}
.rh-detail-back-top:hover { color: var(--accent-interactive); }

/* "View profile" inline link inside the creator block. */
.rh-detail-link { transition: color var(--dur-fast) var(--ease-precision); }
.rh-detail-link:hover { color: var(--accent-deep) !important; }

/* Bottom Cancel button — primary back action. Full-width pill matching
   the rest of the left column. Adopts the Ghost tier visual from the
   jp-btn system (see DESIGN_SYSTEM.md §10) with full-width layout. */
.rh-detail-cancel {
  background: transparent;
  border: 1px solid rgba(1, 36, 61, 0.15);
  border-radius: 12px;
  padding: 13px 16px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  font-family: var(--font);
  letter-spacing: -0.005em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  user-select: none;
  transition:
    transform     280ms cubic-bezier(0.22, 1, 0.36, 1),
    background    var(--dur-fast)   var(--ease-precision),
    border-color  var(--dur-fast)   var(--ease-precision),
    color         var(--dur-fast)   var(--ease-precision);
}
.rh-detail-cancel:hover:not(:disabled) {
  background: rgba(1, 36, 61, 0.04);
  border-color: rgba(1, 36, 61, 0.28);
  color: var(--text-primary);
  transform: translate3d(0, -1px, 0);
}
.rh-detail-cancel:active:not(:disabled) {
  transform: translate3d(0, 1px, 0);
  transition-duration: var(--dur-fast);
}
.rh-detail-cancel:focus-visible {
  outline: none;
  border-color: var(--accent-interactive);
  box-shadow: 0 0 0 3px rgba(31, 140, 239, 0.18);
}
.rh-detail-cancel-x {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid currentColor;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── Chat panel ───────────────────────────────────────────────────────
   Header + thread + composer. The header gives the panel structural
   presence so the thread doesn't read as an empty drawer when there
   are few messages. */
.rh-chat-panel {
  background: var(--surface-primary);
  border: 1px solid var(--border-quiet);
  border-radius: 14px;
  box-shadow: var(--shadow-resting);
  display: flex;
  flex-direction: column;
  height: 660px;
  max-height: calc(100vh - 160px);
  overflow: hidden;
}

/* Header — quiet, structural. "Conversation" label on the left, live
   count badge on the right (hidden when 0). */
.rh-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border-quiet);
  background: linear-gradient(180deg,
    rgba(1, 36, 61, 0.018) 0%,
    rgba(255, 255, 255, 0) 100%);
}
.rh-chat-header-title {
  font-size: 13.5px;
  color: var(--text-primary);
  font-family: var(--font);
  letter-spacing: -0.005em;
}
.rh-chat-header-count {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font);
  background: rgba(1, 36, 61, 0.05);
  padding: 3px 9px;
  border-radius: 10px;
  font-variant-numeric: tabular-nums;
}

.rh-chat-thread {
  flex: 1;
  overflow-y: auto;
  padding: 24px 24px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Empty state — three-tier hierarchy: icon, title, body. Centered in
   the thread, quiet enough not to compete with messages once they
   appear. */
.rh-chat-empty {
  margin: auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 11px;
  max-width: 340px;
  font-family: var(--font);
}
.rh-chat-empty-icon {
  width: 32px;
  height: 32px;
  color: rgba(1, 36, 61, 0.22);
}
.rh-chat-empty-title {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
  letter-spacing: -0.005em;
}
.rh-chat-empty-body {
  font-size: 12.5px;
  color: var(--text-tertiary);
  line-height: 1.6;
  max-width: 280px;
}

/* Message row */
.rh-chat-message {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  max-width: 86%;
}
.rh-chat-message.is-mine {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.rh-chat-msg-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex-shrink: 0;
  background: linear-gradient(135deg, #01243D, #1B3A6B);
  color: #fff;
  font-size: 11px;
  font-family: var(--font);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(1, 36, 61, 0.06);
}
.rh-chat-msg-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rh-chat-msg-stack {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.rh-chat-message.is-mine .rh-chat-msg-stack { align-items: flex-end; }

.rh-chat-msg-bubble {
  background: #f5f5f7;
  border: 1px solid var(--border-quiet);
  border-radius: 12px;
  padding: 9px 13px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-primary);
  font-family: var(--font);
  word-wrap: break-word;
  overflow-wrap: anywhere;
}
.rh-chat-message.is-mine .rh-chat-msg-bubble {
  background: linear-gradient(135deg, #1F8CEF 0%, #1B5B8E 100%);
  color: #fff;
  border-color: transparent;
}
.rh-chat-msg-bubble b, .rh-chat-msg-bubble strong { font-weight: 600; }
.rh-chat-msg-bubble i, .rh-chat-msg-bubble em     { font-style: italic; }
.rh-chat-msg-bubble u                              { text-decoration: underline; }

.rh-chat-msg-meta {
  font-size: 10.5px;
  color: var(--text-tertiary);
  margin-top: 5px;
  font-family: var(--font);
}

/* ── Composer ─────────────────────────────────────────────────────────
   One unified bordered shell: toolbar pinned to top with a hairline
   divider, input in the middle, send tucked into the bottom-right
   inside the shell. Same pattern Notion / Linear / GitHub use. Replaces
   the prior stacked-floating-boxes feel — composer now reads as a
   single grounded tool. */
.rh-composer {
  border-top: 1px solid var(--border-quiet);
  background: var(--surface-secondary);
  padding: 12px 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Inline error banner — shown when a send fails. Quiet red, no border. */
.rh-composer-error {
  font-size: 12px;
  color: #b91c1c;
  font-family: var(--font);
  padding: 4px 2px 0;
  line-height: 1.45;
}

.rh-composer-shell {
  background: #fff;
  border: 1px solid var(--border-base);
  border-radius: 11px;
  display: flex;
  flex-direction: column;
  transition: border-color var(--dur-fast) var(--ease-precision),
              box-shadow   var(--dur-shadow) var(--ease-precision);
}
.rh-composer-shell:focus-within {
  border-color: var(--accent-interactive);
  box-shadow: 0 0 0 3px rgba(31, 140, 239, 0.10);
}

.rh-composer-toolbar {
  display: flex;
  gap: 4px;
  padding: 6px 8px;
  border-bottom: 1px solid rgba(1, 36, 61, 0.06);
}

.rh-cb {
  width: 28px;
  height: 26px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 12px;
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    background-color var(--dur-fast) var(--ease-precision),
    color            var(--dur-fast) var(--ease-precision);
}
.rh-cb:hover {
  background: rgba(1, 36, 61, 0.05);
  color: var(--accent-interactive);
}
.rh-cb.is-bold      { font-weight: 700; }
.rh-cb.is-italic    { font-style: italic; }
.rh-cb.is-underline { text-decoration: underline; }

.rh-composer-input {
  min-height: 56px;
  max-height: 180px;
  overflow-y: auto;
  background: transparent;
  border: none;
  padding: 10px 13px 6px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-primary);
  font-family: var(--font);
  outline: none;
  word-wrap: break-word;
  overflow-wrap: anywhere;
}
.rh-composer-input:empty::before {
  content: attr(data-placeholder);
  color: var(--text-tertiary);
  pointer-events: none;
}
.rh-composer-input b, .rh-composer-input strong { font-weight: 600; }
.rh-composer-input i, .rh-composer-input em     { font-style: italic; }
.rh-composer-input u                             { text-decoration: underline; }

.rh-composer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 8px 8px 13px;
}
.rh-composer-hint {
  font-size: 10.5px;
  color: var(--text-tertiary);
  font-family: var(--font);
  font-variant-numeric: tabular-nums;
}

/* Send button — visual treatment comes from .jp-btn .jp-btn-sm .jp-btn-primary
   (applied in the markup). Only layout-specific bits live here. */
.rh-composer-send {
  flex-shrink: 0;
}

@media (prefers-reduced-motion: reduce) {
  .rh-detail-cancel,
  .rh-composer-send,
  .rh-composer-shell { transition: none; }
  .rh-detail-cancel:hover,
  .rh-composer-send:hover:not(:disabled) { transform: none; }
}
/* ═══════════════════════════════════════
   PREMIUM CARDS — OPERATOR GRADE  (Phase 2)
   Three-layer elevation, hairline border, inner top highlight,
   restrained hover lift. Replaces flat 1-shadow paint with
   material quality.
═══════════════════════════════════════ */

/* Foundational pattern — opt-in for new surfaces */
.jp-card {
  background: #ffffff;
  border: 1px solid rgba(1, 36, 61, 0.06);
  border-radius: 14px;
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.04),
    0 4px 12px -2px rgba(1, 36, 61, 0.06),
    0 16px 40px -8px rgba(1, 36, 61, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
  transition: box-shadow 0.18s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}
.jp-card:hover {
  border-color: rgba(1, 36, 61, 0.10);
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.05),
    0 6px 16px -2px rgba(1, 36, 61, 0.08),
    0 24px 56px -8px rgba(1, 36, 61, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

/* Dashboard cards — apply the same operator-grade material */
.dash-card {
  background: #ffffff !important;
  border: 1px solid rgba(1, 36, 61, 0.06) !important;
  border-radius: 14px !important;
  padding: 24px !important;
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.04),
    0 4px 12px -2px rgba(1, 36, 61, 0.06),
    0 16px 40px -8px rgba(1, 36, 61, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.85) !important;
  transition: box-shadow 0.18s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.18s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.dash-card:hover {
  border-color: rgba(1, 36, 61, 0.10) !important;
  box-shadow:
    0 1px 2px rgba(1, 36, 61, 0.05),
    0 6px 16px -2px rgba(1, 36, 61, 0.08),
    0 24px 56px -8px rgba(1, 36, 61, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.95) !important;
}

/* Retire the .dash-card-right yellow/gray top border — the lifted
   shadow stack now does the elevation work, the line just adds noise */
.dash-card-right {
  border-top: 1px solid rgba(1, 36, 61, 0.06) !important;
}

/* ═══════════════════════════════════════
   TYPOGRAPHY — OPERATOR HIERARCHY  (Phase 3)
═══════════════════════════════════════ */

/* Sidebar nav: 16px (chunky) → 14px (operator-grade refinement) */
#sib-dashboard,
#sib-ai-coach,
.phase-header,
#sidebar .phase-sub-item,
.settings-nav-item,
.settings-nav-back,
#sidebar-settings-btn {
  font-size: 14px !important;
  letter-spacing: 0.005em !important;
}
.sidebar-user-name {
  font-size: 12px !important;
  letter-spacing: 0.005em !important;
}

/* Dashboard "Welcome back" title — tighter, more authoritative */
.dash-title {
  font-size: 26px !important;
  font-weight: 400 !important;
  letter-spacing: -0.018em !important;
  color: #01243D !important;
}

/* Dashboard section labels (CHECKLIST, GHL CHECKLIST, etc.) — wider tracking */
.dash-section-label {
  font-size: 10px !important;
  font-weight: 500 !important;
  letter-spacing: 0.16em !important;
  color: #94a3b8 !important;
  text-transform: uppercase;
}

/* Dashboard card titles ("Foundation", "Core Setup", "Launchpads") —
   slight weight bump for hierarchy clarity against the body text */
.dash-card h3,
.dash-card .dash-card-title {
  font-weight: 500 !important;
  letter-spacing: -0.005em !important;
}

/* ─────────────────────────────────────────────────────────────────
   Global button typography (2026-06-18)
   Every <button> (and equivalent form-input button) across the SaaS
   app lands at font-weight 400 per Brendan's design pass. !important
   so class-level overrides scattered across per-page CSS strings
   stop winning the cascade. Anchor tags styled as buttons (rare —
   network EZ card preview, a couple of legacy spots) are not caught
   here; those are corrected at the inline-style level.
───────────────────────────────────────────────────────────────── */
button,
input[type="button"],
input[type="submit"],
input[type="reset"] {
  font-weight: 400 !important;
}

/* ═══════════════════════════════════════════════════════════════════
   MOBILE RESPONSIVE LAYER  —  2026-06-26 (audit-driven, rev 2)
   ───────────────────────────────────────────────────────────────────
   Rev 2 (2026-06-26): off-canvas hamburger pattern reverted per Amanda's
   feedback — too much UI for the use case. Sidebar instead reuses its
   existing collapsed-rail state (60px icons-only) at ≤768px. The desktop
   collapse arrow is hidden on mobile so the rail can't be expanded back.

   Layout-layer fixes (covers ~70% of audit blockers):
     1. Force sidebar into collapsed-rail state at ≤768px
     2. Known 2-col grids collapse to 1fr ≤480px
     3. Wide containers (eco-map) capped to viewport
     4. Topnav search expands to fill row
     5. Cluster buttons bumped to 36px touch target
   ═══════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  /* Force the existing .sidebar-collapsed visual state without needing the JS class.
     Selectors mirror the .sidebar-collapsed rules at lines 1106–1156 so the
     sidebar lands in the same icon-rail layout the desktop collapse toggle produces.
     Key: text is hidden via font-size:0 (NOT display:none), because the SVG icons
     live inside .phase-sub-item > div alongside the text. display:none kills both. */
  #sidebar {
    width: 60px !important;
    min-width: 60px !important;
    overflow: visible;
  }
  #sidebar .sidebar-wordmark { display: none !important; }
  #sidebar .sidebar-icon-only { display: block !important; }
  #sidebar .sidebar-logo {
    justify-content: center !important;
    padding: 16px 0 !important;
    flex-direction: column !important;
    gap: 0 !important;
  }
  #sidebar #sidebar-settings-nav { display: none !important; }
  #sidebar #sidebar-main-nav {
    display: flex !important;
    flex-direction: column;
    align-items: center;
  }
  /* Nav item buttons — narrow, centered (matches .sidebar-collapsed) */
  #sidebar .phase-sub-item,
  #sidebar .phase-header {
    width: 44px !important;
    min-width: 44px !important;
    padding: 10px 0 !important;
    justify-content: center !important;
    border-radius: 10px !important;
    margin: 1px auto !important;
  }
  /* Hide text but keep SVG icons (font-size:0 collapses text, SVGs survive) */
  #sidebar .phase-sub-item > div,
  #sidebar .phase-header .phase-header-left {
    font-size: 0 !important;
    gap: 0 !important;
    justify-content: center !important;
  }
  #sidebar .phase-sub-item > div svg,
  #sidebar .phase-header .phase-header-left svg {
    width: 18px !important; height: 18px !important; flex-shrink: 0;
  }
  /* Hide arrows, badges, expandable phase-items, status dots */
  #sidebar .phase-arrow,
  #sidebar .item-status,
  #sidebar #sib-ai-coach > div:last-child,
  #sidebar #sib-referral-hub > div:last-child,
  #sidebar .phase-items,
  #sidebar .sidebar-status-dot { display: none !important; }
  /* User pill — avatar only */
  #sidebar .sidebar-user-pill {
    width: 44px !important; margin: 4px auto 8px !important;
    padding: 6px !important; justify-content: center !important;
  }
  #sidebar .sidebar-user-info { display: none !important; }
  #sidebar .sidebar-user-avatar { width: 34px !important; height: 34px !important; }
  /* Hide the desktop collapse arrow on mobile — no expanded state available */
  #sidebar-toggle-arrow { display: none !important; }

  /* Topnav search expands to fill row (was max-width:400px, crowded iPhone) */
  .topnav-search { max-width: 100% !important; margin: 0 8px !important; }

  /* Eco-map (3344) — was fixed 1042px, forced horizontal scroll */
  .eco-map-outer { width: 100% !important; max-width: 100% !important; overflow-x: auto; }

  /* Reduce body padding so content breathes */
  #main { padding-left: 16px !important; padding-right: 16px !important; }

  /* ── Sticky page header band (every route) ── */
  /* Desktop has 48px gutters; mobile gets 16px to match the body padding above. */
  .app-page-header { padding: 0 16px !important; min-height: 52px !important; }
  #app-header-band::after { margin: 10px 16px 0 !important; }
  /* Tighten the separator gap between title and subtitle */
  .app-page-header-sep { margin: 0 10px !important; }
  /* Action buttons row — keep tight against the right edge */
  .app-page-header-actions { margin-left: 8px !important; gap: 6px !important; }
}

/* Tighter rules for iPhone-class widths */
@media (max-width: 480px) {
  /* Blanket 2-col grid collapse — covers all the named cases from the audit */
  .syn-two-col,
  .syn-social-grid,
  .syn-link-grid,
  .rh-card-grid,
  .pm-cards,
  .st-fields-grid:not(.single),
  .st-settings-grid {
    grid-template-columns: 1fr !important;
  }

  /* Touch targets — cluster buttons audit-flagged at 26px (Apple min is 44px) */
  .jp-cluster-btn { width: 36px !important; height: 36px !important; }

  /* Topbar — let cluster + hamburger breathe */
  #jp-topbar { padding-left: 8px !important; padding-right: 8px !important; }

  /* ── Sticky page header band (tightest size for iPhone) ── */
  .app-page-header-title { font-size: 18px !important; }
  .app-page-header-sub   { font-size: 13px !important; }
  .app-page-header-icon  { width: 22px !important; height: 22px !important; margin-right: 8px !important; }
  .app-page-header-icon svg { width: 18px !important; height: 18px !important; }

  /* ── Dashboard polish ── */
  /* Banner — title was 22px, too big at this width */
  .dash-act-banner-title { font-size: 18px !important; line-height: 1.3 !important; }
  .dash-act-banner-sub   { font-size: 13px !important; }
  /* Stack each card's head vertically so the title gets the full row width
     (was wrapping word-by-word because the IN PROGRESS pill + chevron ate
     ~120px on the right). Pill + chev sit on their own row at the bottom-right. */
  .dash-act-head {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
    padding: 16px 16px !important;
  }
  .dash-act-head-right {
    justify-content: flex-end !important;
  }
  /* Body — desktop has 64px left padding to align under the title; on
     mobile that wastes half the row, drop to flush */
  .dash-act-body { padding: 0 16px 18px 16px !important; }
  .dash-act-desc { font-size: 13px !important; line-height: 1.55 !important; }
  /* Card title + subtitle slightly tighter */
  .dash-act-title { font-size: 14px !important; line-height: 1.3 !important; }
  .dash-act-sub   { font-size: 12px !important; line-height: 1.35 !important; }
  /* Tighter spacing between cards */
  .dash-act-grid { gap: 14px !important; }
  /* Action button full-width so the CTA tap target is generous */
  .dash-act-actions { width: 100%; }
  .dash-act-btn    { width: 100%; }
}