/* Brochure Studio review screen (page.ts serves it at /review/app.css).
   2026-10-04 AI-first design, restyled the same day (owner: "from 2024-2025 to current and forward looking; no
   gradients, no violet, no generic spheres"): neutral graphite or paper, the brochure the brightest thing on screen,
   one solid accent per host (MiClara's gold, used sparingly; Casafari's blue) marking only what the AI does, and the
   host's own mark in the bar. No gradient, glow, aurora or orb anywhere: the "2026 look" block at the end flattens
   the components below.

   Themes (2026-10-04, theme.ts): every colour, font and corner below is a token. The person chooses light, dark or
   their system's (data-theme on <html>, kept in localStorage by /review/theme.js); the host chooses the look
   (data-host: the studio's own, miclara.ai's, Casafari's), and a tenant's own accent, font and corner radius arrive as
   inline custom properties on <html>, which win over all of these. Dark is the studio's default; a host's preset
   decides its own default mode. */

@property --ang { syntax: "<angle>"; initial-value: 0deg; inherits: false; }

:root {
  color-scheme: dark;
  --bg: #0f0f10;
  --bg-2: #151516;
  --bg-3: #1c1c1e;
  --pop: #18181a;
  --glass: rgba(26, 26, 28, .94);
  --glass-2: rgba(255, 255, 255, .045);
  --glass-3: rgba(255, 255, 255, .08);
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --fg-tint: #ffffff;
  --text: #ededea;
  --text-2: #a6a5a0;
  --text-3: #73726d;
  --ai-c: #d4b062;
  --ai-c2: #d4b062;
  --ai-c3: #d4b062;
  --ai-c4: #d4b062;
  --ai-c5: #d4b062;
  --ai-c6: #d4b062;
  --ai-1: #d4b062;
  --ai-2: #d4b062;
  --ai-3: #d4b062;
  --ai: #d4b062;
  --ai-fg: #161513;
  --ai-icon: #161513;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #d4b062 35%, transparent);
  --ring-1: #d4b062;
  --ring-2: #d4b062;
  --ring-3: #d4b062;
  --ring-4: #d4b062;
  --orb-1: #d4b062;
  --orb-2: #d4b062;
  --orb-3: #d4b062;
  --orb-4: #d4b062;
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #ffffff;
  --solid-fg: #0b0c12;
  --solid-hover: #e8e9f1;
  --title-a: #ededea;
  --title-b: #ededea;
  --shimmer-hi: #ffffff;
  --shade: #000000;
  --shade-k: 1;
  --scrim-c: #050505;
  --scrim-k: 1;
  --drop-c: #151516;
  --ok: #4ade80;
  --warn: #fbbf24;
  --bad: #fb7185;
  --r-btn: 10px;
  --r-sm: 8px;
  --r: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --bar-h: 58px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-d: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* The studio's own light look. */
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f6f5f2;
  --bg-2: #eeede8;
  --bg-3: #ffffff;
  --pop: #ffffff;
  --glass: rgba(255, 255, 255, .96);
  --glass-2: rgba(15, 17, 26, .035);
  --glass-3: rgba(15, 17, 26, .065);
  --line: rgba(15, 17, 26, .10);
  --line-2: rgba(15, 17, 26, .17);
  --fg-tint: #0f111a;
  --text: #161513;
  --text-2: #55534e;
  --text-3: #85827b;
  --ai-c: #7a5a17;
  --ai-c2: #7a5a17;
  --ai-c3: #7a5a17;
  --ai-c4: #7a5a17;
  --ai-c5: #7a5a17;
  --ai-c6: #7a5a17;
  --ai-1: #7a5a17;
  --ai-2: #7a5a17;
  --ai-3: #7a5a17;
  --ai: #7a5a17;
  --ai-fg: #ffffff;
  --ai-icon: #ffffff;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #7a5a17 35%, transparent);
  --ring-1: #7a5a17;
  --ring-2: #7a5a17;
  --ring-3: #7a5a17;
  --ring-4: #7a5a17;
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #0f111a;
  --solid-fg: #ffffff;
  --solid-hover: #2a2e3b;
  --title-a: #161513;
  --title-b: #161513;
  --shimmer-hi: #0f111a;
  --shade: #0f111a;
  --shade-k: .32;
  --scrim-c: #0f111a;
  --scrim-k: .5;
  --drop-c: #f6f5f2;
  --ok: #15803d;
  --warn: #b45309;
  --bad: #e11d48;
}
@media (prefers-color-scheme: light) {
  :root[data-theme="system"] {
    color-scheme: light;
    --bg: #f6f5f2;
    --bg-2: #eeede8;
    --bg-3: #ffffff;
    --pop: #ffffff;
    --glass: rgba(255, 255, 255, .96);
    --glass-2: rgba(15, 17, 26, .035);
    --glass-3: rgba(15, 17, 26, .065);
    --line: rgba(15, 17, 26, .10);
    --line-2: rgba(15, 17, 26, .17);
    --fg-tint: #0f111a;
    --text: #161513;
    --text-2: #55534e;
    --text-3: #85827b;
    --ai-c: #7a5a17;
    --ai-c2: #7a5a17;
    --ai-c3: #7a5a17;
    --ai-c4: #7a5a17;
    --ai-c5: #7a5a17;
    --ai-c6: #7a5a17;
    --ai-1: #7a5a17;
    --ai-2: #7a5a17;
    --ai-3: #7a5a17;
    --ai: #7a5a17;
    --ai-fg: #ffffff;
    --ai-icon: #ffffff;
    --ai-glow: 0 0 0 1px color-mix(in srgb, #7a5a17 35%, transparent);
    --ring-1: #7a5a17;
    --ring-2: #7a5a17;
    --ring-3: #7a5a17;
    --ring-4: #7a5a17;
    --aurora-a: transparent;
    --aurora-b: transparent;
    --aurora-c: transparent;
    --solid-bg: #0f111a;
    --solid-fg: #ffffff;
    --solid-hover: #2a2e3b;
    --title-a: #161513;
    --title-b: #161513;
    --shimmer-hi: #0f111a;
    --shade: #0f111a;
    --shade-k: .32;
    --scrim-c: #0f111a;
    --scrim-k: .5;
    --drop-c: #f6f5f2;
    --ok: #15803d;
    --warn: #b45309;
    --bad: #e11d48;
  }
}

/* miclara.ai: the site's own paper, ink, sand and gold; Fraunces headings, Public Sans text (each falls back to the
   system's when it is not installed: the screen loads no font files). The AI's accent is the site's gold. */
:root[data-host="miclara"] {
  --font: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-d: "Fraunces", "Newsreader", Georgia, "Times New Roman", serif;
  --r-btn: 6px;
  --r-sm: 4px;
  --r: 8px;
  --r-lg: 12px;
  --r-xl: 16px;
  --ai: #d4b062;
  --ai-fg: #161513;
  --ai-icon: #161513;
  --orb-1: #d4b062;
  --orb-2: #d4b062;
  --orb-3: #d4b062;
  --orb-4: #d4b062;
  --ring-1: #d4b062;
  --ring-2: #d4b062;
  --ring-3: #d4b062;
  --ring-4: #d4b062;
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --bg: #121113;
  --bg-2: #1a1917;
  --bg-3: #221f1b;
  --pop: #1c1a17;
  --glass: rgba(28, 26, 23, .7);
  --text: #fdfcfa;
  --text-2: #cfc7b6;
  --text-3: #8b8476;
  --ai-c: #d4b062;
  --ai-c2: #d4b062;
  --ai-c3: #d4b062;
  --ai-c4: #d4b062;
  --ai-c5: #d4b062;
  --ai-c6: #d4b062;
  --ai-1: #d4b062;
  --ai-2: #d4b062;
  --ai-3: #d4b062;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #d4b062 35%, transparent);
  --solid-bg: #fdfcfa;
  --solid-fg: #121113;
  --solid-hover: #f6f1e5;
  --title-a: #fdfcfa;
  --title-b: #e7d9b8;
  --drop-c: #1a1917;
}
:root[data-host="miclara"][data-theme="light"] {
  color-scheme: light;
  --bg: #fdfcfa;
  --bg-2: #f6f1e5;
  --bg-3: #ffffff;
  --pop: #fffdf9;
  --glass: rgba(253, 252, 250, .82);
  --glass-2: rgba(18, 17, 19, .035);
  --glass-3: rgba(18, 17, 19, .06);
  --line: rgba(18, 17, 19, .10);
  --line-2: rgba(201, 182, 131, .7);
  --fg-tint: #121113;
  --text: #121113;
  --text-2: #5b564c;
  --text-3: #8b8476;
  --ai-c: #7a5a17;
  --ai-c2: #7a5a17;
  --ai-c3: #7a5a17;
  --ai-c4: #7a5a17;
  --ai-c5: #7a5a17;
  --ai-c6: #7a5a17;
  --ai-1: #7a5a17;
  --ai-2: #7a5a17;
  --ai-3: #7a5a17;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #7a5a17 35%, transparent);
  --solid-bg: #121113;
  --solid-fg: #fdfcfa;
  --solid-hover: #34302a;
  --title-a: #121113;
  --title-b: #34302a;
  --shimmer-hi: #121113;
  --shade: #34302a;
  --shade-k: .28;
  --scrim-c: #121113;
  --scrim-k: .45;
  --drop-c: #f6f1e5;
  --ok: #3f7d3a;
  --warn: #7a5a17;
  --bad: #b42318;
}
@media (prefers-color-scheme: light) {
  :root[data-host="miclara"][data-theme="system"] {
    color-scheme: light;
    --bg: #fdfcfa;
    --bg-2: #f6f1e5;
    --bg-3: #ffffff;
    --pop: #fffdf9;
    --glass: rgba(253, 252, 250, .82);
    --glass-2: rgba(18, 17, 19, .035);
    --glass-3: rgba(18, 17, 19, .06);
    --line: rgba(18, 17, 19, .10);
    --line-2: rgba(201, 182, 131, .7);
    --fg-tint: #121113;
    --text: #121113;
    --text-2: #5b564c;
    --text-3: #8b8476;
    --ai-c: #7a5a17;
    --ai-c2: #7a5a17;
    --ai-c3: #7a5a17;
    --ai-c4: #7a5a17;
    --ai-c5: #7a5a17;
    --ai-c6: #7a5a17;
    --ai-1: #7a5a17;
    --ai-2: #7a5a17;
    --ai-3: #7a5a17;
    --ai-glow: 0 0 0 1px color-mix(in srgb, #7a5a17 35%, transparent);
    --solid-bg: #121113;
    --solid-fg: #fdfcfa;
    --solid-hover: #34302a;
    --title-a: #121113;
    --title-b: #34302a;
    --shimmer-hi: #121113;
    --shade: #34302a;
    --shade-k: .28;
    --scrim-c: #121113;
    --scrim-k: .45;
    --drop-c: #f6f1e5;
    --ok: #3f7d3a;
    --warn: #7a5a17;
    --bad: #b42318;
  }
}

/* Casafari: the design system's blue action, ink and grey ramp, 4px corners, Söhne/Inter; its blue for the AI. */
:root[data-host="casafari"] {
  --font: "Söhne", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-d: "Söhne", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --r-btn: 4px;
  --r-sm: 4px;
  --r: 4px;
  --r-lg: 6px;
  --r-xl: 8px;
  --ai: #4d9bf0;
  --ai-fg: #0b0c10;
  --ai-icon: #0b0c10;
  --orb-1: #4d9bf0;
  --orb-2: #4d9bf0;
  --orb-3: #4d9bf0;
  --orb-4: #4d9bf0;
  --ring-1: #4d9bf0;
  --ring-2: #4d9bf0;
  --ring-3: #4d9bf0;
  --ring-4: #4d9bf0;
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #0f72e6;
  --solid-fg: #ffffff;
  --solid-hover: #0d62c5;
  --ai-c: #4d9bf0;
  --ai-c2: #4d9bf0;
  --ai-c3: #4d9bf0;
  --ai-c4: #4d9bf0;
  --ai-c5: #4d9bf0;
  --ai-c6: #4d9bf0;
  --ai-1: #4d9bf0;
  --ai-2: #4d9bf0;
  --ai-3: #4d9bf0;
}
:root[data-host="casafari"][data-theme="light"] {
  color-scheme: light;
  --bg: #f9fafb;
  --bg-2: #f3f4f7;
  --bg-3: #ffffff;
  --pop: #ffffff;
  --glass: rgba(255, 255, 255, .85);
  --glass-2: rgba(28, 28, 28, .035);
  --glass-3: rgba(28, 28, 28, .06);
  --line: #e9ecf1;
  --line-2: #dadfe7;
  --fg-tint: #1c1c1c;
  --text: #1c1c1c;
  --text-2: #344151;
  --text-3: #6e6e6e;
  --ai-c: #0f72e6;
  --ai-c2: #0f72e6;
  --ai-c3: #0f72e6;
  --ai-c4: #0f72e6;
  --ai-c5: #0f72e6;
  --ai-c6: #0f72e6;
  --ai-1: #0f72e6;
  --ai-2: #0f72e6;
  --ai-3: #0f72e6;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #0f72e6 35%, transparent);
  --title-a: #1c1c1c;
  --title-b: #344151;
  --shimmer-hi: #1c1c1c;
  --shade: #262626;
  --shade-k: .22;
  --scrim-c: #1c1c1c;
  --scrim-k: .45;
  --drop-c: #ecf4fe;
  --ok: #176f27;
  --warn: #6d5601;
  --bad: #a03c03;
}
@media (prefers-color-scheme: light) {
  :root[data-host="casafari"][data-theme="system"] {
    color-scheme: light;
    --bg: #f9fafb;
    --bg-2: #f3f4f7;
    --bg-3: #ffffff;
    --pop: #ffffff;
    --glass: rgba(255, 255, 255, .85);
    --glass-2: rgba(28, 28, 28, .035);
    --glass-3: rgba(28, 28, 28, .06);
    --line: #e9ecf1;
    --line-2: #dadfe7;
    --fg-tint: #1c1c1c;
    --text: #1c1c1c;
    --text-2: #344151;
    --text-3: #6e6e6e;
    --ai-c: #0f72e6;
    --ai-c2: #0f72e6;
    --ai-c3: #0f72e6;
    --ai-c4: #0f72e6;
    --ai-c5: #0f72e6;
    --ai-c6: #0f72e6;
    --ai-1: #0f72e6;
    --ai-2: #0f72e6;
    --ai-3: #0f72e6;
    --ai-glow: 0 0 0 1px color-mix(in srgb, #0f72e6 35%, transparent);
    --title-a: #1c1c1c;
    --title-b: #344151;
    --shimmer-hi: #1c1c1c;
    --shade: #262626;
    --shade-k: .22;
    --scrim-c: #1c1c1c;
    --scrim-k: .45;
    --drop-c: #ecf4fe;
    --ok: #176f27;
    --warn: #6d5601;
    --bad: #a03c03;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
/* The aurora: slow light behind everything. */
body::before {
  content: ""; position: fixed; inset: -20%; z-index: 0; pointer-events: none;
  background:
    radial-gradient(40% 35% at 18% 12%, color-mix(in srgb, var(--aurora-a) 16%, transparent), transparent 70%),
    radial-gradient(35% 30% at 88% 8%, color-mix(in srgb, var(--aurora-b) 10%, transparent), transparent 70%),
    radial-gradient(45% 40% at 60% 105%, color-mix(in srgb, var(--aurora-c) 14%, transparent), transparent 70%);
  animation: aurora 40s ease-in-out infinite alternate;
}
@keyframes aurora { from { transform: translate3d(0, 0, 0) rotate(0deg); } to { transform: translate3d(-3%, 2%, 0) rotate(6deg); } }
button { font: inherit; color: inherit; }
.muted { color: var(--text-2); }
.small { font-size: 12px; }
.row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.ic { display: inline-flex; width: 16px; height: 16px; flex: none; }
.ic svg { width: 100%; height: 100%; }
.eyebrow { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); font-weight: 600; }
.glass { background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%); }
.in { animation: rise .55s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); filter: blur(4px); } to { opacity: 1; transform: none; filter: none; } }
:focus-visible { outline: 2px solid var(--focus, var(--ai-2)); outline-offset: 2px; }

/* ---- the orb: the assistant's presence ---- */
.orb { position: relative; width: 22px; height: 22px; flex: none; border-radius: 50%; display: inline-block;
  background: radial-gradient(circle at 32% 30%, #fff 0%, var(--orb-1) 18%, var(--orb-2) 46%, var(--orb-3) 70%, var(--orb-4) 100%);
  box-shadow: 0 0 18px -2px color-mix(in srgb, var(--ai-c) 65%, transparent), inset 0 0 6px color-mix(in srgb, var(--fg-tint) 35%, transparent); }
.orb i { position: absolute; inset: -3px; border-radius: 50%; border: 1px solid color-mix(in srgb, var(--ai-c2) 35%, transparent); opacity: 0; }
.orb.live { animation: orbBreath 2.4s ease-in-out infinite; }
.orb.live i { animation: orbRing 2.4s var(--ease) infinite; }
.orb.live i + i { animation-delay: 1.2s; }
.orb.sm { width: 18px; height: 18px; }
.orb.xl { width: 56px; height: 56px; box-shadow: 0 0 60px -6px color-mix(in srgb, var(--ai-c) 80%, transparent), inset 0 0 14px color-mix(in srgb, var(--fg-tint) 40%, transparent); }
@keyframes orbBreath { 0%, 100% { transform: scale(1); filter: hue-rotate(0deg); } 50% { transform: scale(1.08); filter: hue-rotate(28deg); } }
@keyframes orbRing { from { transform: scale(1); opacity: .9; } to { transform: scale(2.1); opacity: 0; } }

/* ---- buttons ---- */
.btn { height: 36px; padding: 0 14px; border-radius: var(--r-btn); border: 0; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 14px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: transform .15s var(--ease), background-color .15s, box-shadow .2s, opacity .15s, background-position .4s; }
.btn:active:not(:disabled) { transform: scale(.97); }
.btn:disabled { opacity: .38; cursor: not-allowed; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: calc(var(--r-btn) - 1px); }
.btn-xs { height: 26px; padding: 0 10px; font-size: 12px; border-radius: 8px; gap: 6px; }
.btn-xs .ic { width: 13px; height: 13px; }
.btn.wide { width: 100%; height: 44px; font-size: 15px; }
.btn-solid { background: var(--solid-bg); color: var(--solid-fg); font-weight: 600; }
.btn-solid:hover:not(:disabled) { background: var(--solid-hover); box-shadow: 0 6px 24px -8px color-mix(in srgb, var(--fg-tint) 50%, transparent); }
.btn-glass { background: var(--glass-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.btn-glass:hover:not(:disabled) { background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover:not(:disabled) { background: var(--glass-2); color: var(--text); }
.btn-ghost.danger { color: var(--bad); }
.btn-icon { width: 34px; height: 34px; padding: 0; background: transparent; color: var(--text-2); border-radius: var(--r-btn); }
.btn-icon:hover { background: var(--glass-3); color: var(--text); }
.btn-ai { background: var(--ai); background-size: 180% 100%; background-position: 0 0; color: var(--ai-fg); font-weight: 600; box-shadow: 0 0 0 1px color-mix(in srgb, var(--fg-tint) 20%, transparent) inset; }
.btn-ai:hover:not(:disabled) { background-position: 100% 0; box-shadow: var(--ai-glow); }
.btn-ai .ic svg path { fill: var(--ai-icon) !important; }
.kbd { font: 600 11px/1 var(--font); color: var(--text-3); border: 1px solid var(--line-2); border-radius: 6px; padding: 3px 6px; }
.tag { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 600; background: var(--glass-3); color: var(--text-2); width: fit-content; }
.tag.ok { background: color-mix(in srgb, var(--ok) 12%, transparent); color: var(--ok); }
.tag.bad { background: color-mix(in srgb, var(--bad) 12%, transparent); color: var(--bad); }
.tag.ai { background: color-mix(in srgb, var(--ai-c) 16%, transparent); color: var(--ai-1); }

/* ---- top bar ---- */
.bar { position: relative; z-index: 20; height: var(--bar-h); display: flex; align-items: center; gap: 10px; padding: 0 16px;
  border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 72%, transparent); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.brand { display: inline-flex; align-items: center; gap: 10px; background: none; border: 0; cursor: pointer; padding: 6px 8px 6px 4px; border-radius: var(--r-btn); }
.brand:hover { background: var(--glass-2); }
.brand-t { font: 600 15px/1 var(--font-d); letter-spacing: -.01em; }
.bar-doc { display: flex; align-items: center; gap: 10px; min-width: 0; }
.bar-doc .sep { width: 1px; height: 20px; background: var(--line-2); }
.doc-t { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 36vw; }
.bar-spacer { flex: 1; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 500; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--text-2); white-space: nowrap; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); flex: none; }
.st-done .dot, .dot.st-done { background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.st-frozen .dot, .dot.st-frozen { background: var(--ai-3); box-shadow: 0 0 10px var(--ai-3); }
.st-needs_edit .dot, .dot.st-needs_edit { background: var(--warn); box-shadow: 0 0 10px var(--warn); }
.st-failed .dot, .dot.st-failed { background: var(--bad); box-shadow: 0 0 10px var(--bad); }
.st-running .dot, .st-queued .dot, .dot.st-running, .dot.st-queued { background: var(--ai-1); box-shadow: 0 0 10px var(--ai-1); animation: blink 1.2s ease-in-out infinite; }
.pill.st-running, .pill.st-queued { color: var(--ai-1); }
@keyframes blink { 50% { opacity: .35; } }

.app { position: relative; z-index: 1; height: calc(100% - var(--bar-h)); }

/* ---- sign in ---- */
.signin { height: 100%; display: grid; place-items: center; padding: 24px; }
.signin-box { width: min(420px, 100%); display: flex; flex-direction: column; gap: 16px; align-items: stretch; padding: 36px 32px; border-radius: var(--r-xl);
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(24px); box-shadow: 0 40px 120px -40px color-mix(in srgb, var(--shade) calc(80% * var(--shade-k)), transparent); }
.signin-box .orb { align-self: center; }
.signin-box h1 { margin: 0; text-align: center; font: 600 24px/1.2 var(--font-d); letter-spacing: -.02em; }
.field { display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--text-2); }
.input, .textarea, .pal-in, .tb-in { width: 100%; border: 0; color: var(--text); background: color-mix(in srgb, var(--fg-tint) 4%, transparent); box-shadow: inset 0 0 0 1px var(--line); border-radius: var(--r-btn); font: inherit; }
.input { height: 44px; padding: 0 14px; }
.textarea { padding: 12px 14px; line-height: 1.6; resize: vertical; }
.input:focus, .textarea:focus { outline: none; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 60%, transparent), 0 0 0 4px color-mix(in srgb, var(--ai-c) 12%, transparent); }
.note { padding: 10px 12px; border-radius: var(--r-btn); font-size: 13px; }
.note.warn { background: color-mix(in srgb, var(--warn) 10%, transparent); color: var(--warn); }

/* ---- welcome ---- */
.welcome { height: 100%; overflow: auto; padding: clamp(28px, 6vh, 72px) clamp(16px, 5vw, 64px) 64px; }
.hero { max-width: 980px; margin: 0 auto 56px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.badge-ai { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 14px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--ai-1);
  background: color-mix(in srgb, var(--ai-c) 10%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 25%, transparent); }
.grad-t { margin: 0; font: 650 clamp(34px, 5.4vw, 64px)/1.04 var(--font-d); letter-spacing: -.035em; max-width: 15ch;
  background: linear-gradient(180deg, var(--title-a) 30%, var(--title-b) 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lede { margin: 0; max-width: 60ch; font-size: clamp(15px, 1.4vw, 18px); color: var(--text-2); }
.points { list-style: none; margin: 12px 0 0; padding: 0; display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.points li { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: calc(var(--r) + 2px); font-size: 13px; color: var(--text); max-width: 300px; text-align: left; }
.points li .ic { color: var(--ai-2); width: 18px; height: 18px; }
.recent-wrap { max-width: 1180px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.card-b { position: relative; text-align: left; display: flex; flex-direction: column; gap: 8px; padding: 18px; min-height: 120px; border-radius: var(--r-lg); cursor: pointer;
  background: linear-gradient(180deg, color-mix(in srgb, var(--fg-tint) 5.5%, transparent), color-mix(in srgb, var(--fg-tint) 2%, transparent)); border: 1px solid var(--line); transition: transform .25s var(--ease), border-color .2s, box-shadow .25s; overflow: hidden; }
.card-b::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .25s;
  background: radial-gradient(120% 80% at 0% 0%, color-mix(in srgb, var(--ai-c) 14%, transparent), transparent 60%); }
.card-b:hover { transform: translateY(-3px); border-color: var(--line-2); box-shadow: 0 24px 60px -30px color-mix(in srgb, var(--shade) calc(80% * var(--shade-k)), transparent); }
.card-b:hover::after { opacity: 1; }
.card-b .row1 { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.card-b .title { font: 600 17px/1.3 var(--font-d); letter-spacing: -.01em; }
.empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 40px 24px; border-radius: var(--r-lg); text-align: center; }
.skeleton { background: linear-gradient(90deg, color-mix(in srgb, var(--fg-tint) 4%, transparent) 25%, color-mix(in srgb, var(--fg-tint) 9%, transparent) 50%, color-mix(in srgb, var(--fg-tint) 4%, transparent) 75%); background-size: 200% 100%; animation: shimmer 1.6s linear infinite; border-radius: var(--r); }
.card-b.skeleton { cursor: default; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* ---- palette (all brochures) ---- */
.scrim { position: fixed; inset: 0; z-index: 50; background: color-mix(in srgb, var(--scrim-c) calc(55% * var(--scrim-k)), transparent); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 16px; animation: fade .2s ease both; }
.scrim.top { place-items: start center; padding-top: min(14vh, 120px); }
@keyframes fade { from { opacity: 0; } }
.palette { width: min(640px, 100%); max-height: 70vh; display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden;
  background: color-mix(in srgb, var(--pop) 92%, transparent); border: 1px solid var(--line-2); box-shadow: 0 40px 120px -30px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent), var(--ai-glow); animation: pop .25s var(--ease) both; }
@keyframes pop { from { opacity: 0; transform: translateY(-8px) scale(.98); } }
.pal-h { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--line); color: var(--text-3); }
.pal-in { height: 56px; background: transparent; box-shadow: none; font-size: 16px; padding: 0; }
.pal-in:focus { outline: none; }
.pal-list { overflow: auto; padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.pal-item { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; text-align: left; padding: 10px 12px; border-radius: var(--r-btn); background: none; border: 0; cursor: pointer; }
.pal-item.on { background: var(--glass-3); }
.pal-t { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-empty { padding: 28px; text-align: center; color: var(--text-2); }
.pal-f { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--text-3); }

/* ---- the studio: rail | canvas | assistant ---- */
.studio { --grip: 12px; --rail-w: 176px; --panel-w: 400px; height: 100%; display: grid; grid-template-columns: var(--rail-w) var(--grip) minmax(0, 1fr) var(--grip) var(--panel-w); }
/* The sizes above are only defaults: a divider the person has dragged writes its own --rail-w / --panel-w inline (WP37). */

.rail { min-width: 0; overflow: auto; padding: 14px 10px; display: flex; flex-direction: column; gap: 2px; background: color-mix(in srgb, var(--bg) 40%, transparent); }
.rail-i { position: relative; display: flex; align-items: center; border-radius: var(--r-btn); }
.rail-i:hover, .rail-i.is-open { background: var(--glass-2); }
.rail-b { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 8px; background: none; border: 0; cursor: pointer; text-align: left; border-radius: var(--r-btn); }
.rail-n { width: 24px; height: 24px; flex: none; display: grid; place-items: center; border-radius: 7px; font-size: 11px; font-weight: 600; color: var(--text-2); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); }
.rail-l { font-size: 13px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail-i:hover .rail-l { color: var(--text); }
.rail-i.dropped .rail-l { text-decoration: line-through; color: var(--text-3); }
.rail-i.omitted .rail-l, .rail-i.omitted .rail-n { opacity: .45; }
.rail-i.omitted .rail-b { cursor: default; }
.rail-t { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rail-why { font-size: 11px; line-height: 1.3; color: var(--text-3); white-space: normal; }

/* ---- who the brochure is written for: the two-chip switch in "About your client" ---- */
.aud { display: flex; flex-direction: column; gap: 6px; padding: 2px 2px 0; }
.aud-h { font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--text-3); }
.aud-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.aud-chip { height: 30px; padding: 0 12px; border-radius: 999px; border: 0; cursor: pointer; font-size: 12.5px; color: var(--text-2); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s, background-color .2s, color .2s; }
.aud-chip:hover:not(:disabled):not(.on) { color: var(--text); background: var(--glass-3); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 45%, transparent); }
.aud-chip.on { color: var(--text); background: color-mix(in srgb, var(--ai-c) 14%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 60%, transparent); cursor: default; }
.aud-chip:disabled:not(.on) { opacity: .5; cursor: default; }
.aud-chip:focus-visible { outline: 2px solid var(--ai-c2); outline-offset: 2px; }
.flag { width: 7px; height: 7px; border-radius: 50%; background: var(--warn); box-shadow: 0 0 8px var(--warn); flex: none; margin-left: auto; }
.rail-m { width: 26px; height: 26px; display: grid; place-items: center; background: none; border: 0; border-radius: 8px; color: var(--text-3); cursor: pointer; opacity: 0; margin-right: 4px; }
.rail-i:hover .rail-m, .rail-i.is-open .rail-m, .rail-m:focus-visible { opacity: 1; }
.rail-m:hover { background: var(--glass-3); color: var(--text); }
.menu { position: absolute; z-index: 30; left: calc(100% - 8px); top: 4px; min-width: 200px; padding: 6px; border-radius: var(--r); box-shadow: 0 24px 60px -20px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); animation: pop .18s var(--ease) both; }
.menu-b { width: 100%; display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: none; border: 0; border-radius: 8px; cursor: pointer; text-align: left; font-size: 13px; color: var(--text); }
.menu-b:hover { background: var(--glass-3); }
.menu-b.danger { color: var(--bad); }

/* the canvas */
.stage { position: relative; min-width: 0; overflow: hidden;
  background: radial-gradient(color-mix(in srgb, var(--fg-tint) 4.5%, transparent) 1px, transparent 1px) 0 0 / 22px 22px; }
.stage-scroll { position: absolute; inset: 0; overflow: auto; padding: 8px 12px 120px; }
.stage-scroll:focus { outline: none; }
.preview-sizer { position: relative; margin: 0 auto; transition: opacity .5s, filter .5s; }
.preview-scale { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
/* The brochure is a light document: a frame whose colour scheme differs from its document gets an opaque white backdrop. */
.preview-scale iframe { display: block; border: 0; background: transparent; color-scheme: light; }
.stage.fading .preview-sizer { opacity: .35; filter: saturate(.6) blur(1px); }
.tb-host { position: absolute; inset: 0; pointer-events: none; }
.stage-overlay { position: absolute; inset: 0; pointer-events: none; display: none; }
.stage-overlay.on { display: grid; place-items: center; pointer-events: auto; background: color-mix(in srgb, var(--bg) 55%, transparent); backdrop-filter: blur(2px); }
.stage-overlay.sweep { display: block; overflow: hidden; }
.stage-overlay.drop { background: color-mix(in srgb, var(--drop-c) 72%, transparent); }

.ghosts { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; gap: 28px; padding-top: 36px; overflow: hidden; opacity: .55; }
.ghost-page { width: min(78%, 760px); aspect-ratio: 1.414 / 1; flex: none; border-radius: 4px; background: color-mix(in srgb, var(--fg-tint) 3.5%, transparent); border: 1px solid var(--line);
  display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: min-content; gap: 14px; padding: 6%; animation: rise .8s var(--ease) both; }
.ghost-page i { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, color-mix(in srgb, var(--fg-tint) 5%, transparent) 25%, color-mix(in srgb, var(--ai-c2) 14%, transparent) 50%, color-mix(in srgb, var(--fg-tint) 5%, transparent) 75%); background-size: 200% 100%; animation: shimmer 2s linear infinite; }
.ghost-page .g-img { grid-row: span 5; height: auto; aspect-ratio: 4 / 3; border-radius: 4px; }
.g-l.w9 { width: 90%; } .g-l.w8 { width: 80%; } .g-l.w6 { width: 60%; } .g-l.w5 { width: 50%; }

.theatre { position: relative; width: min(560px, calc(100% - 32px)); max-height: calc(100% - 48px); overflow: auto; display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center;
  padding: 32px 28px; border-radius: var(--r-xl); box-shadow: 0 40px 120px -40px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent), var(--ai-glow); animation: pop .4s var(--ease) both; }
.th-t { font: 600 22px/1.2 var(--font-d); letter-spacing: -.02em; margin-top: 6px; }
.steps { list-style: none; margin: 10px 0 0; padding: 0; width: 100%; display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; text-align: left; }
.steps li { display: flex; flex-direction: column; gap: 8px; font-size: 12px; color: var(--text-3); }
.steps li.done, .steps li.now { color: var(--text); }
.st-l { display: flex; align-items: center; gap: 6px; min-height: 32px; line-height: 1.25; }
.st-l .ic { color: var(--ok); width: 14px; height: 14px; }
.st-l .pulse, .st-l .idle { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.st-l .pulse { background: var(--ai-1); box-shadow: 0 0 12px var(--ai-1); animation: blink 1s ease-in-out infinite; }
.st-l .idle { background: var(--text-3); opacity: .5; }
.st-bar { height: 3px; border-radius: 3px; background: var(--glass-3); overflow: hidden; }
.st-bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--ai); transition: width .6s var(--ease); }
.steps li.now .st-bar i:not([style]) { width: 40%; animation: indet 1.4s ease-in-out infinite; }
@keyframes indet { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }
.th-count { font-size: 12px; color: var(--text-2); margin-top: 6px; }
.chapters { list-style: none; margin: 0; padding: 0; width: 100%; display: flex; flex-direction: column; gap: 8px; text-align: left; }
.chapters li { padding: 10px 12px; border-radius: var(--r); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); }
.chapters li.waiting { opacity: .5; }
.chapters .r { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.chapters .n { font-size: 13px; font-weight: 600; }
.chapters .ex { margin-top: 6px; font-size: 12.5px; color: var(--text-2); line-height: 1.55; font-family: Georgia, "Times New Roman", serif; }
.caret { display: inline-block; width: 7px; height: 1.05em; vertical-align: -2px; margin-left: 1px; background: var(--ai-2); animation: blink .9s steps(2) infinite; border-radius: 1px; }

.sweep-bar { position: absolute; left: 0; right: 0; height: 160px; top: -160px; pointer-events: none;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--ai-c) 18%, transparent) 45%, color-mix(in srgb, var(--ai-c4) 28%, transparent) 50%, color-mix(in srgb, var(--ai-c) 18%, transparent) 55%, transparent);
  animation: sweep 2.2s cubic-bezier(.4, 0, .2, 1) infinite; }
