/* Layout tokens only. colors live in dew-theme.css */
:root,
[data-theme="light"],
[data-theme="dark"] {
  --radius: 14px;
  --radius-lg: 16px;
  --transition: 0.25s ease;
  --anim-fast: 150ms;
  --anim-base: 280ms;
  --anim-slow: 400ms;
  --sidebar-w-collapsed: 56px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  transition: background-color var(--transition), color var(--transition);
}
body.splash-lock { overflow: hidden; }

/* Theme toggle */
.theme-toggle {
  flex-shrink: 0;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  color: var(--dew-text-secondary);
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.theme-toggle:hover {
  background: var(--accent-bg);
  border-color: var(--accent-soft);
  transform: scale(1.04);
}
.theme-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Login page theme toggle — top-right, subtle moon glow pulse */
.login-theme-toggle {
  position: absolute;
  top: clamp(20px, 3vh, 32px);
  right: clamp(20px, 3vw, 32px);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--dew-surface) 82%, transparent);
  border: 1px solid color-mix(in srgb, var(--dew-border) 70%, transparent);
  backdrop-filter: blur(8px);
  animation: login-theme-enter 0.8s ease 0.4s both;
}

.login-theme-toggle .theme-toggle-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.login-theme-toggle .theme-moon-icon {
  color: var(--dew-text-secondary);
  animation: moon-glow-pulse 4s ease-in-out infinite;
}

.login-theme-toggle.theme-is-dark .theme-moon-icon {
  animation: none;
}

.login-theme-toggle .theme-sun-icon {
  color: #e8a838;
}

.login-theme-toggle:hover {
  transform: scale(1.06);
  border-color: var(--dew-brand-soft);
}

@keyframes login-theme-enter {
  from {
    opacity: 0;
    transform: scale(0.92);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes moon-glow-pulse {
  0%, 100% {
    opacity: 0.55;
    filter: drop-shadow(0 0 0 transparent);
  }
  50% {
    opacity: 1;
    filter: drop-shadow(0 0 6px rgba(111, 184, 172, 0.55));
  }
}

/* SE Labs splash — warm cream + teal, subtle intro */
.lion-splash {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--splash-bg);
  opacity: 1;
  transition: opacity 0.85s ease;
  overflow: hidden;
}
.lion-splash::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 75% 65% at 50% 42%,
    var(--splash-glow) 0%,
    transparent 68%
  );
  pointer-events: none;
  animation: splash-glow-breathe 4s ease-in-out infinite;
}
.lion-splash-fade { opacity: 0; pointer-events: none; }
.lion-splash-inner {
  position: relative;
  text-align: center;
  padding: 32px;
  animation: splash-rise 1s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.lion-loader {
  width: 88px;
  height: 88px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  box-shadow: var(--dew-shadow-card);
  animation: splash-logo-breathe 2.8s ease-in-out infinite;
}
.lion-title {
  margin: 0 0 6px;
  font-size: 26px;
  font-weight: 800;
  color: var(--dew-text);
  letter-spacing: -0.03em;
}
.lion-tagline {
  color: var(--dew-text-secondary);
  margin: 0;
  font-size: 14px;
  letter-spacing: 0.02em;
  animation: splash-tagline-fade 1.2s ease 0.35s both;
}
@keyframes splash-glow-breathe {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.9; transform: scale(1.02); }
}
@keyframes splash-logo-breathe {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-3px) scale(1.015); }
}
@keyframes splash-tagline-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes splash-rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .lion-splash::before,
  .lion-loader,
  .lion-splash-inner,
  .lion-tagline {
    animation: none;
  }
  .lion-splash-inner { opacity: 1; transform: none; }
}

/* Shared Dew loading and feedback surfaces */
.app-loading {
  position: fixed;
  inset: 0;
  z-index: 180;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--dew-bg) 78%, transparent);
  backdrop-filter: blur(4px);
}
.app-loading-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 22px;
  color: var(--dew-text);
  border: 1px solid var(--dew-border);
  box-shadow: var(--dew-shadow-popover);
}
.app-loading-message {
  white-space: nowrap;
  font-size: 0.9375rem;
  line-height: 1.4;
}
.dew-status-host {
  margin: 0 26px 16px;
}
.dew-status-host fw-inline-message {
  width: 100%;
}
.dew-status-host .dew-orbit-spinner {
  display: inline-block;
  vertical-align: middle;
  margin-right: 8px;
}
fw-inline-message .dew-orbit-spinner {
  display: inline-block;
  vertical-align: middle;
  margin-right: 8px;
}
.dew-loading-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 120px;
  padding: 24px;
  border: 1px solid var(--dew-border);
  border-radius: var(--dew-radius-lg);
  background: var(--dew-surface);
}
.dew-skeleton-card {
  display: grid;
  gap: 14px;
  margin: 0 26px 20px;
  padding: 24px;
  border: 1px solid var(--dew-border);
  box-shadow: var(--dew-shadow-island);
}
.dew-skeleton-loading-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 4px;
}

/* Login — full-screen video background, centered card */
.login-page {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  background: var(--dew-bg);
  overflow: hidden;
  isolation: isolate;
}

.login-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.login-bg-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
  animation: login-video-drift 24s ease-in-out infinite alternate;
}

@keyframes login-video-drift {
  from {
    transform: scale(1.03);
  }
  to {
    transform: scale(1.08);
  }
}

.login-bg-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(253, 252, 250, 0.78) 0%, rgba(253, 252, 250, 0.62) 50%, rgba(227, 239, 236, 0.52) 100%),
    radial-gradient(circle at 50% 40%, rgba(111, 184, 172, 0.18), transparent 55%);
  pointer-events: none;
}

[data-theme="dark"] .login-bg-overlay {
  background:
    linear-gradient(135deg, rgba(26, 36, 34, 0.82) 0%, rgba(26, 36, 34, 0.68) 50%, rgba(46, 137, 123, 0.28) 100%),
    radial-gradient(circle at 50% 40%, rgba(111, 184, 172, 0.14), transparent 55%);
}

.login-page-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 400px;
  animation: login-rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes login-rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-card {
  width: 100%;
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(43, 41, 38, 0.06);
  padding: 12px 8px 16px;
}

.login-card-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0;
}

.login-brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: contain;
  margin-bottom: 24px;
  animation: login-logo-enter 0.65s ease 0.1s both;
}

@keyframes login-logo-enter {
  from {
    opacity: 0;
    transform: scale(0.92);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.login-card-head h1 {
  margin: 0;
  font-size: clamp(24px, 2.4vw, 26px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--dew-text);
}

.login-card-head .muted {
  margin: 10px 0 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--dew-text-secondary);
  max-width: 340px;
}

.login-card-head .muted[hidden] {
  display: none;
}

.login-google-btn-wrap {
  position: relative;
  margin-top: 32px;
  animation: login-field-enter 0.55s ease 0.22s both;
}

@keyframes login-field-enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-google-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  pointer-events: none;
}

.login-google-btn-wrap fw-button.login-google-btn {
  display: block;
  width: 100%;
}

.login-google-btn-wrap fw-button.login-google-btn::part(native) {
  width: 100%;
  min-height: 48px;
  justify-content: center;
  padding-left: 48px;
  background: var(--dew-text);
  color: #fff;
  border: none;
  border-radius: 999px;
  font-weight: 600;
  transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.login-google-btn-wrap fw-button.login-google-btn:hover::part(native) {
  background: #3d3a36;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(43, 41, 38, 0.18);
}

.login-card form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 4px;
}

.login-form fw-input {
  animation: login-field-enter 0.55s ease both;
  transition: transform 0.2s ease;
}

.login-form fw-input:nth-child(1) {
  animation-delay: 0.28s;
}

.login-form fw-input:nth-child(2) {
  animation-delay: 0.38s;
}

.login-form fw-input:focus-within {
  transform: translateY(-1px);
}

.login-form fw-input::part(input) {
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.login-form fw-input:focus-within::part(input) {
  border-color: var(--dew-brand);
  box-shadow: 0 0 0 3px rgba(46, 137, 123, 0.14);
}

.login-form fw-button[color="primary"] {
  animation: login-field-enter 0.55s ease 0.48s both;
}

.login-form fw-button[color="primary"]::part(native) {
  min-height: 46px;
  border-radius: 999px;
  font-weight: 600;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.login-form fw-button[color="primary"]:hover::part(native) {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(46, 137, 123, 0.28);
}

.login-form fw-button[color="primary"]:active::part(native) {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(46, 137, 123, 0.2);
}

.login-hint {
  margin-top: 20px;
  font-size: 13px;
  animation: login-field-enter 0.55s ease 0.58s both;
}

.login-hint summary {
  cursor: pointer;
  color: var(--dew-brand);
  font-weight: 600;
  transition: color 0.15s ease;
}

.login-hint summary:hover {
  color: var(--dew-brand-hover);
}

.login-hint ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

.login-hint code {
  font-size: 12px;
  background: rgba(46, 137, 123, 0.08);
  padding: 1px 5px;
  border-radius: 4px;
}

.or-divider {
  text-align: center;
  margin: 20px 0 16px;
  font-size: 13px;
  animation: login-field-enter 0.5s ease 0.2s both;
}

#login-or-divider[hidden],
.or-divider[hidden] {
  display: none;
}

#login-error,
#signin-error {
  animation: login-field-enter 0.4s ease both;
}

@media (prefers-reduced-motion: reduce) {
  .login-bg-video {
    animation: none;
    transform: scale(1.03);
  }

  .login-bg-overlay {
    background: linear-gradient(160deg, #1f2b28 0%, var(--dew-brand) 100%);
  }

  [data-theme="light"] .login-bg-overlay {
    background:
      linear-gradient(135deg, rgba(253, 252, 250, 0.78) 0%, rgba(227, 239, 236, 0.52) 100%);
  }

  .login-theme-toggle,
  .login-theme-toggle .theme-moon-icon,
  .login-brand-logo {
    animation: none;
  }

  .login-page-inner,
  .login-google-btn-wrap,
  .login-form fw-input,
  .login-form fw-button,
  .login-hint,
  .or-divider {
    animation: none;
  }

  .login-form fw-input:focus-within,
  .login-form fw-button[color="primary"]:hover::part(native),
  .login-google-btn-wrap fw-button.login-google-btn:hover::part(native) {
    transform: none;
    box-shadow: none;
  }
}

/* App shell + sidebar */
.app-shell {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--dew-sidebar-bg);
  border-right: none;
  display: flex;
  flex-direction: column;
  padding: 26px 0 18px;
  position: sticky;
  top: 0;
  height: 100dvh;
  max-height: 100dvh;
  min-height: 0;
  align-self: flex-start;
  overflow: hidden;
  box-shadow: none;
  transition: width 280ms ease, background var(--transition);
}
.sidebar-inner {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  padding: 0 20px 24px;
  min-height: 36px;
  overflow: visible;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  flex: 1;
  order: 1;
  font-weight: 800;
  font-size: 19px;
  line-height: 1.05;
  color: var(--dew-text);
  letter-spacing: -0.03em;
  overflow: hidden;
}
.sidebar-brand-logo {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  object-fit: contain;
  display: block;
}
.sidebar-brand-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--dew-brand);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  box-shadow: none;
}
.sidebar-brand-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 1px;
}
.sidebar-brand-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 1;
  max-width: 200px;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.03em;
  transition: opacity 250ms ease, max-width 250ms ease;
}
fw-button.sidebar-collapse {
  position: static;
  flex-shrink: 0;
  order: 2;
  width: 32px;
  height: 32px;
  min-width: 32px;
  padding: 0;
  border-radius: 8px;
  --fw-button-min-width: 32px;
  --fw-button-min-height: 32px;
  --fw-button-padding-start: 0;
  --fw-button-padding-end: 0;
  --fw-button-background-color: transparent;
  --fw-button-border: none;
  --fw-button-color: var(--dew-text-secondary);
  --fw-button-box-shadow: none;
  --fw-button-hover-background-color: var(--dew-surface-subtle);
  --fw-button-hover-border-color: transparent;
  --fw-button-hover-color: var(--dew-text);
  --color-fill-surface: transparent;
  --shadow-xs: none;
}
fw-button.sidebar-collapse:hover {
  --fw-button-background-color: var(--dew-surface-subtle);
  --fw-button-border: 1px solid var(--dew-input-border);
  --fw-button-color: var(--dew-text);
  --color-fill-surface: var(--dew-surface-subtle);
  --color-boundary-border-mildest: var(--dew-input-border);
  --color-text-primary: var(--dew-text);
}
fw-button.sidebar-collapse:focus-visible {
  outline: 2px solid var(--dew-brand);
  outline-offset: 2px;
}
.sidebar-collapse-glyph {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  color: inherit;
  pointer-events: none;
}
.sidebar-close {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: var(--muted);
  padding: 0 4px;
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 12px;
  margin: 0;
  border-radius: 12px;
  background: #ece6db;
  border: none;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  overflow: hidden;
  transition: background var(--transition);
}
.sidebar-user:hover {
  background: #e5ded1;
}
.sidebar-user:focus-visible {
  outline: 2px solid var(--dew-brand);
  outline-offset: 2px;
}
[data-theme="dark"] .sidebar-user {
  background: color-mix(in srgb, var(--dew-surface-subtle) 88%, var(--dew-brand) 12%);
}
[data-theme="dark"] .sidebar-user:hover {
  background: color-mix(in srgb, var(--dew-surface-subtle) 78%, var(--dew-brand) 22%);
}
.sidebar-user-avatar {
  flex-shrink: 0;
  display: flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  background: #ddd4c4;
  color: #57514a;
  font-weight: 700;
  font-size: 12px;
  border-radius: 50%;
  border: none;
}
.sidebar-user-text {
  min-width: 0;
  flex: 1;
  overflow: hidden;
  transition: opacity 250ms ease, max-width 250ms ease;
  max-width: 200px;
  opacity: 1;
}
.sidebar-user-name {
  display: block;
  font-weight: 600;
  font-size: 13.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--dew-text);
}
.sidebar-user-role {
  display: block;
  font-size: 11.5px;
  color: #6f6759;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user-chevron {
  flex-shrink: 0;
  color: #7c7466;
  font-size: 12px;
  line-height: 1;
  transition: transform 150ms ease;
}
.sidebar-user[aria-expanded="true"] .sidebar-user-chevron {
  transform: rotate(180deg);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0 12px;
  scrollbar-gutter: stable;
}
.sidebar-nav-divider {
  height: 1px;
  background: #e5dfd2;
  margin: 12px 14px;
  flex-shrink: 0;
}
.nav-grp {
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--dew-text-muted);
  font-weight: 700;
  padding: 12px 12px 5px;
}
.nav-grp--rollup[hidden] {
  display: none;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  background: none;
  border: none;
  padding: 11px 14px;
  border-radius: 11px;
  font-size: 14.5px;
  font-weight: 500;
  color: #57514a;
  min-height: 44px;
  transition: background var(--transition), color var(--transition), border-color var(--transition), padding 250ms ease;
  border: 1px solid transparent;
  overflow: hidden;
  white-space: nowrap;
}
.nav-icon {
  flex-shrink: 0;
  width: 18px;
  text-align: center;
  color: #7c7466;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.nav-icon svg {
  width: 18px;
  height: 18px;
  display: block;
  color: #7c7466;
}
.nav-item.active .nav-icon svg,
fw-button.nav-item.active .nav-icon svg {
  color: var(--dew-text);
}
.nav-icon-text {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  font-size: 14px;
  color: #7c7466;
  line-height: 1;
}
.nav-item.active .nav-icon,
fw-button.nav-item.active .nav-icon {
  --fw-icon-color: var(--dew-text);
}
.nav-item.active .nav-icon-text,
fw-button.nav-item.active .nav-icon-text {
  color: var(--dew-text);
}
.sidebar-history-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  --fw-icon-color: var(--dew-text-muted);
}
.nav-label {
  overflow: hidden;
  opacity: 1;
  max-width: 180px;
  transition: opacity 250ms ease, max-width 250ms ease;
}
.nav-item:hover {
  background: #ebe5da;
  border-color: transparent;
}
[data-theme="dark"] .nav-item:hover {
  background: var(--dew-surface-subtle);
}
.nav-item.active {
  background: #e5ded1;
  color: var(--dew-text);
  border-color: transparent;
  font-weight: 600;
}
[data-theme="dark"] .nav-item.active {
  background: color-mix(in srgb, var(--dew-brand) 16%, var(--dew-surface-subtle));
}
.sidebar-history,
.sidebar-recent-work {
  flex: 1;
  padding: 16px 12px 8px;
  min-height: 0;
  min-width: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-gutter: stable;
}
.sidebar-history-list li {
  list-style: none;
  margin: 0 0 4px;
  padding: 0;
  min-width: 0;
}
.sidebar-recent-section {
  margin-bottom: 14px;
}
.sidebar-recent-subtitle {
  margin: 0 0 6px;
  padding: 0 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.sidebar-history-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin: 0 0 8px;
  padding: 0 8px;
  overflow: hidden;
}
.sidebar-history-label {
  overflow: hidden;
  opacity: 1;
  max-width: 120px;
  transition: opacity 250ms ease, max-width 250ms ease;
}
.sidebar-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.sidebar-history-empty {
  font-size: 12px;
  padding: 7px 8px;
  margin: 0;
  border: 1px solid var(--dew-border);
  border-radius: 7px;
  background: color-mix(in srgb, var(--dew-surface) 55%, transparent);
}
.sidebar-history-sync {
  font-size: 12px;
  padding: 0 8px 8px;
  margin: 0;
  font-style: italic;
}
.sidebar-history-item,
fw-button.sidebar-history-item {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  text-align: left;
  background: var(--surface-elevated);
  border: 1px solid var(--border-soft);
  padding: 8px 10px;
  border-radius: var(--radius);
  font-size: 13px;
  gap: 2px;
  margin-bottom: 0;
  overflow: hidden;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
  --fw-button-min-width: 0;
  --fw-button-padding: 0;
}
.sidebar-history-item:hover,
fw-button.sidebar-history-item:hover {
  background: var(--surface-muted);
  border-color: var(--accent-soft);
  box-shadow: var(--shadow-sm);
}
.sidebar-history-item.active,
fw-button.sidebar-history-item.active {
  background: var(--accent-bg);
  border-color: var(--accent-soft);
}
.hist-title {
  display: block;
  width: 100%;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.hist-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 8px;
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
}
.hist-kind {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.85;
}
.hist-score {
  font-weight: 600;
  color: var(--accent);
}
.sidebar-foot {
  flex-shrink: 0;
  padding: 14px 14px 0;
  border-top: none;
  margin-top: auto;
  position: relative;
}
.user-menu--sidebar {
  position: relative;
  width: 100%;
}
.user-menu-panel--sidebar {
  position: fixed;
  left: var(--sidebar-w);
  bottom: 18px;
  top: auto;
  right: auto;
  min-width: 280px;
  max-height: min(420px, calc(100dvh - 36px));
  overflow-y: auto;
  z-index: 400;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(43, 41, 38, 0.14);
}
.user-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 350;
  background: transparent;
}
.sidebar-collapsed ~ .user-menu-backdrop + .app-main .user-menu-panel--sidebar,
.sidebar-collapsed ~ .app-main .user-menu-panel--sidebar {
  left: var(--sidebar-w-collapsed);
}
.launch-kpi-card[data-kpi-nav] {
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.launch-kpi-card[data-kpi-nav]:hover {
  border-color: #d8d0c4;
  box-shadow: 0 2px 8px rgba(43, 41, 38, 0.06);
}
.launch-kpi-card[data-kpi-nav]:focus-visible {
  outline: 2px solid var(--dew-brand);
  outline-offset: 2px;
}
.feedback-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: min(420px, 90vw);
}
.feedback-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}
.sidebar-logout {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-start;
  overflow: hidden;
}

