:root {
  --teal-900: #0e5c58;
  --teal-700: #13807a;
  --teal-100: #d5edeb;
  --teal-50: #eef8f7;
  --ink-900: #0b0f12;
  --ink-700: #252d33;
  --ink-500: #5b6672;
  --ink-300: #c7cdd3;
  --line-200: #e6e9ec;
  --surface-100: #f3f5f7;
  --bg-50: #fafbfc;
  --white: #ffffff;
  --warn-100: #fdf1d8;
  --success-600: #1f9d55;
  --shadow: 0 20px 48px rgba(11, 15, 18, 0.08);
  --shadow-soft: 0 12px 30px rgba(11, 15, 18, 0.055);
  color-scheme: light;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg-50);
  color: var(--ink-900);
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

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

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

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 0 40px;
  border-bottom: 1px solid var(--line-200);
  background: rgba(250, 251, 252, 0.94);
  backdrop-filter: blur(16px);
}

.brand,
.nav-links,
.hero-actions,
.panel-header,
.preview-row,
.queue-row,
.pass-identity,
.pass-topline,
.inline-actions,
.title-actions,
.next-actions,
.side-actions {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-size: 18px;
  font-weight: 850;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line-200);
  border-radius: 10px;
  background: var(--white);
  color: var(--teal-900);
}

.nav-links {
  gap: 28px;
  color: var(--ink-500);
  font-size: 14px;
  font-weight: 700;
}

.nav-links a {
  padding: 24px 0;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--teal-900);
}

.quiet-button {
  justify-self: end;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line-200);
  border-radius: 12px;
  background: var(--white);
  color: var(--ink-500);
  cursor: pointer;
}

main {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  gap: 48px;
  align-items: center;
  min-height: min(520px, calc(100vh - 185px));
  padding: 36px 0 22px;
}

.hero-copy h1,
.app-title-row h1,
.empty-state h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(44px, 6vw, 78px);
  line-height: 0.98;
  letter-spacing: 0;
}

.hero-copy h1 {
  font-size: clamp(42px, 5.3vw, 68px);
}

.hero-copy p,
.app-title-row p,
.empty-state p {
  max-width: 610px;
  margin: 24px 0 0;
  color: var(--ink-500);
  font-size: 18px;
  line-height: 1.55;
}

.hero-actions {
  gap: 12px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.primary-button,
.secondary-button,
.icon-link,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 850;
  cursor: pointer;
}

.primary-button,
.secondary-button {
  min-height: 48px;
  padding: 0 20px;
}

.primary-button {
  border: 1px solid var(--teal-900);
  background: var(--teal-900);
  color: var(--white);
}

.primary-button:hover {
  border-color: var(--teal-700);
  background: var(--teal-700);
}

.primary-button:disabled {
  border-color: var(--ink-300);
  background: var(--ink-300);
  cursor: not-allowed;
}

.secondary-button {
  border: 1px solid var(--line-200);
  background: var(--white);
  color: var(--ink-900);
}

.secondary-button:hover,
.quiet-button:hover {
  border-color: var(--ink-300);
}

.primary-button.full,
.secondary-button.full {
  width: 100%;
}

.secondary-button.small {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 12px;
}

.text-link {
  min-height: auto;
  padding: 0;
  color: var(--teal-900);
}

.icon-link {
  width: 48px;
  height: 42px;
  border: 1px solid var(--line-200);
  background: var(--white);
  color: var(--ink-500);
  font-size: 12px;
}

.small-label {
  display: block;
  margin: 0 0 14px;
  color: var(--teal-900);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.04em;
}

.flow-map {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line-200);
  border-radius: 24px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.flow-step {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 4px 14px;
  padding: 18px;
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--white);
}

.flow-step.active {
  border-color: var(--teal-900);
  background: var(--teal-50);
}

.flow-step span {
  grid-row: span 2;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-100);
  color: var(--teal-900);
  font-size: 12px;
  font-weight: 850;
}

.flow-step strong {
  font-size: 16px;
}

.flow-step p {
  margin: 0;
  color: var(--ink-500);
  font-size: 14px;
  line-height: 1.45;
}

.route-strip,
.preview-band,
.behind-scenes,
.privacy-band {
  border: 1px solid var(--line-200);
  border-radius: 24px;
  background: var(--white);
}

.route-strip,
.preview-band {
  display: grid;
  grid-template-columns: minmax(300px, 0.78fr) minmax(520px, 1.22fr);
  gap: 32px;
  align-items: start;
  margin: 10px 0 38px;
  padding: 34px;
}

