/* ═══════════════════════════════════════════════════════
   IKIGAI · Design Tokens · The White Cosmos
   ═══════════════════════════════════════════════════════ */

:root {
  /* ── Canvas / Surfaces ───────────────────────────── */
  --ik-canvas:      #F5F6FA;
  --ik-surface:     #FFFFFF;
  --ik-porcelain:   #EDF0F6;
  --ik-mist:        #F0F2F8;
  --ik-pearl:       #F8F9FC;

  /* ── Ink ─────────────────────────────────────────── */
  --ik-ink-deep:    #070810;
  --ik-ink-mid:     #2A2D3E;
  --ik-ink-soft:    #4A5070;
  --ik-ink-light:   #8891AA;
  --ik-ink-faint:   #B0B7CC;

  /* ── Cosmic accents (use sparingly: < 5% of surface) ── */
  --ik-cosmic:      #6EA8FF;  /* azul galáctico */
  --ik-aura:        #7EF6E2;  /* cian de consciencia */
  --ik-violet:      #9B8CFF;  /* violeta espiritual */
  --ik-gold:        #F5DFA7;  /* luz dorada */
  --ik-stardust:    #C8D4F0;  /* plata sideral */

  /* ── Glass ───────────────────────────────────────── */
  --ik-glass:       rgba(255,255,255,0.72);
  --ik-glass-deep:  rgba(255,255,255,0.88);
  --ik-glass-border: rgba(160,180,255,0.18);
  --ik-glass-shadow: 0 8px 48px rgba(80,100,200,0.06);
  --ik-glass-shadow-lg: 0 24px 72px rgba(80,100,200,0.10);

  /* ── Type ────────────────────────────────────────── */
  --ff-display: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", system-ui, sans-serif;
  --ff-text:    "SF Pro Text",    -apple-system, BlinkMacSystemFont, "Helvetica Neue", system-ui, sans-serif;
  --ff-mono:    "SF Mono", "JetBrains Mono", ui-monospace, Menlo, monospace;

  /* ── Spacing scale ───────────────────────────────── */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;
  --s-9: 96px; --s-10: 128px; --s-11: 192px;

  /* ── Radius ──────────────────────────────────────── */
  --r-sm: 8px; --r-md: 14px; --r-lg: 20px; --r-xl: 28px; --r-2xl: 40px;

  /* ── Section width ───────────────────────────────── */
  --maxw: 1280px;
}

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

html, body {
  background: var(--ik-canvas);
  color: var(--ik-ink-deep);
  font-family: var(--ff-text);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body {
  /* radial atmospheric tint */
  background:
    radial-gradient(ellipse 90% 60% at 50% 0%, rgba(110,168,255,0.05), transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 80%, rgba(126,246,226,0.04), transparent 60%),
    radial-gradient(ellipse 60% 40% at 20% 60%, rgba(155,140,255,0.035), transparent 60%),
    var(--ik-canvas);
  min-height: 100svh;
}

a { color: inherit; text-decoration: none; }
button { background: none; border: 0; cursor: pointer; font: inherit; color: inherit; }

/* ── Display helpers ─────────────────────────────────── */
.display {
  font-family: var(--ff-display);
  font-weight: 200;
  letter-spacing: -0.04em;
  line-height: 1.02;
  color: var(--ik-ink-deep);
}
.label {
  font-family: var(--ff-text);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ik-ink-light);
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ik-ink-light);
}
.eyebrow::before {
  content: "";
  width: 24px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--ik-stardust));
}
.eyebrow.center::after {
  content: "";
  width: 24px; height: 1px;
  background: linear-gradient(90deg, var(--ik-stardust), transparent);
}

/* ── IKIGAI wordmark ─────────────────────────────────── */
.wordmark {
  font-family: var(--ff-display);
  font-style: italic;
  font-weight: 200;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: var(--ik-ink-deep);
}
html[data-wordmark="regular"] .wordmark {
  font-style: normal;
  font-weight: 300;
  letter-spacing: 0.04em;
}

/* ── Layered canvases ────────────────────────────────── */
#constellation {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100svh;
  pointer-events: none;
  z-index: 1;
}

#root {
  position: relative;
  z-index: 2;
}

/* ── Sections ────────────────────────────────────────── */
section {
  position: relative;
  padding: clamp(80px, 12vh, 160px) clamp(24px, 5vw, 64px);
}
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  position: relative;
}

/* ── Glass card ──────────────────────────────────────── */
.glass {
  background: var(--ik-glass);
  border: 1px solid var(--ik-glass-border);
  box-shadow: var(--ik-glass-shadow);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-radius: var(--r-lg);
}

/* ── Selection ───────────────────────────────────────── */
::selection {
  background: rgba(126,246,226,0.35);
  color: var(--ik-ink-deep);
}

/* ── Scrollbar ───────────────────────────────────────── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(160,180,255,0.18);
  border-radius: 8px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(160,180,255,0.32); }

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

/* ── Keyframes ───────────────────────────────────────── */
@keyframes breathe {
  0%, 100% { transform: scale(1); opacity: 0.9; }
  50%      { transform: scale(1.04); opacity: 1; }
}
@keyframes spin-slow { to { transform: rotate(360deg); } }
@keyframes spin-rev { to { transform: rotate(-360deg); } }
@keyframes float-y {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(-8px); }
}
@keyframes pulse-ring {
  0%   { transform: scale(0.8); opacity: 0.7; }
  100% { transform: scale(2.6); opacity: 0; }
}
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes caret-blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}
@keyframes fade-up {
  from { opacity: 0; transform: translateY(20px); filter: blur(8px); }
  to   { opacity: 1; transform: translateY(0); filter: blur(0); }
}
@keyframes type-glow {
  0%, 100% { box-shadow: 0 0 0 1px rgba(110,168,255,0.18), 0 8px 32px rgba(110,168,255,0.06); }
  50%      { box-shadow: 0 0 0 1px rgba(126,246,226,0.32), 0 8px 32px rgba(126,246,226,0.12); }
}