@keyframes sweep { to { top: 100%; } }
.sweep-pill { position: absolute; left: 50%; top: 18px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 10px; height: 38px; padding: 0 16px 0 12px; border-radius: 999px;
  background: color-mix(in srgb, var(--pop) 85%, transparent); border: 1px solid var(--line-2); box-shadow: var(--ai-glow); font-size: 13px; font-weight: 500; backdrop-filter: blur(12px); white-space: nowrap; }
.drop-card { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 36px 44px; border-radius: var(--r-xl); border: 2px dashed color-mix(in srgb, var(--ai-c2) 55%, transparent); color: var(--ai-1); font: 600 18px/1.3 var(--font-d); text-align: center; animation: pop .2s var(--ease) both; }
.drop-card .ic { width: 40px; height: 40px; }
.fail-card { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 28px; max-width: 460px; border-radius: var(--r-lg); text-align: center; }
.fail-card .ic { color: var(--bad); width: 28px; height: 28px; }
.fail-card code { font-size: 12px; color: var(--text-3); word-break: break-word; }

/* WP38: the "updating" card over the last finished version, and the design's card. Neither covers the screen: the card sits in a
   corner of the canvas, and everything around it (the pages, the rail, the conversation) stays usable. */
.build-card { position: absolute; left: 50%; top: 16px; transform: translateX(-50%); pointer-events: auto; width: min(440px, calc(100% - 32px)); display: flex; flex-direction: column; gap: 6px;
  padding: 12px 16px; border-radius: var(--r-lg); background: color-mix(in srgb, var(--pop) 90%, transparent); border: 1px solid var(--line-2); box-shadow: var(--ai-glow); backdrop-filter: blur(12px); font-size: 13px; animation: pop .3s var(--ease) both; }
