/* heylife.ai landing — Watercolor (light) + Dark Cosmic (dark) */

@font-face {
  font-family: 'Stolzl';
  src: url('./fonts/stolzl-regular.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

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

:root {
  --font-body:    Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-heading: Stolzl, 'Inter Display', Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* ───────── theme tokens ───────── */
:root,
[data-theme='light'] {
  --bg:            #FBF6EE;
  --text:          #3A3530;
  --text-strong:   #1F2A1E;
  --text-muted:    #5C6B5A;
  --text-faint:    #7A7064;
  --accent:        #5E8A4B;
  --accent-solid:  #5E8A4B;
  --accent-rgb:    94 138 75;
  --pill-health:   #83AF6F;
  --pill-craft:    #D88F58;
  --pill-rel:      #C97A98;
  --pill-health-strong: #5E8A4B;
  --pill-craft-strong:  #B86A2E;
  --pill-rel-strong:    #A35578;
  --input-bg:      #ffffff;
  --input-border:  rgba(0, 0, 0, 0.094);
  --input-text:    #1F2A1E;
  --rule:          rgba(0, 0, 0, 0.063);
  --nav-link:      #5C6B5A;
  --logo-color:    #3A3530;
  --toggle-bg:     rgba(0, 0, 0, 0.04);
  --toggle-border: rgba(0, 0, 0, 0.08);
  --toggle-text:   #5C6B5A;
}

[data-theme='dark'] {
  --bg:            #0B1314;
  --text:          #E5EDED;
  --text-strong:   #F4F8F7;
  --text-muted:    #A8B8B5;
  --text-faint:    #7A8E89;
  --accent:        #A8E6D6;
  --accent-solid:  #3FA88E;
  --accent-rgb:    168 230 214;
  --pill-health:   #A8E6D6;
  --pill-craft:    #E8C8A8;
  --pill-rel:      #D8B0E0;
  --pill-health-strong: #A8E6D6;
  --pill-craft-strong:  #E8C8A8;
  --pill-rel-strong:    #D8B0E0;
  --input-bg:      rgba(255, 255, 255, 0.031);
  --input-border:  rgba(255, 255, 255, 0.125);
  --input-text:    #F4F8F7;
  --rule:          rgba(255, 255, 255, 0.063);
  --nav-link:      #9BB0AB;
  --logo-color:    #E5EDED;
  --toggle-bg:     rgba(255, 255, 255, 0.04);
  --toggle-border: rgba(255, 255, 255, 0.10);
  --toggle-text:   #9BB0AB;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 240ms ease, color 240ms ease;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
button { font: inherit; }

/* ───────── theme show/hide ───────── */
.only-light { display: block; }
.only-dark  { display: none; }
[data-theme='dark'] .only-light { display: none; }
[data-theme='dark'] .only-dark  { display: block; }

/* ───────── scenery (background art) ───────── */
.scene {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

/* watercolor washes + sparkles */
.scene-light .washes {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.5;
}
.scene-light .sparkle {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.4;
}

/* dark cosmic nebulae + stars */
.scene-dark .nebula {
  position: absolute;
  border-radius: 50%;
}
.scene-dark .nebula.tr {
  right: -200px;
  top: -200px;
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(29, 77, 66, 0.20) 0%, transparent 70%);
}
.scene-dark .nebula.bl {
  left: -100px;
  bottom: -100px;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(94, 61, 110, 0.13) 0%, transparent 70%);
}
.scene-dark .star {
  position: absolute;
  border-radius: 50%;
  background: #E5EDED;
}

/* ───────── page layout ───────── */
.page {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 1280px;
  margin: 0 auto;
}

/* ───────── nav ───────── */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px clamp(20px, 4.5vw, 56px);
  gap: 16px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: var(--logo-color);
  letter-spacing: -0.3px;
}
.logo .tld { opacity: 0.5; font-weight: 700; }
.logo svg { color: var(--logo-color); display: block; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 13px;
  color: var(--nav-link);
}
.nav-links a { transition: color 160ms ease; }
.nav-links a:hover { color: var(--text-strong); }

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--toggle-bg);
  border: 1px solid var(--toggle-border);
  color: var(--toggle-text);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  transition: background 160ms ease, color 160ms ease, border-color 160ms ease;
}
.theme-toggle:hover { color: var(--text-strong); }
.theme-toggle svg { display: block; width: 12px; height: 12px; }

/* ───────── hero ───────── */
.hero {
  position: relative;
  flex: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(24px, 4vw, 60px);
  align-items: center;
  padding: 0 clamp(20px, 4.5vw, 56px);
}
[data-theme='dark'] .hero {
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(24px, 3.5vw, 50px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 2.5px;
  color: var(--accent);
  font-weight: 700;
  margin: 0 0 22px;
  text-transform: none;
}
.eyebrow .glow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}
.eyebrow .diamond {
  width: 8px;
  height: 8px;
  background: var(--accent);
  transform: rotate(45deg);
  display: inline-block;
}