/* Collapsed sidebar (desktop). icon rail only */
.sidebar-collapsed {
  width: var(--sidebar-w-collapsed);
  overflow: hidden;
  padding: 12px 0;
}
.sidebar-collapsed .sidebar-head {
  flex-direction: column;
  align-items: center;
  padding: 8px 0;
  gap: 8px;
  min-width: 0;
  overflow: visible;
}
.sidebar-collapsed .sidebar-brand {
  order: 0;
  flex: 0 0 auto;
  justify-content: center;
  width: 100%;
  min-width: 0;
  overflow: visible;
}
.sidebar-collapsed .sidebar-brand-copy {
  display: none;
}
.sidebar-collapsed .sidebar-brand-logo {
  width: 32px;
  height: 32px;
  margin: 0 auto;
}
.sidebar-collapsed fw-button.sidebar-collapse {
  order: 1;
  align-self: center;
  width: 32px;
  margin: 0;
}
@media (min-width: 769px) {
  .sidebar-collapsed .sidebar-history,
  .sidebar-collapsed .sidebar-recent-work,
  .sidebar-is-collapsed .sidebar-history,
  .sidebar-is-collapsed .sidebar-recent-work {
    display: none !important;
  }
}
.sidebar-collapsed .nav-label,
.sidebar-collapsed .sidebar-user-text,
.sidebar-collapsed .sidebar-user-chevron {
  display: none;
}
.sidebar-collapsed .sidebar-brand-text,
.sidebar-collapsed .nav-grp,
.sidebar-collapsed .sidebar-history-label,
.sidebar-collapsed .sidebar-feedback .nav-label {
  opacity: 0;
  max-width: 0;
  min-width: 0;
  width: 0;
  padding: 0;
  margin: 0;
  overflow: hidden;
  flex-shrink: 0;
  pointer-events: none;
}
.sidebar-collapsed .sidebar-nav {
  align-items: center;
  padding: 4px 12px;
  gap: 4px;
}
.sidebar-collapsed fw-button.nav-item ::slotted([slot="before-label"]),
.sidebar-collapsed fw-button.nav-item [slot="before-label"] {
  margin: 0;
}
.sidebar-collapsed fw-button.nav-item .nav-icon {
  margin: 0;
}
.sidebar-collapsed .nav-item,
.sidebar-collapsed fw-button.nav-item {
  justify-content: center;
  align-items: center;
  width: 32px;
  min-width: 32px;
  max-width: 32px;
  height: 32px;
  min-height: 32px;
  margin: 0 auto;
  padding: 0;
  gap: 0;
  text-align: center;
  --nav-btn-justify: center;
  --fw-button-min-width: 32px;
  --fw-button-min-height: 32px;
  --fw-button-padding-start: 0;
  --fw-button-padding-end: 0;
  --fw-button-label-vertical-padding: 0;
  border-radius: 10px;
}
.sidebar-collapsed fw-button.nav-item.active,
.sidebar-collapsed .nav-item.active {
  --fw-button-background-color: var(--dew-brand-tint);
}
.sidebar-collapsed .nav-icon svg {
  color: #7c7466;
}
.sidebar-collapsed fw-button.nav-item.active .nav-icon svg,
.sidebar-collapsed .nav-item.active .nav-icon svg {
  color: var(--dew-primary);
}
.sidebar-collapsed .sidebar-foot {
  padding: 8px 12px 0;
  min-width: 0;
  overflow: visible;
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.sidebar-collapsed .user-menu--sidebar {
  width: auto;
}
.sidebar-collapsed .sidebar-user {
  justify-content: center;
  /* text/chevron siblings collapse to width:0 but keep contributing to the
     flex gap (gap isn't content-dependent) unless it's zeroed here too —
     that was pushing the centered group, and so the avatar, off to the left. */
  align-items: center;
  width: 34px;
  min-width: 34px;
  max-width: 34px;
  height: 34px;
  min-height: 34px;
  padding: 0;
  margin: 0 auto;
  gap: 0;
  background: transparent;
  overflow: visible;
}
.sidebar-collapsed .sidebar-user:hover {
  background: transparent;
}
[data-theme="dark"] .sidebar-collapsed .sidebar-user,
[data-theme="dark"] .sidebar-collapsed .sidebar-user:hover {
  background: transparent;
}
.sidebar-collapsed .sidebar-logout,
.sidebar-collapsed fw-button.sidebar-logout,
.sidebar-collapsed .sidebar-feedback,
.sidebar-collapsed fw-button.sidebar-feedback {
  justify-content: center;
  align-items: center;
  width: 100%;
  height: auto;
  min-height: 40px;
  margin: 0;
  padding: 10px 0;
  gap: 0;
  --fw-button-min-width: 0;
  --fw-button-padding-start: 0;
  --fw-button-padding-end: 0;
  border-radius: 10px;
}

/* Sign-in welcome pulse */
.signin-lion-pulse {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--dew-brand);
}
.signin-lion-pulse-active {
  animation: signin-lion-pulse 0.7s ease-in-out 3;
}
@keyframes signin-lion-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.85; }
}

.app-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--dew-bg);
}
.global-search-input {
  flex: 0 1 300px;
  max-width: 300px;
  min-width: 160px;
  /* match .topbar-action's 44px so the search field isn't visibly shorter
     than "New brief" / "New call analysis" beside it. */
  height: 44px;
  box-sizing: border-box;
  --fw-input-min-height: 44px;
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.topbar-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 44px;
  padding: 0 15px;
  border-radius: 11px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}
.topbar-action--primary {
  border: none;
  background: var(--dew-brand);
  color: #fff;
  box-shadow: 0 1px 2px rgba(43, 41, 38, 0.06);
}
.topbar-action--primary:hover {
  filter: brightness(1.04);
}
.topbar-action--secondary {
  border: 1px solid #cfe3de;
  background: #fff;
  color: #2e897b;
}
.topbar-action--secondary:hover {
  background: #f0f7f5;
}
.topbar-action--icon {
  width: 44px;
  padding: 0;
  justify-content: center;
  border: 1px solid var(--dew-border);
  background: #fff;
  color: var(--dew-text-secondary);
  position: relative;
}
.topbar-action-icon {
  font-size: 15px;
  line-height: 1;
}
.prep-deal-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
}
.prep-deal-new-btn {
  height: 42px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--dew-border);
  background: var(--dew-surface);
  color: var(--dew-text-secondary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.prep-deal-new-btn:hover {
  background: var(--dew-surface-subtle);
}
.prep-account-card {
  margin-top: -4px;
}
.prep-account-chip {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--dew-border);
  background: var(--dew-surface-subtle);
}
.prep-account-chip-mono {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: var(--dew-brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}
.prep-account-chip-body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.prep-account-chip-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--dew-text);
}
.prep-account-chip-domain {
  font-size: 12px;
}
.prep-account-name-block {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--dew-border);
}
.prep-account-name-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--dew-text-secondary);
  margin-bottom: 6px;
}
.prep-account-name-input {
  width: 100%;
  box-sizing: border-box;
}
.pc-crm-domain-group + .pc-crm-domain-group {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--dew-border);
}
.pc-crm-row--domain {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}
.pc-crm-domain-label {
  font-weight: 600;
  color: var(--dew-text-primary);
}
.pc-crm-contacts {
  font-size: 12px;
  word-break: break-all;
}
.pc-crm-row--status {
  border-top: 0;
  padding-top: 0;
}
.launch-activity-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 22px 0;
}
.launch-activity-viewall {
  border: none;
  background: transparent;
  color: var(--dew-brand);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}
