/* ═══════════════════════════════════════
   NearOS — Aurora-inspired Design System v2
   Forest green + terracotta · Onest typeface
   ═══════════════════════════════════════ */

/* Onest — Latin */
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/onest-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/onest-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/onest-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/onest-cyrillic-ext.woff2') format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}

/* ═══════════════════════════════════════
   Design tokens
   ═══════════════════════════════════════ */
:root {
  /* Typography */
  --font: 'Onest', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;

  /* Colors — S49 Council */
  --bg:           #FAFAF8;
  --bg-alt:       #F0EFEB;
  --bg-warm:      #F5F2EC;
  --text:         #1A1A1A;
  --text-muted:   #6B6B6B;
  --accent:       #2D5A3D;
  --accent-light: #E8F0EB;
  --accent-hover: #1F4029;
  --signal:       #C4704B;
  --signal-hover: #A85A38;
  --signal-light: #F5E5D8;
  --border:       #E5E3DE;
  --border-soft:  #EFEDE8;

  /* Spacing */
  --max-w: 1120px;
  --max-reading: 65ch;

  /* Misc */
  --radius: 12px;
  --radius-sm: 6px;
  --radius-lg: 20px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-sm: 0 1px 2px rgba(26,26,26,0.04);
  --shadow-md: 0 4px 16px rgba(26,26,26,0.06);
  --shadow-lg: 0 12px 32px rgba(26,26,26,0.08);
}

/* ═══════════════════════════════════════
   Reset
   ═══════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; }

/* ═══════════════════════════════════════
   Layout
   ═══════════════════════════════════════ */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 720px; }

section { padding: 96px 0; }

.section-label {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  padding: 6px 14px;
  background: var(--accent-light);
  border-radius: 100px;
  margin-bottom: 20px;
}

h1, h2, h3 { font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: clamp(2.5rem, 5.5vw, 3.75rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.25rem; font-weight: 500; line-height: 1.3; }

p { color: var(--text-muted); }

/* ═══════════════════════════════════════
   Header
   ═══════════════════════════════════════ */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 16px 0;
  background: rgba(250, 250, 248, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border-soft);
}
.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.logo {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--text);
}
.logo span { color: var(--accent); }
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.lang-toggle {
  font-family: var(--font);
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 8px 14px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}
.lang-toggle:hover { border-color: var(--accent); color: var(--text); }

/* ═══════════════════════════════════════
   Buttons
   ═══════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  font-family: var(--font);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.2s var(--ease), transform 0.15s var(--ease), border-color 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn--primary { background: var(--signal); color: #fff; }
.btn--primary:hover { background: var(--signal-hover); }
.btn--secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn--secondary:hover { border-color: var(--accent); color: var(--accent); }
.btn--ghost { background: transparent; color: var(--accent); padding: 14px 4px; }
.btn--ghost:hover { text-decoration: underline; }
.btn svg { flex-shrink: 0; }

/* ═══════════════════════════════════════
   Hero
   ═══════════════════════════════════════ */
.hero {
  padding: 160px 0 96px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 50% 10%, rgba(45, 90, 61, 0.08), transparent 60%),
    radial-gradient(ellipse 50% 30% at 90% 80%, rgba(196, 112, 75, 0.06), transparent 60%);
  pointer-events: none;
}
.hero .container { position: relative; }
.hero-content {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}
.hero h1 {
  margin-bottom: 24px;
}
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-sub {
  font-size: 1.1875rem;
  line-height: 1.6;
  max-width: 580px;
  margin: 0 auto 40px;
  color: var(--text-muted);
}

/* Email waitlist form */
.waitlist-form {
  display: flex;
  gap: 8px;
  max-width: 440px;
  margin: 0 auto;
  background: #fff;
  padding: 6px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-soft);
}
.waitlist-form input {
  flex: 1;
  border: none;
  outline: none;
  padding: 12px 16px;
  font-family: var(--font);
  font-size: 0.9375rem;
  background: transparent;
  color: var(--text);
  min-width: 0;
}
.waitlist-form input::placeholder { color: var(--text-muted); opacity: 0.7; }
.waitlist-form button {
  padding: 12px 22px;
  background: var(--signal);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: var(--font);
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}
.waitlist-form button:hover { background: var(--signal-hover); }

