/* ===== BASE ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --font: 'Bricolage Grotesque', system-ui, sans-serif;
  --white: #ffffff;
  --bg: #fafafa;
  --tint: #f5f5f7;
  --border: #e5e5ea;
  --text: #111111;
  --muted: #6b7280;
  --dim: #9ca3af;
  --accent: #5b5bd6;
  --accent-light: #eeefff;
  --green: #16a34a;
  --red: #dc2626;
  --radius: 0.875rem;
  --radius-sm: 0.5rem;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.08);
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* ===== LAYOUT ===== */
.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.wrap-narrow {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

.section-tinted {
  background: var(--tint);
}

/* ===== TYPOGRAPHY ===== */
.section-label {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.875rem;
}

.label-light {
  color: rgba(255,255,255,0.65);
}

.section-h2 {
  font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 2.5rem;
  color: var(--text);
}

.section-h2 em {
  font-style: normal;
  color: var(--accent);
}

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(16px) saturate(1.8);
  -webkit-backdrop-filter: blur(16px) saturate(1.8);
  border-bottom: 1px solid transparent;
  transition: var(--transition);
}

.nav.scrolled {
  border-color: var(--border);
  background: rgba(255,255,255,0.92);
}

.nav-inner {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: opacity 0.2s;
}

.logo:hover {
  opacity: 0.75;
}

.logo-img {
  height: 28px;
  width: auto;
  display: block;
}

.logo-img-sm {
  height: 24px;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin-left: auto;
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--text);
}

.btn-nav {
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
}

.btn-nav:hover {
  opacity: 0.7;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
  padding: 0.25rem;
}

.hamburger span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}

.mobile-menu {
  display: none;
  flex-direction: column;
  padding: 0.75rem 1.5rem 1.25rem;
  border-top: 1px solid var(--border);
  gap: 0.25rem;
}

.mobile-menu.open {
  display: flex;
}

.mobile-link {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  padding: 0.5rem 0;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.mobile-link:hover {
  color: var(--accent);
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font);
  font-weight: 700;
  font-size: 0.9375rem;
  background: var(--accent);
  color: #fff;
  padding: 0.6875rem 1.5rem;
  border-radius: var(--radius-sm);
  border: none;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: #4a4abf;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(91,91,214,0.28);
}

.btn-primary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--muted);
  text-decoration: none;
  padding: 0.6875rem 1.25rem;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.btn-ghost:hover {
  color: var(--text);
  background: var(--tint);
}

.btn-white {
  background: #fff;
  color: var(--accent);
}

.btn-white:hover {
  background: #f8f8ff;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  padding-top: 60px;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-visual {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 58%;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: left center;
  display: block;
  padding: 80px 0 2rem 2vw;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    transparent 0%,
    transparent 38%,
    rgba(255,255,255,0.55) 46%,
    rgba(255,255,255,0.92) 54%,
    var(--white) 58%
  );
  pointer-events: none;
  z-index: 1;
}

.hero-text-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  align-items: center;
  min-height: calc(100vh - 60px);
}

.hero-text {
  margin-left: auto;
  width: 50%;
  max-width: 520px;
  padding: 3rem 4vw 3rem 1.5rem;
}

.hero-label {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-light);
  padding: 0.3125rem 0.875rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}

.hero-h1 {
  font-size: clamp(2rem, 2.8vw, 2.75rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.025em;
  margin-bottom: 1rem;
  color: var(--text);
  text-wrap: balance;
}

.hero-h1 em {
  font-style: normal;
  color: var(--accent);
}

.hero-sub {
  font-size: 1rem;
  color: var(--muted);
  max-width: 380px;
  margin-bottom: 1.75rem;
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.hero-trust {
  margin-top: 1.25rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--dim);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-trust::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

/* ===== FEATURE CARDS ===== */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.625rem 1.375rem;
  transition: var(--transition);
}

.card:hover {
  border-color: #d4d4d8;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-icon {
  font-size: 1.625rem;
  margin-bottom: 0.875rem;
  line-height: 1;
}

.card h3 {
  font-size: 0.9375rem;
  font-weight: 700;
  margin-bottom: 0.375rem;
  color: var(--text);
}

.card p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ===== STEPS ===== */
.steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 0;
  align-items: start;
}

.step {
  text-align: center;
  padding: 0 1.5rem;
}

.step-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 800;
  margin: 0 auto 0.875rem;
}

.step h3 {
  font-size: 0.9375rem;
  font-weight: 700;
  margin-bottom: 0.375rem;
  color: var(--text);
}

.step p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.55;
}

.step-arrow {
  font-size: 1.125rem;
  color: var(--dim);
  padding-top: 0.375rem;
  align-self: flex-start;
}

/* ===== STORY ===== */
.story-text {
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 0.875rem;
}