.route-strip h2,
.preview-band h2,
.landing-grid h2,
.behind-scenes h2,
.privacy-band h2,
.tool-panel h2,
.side-panel h2 {
  margin: 0;
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.03;
  letter-spacing: 0;
}

.route-strip p,
.section-lead,
.panel-note,
.side-panel p,
.tool-panel p {
  margin: 16px 0 0;
  color: var(--ink-500);
  line-height: 1.55;
}

.route-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.route-card {
  display: grid;
  min-height: 156px;
  align-content: start;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--teal-50);
}

.route-card:hover {
  border-color: var(--teal-900);
}

.route-card span {
  overflow-wrap: anywhere;
  color: var(--teal-900);
  font-size: 12px;
  font-weight: 850;
}

.route-card strong {
  font-size: 20px;
}

.route-card p {
  margin: 0;
  color: var(--ink-500);
  font-size: 14px;
  line-height: 1.45;
}

.landing-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.8fr) minmax(520px, 1.2fr);
  gap: 28px;
  align-items: start;
  padding: 18px 0 52px;
}

.landing-points {
  display: grid;
  gap: 12px;
}

.landing-points > div {
  display: grid;
  grid-template-columns: minmax(150px, 0.34fr) 1fr;
  gap: 18px;
  align-items: start;
  border: 1px solid var(--line-200);
  border-radius: 18px;
  background: var(--white);
  padding: 18px 20px;
  box-shadow: var(--shadow-soft);
}

.landing-points strong {
  display: block;
  font-size: 18px;
}

.landing-points p {
  margin: 0;
  color: var(--ink-500);
  line-height: 1.48;
}

.host-snapshot {
  display: grid;
  gap: 18px;
  border: 1px solid var(--line-200);
  border-radius: 22px;
  padding: 22px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.host-snapshot h3 {
  margin: 0;
  font-size: 34px;
  line-height: 1;
}

.app-page {
  padding: 54px 0 80px;
}

.app-page.compact {
  padding-top: 44px;
}

.app-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: end;
  margin-bottom: 28px;
}

.title-actions,
.next-actions,
.side-actions {
  gap: 10px;
  flex-wrap: wrap;
}

.host-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.86fr) minmax(320px, 0.74fr);
  gap: 18px;
  align-items: start;
}

.tool-panel,
.side-panel {
  display: grid;
  gap: 18px;
  border: 1px solid var(--line-200);
  border-radius: 22px;
  background: var(--white);
  padding: 24px;
  box-shadow: var(--shadow-soft);
}

.tool-panel.wide {
  grid-column: 1 / -1;
}

.tool-panel h2,
.side-panel h2 {
  font-size: 28px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span,
.link-panel span,
.status-panel > span {
  color: var(--ink-500);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.04em;
}

.field input {
  width: 100%;
  min-height: 58px;
  border: 1px solid var(--line-200);
  border-radius: 14px;
  background: var(--white);
  color: var(--ink-900);
  padding: 0 16px;
  font-size: 22px;
  font-weight: 750;
  outline: none;
}

.field input:focus {
  border: 2px solid var(--teal-900);
}

.link-panel,
.status-panel,
.session-table {
  display: grid;
  gap: 10px;
  border: 1px solid var(--line-200);
  border-radius: 18px;
  padding: 18px;
}

.link-panel {
  background: var(--surface-100);
}

.link-panel strong,
.side-panel h2 {
  overflow-wrap: anywhere;
}

.link-panel strong {
  font-size: 18px;
}

.inline-actions {
  gap: 16px;
  flex-wrap: wrap;
}

.text-button {
  width: fit-content;
  border: 0;
  background: transparent;
  color: var(--teal-900);
  padding: 0;
  font-weight: 850;
  cursor: pointer;
}

.status-panel {
  border-color: rgba(14, 92, 88, 0.28);
  background: var(--teal-50);
}

.status-panel > span {
  color: var(--teal-900);
}

.status-panel strong {
  font-size: 18px;
}

.status-panel p {
  margin: 0;
  color: var(--ink-500);
  font-size: 14px;
  line-height: 1.45;
}

.status-track {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: rgba(14, 92, 88, 0.14);
}

.status-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--teal-900);
  transition: width 180ms ease;
}

.plain-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.plain-list li {
  position: relative;
  padding-left: 28px;
  color: var(--ink-500);
}

.plain-list li::before {
  position: absolute;
  left: 0;
  top: 2px;
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 999px;
  background: var(--teal-100);
  color: var(--teal-900);
  content: "OK";
  font-size: 8px;
  font-weight: 900;
}