.build-card .bc-h { display: flex; align-items: center; gap: 10px; }
.build-card .bc-h b { font-weight: 600; }
.bc-q { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.theatre .bc-q { justify-content: center; }
.is-waiting { opacity: .55; cursor: help; }
.prop-card .warn-l { color: var(--warn); }
.dp-host { position: absolute; left: 16px; bottom: 16px; z-index: 6; width: min(360px, calc(100% - 32px)); pointer-events: none; }
.dp-card { pointer-events: auto; display: flex; flex-direction: column; gap: 8px; padding: 14px 16px; border-radius: var(--r-lg); background: color-mix(in srgb, var(--pop) 94%, transparent);
  border: 1px solid var(--line-2); box-shadow: 0 24px 60px -24px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent), var(--ai-glow); backdrop-filter: blur(14px); animation: pop .3s var(--ease) both; }
.dp-card.bad { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bad) 45%, transparent), 0 24px 60px -24px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); }
.dp-top { display: flex; align-items: center; gap: 10px; }
.dp-ic { width: 22px; height: 22px; flex: none; display: grid; place-items: center; color: var(--ai-1); }
.dp-card.bad .dp-ic { color: var(--bad); }
.dp-ic .pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--ai-1); box-shadow: 0 0 12px var(--ai-1); animation: blink 1s ease-in-out infinite; }
.dp-n { flex: 1; min-width: 0; font: 600 14px/1.3 var(--font-d); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dp-x { width: 28px; height: 28px; flex: none; display: grid; place-items: center; border: 0; border-radius: 8px; background: none; color: var(--text-3); cursor: pointer; }
.dp-x:hover { background: var(--glass-3); color: var(--text); }
.dp-h { font-weight: 600; font-size: 13px; }
.dp-l { font-size: 13px; line-height: 1.5; }
.dp-steps { list-style: none; margin: 2px 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--text-3); }
.dp-steps li { display: flex; align-items: center; gap: 8px; }
.dp-steps li.done, .dp-steps li.now { color: var(--text); }
.dp-steps .ic { width: 14px; height: 14px; color: var(--ok); }
.dp-steps .pulse, .dp-steps .idle { width: 8px; height: 8px; border-radius: 50%; flex: none; margin: 0 3px; }
.dp-steps .pulse { background: var(--ai-1); animation: blink 1s ease-in-out infinite; }
.dp-steps .idle { background: var(--text-3); opacity: .5; }
.dp-a { flex-wrap: wrap; gap: 8px; margin-top: 4px; }
@media (max-width: 720px) { .dp-host { left: 8px; right: 8px; bottom: 8px; width: auto; } .build-card { top: 8px; } }

