/* ===========================================================================
   Wellness Docs — Free Benefits Check Funnel
   Brand palette pulled from wellnessdocs.com
   =========================================================================== */

:root {
  --brand-blue: #26ACE2;
  --brand-blue-light: #34BCF3;
  --brand-blue-dark: #1E8DBB;
  --brand-black: #22211E;
  --brand-black-soft: #2D2C28;
  --ink: #373531;
  --ink-soft: #6B6964;
  --ink-muted: #9E9C97;
  --cream: #FAFAF7;
  --grey: #F5F5F7;
  --line: #E8E7E3;
  --white: #FFFFFF;

  --radius-sm: 0.6rem;
  --radius-md: 0.8rem;
  --radius-lg: 1rem;
  --radius-xl: 1.4rem;

  --shadow-sm: 0 1px 2px rgba(20, 24, 40, 0.06);
  --shadow-md: 0 4px 8px rgba(20, 24, 40, 0.04), 0 24px 48px -16px rgba(20, 24, 40, 0.12);
  --shadow-blue: 0 1px 2px rgba(20, 24, 40, 0.06), 0 12px 24px -10px rgba(38, 172, 226, 0.5);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Rubik', -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  background: var(--cream);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
  background-image:
    radial-gradient(ellipse 60% 40% at 50% -10%, rgba(38, 172, 226, 0.10), transparent 70%),
    radial-gradient(ellipse 50% 30% at 100% 100%, rgba(38, 172, 226, 0.06), transparent 60%);
  background-attachment: fixed;
}

/* ---------- Layout ---------- */

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1.25rem 3rem;
}

.brand-bar {
  width: 100%;
  max-width: 540px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 0 1.75rem;
}

.brand-bar img {
  height: 38px;
  width: auto;
  display: block;
}

.card {
  width: 100%;
  max-width: 540px;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2rem 1.75rem 2rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--line);
}

@media (min-width: 640px) {
  .card { padding: 2.5rem 2.25rem; }
  .page { padding: 2.5rem 1.5rem 4rem; }
}

/* ---------- Progress ---------- */

.progress {
  display: flex;
  gap: 6px;
  margin-bottom: 1.75rem;
}
.progress span {
  flex: 1;
  height: 4px;
  background: var(--line);
  border-radius: 999px;
  transition: background 0.3s ease;
}
.progress span.active { background: var(--brand-blue); }

/* ---------- Typography ---------- */

.eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand-blue);
  margin-bottom: 0.6rem;
}

h1 {
  font-family: 'Rubik', sans-serif;
  font-weight: 600;
  font-size: 1.85rem;
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--brand-black);
  margin-bottom: 0.65rem;
}

@media (min-width: 640px) {
  h1 { font-size: 2.25rem; }
}

.lede {
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.5;
  margin-bottom: 1.75rem;
}

/* ---------- Form ---------- */

form { display: flex; flex-direction: column; gap: 1rem; }

.field { display: flex; flex-direction: column; gap: 0.4rem; }

.field label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--brand-black);
  letter-spacing: -0.005em;
}

.field .hint {
  font-size: 0.75rem;
  color: var(--ink-muted);
  font-weight: 400;
}

.field input,
.field select {
  font-family: inherit;
  font-size: 1rem;
  padding: 0.85rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--white);
  color: var(--ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  width: 100%;
}

.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 4px rgba(38, 172, 226, 0.15);
}

.field input::placeholder { color: var(--ink-muted); }

.row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 480px) {
  .row.two { grid-template-columns: 1fr 1fr; }
}

/* ---------- Button ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 1rem 1.75rem;
  background: var(--brand-blue);
  color: var(--white);
  border: none;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.005em;
  cursor: pointer;
  width: 100%;
  margin-top: 0.5rem;
  box-shadow: var(--shadow-blue);
  transition: background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.btn:hover {
  background: var(--brand-blue-dark);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(20, 24, 40, 0.08), 0 18px 32px -12px rgba(38, 172, 226, 0.6);
}
.btn:active { transform: translateY(0); }
.btn[disabled] { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn .arrow { transition: transform 0.25s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ---------- Trust strip ---------- */

.trust {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: var(--ink-muted);
  text-align: center;
}
.trust svg { flex-shrink: 0; }

/* ---------- Voucher page ---------- */

.voucher-card {
  text-align: center;
}

.voucher-icon {
  width: 88px;
  height: 88px;
  margin: 0 auto 1.5rem;
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--brand-blue-light) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 32px -8px rgba(38, 172, 226, 0.5);
  position: relative;
}
.voucher-icon::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1.5px solid rgba(38, 172, 226, 0.25);
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0%   { transform: scale(0.92); opacity: 0.9; }
  100% { transform: scale(1.18); opacity: 0; }
}

.voucher-amount {
  margin: 1.25rem 0 0.4rem;
  font-family: 'Rubik', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-blue);
}

.benefits-list {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 1.25rem;
  background: var(--grey);
  border-radius: var(--radius-md);
  text-align: left;
}
.benefits-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.4rem 0;
  font-size: 0.95rem;
  color: var(--ink);
}
.benefits-list svg { flex-shrink: 0; margin-top: 2px; color: var(--brand-blue); }

/* ---------- Footer ---------- */

.foot {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--ink-muted);
  max-width: 540px;
}
.foot a { color: var(--ink-soft); text-decoration: underline; }

/* ---------- Loading state ---------- */

.spinner {
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Errors ---------- */

.field input.invalid,
.field select.invalid {
  border-color: #DC2626;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.10);
}
.error-msg {
  margin-top: 0.5rem;
  padding: 0.65rem 0.85rem;
  background: #FEE2E2;
  color: #991B1B;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
