:root {
  /* Rallie brand palette — extracted from app mockups */
  --ink: #1a1a1a;
  --muted: #6b6b6b;
  --green: #5a7a00;
  --mint: #f0f7d4;
  --lime: #c5e840;
  --cream: #f5f5f5;
  --line: #e0e0e0;
  --white: #ffffff;
  --olive: #4a5e1a;
  --olive-dark: #3d4f10;
  --toggle-green: #2d3d00;
  --sky: #f5f5f5;
  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(--cream);
  color: var(--ink);
}

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

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
}

.brand,
.nav nav {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand {
  font-size: 1.65rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.ball {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background:
    linear-gradient(90deg, transparent 43%, rgba(255, 255, 255, 0.9) 43% 57%, transparent 57%),
    var(--lime);
  box-shadow: inset 0 0 0 2px rgba(61, 79, 16, 0.18);
}

.nav nav {
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 400;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1fr);
  gap: clamp(32px, 7vw, 84px);
  align-items: center;
  width: min(1120px, calc(100% - 32px));
  min-height: calc(100vh - 76px);
  margin: 0 auto;
  padding: 34px 0 76px;
}

.kicker {
  margin: 0 0 14px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1,
h2 {
  margin: 0;
  line-height: 1.02;
  letter-spacing: -0.03em;
}

h1 {
  max-width: 620px;
  font-size: clamp(4rem, 11vw, 8.4rem);
}

.lede {
  max-width: 560px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(1.1rem, 2vw, 1.28rem);
  line-height: 1.65;
}

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

.primary,
.secondary,
button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 0 20px;
  font: inherit;
  font-weight: 600;
}

.primary,
button {
  border: 0;
  background: var(--lime);
  color: var(--olive-dark);
  cursor: pointer;
}

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

.hero-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  background: white;
  box-shadow: 0 26px 80px rgba(61, 79, 16, 0.14);
}

.hero-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.signal-card {
  position: absolute;
  right: 16px;
  bottom: 16px;
  left: 16px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
}

.signal-card span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: uppercase;
}

.signal-card strong {
  display: block;
  margin-top: 3px;
  font-size: 1.08rem;
}

.signal-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.signal-grid p {
  margin: 0;
  border-radius: 8px;
  padding: 10px;
  background: var(--mint);
}

.signal-grid p strong {
  margin: 0;
  font-size: 1.12rem;
}

.signal-grid p span {
  margin-top: 2px;
  font-size: 0.68rem;
}

.strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
  scroll-margin-top: calc(50vh - 105px);
}

.strip article {
  min-height: 210px;
  padding: 28px;
  background: white;
}

.strip span {
  color: var(--green);
  font-weight: 500;
}

.strip h2 {
  margin-top: 34px;
  font-size: 1.35rem;
}

.strip p,
.join-copy p {
  color: var(--muted);
  line-height: 1.6;
}

.join {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(360px, 1fr);
  gap: clamp(32px, 7vw, 84px);
  align-items: start;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: clamp(72px, 10vw, 120px) 0;
}

.join h2 {
  font-size: clamp(2.35rem, 6vw, 5rem);
}

.form {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(20px, 4vw, 30px);
  background: white;
  box-shadow: 0 18px 50px rgba(61, 79, 16, 0.08);
}

.form-step {
  display: none;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  opacity: 0;
  transform: translateY(8px);
}

.form-step.active {
  display: grid;
  opacity: 1;
  transform: translateY(0);
  animation: stepIn 180ms ease-out;
}

.step-label,
.step-copy,
.fine-print,
.form-step h3 {
  grid-column: 1 / -1;
}

.step-label {
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: uppercase;
}

.form-step h3 {
  margin: 0;
  font-size: clamp(1.7rem, 4vw, 2.35rem);
  line-height: 1.05;
}

.success-step {
  text-align: center;
}

.success-step h3,
.success-step .step-copy,
.success-step button,
.reserved-badge {
  grid-column: 1 / -1;
}

.reserved-badge {
  display: inline-flex;
  width: fit-content;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  justify-self: center;
  border-radius: 999px;
  padding: 0 18px;
  background: var(--lime);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: uppercase;
  box-shadow: 0 10px 24px rgba(74, 94, 26, 0.18);
}