/* the floating toolbar over a picked text */
.tb { position: absolute; pointer-events: auto; display: flex; align-items: center; gap: 2px; flex-wrap: wrap; max-width: min(560px, 92%); padding: 5px; border-radius: calc(var(--r) + 2px);
  background: color-mix(in srgb, var(--pop) 94%, transparent); border: 1px solid var(--line-2); box-shadow: 0 20px 50px -16px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent), var(--ai-glow); backdrop-filter: blur(14px); animation: pop .18s var(--ease) both; }
.tb.wide { width: min(520px, 92%); flex-wrap: nowrap; }
.tb-name { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); padding: 0 8px 0 6px; white-space: nowrap; max-width: 140px; overflow: hidden; text-overflow: ellipsis; }
.tb.wide .tb-name { display: none; }
.tb-b { height: 32px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px; border: 0; border-radius: calc(var(--r-btn) - 1px); background: none; cursor: pointer; font-size: 13px; font-weight: 500; color: var(--text); }
.tb-b:hover { background: var(--glass-3); }
.tb-b.ai { color: var(--ai-1); }
.tb-b.ai:hover { background: color-mix(in srgb, var(--ai-c) 14%, transparent); }
.tb-spark { margin: 0 4px 0 6px; }
.tb-in { height: 32px; background: transparent; box-shadow: none; padding: 0 6px; font-size: 14px; flex: 1; min-width: 0; }
.tb-in:focus { outline: none; }
.tb-go { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border: 0; border-radius: calc(var(--r-btn) - 1px); background: var(--ai); color: var(--ai-fg); cursor: pointer; }
.tb-note { flex-basis: 100%; display: flex; align-items: flex-start; gap: 6px; padding: 6px 8px 4px; font-size: 12px; color: var(--warn); }
.tb-note .ic { width: 14px; height: 14px; margin-top: 2px; }

/* the assistant's column */
.panel { --thread-min: 140px; min-width: 0; min-height: 0; display: flex; flex-direction: column; background: linear-gradient(180deg, color-mix(in srgb, var(--pop) 82%, transparent), color-mix(in srgb, var(--pop) 92%, transparent)); backdrop-filter: blur(20px); }
.panel-head { flex: 0 1 var(--head-h, auto); min-height: 0; overflow: auto; padding: 16px 18px 12px; display: flex; flex-direction: column; gap: 10px; }
.panel-head:empty { display: none; }
.brief { display: flex; align-items: center; gap: 12px; }
.brief .orb { width: 34px; height: 34px; }
.brief-t { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.brief-n { font: 600 16px/1.25 var(--font-d); letter-spacing: -.01em; }
.brief-m { display: flex; gap: 6px; flex-wrap: wrap; }
.mini { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; color: var(--text-2); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); border: 0; cursor: pointer; }
.mini .ic { width: 13px; height: 13px; }
.mini:hover:not(:disabled):not(.static) { color: var(--text); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 45%, transparent); }
.mini.static, .mini:disabled { cursor: default; }
/* the agency on the brochure: its logo, name and contact line; a dashed invitation while none is named */
.agency { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; border-radius: var(--r); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); cursor: pointer; text-align: left; transition: box-shadow .2s, background-color .2s; }
.agency:hover { background: var(--glass-3); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 40%, transparent); }
.agency.missing { background: color-mix(in srgb, var(--ai-c) 6%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 35%, transparent); border: 1px dashed transparent; }
.ag-logo { width: 34px; height: 34px; flex: none; border-radius: 8px; object-fit: contain; background: #fff; padding: 3px; }
.ag-logo.empty { display: grid; place-items: center; background: color-mix(in srgb, var(--fg-tint) 6%, transparent); color: var(--ai-1); font-weight: 700; padding: 0; }
.ag-logo.empty .ic { width: 16px; height: 16px; }
.ag-t { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.ag-n { font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.agency.missing .ag-n { color: var(--ai-1); }
.ag-c { font-size: 11.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ag-edit { color: var(--text-3); width: 14px; height: 14px; }
.modal-agency { width: min(520px, 100%); }
.logo-drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 160px; padding: 20px; border-radius: 16px; cursor: pointer;
  border: 2px dashed color-mix(in srgb, var(--ai-c2) 40%, transparent); background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--ai-c) 10%, transparent), transparent 70%); color: var(--ai-1); transition: border-color .2s, background-color .2s; }
.logo-drop:hover:not(:disabled), .logo-drop.over { border-color: color-mix(in srgb, var(--ai-c2) 85%, transparent); background-color: color-mix(in srgb, var(--ai-c) 8%, transparent); }
.logo-drop:disabled { opacity: .5; cursor: default; }
.logo-drop img { max-width: 200px; max-height: 80px; object-fit: contain; background: #fff; border-radius: 8px; padding: 8px; }
.logo-drop .ic { width: 30px; height: 30px; }
.ld-t { font-weight: 600; color: var(--text); }
.stats { display: flex; gap: 6px; flex-wrap: wrap; }
.stat { font-size: 11.5px; color: var(--text-2); padding: 3px 8px; border-radius: 7px; background: color-mix(in srgb, var(--ai-c) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 14%, transparent); }

.panel-body { flex: 1; min-height: var(--thread-min); overflow: auto; padding: 14px 18px; display: flex; flex-direction: column; gap: 12px; }
.issues { border-radius: calc(var(--r) + 2px); padding: 12px; background: color-mix(in srgb, var(--warn) 6%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 22%, transparent); display: flex; flex-direction: column; gap: 10px; }
.issues-h { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--warn); }
.issues-h .btn { margin-left: auto; }
.count { min-width: 20px; height: 20px; padding: 0 6px; display: inline-grid; place-items: center; border-radius: 999px; font-size: 11px; font-weight: 700; background: color-mix(in srgb, var(--warn) 18%, transparent); }
.issue { display: flex; flex-direction: column; gap: 4px; padding-top: 10px; border-top: 1px solid color-mix(in srgb, var(--warn) 14%, transparent); }
.issue-n { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; font-weight: 600; }
.issue-w { font-size: 12.5px; color: var(--text-2); }
.issue .row { margin-top: 4px; }
.hidden-t { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 999px; border: 0; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--text-2); cursor: pointer; font-size: 12px; }
.hidden-l { display: flex; flex-direction: column; gap: 6px; }
.hidden-i { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 8px; font-size: 13px; padding: 8px 10px; border-radius: var(--r-btn); background: var(--glass-2); }

.thread { display: flex; flex-direction: column; gap: 20px; }
.msg { display: flex; gap: 10px; font-size: 14px; line-height: 1.55; }
.msg.ai .orb { margin-top: 2px; }
.msg-c { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 10px; }
.msg-x:empty { display: none; }
.msg.me { align-self: flex-end; max-width: 88%; padding: 10px 14px; border-radius: 16px 16px 4px 16px; background: color-mix(in srgb, var(--fg-tint) 8%, transparent); box-shadow: inset 0 0 0 1px var(--line); white-space: pre-wrap; }
.msg.sys { align-self: center; align-items: center; gap: 8px; font-size: 12px; color: var(--ai-1); padding: 6px 12px; border-radius: 999px; background: color-mix(in srgb, var(--ai-c) 8%, transparent); }
.msg.sys .ic { width: 13px; height: 13px; }
.msg.thinking { align-items: center; }
.shimmer-t { background: linear-gradient(90deg, var(--text-3) 25%, var(--shimmer-hi) 50%, var(--text-3) 75%); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 1.6s linear infinite; font-weight: 500; }
.prop-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: calc(var(--r) + 2px); background: color-mix(in srgb, var(--pop) 90%, transparent); }
.prop-card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(135deg, color-mix(in srgb, var(--ai-c5) 70%, transparent), color-mix(in srgb, var(--ai-c6) 35%, transparent), color-mix(in srgb, var(--ai-c4) 60%, transparent));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.prop-t { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; }
.prop-rows { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.prop-rows div { display: flex; flex-direction: column; gap: 1px; }
.prop-rows dt { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); font-weight: 600; }
.prop-rows dd { margin: 0; font-size: 13px; color: var(--text); white-space: pre-wrap; }
.prop-op { padding: 8px 10px; border-radius: var(--r-btn); background: var(--glass-2); animation: rise .4s var(--ease) both; }
.prop-op .w { font-size: 11.5px; color: var(--text-3); }
.prop-op .d { font-size: 13px; }

.chips { flex: none; display: flex; gap: 8px; flex-wrap: nowrap; overflow: hidden; padding: 8px 18px 12px; }
.chips:empty { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-width: 0; flex: 0 1 auto; max-width: 100%; height: 30px; padding: 0 12px; border-radius: 999px; border: 0; cursor: pointer; font-size: 12.5px; color: var(--text);
  background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s, background-color .2s, transform .15s var(--ease); }
.chip:hover:not(:disabled) { background: color-mix(in srgb, var(--ai-c) 10%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 45%, transparent); transform: translateY(-1px); }
.chip .ic { width: 13px; height: 13px; }
.chip:disabled { opacity: .45; cursor: default; }

/* the prompt */
.comp-wrap { padding: 0 14px 12px; }
.composer { position: relative; display: flex; align-items: flex-end; gap: 8px; padding: 8px 8px 8px 12px; border-radius: var(--r-lg); background: var(--bg-3); transition: box-shadow .25s; }
.composer::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: conic-gradient(from var(--ang), color-mix(in srgb, var(--fg-tint) 12%, transparent), color-mix(in srgb, var(--fg-tint) 12%, transparent));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.composer.focus::before, .composer.thinking::before { background: conic-gradient(from var(--ang), var(--ring-1), var(--ring-2), var(--ring-3), var(--ring-4), var(--ring-1)); }
.composer.focus { box-shadow: 0 0 0 4px color-mix(in srgb, var(--ai-c) 8%, transparent), 0 18px 40px -20px color-mix(in srgb, var(--ai-c3) 55%, transparent); }
.composer.thinking::before { animation: spin 2.4s linear infinite; }
@keyframes spin { to { --ang: 360deg; } }
.comp-spark { align-self: center; }
.comp-in { flex: 1; min-width: 0; max-height: 160px; resize: none; border: 0; background: transparent; color: var(--text); font: 14.5px/1.5 var(--font); padding: 6px 0; }
.comp-in:focus { outline: none; }
.comp-in::placeholder { color: var(--text-3); }
.comp-send { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border: 0; border-radius: calc(var(--r-btn) + 1px); cursor: pointer; background: var(--solid-bg); color: var(--solid-fg); transition: transform .15s var(--ease), opacity .15s; }
.comp-send .ic { width: 18px; height: 18px; }
.comp-send:hover:not(:disabled) { transform: scale(1.05); }
.comp-send:disabled { opacity: .3; cursor: default; }
/* The key hint shows only while typing, but always keeps its room: hiding it on blur shrank the composer, and a click that blurred the
   prompt moved the conversation under the pointer between press and release, so a proposal's Apply was lost (WP41 review). */
.comp-hint { visibility: hidden; font-size: 11px; color: var(--text-3); padding: 6px 4px 0; text-align: center; }
.comp-wrap:focus-within .comp-hint { visibility: visible; }

/* ---- modals and sheets ---- */
.modal { width: min(480px, 100%); max-height: calc(100vh - 32px); overflow: auto; display: flex; flex-direction: column; gap: 16px; padding: 24px; border-radius: var(--r-xl);
  background: color-mix(in srgb, var(--pop) 96%, transparent); border: 1px solid var(--line-2); box-shadow: 0 40px 120px -30px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); animation: pop .25s var(--ease) both; }