.session-table {
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.session-row {
  display: grid;
  grid-template-columns: minmax(140px, 0.42fr) 1fr;
  gap: 16px;
  padding: 14px 16px;
  border-top: 1px solid var(--line-200);
}

.session-row:first-child {
  border-top: 0;
}

.session-row-head {
  background: var(--surface-100);
  color: var(--ink-500);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.04em;
}

.session-row strong {
  overflow-wrap: anywhere;
}

.split-app {
  display: grid;
  grid-template-columns: minmax(360px, 0.86fr) minmax(340px, 0.74fr);
  gap: 34px;
  align-items: start;
}

.phone-frame {
  display: flex;
  min-height: 760px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line-200);
  border-radius: 30px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.phone-frame.pass-route {
  min-height: 700px;
}

.phone-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line-200);
  color: var(--ink-500);
  font-size: 13px;
  font-weight: 850;
}

.phone-progress {
  height: 4px;
  background: var(--surface-100);
}

.phone-progress span {
  display: block;
  height: 100%;
  background: var(--teal-900);
  transition: width 180ms ease;
}

.screen-content {
  display: grid;
  flex: 1;
  align-content: start;
  gap: 0;
  min-height: 0;
  padding: 42px 32px 28px;
}

.screen-content h1 {
  margin: 0;
  font-size: clamp(34px, 4vw, 48px);
  line-height: 1.03;
  letter-spacing: 0;
}

.screen-content p {
  margin: 14px 0 0;
  color: var(--ink-500);
  font-size: 18px;
  line-height: 1.48;
}

.session-chip {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 26px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--teal-100);
  color: var(--teal-900);
  font-size: 13px;
  font-weight: 850;
}

.info-list,
.ack-list,
.vouch-questions,
.principles {
  display: grid;
  gap: 12px;
}

.info-list {
  margin-top: 28px;
}

.info-list > div,
.ack-row,
.vouch-question,
.queue-row,
.principles > div {
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--white);
}

.info-list > div,
.vouch-question,
.principles > div {
  padding: 16px;
}

.info-list strong,
.vouch-question strong,
.principles strong {
  display: block;
  font-size: 18px;
}

.info-list span,
.preview-row span,
.queue-row span,
.pass-identity span,
.principles span {
  display: block;
  color: var(--ink-500);
  font-size: 14px;
  line-height: 1.45;
}

.preview-row {
  gap: 14px;
  margin-top: 18px;
  padding: 16px;
  border-radius: 16px;
  background: var(--surface-100);
}

.avatar {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 999px;
  background: var(--teal-100);
  color: var(--teal-900);
  font-size: 14px;
  font-weight: 850;
}

.avatar.large {
  width: 64px;
  height: 64px;
  font-size: 18px;
}

.screen-footer {
  display: grid;
  gap: 12px;
  align-self: end;
  margin-top: 36px;
  padding-top: 22px;
  border-top: 1px solid var(--line-200);
}

.screen-footer p {
  min-height: 20px;
  margin: 0;
  font-size: 14px;
}

.ack-row {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: center;
  padding: 14px;
  text-align: left;
  cursor: pointer;
}

.ack-row.is-checked {
  border: 2px solid var(--teal-900);
}

.ack-marker {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--ink-300);
  border-radius: 999px;
  color: var(--ink-500);
  font-size: 12px;
  font-weight: 850;
}

.is-checked .ack-marker {
  border-color: var(--teal-900);
  background: var(--teal-900);
  color: var(--white);
}

.ack-row strong {
  display: block;
  font-size: 15px;
}

.ack-row span:last-child {
  display: block;
  margin-top: 3px;
  color: var(--ink-500);
  font-size: 13px;
  line-height: 1.35;
}

.pass-card {
  display: grid;
  gap: 20px;
  margin-top: 24px;
  padding: 20px;
  border: 1px solid var(--teal-900);
  border-radius: 22px;
  background: var(--teal-100);
}

.pass-topline {
  justify-content: space-between;
  color: var(--teal-900);
  font-size: 12px;
  font-weight: 850;
}

.pass-identity {
  gap: 14px;
}

dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid rgba(14, 92, 88, 0.2);
  padding-top: 10px;
}

dt {
  color: var(--ink-500);
}

dd {
  margin: 0;
  font-weight: 850;
  text-align: right;
}

.vouch-question {
  display: grid;
  gap: 12px;
}

.chip-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chip-row button {
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--surface-100);
  color: var(--ink-500);
  padding: 0 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.chip-row button.is-selected {
  border-color: var(--teal-900);
  background: var(--teal-100);
  color: var(--teal-900);
}

