/* ORANO desk — the web companion surface.
   It intentionally shares the landing system's black / white / red language,
   but gives the desktop app enough hierarchy for work instead of marketing. */

:root {
  --ws-bg: #000;
  --ws-panel: #080808;
  --ws-panel-raised: #0d0d0d;
  --ws-line: #202020;
  --ws-line-strong: #303030;
  --ws-white: #f7f7f5;
  --ws-copy: #c9c9c5;
  --ws-muted: #888884;
  --ws-dim: #555550;
  --ws-red: #f04438;
  --ws-red-soft: rgba(240, 68, 56, .12);
  --ws-sidebar: 250px;
  --ws-radius: 12px;
  --ws-radius-small: 8px;
  --ws-shadow: 0 20px 70px rgba(0, 0, 0, .35);
}

html.workspace-page-html,
body.workspace-page {
  background: var(--ws-bg);
}

body.workspace-page {
  min-height: 100vh;
  color: var(--ws-white);
  overflow-x: hidden;
}

body.workspace-page button,
body.workspace-page input,
body.workspace-page select,
body.workspace-page textarea {
  font: inherit;
}

body.workspace-page input,
body.workspace-page select,
body.workspace-page textarea {
  color: var(--ws-white);
  background: var(--ws-panel);
  border: 1px solid var(--ws-line);
  border-radius: var(--ws-radius-small);
  outline: 0;
  transition: border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

body.workspace-page input:focus,
body.workspace-page select:focus,
body.workspace-page textarea:focus {
  border-color: var(--ws-red);
  box-shadow: 0 0 0 3px var(--ws-red-soft);
}

body.workspace-page input::placeholder,
body.workspace-page textarea::placeholder {
  color: var(--ws-dim);
}

body.workspace-page select {
  appearance: auto;
}

[hidden] { display: none !important; }

.ws-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.ws-boot {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  color: var(--ws-muted);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.ws-boot-mark {
  width: 56px;
  height: 56px;
  border: 1px solid var(--ws-line-strong);
  border-radius: 50%;
  display: grid;
  place-items: center;
  animation: ws-breathe 1.6s ease-in-out infinite;
}

.ws-boot-mark img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  filter: grayscale(1) brightness(3);
}

@keyframes ws-breathe {
  0%, 100% { opacity: .55; transform: scale(.96); }
  50% { opacity: 1; transform: scale(1); }
}

/* Auth gate */
.ws-auth-gate {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px 56px;
  position: relative;
  isolation: isolate;
}

.ws-auth-gate::before,
.ws-auth-gate::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 320px;
  height: 320px;
  border: 1px solid var(--ws-line);
  border-radius: 50%;
  pointer-events: none;
}

.ws-auth-gate::before { top: 10%; left: -210px; }
.ws-auth-gate::after { right: -215px; bottom: 8%; width: 430px; height: 430px; border-color: #171717; }

.ws-auth-brand,
.ws-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--ws-white);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .18em;
}

.ws-auth-brand {
  position: absolute;
  top: 28px;
  left: clamp(20px, 5vw, 64px);
}

.ws-auth-brand img,
.ws-brand img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  filter: grayscale(1) brightness(3);
}

.ws-auth-card {
  width: min(100%, 620px);
  border: 1px solid var(--ws-line);
  background: rgba(8, 8, 8, .92);
  padding: clamp(30px, 6vw, 66px);
  position: relative;
  overflow: hidden;
}

.ws-auth-card::after {
  content: "";
  position: absolute;
  right: -100px;
  top: 50%;
  width: 200px;
  height: 200px;
  border: 1px solid #181818;
  border-radius: 50%;
  pointer-events: none;
}

.ws-auth-orbit {
  width: 70px;
  height: 70px;
  border: 1px solid var(--ws-line-strong);
  border-radius: 50%;
  margin-bottom: 38px;
  position: relative;
}

.ws-auth-orbit::before,
.ws-auth-orbit::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid var(--ws-line);
  border-radius: 50%;
}

.ws-auth-orbit::after { inset: 25px; border-color: var(--ws-red); }
.ws-auth-orbit span { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: var(--ws-red); top: 8px; left: 50%; }
.ws-auth-orbit i { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: var(--ws-white); bottom: 16px; right: 11px; }
.ws-auth-orbit b { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--ws-muted); left: 10px; bottom: 20px; }

.ws-eyebrow,
.ws-kicker {
  color: var(--ws-muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  line-height: 1.35;
  text-transform: uppercase;
}

.ws-eyebrow em,
.ws-kicker em,
.ws-auth-card h1 em {
  color: var(--ws-red);
  font-style: normal;
}

.ws-auth-card h1 {
  margin-top: 16px;
  max-width: 520px;
  font-size: clamp(36px, 5.5vw, 68px);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: .98;
}

.ws-auth-copy {
  max-width: 480px;
  margin-top: 25px;
  color: var(--ws-copy);
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: -.015em;
}

.ws-auth-form {
  margin-top: 38px;
}

.ws-google-button {
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 30px;
  padding: 0 16px;
  border: 1px solid var(--ws-line-strong);
  border-radius: var(--ws-radius-small);
  background: var(--ws-panel);
  color: var(--ws-white);
  font-size: 12px;
  font-weight: 600;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.ws-google-button:hover {
  border-color: var(--ws-white);
  background: #111;
  transform: translateY(-1px);
}

.ws-google-button:active { transform: translateY(0); }
.ws-google-button:disabled { cursor: wait; opacity: .55; transform: none; }

.ws-google-mark {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ws-white);
  color: #4285f4;
  font-size: 13px;
  font-weight: 700;
}

.ws-auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 23px;
  color: var(--ws-dim);
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.ws-auth-divider::before,
.ws-auth-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--ws-line);
}

.ws-auth-form label,
.ws-save-form label,
.ws-key-form label,
.ws-filter-label {
  display: block;
  margin-bottom: 9px;
  color: var(--ws-muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.ws-input-action {
  display: flex;
  gap: 8px;
}

.ws-input-action input {
  min-width: 0;
  flex: 1;
  height: 52px;
  padding: 0 16px;
}

.ws-auth-footnote,
.ws-auth-back {
  color: var(--ws-dim);
  font-size: 12px;
  line-height: 1.5;
}

.ws-auth-footnote { margin-top: 14px; }
.ws-auth-back { margin-top: 22px; }
.ws-auth-back a:hover { color: var(--ws-white); }

/* App frame */
.ws-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--ws-sidebar) minmax(0, 1fr);
}

.ws-sidebar {
  min-height: 100vh;
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--ws-line);
  background: var(--ws-bg);
  z-index: 20;
}

.ws-sidebar-top { padding: 27px 18px 20px; }
.ws-brand { padding: 0 10px; }
.ws-brand img { width: 19px; height: 19px; }

.ws-account {
  display: grid;
  gap: 5px;
  margin: 47px 10px 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--ws-line);
}

.ws-account strong { font-size: 15px; font-weight: 600; letter-spacing: -.03em; }
.ws-account > span:last-child { overflow: hidden; color: var(--ws-dim); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }

.ws-nav { display: grid; gap: 4px; }