.modal-confirm { text-align: center; align-items: center; }
.modal-ic { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: color-mix(in srgb, var(--ai-c) 12%, transparent); color: var(--ai-1); }
.modal-ic .ic { width: 26px; height: 26px; }
.modal-t { margin: 0; font-size: 16px; line-height: 1.5; }
.modal-confirm .row { width: 100%; justify-content: center; }
.modal-edit { width: min(720px, 100%); }
.modal-h { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.modal-h .muted { margin-left: auto; font-weight: 400; font-size: 12px; }
.modal-edit .textarea { min-height: 240px; }
.sheet-h { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.sheet-t { font: 600 20px/1.25 var(--font-d); letter-spacing: -.02em; margin-bottom: 4px; }
.seg { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 4px; border-radius: var(--r); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); }
.seg-b { height: 36px; border: 0; border-radius: calc(var(--r-btn) - 1px); background: none; color: var(--text-2); cursor: pointer; font-weight: 500; }
.seg-b.on { background: var(--solid-bg); color: var(--solid-fg); }
.newlink { display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 14px; border-radius: var(--r); background: color-mix(in srgb, var(--ai-c4) 6%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c4) 30%, transparent); }
.newlink code { flex: 1; min-width: 0; font-size: 12.5px; overflow-wrap: anywhere; color: var(--ai-3); }
.links { display: flex; flex-direction: column; gap: 6px; }
.ln { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 12px; font-size: 13px; padding: 8px 10px; border-radius: var(--r-btn); background: var(--glass-2); }
.modal-looks { width: min(860px, 100%); }
.looks { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.look { display: flex; flex-direction: column; gap: 10px; padding: 10px; border-radius: 16px; border: 0; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); cursor: pointer; text-align: left; transition: transform .25s var(--ease), box-shadow .25s; }
.look:hover:not(:disabled) { transform: translateY(-4px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 45%, transparent), 0 30px 60px -30px color-mix(in srgb, var(--ai-c3) 60%, transparent); }
.look.current { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--ai-c2) 75%, transparent), var(--ai-glow); }
.look:disabled { cursor: default; opacity: .6; }
.look-frame { aspect-ratio: 4 / 5; display: grid; place-items: center; padding: 12px; border-radius: var(--r-btn); background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--ai-c) 12%, transparent), color-mix(in srgb, var(--fg-tint) 2%, transparent) 70%); }
.look-cover { position: relative; border-radius: 4px; overflow: hidden; background: #f4f1ea; container-type: size; box-shadow: 0 16px 40px -18px color-mix(in srgb, var(--shade) calc(80% * var(--shade-k)), transparent); }
.look-cover.wide { width: 100%; }
.look-cover.tall { height: 100%; }
.look-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.look-plain { aspect-ratio: .707; display: grid; place-items: center; color: #99a; }
.look-photo { position: absolute; background-size: cover; background-position: center; }
/* White under "difference" reads dark on a light cover and light on a dark one. */
.look-title { position: absolute; font: 600 min(7.2cqw, calc(var(--th, 12) * .45cqh))/1.1 Georgia, "Times New Roman", serif; color: #fff; mix-blend-mode: difference; overflow: hidden; }
.look-l { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-weight: 600; padding: 0 2px 2px; }

/* ---- the look: light, dark or the device's own ---- */
.theme-w { position: relative; display: inline-flex; }
.theme-menu { left: auto; right: 0; top: calc(100% + 8px); min-width: 180px; }
.menu-b.on { background: var(--glass-3); }
.menu-b.on::after { content: ""; margin-left: auto; width: 6px; height: 6px; border-radius: 50%; background: var(--ai-1); }

/* ---- sharing: a PDF, or a smartlink ---- */
.modal-share { width: min(960px, 100%); }
.opts { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.25fr); gap: 14px; align-items: start; }
.opt { display: flex; flex-direction: column; gap: 14px; padding: 18px; border-radius: var(--r-lg); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); }
.opt-link { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 35%, transparent), var(--ai-glow); }
.opt-h { display: flex; gap: 12px; align-items: flex-start; }
.opt-ic { width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: var(--r); background: var(--glass-3); color: var(--text); }
.opt-ic.ai { background: color-mix(in srgb, var(--ai-c) 16%, transparent); color: var(--ai-1); }
.opt-ic .ic { width: 20px; height: 20px; }
.opt-t { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font: 600 17px/1.3 var(--font-d); letter-spacing: -.01em; margin-bottom: 2px; }
.note-b { padding: 10px 12px; border-radius: var(--r); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); }
.link-field { display: flex; align-items: center; gap: 10px; padding: 6px 6px 6px 12px; border-radius: var(--r); background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.link-field > .ic { color: var(--ai-1); }
.link-field code { flex: 1; min-width: 0; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-2); }
.msg-in { min-height: 64px; resize: vertical; font-size: 13.5px; }
.share-g { display: flex; flex-direction: column; gap: 8px; }
.share-row { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-b { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px 0 12px; border: 0; border-radius: var(--r-btn); background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--text); cursor: pointer; font-size: 13.5px; font-weight: 500;
  transition: transform .15s var(--ease), box-shadow .2s; }
.sh-b:hover { transform: translateY(-1px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 60%, transparent), 0 10px 24px -14px color-mix(in srgb, var(--shade) calc(60% * var(--shade-k)), transparent); }
.sh-b .ic, .ch-stat .ic { width: 18px; height: 18px; }
.ch-wa .ic { color: #25d366; }
.ch-tg .ic { color: #229ed9; }
.ch-li .ic { color: #0a66c2; }
.ch-fb .ic { color: #1877f2; }
.client-note { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px; border-radius: var(--r); font-size: 12.5px; color: var(--text-2);
  background: color-mix(in srgb, var(--warn) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 24%, transparent); }
.stats-b { display: flex; flex-direction: column; gap: 8px; }
.stats-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.stat-n { font-weight: 600; font-size: 13px; }
.ch-stat { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px 0 8px; border-radius: 999px; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); font-size: 12px; color: var(--text-2); }
.ch-stat .ic { width: 14px; height: 14px; }
.ch-stat b { color: var(--text); font-weight: 700; }
.link-foot { align-items: center; }
.link-foot .grow { flex: 1; }
.earlier { display: flex; flex-direction: column; gap: 8px; }
.earlier .ln { grid-template-columns: auto 1fr auto; align-items: start; }
@media (max-width: 760px) { .opts { grid-template-columns: 1fr; } }

/* ---- the QR code: always dark on white, whatever the theme, so every phone camera reads it ---- */
.qr-box { display: flex; gap: 14px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--glass-2); }
.qr-img { width: 132px; height: 132px; flex: none; background: #ffffff; border-radius: var(--r-sm); display: grid; place-items: center; }
.qr-img img { width: 132px; height: 132px; display: block; border-radius: var(--r-sm); }
.qr-side { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; min-width: 0; }

/* ---- a link's activity timeline ---- */
.activity { display: flex; flex-direction: column; gap: 2px; max-height: 180px; overflow: auto; }
.activity:empty { display: none; }
.act-row { display: grid; grid-template-columns: minmax(130px, auto) 1fr auto; gap: 10px; font-size: 12px; padding: 4px 6px; border-radius: var(--r-sm); }
.act-row:nth-child(odd) { background: var(--glass-2); }
.act-t { font-variant-numeric: tabular-nums; color: var(--text-2); }

/* ---- toast, celebration, skeletons ---- */
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 70; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; display: inline-flex; align-items: center; gap: 10px;
  max-width: min(560px, calc(100% - 32px)); padding: 12px 16px; border-radius: calc(var(--r) + 2px); font-size: 13.5px; background: color-mix(in srgb, var(--pop) 95%, transparent); border: 1px solid var(--line-2); box-shadow: 0 20px 60px -20px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); transition: transform .3s var(--ease), opacity .3s; }
.toast.on { transform: translate(-50%, 0); opacity: 1; }
.toast .ic { color: var(--bad); }
.toast.ok .ic { color: var(--ok); }
.celebrate { position: fixed; inset: 0; z-index: 80; pointer-events: none; display: grid; place-items: center; }
.celebrate .ring { width: 108px; height: 108px; border-radius: 50%; display: grid; place-items: center; color: var(--ai-fg); background: var(--ai); box-shadow: 0 0 80px color-mix(in srgb, var(--ai-c) 80%, transparent); animation: ringIn 1.5s var(--ease) both; }
.celebrate .ring .ic { width: 52px; height: 52px; }
@keyframes ringIn { 0% { transform: scale(.4); opacity: 0; } 25% { transform: scale(1.08); opacity: 1; } 70% { transform: scale(1); opacity: 1; } 100% { transform: scale(.96); opacity: 0; } }
.spark-p { position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; border-radius: 2px; background: var(--c); animation: burst 1.2s var(--ease) both; }
@keyframes burst { 0% { transform: translate(-50%, -50%) scale(.4); opacity: 1; } 100% { transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) rotate(220deg) scale(1); opacity: 0; } }
.skel-stack { display: flex; flex-direction: column; gap: 10px; }
.skeleton.line { height: 14px; } .skeleton.line.s { width: 60%; } .skeleton.block { height: 120px; }
.dots { display: inline-flex; gap: 4px; } .dots i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: blink 1.2s infinite; } .dots i + i { animation-delay: .2s; } .dots i + i + i { animation-delay: .4s; }

::view-transition-old(root), ::view-transition-new(root) { animation-duration: .35s; }