.side-panel {
  position: sticky;
  top: 96px;
}

.side-actions {
  align-items: stretch;
  flex-direction: column;
}

.side-actions .primary-button,
.side-actions .secondary-button {
  width: 100%;
}

.mini-steps {
  display: grid;
  gap: 10px;
}

.mini-steps > div {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line-200);
  border-radius: 14px;
  padding: 12px;
}

.mini-steps span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-100);
  color: var(--ink-500);
  font-size: 11px;
  font-weight: 850;
}

.mini-steps strong {
  font-size: 15px;
}

.mini-steps .is-active {
  border-color: var(--teal-900);
  background: var(--teal-50);
}

.mini-steps .is-active span,
.mini-steps .is-done span {
  background: var(--teal-900);
  color: var(--white);
}

.queue-row {
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
}

.behind-scenes {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(360px, 1.28fr);
  gap: 30px;
  align-items: start;
  margin-bottom: 28px;
  padding: 34px;
}

.behind-scenes.is-standalone {
  margin-bottom: 28px;
}

.behind-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.behind-card {
  min-height: 148px;
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--white);
  padding: 18px;
}

.behind-card.is-ready {
  background: var(--teal-50);
}

.behind-card strong {
  display: block;
  font-size: 18px;
}

.behind-card span {
  display: block;
  margin-top: 10px;
  color: var(--ink-500);
  line-height: 1.48;
}

.privacy-band {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(340px, 1.2fr);
  gap: 36px;
  margin-bottom: 80px;
  padding: 34px;
}

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

.empty-state {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 0;
  text-align: left;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 20;
  max-width: 340px;
  transform: translateY(16px);
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow);
  color: var(--ink-900);
  opacity: 0;
  padding: 14px 16px;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.noscript {
  margin: 24px auto;
  width: min(720px, calc(100% - 40px));
  border: 1px solid var(--line-200);
  border-radius: 16px;
  background: var(--warn-100);
  padding: 16px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 1000px) {
  .topbar {
    grid-template-columns: 1fr auto;
    padding: 0 20px;
  }

  .nav-links {
    display: none;
  }

  .hero,
  .route-strip,
  .preview-band,
  .landing-grid,
  .host-grid,
  .split-app,
  .behind-scenes,
  .privacy-band,
  .behind-grid,
  .principles {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    gap: 28px;
    padding-top: 34px;
  }

  .app-title-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .side-panel {
    position: relative;
    top: auto;
  }

  .phone-frame {
    min-height: 720px;
  }
}

@media (max-width: 660px) {
  main {
    width: min(100% - 24px, 480px);
  }

  .topbar {
    min-height: 64px;
  }

  .brand {
    font-size: 17px;
  }

  .quiet-button {
    min-height: 36px;
    padding: 0 10px;
    font-size: 13px;
  }

  .hero-copy h1,
  .app-title-row h1,
  .empty-state h1 {
    font-size: 40px;
    line-height: 1.03;
  }

  .hero-copy p,
  .app-title-row p,
  .empty-state p,
  .screen-content p {
    margin-top: 14px;
    font-size: 16px;
    line-height: 1.42;
  }

  .hero-actions,
  .title-actions,
  .next-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
  }

  .primary-button,
  .secondary-button {
    min-height: 44px;
    width: 100%;
  }

  .flow-map {
    gap: 8px;
    padding: 8px;
    border-radius: 18px;
  }

  .flow-step {
    grid-template-columns: 30px 1fr;
    gap: 2px 10px;
    min-height: 48px;
    padding: 10px;
    border-radius: 12px;
  }

  .flow-step span {
    width: 26px;
    height: 26px;
    font-size: 10px;
  }

  .flow-step strong {
    align-self: center;
    font-size: 14px;
  }

  .flow-step p {
    display: none;
  }

  .route-strip,
  .preview-band,
  .behind-scenes,
  .privacy-band,
  .tool-panel,
  .side-panel {
    padding: 22px;
    border-radius: 20px;
  }

  .route-list {
    grid-template-columns: 1fr;
  }

  .landing-points > div {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .phone-frame {
    min-height: 710px;
    border-radius: 24px;
  }

  .phone-header {
    min-height: 70px;
    padding: 14px 16px;
  }

  .screen-content {
    padding: 28px 20px 22px;
  }

  .screen-content h1 {
    font-size: 34px;
  }

  .field input {
    min-height: 54px;
    font-size: 20px;
  }

  .session-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .behind-card {
    min-height: 0;
  }

  .toast {
    right: 12px;
    bottom: 12px;
    left: 12px;
    max-width: none;
  }
}
