*, *::before, *::after { box-sizing: border-box; }

:root {
  --in-green: #2f9875;
  --in-green-dark: #1f5b45;
  --in-mint: #eaf7f0;
  --in-mint-2: #f4fbf7;
  --in-blue: #28a8d2;
  --in-red: #dc473f;
  --in-amber: #d99014;
  --in-ink: #202225;
  --in-soft: #5e6468;
  --in-mute: #9aa1a4;
  --in-line: #e5e7e8;
  --in-shadow: 0 8px 28px rgba(32, 34, 37, 0.08);
}

html { min-height: 100%; }

body {
  margin: 0;
  background: #fff;
  color: var(--in-ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

.intake-shell {
  min-height: 100vh;
  background: #fff;
}

.intake-header {
  position: sticky;
  top: 0;
  z-index: 20;
  width: min(100%, 480px);
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.header-row {
  height: 52px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 8px;
  border-bottom: 1px solid var(--in-line);
  padding: 0 22px;
}

.brand {
  grid-column: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  width: fit-content;
  color: inherit;
  text-decoration: none;
}

.brand img {
  display: block;
  height: 23px;
  width: auto;
}

.trust-mini {
  grid-column: 3;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 10px;
  color: #63676a;
  white-space: nowrap;
}

.stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.stars i {
  width: 15px;
  height: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #00b67a;
  color: #fff;
  font-size: 10px;
  font-style: normal;
  line-height: 1;
}

.stars .half {
  background: linear-gradient(90deg, #00b67a 72%, #d9dddf 72%);
}

.progress-row {
  display: grid;
  grid-template-columns: 26px 1fr 26px;
  align-items: center;
  gap: 10px;
  min-height: 64px;
  padding: 14px 22px;
}

.back-btn {
  width: 26px;
  height: 26px;
  border: 0;
  background: transparent;
  color: var(--in-ink);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
}

.back-btn[data-visible="true"] {
  opacity: 1;
  pointer-events: auto;
}

.back-btn:disabled {
  cursor: default;
}

.progress-pills {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
  align-items: center;
}

.progress-pills span {
  display: block;
  height: 11px;
  border-radius: 999px;
  background: #eceef1;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.02);
}

.progress-pills span.done { background: var(--in-green); }
.progress-pills span.active { background: #dfeee6; }

.screen {
  width: min(100%, 480px);
  min-height: calc(100vh - 108px);
  margin: 0 auto;
  padding: 18px 22px 72px;
}

.screen-wide {
  width: min(100%, 620px);
}

.intake-shell[data-terminal="not-fit"] .intake-header {
  display: none;
}

.intake-shell[data-terminal="not-fit"] .screen {
  min-height: 100vh;
  padding-top: 0;
  padding-bottom: 0;
}

.hero-img {
  position: relative;
  overflow: hidden;
  width: calc(100% + 44px);
  margin: -18px -22px 28px;
  aspect-ratio: 1.35;
  background: var(--in-mint);
}

.hero-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-img .hero-watermark {
  position: absolute;
  left: 20px;
  bottom: 18px;
  width: auto;
  height: 44px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.22));
  opacity: 1;
}

.h1 {
  margin: 0 0 14px;
  color: var(--in-ink);
  font-family: var(--font-sans);
  font-size: clamp(26px, 6.8vw, 34px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: 0;
}

.h1 .green, .h2 .green, .lead .green {
  color: var(--in-green);
}

.h2 {
  margin: 0 0 12px;
  font-family: var(--font-sans);
  font-size: clamp(22px, 5.8vw, 30px);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: 0;
}

.sub {
  margin: 0 0 24px;
  color: var(--in-soft);
  font-size: 16px;
  line-height: 1.45;
}

.rule {
  height: 1px;
  background: var(--in-line);
  margin: 22px 0 26px;
}

.question {
  margin: 0 0 34px;
}

.question-title {
  margin: 0 0 14px;
  color: var(--in-ink);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.question-kicker {
  display: block;
  margin-bottom: 6px;
  color: var(--in-soft);
  font-size: 14px;
  font-weight: 500;
}

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

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

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

.field label {
  color: var(--in-ink);
  font-size: 15px;
  font-weight: 500;
}

.input,
.select,
.textarea {
  width: 100%;
  border: 1px solid var(--in-line);
  border-radius: 8px;
  background: #fff;
  color: var(--in-ink);
  box-shadow: 0 6px 18px rgba(32, 34, 37, 0.05);
  outline: 0;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.input,
.select {
  min-height: 50px;
  padding: 0 14px;
}

.textarea {
  min-height: 118px;
  resize: vertical;
  padding: 14px;
  line-height: 1.45;
}

.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--in-blue);
  box-shadow: 0 0 0 2px rgba(40, 168, 210, 0.14), 0 6px 18px rgba(32, 34, 37, 0.05);
}

.field[data-error="true"] .input,
.field[data-error="true"] .select,
.field[data-error="true"] .textarea,
.card-option[data-error="true"],
.question[data-error="true"] .card-option {
  border-color: var(--in-red);
}

.error-text {
  display: none;
  color: var(--in-red);
  font-size: 12px;
  font-weight: 600;
}

.field[data-error="true"] .error-text,
.question[data-error="true"] > .error-text {
  display: block;
}

.question[data-error="true"] > .error-text {
  width: 100%;
  margin-top: 12px;
  padding: 12px 13px;
  border: 1px solid #f0b3af;
  border-radius: 8px;
  background: #fff0ef;
  font-size: 13px;
}

.card-list {
  display: grid;
  gap: 12px;
}

.card-option {
  position: relative;
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 52px;
  width: 100%;
  padding: 15px 16px;
  border: 1px solid var(--in-line);
  border-radius: 8px;
  background: #fff;
  color: var(--in-ink);
  text-align: left;
  box-shadow: 0 6px 18px rgba(32, 34, 37, 0.05);
  cursor: pointer;
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.card-option:hover {
  border-color: rgba(40, 168, 210, 0.45);
}

.card-option:focus-visible,
.next-btn:focus-visible,
.secondary-btn:focus-visible,
.dark-btn:focus-visible,
.back-btn:focus-visible {
  outline: 2px solid rgba(40, 168, 210, 0.8);
  outline-offset: 3px;
}

.card-option:active {
  transform: translateY(1px);
}

.card-option.selected {
  border-color: var(--in-blue);
  box-shadow: 0 0 0 2px rgba(40, 168, 210, 0.12), 0 8px 22px rgba(32, 34, 37, 0.08);
}

.radio-dot,
.check-box {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  border: 1px solid #dfe3e5;
  background: #f7f8f8;
}

.radio-dot {
  border-radius: 50%;
}

.check-box {
  border-radius: 4px;
}

.selected .radio-dot {
  border: 5px solid var(--in-blue);
  background: #fff;
}

.selected .check-box {
  border-color: var(--in-blue);
  background: var(--in-blue);
  color: #fff;
}

.check-box svg {
  display: none;
  width: 13px;
  height: 13px;
}

.selected .check-box svg {
  display: block;
}

.sex-card {
  min-height: 112px;
  justify-content: center;
  flex-direction: column;
  gap: 9px;
  text-align: center;
}

.sex-icon,
.choice-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #fff;
  font-size: 21px;
  font-weight: 700;
}

.sex-icon.male { background: #4d9ee6; }
.sex-icon.female { background: #f178ad; }
.choice-icon.green { background: #dff5e8; color: var(--in-green); }
.choice-icon.blue { background: #e5f4fb; color: var(--in-blue); }
.choice-icon.red { background: #fee7e5; color: var(--in-red); }
.choice-icon.amber { background: #fff3cf; color: var(--in-amber); }
.choice-icon.orange { background: #ffe8d6; color: #f36f21; }

.metric-card {
  align-items: center;
}

.metric-copy {
  display: grid;
  gap: 2px;
}

.metric-value {
  font-size: 17px;
  font-weight: 700;
}

.metric-label {
  font-size: 12px;
  font-weight: 700;
}

.metric-label.green { color: var(--in-green); }
.metric-label.blue { color: var(--in-blue); }
.metric-label.amber { color: var(--in-amber); }
.metric-label.orange { color: #f36f21; }
.metric-label.red { color: var(--in-red); }

.warning {
  display: none;
  align-items: flex-start;
  gap: 10px;
  padding: 13px 14px;
  border: 1px solid #f0c256;
  border-radius: 8px;
  background: #fff8dd;
  color: #9a5c00;
  font-size: 13px;
  line-height: 1.4;
}

.warning[data-visible="true"] {
  display: flex;
}

.btn-row {
  margin: 38px 0 0;
}

.next-btn,
.secondary-btn,
.dark-btn {
  width: 100%;
  min-height: 57px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0;
  transition: transform 150ms ease, opacity 150ms ease, background 150ms ease;
}

.next-btn {
  background: var(--in-green);
  color: #fff;
}

.next-btn:hover { background: #2a8c6c; }
.next-btn:active, .secondary-btn:active, .dark-btn:active { transform: translateY(1px); }
.next-btn:disabled { opacity: 0.55; cursor: not-allowed; }

.secondary-btn {
  border: 1px solid var(--in-line);
  background: #fff;
  color: var(--in-ink);
}

.dark-btn {
  background: #24211f;
  color: #fff;
  min-height: 44px;
  font-size: 14px;
  letter-spacing: 0.05em;
}

.story-stack,
.video-stack {
  display: grid;
  gap: 18px;
  margin: 26px 0 30px;
}

.story-card {
  overflow: hidden;
  border: 1px solid var(--in-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--in-shadow);
}

.story-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1.3;
  object-fit: cover;
  object-position: center 28%;
}

.story-card div {
  padding: 18px 20px 20px;
}

.story-stars {
  display: block;
  margin-bottom: 8px;
  color: #f5a623;
  font-size: 13px;
  letter-spacing: 0.03em;
}

.story-card h2 {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1.2;
}

.story-card p {
  margin: 0;
  color: var(--in-soft);
  font-size: 15px;
  line-height: 1.45;
}

.video-card {
  overflow: hidden;
  border-radius: 10px;
  background: #111;
  box-shadow: var(--in-shadow);
}

.video-card video,
.video-fallback {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  background: #111;
}

.video-fallback {
  position: relative;
  background-size: cover;
  background-position: center;
}

.video-fallback::after {
  content: "▶";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 54px;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
}

.center { text-align: center; }

.review-shell {
  width: calc(100% + 44px);
  margin: -18px -22px 26px;
}

.review-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding: 22px 24px;
  color: #fff;
  background: linear-gradient(100deg, #1f5b45, #0f3025);
}

.review-top strong {
  display: block;
  font-size: 18px;
  letter-spacing: 0.01em;
}

.review-top span {
  display: block;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
}

.review-top .right {
  text-align: right;
}

.review-top .mint {
  color: #b9f2d3;
}

.complete-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px;
  background: #effaf3;
  color: var(--in-green-dark);
}

.complete-banner .badge {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #d8f6e6;
  color: var(--in-green-dark);
  font-weight: 800;
}

.review-card {
  margin: 0 0 26px;
  padding: 28px 22px;
  border: 1px solid #d9ede3;
  border-radius: 10px;
  background: #f2faf5;
}

.review-card h2 {
  margin: 0 0 18px;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 26px;
  font-weight: 800;
}

.prob-card,
.stats-card {
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(32, 34, 37, 0.06);
}

.prob-card {
  padding: 20px 24px;
  margin-bottom: 18px;
}

.prob-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 12px;
}

.prob-label {
  color: var(--in-soft);
  font-size: 15px;
}

.prob-num {
  color: var(--in-green);
  font-size: 30px;
  font-weight: 800;
}

.prob-track {
  overflow: hidden;
  height: 12px;
  margin-top: 8px;
  border-radius: 999px;
  background: #e5eee9;
}

.prob-fill {
  height: 100%;
  width: 94%;
  border-radius: inherit;
  background: #25be62;
}

.stats-card {
  padding: 22px 28px;
}

.stat-row {
  display: grid;
  grid-template-columns: 38px 1fr;
  gap: 14px;
  align-items: center;
  min-height: 54px;
}

.stat-row + .stat-row {
  border-top: 1px solid var(--in-line);
}

.stat-row .bubble {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #dbf7e7;
}

.strong-line {
  margin: 18px 0 0;
  text-align: center;
  color: var(--in-ink);
}

.strong-line strong {
  color: var(--in-green);
}

.secure-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 24px 0 0;
  color: #8a9194;
  font-size: 12px;
  line-height: 1.3;
  text-align: center;
}

.consent {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 12px;
  margin: 26px 0 26px;
  color: var(--in-soft);
  font-size: 12px;
  line-height: 1.35;
}

.consent a {
  color: var(--in-ink);
  font-weight: 800;
}

.consent input {
  width: 18px;
  height: 18px;
  accent-color: var(--in-green);
}

.badge-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 24px;
}

.badge-mini {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--in-soft);
  font-size: 12px;
  font-weight: 800;
}

.seal {
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #80b6c9;
  border-radius: 50%;
  color: #447d91;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
  line-height: 1.1;
}

.trust-badge {
  display: block;
  width: auto;
  height: 50px;
}

.trust-badge--hipaa,
.trust-badge--usa {
  flex: 0 0 auto;
}

.terminal {
  padding-top: 64px;
  text-align: center;
}

.terminal .badge {
  width: 70px;
  height: 70px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 22px;
  border-radius: 50%;
  background: #e5f8ed;
  color: var(--in-green);
  font-size: 32px;
}

.terminal--review .badge {
  background: #fff8dd;
  color: #9a5c00;
}

.terminal--not-fit {
  width: calc(100% + 44px);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  margin: 0 -22px;
  padding: 30px 28px 48px;
  background: linear-gradient(180deg, var(--in-green-dark) 0 34%, #fff 34% 100%);
}

.terminal-card {
  width: 100%;
  margin: 0 auto;
  padding: 38px 26px 32px;
  border: 1px solid rgba(31, 91, 69, 0.08);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 20px 42px rgba(32, 34, 37, 0.14);
}

.terminal-logo {
  display: block;
  width: 150px;
  height: auto;
  margin: 0 auto 26px;
}

.terminal--not-fit .h1 {
  margin-bottom: 24px;
  font-family: var(--font-serif);
  font-size: 36px;
  font-style: italic;
  font-weight: 500;
}

.terminal--not-fit .sub {
  max-width: 310px;
  margin-left: auto;
  margin-right: auto;
  color: #323538;
}

.terminal--not-fit .sub.small {
  margin-top: 18px;
  color: var(--in-soft);
}

.terminal--not-fit .secondary-btn {
  margin-top: 26px;
  background: #24211f;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 13px;
}

.terminal-footer {
  margin: 30px 0 0;
  color: #202225;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

.sub.small {
  margin-top: -12px;
  font-size: 13px;
}

.review-note p {
  margin: 12px 0 0;
  color: var(--in-soft);
  font-size: 14px;
  line-height: 1.45;
}

@media (max-width: 420px) {
  .header-row { padding: 0 16px; }
  .brand img { height: 20px; }
  .trust-mini {
    gap: 5px;
    font-size: 9px;
  }
  .stars i {
    width: 13px;
    height: 13px;
    font-size: 9px;
  }
  .screen { padding-left: 18px; padding-right: 18px; }
  .hero-img,
  .review-shell {
    width: calc(100% + 36px);
    margin-left: -18px;
    margin-right: -18px;
  }
  .terminal--not-fit {
    width: calc(100% + 36px);
    margin-left: -18px;
    margin-right: -18px;
    padding: 40px 28px 48px;
  }
  .progress-row { padding-left: 16px; padding-right: 16px; }
  .progress-pills { gap: 15px; }
  .field-grid { grid-template-columns: 1fr; }
}
