  @import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,300;1,400&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@300;400&family=Jost:wght@300;400;500;600&display=swap');

  /* Hub Design System palette (locked 2026-05-28; Pulse aligned 2026-05-28 late).
     Source of truth: Allure Hub 2026/_Design/HUB-DESIGN-SYSTEM.md §1.
     Pulse-specific deviation: per Peter (2026-05-28 late) the layout stays
     full-screen desktop — NO mobile breakpoint shrinking. Only the color
     vocabulary follows the Hub spec; banner + grid widths are preserved. */
  :root {
    /* Cream surfaces (warm tints, lightest → darkest) */
    --bg: #fdf8f3;          /* solid cream — used as the "page" surface where a solid is needed */
    --bg-2: #fffcf8;        /* primary card / panel surface */
    --bg-3: #fffaf3;        /* hover surface; input bg */
    --bg-4: #fff5e8;        /* warm tinted sub-panel / callout */

    /* Ink (text) — espresso → muted bronze */
    --text: #3a2e24;        /* body ink (default) */
    --text-dim: #6e5a47;    /* secondary ink (sub-text, captions) */
    --ink: #3a2e24;         /* alias used by the Ask AllureOS surface */
    --ink-muted: #9a7b5a;   /* muted bronze (hints, placeholders, labels) */
    --ink-line: #e8ddd0;    /* cream border (alias used by Ask AllureOS) */

    /* Borders */
    --line: #e8ddd0;        /* solid cream border (most cards / inputs) */
    --line-bright: #d4bfa8; /* slightly heavier beige border / dashed */

    /* Gold + bronze accents (the Pulse gold italic + eyebrow vocabulary) */
    --gold: #C5A572;        /* light gold — the "Pulse" italic; eyebrow color */
    --gold-bright: #a07219; /* noteworthy gold for row titles on cream — deeper than spec's #b8911f after live read-back (Peter, 2026-05-28 polish) */
    --gold-dim: #8a6940;    /* walnut bronze (deep accent on cream) */
    --live-green: #2d9a4a;  /* on-cream LIVE indicator — brighter than --green-cream so "live" reads alive */

    /* Semantic — on-cream variants (the banner ready-dot keeps its on-black green inline) */
    --green: #6FCF97;       /* ready-dot green — used on-BLACK in the banner */
    --green-cream: #6b9a6e; /* success on cream */
    --amber: #c89a3a;       /* warning on cream */
    --gray: #9a7b5a;        /* muted bronze */
    --red: #a85842;         /* error on cream */

    /* Banner-only constants (referenced explicitly by the .topbar block below
       so the banner stays locked-black regardless of the cream tokens above). */
    --banner-bg: #000000;
    --banner-ink: #fdf8f3;  /* cream-white (warmer than #ffffff) */
  }
  * { box-sizing: border-box; margin: 0; padding: 0; }
  /* Background coverage (2026-06-04): the cream gradient is painted by a
     FIXED, full-viewport layer (body::before) rather than the body box.
     A content-sized body background still cut off at the bottom on some
     tabs whose layout left the body box shorter than the scrolled content
     (panels/lists that scroll inside their own context). Pinning the
     gradient to the viewport guarantees full coverage on every tab,
     regardless of content height or per-panel layout. The gradient stays
     fixed while content scrolls — standard for a subtle full-bleed wash. */
  html { height: 100%; }
  body { min-height: 100%; }
  body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background: #fdf8f3;   /* flat cream — Pulse main background carries no gradient (Peter 2026-06-30) */
    pointer-events: none;
  }
  /* Scrollbar hidden globally (Hub spec §4) — content stays scrollable; only
     the visual indicator goes away so screen-to-screen height changes don't
     pop a gutter. */
  html {
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  html::-webkit-scrollbar {
    width: 0 !important; height: 0 !important; display: none !important; background: transparent !important;
  }
  body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #fdf8f3;  /* solid base; the cream gradient is the fixed body::before layer above */
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    line-height: 1.45;
    font-variant-numeric: lining-nums tabular-nums;
    font-feature-settings: "lnum" 1, "tnum" 1;
    scrollbar-width: none;
    -ms-overflow-style: none;
    overflow-x: hidden;
  }
  body::-webkit-scrollbar { width: 0 !important; height: 0 !important; display: none !important; }
  a { color: var(--gold-bright); text-decoration: none; }
  a:hover { color: var(--gold-dim); }

  /* ========================= SPLASH (login + picker share this shell) ========================= */
  .splash {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background: var(--bg);
    font-variant-numeric: lining-nums tabular-nums;
    font-feature-settings: "lnum" 1, "tnum" 1;
    animation: fadeUp 0.8s ease both;
  }
  @keyframes fadeUp {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  .splash-eyebrow {
    font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 10px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 20px;
  }
  .splash-logo {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 52px;
    font-weight: 300;
    letter-spacing: -0.02em;
    color: var(--text);
    line-height: 1;
    margin-bottom: 8px;
  }
  .splash-logo span {
    font-style: italic;
    color: var(--gold);
  }
  .splash-sub {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-style: italic;
    font-size: 16px;
    color: var(--text-dim);
    letter-spacing: 0.02em;
    margin-bottom: 36px;
  }
  .splash-card {
    width: 100%;
    max-width: 380px;
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: 4px;
    padding: 28px 24px;
  }
  .splash-card h2 {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 400;
    margin-bottom: 18px;
  }
  .splash-card input[type="password"],
  .splash-card input[type="text"] {
    width: 100%;
    background: var(--bg-3);
    border: 1px solid var(--line);
    color: var(--text);
    padding: 12px 14px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    letter-spacing: 0.02em;
    outline: none;
    transition: border-color 0.15s ease;
  }
  .splash-card input:focus {
    border-color: var(--gold);
  }
  .splash-card button {
    margin-top: 14px;
    width: 100%;
    background: var(--gold);
    color: var(--text);
    border: none;
    padding: 12px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-weight: 400;
    cursor: pointer;
    transition: background 0.15s ease;
  }
  .splash-card button:hover:not(:disabled) {
    background: var(--gold-bright);
  }
  .splash-card button:disabled {
    background: var(--bg-4);
    color: var(--text-dim);
    cursor: not-allowed;
  }
  .splash-error {
    margin-top: 12px;
    color: var(--red);
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    min-height: 16px;
  }
  .splash-footer {
    margin-top: 28px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.15em;
    color: var(--text-dim);
    text-transform: uppercase;
  }

  /* admin picker — buttons stacked */
  .picker-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }
  .picker-btn {
    background: var(--bg-3);
    border: 1px solid var(--line);
    color: var(--text);
    padding: 14px 16px;
    border-radius: 3px;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 18px;
    text-align: left;
    cursor: pointer;
    transition: all 0.12s ease;
  }
  .picker-btn:hover {
    border-color: var(--gold);
    color: var(--gold-bright);
    background: var(--bg-2);
  }
  .picker-back {
    margin-top: 20px;
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    cursor: pointer;
    padding: 0;
  }
  .picker-back:hover { color: var(--gold); }

  /* ========================= APP (post-auth dashboard) ========================= */
  .app { display: none; min-height: 100vh; }
  .app.show { display: block; }
  .splash.hide { display: none; }

  /* ─────────── Banner (Hub spec §3) ───────────
     Locked to BLACK regardless of the cream body palette. Per Peter
     2026-05-28: the banner / brand / name / Sign out all look right as-is —
     this block pins them to explicit on-black values so the token swap
     below doesn't drift them. NOT mobile-shrunk: Pulse stays full-screen
     desktop per Peter's explicit ask. */
  .topbar {
    border-bottom: 0;
    background: var(--banner-bg);
    padding: calc(15px + env(safe-area-inset-top, 0px)) 16px 12px;   /* §10 canon (Receiving) — desktop = mobile */
  }
  .topbar-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
  }
  .topbar-wholine {                     /* §10 canon — ● NAME · LOCATION on every screen, desktop included */
    display: block; text-align: center; padding-top: 12px;
    font-family: 'JetBrains Mono', monospace; font-size: 10px; letter-spacing: .18em; text-transform: uppercase;
    color: #cdbfae; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .topbar-wholine::before { content: "● "; color: #6fcf97; }
  .topbar-wholine .ws-store { color: #f1e3c4; cursor: pointer; text-decoration: none; }
  .topbar-left { grid-column: 1; justify-self: start; display: flex; align-items: center; gap: 14px; }
  .ws-pivot { display: inline-flex; align-items: center; padding: 6px; opacity: .85; text-decoration: none; }
  .ws-pivot:hover { opacity: 1; }
  .topbar-brand {
    grid-column: 2;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 22px;
    font-weight: 300;
    color: var(--banner-ink);
    cursor: pointer;
    text-align: center;
    line-height: 1;
  }
  .topbar-brand span {
    font-style: italic;
    font-weight: 400;
    color: var(--gold);
  }
  .topbar-right {
    grid-column: 3;
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 18px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.1em;
    color: var(--banner-ink);
  }
  .topbar-right .who {
    display: none;   /* name now lives in the §10 who-line below */
    color: var(--banner-ink);
  }
  .topbar-right .who::before {
    content: "● ";
    color: var(--green);
  }
  .logout-btn {
    background: none;
    border: none;
    color: var(--banner-ink);
    padding: 6px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 21px;
    line-height: 1;
    cursor: pointer;
  }
  .logout-btn .lo-txt { display: none; }
  .logout-btn::before { content: "⏻"; }
  .logout-btn:hover { color: var(--gold); border-color: var(--gold); }

  /* Tabs strip — sits directly below the black banner on the cream body.
     Background is transparent so the cream page gradient shows through;
     the subtle beige bottom border anchors the active gold underline. */
  .tabs {
    display: flex;
    gap: 0;
    justify-content: center;
    border-bottom: 1px solid var(--line);
    background: transparent;
    padding: 0 24px;
  }
  .tab {
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    padding: 18px 22px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: color 0.15s ease, border-color 0.15s ease;
  }
  .tab:hover { color: var(--gold-dim); }
  .tab.active {
    color: var(--gold-dim);
    border-bottom-color: var(--gold);
  }
  /* Ungranted tab: present but faded + inert (dictated by the Admin matrix;
     appearance only — the panel stays hidden, the strip just shows the full
     tab set so staff never see a sparse layout). (2026-07-01) */
  .tab.locked { opacity: .4; cursor: default; pointer-events: none; }
  .tab-sep {
    color: var(--line-bright);
    font-size: 18px;
    align-self: center;
    padding: 0 2px;
    pointer-events: none;
    user-select: none;
  }

  .panel {
    display: none;
    padding: 32px 24px 64px;
    max-width: 1280px;
    margin: 0 auto;
  }
  .panel.active { display: block; animation: fadeUp 0.3s ease both; }

  /* ===== Embedded in-Pulse apps (Tribe / Trades) — keep-alive iframe panels ===== */
  .panel.embed-panel { padding: 0; max-width: none; }
  .panel.embed-panel.active { display: block; animation: fadeUp 0.3s ease both; }
  /* Match the native .tab-home column exactly: 1100px content (max 1100 + 2x24 pad = 1148),
     same left edge as Buying at every width; bottom 0 so the .tab-desc 24px margin is the only
     gap to the iframe's first tiles (the embedded apps zero their own top pad in embed-desktop). */
  .embed-head { padding: 34px 24px 0; max-width: 1148px; margin: 0 auto; }
  .embed-frame { display: block; width: 100%; border: 0; background: #fdf8f3; }
  /* Tribe renders its own evolving breadcrumb header inside the iframe, so suppress
     Pulse's static nameplate for the Tribe panel (no double "TRIBE"). */
  #panel-tribe .embed-head { display: none; }
  /* Trades nameplate aligned to Tribe in-iframe breadcrumb line (28px / lh 1.5) so both tab titles sit on the same line. */
  #panel-trades .embed-head { display: none; }   /* Trades self-headers (breadcrumb) — no double TRADES, mirrors #panel-tribe */
  #panel-trades .tab-nameplate { line-height: 1.5; }
  @media (max-width: 720px) { #panel-trades .embed-head { padding-top: 16px; } }  /* mobile: match native nameplate 16px below header */

  /* ===== Shared tab nameplate header — all six Pulse tabs (desktop + mobile) ===== */
  .tab-nameplate { font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 600;
    letter-spacing: .3em; text-transform: uppercase; color: #8a6940; line-height: 1.5; margin: 0 0 7px; }
  .tab-desc { font-family: 'Jost', sans-serif; font-size: 12.5px;
    color: #6e5a3f; line-height: 1.45; margin: 0 0 26px; }
  /* Section labels inside a tab home (e.g. "Coming soon") take the same gold nameplate voice. */
  .tab-home .pl-label { color: #8a6940; font-weight: 600; font-size: 11px; letter-spacing: .3em; }
  /* Coming-soon / unbuilt tiles read as not-yet-active. */
  .tab-home .pl-tile.inert { opacity: .6; }
  @media (max-width: 720px) {
    .tab-desc { margin-bottom: 20px; }
    .embed-head { padding: 20px 16px 14px; }
  }

  .panel-eyebrow {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 6px;
  }
  .panel-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 32px;
    font-weight: 300;
    color: var(--text);
    margin-bottom: 4px;
  }
  .panel-sub {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-style: italic;
    font-size: 15px;
    color: var(--text-dim);
    margin-bottom: 28px;
  }

  .tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
  }
  .tile {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: 4px;
    padding: 22px 22px 20px;
    transition: all 0.15s ease;
    display: flex;
    flex-direction: column;
    min-height: 160px;
  }
  .tile.live, .tile.embed {
    cursor: pointer;
  }
  .tile.live:hover, .tile.embed:hover {
    border-color: var(--gold);
    background: var(--bg-3);
    transform: translateY(-1px);
  }
  .tile.placeholder {
    opacity: 0.7;
    border-style: dashed;
  }
  .tile-status {
    font-family: 'JetBrains Mono', monospace;
    font-size: 9px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    margin-bottom: 10px;
  }
  /* LIVE state — stronger green + weight so the chip reads alive on cream. */
  .tile-status.live { color: var(--live-green); font-weight: 500; }
  .tile-status.coming { color: var(--text-dim); }
  .tile-status.migrating { color: var(--amber); }
  .tile-status.embed { color: var(--gold-bright); }
  .tile-status.live::before { content: "● "; font-size: 1.15em; vertical-align: -1px; text-shadow: 0 0 6px rgba(45,154,74,0.55); }
  .tile-status.coming::before { content: "○ "; }
  .tile-status.migrating::before { content: "◐ "; }
  .tile-status.embed::before { content: "◆ "; }
  .tile-name {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 26px;
    font-weight: 300;
    color: var(--text);
    margin-bottom: 8px;
    letter-spacing: -0.01em;
  }
  .tile-desc {
    color: var(--text-dim);
    font-size: 13px;
    line-height: 1.5;
    flex-grow: 1;
  }
  .tile-footer {
    margin-top: 14px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.15em;
    color: var(--gold);
    text-transform: uppercase;
  }
  .tile.placeholder .tile-footer { color: var(--text-dim); }

  /* ========================= TILE LIST LAYOUT (Buying home + future panels) ========================= */
  .tiles-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 8px;
  }
  .tiles-list .tile {
    border: 1px solid rgba(197,165,114,0.30);
    border-radius: 5px;
    flex-direction: row;
    align-items: center;
    min-height: unset;
    padding: 15px 22px;
    gap: 0;
  }
  .tiles-list .tile.live:hover,
  .tiles-list .tile.embed:hover {
    transform: none;
    background: rgba(197,165,114,0.07);
    border-color: rgba(197,165,114,0.65);
  }
  .tiles-list .tile-footer { display: none; }
  .tiles-list .tile-status {
    flex-shrink: 0;
    width: 110px;
    margin-bottom: 0;
    font-size: 8.5px;
  }
  .tiles-list .tile-name {
    flex-shrink: 0;
    width: 220px;
    font-size: 20px;
    font-weight: 400;  /* bump from inherited 300 — elegant but more noteworthy on cream */
    margin-bottom: 0;
    letter-spacing: 0;
  }
  .tiles-list .tile.live .tile-name,
  .tiles-list .tile.embed .tile-name { color: var(--gold-bright); }
  .tiles-list .tile-desc {
    flex: 1;
    font-size: 12.5px;
    line-height: 1.45;
    padding: 0 28px;
  }
  .tiles-list .tile-footer {
    flex-shrink: 0;
    margin-top: 0;
    font-size: 9.5px;
  }

  /* ========================= EMBEDDED SUB-VIEWS (shared chrome) ========================= */
  /* Sub-pages center in the SAME 1100px column as the tab homes (.tab-home), so
     entering a drill (PO, Receiving, VML, Trainer sub-pages) is zero-shift — the
     content lands at the identical left edge + width as the home. (§12: one 1100
     width everywhere; brings the 1280 drill panels to 1100.) */
  .subview { display: none; max-width: 1100px; margin-left: auto; margin-right: auto; }
  .subview.active { display: block; animation: fadeUp 0.25s ease both; }
  .panel.subview-open .tiles,
  .panel.subview-open .panel-eyebrow,
  .panel.subview-open .panel-title,
  .panel.subview-open .panel-sub { display: none; }

  .back-link {
    display: inline-block;
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    cursor: pointer;
    padding: 0;
    margin-bottom: 22px;
  }
  .back-link:hover { color: var(--gold); }

  /* ===== Vendor Master List — §13 (tiles + breadcrumb-as-title + PO form card) ===== */
  #sv-vendor-master .vm-head { margin-top: -4px; padding-bottom: 8px; }  /* nameplate offset parity with .po-head */
  /* mobile: crumb locked to ONE line — the current segment ellipsizes (§13.1),
     so a long vendor name can never wrap the title row and shift the page */
  @media (max-width: 720px) {
    #sv-vendor-master .sv-title { display: flex; align-items: baseline; gap: 6px; white-space: nowrap; }
    #sv-vendor-master .sv-title .crumb-leaf { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  }
  .vm-controls { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
  @media (max-width: 820px) { .vm-controls { flex-wrap: wrap; } }
  .vm-empty { font-style: italic; color: var(--text-dim); padding: 24px 0; font-family: 'Jost', sans-serif; }
  .vm-dim { color: var(--text-dim); }
  /* vendor tiles = the canonical .pl-tile; scoped extras: 2-line clamps for user data */
  .vm-tiles { margin-top: 6px; }
  #vm-view-list .pl-tile .nm-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; width: 100%; margin-bottom: 3px; }  /* name left · Needs-info pill right, one row (Peter 7-02) */
  #vm-view-list .pl-tile .nm-row .nm { flex: 1; min-width: 0; margin-bottom: 0; }
  #vm-view-list .pl-tile .nm-row .vm-pill { margin-right: 0; flex-shrink: 0; }
  #vm-view-list .pl-tile .nm { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 1; overflow: hidden; overflow-wrap: anywhere; }  /* 1-line vendor name = uniform tile height (Peter 7-02) */
  #vm-view-list .pl-tile .ds { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
  .vm-pill { display: inline-block; font-family: 'Inter', sans-serif; font-size: 9px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; padding: 2px 7px; border-radius: 4px; margin-right: 6px; vertical-align: 1px; }
  .vm-pill.inactive { background: #f1ece5; color: #9a7b5a; }
  .vm-pill.warn { background: #fdf3e0; color: #b8862e; }
  /* detail = the PO form card voice (.po-form / .po-fld / .po-seclabel reused) */
  .vm-form { margin-top: 2px; }
  /* minmax(0,1fr) = truly EQUAL columns — bare 1fr lets an input's intrinsic
     min-width steal width from its neighbor (the mobile Status-box misalign) */
  .vm-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 20px; margin-bottom: 4px; }
  .vm-grid + .vm-grid { margin-top: 10px; }
  .vm-grid .po-fld input, .vm-grid .po-fld select { min-width: 0; width: 100%; height: 36px; }
  .vm-fld-parent { grid-column: span 3; }
  .vm-fld-parent input { font-size: 15px; font-weight: 600; }
  @media (max-width: 820px) { .vm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .vm-fld-parent { grid-column: span 1; } }
  /* brands + contacts sit on the SAME 4-col gridlines as .vm-grid — shared gridlines (§13.3) */
  .vm-inline-row, .vm-contact { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 20px; align-items: center; margin-bottom: 8px; }
  .vm-contact { margin-bottom: 14px; }
  .vm-inline-row input, .vm-contact input, .vm-contact select.vm-title-sel {
    min-width: 0; width: 100%; box-sizing: border-box; background: var(--bg-2); border: 1px solid var(--line); border-radius: 4px;
    color: var(--text); padding: 8px 10px; font-size: 13px; font-family: 'Inter', sans-serif;
  }
  .vm-inline-row input:focus, .vm-contact input:focus, .vm-contact select.vm-title-sel:focus { outline: none; border-color: var(--gold-dim); }
  .vm-inline-row .vm-remove, .vm-contact .vm-remove { justify-self: start; }
  @media (max-width: 820px) { .vm-inline-row, .vm-contact { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  .vm-remove { background: none; border: none; color: var(--text-dim); cursor: pointer; font-size: 14px; padding: 0 6px; }
  .vm-remove:hover { color: #a85842; }
  .vm-add { background: none; border: 1px dashed #d4bfa8; color: #8a6940; border-radius: 8px;
            padding: 7px 14px; font-size: 12px; cursor: pointer; margin: 2px 0 4px; font-family: 'Inter', sans-serif; }
  .vm-add:hover { border-color: #c5a572; background: #fffaf3; }
  .vm-codes { display: flex; flex-wrap: wrap; gap: 8px; }
  .vm-code { background: var(--bg-2); border: 1px solid #e8ddd0; border-radius: 8px; padding: 6px 12px; font-size: 12px; font-family: 'Inter', sans-serif; color: #4a2c17; }
  .vm-code span { color: #9a7b5a; margin-right: 8px; }
  .vm-notes { width: 100%; box-sizing: border-box; min-height: 90px; font-family: 'Inter', sans-serif; font-size: 13px; color: var(--text);
              background: var(--bg-2); border: 1px solid var(--line); border-radius: 4px; padding: 8px 10px; resize: vertical; }
  .vm-notes:focus { outline: none; border-color: var(--gold-dim); }
  .vm-detail-actions { display: flex; gap: 10px; margin-top: 22px; }
  .vm-btn { font-family: 'Inter', sans-serif; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; border-radius: 8px; padding: 10px 18px; cursor: pointer; }
  .vm-btn.primary { background: #3d2417; color: #fdf8f3; border: 1px solid #3d2417; }
  .vm-btn.primary:hover { background: #2a1a10; }
  .vm-btn.ghost { background: #fffcf8; color: #8a6940; border: 1px solid #e8ddd0; }
  .vm-btn.ghost:hover { border-color: #c5a572; background: #fffaf3; }
  .vm-btn.danger { background: none; color: #a85842; border: 1px solid #b66a55; }
  .vm-btn.danger:hover { background: #fdf0ec; }
  .vm-save-msg { margin-top: 10px; font-family: 'Jost', sans-serif; font-size: 12px; min-height: 16px; }
  .vm-save-msg.ok { color: #6b9a6e; }
  .vm-save-msg.err { color: #a85842; }
  .sv-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 32px;
    font-weight: 300;
    color: var(--text);
    letter-spacing: -0.01em;
    margin-bottom: 4px;
  }
  .sv-sub {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-style: italic;
    font-size: 15px;
    color: var(--text-dim);
    margin-bottom: 28px;
  }
  .sv-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
  }
  .sv-action-btn {
    background: var(--bg-2);
    border: 1px solid var(--line);
    color: var(--text);
    padding: 9px 16px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10.5px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }
  .sv-action-btn:hover { border-color: var(--gold); color: var(--gold-bright); }
  .sv-action-btn.primary { background: var(--gold); color: var(--text); border-color: var(--gold); }
  .sv-action-btn.primary:hover { background: var(--gold-dim); color: var(--banner-ink); border-color: var(--gold-dim); }

  /* ============ TRIBE COCKPIT — native (no iframe) ============ */
  .tc-nav {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--line);
    margin-bottom: 24px;
  }
  .tc-nav-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 10px 18px;
    cursor: pointer;
    margin-bottom: -1px;
    transition: color 0.15s, border-color 0.15s;
  }
  .tc-nav-btn:hover { color: var(--gold-bright); }
  .tc-nav-btn.active { color: var(--gold-bright); border-bottom-color: var(--gold); }
  .tc-hidden { display: none !important; }
  .tc-meta {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--text-dim);
    letter-spacing: 0.1em;
    margin-bottom: 20px;
    min-height: 16px;
  }
  .tc-section { margin-bottom: 28px; }
  .tc-section-eyebrow {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold-dim);
    margin-bottom: 10px;
  }
  .tc-hero {
    background: var(--bg-2);
    border: 1px solid var(--line-bright);
    border-radius: 4px;
    padding: 16px 20px;
    margin-bottom: 20px;
  }
  .tc-hero-eyebrow {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--gold-dim);
    margin-bottom: 8px;
  }
  .tc-hero-text {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 19px;
    color: var(--text);
    line-height: 1.45;
    margin-bottom: 8px;
  }
  .tc-hero-meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: baseline; }
  .tc-hero-project {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
  }
  .tc-hero-rationale { font-size: 13px; color: var(--text-dim); font-style: italic; }
  .tc-review-btn {
    display: inline-flex;
    align-items: center;
    background: none;
    border: 1px solid var(--line-bright);
    border-radius: 3px;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    padding: 9px 16px;
    cursor: pointer;
    text-decoration: none;
    transition: border-color 0.15s, color 0.15s;
    margin-bottom: 24px;
  }
  .tc-review-btn:hover { border-color: var(--gold); color: var(--gold-bright); }
  .tc-heat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
  /* 2026-06-12 — the heat row was the one Tribunal grid with no mobile
     collapse: 4 fixed columns x 130px min-width cells = 550px minimum, so on
     a phone the 4th tile leaked past the right edge and the page panned
     sideways. 2-up under 600px (sibling convention: asks-ledger 600 / briefs
     520) locks it to the viewport. */
  @media (max-width: 600px) { .tc-heat-row { grid-template-columns: repeat(2, 1fr); } }
  .tc-heat-cell {
    flex: 1;
    min-width: 130px;
    border: 1px solid var(--line-bright);
    border-left-width: 3px;
    border-radius: 4px;
    padding: 12px 14px;
    transition: border-color 0.15s;
    cursor: pointer;
  }
  .tc-heat-cell:hover { border-color: var(--gold); }
  .tc-heat-cell.green  { border-left-color: var(--green); }
  .tc-heat-cell.yellow { border-left-color: var(--amber); }
  .tc-heat-cell.red    { border-left-color: var(--red); }
  .tc-heat-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gold-bright);
    margin-bottom: 6px;
  }
  .tc-heat-summary { font-size: 13px; color: var(--text-dim); line-height: 1.4; margin-bottom: 4px; }
  .tc-heat-empty { color: var(--text-dim); opacity: 0.5; font-style: italic; }
  .tc-heat-activity { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--text-dim); opacity: 0.6; }
  .tc-gains-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
  .tc-gains-list li {
    border: 1px solid rgba(197,165,114,0.30);
    border-radius: 5px;
    padding: 10px 14px;
    font-size: 14px;
    color: var(--text);
    line-height: 1.45;
  }
  .tc-gains-list li:hover { border-color: rgba(197,165,114,0.65); }
  .tc-asks-ledger { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
  @media (max-width: 600px) { .tc-asks-ledger { grid-template-columns: 1fr; } }
  .tc-asks-col-head {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--text-dim);
    margin-bottom: 10px;
  }
  .tc-asks-row {
    border: 1px solid rgba(197,165,114,0.20);
    border-radius: 4px;
    padding: 9px 12px;
    margin-bottom: 6px;
  }
  .tc-asks-vendor {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 4px;
  }
  .tc-asks-age { color: var(--text-dim); }
  .tc-asks-text { font-size: 13px; color: var(--text-dim); line-height: 1.4; }
  .tc-asks-empty { font-size: 13px; color: var(--text-dim); opacity: 0.45; }
  .tc-directive {
    width: 100%;
    background: var(--bg-2);
    border: 1px solid var(--line-bright);
    border-radius: 3px;
    color: var(--text);
    font-size: 14px;
    padding: 10px 12px;
    resize: vertical;
    margin-bottom: 10px;
    line-height: 1.45;
    font-family: inherit;
  }
  .tc-directive:focus { outline: none; border-color: var(--gold-dim); }
  .tc-directive-btn {
    background: var(--gold);
    color: var(--text);
    border: none;
    border-radius: 3px;
    padding: 9px 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s;
  }
  .tc-directive-btn:hover { background: var(--gold-bright); }
  .tc-directive-btn:disabled { opacity: 0.45; cursor: not-allowed; }
  .tc-briefs-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
  @media (max-width: 520px) { .tc-briefs-grid { grid-template-columns: 1fr; } }
  .tc-brief-tile {
    border: 1px solid var(--line-bright);
    border-radius: 4px;
    padding: 16px;
    cursor: pointer;
    transition: border-color 0.15s;
  }
  .tc-brief-tile:hover { border-color: var(--gold-dim); }
  .tc-brief-tile-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
  }
  .tc-brief-tile-name {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 20px;
    color: var(--gold-bright);
    font-weight: 400;
  }
  .tc-brief-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
  }
  .tc-brief-dot.green  { background: var(--green); }
  .tc-brief-dot.yellow { background: var(--amber); }
  .tc-brief-dot.red    { background: var(--red); }
  .tc-brief-tile-reason { font-size: 13px; color: var(--text-dim); font-style: italic; line-height: 1.5; margin-bottom: 8px; }
  .tc-brief-tile-meta {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--text-dim);
    letter-spacing: 0.15em;
    text-transform: uppercase;
  }
  .tc-brief-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    cursor: pointer;
    padding: 0;
    margin-bottom: 20px;
    transition: color 0.15s;
  }
  .tc-brief-back:hover { color: var(--gold-bright); }
  .tc-brief-detail-name {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 28px;
    font-weight: 300;
    color: var(--text);
    margin-bottom: 4px;
  }
  .tc-brief-card {
    background: var(--bg-2);
    border: 1px solid var(--line-bright);
    border-radius: 4px;
    padding: 16px 20px;
    margin-bottom: 12px;
  }
  .tc-brief-card-title {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 10px;
  }
  .tc-brief-card-content { font-size: 14px; color: var(--text-dim); line-height: 1.6; white-space: pre-wrap; }
  .tc-loading {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-dim);
    padding: 24px 0;
    letter-spacing: 0.1em;
    display: block;
  }
  .tc-error {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--red);
    padding: 16px 0;
    display: block;
  }
  .section-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold);
    margin: 32px 0 14px;
  }
  .section-label:first-child { margin-top: 0; }

  .sv-banner {
    background: rgba(242,201,76,0.06);
    border: 1px solid rgba(242,201,76,0.25);
    border-radius: 4px;
    padding: 14px 16px;
    color: var(--text);
    font-size: 13px;
    line-height: 1.55;
    margin-bottom: 24px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
  }
  .sv-banner .glyph { color: var(--amber); font-size: 16px; line-height: 1.2; }
  .sv-banner strong { color: var(--amber); font-weight: 500; letter-spacing: 0.04em; }

  /* ========================= TRADESHOW LANDING ========================= */
  .ts-meta-strip {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 18px 22px;
    margin-bottom: 28px;
  }
  .ts-meta-item { display: flex; flex-direction: column; gap: 4px; }
  .ts-meta-k {
    font-family: 'JetBrains Mono', monospace;
    font-size: 9.5px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-dim);
  }
  .ts-meta-v {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 18px;
    color: var(--text);
  }
  .ts-show-grid, .ts-vendor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
  }
  /* Event list — vertical rows */
  .ts-show-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
  }
  .ts-show-card {
    background: var(--bg-2);
    border: 1px solid rgba(197,165,114,0.30);
    border-radius: 5px;
    padding: 12px 18px;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
  }
  .ts-show-card:hover {
    background: rgba(197,165,114,0.07);
    border-color: rgba(197,165,114,0.65);
  }
  .ts-show-info { display: flex; flex-direction: column; gap: 3px; }
  .ts-vendor-card {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 18px 20px;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    flex-direction: column;
    gap: 6px;
  }
  .ts-vendor-card:hover { border-color: var(--gold); transform: translateY(-1px); }
  .ts-show-name {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 21px;
    font-weight: 400;
    color: var(--gold-bright);
  }
  .ts-vendor-name {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 22px;
    color: var(--text);
  }
  .ts-show-dates, .ts-vendor-sub {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.14em;
    color: var(--text-dim);
    text-transform: uppercase;
  }
  .ts-counts {
    display: flex;
    gap: 14px;
    flex-shrink: 0;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10.5px;
    letter-spacing: 0.08em;
    color: var(--gold-bright);
  }
  .ts-counts span { display: inline-flex; align-items: center; gap: 4px; }
  .ts-counts em { font-style: normal; color: var(--text-dim); }
  .ts-sys-chip {
    display: inline-block;
    background: rgba(197,165,114,0.10);
    border: 1px solid rgba(197,165,114,0.30);
    color: var(--gold-bright);
    border-radius: 999px;
    padding: 3px 10px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 9.5px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    align-self: flex-start;
    margin-top: 6px;
  }
  /* Local (Pulse-created, not-yet-synced) event chip on a show card */
  .ts-local-chip {
    display: inline-block;
    margin-left: 8px;
    vertical-align: middle;
    background: rgba(197,165,114,0.12);
    border: 1px solid rgba(197,165,114,0.40);
    color: var(--gold-bright);
    border-radius: 999px;
    padding: 2px 9px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 8.5px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
  }
  .ts-feed-err {
    border: 1px solid rgba(197,165,114,0.30);
    background: rgba(197,165,114,0.06);
    color: var(--text-dim);
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 16px;
    font-size: 12px;
  }
  /* New vendor-meeting / market event form */
  .ts-new-form {
    background: var(--bg-2);
    border: 1px solid var(--gold);
    border-radius: 6px;
    padding: 22px 24px;
    margin-bottom: 24px;
  }
  .ts-new-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 24px;
    color: var(--gold-bright);
    margin-bottom: 16px;
  }
  .ts-new-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
  }
  .ts-new-grid label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 9.5px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--text-dim);
  }
  .ts-new-grid input {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 4px;
    padding: 9px 11px;
    color: var(--text);
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    letter-spacing: normal;
    text-transform: none;
  }
  .ts-new-grid input:focus { outline: none; border-color: var(--gold); }
  .ts-new-err { color: var(--red); font-size: 12px; min-height: 16px; margin-top: 10px; }
  .ts-new-actions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
  .ts-new-hint { color: var(--text-dim); font-size: 11.5px; margin-top: 12px; line-height: 1.5; }
  .ts-sheet-docs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
  .ts-sheet-doc {
    display: inline-flex;