.ws-nav button,
.ws-sidebar-link {
  width: 100%;
  min-height: 43px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 10px;
  border: 1px solid transparent;
  color: var(--ws-muted);
  text-align: left;
  font-size: 13px;
  letter-spacing: -.01em;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.ws-nav button:hover,
.ws-nav button.is-active,
.ws-sidebar-link:hover { color: var(--ws-white); }

.ws-nav button.is-active {
  border-color: var(--ws-line);
  background: var(--ws-panel);
}

.ws-nav button.is-active .ws-nav-icon { color: var(--ws-red); }
.ws-nav-icon { width: 18px; color: var(--ws-dim); font-size: 18px; line-height: 1; text-align: center; }
.ws-nav kbd { margin-left: auto; color: var(--ws-dim); font-family: var(--font); font-size: 10px; }

.ws-sidebar-bottom { display: grid; gap: 8px; padding: 20px 18px 24px; }

.ws-mcp-indicator {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 8px;
  padding: 0 10px;
  border: 1px solid var(--ws-line);
  color: var(--ws-muted);
  font-size: 10px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.ws-mcp-indicator i,
.ws-status-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  display: inline-block;
  border-radius: 50%;
  background: var(--ws-dim);
}

.ws-mcp-indicator.is-ready i,
.ws-status-dot.is-ready { background: var(--ws-red); box-shadow: 0 0 0 4px var(--ws-red-soft); }
.ws-mcp-indicator.is-unavailable i { background: #b89552; }
.ws-sidebar-link { min-height: 32px; color: var(--ws-dim); font-size: 11px; }
.ws-sidebar-link span { margin-left: auto; font-size: 14px; }
.ws-signout { color: var(--ws-dim); }

.ws-content-shell { min-width: 0; }

.ws-topbar {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 16px clamp(22px, 4vw, 64px);
  border-bottom: 1px solid var(--ws-line);
  position: sticky;
  top: 0;
  background: rgba(0, 0, 0, .92);
  backdrop-filter: blur(12px);
  z-index: 15;
}

.ws-topbar-title { min-width: 0; display: flex; align-items: center; gap: 15px; }
.ws-breadcrumb { display: block; color: var(--ws-dim); font-size: 9px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.ws-topbar h1 { margin-top: 5px; font-size: 21px; font-weight: 600; letter-spacing: -.045em; }
.ws-menu-toggle { display: none; width: 38px; height: 38px; border: 1px solid var(--ws-line); color: var(--ws-white); }
.ws-topbar-actions { min-width: 0; display: flex; align-items: center; gap: 10px; }

.ws-global-search {
  width: clamp(180px, 22vw, 290px);
  height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px 0 13px;
  border: 1px solid var(--ws-line);
  background: var(--ws-panel);
}

.ws-global-search > span { color: var(--ws-muted); font-size: 23px; line-height: 1; transform: translateY(-1px); }
.ws-global-search input { width: 100%; height: 100%; padding: 0; border: 0; background: transparent; box-shadow: none; font-size: 12px; }
.ws-global-search input:focus { border: 0; box-shadow: none; }
.ws-global-search kbd { flex-shrink: 0; color: var(--ws-dim); font-family: var(--font); font-size: 9px; white-space: nowrap; }

.ws-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: var(--ws-radius-small);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: -.01em;
  white-space: nowrap;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease, border-color 160ms ease;
}

.ws-button:hover { transform: translateY(-1px); }
.ws-button:active { transform: translateY(0); }
.ws-button:disabled { cursor: wait; opacity: .5; transform: none; }
.ws-button-primary { background: var(--ws-white); color: #050505; }
.ws-button-primary:hover { background: #d8dee8; }
.ws-button-quiet { border-color: var(--ws-line); color: var(--ws-copy); background: transparent; }
.ws-button-quiet:hover { border-color: var(--ws-line-strong); color: var(--ws-white); }
.ws-button-accent { border-color: var(--ws-red); color: var(--ws-white); background: transparent; }
.ws-button-accent:hover { background: var(--ws-red-soft); }
.ws-button-small { min-height: 34px; padding: 0 11px; font-size: 11px; }

.ws-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--ws-line-strong);
  border-radius: 50%;
  color: var(--ws-white);
  font-size: 12px;
  font-weight: 600;
}

.ws-avatar:hover { border-color: var(--ws-red); }

.ws-main { min-width: 0; }
.ws-view { max-width: 1500px; margin: 0 auto; padding: clamp(30px, 4vw, 62px) clamp(22px, 4vw, 64px) 100px; animation: ws-enter 320ms var(--ease-out, cubic-bezier(.16, 1, .3, 1)); }

@keyframes ws-enter {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

.ws-view-loading,
.ws-empty-state {
  min-height: 320px;
  display: grid;
  place-items: center;
  border: 1px solid var(--ws-line);
  color: var(--ws-muted);
  font-size: 13px;
}

.ws-loading-pulse { display: inline-flex; align-items: center; gap: 9px; }
.ws-loading-pulse i { width: 5px; height: 5px; display: block; border-radius: 50%; background: var(--ws-red); animation: ws-pulse 1s infinite; }
.ws-loading-pulse i:nth-child(2) { animation-delay: 150ms; }
.ws-loading-pulse i:nth-child(3) { animation-delay: 300ms; }
@keyframes ws-pulse { 0%, 100% { opacity: .2; transform: scale(.8); } 50% { opacity: 1; transform: scale(1); } }

.ws-page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.ws-page-header h2 {
  max-width: 760px;
  margin-top: 12px;
  font-size: clamp(32px, 4.5vw, 58px);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: .98;
}

.ws-page-header h2 em { color: var(--ws-red); font-style: normal; }
.ws-page-header-copy { max-width: 360px; color: var(--ws-muted); font-size: 13px; line-height: 1.55; }
.ws-page-header-actions { display: flex; gap: 8px; align-items: center; }

/* Compact header for the Today view: one short line, no marketing headline. */
.ws-page-header-compact { align-items: center; margin-bottom: 18px; }
.ws-page-header-compact h2 { margin-top: 6px; font-size: clamp(18px, 1.6vw, 22px); font-weight: 600; letter-spacing: -.01em; line-height: 1.25; }
.ws-page-header-compact .ws-kicker { font-size: 10px; }

.ws-stat-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.1fr) minmax(0, 1fr) minmax(0, .9fr);
  border-top: 1px solid var(--ws-line);
  border-bottom: 1px solid var(--ws-line);
  margin-bottom: 22px;
}

.ws-stat {
  min-height: 88px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 16px 18px;
  border-right: 1px solid var(--ws-line);
}

.ws-stat:last-child { border-right: 0; }
.ws-stat-label { color: var(--ws-muted); font-size: 10px; letter-spacing: .13em; text-transform: uppercase; }
.ws-stat-value { font-size: clamp(22px, 2.4vw, 30px); font-weight: 600; letter-spacing: -.06em; }
.ws-stat-value em { color: var(--ws-red); font-style: normal; }
.ws-stat-value-text { font-size: clamp(15px, 1.4vw, 18px); font-weight: 500; }
.ws-stat-foot { color: var(--ws-dim); font-size: 10px; letter-spacing: .04em; }

/* Stat 1 — primary, red accent on the count. */
.ws-stat-primary { background: linear-gradient(180deg, rgba(240, 68, 56, .06), transparent 60%); }
.ws-stat-primary .ws-stat-value em { font-size: 1.1em; }

/* Stat 2 — progress, with an inline bar so it reads visually different. */
.ws-stat-bar { gap: 10px; }
.ws-stat-bar-row { display: flex; align-items: baseline; gap: 8px; }
.ws-stat-bar-row em { color: var(--ws-white); font-size: clamp(22px, 2.4vw, 30px); font-weight: 600; font-style: normal; letter-spacing: -.06em; }
.ws-stat-bar-row small { color: var(--ws-muted); font-size: 11px; }
.ws-stat-bar-track { height: 3px; overflow: hidden; background: var(--ws-line); }
.ws-stat-bar-track i { display: block; height: 100%; background: var(--ws-red); transition: width 220ms ease; }

/* Stat 3 — saved projects, outlined tile. */
.ws-stat-stack { background: transparent; border-right: 1px solid var(--ws-line); }

/* Stat 4 — quiet, no border treatment, larger lower-line copy. */
.ws-stat-quiet { background: transparent; }
.ws-stat-quiet .ws-stat-value { font-weight: 500; color: var(--ws-copy); }

.ws-two-column { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 24px; align-items: start; }
.ws-section { min-width: 0; border: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-section + .ws-section { margin-top: 24px; }
.ws-section-header { min-height: 56px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 18px; border-bottom: 1px solid var(--ws-line); }
.ws-section-title { font-size: 13px; font-weight: 600; letter-spacing: -.02em; }
.ws-section-meta { color: var(--ws-dim); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.ws-section-body { padding: 18px; }

/* Section variants — give each Today section its own surface so they don't
   all read as the same flat box. */
.ws-section-panel { background: var(--ws-panel); }
.ws-section-rail { background: transparent; border-left: 0; border-right: 0; border-top: 0; border-bottom: 1px solid var(--ws-line); }
.ws-section-rail .ws-section-header { padding-left: 14px; border-left: 2px solid var(--ws-red); }
.ws-section-outline { background: transparent; border-style: dashed; border-color: var(--ws-line-strong); }
.ws-section-outline .ws-section-header { border-bottom-style: dashed; }

.ws-date-strip {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 20px;
  padding: 14px;
  border: 1px solid var(--ws-line);
  background: linear-gradient(180deg, rgba(240, 68, 56, .03), transparent 70%);
}

.ws-date-button {
  min-height: 58px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  border: 1px solid transparent;
  color: var(--ws-muted);
  text-align: left;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.ws-date-button:hover { border-color: var(--ws-line-strong); color: var(--ws-white); }
.ws-date-button.is-selected { border-color: var(--ws-red); background: var(--ws-red-soft); color: var(--ws-white); }
.ws-date-button.is-today:not(.is-selected) { background: var(--ws-red-soft); border-color: rgba(240, 68, 56, .25); }
.ws-date-button.is-today:not(.is-selected) .ws-date-number { color: var(--ws-red); }
.ws-date-name { font-size: 9px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.ws-date-number { font-size: 18px; font-weight: 600; letter-spacing: -.04em; }
.ws-date-count { margin-left: auto; color: var(--ws-dim); font-size: 9px; }
.ws-date-button.is-selected .ws-date-count { color: var(--ws-red); }

.ws-task-list { display: grid; }
.ws-task-row { min-height: 72px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--ws-line); }
.ws-task-row:last-child { border-bottom: 0; }
.ws-task-check { width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid var(--ws-line-strong); border-radius: 50%; color: transparent; font-size: 13px; }
.ws-task-check:hover { border-color: var(--ws-red); }
.ws-task-row.is-complete .ws-task-check { border-color: var(--ws-red); background: var(--ws-red); color: #000; }
.ws-task-copy { min-width: 0; padding: 12px 0; }
.ws-task-title { overflow: hidden; font-size: 13px; font-weight: 500; letter-spacing: -.015em; text-overflow: ellipsis; white-space: nowrap; }
.ws-task-row.is-complete .ws-task-title { color: var(--ws-dim); text-decoration: line-through; }
.ws-task-subline { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 5px; color: var(--ws-dim); font-size: 10px; }
.ws-task-subline span + span::before { content: "·"; margin-right: 8px; color: var(--ws-line-strong); }
.ws-task-controls { display: flex; align-items: center; gap: 6px; }
.ws-task-controls select,
.ws-task-controls input { width: 86px; min-height: 31px; padding: 0 9px; color: var(--ws-muted); font-size: 10px; }
.ws-task-controls input { width: 118px; }
.ws-priority-high { color: var(--ws-red) !important; }
.ws-priority-medium { color: #c4a55a !important; }
.ws-priority-low { color: var(--ws-muted) !important; }

.ws-task-quickadd { display: flex; gap: 8px; padding-top: 18px; }
.ws-task-quickadd input { min-width: 0; flex: 1; min-height: 42px; padding: 0 12px; font-size: 12px; }
.ws-task-quickadd select { width: 110px; min-height: 42px; padding: 0 12px; font-size: 11px; }

.ws-up-next { display: grid; gap: 18px; }
.ws-focus-card { position: relative; padding: 22px; border: 1px solid var(--ws-line); background: linear-gradient(135deg, #0e0e0e 0%, #060606 100%); overflow: hidden; }
.ws-focus-card::before { content: ""; position: absolute; top: 0; right: 0; width: 80px; height: 80px; background: radial-gradient(circle at top right, var(--ws-red-soft), transparent 65%); pointer-events: none; }
.ws-focus-card-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; position: relative; }
.ws-focus-card-top .ws-eyebrow { color: var(--ws-red); }
.ws-focus-card h3 { position: relative; margin-top: 14px; font-size: 22px; font-weight: 600; letter-spacing: -.045em; line-height: 1.1; }
.ws-focus-card p { position: relative; margin-top: 10px; color: var(--ws-muted); font-size: 12px; line-height: 1.5; }
.ws-mini-progress { position: relative; height: 3px; margin-top: 18px; background: var(--ws-line); }
.ws-mini-progress i { height: 100%; display: block; background: var(--ws-red); }
.ws-focus-footer { position: relative; display: flex; justify-content: space-between; gap: 12px; margin-top: 12px; color: var(--ws-dim); font-size: 10px; }

.ws-project-preview-list { display: grid; gap: 0; }
.ws-project-preview { min-height: 75px; display: grid; grid-template-columns: 50px minmax(0, 1fr) auto; align-items: center; gap: 13px; border-bottom: 1px solid var(--ws-line); cursor: pointer; }
.ws-project-preview:last-child { border-bottom: 0; }
.ws-project-preview:hover .ws-project-preview-title { color: var(--ws-red); }
.ws-project-thumb { width: 50px; height: 50px; object-fit: cover; border: 1px solid var(--ws-line); background: var(--ws-panel-raised); }
.ws-project-thumb-fallback { display: grid; place-items: center; color: var(--ws-red); font-size: 13px; font-weight: 600; }
.ws-project-preview-copy { min-width: 0; }
.ws-project-preview-title { overflow: hidden; font-size: 12px; font-weight: 600; letter-spacing: -.02em; text-overflow: ellipsis; white-space: nowrap; transition: color 160ms ease; }
.ws-project-preview-meta { margin-top: 5px; color: var(--ws-dim); font-size: 10px; }
.ws-arrow { color: var(--ws-dim); font-size: 18px; }

/* Calendar */
.ws-calendar-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 20px; }
.ws-calendar-range { color: var(--ws-copy); font-size: 14px; font-weight: 600; letter-spacing: -.03em; }
.ws-toolbar-actions { display: flex; gap: 7px; }
.ws-calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--ws-line); border-left: 1px solid var(--ws-line); }
.ws-calendar-day { min-width: 0; min-height: 164px; border-right: 1px solid var(--ws-line); border-bottom: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-calendar-day.is-today { background: #0a0909; }
.ws-calendar-day-head { min-height: 47px; display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; border-bottom: 1px solid var(--ws-line); }
.ws-calendar-day-name { color: var(--ws-muted); font-size: 9px; font-weight: 600; letter-spacing: .11em; text-transform: uppercase; }
.ws-calendar-day-number { color: var(--ws-copy); font-size: 16px; font-weight: 600; letter-spacing: -.04em; }
.ws-calendar-day.is-today .ws-calendar-day-number { color: var(--ws-red); }
.ws-calendar-items { display: grid; gap: 5px; padding: 9px; }
.ws-calendar-item { min-width: 0; padding: 7px 8px; border-left: 2px solid var(--ws-line-strong); background: #111; cursor: pointer; }
.ws-calendar-item:hover { border-left-color: var(--ws-red); }
.ws-calendar-item.is-complete { opacity: .45; }
.ws-calendar-item strong { display: block; overflow: hidden; color: var(--ws-copy); font-size: 10px; font-weight: 500; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.ws-calendar-item small { display: block; overflow: hidden; margin-top: 4px; color: var(--ws-dim); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.ws-calendar-more { padding: 0 9px 9px; color: var(--ws-red); font-size: 9px; }

/* Library */
.ws-library-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.ws-library-search { width: min(100%, 360px); height: 42px; padding: 0 13px; }
.ws-filter-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.ws-filter-pill { min-height: 31px; padding: 0 11px; border: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 10px; }
.ws-filter-pill:hover,
.ws-filter-pill.is-active { border-color: var(--ws-red); color: var(--ws-white); background: var(--ws-red-soft); }
.ws-project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.ws-project-card { min-width: 0; display: flex; flex-direction: column; border: 1px solid var(--ws-line); background: var(--ws-panel); cursor: pointer; transition: border-color 180ms ease, transform 180ms ease; }
.ws-project-card:hover { border-color: var(--ws-line-strong); transform: translateY(-2px); }
.ws-project-card-image { aspect-ratio: 16 / 8; position: relative; overflow: hidden; border-bottom: 1px solid var(--ws-line); background: #111; }
.ws-project-card-image img { width: 100%; height: 100%; object-fit: cover; opacity: .82; transition: opacity 180ms ease, transform 250ms ease; }
.ws-project-card:hover img { opacity: 1; transform: scale(1.03); }
.ws-project-card-fallback { width: 100%; height: 100%; display: grid; place-items: center; color: var(--ws-red); font-size: 30px; font-weight: 600; }
.ws-project-card-badge { position: absolute; left: 10px; bottom: 9px; padding: 5px 7px; border: 1px solid rgba(255,255,255,.16); background: rgba(0,0,0,.8); color: var(--ws-copy); font-size: 8px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.ws-project-card-body { min-height: 132px; display: flex; flex-direction: column; padding: 15px; }
.ws-project-card-body h3 { overflow: hidden; font-size: 15px; font-weight: 600; letter-spacing: -.04em; line-height: 1.15; text-overflow: ellipsis; white-space: nowrap; }
.ws-project-card-body p { display: -webkit-box; overflow: hidden; margin-top: 8px; color: var(--ws-muted); font-size: 11px; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.ws-project-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 16px; color: var(--ws-dim); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.ws-project-card-foot strong { color: var(--ws-red); font-weight: 600; }
.ws-search-results { display: grid; gap: 8px; margin-bottom: 22px; }
.ws-search-result { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px; border: 1px solid var(--ws-line); background: var(--ws-panel); cursor: pointer; }
.ws-search-result:hover { border-color: var(--ws-line-strong); }
.ws-search-result-copy { min-width: 0; }
.ws-search-result h3 { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.ws-search-result p { overflow: hidden; margin-top: 5px; color: var(--ws-muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.ws-search-result small { flex-shrink: 0; color: var(--ws-red); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }

/* Memory and agents */
.ws-facts-list { display: grid; gap: 0; }
.ws-fact-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--ws-line); }
.ws-fact-row:last-child { border-bottom: 0; }
.ws-fact-copy { color: var(--ws-copy); font-size: 13px; line-height: 1.45; }
.ws-fact-meta { margin-top: 7px; color: var(--ws-dim); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.ws-icon-button { width: 32px; height: 32px; border: 1px solid var(--ws-line); color: var(--ws-muted); }
.ws-icon-button:hover { border-color: var(--ws-red); color: var(--ws-red); }
.ws-add-fact { display: grid; grid-template-columns: minmax(0, 1fr) 130px auto; gap: 8px; margin-top: 20px; }
.ws-add-fact input,
.ws-add-fact select { min-height: 42px; padding: 0 11px; font-size: 11px; }
.ws-preference-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.ws-preference-chip { padding: 7px 9px; border: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 10px; }

.ws-agent-hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); gap: 24px; margin-bottom: 24px; }
.ws-agent-callout { padding: clamp(22px, 4vw, 40px); border: 1px solid var(--ws-red); background: var(--ws-red-soft); }
.ws-agent-callout h2 { max-width: 650px; margin-top: 14px; font-size: clamp(28px, 4vw, 48px); font-weight: 600; letter-spacing: -.065em; line-height: 1; }
.ws-agent-callout p { max-width: 590px; margin-top: 16px; color: var(--ws-copy); font-size: 13px; line-height: 1.55; }
.ws-agent-callout .ws-button { margin-top: 25px; }
.ws-agent-status { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; padding: 22px; border: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-agent-status-line { display: flex; align-items: center; gap: 10px; color: var(--ws-copy); font-size: 13px; }
.ws-agent-status-detail { display: grid; gap: 9px; padding-top: 18px; border-top: 1px solid var(--ws-line); }
.ws-agent-status-detail div { display: flex; justify-content: space-between; gap: 12px; color: var(--ws-muted); font-size: 10px; }
.ws-agent-status-detail strong { color: var(--ws-white); font-weight: 500; text-align: right; }
.ws-key-list { display: grid; }
.ws-key-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 15px; min-height: 70px; border-bottom: 1px solid var(--ws-line); }
.ws-key-row:last-child { border-bottom: 0; }
.ws-key-name { font-size: 12px; font-weight: 600; }
.ws-key-prefix { margin-top: 5px; color: var(--ws-dim); font-family: var(--mono); font-size: 10px; letter-spacing: 0; }
.ws-key-state { color: var(--ws-muted); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.ws-key-state.is-active { color: var(--ws-red); }
.ws-agent-instructions { margin-top: 24px; padding: 20px; border: 1px solid var(--ws-line); background: #050505; }
.ws-agent-instructions h3 { font-size: 13px; font-weight: 600; }
.ws-code-line { display: block; overflow-x: auto; margin-top: 14px; padding: 14px; border: 1px solid var(--ws-line); color: var(--ws-copy); font-family: var(--mono); font-size: 11px; line-height: 1.5; white-space: pre; }

/* Project detail */
.ws-project-back { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 18px; color: var(--ws-muted); font-size: 11px; }
.ws-project-back:hover { color: var(--ws-white); }
.ws-project-heading { display: block; margin-bottom: 20px; }
.ws-project-heading h2 { max-width: 720px; margin-top: 8px; font-size: clamp(26px, 3.4vw, 42px); font-weight: 600; letter-spacing: -.05em; line-height: 1; }
.ws-project-heading h2 em { color: var(--ws-red); font-style: normal; }
.ws-project-heading-summary { max-width: 720px; margin-top: 10px; color: var(--ws-copy); font-size: 13px; line-height: 1.55; }
.ws-project-heading .ws-project-chip-row { margin-top: 12px; }
.ws-project-heading .ws-project-chip { padding: 5px 8px; font-size: 9px; }
.ws-video-workbench { display: grid; grid-template-columns: minmax(240px, .86fr) minmax(280px, 1fr) minmax(300px, 1fr); gap: 1px; margin-bottom: 20px; border: 1px solid var(--ws-line); background: var(--ws-line); }
.ws-video-panel,
.ws-understanding-panel,
.ws-live-chat-panel { min-width: 0; min-height: 0; background: var(--ws-panel); }
.ws-video-panel { background: var(--ws-panel); }
.ws-understanding-panel { background: var(--ws-panel-raised); }
.ws-live-chat-panel { background: transparent; border-left: 1px solid var(--ws-line-strong); }
.ws-workbench-head { min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--ws-line); color: var(--ws-dim); font-size: 9px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.ws-workbench-status { min-width: 0; display: inline-flex; align-items: center; gap: 7px; overflow: hidden; color: var(--ws-muted); font-size: 9px; letter-spacing: .08em; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.ws-workbench-status i { width: 6px; height: 6px; flex: 0 0 6px; display: inline-block; border-radius: 50%; background: var(--ws-dim); }
.ws-workbench-status.is-ready i { background: var(--ws-red); box-shadow: 0 0 0 4px var(--ws-red-soft); }
.ws-workbench-status.is-working i { background: var(--ws-red); animation: ws-pulse 1s ease-in-out infinite; }
.ws-video-stage { position: relative; min-height: 440px; display: grid; place-items: center; overflow: hidden; background: #050505; }
.ws-video-stage > img,
.ws-video-stage > .ws-project-source-fallback,
.ws-video-stage > .ws-project-video,
.ws-video-stage > .ws-project-embed { width: 100%; height: 100%; min-height: 440px; display: block; }
.ws-video-stage > img { object-fit: cover; opacity: .92; }
.ws-project-source-fallback { display: grid !important; place-items: center; color: var(--ws-red); font-size: 54px; font-weight: 600; }
.ws-project-video { border: 0; object-fit: cover; background: #000; }
.ws-project-embed { border: 0; background: #000; }
.ws-video-stage.is-processing > img { opacity: .62; }
.ws-video-processing { position: absolute; right: 15px; bottom: 15px; left: 15px; z-index: 2; display: grid; grid-template-columns: 10px minmax(0, 1fr); gap: 3px 9px; padding: 11px 12px; border: 1px solid var(--ws-red); background: rgba(0, 0, 0, .84); pointer-events: none; }
.ws-video-processing-dot { width: 7px; height: 7px; grid-row: span 2; align-self: center; border-radius: 50%; background: var(--ws-red); box-shadow: 0 0 0 4px var(--ws-red-soft); animation: ws-pulse 1.1s ease-in-out infinite; }
.ws-video-processing strong { color: var(--ws-white); font-size: 9px; letter-spacing: .12em; }
.ws-video-processing small { color: var(--ws-muted); font-size: 10px; }
.ws-video-scan-line { position: absolute; top: -2px; right: 12%; left: 12%; z-index: 1; height: 1px; background: var(--ws-red); box-shadow: 0 0 14px rgba(240, 68, 56, .65); opacity: .8; animation: ws-video-scan 2.1s ease-in-out infinite; pointer-events: none; }
@keyframes ws-video-scan { 0%, 100% { transform: translateY(0); opacity: .2; } 50% { transform: translateY(425px); opacity: .9; } }
.ws-video-meta { min-height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 16px; border-top: 1px solid var(--ws-line); color: var(--ws-dim); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.ws-video-meta a { overflow: hidden; color: var(--ws-muted); text-overflow: ellipsis; white-space: nowrap; }
.ws-video-meta a:hover { color: var(--ws-red); }
.ws-project-poster-button { position: relative; display: block; width: 100%; height: 100%; min-height: 440px; padding: 0; border: 0; background: #050505; cursor: pointer; overflow: hidden; }
.ws-project-poster-button:hover .ws-project-play-badge { transform: translate(-50%, -50%) scale(1.04); border-color: var(--ws-red); }
.ws-project-poster-button:focus-visible { outline: 2px solid var(--ws-red); outline-offset: -4px; }
.ws-project-poster { display: block; width: 100%; height: 100%; min-height: 440px; object-fit: cover; opacity: .92; }
.ws-project-play-badge { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 9px; padding: 12px 18px; border: 1px solid var(--ws-line-strong); border-radius: 999px; background: rgba(0, 0, 0, .78); color: var(--ws-white); font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; transition: transform 180ms ease, border-color 180ms ease; }
.ws-project-play-badge i { font-size: 12px; color: var(--ws-red); font-style: normal; }
.ws-understanding-body { min-height: 440px; display: flex; flex-direction: column; padding: 18px 20px 16px; }
.ws-understanding-headline { margin-top: 6px; }
.ws-understanding-title { margin-top: 8px; color: var(--ws-white); font-size: clamp(18px, 2vw, 24px); font-weight: 600; letter-spacing: -.04em; line-height: 1.15; }
.ws-insight-card { margin-top: 16px; padding: 12px 14px; border-left: 2px solid var(--ws-red); background: rgba(0, 0, 0, .35); }
.ws-insight-card p { margin-top: 6px; color: var(--ws-copy); font-size: 12px; line-height: 1.48; }
.ws-tab-pills { display: flex; flex-wrap: wrap; gap: 6px; padding-bottom: 14px; border-bottom: 1px solid var(--ws-line); }
.ws-project-pill { min-height: 28px; padding: 0 11px; border: 1px solid var(--ws-line); border-radius: 999px; background: transparent; color: var(--ws-muted); font-size: 10px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; transition: color 160ms ease, border-color 160ms ease, background 160ms ease; }
.ws-project-pill:hover { color: var(--ws-white); border-color: var(--ws-line-strong); }
.ws-project-pill.is-active { color: var(--ws-white); border-color: var(--ws-red); background: var(--ws-red-soft); }
/* Chat is always in the right column on desktop, so the pill is redundant. */
.ws-project-pill[data-tab="chat"] { display: none; }
.ws-tab-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; padding-top: 14px; }
.ws-signal-list { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--ws-line); }
.ws-signal-list-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 0 8px; color: var(--ws-dim); font-size: 9px; font-weight: 600; letter-spacing: .12em; }
.ws-signal-list-head span:last-child { color: var(--ws-red); }
.ws-signal-row { display: grid; grid-template-columns: 19px minmax(0, 1fr) auto; align-items: center; gap: 7px; min-height: 32px; border-top: 1px solid var(--ws-line); color: var(--ws-copy); font-size: 11px; }
.ws-signal-row > span:last-child { color: var(--ws-dim); font-size: 9px; }
.ws-signal-check { width: 16px; height: 16px; display: grid; place-items: center; border: 1px solid var(--ws-line-strong); color: var(--ws-dim); font-size: 10px; }
.ws-signal-check.is-on { border-color: rgba(240, 68, 56, .55); color: var(--ws-red); }
.ws-inline-link { display: inline-flex; align-items: center; gap: 7px; margin-top: 16px; color: var(--ws-red); font-size: 10px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.ws-inline-link:hover { color: var(--ws-white); }
.ws-live-chat-body { min-height: 440px; display: flex; flex-direction: column; padding: 14px 16px; }
.ws-chat-heading { display: flex; align-items: center; gap: 10px; }
.ws-chat-avatar { width: 31px; height: 31px; flex: 0 0 31px; display: grid; place-items: center; border: 1px solid var(--ws-line-strong); border-radius: 50%; color: var(--ws-white); font-size: 9px; font-weight: 600; }
.ws-chat-heading strong,
.ws-chat-heading small { display: block; }
.ws-chat-heading strong { color: var(--ws-white); font-size: 13px; font-weight: 600; }
.ws-chat-heading small { margin-top: 4px; color: var(--ws-dim); font-size: 10px; }
.ws-chat-quick-prompts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.ws-chat-quick-prompts button { min-height: 28px; padding: 0 9px; border: 1px solid var(--ws-line); border-radius: 999px; color: var(--ws-muted); font-size: 10px; }
.ws-chat-quick-prompts button:hover { border-color: var(--ws-red); color: var(--ws-white); }
.ws-live-chat-panel .ws-chat-live { min-height: 0; flex: 1; display: flex; flex-direction: column; margin-top: 12px; }
.ws-live-chat-panel .ws-chat-messages { min-height: 0; max-height: none; flex: 1; overflow: auto; }
.ws-live-chat-panel .ws-chat-form { margin-top: 12px; }

/* Compact chat surface — quick prompts sit as a single horizontal row above
   the message area, no avatar header, no giant empty box. */
.ws-chat-row { display: flex; flex-wrap: wrap; gap: 6px; }
.ws-chat-chip { min-height: 26px; padding: 0 10px; border: 1px solid var(--ws-line); border-radius: 999px; color: var(--ws-muted); font-size: 10px; letter-spacing: .02em; }
.ws-chat-chip:hover { border-color: var(--ws-red); color: var(--ws-white); }
.ws-chat-send { min-height: 36px; padding: 0 14px; font-size: 11px; }
.ws-chat-focus-note { padding: 14px; border: 1px dashed var(--ws-line-strong); color: var(--ws-copy); font-size: 11px; line-height: 1.45; }
.ws-chat-focus-note strong { display: block; color: var(--ws-white); font-size: 12px; font-weight: 600; }
.ws-chat-focus-note span { display: block; margin-top: 4px; color: var(--ws-muted); }
.ws-processing-compact { margin-bottom: 24px; padding: 14px 16px 15px; border: 1px solid var(--ws-line-strong); background: var(--ws-panel); }
.ws-processing-strip-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--ws-muted); font-size: 9px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.ws-processing-strip-head > span { display: inline-flex; align-items: center; gap: 8px; }
.ws-processing-strip-head strong { color: var(--ws-white); font-size: 10px; font-weight: 500; }
.ws-processing-live-dot { width: 6px; height: 6px; display: inline-block; border-radius: 50%; background: var(--ws-red); box-shadow: 0 0 0 4px var(--ws-red-soft); animation: ws-pulse 1.1s ease-in-out infinite; }
.ws-processing-track { height: 2px; margin-top: 13px; overflow: hidden; background: var(--ws-line); }
.ws-processing-track i { height: 100%; display: block; background: var(--ws-red); transition: width 260ms ease; }
.ws-processing-mini-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 7px; margin-top: 13px; }
.ws-processing-mini-step { min-width: 0; display: flex; align-items: center; gap: 6px; color: var(--ws-dim); font-size: 9px; }
.ws-processing-mini-step i { width: 17px; height: 17px; flex: 0 0 17px; display: grid; place-items: center; border: 1px solid var(--ws-line); border-radius: 50%; color: var(--ws-dim); font-family: var(--mono); font-size: 8px; font-style: normal; }
.ws-processing-mini-step b { overflow: hidden; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.ws-processing-mini-step.is-current { color: var(--ws-white); }
.ws-processing-mini-step.is-current i { border-color: var(--ws-red); color: var(--ws-red); }
.ws-processing-mini-step.is-done i { border-color: #394039; color: #b8caa9; }
.ws-processing-mini-step.is-done b { color: var(--ws-copy); }
.ws-processing-error { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; color: var(--ws-red); font-size: 11px; }
.ws-project-hero { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 26px; align-items: stretch; margin-bottom: 24px; }
.ws-project-intro { min-width: 0; padding: clamp(24px, 4vw, 42px); border: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-project-intro h2 { max-width: 830px; margin-top: 13px; font-size: clamp(32px, 5vw, 62px); font-weight: 600; letter-spacing: -.07em; line-height: .96; }
.ws-project-intro h2 em { color: var(--ws-red); font-style: normal; }
.ws-project-summary { max-width: 720px; margin-top: 21px; color: var(--ws-copy); font-size: 14px; line-height: 1.55; }
.ws-project-chip-row { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 23px; }
.ws-project-chip { padding: 7px 9px; border: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 9px; letter-spacing: .09em; text-transform: uppercase; }
.ws-project-source { min-width: 0; position: relative; overflow: hidden; border: 1px solid var(--ws-line); background: #101010; }
.ws-project-source img { width: 100%; height: 100%; min-height: 220px; object-fit: cover; opacity: .8; }
.ws-project-source-fallback { min-height: 100%; display: grid; place-items: center; color: var(--ws-red); font-size: 54px; font-weight: 600; }
.ws-project-source-caption { position: absolute; inset: auto 0 0; padding: 12px 16px 14px; background: rgba(0,0,0,.86); color: var(--ws-white); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.ws-project-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); gap: 24px; align-items: start; }
.ws-project-left, .ws-project-right { min-width: 0; }

.ws-project-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  padding: 4px;
  border: 1px solid var(--ws-line);
  background: var(--ws-panel);
}

.ws-project-tab {
  min-height: 38px;
  flex: 1;
  padding: 0 13px;
  border: 1px solid transparent;
  color: var(--ws-muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.ws-project-tab-intro {
  display: inline-flex;
  align-items: center;
  padding: 0 10px 0 8px;
  color: var(--ws-dim);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.ws-project-tab:hover { color: var(--ws-white); }
.ws-project-tab.is-active { border-color: var(--ws-red); background: var(--ws-red-soft); color: var(--ws-white); }

.ws-project-tab-panel { display: grid; gap: 24px; }
.ws-project-tab-panel[hidden] { display: none; }

.ws-project-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(220px, .85fr);
  gap: 10px;
}

.ws-overview-lead,
.ws-overview-takeaway,
.ws-overview-section {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--ws-line);
  background: var(--ws-panel);
}

.ws-overview-lead { grid-row: span 2; border-left: 2px solid var(--ws-red); }
.ws-overview-takeaway { border-left: 2px solid var(--ws-line-strong); }
.ws-overview-label { color: var(--ws-muted); font-size: 9px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; }
.ws-overview-lead p:not(.ws-overview-label),
.ws-overview-takeaway p:not(.ws-overview-label) { margin-top: 10px; color: var(--ws-copy); font-size: 14px; line-height: 1.55; }
.ws-overview-takeaway p:not(.ws-overview-label) { font-size: 13px; }

.ws-overview-section { grid-column: 1 / -1; }
.ws-overview-section h3 { margin-bottom: 13px; color: var(--ws-white); font-size: 13px; font-weight: 600; }
.ws-overview-items { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ws-overview-item { padding: 11px 12px; border-left: 2px solid var(--ws-line-strong); background: #050505; }
.ws-overview-item strong { display: block; color: var(--ws-copy); font-size: 11px; font-weight: 600; }
.ws-overview-item span { display: block; margin-top: 5px; color: var(--ws-muted); font-size: 11px; line-height: 1.45; }

.ws-next-move {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border: 1px solid var(--ws-red);
  background: var(--ws-red-soft);
}

.ws-next-move-copy { min-width: 0; }
.ws-next-move-copy p { margin-top: 7px; color: var(--ws-white); font-size: 13px; line-height: 1.45; }
.ws-next-move-action { flex: 0 0 auto; color: var(--ws-red); font-size: 9px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }

.ws-source-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 15px;
}

.ws-source-meta a,
.ws-source-meta span {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  padding: 7px 9px;
  border: 1px solid var(--ws-line);
  color: var(--ws-muted);
  font-size: 9px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ws-source-meta a:hover { border-color: var(--ws-red); color: var(--ws-white); }

.ws-evidence-section .ws-section-body { padding-top: 14px; }
.ws-evidence-grid-compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ws-evidence-grid-compact .ws-evidence-card p { max-height: 116px; }

.ws-context-accordion { border: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-context-accordion summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 18px; color: var(--ws-white); cursor: pointer; font-size: 12px; font-weight: 600; list-style: none; }
.ws-context-accordion summary::-webkit-details-marker { display: none; }
.ws-context-accordion summary::after { content: "＋"; color: var(--ws-red); font-size: 16px; font-weight: 400; }
.ws-context-accordion[open] summary::after { content: "−"; }
.ws-context-accordion > .ws-context-builder-inner { padding: 0 18px 18px; border-top: 1px solid var(--ws-line); }

/* Tight variant used at the bottom of each tab: transparent surface, smaller
   summary, no internal border on the inner sections so the cascade reads
   as a single drawer rather than stacked boxes. */
.ws-context-accordion-tight { margin-top: auto; background: transparent; border: 0; border-top: 1px solid var(--ws-line); }
.ws-context-accordion-tight summary { padding: 12px 0; color: var(--ws-muted); font-size: 10px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.ws-context-accordion-tight summary::after { font-size: 12px; }
.ws-context-accordion-tight[open] summary { color: var(--ws-white); }
.ws-context-accordion-inner { display: grid; gap: 14px; padding: 14px 0 4px; }

/* Mini section variant — tighter header, smaller body, used inside the More
   context accordion. */
.ws-section-mini { background: transparent; border-color: var(--ws-line); }
.ws-section-mini .ws-section-header { min-height: 40px; padding: 10px 12px; }
.ws-section-mini .ws-section-body { padding: 12px 14px; }
.ws-context-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.ws-context-presets .ws-filter-pill { min-height: 29px; }
.ws-key-points { margin-top: 18px; }

.ws-chat-panel { position: sticky; top: 112px; }
.ws-chat-panel .ws-chat-messages { max-height: min(46vh, 430px); }
.ws-chat-panel .ws-section-body { padding: 15px; }

.ws-chat-focus-note { padding: 18px; border: 1px dashed var(--ws-line-strong); color: var(--ws-muted); font-size: 12px; line-height: 1.5; }
.ws-chat-focus-note strong { display: block; margin-bottom: 6px; color: var(--ws-white); font-size: 14px; }

.ws-project-source.is-processing::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -26%;
  width: 22%;
  background: rgba(240, 68, 56, .2);
  transform: translateX(-100%);
  animation: ws-scan 1.9s ease-in-out infinite;
  pointer-events: none;
}

@keyframes ws-scan { to { transform: translateX(560%); } }
.ws-project-processing-label { position: absolute; left: 14px; top: 14px; z-index: 1; padding: 7px 9px; border: 1px solid var(--ws-red); background: rgba(0,0,0,.78); color: var(--ws-white); font-size: 9px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }

.ws-context-builder { border-color: var(--ws-red); }
.ws-context-builder .ws-section-header { border-bottom-color: rgba(240, 68, 56, .35); }
.ws-context-intro { color: var(--ws-muted); font-size: 12px; line-height: 1.5; }
.ws-context-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-top: 16px; }
.ws-context-option { min-height: 47px; display: flex; align-items: center; gap: 8px; padding: 8px 9px; border: 1px solid var(--ws-line); color: var(--ws-copy); font-size: 10px; cursor: pointer; }
.ws-context-option:hover { border-color: var(--ws-line-strong); }
.ws-context-option:has(input:checked) { border-color: var(--ws-red); color: var(--ws-white); background: var(--ws-red-soft); }
.ws-context-option input { accent-color: var(--ws-red); }
.ws-context-controls { display: flex; align-items: flex-end; gap: 9px; margin-top: 16px; }
.ws-context-control { display: grid; gap: 7px; }
.ws-context-control label { color: var(--ws-dim); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.ws-context-control select { min-height: 37px; padding: 0 28px 0 10px; font-size: 10px; }
.ws-context-control.max-chars { width: 110px; }
.ws-context-controls .ws-button { margin-left: auto; }

.ws-context-result { margin-top: 16px; border: 1px solid var(--ws-line); background: #050505; }
.ws-context-result.is-empty { padding: 18px; color: var(--ws-dim); font-size: 11px; }
.ws-context-result-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.ws-context-result-header strong { color: var(--ws-red); font-weight: 600; }
.ws-context-result-body { padding: 14px; }
.ws-context-data-grid { display: grid; gap: 10px; }
.ws-context-data-card { padding: 14px; border-left: 2px solid var(--ws-line-strong); background: var(--ws-panel); }
.ws-context-data-card.is-important { border-left-color: var(--ws-red); }
.ws-context-data-card h4 { color: var(--ws-muted); font-size: 9px; letter-spacing: .13em; text-transform: uppercase; }
.ws-context-data-card p,
.ws-context-data-card pre { margin-top: 9px; color: var(--ws-copy); font-family: var(--font); font-size: 12px; line-height: 1.52; white-space: pre-wrap; word-break: break-word; }
.ws-context-data-card pre { font-family: var(--mono); font-size: 10px; letter-spacing: 0; }
.ws-context-list { display: grid; gap: 7px; margin-top: 9px; }
.ws-context-list li { display: flex; gap: 8px; color: var(--ws-copy); font-size: 11px; line-height: 1.4; }
.ws-context-list li::before { content: "↳"; flex-shrink: 0; color: var(--ws-red); }
.ws-context-links { display: grid; gap: 8px; margin-top: 9px; }
.ws-context-link { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 7px; border-bottom: 1px solid var(--ws-line); color: var(--ws-copy); font-size: 11px; }
.ws-context-link:hover { color: var(--ws-red); }
.ws-context-link small { flex-shrink: 0; color: var(--ws-dim); font-size: 9px; }
.ws-context-raw { max-height: 300px; overflow: auto; padding: 14px; border: 1px solid var(--ws-line); color: var(--ws-copy); font-family: var(--mono); font-size: 10px; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
.ws-raw-disclosure { margin-top: 18px; border-top: 1px solid var(--ws-line); }
.ws-raw-disclosure summary { padding: 14px 0 2px; color: var(--ws-muted); cursor: pointer; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.ws-raw-disclosure summary:hover { color: var(--ws-white); }

.ws-evidence-grid { display: grid; gap: 9px; }
.ws-evidence-card { min-width: 0; padding: 16px; border: 1px solid var(--ws-line); background: var(--ws-panel); }
.ws-evidence-card h3 { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--ws-muted); font-size: 9px; letter-spacing: .13em; text-transform: uppercase; }
.ws-evidence-card h3 span { color: var(--ws-red); font-size: 9px; }
.ws-evidence-card p { max-height: 154px; overflow: auto; margin-top: 10px; color: var(--ws-copy); font-size: 12px; line-height: 1.5; white-space: pre-wrap; }
.ws-evidence-empty { color: var(--ws-dim) !important; }
.ws-resource-list { display: grid; gap: 0; margin-top: 10px; }
.ws-resource { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 10px 0; border-top: 1px solid var(--ws-line); color: var(--ws-copy); font-size: 11px; }
.ws-resource:hover { color: var(--ws-red); }
.ws-resource span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ws-resource small { flex-shrink: 0; margin-left: auto; color: var(--ws-dim); font-size: 9px; }

.ws-processing { margin-bottom: 24px; border-color: var(--ws-line-strong); }
.ws-processing-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 7px; }
.ws-processing-step { min-height: 62px; display: flex; flex-direction: column; justify-content: space-between; gap: 8px; padding: 10px; border: 1px solid var(--ws-line); color: var(--ws-dim); }
.ws-processing-step span { color: var(--ws-dim); font-family: var(--mono); font-size: 10px; }
.ws-processing-step strong { color: var(--ws-muted); font-size: 10px; font-weight: 500; line-height: 1.25; }
.ws-processing-step.is-current { border-color: var(--ws-red); background: var(--ws-red-soft); }
.ws-processing-step.is-current span,
.ws-processing-step.is-current strong { color: var(--ws-white); }
.ws-processing-step.is-done { border-color: #394039; }
.ws-processing-step.is-done span { color: #b8caa9; }
.ws-processing-step.is-done strong { color: var(--ws-copy); }

.ws-project-task-list { display: grid; gap: 0; }
.ws-project-task { display: grid; grid-template-columns: 27px minmax(0, 1fr) auto; gap: 10px; align-items: center; min-height: 62px; border-bottom: 1px solid var(--ws-line); }
.ws-project-task:last-child { border-bottom: 0; }
.ws-project-task button { width: 21px; height: 21px; border: 1px solid var(--ws-line-strong); border-radius: 50%; color: transparent; font-size: 12px; }
.ws-project-task button:hover { border-color: var(--ws-red); }
.ws-project-task.is-done button { background: var(--ws-red); border-color: var(--ws-red); color: #000; }
.ws-project-task-title { font-size: 12px; line-height: 1.35; }
.ws-project-task.is-done .ws-project-task-title { color: var(--ws-dim); text-decoration: line-through; }
.ws-project-task small { color: var(--ws-dim); font-size: 9px; }

.ws-chat { display: grid; gap: 10px; }
.ws-chat-messages { min-height: 150px; max-height: 380px; overflow: auto; display: grid; align-content: start; gap: 9px; padding: 2px; }
.ws-chat-empty { display: flex; align-items: flex-start; gap: 8px; padding: 12px 14px; color: var(--ws-muted); font-size: 11px; line-height: 1.45; }
.ws-chat-empty-mark { color: var(--ws-red); font-size: 14px; line-height: 1; flex: 0 0 auto; }
.ws-chat-bubble { max-width: 92%; padding: 9px 11px; border: 1px solid var(--ws-line); color: var(--ws-copy); font-size: 11.5px; line-height: 1.5; white-space: pre-wrap; display: flex; flex-direction: column; gap: 4px; }
.ws-chat-bubble.user { justify-self: end; border-color: var(--ws-line-strong); background: #0e0e0e; color: var(--ws-white); }
.ws-chat-bubble.agent { justify-self: start; border-left: 2px solid var(--ws-red); background: #060606; }
.ws-chat-bubble-mark { color: var(--ws-red); font-size: 9px; font-weight: 700; letter-spacing: .14em; }
.ws-chat-bubble-text { display: block; }
.ws-chat-form { display: flex; gap: 7px; }
.ws-chat-form input { min-width: 0; flex: 1; min-height: 42px; padding: 0 12px; font-size: 11px; }

/* Modals and feedback */
.ws-modal-backdrop { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: rgba(0, 0, 0, .78); }
.ws-modal { width: min(100%, 580px); max-height: min(90vh, 720px); overflow: auto; position: relative; padding: clamp(24px, 5vw, 42px); border: 1px solid var(--ws-line-strong); background: #080808; box-shadow: var(--ws-shadow); }
.ws-modal-close { position: absolute; top: 12px; right: 14px; width: 34px; height: 34px; color: var(--ws-muted); font-size: 25px; line-height: 1; }
.ws-modal-close:hover { color: var(--ws-red); }
.ws-modal h2 { max-width: 470px; margin-top: 14px; font-size: clamp(28px, 5vw, 44px); font-weight: 600; letter-spacing: -.065em; line-height: 1; }
.ws-modal-copy { max-width: 480px; margin-top: 13px; color: var(--ws-muted); font-size: 13px; line-height: 1.55; }
.ws-save-form, .ws-key-form { margin-top: 28px; }
.ws-save-input-row { display: flex; gap: 8px; }
.ws-save-input-row input { min-width: 0; flex: 1; min-height: 48px; padding: 0 13px; font-size: 12px; }
.ws-upload-divider { display: flex; align-items: center; gap: 12px; margin: 22px 0; color: var(--ws-dim); font-size: 10px; text-transform: uppercase; }
.ws-upload-divider::before, .ws-upload-divider::after { content: ""; height: 1px; flex: 1; background: var(--ws-line); }
.ws-upload-drop { min-height: 77px; display: flex !important; align-items: center; gap: 13px; padding: 12px 14px; border: 1px dashed var(--ws-line-strong); cursor: pointer; }
.ws-upload-drop:hover { border-color: var(--ws-red); background: var(--ws-red-soft); }
.ws-upload-drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.ws-upload-icon { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--ws-line-strong); color: var(--ws-red); font-size: 18px; }
.ws-upload-drop strong, .ws-upload-drop small { display: block; }
.ws-upload-drop strong { color: var(--ws-copy); font-size: 12px; font-weight: 500; }
.ws-upload-drop small { margin-top: 4px; color: var(--ws-dim); font-size: 10px; }
.ws-upload-preview { display: grid; grid-template-columns: 74px minmax(0, 1fr); align-items: center; gap: 12px; margin-top: 10px; padding: 9px; border: 1px solid var(--ws-line); background: #050505; }
.ws-upload-preview video { width: 74px; height: 52px; object-fit: cover; background: #000; }
.ws-upload-preview strong, .ws-upload-preview small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ws-upload-preview strong { color: var(--ws-copy); font-size: 11px; font-weight: 500; }
.ws-upload-preview small { margin-top: 4px; color: var(--ws-muted); font-size: 10px; }
.ws-key-form { display: grid; gap: 10px; }
.ws-key-form input { min-height: 46px; padding: 0 13px; font-size: 12px; }
.ws-key-form .ws-button { margin-top: 8px; }
.ws-form-status { min-height: 18px; margin-top: 11px; color: var(--ws-muted); font-size: 11px; line-height: 1.45; }
.ws-form-status[data-state="error"] { color: var(--ws-red); }
.ws-form-status[data-state="success"] { color: #b8caa9; }
.ws-form-status[data-state="working"] { color: var(--ws-copy); }
.ws-toast { position: fixed; right: 24px; bottom: 24px; z-index: 100; max-width: min(360px, calc(100vw - 40px)); padding: 12px 15px; border: 1px solid var(--ws-line-strong); background: #111; color: var(--ws-copy); font-size: 11px; line-height: 1.4; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity 180ms ease, transform 180ms ease; }
.ws-toast.is-visible { opacity: 1; transform: translateY(0); }
.ws-toast.is-error { border-color: var(--ws-red); color: var(--ws-white); }

/* Responsive desktop-to-phone translation */
@media (max-width: 1180px) {
  :root { --ws-sidebar: 218px; }
  .ws-topbar { gap: 14px; }
  .ws-global-search { width: 210px; }
  .ws-project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ws-project-hero { grid-template-columns: minmax(0, 1fr) 250px; }
}

@media (max-width: 960px) {
  :root { --ws-sidebar: 76px; }
  .ws-sidebar-top { padding: 27px 12px 20px; }
  .ws-brand { justify-content: center; padding: 0; }
  .ws-brand span,
  .ws-account,
  .ws-nav button > span:not(.ws-nav-icon),
  .ws-nav kbd,
  .ws-sidebar-bottom .ws-sidebar-link,
  .ws-mcp-indicator span { display: none; }
  .ws-account { margin: 36px 0 24px; padding-bottom: 20px; }
  .ws-nav button { justify-content: center; padding: 0; }
  .ws-nav-icon { width: auto; }
  .ws-sidebar-bottom { padding: 18px 12px 22px; }
  .ws-mcp-indicator { justify-content: center; padding: 0; border: 0; }
  .ws-project-layout { grid-template-columns: minmax(0, 1fr); }
  .ws-project-right { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; }
  .ws-project-right > .ws-section + .ws-section { margin-top: 0; }
  .ws-project-heading { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .ws-project-heading-side { padding-left: 0; border-left: 0; }
  .ws-video-workbench { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
  .ws-video-panel { grid-row: span 2; }
  .ws-video-stage,
  .ws-video-stage > img,
  .ws-video-stage > .ws-project-source-fallback,
  .ws-video-stage > .ws-project-video,
  .ws-video-stage > .ws-project-embed { min-height: 500px; }
  .ws-understanding-body,
  .ws-live-chat-body { min-height: 0; }
  .ws-agent-hero { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  .ws-shell { display: block; }
  .ws-sidebar { width: min(290px, 86vw); position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-105%); transition: transform 220ms ease; box-shadow: 18px 0 50px rgba(0,0,0,.5); }
  .ws-sidebar.is-open { transform: translateX(0); }
  .ws-sidebar-top { padding: 27px 18px 20px; }
  .ws-brand { justify-content: flex-start; padding: 0 10px; }
  .ws-brand span,
  .ws-account,
  .ws-nav button > span:not(.ws-nav-icon),
  .ws-nav kbd,
  .ws-sidebar-bottom .ws-sidebar-link,
  .ws-mcp-indicator span { display: block; }
  .ws-account { margin: 47px 10px 32px; padding-bottom: 28px; }
  .ws-nav button { justify-content: flex-start; padding: 0 10px; }
  .ws-nav-icon { width: 18px; }
  .ws-sidebar-bottom { padding: 20px 18px 24px; }
  .ws-mcp-indicator { justify-content: flex-start; padding: 0 10px; border: 1px solid var(--ws-line); }
  .ws-menu-toggle { display: block; }
  .ws-topbar { min-height: 74px; padding: 13px 18px; }
  .ws-topbar h1 { font-size: 18px; }
  .ws-global-search { display: none; }
  .ws-add-save { width: 40px; height: 40px; min-height: 40px; padding: 0; font-size: 0; }
  .ws-add-save span { font-size: 20px; }
  .ws-avatar { width: 40px; height: 40px; flex-basis: 40px; }
  .ws-view { padding: 30px 18px 80px; }
  .ws-page-header { display: block; margin-bottom: 26px; }
  .ws-page-header h2 { font-size: clamp(35px, 12vw, 52px); }
  .ws-page-header-copy { margin-top: 16px; }
  .ws-page-header-actions { margin-top: 18px; }
  .ws-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ws-stat:nth-child(2) { border-right: 0; }
  .ws-stat:nth-child(-n+2) { border-bottom: 1px solid var(--ws-line); }
  .ws-two-column { grid-template-columns: minmax(0, 1fr); }
  .ws-section-body { padding: 14px; }
  .ws-date-strip { gap: 4px; }
  .ws-date-button { min-height: 60px; padding: 6px; }
  .ws-date-name { font-size: 8px; }
  .ws-date-number { font-size: 16px; }
  .ws-date-count { font-size: 8px; }
  .ws-task-row { grid-template-columns: 26px minmax(0, 1fr); padding: 3px 0; }
  .ws-task-controls { grid-column: 2; padding-bottom: 9px; }
  .ws-task-controls input { width: 116px; }
  .ws-task-quickadd { flex-wrap: wrap; }
  .ws-task-quickadd input { flex-basis: 100%; }
  .ws-calendar-toolbar { align-items: flex-start; }
  .ws-calendar-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ws-calendar-day { min-height: 145px; }
  .ws-calendar-day:nth-child(7) { grid-column: 1; }
  .ws-library-toolbar { display: block; }
  .ws-library-search { width: 100%; }
  .ws-filter-pills { margin-top: 12px; }
  .ws-project-grid { grid-template-columns: minmax(0, 1fr); }
  .ws-project-hero { grid-template-columns: minmax(0, 1fr); }
  .ws-project-source { max-height: 260px; }
  .ws-project-source img { min-height: 0; aspect-ratio: 16 / 8; }
  .ws-project-source-fallback { min-height: 160px; }
  .ws-project-right { display: block; }
  .ws-project-right > .ws-section + .ws-section { margin-top: 24px; }
  .ws-chat-panel { position: static; }
  .ws-project-heading { gap: 12px; margin-bottom: 18px; }
  .ws-project-heading h2 { font-size: clamp(30px, 10vw, 46px); }
  .ws-project-heading-side > p { font-size: 12px; }
  .ws-video-workbench { grid-template-columns: minmax(0, 1fr); }
  .ws-video-panel { grid-row: auto; }
  .ws-video-stage,
  .ws-video-stage > img,
  .ws-video-stage > .ws-project-source-fallback,
  .ws-video-stage > .ws-project-video,
  .ws-video-stage > .ws-project-embed { min-height: 0; aspect-ratio: 9 / 12; }
  .ws-understanding-body { padding: 19px 16px 18px; }
  .ws-live-chat-body { padding: 15px 16px 17px; }
  /* On stacked mobile, the chat column scrolls away, so expose the pill again. */
  .ws-project-pill[data-tab="chat"] { display: inline-flex; }
  .ws-live-chat-panel .ws-chat-messages { max-height: 260px; }
  .ws-processing-mini-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ws-project-tabs { margin-bottom: 18px; }
  .ws-project-tab-intro { display: none; }
  .ws-project-tab { min-height: 42px; padding-inline: 8px; font-size: 9px; }
  .ws-project-overview-grid { grid-template-columns: minmax(0, 1fr); }
  .ws-overview-lead { grid-row: auto; }
  .ws-overview-items { grid-template-columns: minmax(0, 1fr); }
  .ws-evidence-grid-compact { grid-template-columns: minmax(0, 1fr); }
  .ws-next-move { display: block; }
  .ws-next-move-action { display: block; margin-top: 13px; }
  .ws-context-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ws-context-controls { flex-wrap: wrap; }
  .ws-context-controls .ws-button { margin-left: 0; flex: 1 0 100%; }
  .ws-add-fact { grid-template-columns: minmax(0, 1fr); }
  .ws-key-row { grid-template-columns: minmax(0, 1fr) auto; padding: 10px 0; }
  .ws-key-state { grid-column: 1; }
  .ws-key-row .ws-icon-button { grid-column: 2; grid-row: 1 / span 2; }
  .ws-auth-card { padding: 30px 22px; }
  .ws-auth-card h1 { font-size: clamp(37px, 12vw, 58px); }
  .ws-input-action { display: grid; }
  .ws-input-action .ws-button { width: 100%; }
  .ws-save-input-row { display: grid; }
  .ws-save-input-row .ws-button { width: 100%; }
}

@media (max-width: 420px) {
  .ws-topbar-title { gap: 9px; }
  .ws-breadcrumb { font-size: 8px; }
  .ws-topbar h1 { font-size: 17px; }
  .ws-topbar-actions { gap: 6px; }
  .ws-view { padding-inline: 14px; }
  .ws-stat { padding-inline: 14px; }
  .ws-stat-label { font-size: 9px; }
  .ws-date-name { letter-spacing: .04em; }
  .ws-date-button { min-height: 56px; }
  .ws-date-number { font-size: 14px; }
  .ws-context-options { grid-template-columns: minmax(0, 1fr); }
  .ws-project-intro { padding: 22px 18px; }
  .ws-project-tab { letter-spacing: .04em; }
  .ws-workbench-head { padding-inline: 13px; }
  .ws-video-meta { padding-inline: 13px; }
  .ws-video-processing { right: 11px; bottom: 11px; left: 11px; }
  .ws-processing-compact { padding-inline: 13px; }
  .ws-processing-strip-head { align-items: flex-start; flex-direction: column; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .001ms !important; }
}