.launch-activity-viewall:hover {
  text-decoration: underline;
}
.user-menu {
  position: relative;
}
.user-menu-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}
.user-menu-trigger:hover,
.user-menu-trigger:focus-visible {
  outline: 2px solid var(--dew-brand);
  outline-offset: 2px;
}
.user-menu-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--dew-brand-tint);
  color: var(--dew-brand);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  border: 1px solid var(--dew-border);
  overflow: hidden;
  flex-shrink: 0;
}
.user-menu-avatar.has-image {
  background: transparent;
}
.user-menu-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.user-menu-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 240px;
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  border-radius: 10px;
  box-shadow: var(--dew-shadow-island);
  z-index: 200;
  padding: 8px 0;
}
.user-menu-header {
  padding: 8px 16px 10px;
}
.user-menu-name {
  display: block;
  font-weight: 600;
  font-size: 14px;
  color: var(--dew-text);
}
.user-menu-email {
  display: block;
  font-size: 12px;
  margin-top: 2px;
}
.user-menu-divider {
  height: 1px;
  background: var(--dew-border);
  margin: 4px 0;
}
.user-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: transparent;
  color: var(--dew-text);
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}
.user-menu-item:hover {
  background: var(--dew-surface-subtle);
}
.user-menu-item-icon {
  width: 18px;
  flex-shrink: 0;
  opacity: 0.75;
  text-align: center;
}
.user-menu-item-label {
  flex: 1;
}
.user-menu-chevron {
  opacity: 0.5;
  font-size: 16px;
}
.user-menu-theme-submenu {
  padding: 0 0 4px 28px;
}
.user-menu-theme-option.is-active {
  font-weight: 600;
  color: var(--dew-brand);
}
.user-menu-theme-option.is-active::before {
  content: "✓ ";
}
.user-menu-signout {
  color: var(--dew-text-secondary);
}

/* Profile settings */
.profile-settings-page {
  max-width: 560px;
  margin: 0 auto;
  padding: 8px 0 32px;
}
.profile-settings-head {
  margin-bottom: 20px;
}
.profile-settings-title {
  margin: 0 0 6px;
  font-size: 22px;
}
.profile-settings-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 4px 0;
}
.profile-readonly-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.profile-field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--dew-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.profile-field-value {
  font-size: 15px;
  color: var(--dew-text);
}
.profile-field-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--dew-surface-subtle);
  border: 1px solid var(--dew-border);
  font-size: 13px;
  width: fit-content;
}
.profile-field-hint {
  font-size: 12px;
}
.profile-settings-actions {
  margin-top: 8px;
}
.profile-avatar-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.profile-avatar-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.profile-avatar-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--dew-brand-tint);
  color: var(--dew-brand);
  font-size: 22px;
  font-weight: 700;
  border: 1px solid var(--dew-border);
  overflow: hidden;
  flex-shrink: 0;
}
.profile-avatar-preview.has-image {
  background: transparent;
}
.profile-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.profile-avatar-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.global-search-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 100;
}
.global-search-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 300px;
  max-width: calc(100vw - 16px);
  z-index: 101;
  /* left / top / width are set by global-search.js from the topbar input rect */
}
.global-search-modal-inner {
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  border-radius: 12px;
  box-shadow: var(--dew-shadow-island);
  overflow: hidden;
}
.global-search-palette-input {
  width: 100%;
  border-bottom: 1px solid var(--dew-border);
}
.global-search-results {
  max-height: min(420px, 60vh);
  overflow-y: auto;
  padding: 8px 0;
}
.global-search-group-title {
  margin: 8px 16px 4px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
.global-search-result {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  text-align: left;
  padding: 10px 16px;
  border: none;
  background: transparent;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.global-search-result:hover,
.global-search-result.global-search-result-active {
  background: var(--dew-surface-subtle, rgba(0, 0, 0, 0.04));
}
.global-search-result-label {
  font-weight: 500;
  font-size: 14px;
}
.global-search-result-sub {
  font-size: 12px;
}
.global-search-empty {
  padding: 16px;
  margin: 0;
}

/* Omni search (Freshdesk-inspired) */
.omni-search-panel {
  display: flex;
  flex-direction: column;
}
.omni-search-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--dew-border);
}
.omni-filter-chip {
  border: 1px solid var(--dew-border);
  background: var(--dew-surface);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.omni-filter-chip:hover {
  border-color: var(--accent);
  color: var(--text);
}
.omni-filter-chip.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
[data-theme="dark"] .omni-filter-chip.is-active {
  color: var(--dew-bg, #1a1a1a);
}
.omni-search-results {
  max-height: min(480px, 65vh);
}
.omni-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px 4px;
}
.omni-section-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
.omni-clear-btn {
  border: none;
  background: none;
  color: var(--accent);
  font-size: 12px;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}
.omni-section-list {
  padding: 0 0 8px;
}
.omni-result,
.omni-recent-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 10px 16px;
  border: none;
  background: transparent;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.omni-result:hover,
.omni-result.omni-result-active,
.omni-recent-item:hover {
  background: var(--dew-surface-subtle, rgba(0, 0, 0, 0.04));
}
.omni-result-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--dew-surface-subtle, rgba(0, 0, 0, 0.05));
  color: var(--accent);
}
.omni-result-icon--call { color: var(--dew-green, #2e897b); }
.omni-result-icon--contact { color: #3b82f6; }
.omni-result-icon--deal { color: var(--dew-amber, #d97706); }
.omni-recent-icon {
  flex-shrink: 0;
  color: var(--text-muted);
  display: flex;
}
.omni-result-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.omni-result-label {
  font-weight: 500;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.omni-result-sub {
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.omni-result-type {
  flex-shrink: 0;
  font-size: 11px;
}
.account-list-search,
.account-detail-search {
  margin-bottom: 12px;
  max-width: 420px;
}
.account-detail-no-matches,
.account-list-no-matches {
  margin: 8px 0 0;
}
@media (max-width: 768px) {
  .global-search-input {
    max-width: none;
    flex: 1;
  }
  .main-view-title {
    display: none;
  }
}
.main-view-title {
  display: none;
}
.sidebar-toggle {
  display: none;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 16px;
  transition: background var(--transition), border-color var(--transition);
}
.sidebar-toggle:hover { background: var(--surface-muted); }
.main-content {
  flex: 1;
  max-width: none;
  width: auto;
  margin: 0;
  padding: 0 34px 44px;
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  border: none;
}
.main-topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 20px 0 0;
  margin: 0 0 6px;
  background: transparent;
  border-bottom: none;
  transition: background var(--transition), border-color var(--transition);
  position: relative;
  z-index: 20;
}
.topbar-date {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: row;
  align-items: baseline;
  gap: 0;
  white-space: nowrap;
}
.topbar-day {
  display: none;
}
.topbar-date-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--dew-text-secondary);
  line-height: 1.3;
  white-space: nowrap;
}
.app-shell:has(.account-record) {
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
}

.main-content:has(.account-list-view--compact) {
  max-width: min(1280px, calc(100% - 32px));
}

.main-content:has(.deal-list-view--compact) {
  max-width: min(1600px, calc(100% - 32px));
}

.main-content:has(.call-list-view--compact) {
  max-width: min(1400px, calc(100% - 32px));
}

.main-content:has(.call-record) {
  max-width: min(1400px, calc(100% - 32px));
  padding-top: 0;
}

.main-content:has(.call-record) .main-topbar {
  display: none;
}

.main-content:has(.account-record) {
  max-width: min(1280px, calc(100% - 32px));
  padding-top: 0;
  padding-bottom: 28px;
  flex: 1 1 auto;
  align-self: stretch;
  min-height: 0;
  height: auto;
  max-height: none;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  overflow: hidden;
}

#view-accounts:has(.account-record) {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.view-panel { display: block; }

.main-content:has(.account-record) #view-accounts.view-panel {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.main-content:has(.account-record) #account-panel.account-panel {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.main-content:has(.account-record) .account-record.lifecycle-detail {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
}

.main-content:has(.account-record) .account-command-deck {
  flex: 1 1 auto;
  min-height: 0;
}
.wrap-banner { margin: 0; border-radius: 0; }

.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 90;
}

/* Dashboard. one-pager flow */
.dash-one-pager {
  padding: 0;
  margin-bottom: 0;
}
.dash-one-pager.one-pager {
  padding: 0;
}
.dash-one-pager .card,
.dash-one-pager fw-card {
  margin-bottom: 0;
}
.dash-head {
  margin-bottom: 24px;
}
.dash-section {
  margin-bottom: 26px;
}
.dash-section-title {
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 12px;
}
.dash-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 26px;
}
.dash-stat {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 0;
  padding: 16px 18px;
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  border-radius: 14px;
  box-shadow: var(--dew-shadow-island);
  min-height: 104px;
  justify-content: space-between;
}
.dash-stat:hover { box-shadow: var(--shadow-md); }
.dash-stat-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.005em;
  color: var(--dew-text-secondary);
  margin: 0;
}
.dash-stat-value {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1;
  color: var(--dew-text);
}
.dash-stat-value.dash-stat-text {
  font-size: 16px;
  line-height: 1.3;
}
.dash-stat-denom {
  font-size: 16px;
  font-weight: 500;
  color: var(--muted);
}
.dash-stat-sub {
  font-size: 13px;
  color: var(--muted);
}
.dash-dim-card,
.dash-trend-card,
.dash-distribution-card {
  padding: 20px 22px;
}
.dash-empty {
  text-align: center;
  padding: 48px 28px;
  border: 1px dashed var(--border-soft);
  background: var(--surface-muted);
}
.dash-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  margin-bottom: 12px;
  color: var(--dew-primary);
  border-radius: 10px;
  background: var(--dew-primary-tint);
}
.dash-empty h2 {
  margin: 0 0 8px;
  font-size: 18px;
}
.dash-dim-table th, .dash-dim-table td,
.dash-recent-table th, .dash-recent-table td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.dash-dim-table th, .dash-recent-table th {
  font-weight: 600;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.dash-bar { min-width: 120px; }

/* Recent calls. fluid list */
.dash-recent-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.dash-recent-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-size: 14px;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.dash-recent-item:hover {
  background: var(--surface-muted);
  border-color: var(--accent-soft);
  box-shadow: var(--shadow-md);
}
.dash-recent-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.dash-recent-title {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-recent-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  flex-shrink: 0;
}
.dash-recent-score { font-size: 15px; }
.dash-recent-label { font-size: 12px; }
.dash-recent-when { font-size: 12px; white-space: nowrap; }

.dash-charts-top {
  display: grid;
  grid-template-columns: minmax(0, auto) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  padding: 20px 22px;
  margin-bottom: 0;
}
.dash-gauge-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.dash-gauge { width: 132px; height: 132px; }
.dash-chart-title, .dash-chart-sub {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.dash-chart-sub {
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  margin-bottom: 8px;
}
.dash-radar-wrap { width: 100%; }
.dash-radar-empty { text-align: center; padding: 24px; }

.dash-dim-chart { margin-bottom: 20px; }
.dash-dim-rows { display: flex; flex-direction: column; gap: 12px; }
.dash-dim-row {
  display: grid;
  grid-template-columns: minmax(120px, 28%) 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-soft);
}
.dash-dim-row:last-child { border-bottom: none; }
.dash-dim-label { font-size: 14px; font-weight: 600; }
.dash-dim-bar { min-width: 0; height: 10px; }
.dash-dim-score { min-width: 48px; text-align: right; }

.dash-charts-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}
.dash-trend-section, .dash-distribution-section { margin-bottom: 0; }
.dash-trend-svg {
  width: 100%;
  height: auto;
  display: block;
}
.dash-trend-grid { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 3; }
.dash-trend-axis { fill: var(--muted); font-size: 10px; }
.dash-trend-bar { fill: var(--accent); opacity: 0.85; }
.dash-trend-bar.good { fill: var(--green); }
.dash-trend-bar.ok { fill: var(--amber); }
.dash-trend-bar.weak { fill: var(--danger); }
.dash-trend-label { fill: var(--muted); font-size: 9px; }
.dash-trend-value { font-size: 10px; font-weight: 700; }
.dash-trend-value.good { fill: var(--green); }
.dash-trend-value.ok { fill: var(--amber); }
.dash-trend-value.weak { fill: var(--danger); }

.dash-distribution {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
}
.dash-donut-wrap {
  position: relative;
  width: 120px;
  height: 120px;
  flex-shrink: 0;
}
.dash-donut-svg { width: 100%; height: 100%; }
.dash-donut-track {
  fill: none;
  stroke: var(--border);
  stroke-width: 14;
}
.dash-donut-seg {
  fill: none;
  stroke-width: 14;
  stroke-linecap: butt;
}
.dash-donut-seg.good { stroke: var(--green); }
.dash-donut-seg.ok { stroke: var(--amber); }
.dash-donut-seg.weak { stroke: var(--danger); }
.dash-donut-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.dash-donut-total { font-size: 26px; font-weight: 700; line-height: 1; }
.dash-donut-total-label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.dash-donut-legend { flex: 1; min-width: 160px; display: flex; flex-direction: column; gap: 10px; }
.dash-donut-legend-item {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  gap: 8px;
  align-items: center;
  font-size: 13px;
}
.dash-donut-swatch {
  width: 12px;
  height: 12px;
  border-radius: 3px;
}
.dash-donut-swatch.good { background: var(--green); }
.dash-donut-swatch.ok { background: var(--amber); }
.dash-donut-swatch.weak { background: var(--danger); }
.dash-donut-legend-count { font-weight: 600; }

.dash-recent-compact .dash-recent-table { font-size: 13px; }
.dash-recent-compact .dash-recent-table th,
.dash-recent-compact .dash-recent-table td { padding: 6px 8px; }

/* Form panels. match dashboard chrome */
.form-panel {
  border: 1px solid var(--dew-border);
  border-radius: var(--dew-radius-lg);
  box-shadow: var(--dew-shadow-island);
}
.form-panel h1 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}
.form-panel > .muted:first-of-type {
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.5;
}
.form-panel label { margin-top: 4px; }