.hero-secondary {
  margin-top: 20px;
  font-size: 0.875rem;
}
.hero-secondary a { color: var(--accent); text-decoration: none; font-weight: 500; }
.hero-secondary a:hover { text-decoration: underline; }

/* ═══════════════════════════════════════
   Problem section
   ═══════════════════════════════════════ */
.problem {
  background: var(--bg-alt);
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}
.problem .container { max-width: 720px; }

.problem h2 {
  margin-bottom: 32px;
}

.pain-list {
  list-style: none;
  margin: 0 0 32px;
  padding: 0;
}
.pain-list li {
  padding: 16px 0;
  border-bottom: 1px solid var(--border-soft);
  font-size: 1.0625rem;
  color: var(--text);
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.pain-list li:last-child { border-bottom: none; }
.pain-list li::before {
  content: '—';
  color: var(--signal);
  font-weight: 600;
  flex-shrink: 0;
}

.problem-close {
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--text);
  margin-top: 24px;
}
.problem-close em {
  font-style: normal;
  color: var(--accent);
}

/* ═══════════════════════════════════════
   Approach (3 principles)
   ═══════════════════════════════════════ */
.approach {
  background: var(--bg);
}
.approach-header {
  text-align: center;
  margin-bottom: 56px;
}
.approach-header h2 {
  margin-bottom: 12px;
}

.principles {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, 1fr);
}

.principle {
  background: #fff;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
}
.principle:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--border);
}
.principle-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--accent-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.principle h3 {
  margin-bottom: 10px;
  color: var(--text);
}
.principle p {
  font-size: 0.9375rem;
  line-height: 1.6;
}

/* ═══════════════════════════════════════
   Founder section
   ═══════════════════════════════════════ */
.founder {
  background: var(--bg-warm);
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}
.founder .container {
  max-width: 800px;
  text-align: center;
}
.founder-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #4a7d5e);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 600;
  margin: 0 auto 24px;
  box-shadow: var(--shadow-md);
}
.founder-quote {
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--text);
  font-weight: 400;
  max-width: 640px;
  margin: 24px auto 20px;
  font-style: italic;
}
.founder-name {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════
   Final CTA
   ═══════════════════════════════════════ */
.final-cta {
  background: var(--accent);
  color: #fff;
  text-align: center;
  padding: 96px 0;
}
.final-cta h2 {
  color: #fff;
  margin-bottom: 16px;
}
.final-cta-sub {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.0625rem;
  max-width: 520px;
  margin: 0 auto 36px;
}

.final-cta .waitlist-form {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}
.final-cta .waitlist-form input {
  color: #fff;
}
.final-cta .waitlist-form input::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.final-cta-secondary {
  margin-top: 24px;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
}
.final-cta-secondary a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ═══════════════════════════════════════
   Footer
   ═══════════════════════════════════════ */
.footer {
  padding: 40px 0;
  background: var(--bg);
  border-top: 1px solid var(--border-soft);
  font-size: 0.875rem;
  color: var(--text-muted);
}
.footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--accent); }

/* ═══════════════════════════════════════
   Animations (reduced-motion default)
   ═══════════════════════════════════════ */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  }
  .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
  }
  .reveal-d1 { transition-delay: 0.1s; }
  .reveal-d2 { transition-delay: 0.2s; }
  .reveal-d3 { transition-delay: 0.3s; }
}

/* ═══════════════════════════════════════
   Accessibility
   ═══════════════════════════════════════ */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  background: var(--accent);
  color: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  z-index: 100;
  font-size: 0.875rem;
}
.skip-link:focus { top: 16px; }

/* ═══════════════════════════════════════
   Responsive
   ═══════════════════════════════════════ */
@media (max-width: 899px) {
  section { padding: 72px 0; }
  .hero { padding: 132px 0 72px; }
  .principles { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 639px) {
  .header .container { flex-wrap: wrap; }
  .principles { grid-template-columns: 1fr; }
  .waitlist-form { flex-direction: column; padding: 12px; gap: 8px; }
  .waitlist-form button { width: 100%; }
  .footer .container { flex-direction: column; text-align: center; }
}
