:root {
  --ink: #07162b;
  --ink-soft: #526176;
  --navy: #071b31;
  --surface: #f5f8fc;
  --line: #dce6f2;
  --cyan: #08c7d9;
  --blue: #146df5;
  --green: #22b573;
  --yellow: #f6b943;
  --danger: #e85d75;
  --gradient: linear-gradient(120deg, var(--cyan), var(--blue));
  --shadow: 0 18px 50px rgba(21, 55, 100, .16);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 84% 6%, rgba(8, 199, 217, .18), transparent 28rem),
    linear-gradient(180deg, #f8fbff, #eef4fb);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  touch-action: manipulation;
}

.assessment-shell {
  width: min(100%, 560px);
  min-height: 100dvh;
  margin: 0 auto;
  background: #fff;
  box-shadow: var(--shadow);
}

.screen {
  display: none;
  min-height: 100dvh;
  padding: calc(18px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom));
}

.screen.active {
  display: flex;
  flex-direction: column;
}

.screen-intro {
  color: #fff;
  background:
    radial-gradient(circle at 82% 10%, rgba(8, 199, 217, .38), transparent 18rem),
    linear-gradient(145deg, #071b31, #082846);
}

.brand-row,
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-shrink: 0;
}

.brand-mark {
  font-size: 17px;
  font-weight: 820;
  letter-spacing: 0;
}

.pill,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.pill {
  padding: 7px 11px;
  color: #bff7ff;
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .12);
}

.eyebrow {
  margin: 0 0 12px;
  padding: 7px 11px;
  color: #1062cf;
  background: #eaf3ff;
}

.screen-intro .eyebrow,
.screen-success .eyebrow {
  color: #a8eef6;
  background: rgba(24, 201, 220, .13);
}

.intro-copy {
  margin-top: auto;
  padding-top: 44px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 11ch;
  margin-bottom: 16px;
  font-size: clamp(34px, 10vw, 40px);
  line-height: 1.04;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 12px;
  font-size: clamp(27px, 7.8vw, 32px);
  line-height: 1.1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 19px;
  line-height: 1.2;
  letter-spacing: 0;
}

.lead {
  margin-bottom: 0;
  color: #c9d8e8;
  font-size: 16px;
  line-height: 1.55;
}

.gain-panel {
  margin: 30px 0 22px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 18px;
  background: rgba(255, 255, 255, .08);
}

.gain-title {
  margin-bottom: 12px;
  color: #fff;
  font-weight: 780;
}

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

.gain-panel li {
  position: relative;
  padding-left: 24px;
  color: #d8e7f4;
  font-size: 15px;
  line-height: 1.45;
}

.gain-panel li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .55em;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 0 4px rgba(8, 199, 217, .13);
}

.primary-action,
.secondary-action,
.option-button,
.icon-button {
  border: 0;
  cursor: pointer;
}

.primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  padding: 0 20px;
  border-radius: 999px;
  color: #fff;
  background: var(--gradient);
  box-shadow: 0 14px 30px rgba(20, 109, 245, .25);
  font-size: 17px;
  font-weight: 820;
}

.secondary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  margin-top: 10px;
  padding: 0 18px;
  border-radius: 999px;
  color: var(--ink);
  background: #edf3fa;
  font-weight: 760;
}

.tiny {
  margin: 12px 0 0;
  color: #aebfd1;
  font-size: 12px;
  text-align: center;
}

.topbar {
  min-height: 52px;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  color: var(--ink);
  background: #edf3fa;
  font-size: 34px;
  line-height: 1;
}

.progress-wrap {
  flex: 1;
}

.progress-label {
  margin-bottom: 8px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 850;
  text-align: right;
}

.progress-track {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: #e5edf6;
}

.progress-track span {
  display: block;
  width: 12.5%;
  height: 100%;
  border-radius: inherit;
  background: var(--gradient);
  transition: width .24s ease;
}

.question-area {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 30px 0 0;
}

.question-help {
  margin-bottom: 22px;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.55;
}

.option-grid {
  display: grid;
  gap: 10px;
  margin-top: auto;
  padding-top: 18px;
}

.option-button {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 16px;
  border: 1px solid #cdd8e9;
  border-radius: 18px;
  color: var(--ink);
  background: #fff;
  text-align: left;
  box-shadow: 0 9px 24px rgba(28, 61, 111, .06);
}

.option-button strong {
  font-size: 15.5px;
  line-height: 1.32;
  font-weight: 760;
}

.option-button span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #146df5;
  background: #eef5ff;
  font-weight: 900;
}

.option-button:active {
  transform: scale(.99);
}

.screen-result {
  background: #f6f9fd;
}

.result-header {
  padding-bottom: 16px;
}

.score-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 15px;
  align-items: center;
  margin-bottom: 20px;
  padding: 15px;
  border: 1px solid #b8d7fb;
  border-radius: 20px;
  background: #fff;
}

.score-number {
  display: grid;
  place-items: center;
  width: 96px;
  min-height: 76px;
  border-radius: 22px;
  color: #fff;
  background: var(--gradient);
  font-size: 25px;
  font-weight: 860;
  letter-spacing: 0;
}

.score-label {
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.45;
}

.score-label strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.2;
}

.score-label small {
  display: block;
  color: var(--ink-soft);
  font-size: 12.5px;
  line-height: 1.4;
}

.result-header p {
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.55;
}

.tier-word {
  font-weight: 800;
}
.tier-low { color: #1aa260; }
.tier-medium { color: #d59000; }
.tier-high { color: #d83b3b; }

.result-list {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.result-item {
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.result-item strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.result-item p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.5;
}

.lead-form {
  display: grid;
  gap: 13px;
  margin-top: auto;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #fff;
}

.form-copy p {
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.5;
}

.lead-form label {
  display: grid;
  gap: 7px;
  color: #344158;
  font-size: 13.5px;
  font-weight: 720;
}

.lead-form label span {
  color: #8290a4;
  font-weight: 650;
}

.lead-form input,
.lead-form select {
  width: 100%;
  min-height: 52px;
  padding: 13px 15px;
  border: 1px solid #cdd8e9;
  border-radius: 14px;
  color: var(--ink);
  background: #f9fbfe;
  font-size: 16px;
}

.lead-form select:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.lead-form input:focus,
.lead-form select:focus {
  outline: 3px solid rgba(29, 123, 245, .15);
  border-color: #237cf3;
}

.lead-form .invalid {
  border-color: var(--danger);
}

.form-message {
  min-height: 18px;
  margin: 0;
  color: #bd2f47;
  font-size: 13px;
}

.screen-success {
  justify-content: center;
  color: #fff;
  background: linear-gradient(145deg, #071b31, #082846);
}

.success-mark {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  margin-bottom: 22px;
  border-radius: 50%;
  color: #062039;
  background: #68dce9;
  font-size: 38px;
  font-weight: 900;
}

.screen-success p:not(.eyebrow) {
  color: #c9d8e8;
}

@media (min-width: 760px) {
  body {
    padding: 24px 0;
  }

  .assessment-shell {
    min-height: calc(100dvh - 48px);
    border-radius: 28px;
    overflow: hidden;
  }

  .screen {
    min-height: calc(100dvh - 48px);
    padding: 28px;
  }
}

@media (max-width: 360px) {
  .screen {
    padding-left: 14px;
    padding-right: 14px;
  }

  h1 {
    font-size: 33px;
  }

  h2 {
    font-size: 26px;
  }

  .option-button {
    min-height: 62px;
    padding: 14px;
  }

  .score-card {
    grid-template-columns: 1fr;
  }

  .score-number {
    width: 100%;
  }
}
