/* ============================================================
   EyeProtector landing — light, Apple-like, app-token palette
   bg #FAFAFA · card #FFF · ink #1C1C1E · gray #8A8A8E · accent #007AFF
   ============================================================ */

:root {
  --bg: #fafafa;
  --card: #ffffff;
  --ink: #1c1c1e;
  --ink-2: #6e6e73;
  --gray: #8a8a8e;
  --hairline: rgba(60, 60, 67, 0.14);
  --accent: #007aff;
  --teal: #0ab8a6;
  --night: #0b1220;
  --radius: 16px;
  --shadow-soft: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 28px rgba(0, 0, 0, 0.07);
  --shadow-deep: 0 2px 6px rgba(0, 0, 0, 0.08), 0 24px 64px rgba(11, 18, 32, 0.22);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; }
a { color: inherit; text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- reveal-on-scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.in { opacity: 1; transform: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.25s, background 0.25s;
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(0.98); }

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 16px rgba(0, 122, 255, 0.35);
}
.btn-primary:hover { box-shadow: 0 8px 24px rgba(0, 122, 255, 0.42); }

.btn-ghost {
  background: rgba(120, 120, 128, 0.12);
  color: var(--ink);
}
.btn-ghost:hover { background: rgba(120, 120, 128, 0.2); }

.btn-sm { padding: 8px 18px; font-size: 14px; }

.btn-light { background: #fff; color: var(--night); box-shadow: 0 4px 20px rgba(0,0,0,0.18); }
.btn-outline {
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  color: #fff;
}
.btn-outline:hover { background: rgba(255, 255, 255, 0.12); }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  background: rgba(250, 250, 250, 0.78);
  border-bottom: 1px solid var(--hairline);
}
.nav-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.02em;
  color: var(--accent);
}
.brand span { color: var(--ink); }
.brand-mark { width: 26px; height: 26px; }

.nav-links {
  display: flex;
  gap: 26px;
  margin-left: auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
}
.nav-links a { transition: color 0.2s; }
.nav-links a:hover { color: var(--ink); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  max-width: 1120px;
  margin: 0 auto;
  padding: 88px 24px 72px;
  display: grid;
  grid-template-columns: minmax(0, 460px) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: -1;
  will-change: transform;
}
.hero-glow-a {
  width: 480px; height: 480px;
  background: rgba(10, 184, 166, 0.16);
  top: -120px; right: -60px;
}
.hero-glow-b {
  width: 420px; height: 420px;
  background: rgba(0, 122, 255, 0.13);
  bottom: -140px; left: -120px;
}

.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 18px;
}