/* ---- narrower screens ---- */
@media (max-width: 1360px) { .studio { --rail-w: 152px; --panel-w: 360px; } }
@media (max-width: 1100px) { .studio { --rail-w: 120px; --panel-w: 330px; } }
/* The pages list shows only its numbers and thumbnails once it is narrow, wherever the viewport is (the screen sets data-rail from its width). */
.studio[data-rail="compact"] .rail-l, .studio[data-rail="compact"] .rail-m, .studio[data-rail="compact"] .flag { display: none; }
.studio[data-rail="compact"] .rail-b { justify-content: center; }
@media (max-width: 860px) {
  .hide-s { display: none; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .bar { padding: 0 10px; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* whose full-size photos the brochure prints */
.photo-row { display: flex; align-items: center; gap: 8px; color: var(--text-2); }
.photo-row .ic { width: 15px; height: 15px; }
.select { height: 30px; border: 0; border-radius: 9px; padding: 0 10px; color: var(--text); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); font: inherit; font-size: 12.5px; min-width: 0; }
.photo-row .select { flex: 1; }
.select.wide { width: 100%; height: 36px; }
.select option { background: #12141d; color: var(--text); }
.ask-photos { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--r-lg); background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }


/* ---- 2026 look (owner, 2026-10-04): flat, quiet, no gradients, no violet, no spheres ---- */
body::before { content: none; display: none; }
.orb, .orb.xl, .orb.sm, .brief .orb { width: auto; height: auto; background: none; box-shadow: none; border-radius: 0; display: inline-grid; place-items: center; color: var(--ai); animation: none; }
.orb i { display: none; }
.orb .ic { width: 18px; height: 18px; }
.orb.sm .ic { width: 15px; height: 15px; }
.orb.xl .ic { width: 34px; height: 34px; }
.brief .orb .ic { width: 22px; height: 22px; }
.orb.live .ic { animation: markPulse 1.6s ease-in-out infinite; }
@keyframes markPulse { 50% { opacity: .35; } }
.brand-logo { height: 26px; width: auto; display: block; }
:root[data-theme="dark"] .brand-logo.ink, :root:not([data-theme]) .brand-logo.ink { filter: invert(1); }
@media (prefers-color-scheme: dark) { :root[data-theme="system"] .brand-logo.ink { filter: invert(1); } }
.brand-name { font: 650 15px/1 var(--font-d); letter-spacing: -.01em; }
.brand-sub { font-size: 13px; color: var(--text-2); font-weight: 500; }
.grad-t { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: var(--text); }
.card-b { background: var(--bg-3); }
.card-b::after { content: none; }
.btn-ai { background: var(--ai); background-size: auto; color: var(--ai-fg); box-shadow: none; }
.btn-ai:hover:not(:disabled) { background: var(--ai); filter: brightness(1.08); box-shadow: none; }
.btn-ai .ic svg path { fill: currentColor !important; }
.badge-ai, .stat, .tag.ai, .msg.sys { background: color-mix(in srgb, var(--ai) 10%, transparent); box-shadow: none; }
.prop-card { background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.prop-card::before { content: none; }
.composer { box-shadow: inset 0 0 0 1px var(--line-2); }
.composer::before { content: none; }
.composer.focus { box-shadow: inset 0 0 0 1px var(--ai); }
.composer.thinking { box-shadow: inset 0 0 0 1px var(--ai); animation: markPulse 1.6s ease-in-out infinite; }
.palette, .theatre, .tb, .sweep-pill { box-shadow: 0 24px 60px -24px rgba(0, 0, 0, .45), inset 0 0 0 1px var(--line-2); }
.stage { background: var(--bg-2); }
.panel { background: var(--bg); backdrop-filter: none; }
.look-frame { background: var(--bg-2); }
.look.current { box-shadow: inset 0 0 0 2px var(--ai); }
.logo-drop { background: none; border-color: var(--line-2); color: var(--text-2); }
.logo-drop:hover:not(:disabled), .logo-drop.over { border-color: var(--ai); background: none; }
.skeleton, .ghost-page i { background: var(--glass-3); animation: markPulse 1.6s ease-in-out infinite; }
.shimmer-t { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: var(--text-2); animation: markPulse 1.6s ease-in-out infinite; }
.sweep-bar { top: 0; height: 2px; background: var(--ai); animation: sweepLine 1.4s ease-in-out infinite; transform-origin: left; }
@keyframes sweepLine { 0% { transform: scaleX(0); opacity: 1; } 80% { transform: scaleX(1); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }
.st-bar i { background: var(--ai); }
.celebrate .ring { background: var(--ai); color: var(--ai-fg); box-shadow: none; }
.spark-p { display: none; }

/* Phone: the bar keeps the mark, the home and the actions; the theme toggle moves out of the way, and the panel
   leaves room under its last line for the prompt (Fable's review, 2026-10-04: toggle over the status, prompt over the
   figures). */
@media (max-width: 480px) {
  .bar .brand-sub, .bar .brand .orb { display: none; }
}

/* the fact check as evidence; the share card once approved; who a brochure is for */
.stat-b { border: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; font: inherit; font-size: 11.5px; color: var(--text); }
.stat-b .ic { width: 12px; height: 12px; color: var(--ok); }
.stat-b:hover { box-shadow: inset 0 0 0 1px var(--ai); }
.modal-facts { width: min(680px, 100%); }
.fact-row { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); }
.fact-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.fact-n { font-weight: 600; }
.fact-figs { display: flex; flex-wrap: wrap; gap: 6px; }
.fig { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 12px; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); font-variant-numeric: tabular-nums; }
.fig .ic { width: 11px; height: 11px; color: var(--ok); }
.share-card { display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: var(--r-lg); background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.share-card .btn { align-self: flex-start; }
.card-b .for { font-size: 13px; color: var(--text); font-weight: 500; }

/* The page list's photo group and the panel's design row (team feedback, 2026-10-05). */
.rail-chev { margin-left: auto; color: var(--text-3); transform: rotate(-90deg); transition: transform .2s var(--ease); }
.rail-group.open .rail-chev { transform: none; }
.rail-sub { margin-left: 14px; }
.design-n { font-size: 11px; line-height: 1.25; color: var(--text-2); }

/* ---- "What they read": the reading-time timeline in the share sheet ---- */
.reading { display: flex; flex-direction: column; gap: 10px; padding-top: 4px; }
.sw-row { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; cursor: pointer; width: fit-content; }
.sw { position: relative; width: 36px; height: 20px; flex: none; border: 0; border-radius: 999px; cursor: pointer; background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--line-2); transition: background-color .2s; }
.sw .sw-k { position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--text-2); transition: transform .2s var(--ease), background-color .2s; }
.sw.on { background: var(--ai); }
.sw.on .sw-k { transform: translateX(16px); background: var(--ai-fg); }
.sw:disabled { opacity: .45; cursor: default; }
.sw:focus-visible { outline: 2px solid var(--ai-c); outline-offset: 2px; }
.read-line { font-size: 13.5px; font-weight: 600; }
.read-strip { display: flex; gap: 4px; overflow-x: auto; padding: 2px 0 6px; }
.read-tile { flex: none; width: 46px; height: 62px; border-radius: var(--r-sm); display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 6px 2px; font-size: 11px; font-variant-numeric: tabular-nums;
  color: var(--text-2); background: color-mix(in srgb, var(--ai-c) var(--lvl, 0%), var(--glass-2)); box-shadow: inset 0 0 0 1px var(--line); }
.read-tile.read { color: var(--text); }
.read-n { font-weight: 600; font-size: 13px; }
.read-d { font-size: 10px; line-height: 1.1; text-align: center; }
.read-visits { display: flex; flex-direction: column; gap: 2px; max-height: 180px; overflow: auto; }
.read-row { display: grid; grid-template-columns: minmax(130px, auto) 1fr auto; gap: 10px; font-size: 12px; padding: 4px 6px; border-radius: var(--r-sm); }
.read-row:nth-child(odd) { background: var(--glass-2); }
@media (max-width: 560px) { .read-row { grid-template-columns: 1fr auto; } .read-row .muted { grid-column: 1 / -1; grid-row: 2; } }

/* ---- The agency's own design (2026-10-07, WP24): its page list, the canvas modes, the boxes, the chooser and the questions. ---- */
.row.spread { justify-content: space-between; }
.rail-draft { gap: 6px; }
.rail-d .rail-b { align-items: flex-start; gap: 8px; padding: 6px; }
.rail-d.on .rail-b { background: var(--glass-2); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 40%, transparent); }
.dthumb { position: relative; flex: none; width: 58px; aspect-ratio: .707; border-radius: 6px; overflow: hidden; background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.dthumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.dthumb .skeleton { position: absolute; inset: 0; }
.dthumb .rail-n { position: absolute; left: 3px; top: 3px; width: auto; min-width: 18px; height: 18px; padding: 0 4px; font-size: 10px; background: color-mix(in srgb, var(--bg) 82%, transparent); }
.rail-d .rail-t { flex: 1; gap: 4px; padding-top: 2px; min-width: 0; }
.rail-d .rail-b { padding: 6px 6px 6px 6px; }
.rail-d .rail-l { font-weight: 600; color: var(--text); }
.badge { display: inline-flex; align-items: flex-start; gap: 4px; width: fit-content; max-width: 100%; padding: 2px 6px; border-radius: 7px; font-size: 10px; font-weight: 600; line-height: 1.25; white-space: normal; }
.badge .ic { width: 11px; height: 11px; flex: none; margin-top: 1px; }
.b-filled { color: var(--ai-1); background: color-mix(in srgb, var(--ai-c) 14%, transparent); }
.b-kept { color: var(--text-2); background: var(--glass-3); }
.b-left { color: var(--warn); background: color-mix(in srgb, var(--warn) 12%, transparent); }
.b-added { color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, transparent); }
.rail-d.dropped .dthumb img { opacity: .45; filter: grayscale(1); }
.rail-d.dropped .rail-l { text-decoration: none; color: var(--text-2); }
.rail-d .rail-why { color: var(--text-3); }
.studio[data-rail="compact"] .rail-d .rail-t, .studio[data-rail="compact"] .rail-d .rail-m { display: none; }
.studio[data-rail="compact"] .dthumb { width: 44px; }

.canvas-bar { position: absolute; z-index: 6; left: 0; right: 0; top: 0; display: none; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 16px; padding: 10px 14px 8px; background: color-mix(in srgb, var(--bg-2) 94%, transparent); border-bottom: 1px solid var(--line); backdrop-filter: blur(8px); }
.canvas-bar.on { display: flex; }
.canvas-bar .seg { grid-template-columns: repeat(3, auto); gap: 2px; padding: 3px; }
.canvas-bar .seg-b { height: 28px; padding: 0 12px; font-size: 12.5px; }
.cb-note { flex-basis: 100%; text-align: center; font-size: 11.5px; line-height: 1.4; color: var(--text-3); }
.stage-scroll.has-bar { padding-top: 96px; }
.orig-col { display: none; }
.stage-scroll.mode-original .orig-col, .stage-scroll.mode-split .orig-col { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.stage-scroll.mode-original .preview-sizer { display: none; }
.stage-scroll.mode-split { display: grid; grid-template-columns: auto auto; justify-content: center; align-items: start; column-gap: 16px; }
.stage-scroll.mode-split .preview-sizer { margin: 0; }
.stage-scroll.mode-split .orig-col { gap: 0; align-items: flex-start; }
.orig-fig { position: relative; margin: 0; }
.stage-scroll.mode-original .orig-fig { width: min(680px, 100%); }
.orig-fig img { display: block; width: 100%; height: auto; border-radius: 2px; background: #fff; box-shadow: 0 18px 50px -22px rgba(15, 17, 26, .45), 0 0 0 1px var(--line-2); }
.orig-wait { width: 100%; aspect-ratio: .707; border-radius: 2px; }
.orig-cap { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 12px; color: var(--text-2); }
.orig-cap.out { color: var(--warn); }
.orig-cap:empty { display: none; }

.choose { position: absolute; pointer-events: auto; z-index: 8; min-width: 220px; max-width: 320px; padding: 6px; display: flex; flex-direction: column; gap: 2px; border-radius: var(--r); background: var(--pop); border: 1px solid var(--line-2); box-shadow: 0 20px 50px -16px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); animation: pop .18s var(--ease) both; }
.choose-t { padding: 6px 8px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.choose-o { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; border: 0; border-radius: 8px; background: none; color: var(--text); cursor: pointer; font-size: 13px; text-align: left; }
.choose-o:hover:not(:disabled) { background: var(--glass-3); }
.choose-o:disabled { cursor: default; opacity: 1; }
.choose-o.current { color: var(--ai-1); font-weight: 600; }
.choose-o.danger { color: var(--bad); }
.choose-sep { height: 1px; margin: 4px 2px; background: var(--line); }

.look.add .look-frame, .look.prep .look-frame { display: grid; place-items: center; aspect-ratio: 4 / 5; padding: 0; border-radius: 8px; border: 1.5px dashed var(--line-2); background: none; }
.look.add:hover .look-frame, .look.add.over .look-frame { border-color: var(--ai); }
.add-i { font-size: 26px; line-height: 1; color: var(--ai-1); }
.prep-i { display: grid; place-items: center; }
.prep-i .pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--ai-1); animation: blink 1s ease-in-out infinite; }
.prep-i .ic { width: 18px; height: 18px; color: var(--ok); }
.look.prep.bad .prep-i .ic { color: var(--bad); }
.design-s { font-size: 10.5px; line-height: 1.25; color: var(--ai-1); }
.look.prep.bad .design-s { color: var(--bad); }

.own-drop { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 1.5px dashed var(--line-2); border-radius: var(--r); background: none; color: var(--text); cursor: pointer; text-align: left; }
.own-drop:hover, .own-drop.over { border-color: var(--ai); background: color-mix(in srgb, var(--ai-c) 6%, transparent); }
.own-drop .ic { flex: none; width: 20px; height: 20px; color: var(--ai-1); }
.own-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.own-n { font-weight: 600; font-size: 13px; }
.panel.dropping { outline: 2px dashed var(--ai); outline-offset: -6px; }

.points { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: calc(var(--r) + 2px); background: color-mix(in srgb, var(--ai-c) 6%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 28%, transparent); }
.points .issues-h { color: var(--ai-1); }
.point { display: flex; flex-direction: column; gap: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.point .issue-w { color: var(--text); font-size: 13px; }
.ask-ctx { display: none; padding: 0 2px 6px; }
.ask-ctx.on { display: flex; }
.ask-x { display: inline-flex; margin-left: 4px; padding: 0; border: 0; background: none; color: inherit; cursor: pointer; }
.ask-x .ic { width: 12px; height: 12px; }
.msg.sys.warn { color: var(--warn); background: color-mix(in srgb, var(--warn) 9%, transparent); }
.chip.on { background: color-mix(in srgb, var(--ai-c) 14%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai-c2) 55%, transparent); }

/* the reading strip as the pages themselves: the contact sheet behind numbered, time-shaded tiles */
.read-strip.thumbs { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; overflow: visible; padding: 0 0 4px; }
.read-strip.thumbs .read-sheet { position: absolute; inset: 0 0 4px 0; width: 100%; height: calc(100% - 4px); border: 0; background: transparent; pointer-events: none; z-index: 0; }
.read-strip.thumbs .read-tile { position: relative; z-index: 1; flex: none; width: auto; height: auto; aspect-ratio: var(--tile-ar, 1.414 / 1); padding: 3px; background: color-mix(in srgb, var(--ai-c) calc(var(--lvl, 0%) * .6), transparent); box-shadow: inset 0 0 0 1px var(--line-2); }
.read-strip.thumbs .read-n, .read-strip.thumbs .read-d { padding: 0 4px; border-radius: 5px; background: color-mix(in srgb, var(--bg) 82%, transparent); }
.read-strip.thumbs .read-n { font-size: 10px; }


/* ---- the screen's layout (WP37, owner feedback 2026-10-08): resizable panes, a slim bar, folding details, fewer suggestions ----
   Dividers sit in their own 12px tracks (generous space between the panes, never cramped) and carry a dotted grip that is
   always visible, so it is plain they can be dragged. app.client.js drives them (pointer, arrow keys, double-click to reset). */