.wrap { max-width: 860px; margin: 24px auto; padding: 0 16px; }
.card,
fw-card {
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), box-shadow var(--anim-base), transform var(--anim-base);
  display: block;
}
.card:hover,
fw-card:hover {
  box-shadow: var(--shadow-lift);
  transform: translateY(-3px);
}
[data-theme="dark"] .card,
[data-theme="dark"] fw-card {
  box-shadow: var(--shadow-md);
}
.card h1,
fw-card h1 { font-size: 22px; margin: 0 0 6px; font-weight: 700; letter-spacing: -0.02em; }
.card h2,
fw-card h2 { font-size: 17px; margin: 0 0 14px; font-weight: 600; }
.center { text-align: center; }
.muted { color: var(--muted); }
.opt { color: var(--muted); font-weight: 400; font-size: 12px; }
.field-hint {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}
.field-hint.warn { color: var(--amber); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 16px 0; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 500; }
input {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  background: var(--input-bg);
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
textarea {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  background: var(--input-bg);
  color: var(--text);
  font-family: inherit;
  resize: vertical;
  width: 100%;
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
input:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-bg);
}
button { cursor: pointer; font-size: 14px; transition: background var(--transition), border-color var(--transition), opacity var(--transition), transform var(--transition); }
.link-btn { background: none; border: none; color: var(--dew-primary); padding: 0; }
.link-btn:hover { text-decoration: underline; }
.status {
  padding: 14px 18px;
  border-radius: var(--radius);
  background: var(--accent-bg);
  color: var(--accent);
  margin-bottom: 20px;
  border: 1px solid var(--border-soft);
}
.status.err { background: var(--danger-bg); color: var(--danger); border-color: rgba(196, 74, 74, 0.2); }
.error { color: var(--danger); }

/* Result rendering. one-pager (pre + post) */
.one-pager { padding: 28px 30px; }
.result section { margin: 0 0 32px; }
.result h2 {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  border: none;
  padding: 0;
  margin: 0 0 14px;
}
.result h3 { font-size: 14px; margin: 16px 0 8px; font-weight: 600; }
.result table { width: 100%; border-collapse: collapse; font-size: 14px; }
.result th, .result td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border: none;
  border-bottom: 1px solid var(--border-soft);
}
.result th { background: var(--surface-muted); font-weight: 600; width: 34%; }
.result ul { margin: 8px 0; padding-left: 20px; }
.result li { margin: 6px 0; line-height: 1.55; }
.one-pager-title {
  border: none;
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--text);
}
.head,
.result .head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-soft);
}
.head .sub,
.result .head .sub { color: var(--muted); font-size: 13px; }

.pill { display: inline-block; font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 999px; text-transform: capitalize; }
.pill.a { background: var(--green-bg); color: var(--green); }
details.sources { margin-top: 14px; }
details.sources summary {
  cursor: pointer;
  font-weight: 500;
  color: var(--accent);
  font-size: 14px;
  padding: 6px 0;
  transition: color var(--transition);
}
details.sources summary:hover { color: var(--accent-hover); }
details.sources ul { margin-top: 10px; }

/* Account Snapshot. single table (v6) */
.account-snapshot-wrap {
  margin-bottom: 12px;
}
.account-snapshot {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  table-layout: fixed;
}
.account-snapshot th,
.account-snapshot td {
  text-align: left;
  vertical-align: top;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-soft);
  line-height: 1.35;
  max-height: 2.7em;
  overflow: hidden;
  word-break: break-word;
}
.account-snapshot tr:last-child th,
.account-snapshot tr:last-child td { border-bottom: none; }
.account-snapshot .account-header-row td {
  vertical-align: top;
  max-height: none;
  overflow: visible;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-soft);
}
.account-snapshot .account-company .one-pager-title {
  font-size: 18px;
  line-height: 1.25;
}
.account-snapshot .account-domain {
  font-size: 13px;
  color: var(--muted);
}
.account-snapshot .account-desc {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
}
.account-snapshot .account-attendees .attendee-chips {
  gap: 6px;
}
.account-snapshot .section-label td {
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 700;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 6px 12px;
  border-bottom: 1px solid var(--border-soft);
}
.account-snapshot .col-header th,
.account-snapshot .sub-header th {
  background: var(--surface-muted);
  color: var(--muted);
  font-weight: 600;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.account-snapshot .prep-row-label,
.account-snapshot .fact-label {
  width: 22%;
  background: var(--surface-elevated);
  font-weight: 600;
  font-size: 12px;
  color: var(--muted);
}
.account-snapshot .fact-value { font-weight: 500; }
.account-snapshot .because-cell { color: var(--muted); font-size: 12px; }
.account-snapshot .use-case-row td {
  font-size: 13px;
  font-weight: 500;
}
.account-snapshot .resources-row td { padding: 10px 12px; }
.account-snapshot .demo-link-chips { gap: 6px; }
.account-snapshot .demo-link-chip {
  font-size: 12px;
  padding: 4px 10px;
}
.displacement-badge {
  display: inline-block;
  margin-left: 6px;
  font-size: 10px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  vertical-align: middle;
}
.displacement-badge.displacement-greenfield { background: var(--green-bg); color: var(--green); }
.displacement-badge.displacement-homegrown { background: var(--amber-bg); color: var(--amber); }
.displacement-badge.displacement-entrenched { background: var(--danger-bg); color: var(--danger); }

/* Pre-call + post-call one-pager */
.prep-hero { margin-bottom: 28px; }
.prep-compare {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 14px;
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.prep-compare th,
.prep-compare td {
  text-align: left;
  vertical-align: top;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border-soft);
  border-right: none;
}
.prep-compare tr:last-child th,
.prep-compare tr:last-child td { border-bottom: none; }
.prep-compare thead th {
  background: var(--surface-muted);
  color: var(--muted);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.prep-compare thead th:first-child { background: var(--surface-muted); }
.prep-compare .prep-row-label {
  width: 22%;
  background: var(--surface-elevated);
  font-weight: 600;
  font-size: 13px;
  color: var(--muted);
}
.prep-compare tr.focal-gap-row td,
.prep-compare tr.focal-gap-row th.prep-row-label {
  background: var(--warm-bg);
  border-left: 4px solid var(--warm);
}
.prep-compare tr.focal-gap-row td:last-child {
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.15);
}
.split-blocks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.follow-hint {
  font-size: 13px;
  color: var(--accent);
  font-weight: 500;
}
.action-bullets .action-item { margin: 8px 0; line-height: 1.5; }
.action-rationale { color: var(--muted); font-size: 13px; }
.due-hint { font-size: 12px; }
.crm-block h3 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 16px 0 8px;
}
.prep-bullets { margin: 4px 0 0; padding-left: 20px; }
.prep-bullets li { margin: 4px 0; font-size: 14px; }
.prep-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 4px;
}
.prep-action-block {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  background: var(--surface);
  font-size: 14px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), border-color var(--transition);
}
.prep-action-block:hover { box-shadow: var(--shadow-md); }
.prep-action-block h3 {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.prep-action-wide { grid-column: 1 / -1; }
.prep-lead { margin: 0; font-weight: 500; font-size: 15px; }
.prep-steps { margin: 4px 0 0; padding-left: 22px; }
.prep-steps li { margin: 5px 0; }
.prep-footer {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.prep-attendees h3 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 8px;
}
.prep-attendee-list {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  font-size: 13px;
}
.prep-attendee-list li { margin: 4px 0; }
.prep-att-email { color: var(--accent); }
.prep-att-note { color: var(--muted); }

/* App tabs */
.app-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  padding: 5px;
  background: var(--surface-muted);
  border: none;
  border-radius: var(--radius-lg);
  width: fit-content;
  box-shadow: var(--shadow-sm);
}
.app-tab {
  background: transparent;
  border: none;
  border-radius: 10px;
  padding: 9px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background var(--anim-fast), color var(--anim-fast), box-shadow var(--anim-fast);
}
.app-tab:hover { color: var(--text); background: var(--surface); }
.app-tab.active {
  background: var(--surface);
  color: var(--accent);
  box-shadow: var(--shadow-sm);
}
.tab-panel {
  margin-top: 0;
  transition: opacity var(--anim-base), transform var(--anim-base);
}
.tab-panel.tab-enter {
  opacity: 0;
  transform: translateX(8px);
}
.tab-panel.tab-active {
  opacity: 1;
  transform: translateX(0);
}
.tab-panel.tab-exit {
  opacity: 0;
  transform: translateX(-8px);
}

.dash-tab-panel {
  display: block;
}

.dash-tab-panel[hidden] {
  display: none !important;
}

/* Header strip */
.header-strip {
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-soft);
}
.header-main {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
}
.header-domain, .header-meta {
  font-size: 13px;
  color: var(--muted);
}
.header-desc {
  margin: 8px 0 10px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
}
.attendee-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.attendee-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  padding: 4px 10px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
}
.chip-role { color: var(--muted); }

/* Status dots. semantic left-border accents */
.power-dot, .gap-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px var(--surface);
}
.dot-green { background: var(--green); }
.dot-grey { background: var(--muted); }
.dot-red { background: var(--danger); }
.dot-amber { background: var(--amber); }
.gap-dot.gap-large { background: var(--danger); }
.gap-dot.gap-partial { background: var(--amber); }
.gap-dot.gap-parity { background: var(--green); }
.gap-cell { text-align: center; width: 72px; white-space: nowrap; }
.gap-verdict {
  font-size: 12px;
  font-weight: 600;
  text-transform: capitalize;
  margin-right: 4px;
}

/* v5 must-see strip */
.must-see { margin-bottom: 20px; }
.must-see section { margin-bottom: 22px; }

.incumbent-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  padding: 12px 16px;
  margin-bottom: 18px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  font-size: 14px;
}
.incumbent-row.displacement-greenfield { border-left: 4px solid var(--green); }
.incumbent-row.displacement-homegrown { border-left: 4px solid var(--amber); }
.incumbent-row.displacement-entrenched { border-left: 4px solid var(--danger); }
.incumbent-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.incumbent-name { font-weight: 600; }
.displacement-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.displacement-greenfield .displacement-badge { background: var(--green-bg); color: var(--green); }
.displacement-homegrown .displacement-badge { background: var(--amber-bg, rgba(245, 158, 11, 0.12)); color: var(--amber); }
.displacement-entrenched .displacement-badge { background: var(--danger-bg); color: var(--danger); }

.maturity-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.maturity-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--border-soft);
  background: var(--surface-muted);
}
.maturity-chip.mat-y { border-color: rgba(34, 197, 94, 0.35); background: var(--green-bg); }
.maturity-chip.mat-n { border-color: rgba(196, 74, 74, 0.25); background: var(--danger-bg); }
.maturity-chip.mat-unknown { color: var(--muted); }
.maturity-chip strong { font-weight: 700; }

.use-case-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.use-case-list li {
  margin: 0;
  padding: 6px 12px;
  font-size: 13px;
  border-radius: var(--radius);
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
}

.company-size-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 22px;
  font-size: 14px;
}
.company-size-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.company-size-value { font-weight: 600; }
.est-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* v5 good-to-see collapsible */
details.good-to-see {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}
details.good-to-see > summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  padding: 8px 0;
  list-style: none;
}
details.good-to-see > summary::-webkit-details-marker { display: none; }
details.good-to-see > summary::before {
  content: "▸ ";
  display: inline-block;
  transition: transform var(--transition);
}
details.good-to-see[open] > summary::before { transform: rotate(90deg); }
details.good-to-see[open] > summary { margin-bottom: 12px; }

/* Nested blocks inside good-to-see */
details.good-to-see .more-context,
details.good-to-see .demo-resources,
details.good-to-see .demo-prep-section {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}
details.good-to-see .more-context > summary,
details.good-to-see .demo-prep-section > summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  padding: 4px 0 10px;
  list-style: none;
}
details.good-to-see .more-context > summary::-webkit-details-marker,
details.good-to-see .demo-prep-section > summary::-webkit-details-marker { display: none; }
details.good-to-see .more-context > summary::before,
details.good-to-see .demo-prep-section > summary::before {
  content: "▸ ";
  display: inline-block;
  transition: transform var(--transition);
}
details.good-to-see .more-context[open] > summary::before,
details.good-to-see .demo-prep-section[open] > summary::before { transform: rotate(90deg); }
details.good-to-see .more-context[open] > summary,
details.good-to-see .demo-prep-section[open] > summary { margin-bottom: 8px; }
.demo-resources {
  margin-top: 14px;
}
.demo-resources-label {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.demo-link-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.demo-link-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--accent);
  background: var(--teal-bg);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  text-decoration: none;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.demo-link-chip:hover {
  color: var(--accent-hover);
  background: var(--accent-bg);
  border-color: var(--accent-soft);
}
.demo-link-ext {
  font-size: 11px;
  opacity: 0.75;
}

/* Post-call momentum hero. first focal block after header strip */
.header-strip + .momentum-hero {
  margin-top: 0;
}
.momentum-hero {
  margin-top: 0;
  margin-bottom: 22px;
}
.momentum-hero .outcome-label { font-size: 18px; }
.momentum-hero .outcome-reason { font-size: 15px; }

/* KV table */
.kv-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.kv-table th, .kv-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: top;
}
.kv-table tr:last-child th, .kv-table tr:last-child td { border-bottom: none; }
.kv-table th {
  width: 34%;
  background: var(--surface-muted);
  font-weight: 600;
  font-size: 12px;
  color: var(--muted);
}
.biz-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: start;
}
.workflows-block h3 {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

/* Discovery kit */
.discovery-kit { font-size: 13px; }
.discovery-kit .because-cell { color: var(--muted); font-size: 12px; }

/* Flowchart */
.flowchart { display: flex; flex-direction: column; gap: 12px; }
.flow-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 8px;
  align-items: center;
  font-size: 13px;
}
.flow-cell {
  padding: 12px 14px;
  border: none;
  border-radius: var(--radius);
  background: var(--surface-muted);
  line-height: 1.5;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--anim-base), transform var(--anim-base);
}
.flow-cell.pain { border-left: 4px solid var(--danger); }
.flow-cell.cap { border-left: 4px solid var(--accent); }
.flow-cell.val { border-left: 4px solid var(--green); }
.flow-arrow { color: var(--muted); font-weight: 700; font-size: 16px; text-align: center; opacity: 0.5; }

/* Outcome bar. post-call focal */
.outcome-bar {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 20px;
  align-items: center;
  padding: 18px 22px;
  margin-bottom: 28px;
  border-radius: var(--radius-lg);
  border: none;
  font-size: 15px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}