h1.headline {
  font-family: var(--font-heading);
  font-size: clamp(40px, 5.6vw, 60px);
  line-height: 1.02;
  letter-spacing: -1.5px;
  font-weight: 700;
  margin: 0;
  color: var(--text-strong);
}
[data-theme='dark'] h1.headline {
  font-size: clamp(42px, 6vw, 64px);
  line-height: 1.0;
  letter-spacing: -1.8px;
}
h1.headline .gradient {
  background: linear-gradient(135deg, #A8E6D6 0%, #C9B5E8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.subhead {
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 22px 0 0;
  max-width: 480px;
}
[data-theme='dark'] .subhead {
  font-size: 16px;
  line-height: 1.6;
  margin-top: 24px;
}
.subhead .pill-health { color: var(--pill-health-strong); font-weight: 600; }
.subhead .pill-craft  { color: var(--pill-craft-strong);  font-weight: 600; }
.subhead .pill-rel    { color: var(--pill-rel-strong);    font-weight: 600; }
[data-theme='dark'] .subhead .closer { color: #E5EDED; }

/* waitlist */
.waitlist {
  margin-top: 30px;
  display: flex;
  gap: 8px;
  max-width: 420px;
}
[data-theme='dark'] .waitlist { margin-top: 32px; }
.waitlist input {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--input-border);
  background: var(--input-bg);
  color: var(--input-text);
  font-size: 14px;
  font-family: var(--font-body);
  outline: none;
  transition: border-color 160ms ease;
}
.waitlist input::placeholder { color: var(--text-faint); }
.waitlist input:focus { border-color: var(--accent); }

.waitlist button {
  padding: 12px 18px;
  border-radius: 10px;
  border: 0;
  background: var(--accent-solid);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font-body);
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: filter 160ms ease, transform 160ms ease;
}
.waitlist button:hover { filter: brightness(1.08); }
.waitlist button:active { transform: translateY(1px); }
.waitlist.is-done button { background: var(--accent-solid); }

/* ───── waitlist success card ───── */
.waitlist-area.is-done .waitlist,
.waitlist-area.is-done .proof { display: none; }

.waitlist-success {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  max-width: 460px;
  margin-top: 8px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 1px solid var(--input-border);
  background: linear-gradient(180deg,
    rgb(var(--accent-rgb) / 0.10) 0%,
    rgb(var(--accent-rgb) / 0.02) 100%);
  box-shadow: 0 8px 24px -16px rgb(var(--accent-rgb) / 0.45);
  animation: success-rise 360ms cubic-bezier(.2,.7,.2,1) both;
}
.waitlist-success[hidden] { display: none; }

.waitlist-success .success-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-solid);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 6px rgb(var(--accent-rgb) / 0.18);
}
[data-theme='dark'] .waitlist-success .success-icon {
  color: #0B1314;
  background: var(--accent);
}
.waitlist-success .success-icon svg {
  width: 22px;
  height: 22px;
  display: block;
}

.waitlist-success .success-body { min-width: 0; }
.waitlist-success .success-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--text-strong);
  margin: 0 0 4px;
  line-height: 1.2;
}
.waitlist-success .success-sub {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}
.waitlist-success .success-email {
  color: var(--text-strong);
  font-weight: 600;
  word-break: break-all;
}

@keyframes success-rise {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

.proof {
  font-size: 12px;
  color: var(--text-faint);
  margin-top: 12px;
}
[data-theme='dark'] .proof {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 1px;
  margin-top: 14px;
}

/* ───────── orbit visualization (light · watercolor) ───────── */
.orbit {
  position: relative;
  width: 100%;
  max-width: 540px;
  aspect-ratio: 1 / 1;
  margin: 0 auto;
}

.orbit-light .rings {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.orbit-light .pillar {
  position: absolute;
  width: 23.91%;       /* 110/460 */
  height: 23.91%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.orbit-light .pillar .hex { width: 100%; height: 100%; display: block; }
.orbit-light .pillar .icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.orbit-light .pillar .icon svg { width: 36%; height: 36%; }
.orbit-light .pillar .label {
  position: absolute;
  top: 100%;
  left: 50%;
  margin-top: 8px;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  white-space: nowrap;
}
.orbit-light .sun {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: #fffac8;
  border: 1px solid rgba(0, 0, 0, 0.063);
  box-shadow: 0 0 30px #fffac8;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
}

/* ───────── orbit visualization (dark · cosmic) ───────── */
.orbit-dark .rings,
.orbit-dark .satellite-icons {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.orbit-dark .satellite-icons .sat-icon {
  position: absolute;
  pointer-events: none;
  transform: translate(-50%, -50%);
}

/* ───────── footer ───────── */
.foot {
  position: relative;
  padding: 20px clamp(20px, 4.5vw, 56px);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 11px;
  color: var(--text-faint);
  font-family: var(--font-mono);
  letter-spacing: 1px;
  border-top: 1px solid var(--rule);
}

/* ───────── responsive ───────── */
@media (max-width: 880px) {
  .hero,
  [data-theme='dark'] .hero {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 16px 20px 40px;
  }
  .orbit { max-width: 420px; }
  .nav-links { gap: 12px; font-size: 12px; }
  .nav-links a:not(.theme-toggle) { display: none; }
  h1.headline,
  [data-theme='dark'] h1.headline { font-size: clamp(36px, 9vw, 48px); }
  .foot { flex-direction: column; gap: 4px; }
  .waitlist { max-width: 100%; }
  .subhead { max-width: 100%; }
}

/* Hidden host for the EmailOctopus embed.
   Off-screen but still in the DOM so the embed can run and submit. */
.eo-host {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  left: -9999px;
  top: 0;
  pointer-events: none;
}

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