/* ==========================================================================
   Stylo — Waitlist
   Design tokens lifted directly from /theme (colors, spacing, typography,
   borderRadii, shadows). Keep this file as the single source of truth for
   the tokens — if the theme package changes, update here too.
   ========================================================================== */

:root {
  /* Color */
  --color-black: #000000;
  --color-white: #FFFFFF;

  --color-background: #000000;
  --color-surface: #0A0A0A;
  --color-surface-raised: #141414;
  --color-surface-inverse: #FFFFFF;

  --color-text-primary: #FFFFFF;
  --color-text-secondary: #D6D6D6;
  --color-text-muted: #8A8A8A;
  --color-text-inverse: #000000;

  --color-success-muted: #D9D0D0;
  --color-danger-muted: #D9D0D0;

  --color-border: #242424;
  --color-border-strong: #FFFFFF;
  --color-overlay: rgba(255, 255, 255, 0.08);
  --color-scrim: rgba(0, 0, 0, 0.72);

  /* Spacing */
  --space-none: 0;
  --space-xxs: 2px;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-xxl: 48px;

  /* Border radii */
  --radius-none: 0;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Typography */
  --font-regular: 'Outfit', sans-serif;
  --font-medium: 'Outfit', sans-serif;
  --font-semibold: 'Outfit', sans-serif;
  --font-bold: 'Outfit', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  --fs-hero: 40px;
  --lh-hero: 46px;
  --fs-title: 28px;
  --lh-title: 34px;
  --fs-heading: 20px;
  --lh-heading: 26px;
  --fs-body: 16px;
  --lh-body: 24px;
  --fs-caption: 12px;
  --lh-caption: 16px;

  /* Shadow */
  --shadow-card: 0 12px 24px rgba(255, 255, 255, 0.08);

  /* Layout */
  --container-width: 1180px;
  --header-height: 76px;
}

/* ==========================================================================
   Reset
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background-color: var(--color-background);
  color: var(--color-text-primary);
  font-family: var(--font-regular);
  font-weight: 400;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
  cursor: pointer;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

/* Visible keyboard focus everywhere */
:focus-visible {
  outline: 2px solid var(--color-border-strong);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-md);
  z-index: 100;
  background: var(--color-surface-inverse);
  color: var(--color-text-inverse);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  font-size: var(--fs-caption);
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: var(--space-md);
}

/* ==========================================================================
   Layout helpers
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: var(--space-lg);
}

.eyebrow {
  font-family: var(--font-medium);
  font-weight: 500;
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin: 0 0 var(--space-md);
}

.eyebrow--center {
  text-align: center;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  font-family: var(--font-semibold);
  font-weight: 600;
  font-size: var(--fs-body);
  line-height: 1;
  text-decoration: none;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  padding: var(--space-md) var(--space-xl);
  transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background-color: var(--color-surface-inverse);
  color: var(--color-text-inverse);
}

.btn--primary:hover {
  background-color: var(--color-text-secondary);
}

.btn--ghost {
  background-color: transparent;
  color: var(--color-text-primary);
  border-color: var(--color-border);
}

.btn--ghost:hover {
  border-color: var(--color-border-strong);
}

.btn--small {
  padding: var(--space-sm) var(--space-lg);
  font-size: var(--fs-caption);
  letter-spacing: 0.04em;
}

.btn--large {
  padding: var(--space-lg) var(--space-xxl);
  font-size: var(--fs-heading);
}

.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn__spinner {
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.btn.is-loading .btn__label {
  opacity: 0.5;
}

.btn.is-loading .btn__spinner {
  display: inline-block;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-height);
  display: flex;
  align-items: center;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-bold);
  font-weight: 700;
  font-size: var(--fs-heading);
  letter-spacing: 0.08em;
  text-decoration: none;
  color: var(--color-text-primary);
}

.logo__mark {
  width: 18px;
  height: 18px;
  border-radius: var(--radius-sm);
  background-color: var(--color-surface-inverse);
  flex-shrink: 0;
  display: none;
}

.logo--small {
  font-size: var(--fs-body);
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: var(--space-xxl);
  padding-block: var(--space-xxl) var(--space-xxl);
  min-height: calc(100vh - var(--header-height));
}

.hero__title {
  font-family: var(--font-bold);
  font-weight: 700;
  font-size: clamp(34px, 4.4vw, var(--fs-hero));
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 var(--space-lg);
  color: var(--color-text-primary);
}

.hero__title--muted {
  color: var(--color-text-muted);
}

.hero__body {
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--color-text-secondary);
  max-width: 46ch;
  margin: 0 0 var(--space-xl);
}

/* ---- Waitlist form ---- */

