:root {
  color-scheme: dark;
  --background: #131313;
  --surface: #1c1b1b;
  --surface-2: #201f1f;
  --surface-3: #2a2a2a;
  --surface-4: #353534;
  --text: #e5e2e1;
  --muted: #b9cacb;
  --outline: #3b494b;
  --outline-strong: #849495;
  --primary: #dbfcff;
  --cyan: #00dbe9;
  --cyan-bright: #00f0ff;
  --moss: #b0cfad;
  --moss-dark: #334d33;
  --amber: #ffba43;
  --amber-soft: #ffd290;
  --danger: #ffb4ab;
  --radius-sm: 4px;
  --radius: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --space: 8px;
  --page-x: 24px;
  --nav-h: 68px;
  --sidebar-w: 240px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--background);
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 80% 0%, rgba(0, 219, 233, 0.06), transparent 28rem),
    radial-gradient(circle at 12% 18%, rgba(176, 207, 173, 0.04), transparent 24rem),
    var(--background);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 22px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-flex;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  font-feature-settings: "liga";
  -webkit-font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

.filled {
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}

.app-root {
  min-height: 100vh;
}

.marketing-root {
  min-height: 100vh;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 64px;
  padding: 0 var(--page-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(19, 19, 19, 0.72);
  backdrop-filter: blur(20px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: "Hanken Grotesk", Inter, sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  color: var(--primary);
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(219, 252, 255, 0.16);
  border-radius: 50%;
  background: linear-gradient(140deg, rgba(0, 219, 233, 0.16), rgba(176, 207, 173, 0.06));
  color: var(--cyan);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.icon-btn {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: transparent;
  color: var(--muted);
}

.icon-btn:hover {
  color: var(--cyan);
  background: rgba(255, 255, 255, 0.05);
}

.sidebar {
  display: none;
}

.sidebar-profile {
  padding: 0 var(--page-x) 24px;
}

.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--muted);
}

.profile-title {
  margin-top: 14px;
  font-family: "Hanken Grotesk", Inter, sans-serif;
  font-size: 22px;
  line-height: 1.1;
  font-weight: 700;
  color: var(--primary);
}

.micro {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.side-link {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  color: var(--muted);
  border-left: 2px solid transparent;
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
}

.side-link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.side-link.active {
  color: var(--cyan);
  background: rgba(0, 219, 233, 0.06);
  border-left-color: var(--cyan);
}

.content {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px var(--page-x) calc(var(--nav-h) + 32px);
}

.content.wide {
  max-width: 1320px;
}

.content.narrow {
  max-width: 760px;
}

.page-kicker,
.label {
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  line-height: 20px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.page-title {
  margin: 0;
  font-family: "Hanken Grotesk", Inter, sans-serif;
  font-size: 32px;
  line-height: 40px;
  font-weight: 600;
  color: var(--text);
}

.page-copy {
  margin: 8px 0 0;
  max-width: 640px;
  color: var(--muted);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.grid {
  display: grid;
  gap: 12px;
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.three,
.grid.four {
  grid-template-columns: 1fr;
}

.review-layout {
  grid-template-columns: 1fr;
}

.review-layout > .grid {
  margin-top: 76px;
}

.workflow-layout {
  grid-template-columns: 1fr;
}

.card {
  border-radius: var(--radius-lg);
  background: rgba(32, 31, 31, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.card.pad {
  padding: 20px;
}

.card-title {
  margin: 10px 0 0;
  font-family: "Hanken Grotesk", Inter, sans-serif;
  font-size: 24px;
  line-height: 1.18;
}

.card-copy {
  margin: 10px 0 0;
  color: var(--muted);
}

.card.focus {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 0 32px rgba(0, 219, 233, 0.1);
}

.metric {
  font-family: Inter, sans-serif;
  font-size: 64px;
  line-height: 64px;
  font-weight: 300;
  color: var(--cyan);
  font-variant-numeric: tabular-nums;
}

.metric-sm {
  font-family: Inter, sans-serif;
  font-size: 36px;
  line-height: 40px;
  font-weight: 300;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.stat-card {
  min-height: 104px;
}

.stat-card .metric-sm,
.stat-card .metric {
  margin-top: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid rgba(219, 252, 255, 0.16);
  background: rgba(0, 219, 233, 0.06);
  color: var(--primary);
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--outline);
  background: var(--surface-2);
  color: var(--text);
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn:hover {
  border-color: var(--outline-strong);
  background: var(--surface-3);
}

.btn.primary {
  border-color: rgba(0, 219, 233, 0.72);
  background: rgba(0, 219, 233, 0.1);
  color: var(--cyan);
}

.btn.primary:hover {
  background: rgba(0, 219, 233, 0.18);
}

.btn.ghost {
  background: transparent;
}

.btn.block {
  width: 100%;
}

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  height: var(--nav-h);
  padding: 4px 8px calc(env(safe-area-inset-bottom) + 4px);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(19, 19, 19, 0.72);
  backdrop-filter: blur(20px);
}

.bottom-link {
  min-width: 0;
  min-height: 54px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  line-height: 1;
}

.bottom-link.active {
  color: var(--cyan);
  background: rgba(0, 219, 233, 0.08);
}

.hero {
  min-height: calc(100vh - 64px);
  display: grid;
  align-items: center;
  padding: 72px var(--page-x) 40px;
}

.hero-inner {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
}

.hero h1 {
  max-width: 820px;
  margin: 24px 0 0;
  font-family: "Hanken Grotesk", Inter, sans-serif;
  font-size: 48px;
  line-height: 56px;
  font-weight: 600;
  color: var(--text);
}

.hero p {
  max-width: 680px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 32px;
}

.hero-visual {
  margin-top: 48px;
  min-height: 280px;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(180deg, transparent, rgba(19, 19, 19, 0.72)),
    radial-gradient(circle at 30% 20%, rgba(0, 219, 233, 0.22), transparent 16rem),
    linear-gradient(135deg, rgba(32, 31, 31, 0.9), rgba(14, 14, 14, 0.95));
  overflow: hidden;
  position: relative;
}

.scan-figure {
  width: min(320px, 78vw);
  height: 260px;
  margin: 32px auto;
  position: relative;
  display: grid;
  place-items: center;
  opacity: 0.95;
}

.scan-figure::before {
  content: "";
  position: absolute;
  width: 1px;
  inset: 0 auto;
  background: linear-gradient(transparent, rgba(0, 219, 233, 0.5), transparent);
}

.scan-figure::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 42%;
  height: 2px;
  background: var(--cyan);
  box-shadow: 0 0 18px var(--cyan);
  animation: scan 3s ease-in-out infinite alternate;
}

.body-outline {
  width: 130px;
  height: 210px;
  border: 3px solid rgba(219, 252, 255, 0.76);
  border-radius: 48% 48% 42% 42%;
  position: relative;
  filter: drop-shadow(0 0 16px rgba(0, 219, 233, 0.25));
}

.body-outline::before {
  content: "";
  position: absolute;
  width: 54px;
  height: 54px;
  left: 50%;
  top: -42px;
  transform: translateX(-50%);
  border: 3px solid rgba(219, 252, 255, 0.76);
  border-radius: 50%;
}

.body-outline::after {
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  top: 86px;
  height: 3px;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 16px rgba(0, 219, 233, 0.55);
}

.progress-line {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  height: 4px;
}

.progress-line span {
  border-radius: 999px;
  background: rgba(53, 53, 52, 0.8);
}

.progress-line span.done {
  background: var(--cyan);
}

.choice {
  min-height: 48px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--outline);
  border-radius: var(--radius-md);
  background: var(--surface-2);
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.choice.active {
  border-color: var(--cyan);
  background: rgba(0, 219, 233, 0.1);
  color: var(--cyan);
}

.timeline {
  display: flex;
  gap: 4px;
  height: 14px;
}

.timeline span {
  flex: 1;
  border-radius: 999px;
  background: var(--surface-4);
}

.timeline span.good {
  background: var(--cyan);
}

.timeline span.focus {
  background: var(--amber);
}

.cue-card {
  border-left: 4px solid var(--cyan);
}

.body-map {
  min-height: 320px;
  display: grid;
  place-items: center;
}

.body-map .body-outline {
  width: 150px;
  height: 230px;
}

.body-map-panel {
  min-height: 320px;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(rgba(0, 219, 233, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 219, 233, 0.08) 1px, transparent 1px),
    radial-gradient(circle at 50% 42%, rgba(0, 219, 233, 0.14), transparent 12rem),
    #0e0e0e;
  background-size: 40px 40px, 40px 40px, auto, auto;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}

.region-dot {
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 22px rgba(255, 186, 67, 0.58);
}

.region-dot.cyan {
  background: var(--cyan);
  box-shadow: 0 0 22px rgba(0, 219, 233, 0.58);
}

.bars {
  display: grid;
  gap: 12px;
}

.bar-row {
  display: grid;
  grid-template-columns: 88px 1fr 36px;
  gap: 10px;
  align-items: center;
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
}

.bar {
  height: 8px;
  border-radius: 999px;
  background: var(--surface-4);
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--cyan);
}

.message-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.message {
  max-width: 86%;
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  color: var(--text);
}

.message.ai {
  border-left: 4px solid var(--cyan);
}

.message.user {
  margin-left: auto;
  background: rgba(0, 219, 233, 0.1);
  color: var(--primary);
}

.program-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border-radius: var(--radius-lg);
  background: rgba(32, 31, 31, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.week-num {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(0, 219, 233, 0.09);
  border: 1px solid rgba(0, 219, 233, 0.24);
  color: var(--cyan);
  font-family: "JetBrains Mono", monospace;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.admin-table th,
.admin-table td {
  padding: 14px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  text-align: left;
}

.admin-table th {
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 500;
}

.table-wrap {
  overflow-x: auto;
}

.video-frame {
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(rgba(0, 219, 233, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 219, 233, 0.08) 1px, transparent 1px),
    radial-gradient(circle at 50% 42%, rgba(0, 219, 233, 0.14), transparent 12rem),
    #0e0e0e;
  background-size: 40px 40px, 40px 40px, auto, auto;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}

.workspace-tools {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.tool-chip {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(14, 14, 14, 0.45);
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.review-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.queue-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.client-panel {
  display: grid;
  gap: 12px;
}

.client-card {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: rgba(14, 14, 14, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.client-card.active {
  border-color: rgba(0, 219, 233, 0.44);
  background: rgba(0, 219, 233, 0.08);
}

.risk-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--amber);
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.video-frame .body-outline {
  transform: scale(0.8);
}

.reference-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.reference-card img {
  width: 100%;
  display: block;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.status-ok {
  color: var(--moss);
}

.status-focus {
  color: var(--amber);
}

.mobile-after-fold {
  margin-top: 80px;
}

@keyframes scan {
  from {
    transform: translateY(-92px);
  }
  to {
    transform: translateY(92px);
  }
}

@media (min-width: 720px) {
  .grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .grid.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .review-layout {
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.8fr);
  }

  .review-layout > .grid {
    margin-top: 0;
  }

  .workflow-layout {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  }

  .review-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .queue-layout {
    grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
  }

  .hero-actions {
    flex-direction: row;
  }
}

@media (min-width: 920px) {
  .app-shell {
    padding-left: var(--sidebar-w);
  }

  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-w);
    z-index: 30;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 32px 0;
    background: rgba(19, 19, 19, 0.82);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
  }

  .topbar.app {
    display: none;
  }

  .bottom-nav {
    display: none;
  }

  .content {
    padding: 56px 40px 64px;
  }

  .page-title {
    font-size: 40px;
    line-height: 48px;
  }

  .grid.dashboard {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .span-2 {
    grid-column: span 2;
  }

  .span-3 {
    grid-column: span 3;
  }

  .span-4 {
    grid-column: span 4;
  }

  .reference-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .mobile-after-fold {
    margin-top: 0;
  }
}

@media (max-width: 420px) {
  .page-title {
    font-size: 28px;
    line-height: 36px;
  }

  .hero h1 {
    font-size: 38px;
    line-height: 44px;
  }

  .metric {
    font-size: 56px;
    line-height: 56px;
  }

  .grid.two {
    grid-template-columns: 1fr;
  }
}