.outcome-bar::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(245, 158, 11, 0.14) 0%, rgba(251, 113, 133, 0.08) 50%, transparent 100%);
  background-size: 200% 100%;
  pointer-events: none;
  animation: outcome-shift 6s ease-in-out infinite;
}
.outcome-bar.momentum-advancing { border-left: 4px solid var(--green); }
.outcome-bar.momentum-stalled { border-left: 4px solid var(--amber); }
.outcome-bar.momentum-risk { border-left: 4px solid var(--danger); }
.outcome-status {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  grid-row: span 2;
  position: relative;
  z-index: 1;
}
.outcome-arrow { font-size: 22px; line-height: 1; color: var(--warm); }
.outcome-bar.momentum-advancing .outcome-label { color: var(--green); }
.outcome-bar.momentum-stalled .outcome-label { color: var(--amber); }
.outcome-bar.momentum-risk .outcome-label { color: var(--danger); }
.outcome-reason { margin: 0; font-weight: 500; position: relative; z-index: 1; line-height: 1.55; }
.outcome-action {
  margin: 0;
  font-size: 14px;
  grid-column: 2;
  position: relative;
  z-index: 1;
  color: var(--text);
}
.outcome-action strong { color: var(--warm); }

/* Signals row */
.signals-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.signal-col {
  border: none;
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  font-size: 13px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--anim-base), transform var(--anim-base);
}
.signal-col:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.signal-col h3 {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.signal-pains { border-left: 4px solid var(--green); }
.signal-objections { border-left: 4px solid var(--amber); }
.signal-competitors { border-left: 4px solid var(--muted); }
.signal-list { margin: 0; padding-left: 16px; }
.signal-list li { margin: 3px 0; line-height: 1.35; }

/* Next steps. compact table sized to content */
.next-steps-section { margin-top: 0; }
.result .next-steps-table {
  width: auto;
  max-width: 100%;
  table-layout: auto;
  font-size: 12px;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.result .next-steps-table th,
.result .next-steps-table td {
  padding: 5px 10px;
  line-height: 1.35;
  width: auto;
  white-space: normal;
  border-bottom: 1px solid var(--border-soft);
}
.result .next-steps-table thead th {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  background: var(--surface-muted);
  white-space: nowrap;
  padding: 4px 10px;
}
.result .next-steps-table tbody tr:last-child td { border-bottom: none; }
.result .next-steps-table td:first-child { white-space: nowrap; }
.result .next-steps-table .risk-row td { padding-left: 8px; }
.risk-row { background: var(--danger-bg); border-left: 4px solid var(--danger); }
.risk-flag { color: var(--danger); }

.trunc-ellipsis { color: var(--muted); }
.qc-insights-compact { margin-bottom: 12px; }
.qc-details summary { font-weight: 600; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.ghost {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 14px;
  color: var(--text);
}
.ghost:hover {
  background: var(--surface-muted);
  border-color: var(--accent-soft);
}
a { color: var(--accent); }
.sources li { font-size: 13px; word-break: break-word; }
.confidence { background: var(--amber-bg); color: var(--amber); border-radius: 8px; padding: 10px 14px; font-size: 13px; }

/* Post-call */
.tip { font-size: 13px; margin-top: 8px; }
.tip code { font-size: 12px; background: var(--surface-muted); padding: 1px 5px; border-radius: 4px; }
.zoom-banner { background: var(--surface-muted); }
.email-draft {
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-top: 10px;
}
.email-draft pre { white-space: pre-wrap; font-family: inherit; margin: 8px 0 0; font-size: 14px; }
.crm-notes {
  background: var(--accent-bg);
  padding: 14px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border-soft);
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
}

/* Quality coach scorecard. nested inside .result section like pre-call subsections */
.result section .qc-dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 20px;
  align-items: center;
  margin-bottom: 16px;
  padding: 18px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.result section .qc-scorecard { margin-bottom: 14px; }
.result section .qc-scorecard h3 { margin-top: 0; }
.result section .qc-insights { margin-top: 4px; }

.qc-section { margin-bottom: 0; }
.qc-dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 24px;
  align-items: center;
  margin-bottom: 22px;
  padding: 22px;
  background: var(--surface-muted);
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.qc-hero { display: flex; align-items: center; gap: 18px; min-width: 0; }
.qc-gauge {
  position: relative;
  width: 120px;
  height: 120px;
  flex-shrink: 0;
}
.qc-gauge-svg { width: 100%; height: 100%; }
.qc-gauge-track {
  fill: none;
  stroke: var(--border);
  stroke-width: 10;
}
.qc-gauge-fill {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dasharray var(--anim-slow) ease-out;
}
.qc-gauge-fill.good { stroke: var(--green); }
.qc-gauge-fill.ok { stroke: var(--amber); }
.qc-gauge-fill.weak { stroke: var(--danger); }
.qc-gauge-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1px;
  line-height: 1;
}
.qc-gauge-score { font-size: 32px; font-weight: 700; letter-spacing: -0.02em; }
.qc-gauge-denom { font-size: 14px; color: var(--muted); margin-top: 6px; }
.qc-gauge-score.good { color: var(--green); }
.qc-gauge-score.ok { color: var(--amber); }
.qc-gauge-score.weak { color: var(--danger); }
.qc-hero-meta { min-width: 0; }
.qc-overall-label {
  display: inline-block;
  font-size: 15px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--accent-bg);
  color: var(--accent);
}
.qc-hero-hint { font-size: 13px; margin: 10px 0 0; }

.qc-radar-wrap { display: flex; flex-direction: column; align-items: center; min-width: 0; overflow: visible; }
.qc-radar-title {
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.qc-radar {
  width: 100%;
  max-width: 280px;
  height: auto;
  overflow: visible;
}
.qc-radar-grid {
  fill: none;
  stroke: var(--border);
  stroke-width: 1;
}
.qc-radar-axis { stroke: var(--border); stroke-width: 1; }
.qc-radar-label {
  font-size: 7.5px;
  fill: var(--muted);
  pointer-events: none;
}
.qc-radar-data {
  fill: color-mix(in srgb, var(--dew-primary) 16%, transparent);
  stroke: var(--dew-primary);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-dasharray: var(--radar-perimeter, 400);
  stroke-dashoffset: var(--radar-perimeter, 400);
  transition: stroke-dashoffset var(--anim-slow) ease-out, fill var(--anim-slow) ease-out;
}
[data-theme="dark"] .qc-radar-data { fill: color-mix(in srgb, var(--dew-primary) 22%, transparent); }
.anim-ready .qc-radar-data {
  stroke-dashoffset: 0;
}
.qc-radar-dot { fill: var(--dew-primary); }

.qc-scorecard { margin-bottom: 18px; }
.qc-scorecard h3 { margin-top: 0; }
.qc-dim-list { display: flex; flex-direction: column; gap: 8px; }
.qc-dim {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  transition: border-color var(--transition);
}
.qc-dim:hover { border-color: var(--accent-soft); }
.qc-dim-summary {
  display: grid;
  grid-template-columns: minmax(90px, 28%) 1fr auto 14px;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  cursor: pointer;
  list-style: none;
  font-size: 14px;
}
.qc-dim-summary::-webkit-details-marker { display: none; }
.qc-dim-summary::after {
  content: "▸";
  color: var(--muted);
  font-size: 12px;
  margin-left: 4px;
  transition: transform 0.15s ease;
}
.qc-dim[open] .qc-dim-summary::after { transform: rotate(90deg); }
.qc-dim-name { font-weight: 600; }
.qc-dim-bar {
  height: 8px;
  background: var(--surface-muted);
  border-radius: 999px;
  overflow: hidden;
}
.qc-dim-bar-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  min-width: 4px;
}
.qc-dim-bar-fill.good { background: var(--green); }
.qc-dim-bar-fill.ok { background: var(--amber); }
.qc-dim-bar-fill.weak { background: var(--danger); }
.qc-dim-score {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  min-width: 36px;
  text-align: right;
}
.qc-dim-score.good { color: var(--green); }
.qc-dim-score.ok { color: var(--amber); }
.qc-dim-score.weak { color: var(--danger); }
.qc-dim-body {
  padding: 0 12px 12px;
  border-top: 1px solid var(--border-soft);
  background: var(--surface-muted);
}
.qc-dim-feedback { margin: 10px 0 8px; font-size: 14px; }
.qc-dim-evidence {
  margin: 0;
  padding: 10px 12px;
  border-left: 3px solid var(--accent);
  background: var(--surface);
  border-radius: 0 8px 8px 0;
  font-size: 13px;
  color: var(--muted);
}
.qc-ev-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent);
  margin-bottom: 4px;
}

.qc-insights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.qc-insight {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-size: 14px;
  box-shadow: var(--shadow-sm);
}
.qc-insight-weak { border-top: 3px solid var(--danger); background: var(--danger-bg); }