.waitlist-form {
  margin-bottom: var(--space-xl);
}

.waitlist-form__row {
  display: flex;
  gap: var(--space-sm);
  max-width: 460px;
}

.waitlist-form__input {
  flex: 1;
  min-width: 0;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  color: var(--color-text-primary);
  font-family: var(--font-regular);
  font-size: var(--fs-body);
  padding: var(--space-md) var(--space-lg);
  transition: border-color 0.15s ease;
  outline: none;
}

.waitlist-form__input::placeholder {
  color: var(--color-text-muted);
}


.waitlist-form__input.is-invalid {
  border-color: var(--color-danger-muted);
}

.waitlist-form__message {
  margin-top: var(--space-sm);
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
  color: var(--color-text-muted);
  min-height: var(--lh-caption);
}

.waitlist-form__message.is-error {
  color: var(--color-danger-muted);
}

.waitlist-form__message.is-success {
  color: var(--color-text-primary);
  font-family: var(--font-medium);
  font-weight: 500;
}

/* ---- Social proof ---- */

.social-proof {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.social-proof__avatars {
  display: flex;
}

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--color-background);
  background-color: var(--color-surface-raised);
}

.avatar--1 { background: linear-gradient(135deg, #3a3a3a, #1a1a1a); }
.avatar--2 { background: linear-gradient(135deg, #4d4d4d, #222); margin-left: -8px; }
.avatar--3 { background: linear-gradient(135deg, #6a6a6a, #2b2b2b); margin-left: -8px; }

.social-proof__text {
  font-size: var(--fs-caption);
  color: var(--color-text-muted);
}

.counter {
  font-family: var(--font-mono);
  color: var(--color-text-primary);
  font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   Hero swipe demo (signature element)
   ========================================================================== */

.hero__demo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-lg);
}

.swipe-deck {
  position: relative;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 3 / 4.3;
  touch-action: none;
}

.swipe-card {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background-color: var(--color-surface);
  /* border: 1px solid var(--color-border); */
  border-radius: var(--radius-lg);
  overflow: hidden;
  /* box-shadow: var(--shadow-card); */
  transform-origin: bottom center;
  will-change: transform, opacity;
}

/* Resting stack offsets for the three cards behind the active one */
.swipe-card[data-tone="1"] {
  transform: translateY(14px) scale(0.97);
  z-index: 1;
}
.swipe-card[data-tone="2"] {
  transform: translateY(28px) scale(0.94);
  z-index: 0;
  opacity: 0.85;
}
.swipe-card[data-tone="3"] {
  transform: translateY(42px) scale(0.91);
  z-index: -1;
  opacity: 0.6;
}

.swipe-card--top {
  z-index: 2;
  cursor: grab;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease;
}

.swipe-card--top.is-dragging {
  cursor: grabbing;
  transition: none;
}

.swipe-card--top.is-leaving {
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease;
}

.swipe-card__visual {
  flex: 1;
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  padding: var(--space-md);
}

/* Distinct grayscale "fabric" treatments per tone, no imagery required */
.swipe-card__visual--0 {
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.05) 0 2px, transparent 2px 14px),
    linear-gradient(160deg, #1c1c1c 0%, #050505 100%);
}
.swipe-card__visual--1 {
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,0.04) 0 2px, transparent 2px 16px),
    linear-gradient(160deg, #232323 0%, #0a0a0a 100%);
}
.swipe-card__visual--2 {
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 18px),
    linear-gradient(160deg, #1a1a1a 0%, #060606 100%);
}
.swipe-card__visual--3 {
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 20px),
    linear-gradient(160deg, #202020 0%, #070707 100%);
}

.swipe-card__tag {
  font-family: var(--font-mono);
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
  letter-spacing: 0.04em;
  background-color: var(--color-overlay);
  border: 1px solid var(--color-border);
  color: var(--color-text-inverse);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  backdrop-filter: blur(10px);
}

.swipe-card__info {
  padding: var(--space-md) var(--space-lg) var(--space-lg);
  border-top: 1px solid var(--color-border);
}

.swipe-card__info h3 {
  font-family: var(--font-semibold);
  font-weight: 600;
  font-size: var(--fs-heading);
  line-height: var(--lh-heading);
  margin-bottom: var(--space-xs);
}

.swipe-card__info p {
  font-size: var(--fs-caption);
  line-height: var(--lh-caption);
  color: var(--color-text-muted);
}

#card-1{
    background-position: center;
    background-size: cover;
    background-image: url("https://images.unsplash.com/photo-1594435763464-05f0624e04c9?q=80&w=987&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}
#card-2{
    background-position: center;
    background-size: cover;
    background-image: url("https://images.unsplash.com/photo-1683115764876-074c9b3a29a2?q=80&w=987&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}
#card-3{
    background-position: center;
    background-size: cover;
    background-image: url("https://images.unsplash.com/photo-1768745534123-a491d5d33059?q=80&w=987&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}
#card-4{
    background-position: center;
    background-size: cover;
    background-image: url("https://images.unsplash.com/photo-1715765113469-63b2da1ff81c?q=80&w=987&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}

/* Like / pass indicator badges on the active card */
.swipe-card__badge {
  position: absolute;
  top: var(--space-lg);
  z-index: 3;
  font-family: var(--font-bold);
  font-weight: 700;
  font-size: var(--fs-heading);
  letter-spacing: 0.12em;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-sm);
  border: 2px solid currentColor;
  opacity: 0;
  transition: opacity 0.1s ease;
}

.swipe-card__badge--like {
  right: var(--space-lg);
  color: var(--color-text-primary);
  transform: rotate(8deg);
}

.swipe-card__badge--pass {
  left: var(--space-lg);
  color: var(--color-text-muted);
  transform: rotate(-8deg);
}

/* ---- Controls below deck ---- */

.swipe-controls {
  display: flex;
  gap: var(--space-lg);
}

.swipe-btn {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-pill);
  /* border: 1px solid var(--color-border); */
  background-color: var(--color-surface);
  color: var(--color-text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease, transform 0.15s ease;
  outline: none;
  border: none;
  margin-top: 50px;
}

.swipe-btn:hover {
  border-color: var(--color-border-strong);
}

.swipe-btn:active {
  transform: scale(0.94);
}

.swipe-btn--like {
  color: var(--color-text-primary);
}

.swipe-hint {
  font-size: var(--fs-caption);
  color: var(--color-text-muted);
}

/* ==========================================================================
   How it works
   ========================================================================== */

.how {
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background-color: var(--color-surface);
  padding-block: var(--space-xxl);
}

.how__title {
  font-family: var(--font-bold);
  font-weight: 700;
  font-size: clamp(26px, 3.6vw, var(--fs-title));
  line-height: var(--lh-title);
  text-align: center;
  max-width: 18ch;
  margin: 0 auto var(--space-xxl);
}

.how__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
}

.how__item {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
}

.how__index {
  font-family: var(--font-mono);
  font-size: var(--fs-caption);
  color: var(--color-text-muted);
  letter-spacing: 0.08em;
}

.how__item h3 {
  font-family: var(--font-semibold);
  font-weight: 600;
  font-size: var(--fs-heading);
  line-height: var(--lh-heading);
}

.how__item p {
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--color-text-muted);
}

/* ==========================================================================
   Closing CTA
   ========================================================================== */

.closing {
  text-align: center;
  padding-block: var(--space-xxl) calc(var(--space-xxl) * 1.5);
}

.closing__title {
  font-family: var(--font-bold);
  font-weight: 700;
  font-size: clamp(28px, 4vw, var(--fs-title));
  line-height: var(--lh-title);
  margin: 0 auto var(--space-md);
  max-width: 18ch;
}

.closing__body {
  color: var(--color-text-muted);
  max-width: 48ch;
  margin: 0 auto var(--space-xl);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--color-border);
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-md);
  padding-block: var(--space-xl);
}

.site-footer__copy {
  font-size: var(--fs-caption);
  color: var(--color-text-muted);
}

.site-footer__links {
  display: flex;
  gap: var(--space-lg);
  font-size: var(--fs-caption);
}

.site-footer__links a {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.site-footer__links a:hover {
  color: var(--color-text-primary);
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-block: var(--space-xl);
    gap: var(--space-xxl);
  }

  .hero__demo {
    order: -1;
  }

  .swipe-deck {
    max-width: 280px;
  }

  .how__list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .container {
    padding-inline: var(--space-md);
  }

  .waitlist-form__row {
    flex-direction: column;
  }

  .btn--primary.btn--small,
  .waitlist-form__row .btn {
    width: 100%;
  }

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

  .site-footer__inner {
    flex-direction: column;
    text-align: center;
  }
}