/* ===========================================================================
   RISEEING HUMANITY · Landing — editorial warm direction
   Built on the Riseeing design tokens (cream surfaces, sage ink, Newsreader
   serif accent, Geist body, Geist Mono numerics).
   =========================================================================== */

:root {
  --accent: var(--brand-lime);          /* tweakable energetic accent */
  --page: var(--cream);
  --ink: var(--text-strong);
  --maxw: 1240px;
  --gutter: clamp(22px, 5vw, 96px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; overflow-x: hidden; }
body {
  background: var(--page);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: color-mix(in oklab, var(--accent) 55%, transparent); color: var(--brand-forest-900); }

/* ── Layout helpers ──────────────────────────────────────────────────────── */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 9vw, 130px); position: relative; scroll-margin-top: 80px; }
.divider { height: 1px; background: var(--border-warm); border: 0; margin: 0; }

/* ── Type primitives ─────────────────────────────────────────────────────── */
.eyebrow {
  margin: 0; font-size: 12px; font-weight: 600; line-height: 1;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--brand-moss);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); flex: none; }
.serif { font-family: var(--font-editorial); font-weight: 400; letter-spacing: -0.025em; }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

.display {
  font-family: var(--font-editorial); font-weight: 400;
  letter-spacing: -0.035em; line-height: 0.96; color: var(--brand-forest);
  margin: 0;
}
.h2 {
  font-family: var(--font-editorial); font-weight: 400;
  font-size: clamp(34px, 4.6vw, 58px); letter-spacing: -0.028em; line-height: 1.02;
  color: var(--brand-forest); margin: 0;
}
.lede {
  font-family: var(--font-editorial); font-style: italic; font-weight: 400;
  font-size: clamp(19px, 2.1vw, 26px); line-height: 1.45; color: var(--text-body); margin: 0;
}
.body { font-size: clamp(15px, 1.15vw, 17px); line-height: 1.72; color: var(--text-body); margin: 0; }
.sec-no { font-family: var(--font-editorial); font-weight: 400; color: var(--brand-moss); line-height: 1; }

/* ── Scroll reveal (animation-based: deterministic end-state, restart-proof) ─ */
.reveal { opacity: 0; }
@keyframes revealUp { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: no-preference) {
  .reveal.in { animation: revealUp 0.85s cubic-bezier(0.4,0,0.2,1) both; }
  .reveal.in.d1 { animation-delay: 0.08s; }
  .reveal.in.d2 { animation-delay: 0.16s; }
  .reveal.in.d3 { animation-delay: 0.24s; }
  .reveal.in.d4 { animation-delay: 0.32s; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; }
}
.reveal.in { opacity: 1; }

