    :root {
      --bg-deep:       #050a18;
      --bg-card:       rgba(18, 26, 44, 0.65);
      --bg-card-hover: rgba(255, 255, 255, 0.055);
      --accent:        #7c3aed;
      --accent-mid:    #8b5cf6;
      --accent-light:  #a78bfa;
      --accent-glow:   rgba(139, 92, 246, 0.18);
      --text:          #cbd5e1;
      --text-hi:       #f1f5f9;
      --text-lo:       #64748b;
      --text-mid:      #94a3b8;
      --border-faint:  rgba(255, 255, 255, 0.05);
      /* Admin inbox density (production default — lab Classic overrides these) */
      --admin-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
      --admin-font-size-base: 0.88rem;
      --inbox-row-pad: 0.45rem 0.65rem;
      --inbox-row-label-size: 0.82rem;
      --inbox-preview-size: 0.72rem;
      --msg-card-pad: 0.4rem 0.6rem 0.35rem;
      --msg-card-radius: 9px;
      --msg-card-border: 3px;
      --msg-card-header-size: 0.65rem;
      --msg-card-body-size: 0.82rem;
      --msg-card-action-size: 0.68rem;
      --msg-card-action-pad: 0.15rem 0.4rem;
      /* ── Message-card SINGLE SOURCE OF TRUTH (hybrid: premium-dark fill + author
         left-bar). Every card color is a token here — no hardcoded hex in card rules.
         Per author: --bar (left accent), --bg (fill), --edge (border), --dir (label text).
         Outbound (operator/ai) share the violet fill; inbound (inmate/contact) share
         the slate fill; the LEFT-BAR keeps the per-author accent for at-a-glance ID. */
      --card-edge:            #2a2f3a;   /* default card border */
      --card-inmate-bar:      #7c3aed;  --card-inmate-bg:   #20232c;  --card-inmate-dir:   #a78bfa;
      --card-contact-bar:     #2dd4bf;  --card-contact-bg:  #20232c;  --card-contact-dir:  #5eead4;
      --card-operator-bar:    #d97706;  --card-operator-bg: #241f3d;  --card-operator-edge: #322a54; --card-operator-dir: #fbbf24;
      --card-ai-bar:          #0ea5e9;  --card-ai-bg:       #241f3d;  --card-ai-edge:      #322a54;  --card-ai-dir:       #38bdf8;
      --card-system-bar:      #475569;  --card-system-bg:   #191b22;  --card-system-edge:  #23262f;  --card-system-dir:   #64748b;
      --card-held-bar:        #f59e0b;  --card-held-bg:     #2a2413;  --card-held-edge:    #4a3d17;  --card-held-dir:     #fbbf24;
      --card-selected-bg:     #2a2350;  --card-selected-edge: #4c3d86;
      --inbox-thread-gap: 0.35rem;
      --inbox-thread-pad: 0.65rem;
      --inbox-thread-header-pad: 0.55rem 0.85rem;
      --inbox-thread-header-size: 0.85rem;
      --inbox-legend-size: 0.68rem;
      --inbox-legend-pad: 0.35rem 0.5rem;
      --hub-tab-size: 0.82rem;
      --hub-tab-pad: 0.35rem 0.85rem;
      --inbox-tab-size: 0.72rem;
      --inbox-tab-pad: 0.22rem 0.6rem;
      --inbox-reply-font-size: 0.85rem;
    }

    /* ── Mobile-first responsive overrides ─────────────────────────────── */
    @media (max-width: 640px) {
      .admin-wrap { padding: 1rem 0.75rem 4rem; }
      .panel { padding: 1.25rem 1rem; }
      .row-actions { width: 100%; justify-content: flex-end; }
      #git-status-widget { margin-left: 0 !important; }
      /* Inbox: stack list on top, thread below; full-width, taller on mobile */
      .admin-wrap:has(#app:not([hidden])) {
        height: auto;
        max-height: none;
        overflow: visible;
      }
      #app:not([hidden]) {
        overflow: visible;
        flex: none;
      }
      .admin-main {
        overflow: visible;
      }
      #inbox-layout {
        flex-direction: column !important;
        flex: 1;
        min-height: 280px;
        height: auto !important;
      }
      #inbox-list {
        width: 100% !important;
        min-width: unset !important;
        border-right: none !important;
        /* Single-pane swap (JS toggles .thread-open): the list is the sole visible
           pane until a thread opens, so let it fill the viewport instead of a
           stunted 220px box. No bottom border — it no longer stacks above the pane. */
        flex: 1;
        max-height: none;
        min-height: 0;
        overflow-y: auto;
      }
      .messaging-hub.panel {
        overflow: visible;
        min-height: calc(100dvh - 7rem);
        /* Rail stacks above the content on phones — no side-by-side squeeze. */
        flex-direction: column;
        gap: 0.25rem;
      }
      .hub-rail {
        width: auto;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.3rem;
        border-right: none;
        border-bottom: 1px solid rgba(139, 92, 246, 0.14);
      }
      /* Compose collapses to a compact icon button on phones — icon only, no label.
         Squared (not a round FAB) per the clean-text/no-rounded preference. */
      .hub-rail__compose {
        margin: 0 0.35rem 0 0;
        padding: 0;
        width: 2.1rem;
        height: 2.1rem;
        border-radius: 4px;
        justify-content: center;
        flex-shrink: 0;
      }
      .hub-rail__compose span { display: none; }
      .hub-rail .hub-tabs { flex-direction: row; flex-wrap: wrap; gap: 0.15rem; }
      .hub-rail .hub-tab { width: auto; }
      .hub-rail .hub-tab__label { flex: none; }
      /* Accounts group + label collapse on mobile — account chips wrap inline. */
      .hub-rail__accounts-group { display: flex; align-items: center; gap: 0.3rem; width: 100%; }
      .hub-rail__divider { display: none; }
      .hub-rail__label { display: none; }
      .hub-rail .inbox-account-tabs { flex-direction: row; flex-wrap: wrap; }
      .hub-rail .inbox-tab { width: auto; }
      #inbox-thread-pane {
        display: flex;
        flex-direction: column;
        flex: 1;
        min-height: 0;
        overflow: hidden;
      }
      .inbox-thread {
        min-height: 0;
      }
      #inbox-list.thread-open { display: none !important; }
      #inbox-thread-pane.list-open { display: none !important; }
      #inbox-thread-header { display: flex !important; align-items: center !important; flex-wrap: wrap; gap: 0.4rem; }
      /* Tables: horizontal scroll */
      .panel > table,
      .panel > div > table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
      th, td { padding: 0.75rem 0.85rem; }
      /* Stats grid: 2 cols on small screens */
      .grid { grid-template-columns: repeat(2, 1fr); gap: 0.85rem; }
      .stat { padding: 1rem 1.1rem; }
      .stat .n { font-size: 2rem; }
      /* Modal: full-screen on mobile */
      .modal-overlay { padding: 0; align-items: flex-end; }
      .modal-card { border-radius: 20px 20px 0 0; max-height: 92vh; overflow-y: auto; }
      /* Buttons: comfortable tap targets */
      .btn-sm { padding: 0.55rem 1rem; font-size: 0.82rem; }
      .auth-bar { margin: 2rem auto 1.5rem; padding: 2rem 1.25rem; }
      /* Reply area: shorter textarea, bigger send button tap target, safe-area bottom padding */
      #inbox-reply-text { min-height: 2.5rem; max-height: 6rem; }
      #inbox-reply-btn { padding: 0.65rem 1.4rem; font-size: 0.9rem; }
      #inbox-reply-area { padding-bottom: max(0.75rem, env(safe-area-inset-bottom)); }
    }

    /* Custom Scrollbar */
    ::-webkit-scrollbar {
      width: 10px;
      height: 10px;
    }
    ::-webkit-scrollbar-track {
      background: rgba(15, 23, 42, 0.4);
      border-radius: 4px;
    }
    ::-webkit-scrollbar-thumb {
      background: rgba(100, 116, 139, 0.32);
      border-radius: 4px;
      border: 2px solid rgba(15, 23, 42, 0.4);
      transition: background 0.3s ease;
    }
    ::-webkit-scrollbar-thumb:hover {
      background: rgba(139, 92, 246, 0.48);
    }

    body {
      font-family: var(--admin-font);
      font-size: var(--admin-font-size-base);
      background:
        radial-gradient(ellipse 60% 40% at 100% 0%, rgba(99,102,241,0.12) 0%, transparent 60%),
        radial-gradient(ellipse 50% 30% at 0% 100%, rgba(13,148,136,0.07) 0%, transparent 60%),
        var(--bg-deep);
      background-attachment: fixed;
      color: var(--text);
      margin: 0;
      padding: 0;
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
    }

    @keyframes pulse-amber {
      0%, 100% { opacity: 1; filter: drop-shadow(0 0 2px rgba(245, 158, 11, 0.4)); }
      50% { opacity: 0.5; filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.8)); }
    }

    .admin-wrap { max-width: min(112rem, 100%); margin: 0 auto; padding: 1.25rem 1.25rem 2rem; box-sizing: border-box; }

    /* One viewport when connected — scroll inside list/thread, not the whole page.
       Desktop/tablet only (min-width:641px): on mobile (≤640px) the page must scroll
       naturally so the single-pane thread isn't trapped in a 100dvh/overflow:hidden box
       and starved to a sliver by the fixed pane-head + reply-area. The ≤640px override
       above sets height:auto; overflow:visible — scoping this rule keeps that override
       from losing the cascade tie (identical selector, this rule appears later). */
    @media (min-width: 641px) {
      .admin-wrap:has(#app:not([hidden])) {
        height: 100dvh;
        max-height: 100dvh;
        overflow: hidden;
        display: flex;
        flex-direction: column;
        max-width: 100%;
        width: 100%;
        margin: 0;
        padding: 0;
      }
    }
    /* Connected layout chrome that must apply at every width (flex column, full-bleed) */
    .admin-wrap:has(#app:not([hidden])) {
      display: flex;
      flex-direction: column;
      max-width: 100%;
      width: 100%;
      margin: 0;
      padding: 0;
    }
    .admin-wrap:has(#app:not([hidden])) #dashboard-placeholder {
      display: none;
    }

    /* Connected: flat app chrome (Gmail-style), not centered login card */
    .admin-wrap.admin-connected .auth-bar--compact {
      max-width: none;
      width: 100%;
      margin: 0;
      padding: 0.35rem 0.75rem;
      border-radius: 0;
      background: rgba(15, 23, 42, 0.55);
      border: none;
      border-bottom: 1px solid var(--border-faint);
      box-shadow: none;
      flex-shrink: 0;
    }
    .admin-wrap.admin-connected .auth-bar--compact:hover {
      box-shadow: none;
      border-color: var(--border-faint);
    }
    .admin-wrap.admin-connected .auth-bar__head h1 {
      font-size: 0.95rem;
      font-weight: 700;
      letter-spacing: -0.02em;
    }
    .admin-wrap.admin-connected .auth-bar__head {
      margin: 0;
    }

    #app:not([hidden]) {
      display: flex;
      flex-direction: column;
      flex: 1;
      min-height: 0;
      overflow: hidden;
      padding: 0 0.5rem 0.35rem;
      box-sizing: border-box;
    }
    #app:not([hidden]) .status-bar {
      margin: 0.25rem 0 0.2rem;
      padding: 0.2rem 0 0.25rem;
      border-bottom: none;
      flex-shrink: 0;
      gap: 0.35rem 0.75rem;
    }
    /* Top status bar: same dot-accent treatment as the inbox "friend" badge
       (admin.css ~1489) — strip the pill container, keep uppercase label + a
       colored dot so status reads quietly instead of competing for attention. */
    #app:not([hidden]) .status-bar .pill {
      padding: 0;
      background: none;
      border: none;
      box-shadow: none;
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      font-size: 0.66rem;
    }
    #app:not([hidden]) .status-bar .pill::before {
      content: '';
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: currentColor;
      box-shadow: 0 0 6px currentColor;
      flex-shrink: 0;
    }
    #app:not([hidden]) #status-meta {
      font-size: 0.72rem;
    }
    /* Messaging Hub fills the viewport below the status bar */
    .admin-main {
      flex: 1;
      min-height: 0;
      display: flex;
      flex-direction: column;
      overflow: hidden;
    }
    .messaging-hub.panel {
      display: flex;
      flex-direction: row;
      flex: 1;
      min-height: 0;
      overflow: hidden;
      padding: 0.35rem 0.4rem 0.4rem;
      margin-bottom: 0;
      border-radius: 4px;
      gap: 0.4rem;
    }
    /* ── Gmail-style left rail (Tier 3) ── */
    .hub-rail {
      flex-shrink: 0;
      width: 9.5rem;
      display: flex;
      flex-direction: column;
      gap: 0.15rem;
      padding: 0.35rem 0.3rem;
      border-right: 1px solid rgba(139, 92, 246, 0.14);
      overflow-y: auto;
    }
    .hub-rail__compose {
      display: flex;
      align-items: center;
      gap: 0.55rem;
      margin: 0.15rem 0.15rem 0.6rem;
      padding: 0.6rem 0.9rem;
      border: none;
      border-radius: 4px;
      background: linear-gradient(135deg, #7c3aed, #8b5cf6);
      color: #fff;
      font-family: inherit;
      font-size: 0.85rem;
      font-weight: 600;
      cursor: pointer;
      box-shadow: 0 5px 16px -6px rgba(124, 58, 237, 0.7);
      transition: transform 0.12s, box-shadow 0.12s;
    }
    .hub-rail__compose:hover { transform: translateY(-1px); box-shadow: 0 9px 22px -6px rgba(124, 58, 237, 0.8); }
    .hub-rail__divider { height: 1px; background: rgba(139, 92, 246, 0.14); margin: 0.55rem 0.4rem; }
    .hub-rail__label {
      padding: 0.15rem 0.6rem 0.3rem;
      font-size: 0.62rem;
      font-weight: 700;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: #475569;
    }
    /* hub-tabs stack vertically as full-width nav rows inside the rail */
    .hub-rail .hub-tabs {
      display: flex;
      flex-direction: column;
      flex-wrap: nowrap;
      gap: 0.1rem;
      margin: 0;
      padding: 0;
      border-bottom: none;
    }
    .hub-rail .hub-tab {
      width: 100%;
      justify-content: flex-start;
      padding: 0.5rem 0.75rem;
      border: none;
      border-radius: 4px;
      color: #cbd5e1;
      font-size: 0.85rem;
    }
    .hub-rail .hub-tab:hover { background: rgba(255, 255, 255, 0.04); }
    .hub-rail .hub-tab.is-active {
      background: rgba(124, 58, 237, 0.2);
      color: #f1f5f9;
      border: none;
      font-weight: 600;
    }
    /* Rail nav-row icon + label */
    .hub-tab__icon {
      display: inline-flex;
      align-items: center;
      color: #64748b;
      flex-shrink: 0;
    }
    .hub-rail .hub-tab.is-active .hub-tab__icon { color: #a78bfa; }
    .hub-tab__label { flex: 1; }
    /* account tabs stack vertically too — kept tight so idle accounts don't
       eat rail space (cl3–cl7 with 0 unread were leaving a big empty column). */
    .hub-rail .inbox-account-tabs {
      display: flex;
      flex-direction: column;
      gap: 0.05rem;
      margin: 0;
      padding: 0;
    }
    /* Account tabs in the rail are stacked NAV ROWS, not a horizontal tab bar —
       drop the pill (border + oval radius + fill) inherited from base .inbox-tab so
       they read like the Inbox/System nav rows above them: quiet text, subtle hover,
       soft active fill. No outline per row = far less visual noise in the rail. */
    .hub-rail .inbox-tab {
      width: 100%;
      display: flex;
      align-items: center;
      gap: 0.4rem;
      text-align: left;
      border: none;
      border-radius: 4px;
      background: none;
      padding: 0.34rem 0.7rem;
      font-size: 0.8rem;
    }
    .hub-rail .inbox-tab:hover { background: rgba(255, 255, 255, 0.04); }
    /* Quiet accounts (no unread) recede so the ones needing you stand out; they
       stay fully clickable and light up on hover / when selected. */
    .hub-rail .inbox-tab.is-quiet { color: #64748b; }
    .hub-rail .inbox-tab.is-quiet:hover { color: #cbd5e1; }
    .hub-rail .inbox-tab.has-unread { color: #e2e8f0; font-weight: 600; }
    .hub-rail .inbox-tab.is-active {
      color: #f1f5f9;
      background: rgba(124, 58, 237, 0.2);
      border: none;
    }
    .inbox-tab__text {
      flex: 1;
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    /* Per-account unread count — plain number, no bubble (owner prefers clean text
       over rounded pills; see feedback_no_rounded_prefer_text). */
    .inbox-tab__badge {
      flex-shrink: 0;
      min-width: 0;
      padding: 0;
      border-radius: 0;
      background: none;
      color: #c4b5fd;
      font-size: 0.68rem;
      font-weight: 700;
      font-variant-numeric: tabular-nums;
      text-align: center;
      line-height: 1.35;
    }
    .hub-rail .inbox-tab.is-active .inbox-tab__badge {
      color: #ddd6fe;
    }
    .hub-content {
      flex: 1;
      min-width: 0;
      display: flex;
      flex-direction: column;
      min-height: 0;
      overflow: hidden;
    }
    .messaging-hub > .hub-pane[hidden],
    .hub-content > .hub-pane[hidden] {
      display: none !important;
    }
    .messaging-hub .hub-pane--inbox:not([hidden]) {
      flex: 1;
      display: flex;
      flex-direction: column;
      min-height: 0;
    }
    .messaging-hub > .hub-pane:not([hidden]):not(.hub-pane--inbox),
    .hub-content > .hub-pane:not([hidden]):not(.hub-pane--inbox) {
      flex: 1;
      min-height: 0;
      overflow: auto;
    }
    .hub-pane--admin {
      padding: 0.35rem 0.15rem 0.75rem;
    }
    .hub-pane--admin .issues-list { margin-top: 0; margin-bottom: 0.85rem; }
    .hub-pane--admin .grid { margin-top: 0; margin-bottom: 0.85rem; }
    .hub-pane--admin .panel {
      padding: 1rem 1.1rem;
      margin-bottom: 0.75rem;
    }
    .hub-pane__heading {
      margin: 0 0 0.35rem;
      font-size: 1rem;
      font-weight: 600;
    }
    .hub-pane__heading--sub {
      font-size: 0.92rem;
      color: rgba(226, 232, 240, 0.85);
    }
    #hub-pane-system #infra-summary { margin-bottom: 0.75rem; }
    #hub-pane-system .operator-actions { margin: 0.75rem 0; }
    .admin-connected .inbox-account-tabs .inbox-tab {
      font-size: 0.78rem;
      padding: 0.28rem 0.55rem;
    }
    .hub-tab-group--admin { margin-left: 0.5rem; }
    .inbox-thread-pane__head {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem 0.75rem;
      margin-bottom: 0.35rem;
    }
    .inbox-thread-pane__head .inbox-thread-header {
      flex: 1;
      min-width: 10rem;
      margin-bottom: 0;
    }
    .inbox-view-toggle {
      display: inline-flex;
      gap: 0.15rem;
      padding: 0.15rem;
      border-radius: 4px;
      background: rgba(15, 23, 42, 0.5);
      border: 1px solid rgba(139, 92, 246, 0.2);
    }
    .inbox-view-btn {
      cursor: pointer;
      border: none;
      background: transparent;
      color: #94a3b8;
      font-size: 0.78rem;
      font-weight: 600;
      padding: 0.3rem 0.65rem;
      border-radius: 4px;
    }
    .inbox-view-btn.is-active {
      background: rgba(139, 92, 246, 0.25);
      color: #e2e8f0;
    }
    .inbox-sent-subview {
      flex: 1;
      min-height: 0;
      overflow: auto;
    }
    .inbox-sent-subview__hint { margin: 0 0 0.5rem; font-size: 0.82rem; }
    #inbox-thread-view {
      flex: 1;
      display: flex;
      flex-direction: column;
      min-height: 0;
      overflow: hidden;
    }
    #inbox-thread-view[hidden],
    .inbox-sent-subview[hidden] { display: none !important; }
    .hub-system-section {
      margin-bottom: 1.25rem;
      padding-bottom: 1rem;
      border-bottom: 1px solid rgba(139, 92, 246, 0.15);
    }
    .hub-system-section:last-child {
      margin-bottom: 0;
      padding-bottom: 0;
      border-bottom: none;
    }
    .hub-relay-blasts {
      margin-top: 1.25rem;
      padding-top: 1rem;
      border-top: 1px solid rgba(139, 92, 246, 0.15);
    }
    .hub-queues-intro {
      margin: 0 0 1rem;
      font-size: 0.88rem;
      line-height: 1.45;
    }
    .unconfigured-relay-panel {
      margin-bottom: 1.25rem;
      padding: 1rem 1.25rem;
      border-radius: 4px;
      background: rgba(239, 68, 68, 0.1);
      border: 1px solid rgba(239, 68, 68, 0.35);
    }
    .unconfigured-relay-panel[hidden] { display: none !important; }
    .unconfigured-relay-panel__lead {
      margin: 0 0 0.85rem;
      font-size: 0.9rem;
      color: #fca5a5;
      line-height: 1.45;
    }
    .unconfigured-relay-panel__lead code { color: #fef3c7; word-break: break-all; }
    .unconfigured-relay-panel__actions { margin-top: 0.75rem; }
    .hub-queues-alerts {
      margin-bottom: 0.5rem;
    }
    .hub-queues-alerts .hub-pane__heading--sub {
      margin-bottom: 0.5rem;
    }
    .hub-queues-outbox-hint {
      margin: 0 0 1rem;
    }
    .hub-drafts-section {
      margin-bottom: 1.25rem;
      padding: 1rem 1.15rem 1.15rem;
      border-radius: 4px;
      background: rgba(139, 92, 246, 0.08);
      border: 1px solid rgba(139, 92, 246, 0.28);
    }
    .hub-drafts-section .hub-pane__heading {
      margin-top: 0;
      margin-bottom: 0.35rem;
    }
    .hub-drafts-subtitle {
      font-size: 0.82rem;
      font-weight: 500;
    }
    .hub-outbox-section {
      margin-top: 1.1rem;
      padding-top: 0.85rem;
      border-top: 1px solid rgba(139, 92, 246, 0.12);
    }
    .hub-outbox-section:first-of-type {
      margin-top: 0;
      padding-top: 0;
      border-top: none;
    }
    .hub-outbox-heading {
      font-size: 0.78rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: #c4b5fd;
      margin-bottom: 0.65rem;
    }
    .queue-outbox-actions {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.35rem;
      min-width: 11rem;
    }
    .queue-outbox-action-select {
      flex: 1 1 8.5rem;
      min-width: 0;
      max-width: 12rem;
      font-size: 0.72rem;
      padding: 0.25rem 0.4rem;
      border-radius: 4px;
      border: 1px solid rgba(139, 92, 246, 0.25);
      background: rgba(15, 23, 42, 0.6);
      color: inherit;
    }
    #draft-edit-modal {
      border: 1px solid rgba(139, 92, 246, 0.35);
      border-radius: 4px;
      padding: 1rem 1.25rem;
      max-width: 42rem;
      width: calc(100% - 2rem);
      background: #0f172a;
      color: inherit;
    }
    #draft-edit-modal::backdrop {
      background: rgba(0, 0, 0, 0.55);
    }
    #draft-edit-text {
      width: 100%;
      box-sizing: border-box;
      margin-top: 0.5rem;
      padding: 0.5rem;
      border-radius: 4px;
      border: 1px solid rgba(139, 92, 246, 0.25);
      background: rgba(15, 23, 42, 0.8);
      color: inherit;
      font-family: inherit;
      font-size: 0.85rem;
      line-height: 1.45;
    }
    .hub-queues-section {
      margin-top: 1rem;
      padding-top: 0.75rem;
      border-top: 1px solid rgba(139, 92, 246, 0.15);
    }
    .status-chip[data-scroll-queues-pending],
    .status-chip[data-scroll-hub-drafts],
    .status-chip[data-scroll-owner-review] { cursor: pointer; }
    #hub-pane-system .confirmations-controls { margin-top: 0; }
    #hub-pane-system #infra-summary { margin-bottom: 0.75rem; }
    #hub-pane-system .operator-actions { margin: 0.75rem 0; }

    /* Custom Badges / Pills */
    .pill {
      display: inline-flex;
      align-items: center;
      padding: 0.35rem 0.85rem;
      border-radius: 999px;
      font-size: 0.68rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      line-height: 1;
      border: 1px solid transparent;
      box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    }
    .pill-ok {
      background: rgba(16, 185, 129, 0.1);
      color: #34d399;
      border-color: rgba(16, 185, 129, 0.25);
    }
    .pill-warn {
      background: rgba(245, 158, 11, 0.1);
      color: #fbbf24;
      border-color: rgba(245, 158, 11, 0.25);
    }
    .pill-crit {
      background: rgba(239, 68, 68, 0.1);
      color: #f87171;
      border-color: rgba(239, 68, 68, 0.25);
    }
    .pill-info {
      background: rgba(59, 130, 246, 0.1);
      color: #60a5fa;
      border-color: rgba(59, 130, 246, 0.25);
    }

    .grid {
      display: grid;
      gap: 1.5rem;
      grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
      margin-bottom: 2rem;
    }
    
    /* Stats Card Styling */
    .stat {
      background: linear-gradient(135deg, rgba(30, 41, 59, 0.3) 0%, rgba(15, 23, 42, 0.5) 100%);
      border: 1px solid rgba(255, 255, 255, 0.05);
      border-radius: 4px;
      padding: 1.5rem 1.75rem;
      transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
      position: relative;
      overflow: hidden;
      box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
    }
    .stat::before {
      content: '';
      position: absolute;
      top: 0; left: 0; width: 100%; height: 100%;
      background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(16, 185, 129, 0.03) 100%);
      opacity: 0;
      transition: opacity 0.4s ease;
    }
    .stat:hover::before { opacity: 1; }
    .stat:hover {
      transform: translateY(-5px) scale(1.02);
      border-color: rgba(139, 92, 246, 0.35);
      box-shadow: 0 15px 35px rgba(139, 92, 246, 0.15);
    }
    .stat .n {
      font-size: 2.75rem;
      font-weight: 800;
      line-height: 1;
      background: linear-gradient(135deg, #a78bfa 0%, #34d399 100%);
      -webkit-background-clip: text;
      background-clip: text;
      -webkit-text-fill-color: transparent;
      margin-bottom: 0.5rem;
      letter-spacing: -0.03em;
    }
    .stat .l {
      font-size: 0.82rem;
      color: #94a3b8;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.05em;
    }
    .stat .stat-sub {
      font-size: 0.78rem;
      color: #64748b;
      margin-top: 0.4rem;
      font-weight: 500;
      text-transform: none;
      letter-spacing: 0;
      line-height: 1.4;
    }
    #stats.grid {
      grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
      gap: 1rem;
    }

    .relay-add-panel {
      margin-top: 1.25rem;
      max-width: 36rem;
    }
    .relay-add-label {
      display: block;
      font-weight: 600;
      color: #a78bfa;
      margin-bottom: 0.35rem;
      font-size: 0.9rem;
    }
    .relay-add-hint {
      font-size: 0.82rem;
      margin: 0 0 0.5rem;
      line-height: 1.45;
    }
    .relay-add-panel textarea {
      width: 100%;
      box-sizing: border-box;
      background: rgba(255, 255, 255, 0.05);
      border: 1px solid rgba(139, 92, 246, 0.25);
      border-radius: 4px;
      color: #e2e8f0;
      padding: 0.6rem;
      font-family: ui-monospace, monospace;
      font-size: 0.85rem;
      resize: vertical;
      min-height: 4.5rem;
    }
    .relay-add-bar {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 0.65rem 0.85rem;
      margin-top: 0.65rem;
    }
    .relay-add-cap {
      display: inline-flex;
      align-items: center;
      gap: 0.4rem;
      font-size: 0.82rem;
      cursor: default;
    }
    .relay-add-cap input {
      width: 3.5rem;
      padding: 0.35rem 0.45rem;
      background: rgba(255, 255, 255, 0.05);
      border: 1px solid rgba(139, 92, 246, 0.25);
      border-radius: 4px;
      color: #e2e8f0;
      font-size: 0.85rem;
    }
    .relay-import-count {
      font-size: 0.8rem;
      margin-left: auto;
    }
    .relay-add-options {
      margin-top: 0.5rem;
      font-size: 0.85rem;
    }
    .relay-add-options summary {
      cursor: pointer;
      color: #94a3b8;
      font-weight: 600;
      list-style: none;
    }
    .relay-add-options summary::-webkit-details-marker { display: none; }
    .relay-add-options[open] summary { margin-bottom: 0.45rem; }
    .relay-add-options input {
      width: 100%;
      max-width: 22rem;
      box-sizing: border-box;
      background: rgba(255, 255, 255, 0.05);
      border: 1px solid rgba(139, 92, 246, 0.2);
      border-radius: 4px;
      color: #e2e8f0;
      padding: 0.45rem 0.55rem;
      font-size: 0.85rem;
    }

    /* Glassmorphism Panel */
    .panel {
      background: rgba(30, 41, 59, 0.25);
      backdrop-filter: blur(24px);
      -webkit-backdrop-filter: blur(24px);
      border: 1px solid rgba(255, 255, 255, 0.05);
      border-radius: 4px;
      padding: 2.25rem;
      margin-bottom: 2rem;
      box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
      transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .panel:hover {
      box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
      border-color: rgba(255, 255, 255, 0.09);
    }
    .panel h2 {
      margin: 0 0 1.5rem;
      font-size: 1.25rem;
      font-weight: 700;
      color: #f1f5f9;
      display: flex;
      align-items: center;
      gap: 0.65rem;
      letter-spacing: -0.01em;
    }
    .panel[data-collapse-key].collapsed .panel-collapse-body { display: none; }
    .panel[data-collapse-key].collapsed h2,
    .panel[data-collapse-key].collapsed .panel-collapse-header { margin-bottom: 0; }
    .panel-collapse-header { cursor: pointer; user-select: none; }
    .panel-collapse-chevron {
      margin-left: auto;
      font-size: 0.75rem;
      opacity: 0.45;
      transition: transform 0.2s ease;
      flex-shrink: 0;
    }
    .panel[data-collapse-key].collapsed .panel-collapse-chevron { transform: rotate(-90deg); }
    .photo-thumb-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
      gap: 0.65rem;
      margin-top: 0.75rem;
    }
    .photo-thumb-grid a {
      display: block;
      border-radius: 4px;
      overflow: hidden;
      border: 1px solid rgba(139, 92, 246, 0.25);
      aspect-ratio: 1;
      background: rgba(0,0,0,0.3);
    }
    .photo-thumb-grid img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      display: block;
    }
    .lob-mail-box {
      background: rgba(59, 130, 246, 0.08);
      border: 1px solid rgba(59, 130, 246, 0.25);
      border-radius: 4px;
      padding: 0.85rem 1rem;
      font-size: 0.88rem;
      line-height: 1.45;
      margin-top: 0.75rem;
    }
    .blast-runs-row td {
      background: rgba(15, 23, 42, 0.6);
      padding: 0.75rem 1rem !important;
      font-size: 0.82rem;
    }
    
    .alerts { list-style: none; padding: 0; margin: 0 0 2rem; }
    .alerts li {
      padding: 1rem 1.5rem;
      border-radius: 4px;
      margin-bottom: 1rem;
      font-size: 0.95rem;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 1rem;
      justify-content: space-between;
      transition: all 0.3s ease;
      box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    }
    .alerts li.ok { background: rgba(16, 185, 129, 0.06); border: 1px solid rgba(16, 185, 129, 0.15); color: #a7f3d0; }
    .alerts li.warn { background: rgba(245, 158, 11, 0.06); border: 1px solid rgba(245, 158, 11, 0.15); color: #fde68a; }
    .alerts li.crit { background: rgba(239, 68, 68, 0.06); border: 1px solid rgba(239, 68, 68, 0.15); color: #fecaca; }
    .alerts li.info { background: rgba(59, 130, 246, 0.06); border: 1px solid rgba(59, 130, 246, 0.15); color: #bfdbfe; }
    .alerts li.alert-unconfigured-relay {
      flex-direction: column;
      align-items: stretch;
      gap: 1rem;
      background: rgba(239, 68, 68, 0.08);
      border: 1px solid rgba(239, 68, 68, 0.22);
      color: #fecaca;
    }
    .alert-unconfigured-relay__body { width: 100%; }
    .alert-unconfigured-relay__head {
      display: flex;
      align-items: flex-start;
      gap: 0.75rem;
      margin-bottom: 0.85rem;
    }
    .alert-unconfigured-relay__title {
      display: block;
      font-size: 1.02rem;
      color: #fee2e2;
      margin-bottom: 0.25rem;
    }
    .alert-unconfigured-relay__relay {
      margin: 0;
      font-size: 0.88rem;
      color: #fca5a5;
    }
    .alert-unconfigured-relay__relay code {
      font-size: 0.9em;
      color: #fef3c7;
      word-break: break-all;
    }
    .relay-signup-table {
      width: 100%;
      border-collapse: collapse;
      font-size: 0.88rem;
      margin-bottom: 0.85rem;
    }
    .relay-signup-table th {
      text-align: left;
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.04em;
      color: #f87171;
      padding: 0.35rem 0.5rem 0.35rem 0;
      border-bottom: 1px solid rgba(239, 68, 68, 0.2);
    }
    .relay-signup-table td {
      padding: 0.55rem 0.5rem 0.55rem 0;
      border-bottom: 1px solid rgba(255, 255, 255, 0.05);
      vertical-align: middle;
    }
    .relay-signup-name { color: #fecaca; font-weight: 500; }
    .relay-signup-code {
      display: inline-block;
      font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
      font-size: 1.15rem;
      font-weight: 700;
      letter-spacing: 0.12em;
      color: #fef08a;
      background: rgba(0, 0, 0, 0.35);
      padding: 0.35rem 0.65rem;
      border-radius: 4px;
      cursor: pointer;
      user-select: all;
    }
    .relay-signup-code:hover { background: rgba(0, 0, 0, 0.5); color: #fff; }
    .relay-signup-code-cell {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.4rem;
    }
    .relay-signup-when { font-size: 0.78rem; white-space: nowrap; }
    .alert-unconfigured-relay__steps {
      margin: 0;
      padding-left: 1.15rem;
      font-size: 0.86rem;
      color: #fca5a5;
      line-height: 1.5;
    }
    .alert-unconfigured-relay__steps code {
      font-size: 0.88em;
      color: #fef3c7;
      word-break: break-all;
    }
    .alert-unconfigured-relay__actions {
      display: flex;
      justify-content: flex-end;
      width: 100%;
    }
    
    /* Modern Tables */
    table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
    th, td { text-align: left; padding: 1.1rem 1.25rem; border-bottom: 1px solid rgba(255, 255, 255, 0.04); }
    td.queue-msg-preview {
      max-width: 22rem;
      min-width: 10rem;
      white-space: pre-wrap;
      word-break: break-word;
      font-size: 0.85rem;
      color: #cbd5e1;
    }
    .hub-tab-badge {
      display: inline-block;
      min-width: 0;
      padding: 0;
      border-radius: 0;
      background: none;
      color: #fbbf24;
      font-size: 0.72rem;
      font-weight: 700;
      line-height: 1.2;
      text-align: center;
    }
    .hub-tab-badge:empty {
      display: none !important;
    }
    .msg-preview {
      white-space: pre-wrap;
      word-break: break-word;
      font-size: 0.85rem;
      color: #e2e8f0;
      line-height: 1.45;
    }
    .msg-preview--truncated {
      position: relative;
    }
    .msg-preview__body {
      display: block;
      padding-right: 2.85rem;
    }
    .msg-card__body .msg-preview,
    .err-card__text .msg-preview,
    td.queue-msg-preview .msg-preview {
      font-size: inherit;
      color: inherit;
    }
    .msg-preview__teaser,
    .msg-preview__rest {
      color: #e2e8f0;
    }
    .msg-preview__fade {
      color: #94a3b8;
    }
    .msg-preview__more {
      position: absolute;
      top: 0;
      right: 0;
      z-index: 5;
      margin: 0;
      padding: 0;
      border: none;
      background: none;
      color: #60a5fa;
      font-size: inherit;
      font-family: inherit;
      cursor: pointer;
      text-decoration: underline;
      text-underline-offset: 2px;
      white-space: nowrap;
    }
    .msg-preview__more:hover { color: #93c5fd; }
    th {
      color: #94a3b8;
      font-weight: 700;
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.1em;
      background: rgba(255, 255, 255, 0.015);
      border-bottom: 2px solid rgba(255, 255, 255, 0.08);
    }
    td { color: #cbd5e1; vertical-align: middle; }
    tr { transition: background-color 0.25s ease; }
    tr:hover td { background: rgba(255, 255, 255, 0.025); }
    
    /* Custom Modern Buttons */
    .btn {
      cursor: pointer;
      border: none;
      border-radius: 4px;
      padding: 0.65rem 1.3rem;
      font-weight: 600;
      font-size: 0.88rem;
      text-decoration: none;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 0.5rem;
      transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .btn-primary {
      background: linear-gradient(135deg, #10b981 0%, #059669 100%);
      color: #fff;
      box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
    }
    .btn-primary:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
      filter: brightness(1.1);
    }
    .btn-primary:active { transform: translateY(0); }
    .btn-ghost {
      background: rgba(255, 255, 255, 0.04);
      color: #cbd5e1;
      border: 1px solid rgba(255, 255, 255, 0.08);
    }
    .btn-ghost:hover {
      background: rgba(255, 255, 255, 0.08);
      color: #fff;
      border-color: rgba(255, 255, 255, 0.15);
      transform: translateY(-1px);
    }
    .btn-ghost:active { transform: translateY(0); }
    .btn-danger {
      background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
      color: #fff;
      box-shadow: 0 4px 14px rgba(239, 68, 68, 0.25);
    }
    .btn-danger:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
      filter: brightness(1.1);
    }
    .btn-danger:active { transform: translateY(0); }
    .btn-sm { padding: 0.4rem 0.85rem; font-size: 0.8rem; border-radius: 4px; }
    
    .row-actions { display: flex; flex-wrap: wrap; gap: 0.65rem; align-items: center; }
    .muted { color: #94a3b8; font-size: 0.88rem; line-height: 1.5; }
    
    /* Glowing Auth / Login Card */
    .auth-bar {
      background: rgba(15, 23, 42, 0.45);
      backdrop-filter: blur(24px);
      -webkit-backdrop-filter: blur(24px);
      border: 1px solid rgba(255, 255, 255, 0.08);
      border-radius: 24px;
      padding: 3rem 2.5rem;
      margin: 6rem auto 2rem;
      box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 
                  0 0 40px rgba(99, 102, 241, 0.08);
      max-width: 32rem;
      transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .auth-bar:hover {
      border-color: rgba(99, 102, 241, 0.25);
      box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5), 
                  0 0 50px rgba(99, 102, 241, 0.15);
    }
    .auth-bar label { display: block; font-size: 0.82rem; font-weight: 700; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.75rem; }
    .auth-row { display: flex; flex-wrap: wrap; gap: 0.85rem; align-items: center; }
    .auth-row input {
      flex: 1 1 14rem;
      min-width: 12rem;
      padding: 0.8rem 1.1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(10, 15, 30, 0.8);
      color: #fff;
      font-size: 0.95rem;
      transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .auth-row input:focus {
      outline: none;
      border-color: #8b5cf6;
      box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.15);
    }
    #auth-msg { margin: 1rem 0 0; min-height: 1.2em; font-weight: 600; font-size: 0.9rem; }
    #auth-msg.err { color: #fca5a5; }
    #auth-msg.ok { color: #34d399; }
    
    #dashboard-placeholder {
      text-align: center;
      padding: 5rem 2rem;
      color: #94a3b8;
      font-size: 1.15rem;
      font-weight: 500;
      max-width: 40rem;
      margin: 0 auto;
      line-height: 1.6;
    }
    
    #app[hidden] { display: none !important; }
    
    /* Routing flags */
    .flags { display: flex; flex-wrap: wrap; gap: 0.75rem; }
    .flag {
      font-size: 0.78rem;
      font-weight: 700;
      padding: 0.4rem 1rem;
      border-radius: 4px;
      background: rgba(255, 255, 255, 0.03);
      border: 1px solid rgba(255, 255, 255, 0.06);
      color: #94a3b8;
      transition: all 0.25s ease;
      letter-spacing: 0.02em;
    }
    .flag.on {
      background: rgba(16, 185, 129, 0.08);
      border-color: rgba(16, 185, 129, 0.25);
      color: #34d399;
      box-shadow: 0 2px 10px rgba(16, 185, 129, 0.1);
    }
    
    /* Toast alerts */
    #toast {
      position: fixed;
      bottom: 2.5rem;
      right: 2.5rem;
      background: linear-gradient(135deg, #10b981 0%, #059669 100%);
      color: #fff;
      padding: 1rem 1.75rem;
      border-radius: 4px;
      box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4),
                  0 0 30px rgba(16, 185, 129, 0.25);
      z-index: 999;
      font-weight: 700;
      backdrop-filter: blur(8px);
      border: 1px solid rgba(255, 255, 255, 0.1);
      opacity: 0;
      transform: translateY(20px);
      pointer-events: none;
      transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    }
    #toast.show {
      opacity: 1;
      transform: translateY(0);
      pointer-events: auto;
    }
        
    .confirmations-controls {
      display: flex;
      align-items: center;
      gap: 0.65rem;
      margin-top: 0.65rem;
      flex-wrap: wrap;
    }
    .confirmations-label {
      font-size: 0.85rem;
      color: #94a3b8;
    }
    .confirmations-preset {
      padding: 0.3rem 0.5rem;
      background: rgba(255,255,255,0.07);
      border: 1px solid rgba(139,92,246,0.3);
      border-radius: 4px;
      color: #e2e8f0;
      font-size: 0.85rem;
    }
    .confirmations-status {
      font-size: 0.8rem;
      color: #94a3b8;
    }
    .confirmations-summary {
      font-size: 0.78rem;
      color: #64748b;
    }
    .confirmations-summary .on { color: #34d399; }
    .confirmations-summary .off { color: #64748b; }
    .confirmations-summary .lock {
      margin-left: 0.15rem;
      color: #f59e0b;
      font-size: 0.72rem;
    }
    .confirmations-custom {
      display: flex;
      align-items: center;
      gap: 0.85rem;
      flex-wrap: wrap;
      width: 100%;
      padding: 0.35rem 0 0 0.15rem;
    }
    .confirmations-custom.is-readonly .confirmations-sub {
      opacity: 0.82;
      cursor: default;
    }
    .confirmations-sub {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      font-size: 0.82rem;
      color: #cbd5e1;
      cursor: pointer;
    }
    .confirmations-sub code {
      font-size: 0.78rem;
      color: #a78bfa;
    }
    .confirmations-sub.is-locked {
      opacity: 0.72;
      cursor: not-allowed;
    }
    /* Photo detail modal (also used by blast composer overlay patterns) */
    .modal-overlay {
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
      background: rgba(15, 23, 42, 0.75);
      backdrop-filter: blur(12px);
      z-index: 1000;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 1.5rem;
    }
    .modal-card {
      background: #0f172a;
      border: 1px solid rgba(139, 92, 246, 0.25);
      border-radius: 4px;
      width: 100%;
      max-width: 500px;
      box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 40px rgba(139, 92, 246, 0.15);
      overflow: hidden;
      animation: modal-enter 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    }
    @keyframes modal-enter {
      from { transform: scale(0.95); opacity: 0; }
      to { transform: scale(1); opacity: 1; }
    }
    .modal-header {
      padding: 1.25rem 1.5rem;
      border-bottom: 1px solid rgba(255, 255, 255, 0.08);
      display: flex;
      align-items: center;
      justify-content: space-between;
    }
    .btn-close {
      background: none;
      border: none;
      color: #94a3b8;
      font-size: 1.5rem;
      cursor: pointer;
      line-height: 1;
      padding: 0.25rem;
      transition: color 0.2s;
    }
    .btn-close:hover {
      color: #fff;
    }
    .form-group {
      margin-bottom: 1rem;
    }
    .form-group label {
      display: block;
      font-size: 0.8rem;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: #a78bfa;
      font-weight: 700;
      margin-bottom: 0.5rem;
    }
    .form-group input, .form-group select, .form-group textarea {
      box-sizing: border-box;
      width: 100%;
      background: rgba(255, 255, 255, 0.05);
      border: 1px solid rgba(139, 92, 246, 0.25);
      border-radius: 4px;
      color: #e2e8f0;
      padding: 0.6rem 0.75rem;
      font-size: 0.9rem;
      font-family: inherit;
      outline: none;
      transition: border-color 0.2s, box-shadow 0.2s;
    }
    .form-group input:focus, .form-group select:focus, .form-group textarea:focus {
      border-color: #8b5cf6;
      box-shadow: 0 0 10px rgba(139, 92, 246, 0.25);
    }

    /* Operator inmate / contact cells (tables + inbox) */
    .op-inmate {
      display: flex;
      flex-direction: column;
      gap: 0.2rem;
      line-height: 1.3;
      min-width: 7rem;
    }
    .op-inmate__row {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 0.35rem;
    }
    .op-inmate__bop {
      font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
      font-size: 0.78rem;
      font-weight: 700;
      color: #a5b4fc;
      letter-spacing: 0.03em;
    }
    .op-inmate__name {
      font-size: 0.84rem;
      font-weight: 500;
      color: #e2e8f0;
      text-transform: uppercase;
      letter-spacing: 0.02em;
    }
    table td .op-inmate__name {
      max-width: 14rem;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    /* Inbox row: the inmate cell is ONE line, NAME-FIRST (Gmail leads with the
       name you recognize, not the BOP id). Flatten the stacked table block to a
       row and reorder via flex `order`: name bold up front, BOP demoted to a
       small muted id after it. */
    .inbox-convo-row__label .op-inmate {
      flex-direction: row;
      flex-wrap: nowrap;
      align-items: baseline;
      gap: 0.3rem;
      min-width: 0;
      line-height: 1.3;
    }
    .inbox-convo-row__label .op-inmate__name {
      order: 0;
      max-width: none;
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      text-transform: none;
      letter-spacing: 0;
      font-size: var(--inbox-row-label-size);
      font-weight: 600;
      color: #e2e8f0;
    }
    .inbox-convo-row.is-unread .inbox-convo-row__label .op-inmate__name {
      color: #f8fafc;
      font-weight: 700;
    }
    .inbox-convo-row__label .op-inmate__row {
      order: 1;
      flex-wrap: nowrap;
      flex-shrink: 0;
    }
    /* BOP demoted: smaller, muted, secondary to the name. */
    .inbox-convo-row__label .op-inmate__bop {
      font-size: 0.68rem;
      font-weight: 500;
      color: #64748b;
      letter-spacing: 0.02em;
    }
    /* Repeated sender (consecutive rows, same inmate): dim the whole cell so the
       SUBJECT below reads as the differentiator, not the repeated name. */
    .inbox-convo-row.is-same-sender .inbox-convo-row__label .op-inmate__name {
      font-weight: 400;
      color: #94a3b8;
    }
    .inbox-convo-row.is-same-sender.is-unread .inbox-convo-row__label .op-inmate__name {
      color: #cbd5e1;
      font-weight: 500;
    }
    /* Account tag is secondary — only surface it on hover or when the row is open. */
    .inbox-convo-row .inbox-convo-row__acct-tag { display: none; }
    .inbox-convo-row:hover .inbox-convo-row__acct-tag,
    .inbox-convo-row.is-active .inbox-convo-row__acct-tag { display: inline; }
    /* Soften ALL status pills to a quiet dot-accent so status stops competing with
       the live signals (unread / needs-you). Applied in the inbox row, the thread
       header, AND the System-page status contexts (blocked-inmates roster + LISA
       welcome summary) so the SAME relationship/status reads identically everywhere —
       the "• friend" language, not a loud oval on one page and a dot on another. One
       consistent family: green dot = good (friend/paid), red dot = dead relationship
       (blocked / no access / removed us), amber = trial/expired, blue = trial-active.
       The top status bar keeps its own dot rule; dashboard/blast-table pills that read
       as loud-on-purpose are NOT in scope. */
    .inbox-convo-row__status .pill,
    .thread-header__status .pill,
    #blocked-inmates-list .pill,
    .owner-welcome-summary .pill {
      padding: 0;
      background: none;
      border: none;
      box-shadow: none;
      font-size: 0.6rem;
      font-weight: 600;
      letter-spacing: 0.04em;
    }
    .inbox-convo-row__status .pill::before,
    .thread-header__status .pill::before,
    #blocked-inmates-list .pill::before,
    .owner-welcome-summary .pill::before {
      content: '•';
      margin-right: 0.2rem;
    }
    .inbox-convo-row__status .pill-ok,
    .thread-header__status .pill-ok,
    #blocked-inmates-list .pill-ok,
    .owner-welcome-summary .pill-ok { color: #5b9c86; }
    .inbox-convo-row__status .pill-ok::before,
    .thread-header__status .pill-ok::before,
    #blocked-inmates-list .pill-ok::before,
    .owner-welcome-summary .pill-ok::before { color: #34d399; }
    /* Dead relationship — muted red accent (blocked / no access / removed us). */
    .inbox-convo-row__status .pill-crit,
    .thread-header__status .pill-crit,
    #blocked-inmates-list .pill-crit,
    .owner-welcome-summary .pill-crit { color: #b56b6b; }
    .inbox-convo-row__status .pill-crit::before,
    .thread-header__status .pill-crit::before,
    #blocked-inmates-list .pill-crit::before,
    .owner-welcome-summary .pill-crit::before { color: #ef4444; }
    /* Trial state — amber (expiring/expired/inactive) and blue (trial Nd active). */
    .inbox-convo-row__status .pill-warn,
    .thread-header__status .pill-warn,
    #blocked-inmates-list .pill-warn,
    .owner-welcome-summary .pill-warn { color: #b58a4a; }
    .inbox-convo-row__status .pill-warn::before,
    .thread-header__status .pill-warn::before,
    #blocked-inmates-list .pill-warn::before,
    .owner-welcome-summary .pill-warn::before { color: #f59e0b; }
    .inbox-convo-row__status .pill-info,
    .thread-header__status .pill-info,
    #blocked-inmates-list .pill-info,
    .owner-welcome-summary .pill-info { color: #6a8fc4; }
    .inbox-convo-row__status .pill-info::before,
    .thread-header__status .pill-info::before,
    #blocked-inmates-list .pill-info::before,
    .owner-welcome-summary .pill-info::before { color: #60a5fa; }
    .op-inmate__tag {
      font-size: 0.65rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: #94a3b8;
      background: rgba(148, 163, 184, 0.14);
      border: 1px solid rgba(148, 163, 184, 0.22);
      border-radius: 4px;
      padding: 0.12rem 0.4rem;
      line-height: 1.2;
    }
    .op-inmate--inline {
      flex-direction: row;
      flex-wrap: wrap;
      align-items: baseline;
      gap: 0.35rem;
    }
    .op-inmate--inline .op-inmate__name::before {
      content: '·';
      margin-right: 0.35rem;
      color: #64748b;
      font-weight: 400;
    }
    .op-contact {
      display: flex;
      flex-direction: column;
      gap: 0.15rem;
      line-height: 1.25;
    }
    .op-contact__name {
      font-size: 0.84rem;
      font-weight: 600;
      color: #f1f5f9;
      max-width: 12rem;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .op-contact__meta {
      font-size: 0.76rem;
      color: #94a3b8;
      font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    }
    table td .op-inmate,
    table td .op-contact {
      padding: 0.1rem 0;
    }

    /* Recent issues / error cards */
    .err-card {
      list-style: none;
      margin-bottom: 1rem;
      padding: 1rem 1.25rem;
      border-radius: 4px;
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      gap: 0.75rem;
      border-left: 4px solid;
    }
    .err-card--incoming {
      background: rgba(139, 92, 246, 0.08);
      border-left-color: #8b5cf6;
    }
    .err-card--relay {
      background: rgba(239, 68, 68, 0.06);
      border-left-color: #ef4444;
    }
    .err-card--relay.err-card--relay-highlight {
      box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.55), 0 0 18px rgba(239, 68, 68, 0.25);
      animation: relay-failure-pulse 0.85s ease-in-out 2;
    }
    @keyframes relay-failure-pulse {
      0%, 100% { background: rgba(239, 68, 68, 0.06); }
      50% { background: rgba(239, 68, 68, 0.16); }
    }
    .err-card--outbound {
      background: rgba(245, 158, 11, 0.06);
      border-left-color: #f59e0b;
    }
    .err-card--info {
      list-style: none;
      margin-bottom: 0.75rem;
      padding: 0.75rem 1rem;
      border-radius: 4px;
      background: rgba(96, 165, 250, 0.08);
      border-left: 4px solid #60a5fa;
    }
    .err-card__head {
      display: flex;
      align-items: center;
      gap: 0.75rem;
      width: 100%;
      flex-wrap: wrap;
      padding-bottom: 0.5rem;
      margin-bottom: 0.25rem;
      border-bottom: 1px solid;
    }
    .err-card--incoming .err-card__head { border-bottom-color: rgba(139, 92, 246, 0.15); }
    .err-card--relay .err-card__head { border-bottom-color: rgba(239, 68, 68, 0.15); }
    .err-card--outbound .err-card__head { border-bottom-color: rgba(245, 158, 11, 0.15); }
    .err-card__badge {
      font-size: 0.72rem;
      border-radius: 4px;
      padding: 2px 7px;
      font-weight: 700;
      letter-spacing: 0.02em;
    }
    .err-card--incoming .err-card__badge {
      background: rgba(139, 92, 246, 0.2);
      color: #a78bfa;
    }
    .err-card--relay .err-card__badge {
      background: rgba(239, 68, 68, 0.15);
      color: #ef4444;
    }
    .err-card--outbound .err-card__badge {
      background: rgba(245, 158, 11, 0.15);
      color: #fbbf24;
    }
    .err-card__meta {
      color: #e2e8f0;
      font-size: 0.95rem;
    }
    .err-card__time {
      font-size: 0.8rem;
      margin-left: auto;
    }
    .err-card__section { width: 100%; }
    .err-card__label {
      font-size: 0.75rem;
      text-transform: uppercase;
      font-weight: 700;
      margin-bottom: 0.25rem;
      letter-spacing: 0.05em;
    }
    .err-card--incoming .err-card__label { color: #a78bfa; }
    .err-card--relay .err-card__label { color: #f87171; }
    .err-card--outbound .err-card__label { color: #fbbf24; }
    .err-card__text {
      font-size: 0.9rem;
      color: var(--text);
      white-space: pre-wrap;
      word-break: break-word;
      background: rgba(0, 0, 0, 0.25);
      padding: 0.75rem;
      border-radius: 4px;
      border: 1px solid;
    }
    .err-card--incoming .err-card__text {
      max-height: 12rem;
      overflow-y: auto;
      border-color: rgba(139, 92, 246, 0.1);
    }
    .err-card--relay .err-card__text {
      max-height: 10rem;
      overflow-y: auto;
      border-color: rgba(239, 68, 68, 0.1);
    }
    .err-card--outbound .err-card__text {
      max-height: 8rem;
      overflow-y: auto;
      border-color: rgba(245, 158, 11, 0.1);
    }
    .err-card__subject {
      font-size: 0.9rem;
      color: #f1f5f9;
      font-style: italic;
    }
    .err-card__reason {
      font-size: 0.9rem;
      color: #fbbf24;
    }
    .err-card__actions {
      display: flex;
      gap: 0.5rem;
      flex-wrap: wrap;
      margin-top: 0.25rem;
    }
    .err-card__reply {
      display: none;
      flex-direction: column;
      gap: 0.5rem;
      width: 100%;
      margin-top: 0.5rem;
      padding: 0.75rem;
      border-radius: 4px;
      border: 1px solid;
    }
    .err-card__reply textarea {
      width: 100%;
      background: rgba(255, 255, 255, 0.05);
      border-radius: 4px;
      color: var(--text);
      padding: 0.5rem;
      font-size: 0.9rem;
      resize: vertical;
    }
    .err-card--incoming .err-card__reply {
      background: rgba(139, 92, 246, 0.03);
      border-color: rgba(139, 92, 246, 0.2);
    }
    .err-card__reply-actions { display: flex; gap: 0.5rem; }
    .err-btn-incoming { color: #a78bfa; border-color: rgba(139, 92, 246, 0.35); }
    .err-btn-relay { color: #f87171; border-color: rgba(239, 68, 68, 0.35); }
    .err-card__reply--incoming {
      background: rgba(139, 92, 246, 0.03);
      border-color: rgba(139, 92, 246, 0.2);
    }
    .err-card__reply--incoming textarea { border: 1px solid rgba(139, 92, 246, 0.4); }
    .err-card__reply--relay {
      background: rgba(239, 68, 68, 0.03);
      border-color: rgba(239, 68, 68, 0.2);
    }
    .err-card__reply--relay textarea { border: 1px solid rgba(239, 68, 68, 0.4); }

    /* Inbox */
    .inbox-tab {
      padding: var(--inbox-tab-pad);
      border-radius: 4px;
      cursor: pointer;
      white-space: nowrap;
      font-size: var(--inbox-tab-size);
      border: 1px solid rgba(139, 92, 246, 0.2);
      background: rgba(15, 23, 42, 0.4);
      color: #94a3b8;
    }
    .inbox-tab.is-active {
      border-color: rgba(139, 92, 246, 0.6);
      background: rgba(109, 40, 217, 0.35);
      color: #c4b5fd;
    }
    /* ── Gmail-style per-inmate thread grouping ── */
    .inbox-group { border-bottom: 1px solid rgba(139, 92, 246, 0.08); }
    .inbox-group__header {
      display: grid;
      grid-template-columns: 1.1rem 1fr auto;
      align-items: center;
      gap: 0.5rem;
      padding: 0.5rem 0.7rem;
      cursor: pointer;
      position: relative;
      transition: background 0.14s ease;
    }
    .inbox-group__header:hover { background: rgba(255, 255, 255, 0.04); }
    .inbox-group.is-open > .inbox-group__header { background: rgba(124, 58, 237, 0.12); }
    .inbox-group.has-needs > .inbox-group__header::before {
      content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: #f59e0b;
    }
    .inbox-group__caret {
      display: inline-flex; align-items: center; justify-content: center;
      color: #64748b; transition: transform 0.15s ease;
    }
    .inbox-group.is-open .inbox-group__caret { transform: rotate(90deg); color: #a78bfa; }
    .inbox-group__id { min-width: 0; display: flex; align-items: baseline; gap: 0.35rem; overflow: hidden; }
    /* the inmate cell inside a group header uses the same name-first flatten as a row */
    .inbox-group__id .op-inmate { flex-direction: row; flex-wrap: nowrap; align-items: baseline; gap: 0.3rem; min-width: 0; }
    .inbox-group__id .op-inmate__name { order: 0; font-size: 0.88rem; font-weight: 600; color: #e2e8f0; text-transform: none; letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .inbox-group.has-unread .inbox-group__id .op-inmate__name { color: #f8fafc; font-weight: 700; }
    .inbox-group__id .op-inmate__row { order: 1; flex-shrink: 0; }
    .inbox-group__id .op-inmate__bop { font-size: 0.68rem; font-weight: 500; color: #64748b; }
    .inbox-group__meta { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; }
    .inbox-group__count { font-size: 0.68rem; color: #64748b; font-variant-numeric: tabular-nums; }
    .inbox-group__badge {
      min-width: 0; padding: 0; border-radius: 0; background: none; color: #c4b5fd;
      font-size: 0.68rem; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; line-height: 1.35;
    }
    .inbox-group.has-needs .inbox-group__badge { background: none; color: #fcd34d; }
    .inbox-group__children { display: none; background: rgba(2, 6, 20, 0.35); }
    .inbox-group.is-open > .inbox-group__children { display: block; }
    /* Child rows are subject-led: no sender block, so collapse the grid to a single
       line — [star] subject — snippet ............ time/actions — indented under the
       group. Reuses .inbox-convo-row so all click/selection/bulk/hover handlers apply. */
    .inbox-convo-row.is-child {
      grid-template-columns: 1.3rem 1fr auto;
      grid-template-areas: 'star body meta';
      padding: 0.3rem 0.7rem 0.3rem 1.5rem;
      min-height: 0;
    }
    .inbox-convo-row.is-child .inbox-convo-row__bulk-cb { display: none; }
    .inbox-convo-row.is-child .inbox-convo-row__star { grid-area: star; }
    .inbox-convo-row.is-child .inbox-convo-row__body { grid-area: body; display: flex; align-items: baseline; gap: 0.4rem; min-width: 0; }
    .inbox-convo-row.is-child .inbox-convo-row__meta { grid-area: meta; }
    .inbox-convo-row.is-child .inbox-convo-row__subject { max-width: 72%; }
    .inbox-group__showall {
      display: block; width: 100%; text-align: left;
      padding: 0.4rem 0.7rem 0.4rem 2.4rem;
      background: none; border: none; cursor: pointer;
      color: #a78bfa; font-family: inherit; font-size: 0.76rem; font-weight: 600;
    }
    .inbox-group__showall:hover { color: #c4b5fd; text-decoration: underline; }

    .inbox-convo-row {
      /* Two-line Gmail row tuned for the narrow (~300px) list pane:
         line 1 = [cb] [star] sender ............ time/actions
         line 2 = ............... subject — snippet (spans sender+body) */
      display: grid;
      grid-template-columns: auto auto 1fr auto;
      grid-template-areas:
        'cb star sender meta'
        'cb star body   body';
      align-items: center;
      column-gap: 0.45rem;
      row-gap: 0.08rem;
      padding: 0.38rem 0.7rem;
      cursor: pointer;
      border-bottom: 1px solid rgba(139, 92, 246, 0.07);
      position: relative;
      transition: background 0.14s ease;
    }
    .inbox-convo-row__bulk-cb { grid-area: cb; align-self: center; }
    .inbox-convo-row__star { grid-area: star; align-self: center; transition: color 0.12s ease; }
    .inbox-convo-row__sender { grid-area: sender; align-self: center; }
    .inbox-convo-row__body { grid-area: body; align-self: center; }
    .inbox-convo-row__meta { grid-area: meta; align-self: center; }
    .inbox-convo-row:hover { background: rgba(255, 255, 255, 0.04); }
    /* Selected (open) thread — must be unmistakable. Stronger fill + a bold
       left accent bar, and it wins over needs-attention/hover so you always
       know which thread the reading pane is showing. */
    .inbox-convo-row.is-active,
    .inbox-convo-row.is-active:hover,
    .inbox-convo-row.needs-attention.is-active {
      background: rgba(124, 58, 237, 0.32);
    }
    .inbox-convo-row.is-active .inbox-convo-row__label,
    .inbox-convo-row.is-active .inbox-convo-row__subject { color: #f5f3ff; }
    .inbox-convo-row.is-active::before,
    .inbox-convo-row.needs-attention::before {
      content: '';
      position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
    }
    .inbox-convo-row.needs-attention { background: rgba(245, 158, 11, 0.08); }
    .inbox-convo-row.needs-attention::before { background: #f59e0b; }
    /* Active accent bar is thicker + brighter and always wins over needs-attention. */
    .inbox-convo-row.is-active::before,
    .inbox-convo-row.needs-attention.is-active::before {
      background: #a78bfa;
      width: 4px;
      box-shadow: 0 0 8px rgba(167, 139, 250, 0.5);
    }
    /* Star reflects needs_attention (read-only indicator for now). */
    .inbox-convo-row__star {
      display: inline-flex;
      align-items: center;
      color: #475569;
      flex-shrink: 0;
    }
    .inbox-convo-row__star.is-on { color: #f59e0b; }
    .inbox-convo-row__star svg { fill: currentColor; }
    .inbox-convo-row__sender {
      display: flex;
      align-items: center;
      gap: 0.35rem;
      min-width: 0;
    }
    .inbox-convo-row__body {
      display: flex;
      align-items: baseline;
      gap: 0.4rem;
      min-width: 0;
    }
    .inbox-convo-row__subject {
      flex-shrink: 0;
      max-width: 72%;
      font-size: var(--inbox-preview-size);
      font-weight: 600;
      color: #cbd5e1;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .inbox-convo-row.is-unread .inbox-convo-row__subject { color: #f1f5f9; }
    /* Search-thread rows ("Google - ...") are AI-driven lookups, not conversation —
       mute + italicize so they visually recede behind real inmate/family messages. */
    .inbox-convo-row__subject.is-search-thread {
      font-weight: 500;
      font-style: italic;
      color: #7c8aa0;
    }
    .inbox-convo-row.is-unread .inbox-convo-row__subject.is-search-thread { color: #94a3b8; }
    .inbox-convo-row__snippet {
      flex: 1;
      min-width: 0;
      font-size: var(--inbox-preview-size);
      color: #64748b;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .inbox-convo-row__snippet .msg-preview__body {
      display: inline;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .inbox-convo-row__meta {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      /* FIXED width (was min-width) so swapping the time for the hover action
         button never changes the column width → the row no longer reflows/"shakes"
         as the mouse moves down the list. Fits both "12:19a" and the 1.65rem button. */
      width: 4.1rem;
      flex-shrink: 0;
      overflow: hidden;
    }
    .inbox-convo-row__actions { display: none; align-items: center; gap: 0.1rem; }
    .inbox-convo-row:hover .inbox-convo-row__time { display: none; }
    .inbox-convo-row:hover .inbox-convo-row__actions { display: flex; }
    .inbox-row-act {
      width: 1.65rem; height: 1.65rem;
      display: grid; place-items: center;
      border: none; border-radius: 4px; background: none;
      color: #64748b; cursor: pointer;
      transition: background 0.1s, color 0.1s;
    }
    .inbox-row-act:hover { background: rgba(255, 255, 255, 0.08); color: #f1f5f9; }
    .inbox-attention-badge {
      display: inline-block;
      font-size: 0.65rem;
      font-weight: 700;
      letter-spacing: 0.04em;
      color: #92400e;
      background: #fef3c7;
      border-radius: 4px;
      padding: 0.05rem 0.35rem;
      margin-right: 0.25rem;
      vertical-align: middle;
    }
    /* One-line orientation above the thread list. Neutral bar; the needs-you part
       carries the amber accent (actionable), the unread part is muted (informational)
       — clean text, no pills. */
    .inbox-held-summary {
      padding: 0.4rem 0.85rem;
      font-size: 0.76rem;
      font-weight: 600;
      color: #94a3b8;
      background: rgba(255, 255, 255, 0.02);
      border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }
    .inbox-held-summary__needs { color: #fbbf24; }
    .inbox-held-summary__needs::before {
      content: '•';
      margin-right: 0.3rem;
      color: #f59e0b;
    }
    .inbox-held-summary__unread { color: #94a3b8; }
    .inbox-convo-row.is-unread .inbox-convo-row__label { color: #f8fafc; font-weight: 700; }
    .inbox-convo-row__unread-dot {
      display: inline-block;
      width: 0.45rem;
      height: 0.45rem;
      border-radius: 50%;
      background: #8b5cf6;
      flex-shrink: 0;
      box-shadow: 0 0 6px rgba(139, 92, 246, 0.6);
    }
    .inbox-convo-row__bulk-cb {
      cursor: pointer;
      flex-shrink: 0;
    }
    .inbox-bulk-toolbar {
      display: flex;
      align-items: center;
      gap: 0.5rem;
      padding: 0.4rem 0.85rem;
      background: rgba(56, 189, 248, 0.1);
      border-bottom: 1px solid rgba(56, 189, 248, 0.25);
      font-size: 0.78rem;
    }
    .inbox-bulk-toolbar__count { color: #94a3b8; margin-right: 0.25rem; }
    .msg-card--held_for_review .msg-card__direction { color: #fbbf24; }
    .inbox-convo-row__label {
      flex: 1;
      min-width: 0;
      font-weight: 600;
      font-size: var(--inbox-row-label-size);
      color: #e2e8f0;
      line-height: 1.3;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .inbox-convo-row.is-active .inbox-convo-row__label { color: #c4b5fd; }
    .inbox-convo-row__acct-tag {
      font-size: 0.68rem;
      font-weight: 600;
      letter-spacing: 0.03em;
      color: #a78bfa;
      background: rgba(109, 40, 217, 0.2);
      border: 1px solid rgba(139, 92, 246, 0.35);
      border-radius: 4px;
      padding: 0.05rem 0.35rem;
      vertical-align: middle;
    }
    .chrome-profile-link {
      cursor: pointer;
    }
    .chrome-profile-link:hover {
      text-decoration: underline;
      text-underline-offset: 2px;
    }
    .chrome-profile-link:focus-visible {
      outline: 2px solid rgba(167, 139, 250, 0.6);
      outline-offset: 2px;
      border-radius: 2px;
    }
    .inbox-convo-row.is-active .inbox-convo-row__acct-tag {
      color: #e9d5ff;
      border-color: rgba(167, 139, 250, 0.5);
    }
    .inbox-channel-chip {
      flex-shrink: 0;
      font-size: 0.62rem;
      font-weight: 700;
      letter-spacing: 0.05em;
      border-radius: 4px;
      padding: 0.07rem 0.34rem;
      vertical-align: middle;
      line-height: 1.25;
    }
    .inbox-channel-chip--cl {
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.32);
      border: 1px solid #8b5cf6;
    }
    .inbox-channel-chip--wa {
      color: #5eead4;
      background: rgba(13, 148, 136, 0.32);
      border: 1px solid #2dd4bf;
    }
    .inbox-channel-chip--gv {
      color: #67e8f9;
      background: rgba(6, 182, 212, 0.28);
      border: 1px solid #22d3ee;
    }
    .inbox-convo-row__time {
      font-size: 0.72rem;
      color: #64748b;
      white-space: nowrap;
      font-variant-numeric: tabular-nums;
    }
    .inbox-convo-row.is-unread .inbox-convo-row__time { color: #cbd5e1; font-weight: 600; }
    /* Thread cards: clamp teaser; full text when more/less expanded */
    .msg-card__body .msg-preview--truncated .msg-preview__body {
      display: -webkit-box;
      -webkit-line-clamp: 6;
      -webkit-box-orient: vertical;
      overflow: hidden;
      line-height: 1.45;
    }
    .msg-card__body.is-preview-expanded .msg-preview__body,
    .msg-card__body .msg-preview--expanded .msg-preview__body {
      display: block;
      -webkit-line-clamp: unset;
      overflow: visible;
    }
    .inbox-empty, .inbox-error {
      padding: 1rem;
      font-size: 0.82rem;
    }
    .inbox-thread-focus-bar {
      flex-shrink: 0;
      padding: 0 1rem;
    }
    .inbox-thread-focus-bar:not([hidden]) + .inbox-thread,
    .inbox-thread-load-older:not([hidden]) {
      padding-top: 0.5rem;
    }
    .inbox-thread + .inbox-thread-load-older:not([hidden]) {
      padding-top: 0;
      padding-bottom: 0.5rem;
    }
    .inbox-thread-load-older {
      flex-shrink: 0;
      padding: 0 1rem 0.35rem;
      text-align: center;
    }
    .inbox-thread-load-older-btn {
      font-size: 0.78rem;
      font-weight: 600;
      padding: 0.3rem 0.75rem;
      border-radius: 4px;
      border: 1px solid rgba(139, 92, 246, 0.35);
      background: rgba(30, 27, 75, 0.6);
      color: #c4b5fd;
      cursor: pointer;
    }
    .inbox-thread-load-older-btn:hover:not(:disabled) {
      background: rgba(109, 40, 217, 0.35);
    }
    .inbox-thread-load-older-btn:disabled {
      opacity: 0.6;
      cursor: wait;
    }
    .inbox-thread-filter {
      padding: 0.5rem 0.65rem;
      margin-bottom: 0;
      font-size: 0.8rem;
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.12);
      border: 1px solid rgba(139, 92, 246, 0.25);
      border-radius: 4px;
      flex-shrink: 0;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.35rem 0.5rem;
    }
    .inbox-thread-filter__show-all {
      margin-left: auto;
      flex-shrink: 0;
      font-size: 0.78rem;
      font-weight: 600;
      padding: 0.2rem 0.55rem;
      border-radius: 4px;
      border: 1px solid rgba(167, 139, 250, 0.45);
      background: rgba(109, 40, 217, 0.35);
      color: #e9d5ff;
      cursor: pointer;
    }
    .inbox-thread-filter__show-all:hover {
      background: rgba(124, 58, 237, 0.55);
    }
    .inbox-empty { color: #64748b; font-size: 0.85rem; }
    .inbox-error { color: #ef4444; }

    /* ── Event cards ──────────────────────────────────────────────────────── */
    /* Card foundation — shape/spacing only; COLOR comes from the author rules below,
       ALIGNMENT from the author auto-margins. Author rules set the real bg/edge; these
       are the fallback (system-ish) before an author class applies. */
    .msg-card {
      background: var(--card-system-bg);
      border: 1px solid var(--card-edge);
      border-left: var(--msg-card-border) solid var(--card-system-bar);
      border-radius: var(--msg-card-radius);
      padding: var(--msg-card-pad);
      max-width: 80%;
      display: flex;
      flex-direction: column;
      gap: 0.35rem;
      cursor: default;
      transition: border-color 0.15s, background 0.15s;
    }
    /* Continuation of the same author's exchange: vertical grouping ONLY. State classes
       must NEVER set margin-left/right — that is the alignment axis, owned solely by the
       author auto-margin rules. (This is the class of bug that staggered operator
       follow-ups to the wrong side.) */
    .msg-card.is-reply-to-prev {
      margin-top: -0.15rem;
      border-top-left-radius: 5px;
      border-top-right-radius: 5px;
    }

    /* ── CARD COLOR — one source of truth, token-driven (hybrid look) ──
       COLOR is keyed on AUTHOR only (deriveCardAuthor sets ev.author → .msg-card--author-*).
       Each author reads its tokens: --card-<author>-bg (fill), --card-<author>-bar (left
       accent), --card-<author>-edge (border), --card-<author>-dir (label text). This is the
       ONLY place card color is defined — no .messaging-hub duplicate, no per-kind color.
       ALIGNMENT is owned separately (author auto-margins, below); state classes never
       touch either axis' margins. */
    .msg-card--author-inmate {
      background: var(--card-inmate-bg); border-color: var(--card-edge);
      border-left-color: var(--card-inmate-bar);
    }
    .msg-card--author-contact {
      background: var(--card-contact-bg); border-color: var(--card-edge);
      border-left-color: var(--card-contact-bar);
    }
    .msg-card--author-operator {
      background: var(--card-operator-bg); border-color: var(--card-operator-edge);
      border-left-color: var(--card-operator-bar);
    }
    .msg-card--author-ai {
      background: var(--card-ai-bg); border-color: var(--card-ai-edge);
      border-left-color: var(--card-ai-bar);
    }
    .msg-card--author-system {
      background: var(--card-system-bg); border-color: var(--card-system-edge);
      border-left-color: var(--card-system-bar);
    }
    /* held_for_review is a STATE (needs-attention), not an author — amber tint wins
       (comes after the author rules; a held card's author would be system). Color/fill
       only — never margins. */
    .msg-card--held_for_review {
      background: var(--card-held-bg); border-color: var(--card-held-edge);
      border-left-color: var(--card-held-bar);
    }
    .msg-card.is-selected {
      background: var(--card-selected-bg); border-color: var(--card-selected-edge);
    }

    /* Direction text color by author (same token family) */
    .msg-card--author-inmate .msg-card__direction   { color: var(--card-inmate-dir); }
    .msg-card--author-contact .msg-card__direction  { color: var(--card-contact-dir); }
    .msg-card--author-operator .msg-card__direction { color: var(--card-operator-dir); }
    .msg-card--author-ai .msg-card__direction       { color: var(--card-ai-dir); }
    .msg-card--author-system .msg-card__direction   { color: var(--card-system-dir); }

    /* ── CARD ALIGNMENT — one source of truth, keyed on AUTHOR only ──
       Inbound (inmate/contact) → left.  Outbound (operator/ai) → right.  System → center.
       This is the ONLY place margin-left/right is set on a card. No state class, kind
       class, or theme override may set these — they may only change color/spacing/radius.
       Thread pane is a flex column, so auto-margins do the horizontal placement. */
    .msg-card--author-inmate,
    .msg-card--author-contact {
      margin-right: auto;
      border-bottom-left-radius: 4px;
    }
    .msg-card--author-operator,
    .msg-card--author-ai {
      margin-left: auto;
      border-bottom-right-radius: 4px;
    }
    .msg-card--author-system,
    .msg-card--held_for_review {
      margin-left: auto;
      margin-right: auto;
      max-width: 88%;
    }

    /* Header row */
    .msg-card__header {
      display: flex;
      align-items: center;
      gap: 0.5rem;
      font-size: var(--msg-card-header-size);
      letter-spacing: 0.04em;
    }
    .msg-card__direction {
      font-weight: 700;
      color: #e2e8f0;
      flex: 1;
    }
    .msg-card__time {
      color: #64748b;
      white-space: nowrap;
    }
    /* Per-message CorrLinks account badge (merged "All" view) — which line it went through. */
    .msg-card__acct-tag {
      font-size: 0.65rem;
      font-weight: 600;
      letter-spacing: 0.02em;
      border-radius: 3px;
      padding: 0 0.35em;
      white-space: nowrap;
      background: rgba(148,163,184,0.16);
      color: #94a3b8;
    }
    .msg-card__acct-tag--ai {
      background: rgba(167,139,250,0.16);
      color: #a78bfa;
    }
    .msg-card__acct-tag--operator {
      background: rgba(180,120,60,0.16);
      color: #b4783c;
    }
    .msg-card__acct-tag--approved {
      background: rgba(52,211,153,0.14);
      color: #6ee7b7;
    }
    .msg-card__acct-tag--draft {
      background: rgba(251,191,36,0.14);
      color: #fcd34d;
    }
    .msg-card__acct-tag--manual-cl {
      background: rgba(167,139,250,0.18);
      color: #c4b5fd;
    }
    .msg-card__acct-tag--system {
      background: rgba(148,163,184,0.16);
      color: #94a3b8;
    }
    .msg-time__rel {
      opacity: 0.55;
      font-size: 0.85em;
    }
    .msg-card__status {
      font-size: 0.68rem;
      border-radius: 3px;
      padding: 0 0.3em;
    }
    .msg-card__status--sent     { background: rgba(16,185,129,0.15); color: #34d399; }
    .msg-card__status--wa-sent     { background: rgba(148,163,184,0.18); color: #94a3b8; }
    .msg-card__status--wa-delivered { background: rgba(16,185,129,0.15); color: #34d399; }
    .msg-card__status--wa-read     { background: rgba(96,165,250,0.18); color: #60a5fa; }
    .msg-card__status--received { background: rgba(96,165,250,0.15); color: #60a5fa; }
    .msg-card__status--delayed  { background: rgba(234,179,8,0.22);  color: #fbbf24; font-weight: 600; }
    .msg-card__status--queued   { background: rgba(234,179,8,0.15);  color: #fbbf24; }
    .msg-card__status--failed   { background: rgba(239,68,68,0.15);  color: #f87171; }
    .msg-card__status--superseded { background: rgba(249,115,22,0.12); color: #fb923c; }
    .msg-card__recall-meta {
      font-size: 0.78rem;
      color: #fb923c;
      margin-left: 0.5rem;
      white-space: nowrap;
    }
    .msg-card--superseded { opacity: 0.72; }

    /* Body — readable text; actions live on buttons below */
    .msg-card__body {
      font-size: var(--msg-card-body-size);
      color: #cbd5e1;
      white-space: pre-wrap;
      word-break: break-word;
      line-height: 1.45;
      cursor: text;
      user-select: text;
    }
    .msg-card__internal-note .msg-card__action-btn {
      margin-left: 0.5rem;
      vertical-align: middle;
    }
    .inbox-convo-row__part-tag {
      display: inline-block;
      font-size: 0.68rem;
      font-weight: 600;
      color: #93c5fd;
      background: rgba(59, 130, 246, 0.15);
      border-radius: 4px;
      padding: 0.05rem 0.35rem;
      margin-right: 0.25rem;
      vertical-align: middle;
    }
    .owner-drafts-table thead th {
      font-size: 0.72rem;
      color: #94a3b8;
      text-align: left;
      padding: 0.35rem 0.75rem;
      border-bottom: 1px solid rgba(148, 163, 184, 0.2);
    }
    .msg-card__internal-note {
      font-size: 0.75rem;
      color: #64748b;
      font-style: italic;
    }
    .msg-card__relay-line {
      display: flex;
      flex-wrap: wrap;
      align-items: baseline;
      gap: 0.35rem 0.5rem;
      margin-top: 0.45rem;
      padding-top: 0.4rem;
      border-top: 1px solid rgba(148, 163, 184, 0.12);
    }
    .msg-card__relay-line .msg-card__direction {
      font-size: 0.82rem;
      color: #cbd5e1;
    }
    .msg-card__relay-line .msg-card__time {
      font-size: 0.72rem;
    }

    /* Action row — always visible */
    .msg-card__actions {
      display: flex;
      flex-wrap: wrap;
      gap: 0.35rem;
      margin-top: 0.15rem;
    }
    .msg-card__action-btn {
      font-size: var(--msg-card-action-size);
      padding: var(--msg-card-action-pad);
      border-radius: 4px;
      border: 1px solid transparent;
      cursor: pointer;
      background: rgba(255,255,255,0.06);
      color: #94a3b8;
      transition: background 0.12s, color 0.12s;
    }
    .msg-card__action-btn:hover   { background: rgba(255,255,255,0.12); color: #e2e8f0; }
    .msg-card__action-btn:disabled { opacity: 0.45; cursor: default; }

    .msg-card__action-btn--reply    { color: #a78bfa; border-color: rgba(167,139,250,0.25); }
    .msg-card__action-btn--reply:hover { background: rgba(139,92,246,0.15); }
    .msg-card__action-btn--fwd      { color: #34d399; border-color: rgba(52,211,153,0.25); }
    .msg-card__action-btn--fwd:hover { background: rgba(16,185,129,0.12); }
    .msg-card__action-btn--recall   { color: #f97316; border-color: rgba(249,115,22,0.25); }
    .msg-card__action-btn--recall:hover { background: rgba(249,115,22,0.12); }
    .msg-card__action-btn--reprocess { color: #60a5fa; border-color: rgba(96,165,250,0.25); }
    .msg-card__action-btn--reprocess:hover { background: rgba(59,130,246,0.12); }
    .msg-card__action-btn--send     { color: #34d399; border-color: rgba(52,211,153,0.25); }
    .msg-card__action-btn--send:hover { background: rgba(16,185,129,0.15); }
    .msg-card__action-btn--dismiss { color: #94a3b8; border-color: rgba(148,163,184,0.25); }
    .msg-card__action-btn--dismiss:hover { background: rgba(148,163,184,0.12); }
    .msg-card__action-btn--copy { color: #94a3b8; border-color: rgba(148,163,184,0.2); }
    .msg-card__action-btn--copy:hover { background: rgba(148,163,184,0.1); color: #e2e8f0; }

    /* Inline contact picker */
    .msg-card__contact-picker {
      display: flex;
      flex-wrap: wrap;
      gap: 0.3rem;
      background: rgba(13,148,136,0.08);
      border: 1px solid rgba(13,148,136,0.2);
      border-radius: 4px;
      padding: 0.4rem 0.5rem;
      margin-top: 0.2rem;
    }
    .msg-card__contact-pick-btn {
      font-size: 0.72rem;
      padding: 0.2rem 0.5rem;
      border-radius: 4px;
      border: 1px solid rgba(13,148,136,0.3);
      background: rgba(13,148,136,0.12);
      color: #5eead4;
      cursor: pointer;
    }
    .msg-card__contact-pick-btn:hover { background: rgba(13,148,136,0.22); }
    .msg-card__contact-pick-btn--cancel { border-color: rgba(100,116,139,0.3); background: rgba(100,116,139,0.1); color: #94a3b8; }

    /* Legend strip */
    #inbox-thread-legend {
      display: flex;
      flex-wrap: wrap;
      gap: 0.75rem;
      padding: var(--inbox-legend-pad) 1rem;
      border-bottom: 1px solid rgba(139,92,246,0.12);
      font-size: var(--inbox-legend-size);
      color: #64748b;
      flex-shrink: 0;
    }
    #inbox-thread-legend span {
      padding-left: 0.45rem;
      border-left-width: 3px;
      border-left-style: solid;
    }
    #inbox-thread-legend .inbox-legend__flow {
      border-left: none;
      padding-left: 0;
      color: #94a3b8;
    }

    @media (max-width: 640px) {
      .msg-card__actions { gap: 0.45rem; }
      .msg-card__action-btn { font-size: 0.78rem; padding: 0.28rem 0.65rem; }
    }

    /* ── Consolidated admin layout (2026-06) ───────────────────────────── */
    .auth-bar__head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 0.75rem;
      margin-bottom: 0.75rem;
    }
    .auth-bar--compact .auth-bar__fields { display: none; }
    .auth-bar--compact .auth-bar__hint { display: none; }
    .auth-bar--compact { margin-bottom: 1rem; padding: 1rem 1.25rem; }
    .auth-bar--compact #auth-msg:empty { display: none; }

    .status-bar {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      gap: 0.75rem 1.25rem;
      margin-bottom: 1.5rem;
      padding-bottom: 1rem;
      border-bottom: 1px solid var(--border-faint);
    }
    .status-bar__left {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem 0.75rem;
      flex: 1;
      min-width: 0;
    }
    .status-bar__right {
      display: flex;
      align-items: center;
      gap: 0.65rem;
      flex-shrink: 0;
    }
    .status-chips {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
      align-items: center;
    }
    .status-chip {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      cursor: default;
    }
    .status-chip[role="button"] { cursor: pointer; }
    .status-chips__clear { font-size: 0.85rem; }

    .infra-summary {
      font-size: 0.88rem;
      margin-bottom: 0.65rem;
      line-height: 1.45;
    }
    .workers-details {
      margin: 0.5rem 0 0.85rem;
      font-size: 0.85rem;
    }
    .workers-details summary {
      cursor: pointer;
      color: #94a3b8;
      font-weight: 600;
      margin-bottom: 0.5rem;
    }
    .workers-status-grid {
      display: flex;
      flex-wrap: wrap;
      gap: 0.35rem;
      margin-top: 0.5rem;
    }
    .worker-pill {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      margin: 0;
    }
    .channel-cards {
      display: flex;
      flex-wrap: wrap;
      /* flex-start (not the default stretch) so each card sizes to its own content —
         a 3-account card stays short instead of matching the 7-account card's height. */
      align-items: flex-start;
      gap: 0.6rem;
      margin-bottom: 0.75rem;
    }
    .channel-card {
      flex: 1 1 160px;
      min-width: 140px;
      background: rgba(255,255,255,0.04);
      border: 1px solid rgba(255,255,255,0.1);
      border-radius: 4px;
      padding: 0.55rem 0.7rem 0.5rem;
      display: flex;
      flex-direction: column;
      gap: 0.35rem;
    }
    .channel-card-err {
      border-color: rgba(239,68,68,0.45);
      background: rgba(239,68,68,0.07);
    }
    .ch-header {
      display: flex;
      align-items: center;
      gap: 0.4rem;
    }
    .ch-dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      flex-shrink: 0;
    }
    .ch-dot-ok  { background: #22c55e; }
    .ch-dot-warn { background: #f59e0b; }
    .ch-dot-err { background: #ef4444; }
    /* Stale/stopped tag on the channel title — clean text, colored dot, no pill.
       Surfaces a buried warn/stop automation line so it catches the eye up top. */
    .ch-attention {
      margin-left: auto;
      font-size: 0.66rem;
      font-weight: 600;
      letter-spacing: 0.02em;
      cursor: default;
    }
    .ch-attention::before { content: '•'; margin-right: 0.25rem; }
    .ch-attention-warn { color: #b58a4a; }
    .ch-attention-warn::before { color: #f59e0b; }
    .ch-attention-stop { color: #b56b6b; }
    .ch-attention-stop::before { color: #ef4444; }
    .ch-name {
      font-size: 0.82rem;
      font-weight: 600;
      color: #e2e8f0;
    }
    .ch-worker { font-size: 0.75rem; }
    .ch-ws-run { color: #86efac; }
    .ch-ws-stop { color: #fca5a5; }
    .ch-subtitle {
      font-size: 0.72rem;
      line-height: 1.3;
      margin-top: -0.1rem;
    }
    .ch-automation {
      display: flex;
      flex-direction: column;
      gap: 0.2rem;
    }
    .ch-auto-line {
      font-size: 0.75rem;
      line-height: 1.35;
    }
    .ch-auto-ok { color: #86efac; }
    .ch-auto-warn { color: #fcd34d; }
    .ch-auto-stop { color: #fca5a5; }
    .ch-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 0.3rem;
      margin-top: 0.1rem;
    }
    .ch-dot-sm { width: 6px; height: 6px; }
    .ch-dot-off { background: #64748b; }
    .ch-acct-list {
      display: flex;
      flex-direction: column;
      gap: 0.25rem;
      margin-top: 0.3rem;
      padding-top: 0.3rem;
      border-top: 1px solid rgba(255,255,255,0.07);
    }
    .ch-acct-row {
      display: flex;
      align-items: center;
      gap: 0.35rem 0.5rem;
      font-size: 0.76rem;
      /* Narrow channel cards (4-up grid → ~250px) couldn't fit label + status +
         2 buttons on one nowrap line, so the buttons overlapped the status text.
         Wrap instead: the buttons drop to their own right-aligned line when tight. */
      flex-wrap: wrap;
      row-gap: 0.3rem;
    }
    .ch-acct-label {
      font-weight: 500;
      color: #cbd5e1;
      min-width: 2.4rem;
      flex-shrink: 0;
    }
    .ch-acct-meta {
      font-size: 0.72rem;
      min-width: 0;
    }
    .ch-acct-btns {
      margin-left: auto;
      display: flex;
      align-items: center;
      gap: 0.5rem;
      flex-shrink: 0;
    }
    /* Rolled-up channel summary — leads the card so its health reads at a glance. */
    .ch-acct-summary {
      font-size: 0.76rem;
      color: #cbd5e1;
      font-weight: 500;
    }
    /* Per-account controls disclosure (collapsed by default). */
    .ch-acct-disclosure { margin-top: 0.15rem; }
    .ch-acct-disclosure__summary {
      cursor: pointer;
      list-style: none;
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      color: #a78bfa;
      font-size: 0.74rem;
      font-weight: 600;
      padding: 0.1rem 0;
    }
    .ch-acct-disclosure__summary::-webkit-details-marker { display: none; }
    .ch-acct-disclosure__caret {
      font-size: 0.6rem;
      color: #64748b;
      transition: transform 0.15s ease;
    }
    .ch-acct-disclosure[open] .ch-acct-disclosure__caret { transform: rotate(90deg); }
    /* On/off is a bare text toggle (turn off / turn on) — clean text, not a pill button.
       Still a <button> so the in-flight .disabled debounce works. */
    .ch-acct-toggle {
      background: none;
      border: none;
      padding: 0;
      cursor: pointer;
      font-family: inherit;
      font-size: 0.72rem;
      border-bottom: 1px dashed transparent;
      transition: color 0.12s, border-color 0.12s;
    }
    .ch-acct-toggle.is-on { color: #b58a4a; border-bottom-color: rgba(181, 138, 74, 0.4); }
    .ch-acct-toggle.is-on:hover { color: #fbbf24; border-bottom-color: rgba(245, 158, 11, 0.6); }
    .ch-acct-toggle.is-off { color: #5b9c86; border-bottom-color: rgba(91, 156, 134, 0.4); }
    .ch-acct-toggle.is-off:hover { color: #34d399; border-bottom-color: rgba(52, 211, 153, 0.6); }
    .ch-acct-toggle:disabled { opacity: 0.5; cursor: default; }
    /* View live → compact ⋯ affordance. */
    .ch-acct-kebab {
      background: none;
      border: none;
      padding: 0 0.15rem;
      cursor: pointer;
      color: #64748b;
      font-size: 0.85rem;
      font-weight: 700;
      letter-spacing: 1px;
      line-height: 1;
    }
    .ch-acct-kebab:hover { color: #a78bfa; }
    .btn-xs { padding: 0.2rem 0.5rem; font-size: 0.72rem; border-radius: 4px; }
    /* Channel / provider toggle + inspect buttons are SECONDARY controls — quiet them
       to ghost style so the status content leads and the page stops reading as a wall
       of saturated pills. Scoped to .channel-card + .settings-photo-row (the photo
       automation toggle is the same kind of on/off control) so the loud gradient
       .btn-warn / .btn-indigo / .btn-ok stay intact everywhere else (destructive
       confirms, primary CTAs). Semantic color is a faint tint at rest, full on hover. */
    .channel-card .btn-warn,
    .channel-card .btn-indigo,
    .channel-card .btn-ok,
    .settings-photo-row .btn-warn,
    .settings-photo-row .btn-ok {
      background: rgba(255, 255, 255, 0.03);
      border: 1px solid rgba(148, 163, 184, 0.22);
      box-shadow: none;
      font-weight: 500;
    }
    .channel-card .btn-warn,
    .settings-photo-row .btn-warn { color: #d3a463; }
    .channel-card .btn-warn:hover,
    .settings-photo-row .btn-warn:hover {
      background: rgba(245, 158, 11, 0.14);
      border-color: rgba(245, 158, 11, 0.5);
      color: #fbbf24;
    }
    .channel-card .btn-indigo { color: #9aa0e8; }
    .channel-card .btn-indigo:hover {
      background: rgba(99, 102, 241, 0.16);
      border-color: rgba(99, 102, 241, 0.5);
      color: #c7d2fe;
    }
    .channel-card .btn-ok,
    .settings-photo-row .btn-ok { color: #6bbf95; }
    .channel-card .btn-ok:hover,
    .settings-photo-row .btn-ok:hover {
      background: rgba(16, 185, 129, 0.14);
      border-color: rgba(16, 185, 129, 0.5);
      color: #34d399;
    }
    .ch-ok { color: #86efac; font-size: 0.72rem; }
    .operator-actions {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem;
    }
    .operator-actions [hidden] {
      display: none !important;
    }
    .operator-breakglass-hint {
      margin: 0 0 0.5rem;
      font-size: 0.82rem;
      line-height: 1.45;
    }
    .operator-breakglass-actions {
      margin-top: 0.25rem;
    }
    .runtime-heal-panel {
      margin: 0.5rem 0 0.75rem;
      padding: 0.65rem 0.75rem;
      border: 1px solid rgba(148, 163, 184, 0.22);
      border-radius: 4px;
      background: rgba(15, 23, 42, 0.35);
    }
    .runtime-heal-intro {
      margin: 0 0 0.5rem;
      font-size: 0.78rem;
      line-height: 1.45;
    }
    .runtime-heal-warn {
      margin: 0 0 0.5rem;
      padding: 0.4rem 0.55rem;
      font-size: 0.78rem;
      line-height: 1.45;
      color: #fbbf24;
      background: rgba(251, 191, 36, 0.1);
      border: 1px solid rgba(251, 191, 36, 0.35);
      border-radius: 4px;
    }
    .runtime-heal-block + .runtime-heal-block {
      margin-top: 0.65rem;
      padding-top: 0.65rem;
      border-top: 1px solid rgba(148, 163, 184, 0.15);
    }
    .runtime-heal-when {
      font-size: 0.75rem;
      font-weight: 400;
    }
    .runtime-heal-cols {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 0.75rem;
    }
    @media (max-width: 720px) {
      .runtime-heal-cols {
        grid-template-columns: 1fr;
      }
    }
    .runtime-heal-col-title {
      margin: 0 0 0.25rem;
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.04em;
    }
    .runtime-heal-list {
      margin: 0;
      padding-left: 1.1rem;
      font-size: 0.82rem;
      line-height: 1.5;
    }
    .runtime-heal-k {
      color: #cbd5e1;
    }
    .operator-inline-status { font-size: 0.78rem; color: #94a3b8; }
    .git-status-widget { font-size: 0.78rem; color: #94a3b8; }
    .btn-warn { background: linear-gradient(135deg,#f59e0b,#d97706); color: #fff; border: none; }
    .btn-ok { background: linear-gradient(135deg,#10b981,#059669); color: #fff; border: none; }
    .btn-indigo { background: linear-gradient(135deg,#6366f1,#4338ca); color: #fff; border: none; }
    .btn-danger-soft { background: linear-gradient(135deg,#f43f5e,#be123c); color: #fff; border: none; }
    .btn-sky { background: linear-gradient(135deg,#0ea5e9,#0284c7); color: #fff; border: none; }
    .btn-primary-gradient {
      background: linear-gradient(135deg,#7c3aed,#6d28d9);
      color: #fff;
      border: none;
      box-shadow: 0 3px 10px rgba(124,58,237,0.3);
    }

    .settings-trial-row,
    .settings-photo-row,
    .settings-danger-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.65rem;
      margin-bottom: 0.75rem;
    }
    .settings-photo-hint {
      margin: -0.35rem 0 0.85rem;
      font-size: 0.82rem;
      max-width: 42rem;
    }
    .settings-label { font-size: 0.85rem; color: #94a3b8; }
    #trial-days-input {
      width: 5rem;
      padding: 0.3rem 0.5rem;
      background: rgba(255,255,255,0.07);
      border: 1px solid rgba(139,92,246,0.3);
      border-radius: 4px;
      color: #e2e8f0;
      font-size: 0.85rem;
    }
    .issues-list { margin-bottom: 1.25rem; }
    .issues-list[hidden] { display: none !important; }
    .issues-list .alert-clickable {
      cursor: pointer;
      list-style: none;
      transition: background 0.15s ease;
    }
    .issues-list .alert-clickable:hover {
      background: rgba(251, 191, 36, 0.08);
      border-radius: 4px;
    }
    .status-chip[data-scroll-relay-failures] { cursor: pointer; }
    .status-chip[data-scroll-relay-failures]:hover { opacity: 0.92; }

    .stat--clickable { cursor: pointer; }
    .stat--clickable:hover {
      border-color: rgba(139,92,246,0.35);
      transform: translateY(-1px);
    }

    .hub-tabs {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem 1.25rem;
      margin-bottom: 0.75rem;
      border-bottom: 1px solid rgba(139,92,246,0.2);
      padding-bottom: 0.35rem;
    }
    .hub-tab-group {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.15rem;
    }
    .hub-tab-group-label {
      font-size: 0.68rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: #64748b;
      margin-right: 0.35rem;
    }
    .hub-tab {
      padding: var(--hub-tab-pad);
      background: none;
      border: none;
      border-bottom: 2px solid transparent;
      color: #64748b;
      font-size: var(--hub-tab-size);
      cursor: pointer;
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
    }
    .hub-tab.is-active {
      color: #a78bfa;
      border-bottom-color: #7c3aed;
      font-weight: 600;
    }
    .hub-tab-badge {
      font-size: 0.68rem;
      background: none;
      color: #fbbf24;
      padding: 0;
      border-radius: 0;
    }

    .hub-panel-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      flex-wrap: wrap;
      gap: 0.5rem;
      margin-bottom: 0.75rem;
    }
    .hub-panel-tools { display: flex; gap: 0.4rem; align-items: center; flex-wrap: wrap; }
    .admin-ui-off {
      display: none !important;
    }

    .inbox-layout {
      display: flex;
      border: 1px solid rgba(139,92,246,0.18);
      border-radius: 4px;
      overflow: hidden;
      flex: 1;
      min-height: 0;
      height: auto;
    }
    @media (min-width: 1100px) {
      .inbox-list {
        width: min(340px, 28vw);
        min-width: 300px;
      }
    }
    .inbox-list {
      width: 300px;
      min-width: 260px;
      border-right: 1px solid rgba(139,92,246,0.18);
      display: flex;
      flex-direction: column;
      background: rgba(15,23,42,0.5);
      min-height: 0;
      overflow: hidden;
    }
    /* Gmail-style rounded search pill: icon + input + clear, inside one field. */
    .inbox-list__search {
      margin: 0.6rem 0.7rem 0.45rem;
      padding: 0 0.7rem;
      height: 2.25rem;
      flex-shrink: 0;
      display: flex;
      align-items: center;
      gap: 0.5rem;
      background: rgba(255,255,255,0.05);
      border: 1px solid rgba(139,92,246,0.2);
      border-radius: 4px;
      transition: border-color 0.15s, background 0.15s;
    }
    .inbox-list__search:focus-within {
      border-color: rgba(139,92,246,0.45);
      background: rgba(255,255,255,0.07);
    }
    .inbox-list__search-icon { flex-shrink: 0; color: #64748b; }
    .inbox-list__search input {
      flex: 1;
      min-width: 0;
      box-sizing: border-box;
      background: none;
      border: none;
      color: #e2e8f0;
      font-size: 0.82rem;
      outline: none;
    }
    .inbox-list__search input::placeholder { color: #475569; }
    .inbox-search-clear {
      flex-shrink: 0;
      width: 1.4rem;
      height: 1.4rem;
      padding: 0;
      border-radius: 50%;
      border: none;
      background: none;
      color: #64748b;
      font-size: 1.05rem;
      line-height: 1;
      cursor: pointer;
    }
    .inbox-search-clear:hover { color: #e2e8f0; background: rgba(255,255,255,0.09); }
    /* Search scope hint — collapsed by default, revealed when the box has focus, so the
       search's real reach (names/contacts/subjects/BOP #/body) is discoverable without
       clutter at rest. */
    .inbox-list__search-hint {
      max-height: 0;
      overflow: hidden;
      opacity: 0;
      padding: 0 0.2rem;
      font-size: 0.68rem;
      color: #64748b;
      line-height: 1.4;
      transition: max-height 0.16s ease, opacity 0.16s ease, margin 0.16s ease;
    }
    .inbox-list__search:focus-within + .inbox-list__search-hint {
      max-height: 2.4rem;
      opacity: 1;
      margin: 0.15rem 0 0.1rem;
    }
    .inbox-list__search-hint kbd,
    .inbox-key-help kbd {
      font-family: inherit;
      font-size: 0.92em;
      color: #cbd5e1;
      background: rgba(255, 255, 255, 0.07);
      border: 1px solid rgba(255, 255, 255, 0.12);
      border-radius: 4px;
      padding: 0 0.28rem;
      line-height: 1.3;
    }
    @media (prefers-reduced-motion: reduce) {
      .inbox-list__search-hint { transition: none; }
    }
    /* Keyboard-shortcut help overlay ('?') */
    .inbox-key-help {
      position: fixed;
      inset: 0;
      z-index: 60;
      display: flex;
      align-items: center;
      justify-content: center;
      background: rgba(3, 6, 15, 0.6);
      backdrop-filter: blur(2px);
    }
    .inbox-key-help[hidden] { display: none; }
    .inbox-key-help__card {
      background: #0a1122;
      border: 1px solid rgba(255, 255, 255, 0.1);
      border-radius: 4px;
      padding: 1.1rem 1.3rem 1rem;
      min-width: 18rem;
      box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.7);
    }
    .inbox-key-help__title {
      font-size: 0.9rem;
      font-weight: 600;
      color: #f1f5f9;
      margin-bottom: 0.7rem;
    }
    .inbox-key-help__list { margin: 0; display: flex; flex-direction: column; gap: 0.3rem; }
    .inbox-key-help__list > div {
      display: flex;
      align-items: baseline;
      gap: 0.75rem;
    }
    .inbox-key-help__list dt {
      flex-shrink: 0;
      width: 3.2rem;
      font-family: inherit;
      font-size: 0.78rem;
      color: #cbd5e1;
    }
    .inbox-key-help__list dt::before { content: ''; }
    .inbox-key-help__list dd {
      margin: 0;
      font-size: 0.78rem;
      color: #94a3b8;
    }
    .inbox-key-help__hint {
      margin-top: 0.8rem;
      font-size: 0.68rem;
      color: #64748b;
    }
    /* Filter chip row (All / Unread / Needs you) — underline tabs, not pills */
    .inbox-list__chips {
      display: flex;
      gap: 1rem;
      padding: 0 0.7rem 0.55rem;
      border-bottom: 1px solid rgba(139,92,246,0.12);
      flex-shrink: 0;
    }
    .inbox-chip {
      padding: 0.15rem 0.1rem 0.4rem;
      border: none;
      border-bottom: 2px solid transparent;
      border-radius: 0;
      background: none;
      color: #94a3b8;
      font-size: 0.76rem;
      font-family: inherit;
      cursor: pointer;
      white-space: nowrap;
      transition: color 0.12s, border-color 0.12s;
    }
    .inbox-chip:hover { color: #cbd5e1; }
    .inbox-chip.is-active {
      color: #f1f5f9;
      font-weight: 600;
      border-bottom-color: #a78bfa;
    }
    .inbox-chip--attention.is-active {
      color: #fcd34d;
      border-bottom-color: #f59e0b;
    }
    .inbox-list__items { overflow-y: auto; flex: 1; min-height: 0; padding-bottom: 0.35rem; }
    .inbox-thread-pane { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-height: 0; }
    .inbox-thread-header {
      padding: var(--inbox-thread-header-pad);
      border-bottom: 1px solid rgba(139,92,246,0.15);
      background: rgba(15,23,42,0.4);
      font-size: var(--inbox-thread-header-size);
      color: #a78bfa;
      font-weight: 600;
      flex-shrink: 0;
    }
    .inbox-thread { flex: 1; min-height: 0; overflow-y: auto; padding: var(--inbox-thread-pad); padding-bottom: 1.25rem; display: flex; flex-direction: column; gap: var(--inbox-thread-gap); }
    .inbox-reply-area {
      padding: 0.75rem 1rem;
      border-top: 1px solid rgba(139,92,246,0.15);
      background: rgba(15,23,42,0.4);
      flex-shrink: 0;
    }
    .inbox-reply-area textarea {
      width: 100%;
      box-sizing: border-box;
      resize: vertical;
      min-height: 2.25rem;
      max-height: 5.5rem;
      background: rgba(255,255,255,0.09);
      border: 1px solid rgba(139,92,246,0.35);
      border-radius: 4px;
      color: #e2e8f0;
      padding: 0.55rem 0.75rem;
      font-size: var(--inbox-reply-font-size);
      font-family: inherit;
      outline: none;
    }
    .inbox-reply-actions { display: flex; justify-content: flex-end; margin-top: 0.5rem; gap: 0.5rem; align-items: center; }

    .hub-compose-form { max-width: 560px; display: grid; gap: 0.65rem; }
    .hub-compose-row { display: flex; gap: 0.65rem; flex-wrap: wrap; }
    .hub-compose-field { flex: 1; min-width: 160px; }
    .hub-compose-field label {
      font-size: 0.78rem;
      color: #94a3b8;
      display: block;
      margin-bottom: 0.3rem;
    }
    .hub-compose-field select,
    .hub-compose-field input,
    .hub-compose-field textarea {
      width: 100%;
      box-sizing: border-box;
      background: rgba(255,255,255,0.05);
      border: 1px solid rgba(139,92,246,0.25);
      border-radius: 4px;
      color: #e2e8f0;
      padding: 0.4rem 0.6rem;
      font-size: 0.85rem;
      font-family: inherit;
    }
    .hub-compose-actions { display: flex; align-items: center; gap: 0.75rem; }
    .hub-compose-picker { position: relative; }
    .hub-compose-picker__list {
      position: absolute;
      z-index: 40;
      left: 0;
      right: 0;
      top: calc(100% + 2px);
      margin: 0;
      padding: 0.25rem 0;
      list-style: none;
      max-height: 240px;
      overflow-y: auto;
      background: #1e1b2e;
      border: 1px solid rgba(139,92,246,0.35);
      border-radius: 4px;
      box-shadow: 0 8px 24px rgba(0,0,0,0.45);
    }
    .hub-compose-picker__list[hidden] { display: none !important; }
    .hub-compose-picker__item {
      padding: 0.45rem 0.65rem;
      cursor: pointer;
      font-size: 0.82rem;
      line-height: 1.35;
      color: #e2e8f0;
    }
    .hub-compose-picker__item:hover,
    .hub-compose-picker__item.is-active {
      background: rgba(139,92,246,0.18);
    }
    .hub-compose-picker__sublabel {
      display: block;
      font-size: 0.72rem;
      color: #94a3b8;
      margin-top: 0.1rem;
    }
    .hub-compose-picker__empty {
      padding: 0.45rem 0.65rem;
      font-size: 0.78rem;
      color: #64748b;
    }
    .unlinked-email {
      color: #fff;
      background: rgba(0,0,0,0.4);
      padding: 0.3rem 0.6rem;
      border-radius: 4px;
      border: 1px solid rgba(255,255,255,0.08);
      font-family: monospace;
    }

    .human-needed-section {
      border: 1px solid rgba(74, 222, 128, 0.25);
      border-radius: 4px;
      padding: 1rem 1.1rem;
      margin-bottom: 1rem;
      background: rgba(74, 222, 128, 0.06);
    }
    .human-needed-section--action {
      border-color: rgba(251, 191, 36, 0.55);
      background: rgba(251, 191, 36, 0.08);
    }
    .human-needed-primary {
      margin: 0.5rem 0 0.75rem;
      font-size: 0.95rem;
    }
    .human-needed-steps {
      margin: 0 0 0.75rem 1.1rem;
      padding: 0;
      font-size: 0.88rem;
    }
    .human-needed-intro {
      margin: 0 0 0.35rem;
    }
    .human-needed-accounts {
      display: flex;
      flex-direction: column;
      gap: 0.75rem;
      margin: 0.75rem 0 1rem;
    }
    .chrome-operator-modal { max-width: 32rem; }
    .chrome-fieldset { border: 0; padding: 0; margin: 0.75rem 0; }
    .chrome-fieldset legend { font-weight: 600; margin-bottom: 0.35rem; }
    .chrome-profile-list { display: flex; flex-direction: column; gap: 0.35rem; }
    .chrome-profile-option, .chrome-mode-option { display: block; margin: 0.25rem 0; }
    .login-challenge-card {
      border: 1px solid rgba(248, 113, 113, 0.35);
      background: rgba(127, 29, 29, 0.15);
      border-radius: 0.5rem;
      padding: 0.75rem 0.9rem;
    }
    .login-challenge-card__title {
      font-weight: 600;
      margin-bottom: 0.5rem;
    }
    .login-challenge-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem;
      margin-bottom: 0.35rem;
    }
    .login-challenge-label {
      min-width: 4.5rem;
      color: #94a3b8;
      font-size: 0.85rem;
    }
    .login-challenge-value {
      font-size: 0.9rem;
      word-break: break-all;
    }
    .login-challenge-hint {
      margin: 0.35rem 0 0;
      font-size: 0.82rem;
    }
    .jeff-review-note {
      margin: 0.75rem 0 0;
      padding: 0.65rem 0.75rem;
      border-radius: 4px;
      background: rgba(255, 255, 255, 0.04);
      border: 1px solid rgba(251, 191, 36, 0.25);
      font-size: 0.88rem;
      line-height: 1.45;
    }

    /* Settings layout by profile (visibility via admin_ui_profile.js) */
    body[data-admin-profile="operator"] .settings-more-panel summary {
      display: none;
    }
    body[data-admin-profile="operator"] .settings-more-body {
      margin-top: 0.75rem;
    }
    body.owner-minimal .settings-more-panel {
      margin-top: 0.65rem;
    }
    body.owner-minimal .settings-more-summary {
      cursor: pointer;
      font-size: 0.85rem;
    }
    body[data-admin-profile="owner"] .human-needed-section--action .human-needed-steps {
      display: block;
    }
    .status-bar__controls {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      flex-wrap: wrap;
    }
    body.owner-minimal .owner-insights-section {
      margin-bottom: 1.25rem;
    }
    body.owner-minimal .owner-stats-grid {
      display: flex;
      flex-wrap: wrap;
      gap: 0.65rem;
      margin-bottom: 0.85rem;
    }
    body.owner-minimal .owner-stat-card {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      min-width: 4.5rem;
      padding: 0.55rem 0.85rem;
      border-radius: 4px;
      background: rgba(255, 255, 255, 0.04);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }
    body.owner-minimal .owner-stat-card__n {
      font-size: 1.35rem;
      font-weight: 700;
      line-height: 1.1;
      color: #e8e8f0;
    }
    body.owner-minimal .owner-stat-card__l {
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.04em;
      color: #9ca3af;
      margin-top: 0.15rem;
    }
    body.owner-minimal .owner-stat-card--paid .owner-stat-card__n {
      color: #4ade80;
    }
    body.owner-minimal .owner-stat-card--friend .owner-stat-card__n {
      color: #86efac;
    }
    body.owner-minimal .owner-stat-card--trial .owner-stat-card__n {
      color: #fbbf24;
    }
    body.owner-minimal .owner-stat-card--paused .owner-stat-card__n {
      color: #9ca3af;
    }
    body.owner-minimal .owner-cl-breakdown {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
    }
    body.owner-minimal .owner-cl-chip {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      padding: 0.25rem 0.5rem;
      /* Soft tag, not a hard-bordered oval — quiet summary chip consistent with the
         rest of the admin chrome; still clickable (opens the Chrome profile). */
      border-radius: 4px;
      font-size: 0.8rem;
      background: rgba(255, 255, 255, 0.03);
      border: 1px solid transparent;
      font: inherit;
      color: inherit;
      cursor: pointer;
      transition: background 0.12s ease, border-color 0.12s ease;
    }
    body.owner-minimal .owner-cl-chip:hover {
      background: rgba(255, 255, 255, 0.07);
      border-color: rgba(167, 139, 250, 0.35);
    }
    body.owner-minimal .owner-cl-chip:focus-visible {
      outline: 2px solid rgba(167, 139, 250, 0.6);
      outline-offset: 2px;
    }
    body.owner-minimal .owner-cl-chip__label {
      font-weight: 600;
      color: #a5b4fc;
    }
    body.owner-minimal .owner-cl-chip__n {
      font-weight: 700;
      color: #f3f4f6;
    }
    body.owner-minimal .owner-cl-chip__tag {
      font-size: 0.65rem;
      text-transform: uppercase;
      color: #fbbf24;
      letter-spacing: 0.03em;
    }
    body.owner-minimal .owner-blast-intro {
      margin: 0 0 0.5rem;
      font-size: 0.85rem;
    }
    body.owner-minimal .owner-blast-table {
      width: 100%;
      font-size: 0.82rem;
      border-collapse: collapse;
    }
    body.owner-minimal .owner-blast-table th,
    body.owner-minimal .owner-blast-table td {
      padding: 0.35rem 0.5rem;
      text-align: left;
      border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }
    body.owner-minimal .owner-blast-status-pill {
      font-size: 0.72rem;
      text-transform: none;
      letter-spacing: 0;
    }
    body.owner-minimal .owner-blast-status-pill {
      vertical-align: middle;
    }
    body.owner-minimal .owner-blast-status-cell {
      min-width: 7rem;
    }
    body.owner-minimal .owner-blast-defer-note {
      display: block;
      margin-top: 0.25rem;
      font-size: 0.78rem;
      color: rgba(255, 255, 255, 0.55);
      line-height: 1.35;
    }
    body.owner-minimal .owner-blast-already-sent-note {
      margin: 0.55rem 0 0;
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-deferred-wrap {
      margin-top: 0.65rem;
    }
    body.owner-minimal .owner-blast-schedule {
      margin: 0 0 1rem;
      padding: 0.85rem 1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.1);
      background: rgba(0, 0, 0, 0.18);
    }
    body.owner-minimal .owner-blast-schedule__cadence {
      margin: 0 0 0.35rem;
    }
    body.owner-minimal .owner-blast-schedule__next {
      margin: 0;
    }
    body.owner-minimal .owner-blast-schedule__edit {
      margin-top: 0.65rem;
    }
    body.owner-minimal .owner-blast-schedule__edit > summary {
      cursor: pointer;
      font-size: 0.85rem;
      color: var(--accent, #7eb8ff);
      list-style: none;
    }
    body.owner-minimal .owner-blast-schedule__edit > summary::-webkit-details-marker {
      display: none;
    }
    body.owner-minimal .owner-blast-schedule__form {
      margin-top: 0.65rem;
      display: flex;
      flex-direction: column;
      gap: 0.65rem;
    }
    body.owner-minimal .owner-blast-schedule__field {
      display: flex;
      flex-direction: column;
      gap: 0.25rem;
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-schedule__select {
      max-width: 14rem;
      padding: 0.35rem 0.5rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.15);
      background: rgba(0, 0, 0, 0.25);
      color: inherit;
    }
    body.owner-minimal .owner-blast-schedule__mode {
      display: flex;
      flex-wrap: wrap;
      gap: 0.45rem;
    }
    body.owner-minimal .owner-blast-schedule__actions {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.55rem;
    }
    body.owner-minimal .owner-blast-schedule__status {
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-schedule__hint {
      margin: 0;
      font-size: 0.78rem;
      line-height: 1.45;
    }
    body.owner-minimal .owner-blast-deferred-wrap {
      margin-top: 0.65rem;
    }
    body.owner-minimal .owner-blast-deferred-wrap > summary {
      cursor: pointer;
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-table--deferred {
      margin-top: 0.35rem;
      opacity: 0.85;
    }
    body.owner-minimal .owner-blast-history-foot {
      margin: 0.65rem 0 0;
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-campaign-cell {
      min-width: 10rem;
    }
    body.owner-minimal .owner-blast-campaign-name {
      display: block;
    }
    body.owner-minimal .owner-blast-message {
      margin: 0.35rem 0 0;
    }
    body.owner-minimal .owner-blast-message > summary {
      cursor: pointer;
      font-size: 0.82rem;
      color: var(--accent, #7eb8ff);
      list-style: none;
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
    }
    body.owner-minimal .owner-blast-message > summary::-webkit-details-marker {
      display: none;
    }
    body.owner-minimal .owner-blast-message > summary::before {
      content: '▸';
      font-size: 0.75rem;
      opacity: 0.85;
    }
    body.owner-minimal .owner-blast-message[open] > summary::before {
      content: '▾';
    }
    body.owner-minimal .owner-copy-preview-block {
      margin-top: 0.45rem;
    }
    body.owner-minimal .owner-copy-preview-block__subject {
      margin: 0 0 0.35rem;
      font-size: 0.85rem;
    }
    body.owner-minimal .owner-copy-preview {
      margin: 0;
      padding: 0.65rem 0.75rem;
      max-height: 16rem;
      overflow: auto;
      white-space: pre-wrap;
      word-break: break-word;
      font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
      font-size: 0.78rem;
      line-height: 1.45;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(0, 0, 0, 0.28);
      color: rgba(255, 255, 255, 0.88);
    }
    body.owner-minimal .owner-welcome-summary {
      padding: 0.85rem 1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.1);
      background: rgba(0, 0, 0, 0.18);
    }
    body.owner-minimal .owner-welcome-summary__approved {
      margin: 0 0 0.5rem;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.45rem;
    }
    body.owner-minimal .owner-welcome-summary__stats,
    body.owner-minimal .owner-welcome-summary__subject {
      margin: 0.35rem 0;
    }
    body.owner-minimal .owner-welcome-summary__copy {
      margin: 0.55rem 0 0;
    }
    body.owner-minimal .owner-welcome-summary__copy > summary {
      cursor: pointer;
      font-size: 0.88rem;
      font-weight: 600;
      list-style: none;
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
    }
    body.owner-minimal .owner-welcome-summary__copy > summary::-webkit-details-marker {
      display: none;
    }
    body.owner-minimal .owner-welcome-summary__copy > summary::before {
      content: '▸';
      font-size: 0.75rem;
      opacity: 0.85;
    }
    body.owner-minimal .owner-welcome-summary__copy[open] > summary::before {
      content: '▾';
    }
    body.owner-minimal .owner-welcome-summary__link {
      margin: 0.65rem 0 0;
      font-size: 0.85rem;
    }
    body.owner-minimal .owner-blast-card {
      margin-bottom: 1.25rem;
      padding: 1rem 1.1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.1);
      background: rgba(0, 0, 0, 0.2);
    }
    body.owner-minimal .owner-blast-card__head {
      display: flex;
      flex-wrap: wrap;
      align-items: baseline;
      justify-content: space-between;
      gap: 0.5rem 1rem;
      margin-bottom: 0.35rem;
    }
    body.owner-minimal .owner-blast-card__body {
      margin-top: 0.15rem;
    }
    /* Unified disclosure chevrons — Review drafts, blasts, settings, campaigns */
    body.owner-minimal .owner-review-disclosure > summary,
    body.owner-minimal .owner-review-settings > summary,
    body.owner-minimal .owner-blast-disclosure > summary,
    body.owner-minimal .owner-blast-section > summary,
    body.owner-minimal .owner-draft-section > summary {
      list-style: none;
      display: flex;
      align-items: center;
      gap: 0.55rem;
      cursor: pointer;
    }
    body.owner-minimal .owner-review-disclosure > summary::-webkit-details-marker,
    body.owner-minimal .owner-review-settings > summary::-webkit-details-marker,
    body.owner-minimal .owner-blast-disclosure > summary::-webkit-details-marker,
    body.owner-minimal .owner-blast-section > summary::-webkit-details-marker,
    body.owner-minimal .owner-draft-section > summary::-webkit-details-marker {
      display: none;
    }
    body.owner-minimal .owner-review-disclosure > summary::before,
    body.owner-minimal .owner-review-settings > summary::before,
    body.owner-minimal .owner-blast-disclosure > summary::before,
    body.owner-minimal .owner-blast-section > summary::before,
    body.owner-minimal .owner-draft-section > summary::before {
      content: '';
      flex-shrink: 0;
      width: 0.42rem;
      height: 0.42rem;
      border-right: 2px solid #94a3b8;
      border-bottom: 2px solid #94a3b8;
      transform: rotate(-45deg);
      transition: transform 0.15s ease;
      margin-top: -0.1rem;
    }
    body.owner-minimal .owner-review-disclosure[open] > summary::before,
    body.owner-minimal .owner-review-settings[open] > summary::before,
    body.owner-minimal .owner-blast-disclosure[open] > summary::before,
    body.owner-minimal .owner-blast-section[open] > summary::before,
    body.owner-minimal .owner-draft-section[open] > summary::before {
      transform: rotate(45deg);
      margin-top: 0.15rem;
    }
    body.owner-minimal .owner-review-disclosure {
      margin-bottom: 0.85rem;
    }
    body.owner-minimal .owner-review-disclosure > summary {
      cursor: pointer;
      font-weight: 600;
      color: #cbd5e1;
    }
    body.owner-minimal .owner-review-disclosure[open] > summary {
      margin-bottom: 0.55rem;
    }
    body.owner-minimal .owner-review-section.owner-review-disclosure {
      margin-bottom: 1.25rem;
      padding: 0.85rem 1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(0, 0, 0, 0.12);
    }
    body.owner-minimal .owner-review-section__summary {
      font-size: 1.25rem;
      font-weight: 700;
      color: #f1f5f9;
      letter-spacing: -0.01em;
    }
    body.owner-minimal .owner-blast-disclosure {
      padding: 0;
      margin-bottom: 0;
    }
    body.owner-minimal .owner-blast-disclosure > summary.owner-blast-disclosure__summary {
      font-size: 1.05rem;
      font-weight: 700;
      color: #f1f5f9;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem;
    }
    body.owner-minimal .owner-blast-section {
      margin: 0.45rem 0;
      padding: 0.35rem 0 0.35rem 0.65rem;
      border-left: 2px solid rgba(255, 255, 255, 0.08);
    }
    body.owner-minimal .owner-blast-section > summary {
      font-size: 0.82rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.04em;
      color: #94a3b8;
    }
    body.owner-minimal .owner-draft-section {
      padding: 0.65rem 0.75rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(0, 0, 0, 0.25);
      min-width: 0;
    }
    body.owner-minimal .owner-draft-section.owner-draft-card__msg--draft {
      border-color: rgba(139, 92, 246, 0.28);
      background: rgba(139, 92, 246, 0.08);
    }
    body.owner-minimal .owner-draft-section > summary.owner-draft-card__msg-label {
      margin: 0;
      list-style-position: outside;
    }
    body.owner-minimal .owner-draft-section.owner-draft-card__msg--draft > summary.owner-draft-card__msg-label {
      color: #c4b5fd;
    }
    body.owner-minimal .owner-draft-card__subject-body {
      margin: 0.35rem 0 0;
      font-size: 0.86rem;
      color: #e2e8f0;
    }
    body.owner-minimal .owner-blast-card__head h3 {
      margin: 0;
      font-size: 1.05rem;
    }
    body.owner-minimal .owner-blast-pre {
      margin: 0.35rem 0 0;
      padding: 0.75rem;
      font-size: 0.82rem;
      line-height: 1.45;
      white-space: pre-wrap;
      word-break: break-word;
      border-radius: 4px;
      background: rgba(0, 0, 0, 0.35);
      border: 1px solid rgba(255, 255, 255, 0.08);
      max-height: none;
      overflow: visible;
    }
    body.owner-minimal .owner-blast-pre--full {
      max-height: min(85vh, 720px);
      overflow-y: auto;
    }
    /* LISA: pre-line wraps like CorrLinks prose — avoids pre-wrap soft-wrap trailing spaces. */
    body.owner-minimal .owner-blast-pre--lisa {
      white-space: pre-line;
    }
    body.owner-minimal .owner-review-pre {
      position: relative;
      margin: 0.35rem 0 0;
      padding: 0.75rem;
      font-size: 0.82rem;
      line-height: 1.45;
      white-space: pre-wrap;
      word-break: break-word;
      border-radius: 4px;
      background: rgba(0, 0, 0, 0.35);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }
    body.owner-minimal .owner-review-pre.msg-preview--truncated,
    body.owner-minimal .owner-review-pre.msg-preview--expanded {
      max-height: min(70vh, 520px);
      overflow-y: auto;
    }
    body.owner-minimal .owner-msg-preview-host .msg-preview__body,
    body.owner-minimal .owner-blast-preview-host .msg-preview__body {
      padding-right: 2.85rem;
    }
    body.owner-minimal .owner-blast-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
      margin-top: 0.85rem;
    }
    body.owner-minimal .owner-blast-warn {
      margin: 0 0 0.5rem;
      font-size: 0.85rem;
      color: #fbbf24;
    }
    body.owner-minimal .owner-review-modes {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
      gap: 0.75rem;
      margin-bottom: 1.25rem;
    }
    body.owner-minimal .owner-mode-card {
      padding: 0.85rem 1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.1);
      background: rgba(0, 0, 0, 0.18);
    }
    body.owner-minimal .owner-mode-card__title {
      margin: 0 0 0.35rem;
      font-size: 0.95rem;
    }
    body.owner-minimal .owner-mode-card__hint {
      margin: 0 0 0.6rem;
      font-size: 0.8rem;
    }
    body.owner-minimal .owner-mode-card__btns {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
    }
    body.owner-minimal .owner-mode-card__stat {
      margin: 0.5rem 0 0;
      font-size: 0.82rem;
      color: #fbbf24;
    }
    body.owner-minimal .owner-review-drafts {
      margin-bottom: 1.5rem;
    }
    body.owner-minimal .owner-review-summary {
      margin-bottom: 1rem;
    }
    body.owner-minimal .owner-review-hero {
      display: flex;
      align-items: flex-start;
      gap: 0.85rem;
      padding: 0.95rem 1.1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.1);
    }
    body.owner-minimal .owner-review-hero--clear {
      background: rgba(16, 185, 129, 0.1);
      border-color: rgba(16, 185, 129, 0.28);
    }
    body.owner-minimal .owner-review-hero--pending {
      background: rgba(245, 158, 11, 0.1);
      border-color: rgba(245, 158, 11, 0.32);
    }
    body.owner-minimal .owner-review-hero__icon {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 2rem;
      height: 2rem;
      border-radius: 999px;
      background: rgba(16, 185, 129, 0.2);
      color: #34d399;
      font-weight: 700;
      flex-shrink: 0;
    }
    body.owner-minimal .owner-review-hero__copy strong {
      display: block;
      margin-bottom: 0.25rem;
      color: #f1f5f9;
    }
    body.owner-minimal .owner-review-hero__copy p {
      margin: 0;
      font-size: 0.85rem;
    }
    body.owner-minimal .owner-review-hero__list {
      margin: 0.45rem 0 0;
      padding-left: 1.1rem;
      font-size: 0.88rem;
    }
    body.owner-minimal .owner-review-hero__link {
      color: #fcd34d;
      text-decoration: none;
      cursor: pointer;
    }
    body.owner-minimal .owner-review-hero__link:hover {
      text-decoration: underline;
    }
    body.owner-minimal .owner-draft-list {
      display: flex;
      flex-direction: column;
      gap: 0.85rem;
    }
    body.owner-minimal .owner-draft-card {
      padding: 1rem 1.05rem;
      border-radius: 4px;
      border: 1px solid rgba(139, 92, 246, 0.22);
      background: rgba(0, 0, 0, 0.22);
    }
    body.owner-minimal .owner-draft-card__head {
      display: flex;
      flex-wrap: wrap;
      align-items: flex-start;
      justify-content: space-between;
      gap: 0.35rem 0.75rem;
      margin-bottom: 0.55rem;
    }
    body.owner-minimal .owner-draft-card__when {
      font-size: 0.78rem;
      white-space: nowrap;
    }
    body.owner-minimal .owner-draft-card__subject {
      margin: 0 0 0.65rem;
      font-size: 0.86rem;
      color: #e2e8f0;
    }
    body.owner-minimal .owner-draft-card__subject-label {
      color: #94a3b8;
      font-size: 0.72rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.04em;
      margin-right: 0.35rem;
    }
    body.owner-minimal .owner-draft-card__compare {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 0.65rem;
      margin-bottom: 0.85rem;
    }
    body.owner-minimal .owner-draft-card__msg-label {
      margin: 0;
      font-size: 0.72rem;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: #94a3b8;
    }
    body.owner-minimal .owner-draft-card__actions {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      flex-wrap: wrap;
      gap: 0.55rem;
      margin-top: 0.75rem;
    }
    body.owner-minimal .owner-draft-card__warn {
      margin: 0;
      font-size: 0.86rem;
    }
    body.owner-minimal .owner-draft-feedback {
      width: 100%;
      display: flex;
      flex-direction: column;
      gap: 0.35rem;
    }
    body.owner-minimal .owner-draft-feedback__label {
      font-size: 0.82rem;
      font-weight: 600;
      color: rgba(226, 232, 240, 0.85);
    }
    body.owner-minimal .owner-draft-feedback__input {
      width: 100%;
      min-height: 4.5rem;
      padding: 0.55rem 0.65rem;
      border-radius: 4px;
      border: 1px solid rgba(148, 163, 184, 0.25);
      background: rgba(15, 23, 42, 0.55);
      color: #e2e8f0;
      font: inherit;
      resize: vertical;
    }
    body.owner-minimal .owner-draft-card__discard {
      opacity: 0.75;
    }
    body.owner-minimal .owner-review-empty {
      padding: 0.85rem 0.2rem 0.2rem;
    }
    body.owner-minimal .owner-review-empty__title {
      margin: 0 0 0.35rem;
      font-weight: 600;
      color: #e2e8f0;
    }
    body.owner-minimal .owner-review-settings {
      margin-top: 1.25rem;
      padding: 0.85rem 1rem;
      border-radius: 4px;
      border: 1px solid rgba(255, 255, 255, 0.08);
      background: rgba(0, 0, 0, 0.12);
    }
    body.owner-minimal .owner-review-settings__summary {
      cursor: pointer;
      font-weight: 600;
      color: #cbd5e1;
      list-style-position: outside;
    }
    body.owner-minimal .owner-review-settings__hint {
      margin: 0.5rem 0 0.75rem;
      font-size: 0.82rem;
    }
    body.owner-minimal .owner-blast-card--due {
      border-color: rgba(245, 158, 11, 0.45);
      box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.12);
    }
    body.owner-minimal .owner-blast-card__title-wrap {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem;
    }
    body.owner-minimal .owner-blast-card__due-pill {
      font-size: 0.68rem;
    }
    body.owner-minimal .owner-blast-meta {
      font-size: 0.85rem;
      margin: 0 0 0.65rem;
    }
    body.owner-minimal .owner-blast-card__schedule {
      font-size: 0.85rem;
      margin: 0 0 0.65rem;
    }
    body.owner-minimal .owner-blast-due {
      color: #fcd34d;
    }
    body.owner-minimal .owner-blast-copy__label {
      font-size: 0.78rem;
      margin-bottom: 0.35rem;
    }
    body.owner-minimal .owner-blast-copy__subject {
      margin-bottom: 0.65rem;
      font-size: 0.9rem;
      color: #e2e8f0;
    }
    body.owner-minimal .owner-blast-copy__note {
      margin: 0.5rem 0 0;
      font-size: 0.78rem;
    }
    body.owner-minimal .owner-blast-meta--warn {
      color: #fbbf24;
      font-size: 0.82rem;
      margin: 0 0 0.5rem;
    }
    @media (max-width: 720px) {
      body.owner-minimal .owner-draft-card__compare {
        grid-template-columns: 1fr;
      }
      body.owner-minimal .owner-draft-card__actions .btn {
        flex: 1 1 calc(50% - 0.25rem);
        justify-content: center;
      }
      body.owner-minimal .owner-draft-card__actions .btn-primary {
        flex-basis: 100%;
      }
    }
    body.owner-minimal .owner-welcome-section {
      margin-top: 1.5rem;
    }
    body.owner-minimal .owner-welcome-editor {
      display: grid;
      gap: 0.45rem;
      margin-top: 0.75rem;
    }
    body.owner-minimal .owner-welcome-editor__label {
      font-size: 0.78rem;
      color: #94a3b8;
      margin-top: 0.35rem;
    }
    body.owner-minimal .owner-welcome-editor__subject,
    body.owner-minimal .owner-welcome-editor__body {
      width: 100%;
      box-sizing: border-box;
      font: inherit;
      color: #e2e8f0;
      background: rgba(0, 0, 0, 0.35);
      border: 1px solid rgba(255, 255, 255, 0.12);
      border-radius: 4px;
      padding: 0.65rem 0.75rem;
    }
    body.owner-minimal .owner-welcome-editor__body {
      min-height: 16rem;
      line-height: 1.45;
      resize: vertical;
      white-space: pre-wrap;
    }
    body.owner-minimal #workers-details {
      display: none;
    }
    .breakglass-advanced {
      margin-top: 1rem;
      padding-top: 0.75rem;
      border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    .breakglass-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 0.5rem 0.75rem;
      margin-bottom: 0.65rem;
    }

    .breakglass-activity-list {
      margin-top: 0.65rem;
      max-height: 280px;
      overflow: auto;
    }

    .breakglass-activity-table {
      width: 100%;
      font-size: 0.8rem;
    }

    .breakglass-preview {
      max-width: 12rem;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .breakglass-debug-output {
      margin-top: 0.5rem;
      max-height: 160px;
      overflow: auto;
      font-size: 0.75rem;
      white-space: pre-wrap;
    }

    .pacer-modal .pacer-modal-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 0.65rem 1rem;
      margin: 0.75rem 0;
    }

    .pacer-modal label {
      display: flex;
      flex-direction: column;
      gap: 0.25rem;
      font-size: 0.82rem;
      color: #94a3b8;
    }

    .inmate-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 0.35rem;
      align-items: center;
    }

    .inmate-actions-menu {
      position: relative;
    }

    .inmate-actions-menu__toggle {
      list-style: none;
      cursor: pointer;
      min-width: 2rem;
      text-align: center;
    }

    .inmate-actions-menu__toggle::-webkit-details-marker {
      display: none;
    }

    .inmate-actions-menu__panel {
      position: absolute;
      right: 0;
      top: calc(100% + 0.25rem);
      z-index: 20;
      display: flex;
      flex-direction: column;
      gap: 0.2rem;
      min-width: 9rem;
      padding: 0.35rem;
      background: #1e293b;
      border: 1px solid rgba(255,255,255,0.12);
      border-radius: 4px;
      box-shadow: 0 8px 24px rgba(0,0,0,0.35);
    }

    .inmate-account-cell {
      font-size: 0.78rem;
      line-height: 1.45;
    }

    .inmate-account-label {
      font-weight: 600;
      color: #e2e8f0;
    }

    .inmate-relay-email {
      color: #94a3b8;
      word-break: break-all;
    }

    .inmate-actions--removed {
      font-size: 0.78rem;
    }

    /* ═══════════════════════════════════════════════════════════════════════
       PREMIUM DARK — reading pane declutter (override block, appended last so it
       wins the cascade). Pure visual: no markup/JS change, semantics preserved
       (author→accent, status pills, all data-action buttons stay). Reversible by
       deleting this block. Scoped under .messaging-hub so it only touches the
       thread reading pane, not other .msg-card uses (lab, previews).
       Fixes the 6 clutter sources: stripe, badge-wall, button-wall, multi-accent,
       cramped rhythm, hard-edged cards.
       ═══════════════════════════════════════════════════════════════════════ */

    /* Roomier canvas so bubbles can breathe (clutter #6). */
    .messaging-hub .hub-thread,
    .messaging-hub #hub-thread,
    .messaging-hub [class*="thread"] > .msg-card:first-child { }

    /* 1 — Reading-pane LAYOUT only. Color, alignment, and state are owned by the base
       token rules (single source of truth) — this block must NOT redefine background,
       border-color, or margin-left/right, or the two clusters drift again (the old bug).
       It only adds the roomier reading-pane spacing/depth on top of the shared model. */
    .messaging-hub .msg-card {
      padding: 0.7rem 0.9rem 0.6rem;
      gap: 0.4rem;
      box-shadow: 0 1px 2px rgba(0,0,0,0.25);
      margin-bottom: 0.9rem;
    }

    /* 2 — Header: sender + time read first; account/authorship chips recede. */
    .messaging-hub .msg-card__header { gap: 0.45rem; opacity: 0.92; }
    .messaging-hub .msg-card__direction {
      font-weight: 650; font-size: 0.72rem; letter-spacing: 0.02em;
    }
    .messaging-hub .msg-card__time { font-size: 0.66rem; opacity: 0.7; }
    /* Reading-pane chip sizing only — the ACCOUNT tag (cl1/cl2) may recede to grey,
       but the AUTHORSHIP chips (You sent / AI / You approved / Manual on CorrLinks)
       carry the who-sent-this signal and MUST keep their per-mod color. So this rule
       no longer sets color/background — those come from the --<mod> classes (single
       source of truth), same principle as the card-color refactor. */
    .messaging-hub .msg-card__acct-tag {
      font-weight: 600;
    }
    /* The plain account tag (no authorship mod) is the only one that recedes. */
    .messaging-hub .msg-card__acct-tag:not([class*="--"]) {
      background: rgba(148,163,184,0.10); color: #7b8494;
      font-weight: 500; opacity: 0.75;
    }
    .messaging-hub .msg-card__body {
      font-size: 0.86rem; line-height: 1.5;
    }

    /* 3 — Actions hidden until hover (clutter #3): the single biggest declutter.
       Keyboard focus inside the card also reveals them (accessibility). */
    .messaging-hub .msg-card__actions {
      max-height: 0; overflow: hidden; opacity: 0; margin-top: 0;
      transition: max-height 0.16s ease, opacity 0.16s ease, margin-top 0.16s ease;
      pointer-events: none;
    }
    .messaging-hub .msg-card:hover .msg-card__actions,
    .messaging-hub .msg-card:focus-within .msg-card__actions {
      max-height: 8rem; opacity: 1; margin-top: 0.35rem; pointer-events: auto;
    }
    /* 4 — Quiet, uniform action buttons; keep only reply/send tinted (primary). */
    .messaging-hub .msg-card__action-btn {
      background: rgba(255,255,255,0.05); color: #aab2be;
      border: 1px solid rgba(255,255,255,0.08); border-radius: 4px;
      padding: 0.2rem 0.6rem;
    }
    .messaging-hub .msg-card__action-btn--reply,
    .messaging-hub .msg-card__action-btn--send {
      color: #c4b5fd; border-color: rgba(124,92,246,0.35);
    }
    .messaging-hub .msg-card__action-btn--fwd,
    .messaging-hub .msg-card__action-btn--reprocess,
    .messaging-hub .msg-card__action-btn--recall,
    .messaging-hub .msg-card__action-btn--dismiss,
    .messaging-hub .msg-card__action-btn--copy {
      color: #99a1ad; border-color: rgba(255,255,255,0.08);
    }
    .messaging-hub .msg-card__action-btn:hover {
      background: rgba(124,92,246,0.14); color: #ede9fe;
    }
    @media (prefers-reduced-motion: reduce) {
      .messaging-hub .msg-card__actions { transition: none; }
    }