.hero h1 {
  font-size: clamp(40px, 5.4vw, 62px);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.035em;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(100deg, var(--accent), var(--teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  margin-top: 22px;
  font-size: 18px;
  color: var(--ink-2);
  max-width: 44ch;
}

.cta-row {
  margin-top: 34px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.cta-row.center { justify-content: center; }

.cta-note {
  margin-top: 16px;
  font-size: 13px;
  color: var(--gray);
}

/* ---------- hero break-screen mockup (signature) ---------- */
.hero-demo { min-width: 0; }

.mac-window {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-deep);
}
.break-window {
  transform: perspective(1400px) rotateY(-4deg) rotateX(1.5deg);
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.break-window:hover { transform: perspective(1400px) rotateY(0) rotateX(0); }

.mac-titlebar {
  display: flex;
  gap: 7px;
  padding: 11px 13px;
}
.mac-titlebar.dark { background: #101827; }
.dot { width: 11px; height: 11px; border-radius: 50%; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.break-screen {
  position: relative;
  padding: 34px 24px 30px;
  min-height: 430px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  overflow: hidden;
  background: var(--night);
  isolation: isolate;
}

.break-ambient {
  position: absolute;
  z-index: -1;
  inset: -40%;
  background:
    radial-gradient(circle at 30% 30%, #1e3a8a, transparent 55%),
    radial-gradient(circle at 70% 70%, #0f766e, transparent 55%),
    linear-gradient(#0b1220, #0b1220);
  animation: ambient-drift 22s linear infinite alternate;
  will-change: transform;
}
@keyframes ambient-drift {
  from { transform: translate(-4%, -4%) scale(1); }
  to { transform: translate(4%, 4%) scale(1.08); }
}

.break-ring-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 26px;
  width: clamp(160px, 40vw, 240px);
  height: clamp(160px, 40vw, 240px);
}
.break-ring { width: 100%; height: 100%; }
.break-breath {
  position: absolute;
  width: 62%;
  height: 62%;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  animation: breathe 4s ease-in-out infinite;
}
@keyframes breathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}
.break-count {
  position: absolute;
  font-size: clamp(34px, 6vw, 48px);
  font-weight: 300;
  font-variant-numeric: tabular-nums;
}

.break-title { font-size: clamp(19px, 2.6vw, 26px); font-weight: 600; letter-spacing: -0.01em; }
.break-sub { margin-top: 9px; font-size: 14px; color: rgba(255, 255, 255, 0.68); }

.break-actions { margin-top: 26px; display: flex; gap: 12px; }
.pill {
  padding: 8px 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  font-size: 13px;
  font-weight: 500;
  backdrop-filter: blur(4px);
}
.break-esc {
  margin-top: 18px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
}

.demo-caption {
  margin-top: 16px;
  text-align: center;
  font-size: 13px;
  color: var(--gray);
}

/* ============================================================
   SECTIONS (shared)
   ============================================================ */
.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 96px 24px 40px;
}
.section-head {
  max-width: 620px;
  margin: 0 auto 56px;
  text-align: center;
}
.section-head h2 {
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
}
.section-head p { margin-top: 14px; font-size: 17px; color: var(--ink-2); }

/* ============================================================
   FEATURES
   ============================================================ */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 26px 24px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s;
}
.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04), 0 18px 44px rgba(0, 0, 0, 0.1);
}
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: var(--icon);
  color: #fff;
  margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-card h3 { font-size: 17px; font-weight: 700; letter-spacing: -0.015em; }
.feature-card p { margin-top: 7px; font-size: 14.5px; color: var(--ink-2); }

/* stagger — JS sets --d per card */
.feature-card.reveal { transition-delay: var(--d, 0s); }

/* ============================================================
   PREVIEW — preferences mockup + vignettes
   ============================================================ */
.prefs-demo {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}

.prefs-window {
  background: var(--card);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow-soft), 0 24px 60px rgba(0, 0, 0, 0.1);
  font-size: 13px;
}
.prefs-body { display: flex; min-height: 430px; }

.prefs-sidebar {
  width: 190px;
  flex-shrink: 0;
  background: #f2f2f7;
  border-right: 1px solid var(--hairline);
  padding: 12px 10px;
}
.light-inline { padding: 2px 3px 14px; }

.side-head {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gray);
  padding: 10px 8px 5px;
}
.side-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 7px;
  font-weight: 500;
  color: var(--ink);
}
.side-item.active { background: rgba(120, 120, 128, 0.16); }
.side-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 5.5px;
  background: var(--c);
  color: #fff;
  flex-shrink: 0;
}
.side-icon svg { width: 13px; height: 13px; }

.prefs-content { flex: 1; padding: 22px 24px; min-width: 0; }
.prefs-header { display: flex; align-items: center; justify-content: space-between; }
.prefs-header h4 { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.next-pill {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(0, 122, 255, 0.1);
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.prefs-desc { margin-top: 5px; color: var(--gray); font-size: 12.5px; }

.prefs-card {
  margin-top: 16px;
  border: 1px solid var(--hairline);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}
.prefs-hero {
  height: 110px;
  background: linear-gradient(120deg, #0ab8a6, #007aff);
  display: flex;
  align-items: center;
  justify-content: center;
}
.prefs-hero-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
}
.prefs-hero-icon svg { width: 30px; height: 30px; }

.prefs-rows { padding: 0 14px; }
.prow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 2px;
  border-bottom: 1px solid rgba(60, 60, 67, 0.1);
  font-weight: 500;
}
.prow:last-child { border-bottom: none; }
.pvalue { color: var(--gray); font-weight: 400; }

.switch {
  width: 40px;
  height: 24px;
  border-radius: 999px;
  background: #34c759;
  position: relative;
  flex-shrink: 0;
}
.switch::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}

.prefs-foot { display: flex; justify-content: flex-end; padding: 10px 14px 12px; }
.play-pill {
  font-size: 12px;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: 999px;
  background: rgba(120, 120, 128, 0.12);
  color: var(--ink);
}

