/* Lace landing hero demo — faithful rebuild of the Lace floating window + shared review page.
   All Lace values traced from the codebase (AppHeader.tsx, glass.css, pillTokens.ts,
   composerStyles.ts, ReviewSidePanel/CommentCardComponents, overlayStyleSpec.ts,
   SharedReviewPage.tsx). The "Atlas" ops console is intentionally NOT Lace-styled. */

/* ---------- Fonts (same OTFs the web app ships) — Lace surfaces only ---------- */
@font-face {
  font-family: 'General Sans';
  src: url('./fonts/GeneralSans-Regular.otf') format('opentype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('./fonts/GeneralSans-Medium.otf') format('opentype');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'General Sans';
  src: url('./fonts/GeneralSans-Semibold.otf') format('opentype');
  font-weight: 600;
  font-display: swap;
}

:root {
  /* gestalt-tokens.css */
  --primary-300: #b7c0df;
  --primary-400: #98a5d2;
  --primary-500: #7c8bc9;
  --primary-600: #6574c4;
  --primary-700: #5563b3; /* lace-primary */
  --gestalt-black: #0a0a0c;
  --gestalt-gray-900: #111827;
  --success-check: #22c55e;
  --pin-resolved: #059669;
  /* glass.css */
  --glass-radius: 10px;
  /* pillTokens.ts */
  --pill-primary: #6373cf;
  --pill-primary-dim: #5664b5;
  --pill-primary-bright: #818fe8;
  --pill-glass: rgba(12, 12, 16, 0.965);
  --pill-border: rgba(255, 255, 255, 0.18);
  --pill-text-secondary: #968d86;
  /* Atlas ops console (deliberately non-Lace) */
  --atlas-accent: #2563eb;
  --atlas-ink: #17181c;
  --atlas-sub: #6d7078;
  --atlas-faint: #9a9da6;
  --atlas-line: #e7e8ec;
  --font-sans: 'General Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --font-system: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'SF Mono', 'Menlo', 'Monaco', 'Cascadia Mono', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { width: 100%; height: 100%; }
body {
  background: transparent;
  font-family: var(--font-sans);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

#demo { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }

/* Fixed 1440x900 stage, transparent — scaled to fit by script.js */
.stage {
  position: relative;
  width: 1440px;
  height: 900px;
  transform-origin: center center;
  overflow: hidden;
  background: transparent;
}

.scene { position: absolute; inset: 0; }
.hidden { display: none !important; }
.fade-io { transition: opacity 400ms ease; }
.is-faded { opacity: 0 !important; pointer-events: none; }

/* =====================================================================
   "ATLAS" OPS CONSOLE — fictional refined SaaS. System font, blue accent.
   ===================================================================== */
.ops-window {
  position: absolute;
  left: 0;
  top: 0;
  width: 1440px;
  height: 900px;
  border-radius: 12px;
  background: #ffffff;
  overflow: hidden;
  display: flex;
  font-family: var(--font-system);
  color: var(--atlas-ink);
}

/* sidebar */
.atlas-side {
  width: 208px;
  flex-shrink: 0;
  background: #f7f7f9;
  border-right: 1px solid var(--atlas-line);
  display: flex;
  flex-direction: column;
}
.atlas-lights { display: flex; gap: 8px; padding: 18px 16px 14px; }
.atlas-lights i { width: 12px; height: 12px; border-radius: 50%; display: block; }
.atlas-lights i:nth-child(1) { background: #ff5f57; }
.atlas-lights i:nth-child(2) { background: #febc2e; }
.atlas-lights i:nth-child(3) { background: #28c840; }
.atlas-brand { display: flex; align-items: center; gap: 8px; padding: 4px 16px 14px; }
.atlas-brand i {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: linear-gradient(135deg, #2563eb, #4f83f1);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  font-style: normal;
}
.atlas-brand span { font-size: 13.5px; font-weight: 700; letter-spacing: -0.01em; }
.atlas-nav { padding: 4px 8px; display: flex; flex-direction: column; gap: 1px; }
.atlas-nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--atlas-sub);
}
.atlas-nav-item svg { flex-shrink: 0; opacity: 0.75; }
.atlas-nav-item.is-active { background: #e9edf8; color: #1d4ed8; }
.atlas-nav-item.is-active svg { opacity: 1; }
.atlas-nav-label {
  padding: 14px 18px 5px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--atlas-faint);
}

/* main column */
.atlas-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.atlas-topbar {
  height: 52px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  border-bottom: 1px solid var(--atlas-line);
}
.atlas-topbar h1 { font-size: 14px; font-weight: 650; letter-spacing: -0.01em; }
.atlas-count {
  font-size: 11px;
  font-weight: 600;
  color: #1d4ed8;
  background: #e9edf8;
  border-radius: 999px;
  padding: 3px 8px;
}
.atlas-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 7px;
  width: 210px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--atlas-line);
  background: #fafafb;
  padding: 0 10px;
  font-size: 12px;
  color: var(--atlas-faint);
}
.atlas-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #d8def0;
  color: #3f4a6e;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 650;
}

.atlas-content { flex: 1; min-height: 0; display: flex; }

/* table */
.atlas-table { flex: 1; min-width: 0; border-right: 1px solid var(--atlas-line); }
.atlas-thead {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--atlas-line);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--atlas-faint);
}
.atlas-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 18px;
  border-bottom: 1px solid #f1f2f5;
  cursor: default;
}
.atlas-row.is-selected { background: #f3f6fd; box-shadow: inset 2.5px 0 0 var(--atlas-accent); }
.col-req { width: 52px; flex-shrink: 0; font-size: 12.5px; font-weight: 600; }
.col-cust { flex: 1; min-width: 0; display: flex; align-items: center; gap: 9px; }
.cust-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  font-size: 9.5px;
  font-weight: 650;
  background: #eceef2;
  color: #4c505a;
}
.cust-name { font-size: 12.5px; font-weight: 550; line-height: 1.25; }
.cust-mail { font-size: 11px; color: var(--atlas-faint); line-height: 1.25; }
.col-amt { width: 70px; flex-shrink: 0; text-align: right; font-size: 12.5px; font-weight: 550; font-variant-numeric: tabular-nums; }
.col-date { width: 46px; flex-shrink: 0; font-size: 11.5px; color: var(--atlas-sub); }
.col-status { width: 86px; flex-shrink: 0; display: flex; justify-content: flex-end; }
.ops-chip {
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
  font-family: var(--font-system);
}
.chip-pending { background: #f1f2f5; color: #62656d; }
.chip-approved { background: #e0f3e9; color: #157347; }
.chip-escalated { background: #e5edfc; color: #1d4ed8; }
.chip-declined { background: #f7e8e8; color: #b03d3d; }

/* detail drawer */
.atlas-drawer { width: 330px; flex-shrink: 0; display: flex; flex-direction: column; background: #fcfcfd; border-right: 1px solid var(--atlas-line); }

/* activity column — real app content the Lace window overlays */
.atlas-activity { flex-shrink: 0; width: 430px; padding: 16px 18px; background: #fff; }
.atlas-activity h3 {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--atlas-faint);
  padding-bottom: 12px;
}
.act-item { display: flex; gap: 10px; padding-bottom: 16px; }
.act-item i { width: 7px; height: 7px; border-radius: 50%; background: #d4d7de; margin-top: 4px; flex-shrink: 0; }
.act-item.accent i { background: var(--atlas-accent); }
.act-text { font-size: 12px; line-height: 1.45; color: var(--atlas-sub); }
.act-text b { color: var(--atlas-ink); font-weight: 600; }
.act-time { font-size: 11px; color: var(--atlas-faint); margin-top: 2px; }
.drawer-head { padding: 16px 18px 0; }
.drawer-kicker { font-size: 10.5px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--atlas-faint); }
.drawer-title { display: flex; align-items: center; gap: 8px; margin-top: 5px; }
.drawer-title h2 { font-size: 14.5px; font-weight: 650; letter-spacing: -0.01em; }
.drawer-cust { display: flex; align-items: center; gap: 9px; margin: 14px 18px 0; padding-bottom: 14px; border-bottom: 1px solid var(--atlas-line); }
.drawer-cust .cust-avatar { width: 30px; height: 30px; font-size: 10.5px; }
.drawer-reason { margin: 12px 18px 0; font-size: 12px; line-height: 1.5; color: var(--atlas-sub); }
.drawer-reason b { color: var(--atlas-ink); font-weight: 600; }
.drawer-fields { margin: 6px 18px 0; display: flex; flex-direction: column; }
.drawer-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 2px;
  border-bottom: 1px solid #f1f2f5;
  position: relative;
}
.drawer-field-label { font-size: 11.5px; color: var(--atlas-faint); }
.drawer-field-value { font-size: 12px; font-weight: 550; text-align: right; }
.drawer-field-value em { font-style: normal; color: #b45309; font-weight: 600; }
.drawer-note {
  margin: 14px 18px 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: #f5f6f8;
  border: 1px solid #e9eaee;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--atlas-sub);
}
.drawer-note b { color: var(--atlas-ink); font-weight: 600; }
.drawer-actions { margin-top: auto; padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; }
.atlas-btn {
  font-family: var(--font-system);
  font-size: 12.5px;
  font-weight: 600;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--atlas-line);
  background: #fff;
  color: var(--atlas-ink);
  transition: transform 90ms ease, filter 120ms ease;
}
.atlas-btn.primary { background: var(--atlas-accent); border-color: var(--atlas-accent); color: #fff; }
.atlas-btn.ghost { border-color: transparent; color: var(--atlas-sub); }
.atlas-btn.is-pressed { transform: scale(0.97); filter: brightness(0.92); }
.drawer-actions-row { display: flex; gap: 8px; }
.drawer-actions-row .atlas-btn { flex: 1; }

/* =====================================================================
   LACE PILL — renderer/pill, exact (pillTokens.ts)
   ===================================================================== */
.pill-stack {
  position: absolute;
  left: 50%;
  top: 14px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 340px;
  padding: 0 8px;
  gap: 8px;
  z-index: 40;
}
.pill {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--pill-glass);
  border: 1px solid var(--pill-border);
  transition: border-color 120ms ease, border-radius 150ms ease-out, gap 150ms ease-out,
    padding 150ms ease-out, background 150ms ease-out;
}
.pill-bar {
  width: 56px;
  height: 5px;
  border-radius: 999px;
  background: var(--pill-primary-dim);
  opacity: 0.72;
  transition: height 150ms ease-out, opacity 150ms ease-out, background 150ms ease-out;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}
.pill.is-live .pill-bar { background: var(--pill-primary); opacity: 1; }
.pill.is-processing .pill-bar {
  background: var(--pill-primary-dim);
  opacity: 1;
  animation: pillBreathe 2.4s ease-in-out infinite;
}
.pill.is-processing .pill-bar::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: radial-gradient(ellipse 40% 100% at 50% 50%, var(--pill-primary-bright) 0%, transparent 70%);
  animation: pillGlow 1.6s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}
@keyframes pillBreathe { 0%, 100% { opacity: 0.8; } 50% { opacity: 1; } }
@keyframes pillGlow { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
/* =====================================================================
   macOS NOTIFICATION BANNERS — Lace native system notifications
   ===================================================================== */
.notif-stack {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 344px;
  z-index: 45;
  pointer-events: none;
}
.macos-notif {
  position: absolute;
  top: 0;
  right: 0;
  width: 344px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 20px;
  background: rgba(247, 247, 249, 0.78);
  -webkit-backdrop-filter: blur(36px) saturate(1.8);
  backdrop-filter: blur(36px) saturate(1.8);
  box-shadow: 0 10px 34px rgba(0, 0, 0, 0.28), inset 0 0 0 0.5px rgba(255, 255, 255, 0.4);
  font-family: var(--font-system);
  opacity: 0;
  transform: translateX(380px);
  transition: transform 420ms cubic-bezier(0.2, 0.9, 0.3, 1), opacity 320ms ease, top 380ms cubic-bezier(0.2, 0.9, 0.3, 1);
}
.macos-notif.is-in { opacity: 1; transform: none; }
.macos-notif.is-out { opacity: 0; transform: translateX(380px); }
.notif-icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 9px;
  background: #131316;
  color: #fff;
  flex-shrink: 0;
}
.notif-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.notif-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 17px;
  color: rgba(0, 0, 0, 0.88);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.notif-body {
  font-size: 13px;
  line-height: 17px;
  color: rgba(60, 60, 67, 0.72);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.notif-time {
  align-self: flex-start;
  font-size: 11px;
  color: rgba(60, 60, 67, 0.5);
  flex-shrink: 0;
  padding-top: 1px;
}
.macos-notif.is-pressed { transform: scale(0.98); }

/* =====================================================================
   LACE FLOATING WINDOW — FocusModeLayout .glassPanel + AppHeader, exact
   (macOS vibrancy emulated: real tint is rgba(10,10,12,0.42) over OS blur;
    here alpha is raised + CSS backdrop blur so it reads the same)
   ===================================================================== */
.lace-panel {
  position: absolute;
  top: 12px;
  right: 12px;
  bottom: 12px;
  width: 400px; /* FLOATING_WINDOW_WIDTH */
  border-radius: var(--glass-radius); /* 10px */
  background: rgba(13, 13, 17, 0.92);
  -webkit-backdrop-filter: blur(48px) saturate(1.4);
  backdrop-filter: blur(48px) saturate(1.4);
  color: #fff;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
  transform: translateX(430px);
  transition: transform 260ms cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 30;
}
.lace-panel.is-open { transform: none; }

/* AppHeader — h-11 (44px), native traffic lights left */
.app-header {
  position: relative;
  z-index: 20;
  height: 44px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding-right: 8px;
  padding-left: 20px;
  user-select: none;
}
.app-header .traffic { display: flex; gap: 8px; margin-right: 10px; }
.app-header .traffic i { width: 12px; height: 12px; border-radius: 50%; display: block; }
.app-header .traffic i:nth-child(1) { background: #ff5f57; }
.app-header .traffic i:nth-child(2) { background: #febc2e; }
.app-header .traffic i:nth-child(3) { background: #28c840; }
.app-header-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  line-height: 16px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

/* panel toolbar — search comments + filter + Share + Canvas */
.panel-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 12px 10px;
  flex-shrink: 0;
}
.search-field {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  padding: 0 11px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
}
.search-field svg { flex-shrink: 0; opacity: 0.8; }
.toolbar-icon-btn {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
}
.toolbar-text-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 4px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
  flex-shrink: 0;
}
.toolbar-text-btn svg { opacity: 0.85; }
.app-header-right { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.hdr-icon-btn {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 6px;
  color: rgba(255, 255, 255, 0.45);
  transition: background 150ms ease-out, color 150ms ease-out, transform 80ms ease-out;
}
.hdr-icon-btn.is-active { background: rgba(255, 255, 255, 0.1); color: #fff; }
.hdr-icon-btn.is-pressed { transform: scale(0.95); }

/* review side panel body */
.panel-body { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; }

/* empty state — ReviewModeEmptyState, exact */
.panel-empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  transition: opacity 200ms ease;
  pointer-events: none;
}
.panel-empty h2 {
  margin-top: -96px; /* -mt-24 */
  font-size: 18px;
  line-height: 28px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: rgba(255, 255, 255, 0.6);
}
.panel-empty.is-hidden { opacity: 0; }

/* comment list — px-3 py-2 gap-2 */
.panel-list {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
  padding: 8px 12px;
}

/* comment card — CommentCard, exact */
.lace-card {
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  padding: 12px;
  opacity: 0;
  transform: translateY(6px) scale(0.98);
  transition: opacity 220ms ease, transform 220ms ease, border-color 150ms ease, background 150ms ease;
}
.lace-card.is-shown { opacity: 1; transform: none; }
.lace-card.is-hovered { border-color: rgba(85, 99, 179, 0.4); background: rgba(85, 99, 179, 0.08); }
.card-head { display: flex; align-items: center; gap: 6px; }
.avatar {
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: #fff;
  flex-shrink: 0;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.5);
}
.avatar-xs { width: 20px; height: 20px; font-size: 10px; }
.avatar-2xs { width: 16px; height: 16px; font-size: 8px; }
.avatar-sm { width: 24px; height: 24px; font-size: 10px; }
.avatar-user { background: var(--primary-700); }
.avatar-you { background: linear-gradient(160deg, #e8833a 25%, #7048e8 75%); }
.avatar-agent {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.7);
  text-shadow: none;
}
.card-author {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
}
.card-org { flex-shrink: 0; font-size: 10px; color: rgba(255, 255, 255, 0.3); max-width: 120px; }
.card-body {
  padding-top: 8px;
  font-size: 12px;
  line-height: 18px;
  overflow-wrap: break-word;
  color: rgba(255, 255, 255, 0.8);
}
.card-foot { display: flex; align-items: center; justify-content: space-between; padding-top: 10px; }
.card-time { font-size: 10px; color: rgba(255, 255, 255, 0.4); }
.card-time span { color: rgba(255, 255, 255, 0.3); }
.resolve {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: transparent;
  transition: border-color 150ms ease, background 150ms ease, transform 100ms ease;
}
.resolve svg path { stroke: rgba(255, 255, 255, 0.25); transition: stroke 150ms ease; }
.resolve.is-resolved { border-color: rgba(34, 200, 138, 0.5); background: rgba(34, 200, 138, 0.15); }
.resolve.is-resolved svg path { stroke: var(--success-check); }
.resolve.is-pressed { transform: scale(0.95); }

/* reply thread — ReplyThread.tsx exact */
.reply-thread {
  margin-top: 10px;
  margin-left: 4px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-left: 2px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
  padding-left: 12px;
}
.reply-head { display: flex; align-items: center; gap: 6px; }
.reply-author { font-size: 11px; line-height: 14px; font-weight: 500; color: rgba(255, 255, 255, 0.92); }
.reply-dot { font-size: 10px; color: rgba(255, 255, 255, 0.4); }
.reply-time { font-size: 10px; color: rgba(255, 255, 255, 0.4); }
.reply-body { padding-left: 22px; font-size: 11px; line-height: 16px; color: rgba(255, 255, 255, 0.78); }
.reply-composer {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  padding: 8px 12px;
}
.reply-input { flex: 1; min-width: 0; font-size: 11px; line-height: 14px; color: rgba(255, 255, 255, 0.8); white-space: nowrap; overflow: hidden; }
.reply-input.is-empty { color: rgba(255, 255, 255, 0.4); }
.reply-send { opacity: 0.5; display: grid; place-items: center; flex-shrink: 0; }
.reply-send.is-active { opacity: 0.8; }

/* LivePinHint — px-1 pb-1.5 text-white/40, exact */
.pin-hint {
  padding: 0 4px 6px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  opacity: 0;
  transition: opacity 500ms ease;
}
.pin-hint.is-shown { opacity: 1; }

/* composer — single row: round plus, placeholder, mic; dictation swaps in */
.composer-wrap { margin-top: auto; flex-shrink: 0; padding: 0 8px 8px; }
.composer {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  padding: 7px 8px;
}
.composer-idle { display: flex; align-items: center; gap: 10px; min-height: 28px; }
.composer.is-dictating .composer-idle { display: none; }
.plus-circle {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
}
.composer-ph { flex: 1; min-width: 0; font-size: 13px; color: rgba(255, 255, 255, 0.5); }
.mic-plain { display: grid; place-items: center; color: rgba(255, 255, 255, 0.5); flex-shrink: 0; padding-right: 4px; }
.caret {
  display: inline-block;
  width: 1px;
  height: 14px;
  background: #fff;
  vertical-align: -2px;
  animation: caretBlink 1s steps(1) infinite;
}
@keyframes caretBlink { 50% { opacity: 0; } }
.dictation-row { display: none; align-items: center; gap: 10px; min-width: 0; min-height: 28px; }
.composer.is-dictating .dictation-row { display: flex; }
.wave { display: flex; min-width: 0; flex: 1; align-items: flex-end; justify-content: space-evenly; overflow: hidden; height: 20px; padding-left: 4px; }
.wave span {
  width: 2.5px;
  flex-shrink: 0;
  border-radius: 999px;
  height: 12px;
  transform-origin: bottom;
  animation: dictation-bar 1.1s ease-in-out infinite;
}
@keyframes dictation-bar {
  0%, 100% { transform: translateY(70%); opacity: 0.35; }
  50% { transform: translateY(0%); opacity: 0.9; }
}
.dict-timer { font-size: 13px; font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, 0.7); flex-shrink: 0; }
.dict-btn { display: grid; width: 26px; height: 26px; place-items: center; border-radius: 50%; flex-shrink: 0; transition: transform 100ms ease; }
.dict-cancel { background: rgba(255, 255, 255, 0.1); color: rgba(255, 255, 255, 0.6); }
.dict-stop { background: var(--primary-600); color: #fff; }
.dict-btn.is-pressed { transform: scale(0.94); }

/* =====================================================================
   COMMENT PINS — CommentPinLayer.tsx, exact teardrop
   ===================================================================== */
.pin { position: absolute; transform: translate(-50%, -100%); z-index: 35; }
.pin b {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-top-left-radius: 50%;
  border-top-right-radius: 50%;
  border-bottom-right-radius: 50%;
  border-bottom-left-radius: 3px;
  background: var(--primary-700);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  font-style: normal;
  line-height: 1;
  box-shadow: #00000057 0 6px 16px;
  transform: scale(0);
  transition: transform 180ms cubic-bezier(0.34, 1.4, 0.64, 1), background 200ms ease,
    width 150ms ease, height 150ms ease;
}
.pin.is-shown b { transform: scale(1); }
.pin.is-resolved b {
  width: 28px;
  height: 28px;
  background: var(--pin-resolved);
  opacity: 0.92;
  box-shadow: #00000038 0 3px 9px;
}

/* =====================================================================
   SCENE B — BROWSER + SHARED REVIEW PAGE (apps/client), exact
   ===================================================================== */
#sceneReview { opacity: 0; transition: opacity 450ms ease; }
#sceneReview.is-shown { opacity: 1; }
.browser {
  position: absolute;
  left: 0;
  top: 0;
  width: 1440px;
  height: 900px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--gestalt-black);
  display: flex;
  flex-direction: column;
}
.browser-chrome {
  height: 42px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  background: #1c1c20;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.browser-chrome .traffic { display: flex; gap: 8px; }
.browser-chrome .traffic i { width: 12px; height: 12px; border-radius: 50%; display: block; }
.browser-chrome .traffic i:nth-child(1) { background: #ff5f57; }
.browser-chrome .traffic i:nth-child(2) { background: #febc2e; }
.browser-chrome .traffic i:nth-child(3) { background: #28c840; }
.url-pill {
  flex: 1;
  max-width: 480px;
  margin: 0 auto;
  height: 26px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  overflow: hidden;
  white-space: nowrap;
  padding: 0 12px;
}
.url-pill svg { opacity: 0.5; flex-shrink: 0; }
.browser-chrome .spacer { width: 52px; }
.srp { flex: 1; min-height: 0; display: flex; flex-direction: column; background: var(--gestalt-black); }
.srp-toolbar {
  height: 36px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.02);
  user-select: none;
}
.srp-logo { color: rgba(255, 255, 255, 0.6); display: grid; place-items: center; }
.srp-toolbar .spacer { flex: 1; }
.srp-meta { flex-shrink: 0; font-size: 11px; color: rgba(255, 255, 255, 0.5); }
.srp-tool-btn { display: grid; width: 24px; height: 24px; place-items: center; border-radius: 9px; color: rgba(255, 255, 255, 0.4); }
.srp-divider { height: 14px; width: 1px; background: rgba(255, 255, 255, 0.1); }
.srp-body { flex: 1; min-height: 0; display: flex; padding: 6px; }
.srp-shell {
  flex: 1;
  display: flex;
  min-width: 0;
  overflow: hidden;
  border-radius: 10px;
  background: var(--gestalt-black);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
}
.srp-panel {
  width: 400px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
  color: #fff;
}
.srp-panel-head { display: flex; align-items: center; gap: 10px; background: rgba(255, 255, 255, 0.02); padding: 8px 12px; }
.srp-panel-titles { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.srp-panel-title {
  font-size: 13px;
  font-weight: 500;
  line-height: 16px;
  color: rgba(255, 255, 255, 0.9);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.srp-panel-sub { font-size: 13px; line-height: 12px; color: rgba(255, 255, 255, 0.5); }
.srp-panel-icon { display: grid; width: 22px; height: 22px; place-items: center; border-radius: 5px; color: rgba(255, 255, 255, 0.4); flex-shrink: 0; }
.srp-list { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; overflow: hidden; padding: 8px 12px; }
.srp-composer-wrap { padding: 8px 12px; }
.srp-composer {
  display: flex;
  align-items: center;
  gap: 6px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  padding: 8px 12px;
  margin-bottom: 4px;
  font-size: 13px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.5);
}
.srp-composer svg { margin-left: auto; opacity: 0.4; flex-shrink: 0; }
.srp-content { flex: 1; min-width: 0; position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden; }

/* agent-published HTML artifact */
.artifact {
  position: relative;
  width: 780px;
  height: 692px;
  background: #fdfdfc;
  overflow: hidden;
  font-family: var(--font-system);
  border-radius: 2px;
  color: #17181c;
}
.artifact-inner { padding: 36px 44px; }
.artifact h1 { font-size: 21px; font-weight: 650; letter-spacing: -0.01em; color: #17171c; }
.artifact .a-meta { margin-top: 6px; font-size: 12px; color: #8e8e95; }
.a-chips { display: flex; gap: 8px; margin-top: 18px; }
.a-chip { font-size: 11.5px; font-weight: 600; padding: 5px 11px; border-radius: 999px; display: flex; align-items: center; gap: 6px; }
.a-chip i { width: 7px; height: 7px; border-radius: 50%; display: block; }
.a-chip.ok { background: #e0f3e9; color: #157347; }
.a-chip.ok i { background: #2c9f68; }
.a-chip.esc { background: #e5edfc; color: #1d4ed8; }
.a-chip.esc i { background: #2563eb; }
.a-chip.warn { background: #fdf3d7; color: #8a6d1a; }
.a-chip.warn i { background: #e3b53a; }
.a-section { margin-top: 22px; }
.a-section h2 { font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: #9a9aa1; }
.a-table { margin-top: 8px; border: 1px solid #ececef; border-radius: 8px; overflow: hidden; }
.a-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 14px;
  border-top: 1px solid #f0f0f3;
  font-size: 12.5px;
  color: #3a3a40;
  background: #fff;
}
.a-row:first-child { border-top: none; }
.a-row b { font-weight: 600; color: #1c1c21; width: 52px; }
.a-row .a-cust { flex: 1; color: #55555c; }
.a-row .a-amt { width: 64px; text-align: right; color: #55555c; }
.a-row .a-why { width: 210px; font-size: 11px; color: #8e8e95; }
.a-row.is-attention { background: #fdf8e9; }
.a-more { padding: 8px 14px; font-size: 11px; color: #9a9aa1; background: #fafafb; border-top: 1px solid #f0f0f3; }

/* cursor */
.cursor {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 60;
  pointer-events: none;
  transition: transform 700ms cubic-bezier(0.3, 0.1, 0.25, 1);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
}

@media (prefers-reduced-motion: reduce) {
  .fade-io, .lace-panel, .pill, .pill-bar, .pin b, .lace-card, .agent-card, .cursor, #sceneReview { transition: none !important; }
  .wave span, .pill.is-processing .pill-bar { animation: none !important; }
}