.score.good { color: var(--green); }
.score.ok { color: var(--amber); }
.score.weak { color: var(--danger); }
.qc-insight h4 {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.qc-insight ul { margin: 0; padding-left: 18px; }
.qc-insight li { margin: 4px 0; }
.qc-insight-good { border-top: 3px solid var(--green); background: var(--green-bg); }
.qc-insight-good h4 { color: var(--green); }
.qc-insight-ok { border-top: 3px solid var(--amber); background: var(--amber-bg); }
.qc-insight-ok h4 { color: var(--amber); }
.qc-insight-weak h4 { color: var(--danger); }

.pill.high { background: var(--danger-bg); color: var(--danger); }
.pill.med { background: var(--amber-bg); color: var(--amber); }
.pill.low { background: var(--green-bg); color: var(--green); }

.history { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.history li {
  padding: 12px 14px;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  background: var(--surface-elevated);
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.history li:hover {
  background: var(--surface-muted);
  border-color: var(--accent-soft);
  box-shadow: var(--shadow-md);
}
.history li:first-child { border-top: 1px solid var(--border-soft); }
.history .when { color: var(--muted); font-size: 12px; }

@media (max-width: 900px) {
  .dash-stats { grid-template-columns: repeat(2, 1fr); }
  .dash-charts-top { grid-template-columns: 1fr; justify-items: center; }
  .dash-charts-bottom { grid-template-columns: 1fr; }
  .dash-dim-row { grid-template-columns: 1fr auto; }
  .dash-dim-bar { grid-column: 1 / -1; }
  .dash-recent-item { flex-direction: column; align-items: flex-start; }
  .dash-recent-meta { flex-direction: row; align-items: center; gap: 10px; }
}
@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 100;
    width: var(--sidebar-w) !important;
    transform: translateX(-100%);
    transition: transform 280ms ease;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.08);
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-collapsed .sidebar-history-list {
    display: block;
  }
  .sidebar-collapsed .sidebar-history-empty,
  .sidebar-collapsed .sidebar-history-sync {
    display: block;
  }
  .sidebar-collapsed .sidebar-brand-text,
  .sidebar-collapsed .nav-label,
  .sidebar-collapsed .sidebar-user-text,
  .sidebar-collapsed .sidebar-history-label,
  .sidebar-collapsed .sidebar-history-list,
  .sidebar-collapsed .sidebar-history-empty,
  .sidebar-collapsed .sidebar-history-sync {
    opacity: 1;
    max-width: none;
    min-width: 0;
    width: auto;
    pointer-events: auto;
  }
  .sidebar-collapsed .sidebar-user-avatar { display: none; }
  .sidebar-collapsed .sidebar-history-icon { display: none; }
  .sidebar-collapsed .nav-item { justify-content: center; width: 32px; min-width: 32px; margin: 0 auto; padding: 0; }
  .sidebar-collapsed .sidebar-logout { justify-content: center; padding: 10px 0; }
  .sidebar-backdrop:not([hidden]) { display: block; }
  .sidebar-close { display: block; }
  .sidebar-toggle { display: block; }
  .sidebar-collapse { display: none !important; }
}
@media (max-width: 620px) {
  .grid2, .qc-dashboard, .qc-insights, .dash-stats, .prep-action-grid, .split-blocks, .biz-grid, .signals-grid { grid-template-columns: 1fr; }
  .launch-kpi-grid { grid-template-columns: 1fr; }
  .flow-row { grid-template-columns: 1fr; }
  .flow-arrow { display: none; }
  .outcome-bar { grid-template-columns: 1fr; }
  .outcome-status { grid-row: auto; }
  .outcome-action { grid-column: auto; }
  .prep-action-wide { grid-column: auto; }
  .prep-compare .prep-row-label { width: 28%; font-size: 12px; }
  .qc-hero { flex-direction: column; text-align: center; }
  .qc-dim-summary { grid-template-columns: 1fr auto; }
  .qc-dim-bar { grid-column: 1 / -1; }
  .kv { grid-template-columns: 40% 1fr; }
  .zoom-row { flex-direction: column; align-items: flex-start; }
  .main-content { padding: 16px 12px 32px; }
  .dash-recent-meta { width: 100%; justify-content: space-between; }
}

/* Motion. staggered entrances, dial, radar, flowchart */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes outcome-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
@keyframes flow-reveal {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.anim-root .anim-block {
  opacity: 0;
  transform: translateY(14px);
}
.anim-root.anim-ready .anim-block {
  animation: fade-up var(--anim-base) ease-out forwards;
  animation-delay: var(--anim-delay, 0ms);
}

.anim-root .flow-cell {
  opacity: 0;
}
.anim-root.anim-ready .flow-cell {
  animation: flow-reveal var(--anim-slow) ease-out forwards;
  animation-delay: var(--flow-delay, 0ms);
}

.anim-root .flow-arrow {
  opacity: 0;
}
.anim-root.anim-ready .flow-arrow {
  animation: fade-up var(--anim-fast) ease-out forwards;
  animation-delay: var(--flow-delay, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .card:hover { transform: none; }
  .signal-col:hover { transform: none; }
  .outcome-bar::before { animation: none; }
  .anim-root .anim-block,
  .anim-root .flow-cell,
  .anim-root .flow-arrow {
    opacity: 1;
    transform: none;
    animation: none;
  }
  .signin-lion-pulse-active { animation: none; }
  .sidebar { transition-duration: 0.01ms !important; }
  .sidebar-brand-text,
  .nav-label,
  .sidebar-user-text,
  .sidebar-history-label {
    transition-duration: 0.01ms !important;
  }
}

@media print {
  @page { size: letter; margin: 0.35in 0.4in; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
  :root, [data-theme="dark"] {
    --bg: #fff;
    --surface: #fff;
    --surface-muted: #f5f5f5;
    --text: #111;
    --muted: #444;
    --accent: #6747d4;
    --green: #15803d;
    --amber: #b45309;
    --danger: #991b1b;
    --border-soft: #ddd;
    --warm: #b45309;
  }
  body {
    background: #fff !important;
    background-image: none !important;
    color: #111 !important;
    font-size: 9pt;
    line-height: 1.35;
  }
  .sidebar, .main-topbar, .toolbar, .app-tabs, #prep-form, #postcall-form-view, #postcall-form, #history-section, #zoom-banner, #prep-status, #postcall-status, .wrap-banner, .site-footer, .lion-splash, .theme-toggle { display: none !important; }
  .app-main { margin: 0; }
  .main-content { max-width: none; padding: 0; }
  .card,
  fw-card {
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
    page-break-inside: avoid;
  }
  .card:hover,
  fw-card:hover { transform: none; box-shadow: none; }
  .one-pager { padding: 0 !important; }
  .result section { margin: 0 0 10px; page-break-inside: avoid; }
  .result h2 { font-size: 8pt; margin-bottom: 4px; color: #444 !important; }
  .result table, .prep-compare, .kv-table, .discovery-kit, .next-steps-table { font-size: 8pt; }
  .result th, .result td, .prep-compare th, .prep-compare td { padding: 4px 6px; border-bottom: 1px solid #ddd !important; }
  .prep-bullets li, .signal-list li { font-size: 8pt; margin: 2px 0; }
  .header-strip { margin-bottom: 8px; padding-bottom: 6px; border-bottom: 1px solid #ddd; }
  .one-pager-title { font-size: 14pt; color: #111 !important; }
  .account-snapshot .account-company .one-pager-title { font-size: 11pt; }
  .account-snapshot .account-domain { font-size: 8pt; }
  .account-snapshot .account-desc { font-size: 8pt; }
  .header-desc { font-size: 9pt; margin: 4px 0; }
  .attendee-chip { font-size: 8pt; padding: 2px 6px; border: 1px solid #ddd; background: #f5f5f5; }
  .outcome-bar {
    padding: 8px 10px;
    margin-bottom: 8px;
    font-size: 8pt;
    box-shadow: none;
    border-left: 3px solid #b45309 !important;
    background: #fffbeb !important;
  }
  .outcome-bar::before { display: none; }
  .prep-compare tr.focal-gap-row td,
  .prep-compare tr.focal-gap-row th.prep-row-label {
    background: #fffbeb !important;
    border-left: 3px solid #b45309 !important;
  }
  .flow-row { font-size: 8pt; gap: 4px; }
  .flow-cell { padding: 4px 6px; box-shadow: none; background: #f5f5f5; }
  .signals-grid { gap: 6px; }
  .signal-col { padding: 6px 8px; box-shadow: none; border-left: 3px solid #ddd; }
  .qc-dashboard { padding: 8px; margin-bottom: 8px; grid-template-columns: 1fr 1fr; gap: 8px; background: #f5f5f5; box-shadow: none; }
  .qc-gauge { width: 72px; height: 72px; }
  .qc-gauge-score { font-size: 18px; }
  .qc-radar { max-width: 160px; }
  .qc-radar-data { stroke-dashoffset: 0 !important; fill: color-mix(in srgb, var(--dew-primary) 12%, transparent) !important; }
  .qc-insights { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .qc-insight { padding: 6px 8px; font-size: 8pt; box-shadow: none; }
  .qc-details .qc-dim-body { display: block !important; }
  .qc-dim { break-inside: avoid; }
  .account-snapshot, .account-snapshot th, .account-snapshot td { font-size: 7.5pt; }
  .account-snapshot th, .account-snapshot td { padding: 3px 5px; line-height: 1.25; max-height: none; }
  .account-snapshot .section-label td { font-size: 7pt; padding: 2px 5px; }
  .account-snapshot-wrap { margin-bottom: 4px; page-break-inside: avoid; }
  .account-snapshot .demo-link-chip { font-size: 7pt; padding: 1px 5px; }
  details.sources { display: none !important; }
  .qc-details { display: none !important; }
  .prep-footer { margin-top: 4px; padding-top: 4px; }
  .anim-block, .flow-cell, .flow-arrow { opacity: 1 !important; }
}

/* Site footer */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  background: var(--footer-bg);
  border-top: 1px solid var(--border);
  backdrop-filter: blur(8px);
  font-size: 13px;
  transition: background var(--transition), border-color var(--transition);
}
.site-footer a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}
.site-footer a:hover {
  color: var(--accent);
  text-decoration: underline;
}
.login-page,
.app-shell {
  padding-bottom: 0;
}

/* QC preview page (dev fixture) */
.qc-preview-page {
  min-height: 100vh;
  padding: 24px 20px 40px;
  background: var(--bg);
}
.qc-preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: 960px;
  margin: 0 auto 16px;
}
.qc-preview-card {
  display: block;
  max-width: 960px;
  margin: 0 auto;
  padding: 20px 24px;
  border: 1px solid var(--dew-border);
  border-radius: var(--dew-radius-lg);
  box-shadow: var(--dew-shadow-island);
}

/* About page */
.about-page {
  min-height: 100vh;
  padding-bottom: 52px;
}
.about-header {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 20px 8px;
}
.about-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}
.about-header-top .about-back {
  margin-bottom: 0;
}
.about-back {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}
.about-back:hover { text-decoration: underline; }
.about-kicker {
  font-size: 13px;
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.about-header h1 {
  font-size: 28px;
  margin: 0 0 10px;
  line-height: 1.2;
}
.about-lead {
  font-size: 16px;
  margin: 0;
  line-height: 1.55;
}
.about-main {
  max-width: 720px;
  margin: 0 auto;
  padding: 8px 20px 24px;
}
.about-section h2 {
  font-size: 20px;
  margin: 0 0 12px;
}
.about-section h3,
.about-subhead {
  font-size: 15px;
  margin: 20px 0 8px;
}
.about-section p {
  margin: 0 0 12px;
  font-size: 15px;
}
.about-list {
  margin: 0 0 12px;
  padding-left: 22px;
  font-size: 15px;
}
.about-list li { margin: 6px 0; }
.about-note,
.about-calibration,
.about-demo-path {
  font-size: 14px;
  margin-bottom: 0;
}
.about-steps {
  list-style: none;
  margin: 16px 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.about-steps li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 15px;
}
.about-step-num {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 700;
  font-size: 13px;
  border-radius: 999px;
}
.about-callout {
  margin-top: 20px;
  padding: 16px 18px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  font-size: 14px;
}
.about-callout strong {
  display: block;
  margin-bottom: 12px;
  font-size: 14px;
}
.about-grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.about-grid2 h3 {
  font-size: 14px;
  margin: 0 0 4px;
}
.about-grid2 p { margin: 0; font-size: 13px; }
.about-table-wrap {
  overflow-x: auto;
  margin: 12px 0;
}
.about-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.about-table th,
.about-table td {
  text-align: left;
  padding: 9px 12px;
  border: 1px solid var(--border);
  vertical-align: top;
}
.about-table th {
  background: var(--surface-muted);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}
.about-table code {
  font-size: 12px;
  background: var(--surface-muted);
  padding: 1px 5px;
  border-radius: 4px;
}
.about-cta { margin: 20px 0 0; }
.about-btn {
  display: inline-block;
  text-decoration: none;
}
.about-code-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.about-code-head h2 { margin: 0; }
.about-print-btn {
  font-size: 13px;
  padding: 6px 14px;
  flex-shrink: 0;
}
.about-arch {
  margin: 8px 0 12px;
  padding: 12px 14px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  font-family: ui-monospace, "Cascadia Code", "Segoe UI Mono", monospace;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-x: auto;
}
.about-code-logic .about-callout { margin-top: 10px; }
.about-code-logic .about-callout p { margin: 0; font-size: 13px; }
.about-print-hint { margin-top: 16px; margin-bottom: 0; }
.about-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.about-section-head h2 { margin: 0; }
.about-wireframe {
  margin: 12px 0;
  padding: 14px 16px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  font-family: ui-monospace, "Cascadia Code", "Segoe UI Mono", monospace;
  font-size: 11px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-x: auto;
}

@media print {
  body.print-wireframe-guide * { visibility: hidden; }
  body.print-wireframe-guide #discovery-wireframe,
  body.print-wireframe-guide #discovery-wireframe * { visibility: visible; }
  body.print-wireframe-guide #discovery-wireframe {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0.4in 0.5in;
    border: none;
    box-shadow: none;
    background: #fff;
    color: #111;
    font-size: 10pt;
    line-height: 1.4;
  }
  body.print-wireframe-guide .about-wireframe {
    font-size: 8.5pt;
    padding: 8pt 10pt;
    background: #f8fafc;
    border-color: #e2e8f0;
    page-break-inside: avoid;
  }
  body.print-wireframe-guide .about-print-btn,
  body.print-wireframe-guide .about-print-hint { display: none !important; }

  body.print-code-guide * { visibility: hidden; }
  body.print-code-guide .about-code-logic,
  body.print-code-guide .about-code-logic * { visibility: visible; }
  body.print-code-guide .about-code-logic {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0.4in 0.5in;
    border: none;
    box-shadow: none;
    background: #fff;
    color: #111;
    font-size: 9.5pt;
    line-height: 1.35;
  }
  body.print-code-guide .about-code-logic h2 { font-size: 14pt; margin-bottom: 6pt; }
  body.print-code-guide .about-code-logic h3 { font-size: 10pt; margin: 8pt 0 4pt; }
  body.print-code-guide .about-code-logic p,
  body.print-code-guide .about-code-logic li { font-size: 9pt; margin-bottom: 4pt; }
  body.print-code-guide .about-code-logic .about-list { margin-bottom: 6pt; }
  body.print-code-guide .about-code-logic .about-arch {
    font-size: 8pt;
    padding: 6pt 8pt;
    margin: 4pt 0 6pt;
    background: #f4f4f5;
    border-color: #ddd;
  }
  body.print-code-guide .about-code-logic .about-callout {
    padding: 6pt 8pt;
    margin-top: 4pt;
    background: #f8fafc;
    border-color: #e2e8f0;
    page-break-inside: avoid;
  }
  body.print-code-guide .about-code-logic .about-table {
    font-size: 8pt;
  }
  body.print-code-guide .about-code-logic .about-table th,
  body.print-code-guide .about-code-logic .about-table td {
    padding: 4pt 6pt;
  }
  body.print-code-guide .about-print-btn,
  body.print-code-guide .about-print-hint { display: none !important; }
  @page { margin: 0.45in; size: letter; }
}

@media (max-width: 620px) {
  .about-header { padding: 24px 16px 8px; }
  .about-header h1 { font-size: 24px; }
  .about-main { padding: 8px 16px 24px; }
  .about-grid2 { grid-template-columns: 1fr; }
}

/* SE launchpad */
.launchpad { max-width: 100%; overflow-x: hidden; }
.launchpad--loading .dew-loading-panel,
.manager-view--loading .dew-loading-panel {
  margin-top: 18px;
  min-height: 72px;
}
.launch-skeleton {
  border-radius: 14px;
  background: linear-gradient(
    90deg,
    var(--dew-hairline) 0%,
    color-mix(in srgb, var(--dew-border) 70%, var(--dew-hairline)) 50%,
    var(--dew-hairline) 100%
  );
  background-size: 200% 100%;
  animation: launch-skeleton-shimmer 1.2s ease-in-out infinite;
}
.launch-skeleton--title {
  height: 34px;
  width: min(320px, 72%);
  margin-bottom: 6px;
}
.launch-skeleton--subtitle {
  height: 18px;
  width: min(420px, 88%);
}
.launch-skeleton--kpi { min-height: 104px; }
.launch-kpi-grid--skeleton {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.launch-skeleton--board { min-height: 320px; }
.launch-skeleton--side { min-height: 320px; }
.launch-skeleton--heatmap {
  min-height: 240px;
  margin-bottom: 20px;
}
@keyframes launch-skeleton-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
@media (prefers-reduced-motion: reduce) {
  .launch-skeleton { animation: none; }
}
.launch-hero,
.launch-kpi-grid,
.launch-split.dash-split {
  max-width: 100%;
}
.launch-hero { margin-bottom: 20px; }
.launch-greeting {
  margin: 0 0 6px;
  font-size: 29px;
  font-weight: 700;
  letter-spacing: -0.032em;
  color: var(--dew-text);
}
.launch-sub {
  margin: 0;
  font-size: 14.5px;
  color: var(--dew-text-secondary);
}
.launch-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.launch-kpi-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  min-height: 104px;
  padding: 16px 18px;
  background: var(--dew-surface);
  border: 1px solid var(--dew-border);
  border-radius: 14px;
  box-shadow: var(--dew-shadow-island);
  text-align: left;
  font: inherit;
  color: inherit;
  width: 100%;
}
.launch-kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.launch-kpi-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--dew-text-secondary);
  /* wrap rather than ellipsis-truncate ("Briefs generated") when cards get
     narrow; the KPI cards share a grid row and stretch to equal height. */
  overflow-wrap: break-word;
  min-width: 0;
}
.launch-kpi-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 16px;
  line-height: 1;
}
.launch-kpi-icon.tile-clay { background: var(--dew-clay-tint); color: #b0785b; }
.launch-kpi-icon.tile-teal { background: var(--dew-teal-tint); color: var(--dew-teal); }
.launch-kpi-icon.tile-sand { background: var(--dew-sand-tint); color: #a5883f; }
.launch-activity-icon.tile-teal { background: var(--dew-teal-tint); color: var(--dew-teal); }
.launch-activity-icon.tile-sand { background: var(--dew-sand-tint); color: #a5883f; }
.launch-kpi-foot {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}
.launch-kpi-value {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1;
  color: var(--dew-text);
  font-variant-numeric: tabular-nums;
}
.launch-kpi-value--pending {
  display: inline-flex;
  align-items: center;
  min-width: 2.75rem;
  min-height: 2rem;
}
.launch-kpi-shimmer {
  display: block;
  width: 2.75rem;
  height: 1.75rem;
  border-radius: 8px;
  background: linear-gradient(
    90deg,
    color-mix(in srgb, var(--dew-border) 55%, transparent) 0%,
    color-mix(in srgb, var(--dew-teal) 18%, var(--dew-border)) 50%,
    color-mix(in srgb, var(--dew-border) 55%, transparent) 100%
  );
  background-size: 200% 100%;
  animation: launch-skeleton-shimmer 1.2s ease-in-out infinite;
}
.launch-kpi-value--syncing {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.launch-kpi-syncing {
  font-size: 0.85rem;
  color: var(--dew-text-muted);
  opacity: 0.7;
  animation: launch-kpi-spin 1.4s linear infinite;
}
@keyframes launch-kpi-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.launch-kpi-delta {
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
}
.launch-kpi-delta.good { color: var(--dew-green); }
.launch-kpi-delta.warn { color: var(--dew-red); }
.launch-kpi-delta.muted { color: var(--dew-text-muted); }
/* Launchpad variant of `.dash-split` (base at "Dashboard split layout" below):
   base supplies display:grid + align-items:start; this only widens the right
   rail (380px) and tightens the gap. Keep both in sync intentionally. */
.launch-split.dash-split {
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 16px;
}
.launch-split .dash-split-side {
  border-left: none;
  padding-left: 0;
}
.launch-side .dash-section-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--dew-text);
  margin: 0;
}
.launch-activity-card {
  padding: 0;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid var(--dew-border);
  box-shadow: var(--dew-shadow-island);
}
.launch-activity-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 14px;
}
fw-button.launch-activity-row,
button.launch-activity-row {
  display: block;
  width: 100%;
  --fw-button-min-width: 100%;
  --fw-button-padding: 0;
  margin: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  text-align: left;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
}
fw-button.launch-activity-row:hover,
button.launch-activity-row:hover {
  background: var(--dew-surface-subtle);
}
button.launch-activity-row:focus-visible {
  outline: 2px solid var(--dew-brand);
  outline-offset: -2px;
}
.launch-activity-inner {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 13px 22px;
  border-top: 1px solid var(--border-soft);
  box-sizing: border-box;
}
.launch-activity-row {
  display: block;
  width: 100%;
}
.launch-activity-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 14px;
}
.launch-activity-icon fw-icon {
  --fw-icon-color: currentColor;
}
.launch-activity-body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.launch-activity-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--dew-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.launch-activity-status {
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.launch-activity-when {
  font-size: 11.5px;
  color: var(--dew-text-muted);
  white-space: nowrap;
}
.launch-action-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.launch-action-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  text-align: left;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.launch-action-btn:hover {
  background: var(--surface-muted);
  border-color: var(--accent-soft);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.launch-action-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.launch-action-primary {
  background: var(--warm-bg);
  border-color: rgba(245, 158, 11, 0.35);
}
.launch-action-primary:hover {
  background: var(--warm-bg);
  border-color: var(--warm);
}
.launch-action-primary .launch-action-label { color: var(--text); }
.launch-action-icon { font-size: 28px; line-height: 1; flex-shrink: 0; }
.launch-action-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.launch-action-label { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; }
.launch-action-sub { font-size: 13px; line-height: 1.35; }

.launch-followup-list,
.launch-recent-list {
  padding: 0;
  overflow: hidden;
}
.launch-followup-row,
.launch-recent-row,
fw-button.launch-followup-row,
fw-button.launch-recent-row {
  display: block;
  width: 100%;
  --fw-button-min-width: 100%;
  --fw-button-padding: 0;
  margin: 0;
  border: none;
  border-bottom: 1px solid var(--border-soft);
  background: transparent;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  transition: background var(--transition);
  border-radius: 0;
}
.launch-followup-inner,
.launch-recent-inner {
  display: grid;
  align-items: center;
  gap: 10px 12px;
  width: 100%;
  text-align: left;
  padding: 12px 16px;
}
.launch-recent-inner {
  grid-template-columns: minmax(80px, 1.2fr) auto minmax(72px, auto) minmax(0, 1.5fr) auto;
}
.launch-recent-inner-side {
  grid-template-columns: minmax(80px, 1.2fr) auto minmax(72px, auto) auto;
}
.launch-followup-inner {
  grid-template-columns: 10px minmax(80px, 1.1fr) minmax(0, 2fr) auto;
}
.launch-followup-row:last-child,
.launch-recent-row:last-child { border-bottom: none; }
.launch-followup-row:hover,
.launch-recent-row:hover { background: var(--surface-muted); }
.launch-followup-row:focus-visible,
.launch-recent-row:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.launch-followup-row {
  grid-template-columns: 10px minmax(80px, 1.1fr) minmax(0, 2fr) auto;
}
.launch-followup-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.launch-followup-dot.dot-red { background: var(--danger); }
.launch-followup-dot.dot-amber { background: var(--amber); }
.launch-followup-dot.dot-green { background: var(--green); }
.launch-followup-company { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.launch-followup-action { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.launch-followup-due { font-size: 12px; white-space: nowrap; color: var(--muted); }

.launch-recent-row {
  grid-template-columns: minmax(80px, 1.2fr) auto minmax(72px, auto) minmax(0, 1.5fr) auto;
}
.launch-recent-row:not(fw-button) {
  display: grid;
  align-items: center;
  gap: 10px 12px;
  padding: 12px 16px;
}
.launch-recent-company { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.launch-recent-date { font-size: 12px; white-space: nowrap; }
.launch-recent-momentum {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.launch-recent-momentum.momentum-advancing { color: var(--green); }
.launch-recent-momentum.momentum-stalled { color: var(--muted); }
.launch-recent-momentum.momentum-risk { color: var(--danger); }
.launch-recent-next { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.launch-recent-score { font-size: 13px; white-space: nowrap; }

.launch-nudge-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 16px;
  padding: 16px 20px;
}
.launch-nudge-text { margin: 0; font-size: 15px; flex: 1; min-width: 0; }
.launch-nudge-link { flex-shrink: 0; font-weight: 600; }

.launch-empty { padding: 32px 24px; }
.launch-empty h3 { margin: 0 0 6px; font-size: 16px; }

.coaching-stats,
.manager-stats { margin-bottom: 26px; }

.manager-team-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.manager-filter-banner {
  margin: 12px 0 16px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 2px solid var(--dew-brand);
  background: color-mix(in srgb, var(--dew-brand) 8%, var(--surface));
}
.manager-filter-banner--spine {
  border-color: var(--dew-brand);
}
.manager-filter-eyebrow {
  display: block;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 4px;
}
.manager-filter-label {
  display: block;
  font-size: 18px;
  color: var(--dew-navy, var(--text));
  margin-bottom: 4px;
}
.manager-filter-detail { display: block; font-size: 13px; line-height: 1.5; }
.manager-filter-provisional {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--amber);
}
.manager-heatmap-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.manager-heatmap-filter-label {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.manager-heatmap-filter {
  min-width: 280px;
  max-width: 100%;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border-soft);
}
.manager-heatmap-card { padding: 16px 12px 14px; overflow: hidden; }
.team-heatmap-wrap { overflow-x: auto; }
.team-heatmap {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
}
.team-heatmap th,
.team-heatmap td {
  padding: 6px 5px;
  vertical-align: middle;
  border-bottom: 1px solid var(--border-soft);
}
.team-heatmap-theme {
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}
.team-heatmap-se {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  padding-right: 10px;
}
.team-heatmap-col-summary-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--dew-navy, var(--text));
  white-space: nowrap;
}
.team-heatmap-col-summary { background: color-mix(in srgb, var(--dew-brand) 6%, transparent); }
.team-heatmap-row-summary-head {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-align: center;
  font-weight: 600;
}
.team-heatmap-cell { padding: 4px 3px; }
.team-heatmap-score {
  border-radius: 6px;
  padding: 8px 4px;
  text-align: center;
  font-weight: 600;
  font-size: 12px;
  font-family: var(--font-mono, ui-monospace, monospace);
  min-width: 38px;
}
.team-heatmap-cell--col-summary .team-heatmap-score {
  padding: 11px 4px;
  font-size: 15px;
  font-weight: 700;
  border: 1px solid color-mix(in srgb, var(--dew-brand) 25%, transparent);
}
.team-heatmap-cell--corner-muted { background: transparent; border: none; }
.team-heatmap-cell--row-summary .team-heatmap-score {
  opacity: 0.55;
  font-size: 11px;
  font-weight: 500;
}
.team-heatmap-foot {
  margin: 14px 4px 0;
  font-size: 12px;
  line-height: 1.55;
}
.team-heatmap-legend {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 10px 4px 0;
  font-size: 11px;
}
.team-heatmap-swatch {
  width: 22px;
  height: 11px;
  border-radius: 2px;
  display: inline-block;
}
.manager-secondary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}
.dash-section-sub { margin: -6px 0 12px; font-size: 13px; }
.manager-deal-title { font-weight: 600; }
.manager-deal-account { font-size: 12px; }
.manager-deals-table td.num,
.manager-coaching-queue-table td.num { font-variant-numeric: tabular-nums; }

.dash-drill-link {
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: inherit;
}
.dash-drill-link:hover { color: var(--dew-brand); }
.team-heatmap-score-btn {
  width: 100%;
  border: none;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.team-heatmap-se-link,
.manager-se-link {
  font-weight: 600;
  color: var(--ink);
}
.manager-metric-link {
  text-align: left;
  cursor: pointer;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  transition: border-color 0.15s ease;
}
.manager-metric-link:hover { border-color: color-mix(in srgb, var(--dew-brand) 35%, transparent); }

.se-detail-view .se-detail-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}
.se-detail-identity { display: flex; gap: 13px; align-items: center; }
.se-detail-avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #efebfd;
  color: var(--dew-brand);
  display: grid;
  place-items: center;
  font-weight: 700;
  flex-shrink: 0;
}
.se-detail-stats { margin-bottom: 18px; }
.se-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}
.se-theme-rows { display: grid; gap: 9px; }
.se-theme-row {
  display: grid;
  grid-template-columns: 1fr minmax(80px, 120px) 40px auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 6px 4px;
  border-radius: 6px;
}
.se-theme-row--expanded { background: color-mix(in srgb, var(--dew-brand) 8%, transparent); }
.se-theme-delta { font-size: 11px; white-space: nowrap; }
.se-accounts-table td:first-child,
.se-calls-table td:first-child { font-weight: 600; }
.health-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
}
.health-pill--red { background: #fce8ec; color: #8c2237; }
.health-pill--green { background: #e6f6ef; color: #0d5c41; }
.health-pill--amber { background: #fef3e2; color: #8a5a11; }

@media (max-width: 960px) {
  .se-detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 960px) {
  .manager-team-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .manager-secondary-grid { grid-template-columns: 1fr; }
}

.coaching-head .coaching-privacy { margin: 6px 0 0; max-width: 52rem; }
.coaching-provisional-note { margin: 0 0 14px; font-size: 13px; }
.coaching-stats-types { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.coaching-spine-note { display: block; margin-top: 6px; font-size: 11px; line-height: 1.4; }
.coaching-two-averages-note {
  margin: 0 0 18px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  font-size: 13px;
  line-height: 1.55;
}
.coaching-charts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}
.coaching-trend-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
}
.coaching-trend-legend-item { display: inline-flex; align-items: center; gap: 6px; }
.coaching-trend-swatch { width: 18px; height: 3px; border-radius: 2px; }
.coaching-theme-rows { gap: 9px; }
.coaching-receipts-card { padding: 16px 18px; }
.coaching-receipts-sub { margin: 0 0 12px; }
.coaching-receipt-list { display: grid; gap: 12px; }
.coaching-receipt {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 12px;
  align-items: start;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border-soft);
  background: var(--surface-muted);
}
.coaching-receipt-weak { border-color: color-mix(in srgb, var(--danger) 35%, var(--border-soft)); }
.coaching-receipt-link {
  all: unset;
  cursor: pointer;
  display: block;
  min-width: 0;
}
.coaching-receipt-link:hover .coaching-receipt-quote { text-decoration: underline; }
.coaching-receipt-meta { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.coaching-receipt-quote {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text);
}
.coaching-receipt-dispute,
.coaching-call-dispute {
  all: unset;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}
.coaching-receipt-dispute:hover,
.coaching-call-dispute:hover { text-decoration: underline; }
.coaching-calls-card { padding: 0; overflow: hidden; }
.coaching-calls-table-wrap { overflow-x: auto; }
.coaching-calls-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.coaching-calls-table th,
.coaching-calls-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.coaching-calls-table th {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
  white-space: nowrap;
}
.coaching-call-link {
  all: unset;
  cursor: pointer;
  font-weight: 600;
  color: var(--accent);
}
.coaching-call-link:hover { text-decoration: underline; }
.coaching-call-score { white-space: nowrap; }

@media (max-width: 900px) {
  .coaching-charts-grid { grid-template-columns: 1fr; }
}

/* Manager dashboard table */
.manager-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.manager-se-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.manager-se-table th,
.manager-se-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.manager-se-table th {
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
  white-space: nowrap;
}
.manager-se-table tbody tr:hover { background: var(--surface-muted); }
.manager-table-card { padding: 0; overflow: hidden; }
.manager-table-card .manager-table-wrap { padding: 4px 0; }

@media (max-width: 768px) {
  .launch-action-strip { grid-template-columns: 1fr; }
  .launch-followup-row {
    grid-template-columns: 10px 1fr;
    grid-template-rows: auto auto;
  }
  .launch-followup-company { grid-column: 2; }
  .launch-followup-action { grid-column: 2; white-space: normal; }
  .launch-followup-due { grid-column: 2; }
  .launch-recent-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto auto;
  }
  .launch-recent-company { grid-column: 1; }
  .launch-recent-date { grid-column: 2; grid-row: 1; }
  .launch-recent-momentum { grid-column: 1; }
  .launch-recent-next { grid-column: 1 / -1; white-space: normal; }
  .launch-recent-score { grid-column: 2; grid-row: 2; }
  .dash-charts-top { grid-template-columns: 1fr; }
  .dash-charts-bottom { grid-template-columns: 1fr; }
  .coaching-stats,
  .manager-stats,
  .dash-stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .coaching-stats,
  .manager-stats,
  .dash-stats { grid-template-columns: 1fr; }
}

/* Crayons integration. layout shell; button colors from dew-theme.css */
fw-button.theme-toggle,
fw-button.sidebar-toggle,
fw-button.sidebar-close {
  --fw-button-min-width: auto;
}
fw-button.nav-item,
fw-button.sidebar-logout {
  width: 100%;
  --fw-button-min-width: 100%;
  --fw-button-background-color: transparent;
  --fw-button-border: 0;
  --fw-button-box-shadow: none;
  /* consumed inside the shadow root by sidebar.js -> alignNavButton() */
  --nav-btn-justify: flex-start;
  text-align: left;
  border: none;
  box-shadow: none;
  border-radius: 10px;
}
fw-button.nav-item:hover,
fw-button.sidebar-logout:hover {
  --fw-button-background-color: var(--surface-muted);
}
fw-button.nav-item.active {
  --fw-button-background-color: var(--dew-brand-tint);
  --fw-button-color: var(--dew-brand);
}
.sidebar-collapsed fw-button.nav-item {
  width: 32px;
  min-width: 32px;
  max-width: 32px;
  height: 32px;
  min-height: 32px;
  margin: 0 auto;
  padding: 0;
  align-self: center;
  text-align: center;
  --nav-btn-justify: center;
  --fw-button-min-width: 32px;
  --fw-button-min-height: 32px;
  --fw-button-padding-start: 0;
  --fw-button-padding-end: 0;
  --fw-button-label-vertical-padding: 0;
}
.login-form fw-input,
.login-form fw-button,
#prep-form fw-input,
#prep-form fw-textarea,
#prep-form fw-button,
#postcall-form fw-input,
#postcall-form fw-button {
  margin-bottom: 14px;
}
.worker-banner {
  margin: 0 16px 12px;
  max-width: calc(100% - 32px);
}
.dash-tabs {
  margin: 0 0 8px;
  padding: 0;
}
.launch-side.dash-section {
  margin-bottom: 0;
}
#view-dashboard .launch-hero {
  margin-top: 0;
}

/* Task board. ClickUp / Monday inspired */
.task-board-section { margin-bottom: 24px; }
.task-board-head {
  display: flex;
  flex-direction: row;
  align-items: center;
  /* push the quick-add controls to the right edge, title stays left */
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 32px;
  padding: 20px 22px 14px;
  border-bottom: 1px solid var(--border-soft);
}
.task-board-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--dew-text);
  flex: 0 0 auto;
  white-space: nowrap;
}
.task-board-card {
  display: block;
  padding: 0;
  /* matches fw-card.task-board-card below; the call select hoists its dropdown
     to <body>, so clipping to rounded corners here is safe. */
  overflow: hidden;
  border-radius: var(--dew-radius-lg);
  box-shadow: var(--dew-shadow-island);
  border: 1px solid var(--dew-border);
}
/* Flex row (not grid): the call select is conditionally rendered, so a fixed
   column count would leave a dead track / float the Add button. Flex keeps the
   controls grouped and consistently sized whether there are 3 or 4 of them. */
.task-quick-add {
  display: flex;
  align-items: center;
  /* nowrap here so the controls never break across lines; .task-board-head
     wraps the whole row below the title when the card is narrow. Mobile
     switches to wrap+stack below. */
  flex-wrap: nowrap;
  gap: 10px;
  padding: 0;
  border-bottom: none;
  flex: 0 1 auto;
  min-width: 0;
}
.task-quick-add fw-input,
.task-quick-add fw-select {
  margin: 0;
  min-width: 0;
  --fw-input-min-height: 32px;
  --fw-input-label-font-size: 0;
  height: 32px;
  box-sizing: border-box;
  align-self: end;
}
.task-quick-add fw-button.task-quick-btn {
  margin: 0;
  height: 32px;
  min-height: 32px;
  --fw-button-min-height: 32px;
  --fw-button-label-vertical-padding: 0;
  --fw-button-padding-start: 14px;
  --fw-button-padding-end: 14px;
  width: auto;
  min-width: 72px;
  align-self: center;
  flex: 0 0 auto;
  box-sizing: border-box;
  display: flex;
  /* fw-input's shadow box top-aligns within its host; fw-button's shadow pill
     has a fixed intrinsic height and centers by default. flex-start makes the
     two match top-edges instead of the button's pill sitting ~4px lower. */
  align-items: flex-start;
  padding-block: 0;
}
.task-quick-title {
  flex: 0 1 220px;
  min-width: 160px;
}
.task-quick-due {
  flex: 0 0 auto;
  width: 150px;
}
.task-quick-call {
  flex: 0 1 200px;
  min-width: 160px;
}
.task-quick-btn {
  flex: 0 0 auto;
}
.task-board-sections {
  padding: 8px 0 16px;
}
.task-section {
  padding: 8px 0 4px;
}
.task-section-header {
  margin: 0;
  padding: 16px 22px 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--dew-text-muted);
}
.task-section-hint {
  margin: 0;
  padding: 0 22px 10px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--dew-text-secondary);
}
.task-section-recommended .task-section-header {
  padding-bottom: 4px;
}
.task-section-count {
  font-weight: 600;
}
.task-completed-accordion {
  border-top: 1px solid var(--border-soft);
  margin-top: 4px;
}
.task-recommended-more {
  border-top: 1px solid var(--border-soft);
  margin-top: 0;
}
.task-completed-summary,
.task-recommended-summary {
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.task-completed-summary::-webkit-details-marker,
.task-recommended-summary::-webkit-details-marker { display: none; }
.task-completed-summary::before,
.task-recommended-summary::before {
  content: "▸ ";
  display: inline-block;
  transition: transform 0.15s ease;
}
.task-completed-accordion[open] .task-completed-summary::before,
.task-recommended-more[open] .task-recommended-summary::before {
  transform: rotate(90deg);
}
.task-list { display: flex; flex-direction: column; }
.task-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px 16px;
  padding: 13px 22px;
  border-bottom: 1px solid var(--border-soft);
}
.task-row + .task-row {
  margin-top: 2px;
}
.task-row-recommended {
  grid-template-columns: minmax(0, 1fr) auto;
  padding-top: 14px;
  padding-bottom: 14px;
}
.task-row-active,
.task-row-completed {
  grid-template-columns: minmax(0, 1fr) auto;
}
.task-row-body-recommended {
  min-width: 0;
}
.task-row-body-recommended .task-row-title {
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
}
.task-row:last-child { border-bottom: none; }
.task-row-done { opacity: 0.72; }
.task-row-body { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.task-row-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.task-row-title {
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
}
.task-row-title-done {
  text-decoration: line-through;
  color: var(--muted);
}
.task-row-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.task-row-meta { font-size: 12px; }
.task-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}
.task-row-actions fw-button { margin: 0; }
.task-row-actions fw-button[color="primary"],
.task-quick-btn {
  --color-fill-brand: var(--dew-primary);
  --fw-button-hover-background-color: var(--dew-primary-hover);
}
.task-row-actions fw-button[color="secondary"] {
  --color-fill-surface: var(--dew-surface);
  --color-boundary-border-mildest: var(--dew-input-border);
  --fw-button-hover-background-color: var(--dew-surface-subtle);
}
.task-empty-links fw-button[color="link"] {
  --color-text-brand: var(--dew-primary);
}
.task-show-more-wrap {
  padding: 8px 20px 12px;
}
.task-show-more {
  margin: 0;
}
.task-status-pill {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 2px 7px;
  border-radius: 999px;
  line-height: 1.4;
  flex-shrink: 0;
}
.task-pill-recommended {
  background: var(--dew-primary-tint);
  color: var(--dew-primary);
}
.task-pill-active {
  background: var(--dew-amber-tint);
  color: var(--dew-amber);
}
.task-pill-done {
  background: var(--surface-muted);
  color: var(--muted);
}
[data-theme="dark"] .task-pill-recommended {
  background: color-mix(in srgb, var(--dew-primary) 18%, transparent);
  color: var(--dew-primary);
}
[data-theme="dark"] .task-pill-active {
  background: color-mix(in srgb, var(--dew-amber) 18%, transparent);
  color: var(--dew-amber);
}
.task-call-chip,
fw-button.task-call-chip {
  --fw-button-min-width: auto;
  font-size: 11px;
  font-weight: 600;
  margin: 0;
}
fw-button.task-call-chip:hover { text-decoration: underline; }
.task-urgency-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  align-self: center;
  margin-top: 0;
}
.task-urgency-spacer {
  visibility: hidden;
}
.task-urgency-dot.dot-red { background: var(--danger); }
.task-urgency-dot.dot-amber { background: var(--amber); }
.task-urgency-dot.dot-green { background: var(--green); }
.task-empty,
.task-board-empty {
  padding: 16px;
  margin: 0;
  font-size: 14px;
}
.task-board-empty {
  padding: 20px 16px 24px;
  text-align: center;
}
.dew-empty-copy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.dew-empty-copy fw-icon {
  color: var(--dew-primary);
}
.dew-empty-state {
  display: grid;
  justify-items: start;
  gap: 8px;
  padding: 28px;
  border: 1px dashed var(--dew-border);
  background: var(--dew-surface-subtle);
  box-shadow: none;
}
.dew-empty-state fw-icon {
  padding: 9px;
  color: var(--dew-primary);
  border-radius: 9px;
  background: var(--dew-primary-tint);
}
.task-empty-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