/* ---------- vignettes ---------- */
.vignettes {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.vignette {
  flex: 1;
  border-radius: var(--radius);
  padding: 26px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.blink-vignette {
  background: linear-gradient(140deg, #0e7490, #6d28d9);
  color: #fff;
  box-shadow: var(--shadow-soft);
}
.blink-eye {
  transform-box: fill-box;
  transform-origin: center;
  animation: blink-squeeze 3.4s ease-in-out infinite;
}
@keyframes blink-squeeze {
  0%, 86%, 100% { transform: scaleY(1) var(--tx, translate(0, 0)); opacity: 1; }
  91%, 95% { transform: scaleY(0.15); opacity: 0.85; }
}
.vignette-title { margin-top: 14px; font-size: 17px; font-weight: 700; letter-spacing: -0.015em; }
.vignette-sub { margin-top: 4px; font-size: 13px; opacity: 0.75; }

.tray-vignette {
  background: var(--card);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow-soft);
}
.tray-bar {
  width: 100%;
  max-width: 250px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 6px 12px;
  border-radius: 8px 8px 0 0;
  background: rgba(246, 246, 248, 0.9);
  border: 1px solid var(--hairline);
  border-bottom: none;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--ink);
}
.tray-icon { display: inline-flex; color: var(--ink); }
.tray-time { font-variant-numeric: tabular-nums; }

.tray-menu {
  width: 100%;
  max-width: 210px;
  margin-right: 12px;
  align-self: flex-end;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--hairline);
  border-radius: 0 0 10px 10px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
  padding: 5px;
  font-size: 12.5px;
  text-align: left;
}
.tray-row { padding: 6px 10px; border-radius: 6px; color: var(--ink); }
.tray-row.strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.tray-row:nth-child(2) { background: var(--accent); color: #fff; }
.tray-sep { height: 1px; background: var(--hairline); margin: 4px 8px; }

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  counter-reset: step;
  position: relative;
}
.step {
  position: relative;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-soft);
  text-align: center;
}
.step.reveal { transition-delay: var(--d, 0s); }
.step-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(0, 122, 255, 0.1);
  color: var(--accent);
  margin-bottom: 16px;
}
.step-dot svg { width: 26px; height: 26px; }
.step h3 { font-size: 17px; font-weight: 700; letter-spacing: -0.015em; }
.step p { margin-top: 7px; font-size: 14.5px; color: var(--ink-2); }

/* ============================================================
   CTA BAND
   ============================================================ */
.cta-band {
  margin: 110px 0 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(30, 58, 138, 0.85), transparent 60%),
    radial-gradient(circle at 80% 80%, rgba(15, 118, 110, 0.85), transparent 60%),
    var(--night);
  color: #fff;
  padding: 96px 24px;
  text-align: center;
}
.cta-band-inner { max-width: 640px; margin: 0 auto; }
.cta-band h2 {
  font-size: clamp(28px, 3.8vw, 42px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.cta-band p { margin-top: 14px; font-size: 17px; color: rgba(255, 255, 255, 0.72); }
.cta-band .cta-row { margin-top: 32px; }
.cta-fine { margin-top: 22px; font-size: 13px; color: rgba(255, 255, 255, 0.55); }
.cta-fine a { text-decoration: underline; text-underline-offset: 3px; }
.cta-fine a:hover { color: #fff; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  border-top: 1px solid var(--hairline);
  background: var(--bg);
}
.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
  color: var(--gray);
}
.footer-inner nav { display: flex; gap: 20px; }
.footer-inner a:hover { color: var(--ink); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 960px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 56px;
    gap: 48px;
    text-align: center;
  }
  .hero-copy .lede { margin-left: auto; margin-right: auto; }
  .cta-row { justify-content: center; }
  .break-window { transform: none; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .prefs-demo { grid-template-columns: 1fr; }
  .vignettes { flex-direction: row; }
  .vignettes .vignette { flex: 1; }
  .steps { grid-template-columns: 1fr; max-width: 460px; margin: 0 auto; }
}

@media (max-width: 640px) {
  .nav-links { display: none; }
  .feature-grid { grid-template-columns: 1fr; }
  .vignettes { flex-direction: column; }
  .prefs-sidebar { width: 150px; }
  .prefs-content { padding: 18px 16px; }
  .break-screen { min-height: 380px; }
  .footer-inner { flex-direction: column; }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .break-ambient, .break-breath, .blink-eye { animation: none; }
  .btn, .feature-card, .break-window { transition: none; }
}