.step-copy,
.fine-print {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.fine-print {
  font-size: 0.9rem;
}

@keyframes stepIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

label,
fieldset {
  min-width: 0;
}

label span,
legend {
  display: block;
  margin-bottom: 7px;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 500;
}

label em {
  color: var(--green);
  font-style: normal;
}

input:not([type="checkbox"]) {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 13px;
  background: white;
  color: var(--ink);
  font: inherit;
}

input[readonly] {
  background: var(--cream);
  color: var(--muted);
}

input:focus {
  border-color: var(--olive);
  outline: 3px solid rgba(197, 232, 64, 0.4);
}

fieldset,
.consent,
button,
.form-actions,
.message {
  grid-column: 1 / -1;
}

fieldset {
  margin: 6px 0 0;
  border: 0;
  padding: 0;
}

.check {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  margin-top: 11px;
  color: var(--muted);
  line-height: 1.45;
}

.check input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--olive);
}

.check span {
  margin: 0;
  color: inherit;
  font-size: 0.95rem;
  font-weight: 650;
}

.form-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.ghost-button {
  border: 1px solid var(--line);
  background: white;
  color: var(--olive);
}

.message {
  min-height: 22px;
  margin: 0;
  color: var(--olive);
  font-weight: 850;
}

footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line);
  padding: 26px max(16px, calc((100vw - 1120px) / 2));
  color: var(--muted);
  font-weight: 400;
}

footer span:first-child {
  color: var(--ink);
  font-weight: 400;
}

@media (max-width: 850px) {
  .nav {
    padding: 16px 0 10px;
  }

  .hero,
  .join {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    gap: 30px;
    padding-top: 42px;
    padding-bottom: 54px;
  }

  .hero-card img {
    aspect-ratio: 16 / 10;
    object-position: center 42%;
  }

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

@media (max-width: 560px) {
  body {
    background: var(--cream);
  }

  .nav {
    width: min(100% - 36px, 1120px);
  }

  .nav nav a:first-child {
    display: none;
  }

  .brand {
    font-size: 1rem;
  }

  .ball {
    width: 26px;
    height: 26px;
  }

  .hero,
  .strip,
  .join {
    width: min(100% - 36px, 1120px);
  }

  .hero {
    padding-top: 46px;
    padding-bottom: 42px;
  }

  .kicker {
    margin-bottom: 12px;
    font-size: 0.72rem;
    line-height: 1.35;
  }

  h1 {
    max-width: 9ch;
    font-size: clamp(2.85rem, 13vw, 3.85rem);
    line-height: 1;
  }

  .lede {
    margin-top: 18px;
    font-size: 1rem;
    line-height: 1.55;
  }

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

  .actions {
    gap: 10px;
    margin-top: 28px;
  }

  .hero-card {
    overflow: visible;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .hero-card img {
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px 8px 0 0;
    aspect-ratio: 16 / 9;
    object-position: center center;
    box-shadow: 0 20px 46px rgba(61, 79, 16, 0.12);
  }

  .signal-card {
    position: static;
    border-radius: 0 0 8px 8px;
    border-color: var(--line);
    border-top: 0;
    padding: 14px;
    background: white;
    backdrop-filter: none;
    box-shadow: 0 16px 36px rgba(61, 79, 16, 0.08);
  }

  .signal-card > div:first-child {
    margin-bottom: 10px;
  }

  .signal-card strong {
    font-size: 1rem;
  }

  .signal-grid,
  .form-step,
  .form-actions {
    grid-template-columns: 1fr;
  }

  .signal-grid {
    gap: 8px;
    margin-top: 0;
  }

  .signal-grid p {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    align-items: baseline;
    padding: 10px 12px;
  }

  .signal-grid p strong {
    font-size: 1.08rem;
  }

  .signal-grid p span {
    margin-top: 0;
  }

  .strip article {
    min-height: auto;
    padding: 24px;
  }

  .strip h2 {
    margin-top: 24px;
  }

  .join {
    padding: 64px 0 88px;
  }

  .join h2 {
    font-size: clamp(2.6rem, 13vw, 3.8rem);
  }

  .form {
    padding: 22px;
  }
}