/* Dashboard split layout */
.dash-split {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}
.dash-split-main {
  min-width: 0;
}
.dash-split-side {
  min-width: 0;
  border-left: 1px solid var(--border-soft);
  padding-left: 20px;
}
.dash-side-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.dash-side-stats .dash-stat {
  padding: 12px 14px;
}
.dash-side-recent .launch-recent-row {
  grid-template-columns: 1fr auto auto;
}
.dash-side-recent .launch-recent-next { display: none; }
.dash-side-empty {
  font-size: 13px;
  padding: 8px 0 16px;
  margin: 0;
}

/* Task column charts */
.task-charts-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}
.task-chart-card {
  padding: 12px 14px 8px;
}
.task-chart-title {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.task-chart-svg {
  width: 100%;
  height: auto;
  display: block;
}
.task-chart-label {
  font-size: 10px;
}
.task-chart-value {
  font-size: 11px;
  font-weight: 700;
}

@media (max-width: 960px) {
  .dash-split {
    grid-template-columns: 1fr;
  }
  /* Must match the .launch-split.dash-split specificity (0,2,0) to actually
     collapse the launchpad's 380px rail; a bare .launch-split rule loses. */
  .launch-split.dash-split {
    grid-template-columns: 1fr;
  }
  .dash-split-side {
    border-left: none;
    border-top: 1px solid var(--border-soft);
    padding-left: 0;
    padding-top: 20px;
  }
  .task-charts-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .task-board-head {
    flex-direction: column;
    align-items: stretch;
  }
  .task-board-title {
    white-space: normal;
  }
  .task-quick-add {
    flex: 1 1 auto;
    flex-wrap: wrap;
    min-width: 0;
  }
  .task-quick-title,
  .task-quick-due,
  .task-quick-call,
  .task-quick-btn {
    flex: 1 1 100%;
    min-width: 0;
    width: 100%;
  }
  .task-quick-add fw-button.task-quick-btn {
    width: 100%;
  }
  .task-row {
    grid-template-columns: auto auto 1fr;
  }
  .task-row-actions {
    grid-column: 2 / -1;
    justify-content: flex-end;
  }
}

/* Crayons. Dew theme alignment (tokens in dew-theme.css) */

fw-card.launch-recent-list,
fw-card.launch-followup-list,
fw-card.launch-activity-card,
fw-card.task-board-card,
fw-card.task-chart-card,
fw-card.dash-empty,
fw-card.launch-nudge-card {
  padding: 0;
  overflow: hidden;
}
fw-card.task-chart-card {
  padding: 12px 14px 8px;
  overflow: visible;
}
fw-card.dash-empty,
fw-card.launch-empty {
  padding: 28px 24px;
  overflow: visible;
}
fw-card.result.one-pager {
  margin-top: 16px;
}
fw-card.about-section {
  margin-bottom: 20px;
}
.toolbar fw-button {
  margin: 0;
}
.toolbar fw-button[color="secondary"] {
  --color-fill-surface: var(--dew-surface);
  --color-boundary-border-mildest: var(--dew-input-border);
}
.login-form fw-button[color="primary"],
#prep-form fw-button[color="primary"],
#postcall-form fw-button[color="primary"] {
  --color-fill-brand: var(--dew-primary);
  --fw-button-hover-background-color: var(--dew-primary-hover);
}
.login-form fw-button[color="secondary"] {
  --color-fill-surface: var(--dew-surface);
  --color-boundary-border-mildest: var(--dew-input-border);
}
.about-print-btn {
  flex-shrink: 0;
}
.about-cta a {
  text-decoration: none;
}

.feedback-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px 0 8px;
}
.feedback-form fw-select,
.feedback-form fw-textarea {
  width: 100%;
}
.feedback-form .dew-status-host {
  margin: 4px 0 0;
}

.feedback-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 4px;
}