/* ── Decorative motion ───────────────────────────────────────────────────── */
@keyframes spin-slow { to { transform: rotate(360deg); } }
@keyframes float-y { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
.fol-spin { animation: spin-slow 120s linear infinite; transform-origin: 50% 50%; }
.floaty { animation: float-y 9s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .fol-spin, .floaty { animation: none !important; }
}
.no-deco-motion .fol-spin, .no-deco-motion .floaty { animation: none !important; }

/* ── Lime glow ───────────────────────────────────────────────────────────── */
.glow {
  position: absolute; border-radius: 50%; pointer-events: none; z-index: 0;
  background: radial-gradient(circle, color-mix(in oklab, var(--accent) 42%, transparent), transparent 68%);
  filter: blur(2px);
}

/* ── Header ──────────────────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in oklab, var(--cream) 86%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color 0.24s, background 0.24s;
}
.site-header.scrolled { border-bottom-color: var(--border-warm); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 76px; }
.brand-lock { display: inline-flex; align-items: center; gap: 12px; color: var(--brand-forest); }
.brand-lock .name { font-family: var(--font-header); font-weight: 600; font-size: 19px; letter-spacing: -0.01em; }
.brand-lock .sub { font-size: 10.5px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--brand-moss); margin-top: 2px; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  font-size: 14px; font-weight: 500; color: var(--brand-forest); padding: 9px 16px;
  border-radius: 999px; transition: background 0.12s, color 0.12s;
}
.nav a:hover { background: rgba(67,97,79,0.07); }
.nav a.active { background: rgba(67,97,79,0.12); font-weight: 600; }
.header-cta { display: inline-flex; align-items: center; }
@media (max-width: 940px) { .nav { display: none; } }

/* ── Buttons (editorial pills, complementing DS Button) ──────────────────── */
.pill {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer;
  font-family: var(--font-body); font-size: 15px; font-weight: 600; line-height: 1;
  padding: 15px 26px; border-radius: 999px; border: 1px solid transparent;
  transition: background 0.14s, color 0.14s, border-color 0.14s, transform 0.14s;
  white-space: nowrap;
}
.pill svg { flex: none; }
.pill-primary { background: var(--brand-forest); color: var(--brand-lime-fg); }
.pill-primary:hover { background: var(--brand-forest-800); }
.pill-lime { background: var(--accent); color: var(--brand-forest-900); }
.pill-lime:hover { filter: brightness(0.96); }
.pill-ghost { background: transparent; color: var(--brand-forest); border-color: rgba(67,97,79,0.28); }
.pill-ghost:hover { background: rgba(67,97,79,0.06); }
.pill-cream { background: var(--cream); color: var(--brand-forest); }
.pill-cream:hover { background: #fff; }

/* ── Pulse Breath Animation ──────────────────────────────────────────────── */
@keyframes pulse-breath {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 14px rgba(67, 97, 79, 0.12);
  }
  50% {
    transform: scale(1.025);
    box-shadow: 0 6px 20px rgba(67, 97, 79, 0.22), 0 0 0 6px color-mix(in oklab, var(--brand-forest) 15%, transparent);
  }
}

.pulse-breath {
  animation: pulse-breath 4.5s infinite ease-in-out;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.pulse-breath:hover {
  animation-play-state: paused;
  transform: scale(1.05) translateY(-1px);
}

/* ── Meta row ────────────────────────────────────────────────────────────── */
.meta-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.meta-row .item { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-body); }
.meta-row .item svg { color: var(--brand-moss); }
.meta-row .sep { width: 4px; height: 4px; border-radius: 50%; background: var(--border-warm); }

/* ── Image slots ─────────────────────────────────────────────────────────── */
image-slot { display: block; }
.heroA-figure image-slot {
  width: 100%; aspect-ratio: 4 / 5; height: auto;
  box-shadow: var(--shadow-lift, 0 24px 60px -28px rgba(43,70,50,0.35));
}
.como-grid image-slot {
  width: 100%; aspect-ratio: 16 / 11; height: auto;
  box-shadow: var(--shadow-lift, 0 24px 60px -28px rgba(43,70,50,0.35));
}

/* ── Cards ───────────────────────────────────────────────────────────────── */
.card-warm {
  background: var(--cream-card); border: 1px solid var(--border-warm);
  border-radius: 22px; padding: clamp(26px, 3vw, 40px);
}

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero { position: relative; overflow: clip; }
.hero-eyebrow-rule { display: inline-flex; align-items: center; gap: 14px; }
.hero-eyebrow-rule .rule { width: clamp(28px, 6vw, 64px); height: 1px; background: var(--brand-sage-300); }

/* Hero A — editorial split */
.heroA { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(36px, 5vw, 80px); align-items: center; position: relative; z-index: 2; }
.heroA-figure { position: relative; }
.heroA-figure image-slot { width: 100%; aspect-ratio: 4 / 5; }
.heroA-badge {
  position: absolute; left: -22px; bottom: 34px; z-index: 3;
  background: var(--cream); border: 1px solid var(--border-warm); border-radius: 16px;
  padding: 14px 18px; box-shadow: var(--shadow-lift, 0 18px 40px -20px rgba(43,70,50,0.4)); max-width: 230px;
}
@media (max-width: 880px) {
  .heroA { grid-template-columns: 1fr; }
  .heroA-figure { order: -1; max-width: 460px; }
  .heroA-badge { left: 12px; }
}

/* Hero B — immersive full-bleed */
.heroB { position: relative; min-height: clamp(560px, 86vh, 880px); display: grid; place-items: center; text-align: center; overflow: clip; }
.heroB-media { position: absolute; inset: 0; z-index: 0; }
.heroB-media image-slot { width: 100%; height: 100%; box-shadow: none; }
.heroB-scrim { position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(20,33,24,0.30) 0%, rgba(20,33,24,0.52) 55%, rgba(20,33,24,0.78) 100%); }
.heroB-inner { position: relative; z-index: 3; color: var(--cream); padding-block: 96px; }
.heroB .eyebrow { color: color-mix(in oklab, var(--brand-lime) 88%, white); }
.heroB-fol { position: absolute; z-index: 2; inset: 0; display: grid; place-items: center; pointer-events: none; opacity: 0.5; }

/* ── Manifesto ───────────────────────────────────────────────────────────── */
.manifesto {
  background: var(--brand-forest-900); color: var(--cream); position: relative; overflow: clip;
  text-align: center;
}
.manifesto .fol-wrap { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0.16; pointer-events: none; }
.manifesto em { font-style: normal; color: var(--accent); }
.manifesto .line { font-family: var(--font-editorial); letter-spacing: -0.03em; line-height: 1.18; margin: 0; }

/* ── List marks ──────────────────────────────────────────────────────────── */
.lead-num {
  font-family: var(--font-editorial); font-size: 13px; color: var(--brand-moss);
  border: 1px solid var(--border-warm); border-radius: 999px; width: 34px; height: 34px;
  display: inline-grid; place-items: center; flex: none;
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.site-footer { background: var(--brand-forest-900); color: var(--cream); }
.site-footer a:hover { color: var(--brand-lime); }
.social-btn {
  border: 1px solid rgba(250,247,238,0.45); background: transparent; color: var(--cream);
  width: 42px; height: 42px; border-radius: 999px; display: inline-flex; align-items: center;
  justify-content: center; cursor: pointer; transition: background 0.14s, color 0.14s, border-color 0.14s;
}
.social-btn:hover { background: var(--brand-lime); color: var(--brand-forest-900); border-color: var(--brand-lime); }

/* ── Reduced chrome for the hero variant toggle pill (in-page) ───────────── */
.var-toggle {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 18px; z-index: 60;
  display: none;
}

/* ── Mobile Responsive Optimizations ─────────────────────────────────────── */
@media (max-width: 880px) {
  .que-es-grid,
  .prop-grid,
  .como-grid,
  .fac-grid,
  .foot-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 480px) {
  .header-inner {
    padding-inline: 12px !important;
    gap: 8px;
  }
  .brand-lock {
    gap: 6px;
  }
  .brand-lock .sub {
    font-size: 9px !important;
    letter-spacing: 0.12em !important;
  }
  .pill {
    padding: 12px 18px !important;
    font-size: 13px !important;
    white-space: normal !important;
    text-align: center;
  }
  .card-warm {
    padding: 22px 16px !important;
    border-radius: 18px !important;
  }
  .manifesto .fol-wrap {
    opacity: 0.25 !important;
  }
  .vision-fol {
    opacity: 0.78 !important;
  }
  .heroB-fol {
    opacity: 0.75 !important;
  }
}