.split { position: relative; z-index: 3; display: grid; place-items: center; touch-action: none; outline: none; -webkit-user-select: none; user-select: none; }
.split::before { content: ""; position: absolute; background: var(--line); transition: background-color .15s; }
.split.v { cursor: col-resize; }
.split.v::before { top: 0; bottom: 0; left: 50%; width: 1px; transform: translateX(-50%); }
.split .grip { position: relative; display: block; border-radius: 999px; background-color: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); transition: box-shadow .15s; }
.split.v .grip { width: 10px; height: 34px;
  background-image: radial-gradient(circle at 50% 50%, var(--text-2) 1.2px, transparent 1.6px), radial-gradient(circle at 50% 50%, var(--text-2) 1.2px, transparent 1.6px), radial-gradient(circle at 50% 50%, var(--text-2) 1.2px, transparent 1.6px);
  background-size: 100% 8px, 100% 8px, 100% 8px; background-position: 0 3px, 0 13px, 0 23px; background-repeat: no-repeat; }
.split:hover::before, .split.drag::before, .split:focus-visible::before { background: var(--ai); }
.split.v:hover::before, .split.v.drag::before, .split.v:focus-visible::before { width: 2px; }
.split:hover .grip, .split.drag .grip { box-shadow: inset 0 0 0 1px var(--ai); }
.split:focus-visible .grip { box-shadow: inset 0 0 0 2px var(--ai); }
html.resizing, html.resizing * { -webkit-user-select: none !important; user-select: none !important; }
html.resizing-v, html.resizing-v * { cursor: col-resize !important; }
html.resizing iframe { pointer-events: none; }

/* the suggestions: one row of three, the rest behind "More" */
.chips .chip { flex: 0 1 auto; min-width: 96px; max-width: min(220px, 100%); }
.chips.open .chip { flex: none; min-width: 0; max-width: 100%; }
.chip-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chip-more { flex: none; color: var(--text-2); }
.chip-more .ic { transition: transform .2s var(--ease); transform: none; }
.chip-more[aria-expanded="true"] .ic { transform: rotate(180deg); }
.chips.open { flex-wrap: wrap; overflow-x: hidden; overflow-y: auto; max-height: 34vh; }


/* ---- WP41 (2026-10-09, after Fable's strict review): pages left as thumbnails, the brochure in the middle, one line of settings, one
   task and the conversation on the right; Approve the one accent button and Share beside it; the bar's other controls in one menu.
   Generous room between blocks (owner, 2026-10-08): 24px inside the assistant's column, 20px between pages in the rail. ---- */

/* the top bar */
.bar { --bar-pad: 16px; gap: 12px; }
.brand-w { position: relative; display: inline-flex; }
.brand .brand-chev { width: 14px; height: 14px; color: var(--text-3); margin-left: -4px; }
.menu { background: var(--pop); border: 1px solid var(--line-2); }
.bar-menu { left: 0; top: calc(100% + 8px); min-width: 240px; z-index: 60; }
.bar-menu.right { left: auto; right: 0; }
.menu-sep { height: 1px; margin: 6px 4px; background: var(--line); }
.menu-h { padding: 8px 10px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.bar-back, .bar-more { display: none; }
.pill-b { border: 0; cursor: pointer; font-family: inherit; }
.pill-b:hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }
.pill-b.st-needs_edit { color: var(--warn); }
.bar-share, .bar-approve { flex: none; }

/* the pages: thumbnails of the printed pages, numbered as the PDF numbers them */
/* Above the dividers, so a page's menu or "Add page" is never crossed by a divider's grip. */
.rail-pages, .rail-draft { position: relative; z-index: 4; }
.rail-pages { padding: 16px 16px 0; display: flex; flex-direction: column; }
.rail-head { display: none; }
.rail-wrap { position: relative; flex: none; }
/* Laid out even while hidden: its pages are measured before the first thumbnail shows. */
.rail-sheet { position: absolute; left: 0; top: 0; z-index: 0; width: 100%; height: 100%; border: 0; pointer-events: none; background: transparent; color-scheme: light; visibility: hidden; }
.rail.thumbs .rail-sheet { visibility: visible; }
.rail-draft .rail-sheet { display: none; }
.rail-list { position: relative; display: flex; flex-direction: column; gap: 20px; }
.rail-pages .rail-i { flex-direction: column; align-items: stretch; background: none; border-radius: var(--r-sm); }
.rail-pages .rail-i:hover, .rail-pages .rail-i.is-open { background: none; }
.rail-pages .rail-b { flex-direction: column; align-items: stretch; gap: 8px; padding: 0; border-radius: var(--r-sm); }
.rthumb { position: relative; display: block; width: 100%; aspect-ratio: 210 / 297; border-radius: 3px; background: var(--glass-2); box-shadow: 0 0 0 1px var(--line); transition: box-shadow .15s; }
.rthumb.filled { aspect-ratio: auto; background: transparent; }
/* A page's stored picture (WP42): the box keeps the picture's own proportions from the start, so loading it as the row scrolls into view moves nothing. */
.rthumb.has-img { background: var(--glass-2); overflow: hidden; }
.rthumb-img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.rail-pages .rail-i:hover .rthumb { box-shadow: 0 0 0 1px var(--line-2), 0 10px 28px -16px color-mix(in srgb, var(--shade) calc(80% * var(--shade-k)), transparent); }
.rail-pages .rail-i.on .rthumb { box-shadow: 0 0 0 2px var(--text-2); }
.rthumb .rail-n { position: absolute; left: 6px; top: 6px; width: auto; min-width: 22px; height: 22px; padding: 0 6px; background: color-mix(in srgb, var(--bg) 86%, transparent); }
.rthumb .flag { position: absolute; left: 24px; top: 4px; margin: 0; }
.rail-hid { position: absolute; right: 6px; bottom: 6px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 6px; color: var(--text-2); background: color-mix(in srgb, var(--bg) 86%, transparent); }
.rail-hid .ic { width: 13px; height: 13px; }
.rail-pages .rail-l { font-size: 12px; line-height: 16px; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--text-2); }
.rail-pages .rail-i.on .rail-l { color: var(--text); font-weight: 600; }
.rail-pages .rail-m { position: absolute; right: 6px; top: 6px; margin: 0; background: color-mix(in srgb, var(--bg) 86%, transparent); color: var(--text); }
.rail-pages .rail-i[draggable="true"] .rail-b { cursor: grab; }
.rail-i.dragging { opacity: .45; }
.rail-i.drop-before::before, .rail-i.drop-after::after { content: ""; position: absolute; left: 0; right: 0; height: 2px; border-radius: 2px; background: var(--ai); }
.rail-i.drop-before::before { top: -11px; }
.rail-i.drop-after::after { bottom: -11px; }
.rail-foot { position: sticky; bottom: 0; z-index: 2; margin-top: auto; padding: 16px 0; background: var(--bg); }
.rail-foot:empty { display: none; }
.rail-add { width: 100%; height: 36px; display: flex; align-items: center; gap: 8px; padding: 0 10px; border: 1px dashed var(--line-2); border-radius: var(--r); background: none; color: var(--text-2); cursor: pointer; font-size: 12.5px; }
.rail-add:hover, .rail-add[aria-expanded="true"] { color: var(--text); border-color: var(--text-3); }
.rail-add .ic { width: 14px; height: 14px; }
.rail-pop, .add-pop { position: fixed; left: 0; top: 0; z-index: 60; min-width: 0; max-height: min(70vh, 520px); overflow: auto; }
.rail .add-pop .rail-i { display: flex; flex-direction: row; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 8px; }
.rail .add-pop .rail-i.dropped .rail-l { text-decoration: none; }
.add-pop .rail-i:hover { background: var(--glass-2); }
.add-pop .rail-t { flex: 1; min-width: 0; gap: 2px; }
.add-pop .rail-l { white-space: normal; color: var(--text); opacity: 1; }
.add-pop .rail-why { font-size: 11.5px; }
.studio[data-rail="compact"] .rail-pages { padding: 12px 8px 0; }
.studio[data-rail="compact"] .rail-add span, .studio[data-rail="compact"] .rail-hid { display: none; }
.studio[data-rail="compact"] .rail-add { justify-content: center; padding: 0; }
.studio[data-rail="compact"] .rthumb .rail-n { left: 3px; top: 3px; min-width: 18px; height: 18px; padding: 0 4px; font-size: 10px; }
.pages-pill { display: none; }

/* the dividers stay (WP37): a hairline with a quieter grip that comes forward on hover */
.split .grip { opacity: .6; transition: opacity .15s, box-shadow .15s; }
.split:hover .grip, .split.drag .grip, .split:focus-visible .grip { opacity: 1; }

/* the assistant's column: the settings line, then one scrolling region */
.panel-strip, .panel-close { display: none; }
.setup { flex: none; position: relative; z-index: 5; padding: 20px 24px 16px; border-bottom: 1px solid var(--line); }
.set-row { display: flex; flex-wrap: wrap; gap: 8px; }
.setup .pop-w { position: static; display: inline-flex; max-width: 100%; }
.set-b { display: inline-flex; align-items: center; gap: 6px; height: 32px; min-width: 0; max-width: 100%; padding: 0 12px 0 10px; border: 0; border-radius: 999px; background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--text); font-size: 12.5px; cursor: pointer; transition: box-shadow .15s, background-color .15s; }
.set-b:hover:not(:disabled) { background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.set-b[aria-expanded="true"] { box-shadow: inset 0 0 0 1px var(--text-2); }
.set-b:disabled { cursor: default; opacity: .6; }
.set-b > .ic { width: 14px; height: 14px; color: var(--text-2); }
.set-b.missing { color: var(--text-2); }
.set-t { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.set-b .ag-logo { width: 20px; height: 20px; border-radius: 5px; padding: 1px; font-size: 11px; }
.set-b .ag-logo.empty { color: var(--text-2); }
.set-b .ag-logo.empty .ic { width: 12px; height: 12px; }
.pop { position: absolute; z-index: 40; left: 16px; right: 16px; top: calc(100% - 4px); display: flex; flex-direction: column; gap: 14px; padding: 16px; border-radius: var(--r-lg); background: var(--pop); border: 1px solid var(--line-2); box-shadow: 0 24px 60px -20px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); animation: pop .18s var(--ease) both; }
.pop-foot { display: flex; flex-direction: column; gap: 10px; }
.lang-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.lang-b { height: 34px; padding: 0 12px; border: 0; border-radius: var(--r-btn); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--text-2); cursor: pointer; text-align: left; font-size: 13px; }
.lang-b:hover { color: var(--text); }
.lang-b.on { color: var(--text); background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--text-2); }
.lang-b.current { font-weight: 600; }
.panel-body { padding: 24px; gap: 24px; }
.panel .comp-wrap { padding: 16px 24px 24px; }
.panel .chips { padding: 16px 24px 0; flex-wrap: wrap; overflow: visible; }
.panel .chips .chip { min-width: 0; max-width: 100%; flex: 0 1 auto; }
.panel .chips .chip-t { overflow: visible; text-overflow: clip; }