.story-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.75rem;
}

.pill {
  font-size: 0.8125rem;
  font-weight: 600;
  background: var(--white);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.3125rem 0.875rem;
  border-radius: 999px;
  transition: var(--transition);
}

.pill:hover {
  border-color: var(--dim);
}

.pill-accent {
  background: var(--accent-light);
  border-color: var(--accent-light);
  color: var(--accent);
}

/* ===== JOIN ===== */
.section-join {
  background: var(--accent);
  color: #fff;
  text-align: center;
}

.section-join .section-label {
  text-align: center;
}

.join-h2 {
  font-size: clamp(1.875rem, 3.8vw, 2.875rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 1.75rem;
  text-align: center;
}

.join-tabs {
  display: inline-flex;
  background: rgba(255,255,255,0.12);
  border-radius: var(--radius-sm);
  padding: 0.25rem;
  margin-bottom: 1.5rem;
  gap: 0.25rem;
}

.jtab {
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  background: none;
  color: rgba(255,255,255,0.6);
  transition: var(--transition);
}

.jtab:hover {
  color: rgba(255,255,255,0.9);
}

.jtab.active {
  background: #fff;
  color: var(--accent);
}

.jtab:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 1px;
}

.jpanel {
  text-align: center;
}

.jpanel.hidden {
  display: none;
}

.jpanel p {
  color: rgba(255,255,255,0.85);
  margin-bottom: 1.25rem;
  font-size: 0.9375rem;
}

.wl-form {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  max-width: 380px;
  margin: 0 auto;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  text-align: left;
}

.wl-form input {
  width: 100%;
  font-family: var(--font);
  font-size: 0.9375rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.12);
  color: #fff;
  outline: none;
  transition: var(--transition);
}

.wl-form input::placeholder {
  color: rgba(255,255,255,0.5);
}

.wl-form input:focus {
  background: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.45);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.15);
}

.wl-form input.wl-input-error {
  background: rgba(220, 38, 38, 0.18);
  border-color: rgba(255, 100, 100, 0.7);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.25);
}

.wl-error {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #ffcccc;
  text-align: left;
  min-height: 1.2rem;
  line-height: 1.3;
}

.wl-message {
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin-top: 1.25rem;
  max-width: 380px;
  margin-left: auto;
  margin-right: auto;
  font-weight: 600;
}

.wl-message p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
}

#wl-success {
  background: #14532d;
  border: 1px solid #22c55e;
}

#wl-success p {
  color: #ffffff;
}

#wl-error {
  background: #7f1d1d;
  border: 1px solid #ef4444;
}

#wl-error p {
  color: #ffffff;
}

#wl-success.hidden,
#wl-error.hidden,
#wl-form.hidden {
  display: none;
}

#wl-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ===== FAQ ===== */
.faqs {
  display: flex;
  flex-direction: column;
}

.faq {
  border-bottom: 1px solid var(--border);
}

.faq-q {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.125rem 0;
  font-family: var(--font);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text);
  text-align: left;
  gap: 1rem;
  transition: var(--transition);
}

.faq-q:hover {
  color: var(--accent);
}

.faq-q:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.fchev {
  font-size: 1rem;
  color: var(--dim);
  flex-shrink: 0;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-style: normal;
}

.faq-q[aria-expanded="true"] .fchev {
  transform: rotate(45deg);
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-a p {
  padding: 0 0 1.125rem;
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.65;
}

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--dim);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--muted);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--text);
}

/* ===== REVEAL ANIMATION ===== */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 860px) {
  .section {
    padding: 4rem 0;
  }

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

  .steps {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .step {
    padding: 1rem 0;
    text-align: left;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
  }

  .step-num {
    margin: 0;
    flex-shrink: 0;
  }

  .step-arrow {
    display: none;
  }

  .nav-right {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .hero {
    min-height: unset;
    flex-direction: column;
  }

  .hero-visual {
    position: relative;
    width: 100%;
    height: 52vw;
    min-height: 240px;
  }

  .hero-img {
    padding: 60px 1rem 1rem;
    object-position: center top;
  }

  .hero-overlay {
    background: linear-gradient(to bottom, transparent 50%, var(--white) 88%);
    z-index: 1;
  }

  .hero-text-wrap {
    min-height: unset;
    justify-content: center;
  }

  .hero-text {
    width: 100%;
    max-width: 100%;
    padding: 1.5rem 1.5rem 2.5rem;
    text-align: center;
  }

  .hero-sub {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-trust {
    justify-content: center;
  }
}

@media (max-width: 560px) {
  .cards {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 5.5rem 0 2rem;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
  }

  .step {
    padding: 0.875rem 0;
  }

  .story-pills {
    justify-content: center;
  }
}

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

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