/* one task at a time: the issue, or the question the brochure asks once */
.task { scroll-margin-top: 8px; }
.task-issue { display: flex; flex-direction: column; gap: 10px; padding: 16px; margin-bottom: 12px; border-radius: 12px; cursor: pointer; background: color-mix(in srgb, var(--warn) 5%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ai) 70%, transparent); }
.task-h { display: flex; align-items: center; gap: 8px; min-width: 0; }
.task-h > .ic { color: var(--warn); }
.task-h .count { margin-left: auto; background: color-mix(in srgb, var(--warn) 14%, transparent); color: var(--warn); }
.task-nav { margin-left: auto; display: flex; align-items: center; gap: 2px; flex: none; }
.task-nav .count { margin-left: 0; font-variant-numeric: tabular-nums; }
.task-nav .btn-icon { width: 26px; height: 26px; }
.task-nav .btn-icon .ic { width: 14px; height: 14px; }
.lnk { padding: 0; border: 0; background: none; color: var(--text-2); font: inherit; font-size: 12.5px; cursor: pointer; text-align: left; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.lnk:hover { color: var(--text); text-decoration-color: currentColor; }
.task-w { min-width: 0; color: var(--text); font-size: 13px; font-weight: 600; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-q { margin: 0; padding-left: 12px; border-left: 2px solid var(--line-2); font: 13.5px/1.5 Georgia, "Times New Roman", serif; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.task-r { font-size: 12.5px; color: var(--text-2); }
.task-f { display: flex; flex-wrap: wrap; gap: 16px; }
.task-d { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; border-top: 1px solid var(--line); }
.task-issue.flash { animation: taskFlash 1.1s ease 2; }
@keyframes taskFlash { 50% { box-shadow: inset 0 0 0 2px var(--ai), 0 0 0 4px color-mix(in srgb, var(--ai) 22%, transparent); } }
.msg.task { padding: 16px; margin-bottom: 12px; border-radius: 12px; background: var(--bg-3); box-shadow: inset 0 0 0 1px var(--line-2); }
.msg.task .lnk { align-self: flex-start; }
.opt-list { display: flex; flex-wrap: wrap; gap: 8px; }
.msg.task .opt-list .btn.on { background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--text-2); }
.msg.task .row { margin-top: 10px; }
.modal-photos .opt-list { flex-direction: column; flex-wrap: nowrap; }
.opt-b { width: 100%; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 0; border-radius: var(--r); background: var(--glass-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--text); cursor: pointer; text-align: left; font-size: 13.5px; }
.opt-b.on { background: var(--glass-3); box-shadow: inset 0 0 0 1px var(--text-2); }
.fact-counts { font-size: 13px; font-weight: 600; }
.look.picked { box-shadow: inset 0 0 0 2px var(--text-2); }
.look.add .muted { line-height: 1.4; }
.modal-looks .pop-foot { padding-top: 4px; border-top: 1px solid var(--line); }

/* texts the person hid, marked on their page with a way to show them again */
.gh-host { z-index: 4; }
.ghost-p { position: absolute; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; pointer-events: auto; }
.ghost-s { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 4px 0 10px; border-radius: 999px; border: 1px dashed var(--line-2); background: color-mix(in srgb, var(--pop) 94%, transparent); color: var(--text-2); font-size: 12px; box-shadow: 0 8px 24px -12px color-mix(in srgb, var(--shade) calc(70% * var(--shade-k)), transparent); }
.ghost-s .ic { width: 14px; height: 14px; }

/* ---- the phone (WP41): the brochure takes the screen; the pages and the conversation are sheets from the bottom ---- */
@media (max-width: 860px) {
  body { overflow: hidden; }
  .studio { --dock-h: 116px; display: block; position: relative; height: 100%; }
  .split.v { display: none; }
  .stage { position: absolute; left: 0; right: 0; top: 0; bottom: var(--dock-h); height: auto; }
  .pages-pill { position: absolute; right: 16px; bottom: 16px; z-index: 7; display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border: 0; border-radius: 999px; cursor: pointer;
    background: color-mix(in srgb, var(--pop) 94%, transparent); color: var(--text); font: 600 13px/1 var(--font); font-variant-numeric: tabular-nums; box-shadow: 0 8px 24px -10px color-mix(in srgb, var(--shade) calc(80% * var(--shade-k)), transparent), inset 0 0 0 1px var(--line-2); }
  .pages-pill[hidden] { display: none; }
  .rail, .rail-pages, .rail-draft { position: fixed; left: 0; right: 0; bottom: 0; z-index: 46; display: flex; flex-direction: column; height: 70vh; padding: 0 16px; background: var(--pop); border-radius: 16px 16px 0 0;
    box-shadow: 0 -20px 60px -20px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); transform: translateY(105%); visibility: hidden; transition: transform .25s var(--ease), visibility 0s linear .25s; }
  .studio[data-pages="open"] .rail { transform: none; visibility: visible; transition: transform .25s var(--ease); }
  .rail-head { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; justify-content: space-between; padding: 12px 0 8px; background: var(--pop); font-weight: 600; }
  .rail-sheet { display: none !important; }
  .rail-list { gap: 2px; }
  .rail-pages .rail-i { flex-direction: row; align-items: center; }
  .rail-pages .rail-b { flex: 1; flex-direction: row; align-items: center; gap: 12px; padding: 10px 6px; }
  .rthumb { flex: none; width: auto; aspect-ratio: auto; background: none; box-shadow: none !important; }
  .rthumb .rail-n { position: static; }
  .rthumb .flag { left: auto; right: -6px; top: -2px; }
  .rail-hid { display: none; }
  .rail-pages .rail-l { font-size: 14px; -webkit-line-clamp: 1; }
  .rail-pages .rail-m { position: static; opacity: 1; background: none; }
  .rail-foot { background: var(--pop); }
  .panel { position: fixed; left: 0; right: 0; bottom: 0; z-index: 44; display: flex; flex-direction: column; background: var(--bg); border-top: 1px solid var(--line); }
  .panel-strip { flex: none; display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 16px; border: 0; background: none; color: var(--text); font-size: 13px; text-align: left; cursor: pointer; }
  .strip-t { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .strip-m { margin-left: auto; color: var(--text-2); white-space: nowrap; }
  .strip-ic.warn { color: var(--warn); }
  .strip-chev { transform: rotate(180deg); color: var(--text-3); }
  .studio[data-chat="closed"] .setup, .studio[data-chat="closed"] .panel-head, .studio[data-chat="closed"] .panel-body, .studio[data-chat="closed"] .chips { display: none; }
  .studio[data-chat="open"] .panel { height: 70vh; border-radius: 16px 16px 0 0; box-shadow: 0 -20px 60px -20px color-mix(in srgb, var(--shade) calc(90% * var(--shade-k)), transparent); }
  .studio[data-chat="open"] .panel-strip { display: none; }
  .studio[data-chat="open"] .panel-close { position: absolute; right: 8px; top: 10px; z-index: 6; display: grid; place-items: center; }
  .setup, .panel-head { padding: 16px 52px 12px 16px; }
  .panel-body { padding: 16px; gap: 16px; }
  .panel .chips { padding: 12px 16px 0; }
  .panel .comp-wrap { padding: 8px 16px 12px; }
  .bar.has-doc .brand-w { display: none; }
  .bar.has-doc .bar-back { display: grid; place-items: center; }
  .bar.has-doc .bar-more { display: inline-flex; position: relative; }
  .bar-share { display: none; }
  .bar-doc .sep { display: none; }
  .doc-t { max-width: none; min-width: 0; }
  .bar-doc { flex: 1; min-width: 0; }
  .bar .bar-spacer { display: none; }
}
@media (max-width: 560px) { .bar-doc .pill { display: none; } }

/* ---- Casafari Business Expansion (expansion.casafari.com), preset "expansion" (owner, 2026-10-14) ----
   The same look as expansion.casafari.com and its Claro app (casafari/premises, PR 65 and 66): confident, money,
   trust, calm enough to work in for hours. A soft paper stage (#f4f2ee) with cards a shade lighter, softer ink,
   one dusty violet accent (#6a5596) for the action and focus, gold (#85620f) only as the warning tone; the main
   action is solid violet like the site's buttons (the site's violet-to-gold gradient is for large text only). No
   glows, soft corners, pill buttons. Geist, served from this origin (/review/fonts/geist.woff2). Light is the host's
   look (sessions open in it); the dark block is a calm near-black violet for people who choose dark. Each block
   restates every key (CONTRACT). Scoped to data-host="expansion": the flat 2026 look stays every other host's. */
@font-face {
  font-family: "Geist";
  src: url("/review/fonts/geist.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root[data-host="expansion"] {
  color-scheme: dark;
  --font: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-d: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --r-btn: 999px;
  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
  --r-xl: 20px;
  --bg: #17151c;
  --bg-2: #1e1b25;
  --bg-3: #26222e;
  --pop: #26222e;
  --glass: rgba(30, 27, 37, .94);
  --glass-2: rgba(244, 240, 255, .035);
  --glass-3: rgba(244, 240, 255, .06);
  --line: rgba(240, 235, 255, .08);
  --line-2: rgba(240, 235, 255, .14);
  --fg-tint: #ffffff;
  --text: #f3f1f6;
  --text-2: #c6c1d1;
  --text-3: #938da2;
  --ai: #b4a3dc;
  --ai-fg: #1a1622;
  --ai-icon: #1a1622;
  --ai-c: #b4a3dc;
  --ai-c2: #b4a3dc;
  --ai-c3: #b4a3dc;
  --ai-c4: #b4a3dc;
  --ai-c5: #b4a3dc;
  --ai-c6: #b4a3dc;
  --ai-1: #b4a3dc;
  --ai-2: #b4a3dc;
  --ai-3: #b4a3dc;
  --ring-1: #b4a3dc;
  --ring-2: #b4a3dc;
  --ring-3: #b4a3dc;
  --ring-4: #b4a3dc;
  --orb-1: #b4a3dc;
  --orb-2: #b4a3dc;
  --orb-3: #b4a3dc;
  --orb-4: #b4a3dc;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #b4a3dc 30%, transparent);
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #b4a3dc;
  --solid-fg: #1a1622;
  --solid-hover: #a593d1;
  --focus: #b4a3dc;
  --title-a: #f3f1f6;
  --title-b: #c6c1d1;
  --shimmer-hi: #ffffff;
  --shade: #000000;
  --shade-k: 1;
  --scrim-c: #0b0a0e;
  --scrim-k: 1;
  --drop-c: #26222e;
  --ok: #5fd3a0;
  --warn: #e0b860;
  --bad: #f08a8a;
}
:root[data-host="expansion"][data-theme="light"] {
  color-scheme: light;
  --bg: #f4f2ee;
  --bg-2: #eeebe5;
  --bg-3: #fbfaf8;
  --pop: #fbfaf8;
  --glass: rgba(251, 250, 248, .92);
  --glass-2: rgba(36, 33, 43, .03);
  --glass-3: rgba(36, 33, 43, .055);
  --line: #e6e2da;
  --line-2: #dbd6cc;
  --fg-tint: #24212b;
  --text: #24212b;
  --text-2: #4f4b5c;
  --text-3: #6a6676;
  --ai: #6a5596;
  --ai-fg: #ffffff;
  --ai-icon: #ffffff;
  --ai-c: #6a5596;
  --ai-c2: #6a5596;
  --ai-c3: #6a5596;
  --ai-c4: #6a5596;
  --ai-c5: #6a5596;
  --ai-c6: #6a5596;
  --ai-1: #6a5596;
  --ai-2: #6a5596;
  --ai-3: #6a5596;
  --ring-1: #6a5596;
  --ring-2: #6a5596;
  --ring-3: #6a5596;
  --ring-4: #6a5596;
  --orb-1: #6a5596;
  --orb-2: #6a5596;
  --orb-3: #6a5596;
  --orb-4: #6a5596;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #6a5596 28%, transparent);
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #6a5596;
  --solid-fg: #ffffff;
  --solid-hover: #5c4985;
  --focus: #6a5596;
  --title-a: #24212b;
  --title-b: #4f4b5c;
  --shimmer-hi: #24212b;
  --shade: #24212b;
  --shade-k: .16;
  --scrim-c: #24212b;
  --scrim-k: .4;
  --drop-c: #eeebe5;
  --ok: #0b6b45;
  --warn: #85620f;
  --bad: #b01e2c;
}
@media (prefers-color-scheme: light) {
  :root[data-host="expansion"][data-theme="system"] {
  color-scheme: light;
  --bg: #f4f2ee;
  --bg-2: #eeebe5;
  --bg-3: #fbfaf8;
  --pop: #fbfaf8;
  --glass: rgba(251, 250, 248, .92);
  --glass-2: rgba(36, 33, 43, .03);
  --glass-3: rgba(36, 33, 43, .055);
  --line: #e6e2da;
  --line-2: #dbd6cc;
  --fg-tint: #24212b;
  --text: #24212b;
  --text-2: #4f4b5c;
  --text-3: #6a6676;
  --ai: #6a5596;
  --ai-fg: #ffffff;
  --ai-icon: #ffffff;
  --ai-c: #6a5596;
  --ai-c2: #6a5596;
  --ai-c3: #6a5596;
  --ai-c4: #6a5596;
  --ai-c5: #6a5596;
  --ai-c6: #6a5596;
  --ai-1: #6a5596;
  --ai-2: #6a5596;
  --ai-3: #6a5596;
  --ring-1: #6a5596;
  --ring-2: #6a5596;
  --ring-3: #6a5596;
  --ring-4: #6a5596;
  --orb-1: #6a5596;
  --orb-2: #6a5596;
  --orb-3: #6a5596;
  --orb-4: #6a5596;
  --ai-glow: 0 0 0 1px color-mix(in srgb, #6a5596 28%, transparent);
  --aurora-a: transparent;
  --aurora-b: transparent;
  --aurora-c: transparent;
  --solid-bg: #6a5596;
  --solid-fg: #ffffff;
  --solid-hover: #5c4985;
  --focus: #6a5596;
  --title-a: #24212b;
  --title-b: #4f4b5c;
  --shimmer-hi: #24212b;
  --shade: #24212b;
  --shade-k: .16;
  --scrim-c: #24212b;
  --scrim-k: .4;
  --drop-c: #eeebe5;
  --ok: #0b6b45;
  --warn: #85620f;
  --bad: #b01e2c;
}
}
/* The main action: solid violet, like expansion.casafari.com's buttons (white text 6.3:1); everything else one quiet accent. */
:root[data-host="expansion"] .btn-ai {
  background: var(--solid-bg);
  color: var(--solid-fg);
  box-shadow: none;
}
:root[data-host="expansion"] .btn-ai:hover:not(:disabled) {
  background: var(--solid-hover);
  filter: none;
  box-shadow: none;
}
