/* ====================================================================
   Gonzalo Rocca — Portfolio
   Design System: Apple (cinematic black/light alternating, SF Pro)
   Reference: ./DESIGN.md (section 2 — Color · section 3 — Typography)
   ==================================================================== */

/* ===== TOKENS ===== */
:root {
  /* Apple core palette */
  --black:        #000000;
  --near-black:   #1d1d1f;
  --light:        #f5f5f7;
  --white:        #ffffff;

  /* Dark surfaces (section 2 — Apple dark variants) */
  --dark-surface-1: #272729;
  --dark-surface-2: #28282a;
  --dark-surface-3: #2a2a2d;
  --dark-surface-5: #242426;

  /* Interactive — Apple Blue */
  --blue:         #0071e3;
  --blue-link:    #0066cc;
  --blue-bright:  #2997ff;

  /* Text */
  --text-dim-dark: rgba(255, 255, 255, 0.72);
  --text-dim-lt:   rgba(0, 0, 0, 0.72);
  --text-mut-lt:   rgba(0, 0, 0, 0.56);

  /* Shadow (section 2 — card shadow) */
  --shadow-card:   rgba(0, 0, 0, 0.22) 3px 5px 30px 0;

  /* Type — SF Pro proxy via -apple-system, Inter fallback */
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display",
                  "Inter", "Helvetica Neue", Arial, sans-serif;
  --font-text:    -apple-system, BlinkMacSystemFont, "SF Pro Text",
                  "Inter", "Helvetica Neue", Arial, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* Layout */
  --nav-h: 48px;
  --max: 980px;
  --max-wide: 1200px;
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: auto; } /* lenis handles scroll */
body {
  margin: 0;
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.022em; /* apple tracks tight at every size */
  background: var(--black);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color 700ms cubic-bezier(.4, 0, .2, 1);
}
body.lenis-anchor { scroll-behavior: auto; }
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }
::selection { background: var(--blue); color: var(--white); }

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

.skip-link {
  position: fixed; left: -9999px; top: 0;
  background: var(--blue); color: var(--white);
  padding: 10px 14px; border-radius: 8px;
  z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

/* ===== SCENE (section background alternation — core Apple pattern) ===== */
.scene {
  position: relative;
  width: 100%;
  padding: 120px 0;
}
.scene-dark {
  background: var(--black);
  color: var(--white);
}
.scene-light {
  background: var(--light);
  color: var(--near-black);
}

.wrap {
  width: 100%;
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0 40px;
  position: relative;
}
@media (max-width: 640px) {
  .wrap { padding: 0 22px; }
  .scene { padding: 80px 0; }
}

/* ===== TYPE ===== */
.display {
  font-family: var(--font-display);
  font-size: clamp(56px, 11vw, 132px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin: 0 0 36px;
  color: var(--white);
}
.display-sm {
  font-size: clamp(48px, 8vw, 96px);
  margin: 0 0 28px;
}

.h-section {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.025em;
  color: var(--near-black);
  margin: 0 0 20px;
}
.h-section-dark { color: var(--white); }
.h-section-sub {
  font-family: var(--font-display);
  font-size: clamp(19px, 1.8vw, 24px);
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: -0.015em;
  color: var(--text-dim-dark);
  max-width: 640px;
  margin: 0;
}
.scene-light .h-section-sub { color: var(--text-dim-lt); }
.h-section-sub.centered { margin-left: auto; margin-right: auto; }

.eyebrow {
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--blue-link);
  text-transform: none;
  margin: 0 0 14px;
}
.eyebrow-blue { color: var(--blue-bright); }

.mono, .micro {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  font-weight: 500;
  text-transform: uppercase;
}
.mono { color: inherit; opacity: 0.6; }

.section-head {
  margin-bottom: 80px;
  max-width: 820px;
}
.section-head.centered {
  margin-left: auto; margin-right: auto;
  text-align: center;
}

.prose p {
  font-size: 17px;
  line-height: 1.55;
  letter-spacing: -0.015em;
  color: var(--text-dim-lt);
  margin: 0 0 18px;
  max-width: 620px;
}
.prose p:last-child { margin-bottom: 0; }
.prose strong { color: var(--near-black); font-weight: 600; }

.wrap-2col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  margin-bottom: 80px;
}
@media (min-width: 900px) {
  .wrap-2col { grid-template-columns: 1fr 1.2fr; gap: 80px; }
}

/* ===== NAV (glass Apple) ===== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  z-index: 50;
  transition: background 500ms cubic-bezier(.4, 0, .2, 1), color 500ms ease;
  color: var(--white);
}
body[data-theme="light"] .nav {
  background: rgba(245, 245, 247, 0.82);
  color: var(--near-black);
}
.nav-inner {
  height: 100%;
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--light);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  padding: 5px;
}
.brand-logo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
body[data-theme="dark"] .brand-mark { background: var(--light); }
body[data-theme="light"] .brand-mark {
  background: var(--white);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.nav-links {
  display: flex;
  gap: 4px;
  align-items: center;
}
.nav-links a {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: -0.01em;
  padding: 8px 12px;
  border-radius: 6px;
  opacity: 0.88;
  transition: opacity 200ms ease, background 200ms ease;
}
.nav-links a:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.08);
}
body[data-theme="light"] .nav-links a:hover { background: rgba(0, 0, 0, 0.06); }

.nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-icon {
  width: 32px; height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  opacity: 0.85;
  transition: opacity 200ms ease, background 200ms ease;
}
.nav-icon:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.12);
}
body[data-theme="light"] .nav-icon:hover { background: rgba(0, 0, 0, 0.08); }

.nav-toggle {
  display: none;
  width: 32px; height: 32px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-radius: 50%;
}
.nav-toggle span {
  width: 16px; height: 1px;
  background: currentColor;
  transition: transform 250ms ease, opacity 250ms ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(2.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-2.5px) rotate(-45deg); }

@media (max-width: 820px) {
  .nav-links {
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    background: inherit;
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    flex-direction: column;
    padding: 14px 24px;
    gap: 0;
    transform: translateY(-120%);
    transition: transform 350ms cubic-bezier(.4, 0, .2, 1);
    border-top: 1px solid rgba(255,255,255,0.08);
  }
  body[data-theme="light"] .nav-links { border-top-color: rgba(0,0,0,0.08); }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: 14px 0; font-size: 17px; }
  .nav-toggle { display: inline-flex; }
  .nav-brand-text { display: none; }
}

/* ===== PILL BUTTONS (Apple signature 980px radius) ===== */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 22px;
  border-radius: 980px;
  font-family: var(--font-text);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.015em;
  border: 1px solid transparent;
  transition: background 220ms ease, color 220ms ease, border-color 220ms ease, transform 220ms ease, opacity 220ms ease;
  white-space: nowrap;
  cursor: pointer;
}
.pill:active { transform: scale(0.97); }
.pill-sm { height: 30px; padding: 0 14px; font-size: 13px; }
.pill-lg { height: 52px; padding: 0 30px; font-size: 17px; }

.pill-filled {
  background: var(--blue);
  color: var(--white);
}
.pill-filled:hover { background: #147ce5; }

.pill-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.5);
}
.pill-outline:hover { border-color: var(--white); background: rgba(255,255,255,0.06); }

.pill-outline-dark {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.4);
}
.pill-outline-dark:hover { border-color: var(--white); background: rgba(255,255,255,0.06); }

.scene-light .pill-outline {
  color: var(--near-black);
  border-color: rgba(0, 0, 0, 0.35);
}
.scene-light .pill-outline:hover {
  border-color: var(--near-black);
  background: rgba(0, 0, 0, 0.04);
}

.link-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 17px;
  font-weight: 400;
  color: var(--blue-bright);
  padding: 6px 14px;
  border: 1px solid var(--blue-bright);
  border-radius: 980px;
  transition: background 200ms ease, color 200ms ease;
}
.link-pill:hover { background: var(--blue-bright); color: var(--black); }

.learn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--blue-bright);
  transition: color 200ms ease;
}
.learn:hover { color: #56b0ff; }
.learn.muted { color: var(--text-dim-dark); cursor: default; }

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 40px) 0 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 900px 500px at 50% 110%, rgba(41, 151, 255, 0.12), transparent 70%),
    radial-gradient(ellipse 700px 400px at 80% 20%, rgba(0, 113, 227, 0.06), transparent 70%);
  pointer-events: none;
}
.hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 40px;
  width: 100%;
  position: relative;
  z-index: 1;
}
@media (max-width: 640px) { .hero-inner { padding: 0 22px; } }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 10px;
  margin: 0 0 40px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 980px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-dim-dark);
  letter-spacing: -0.01em;
  background: rgba(255,255,255,0.03);
}
.hero-eyebrow .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #2db670;
  box-shadow: 0 0 10px rgba(45, 182, 112, 0.6);
  animation: pulse-dot 2.4s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.55; }
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 400;
  line-height: 1.22;
  letter-spacing: -0.02em;
  color: var(--text-dim-dark);
  margin: 0 0 48px;
  max-width: 720px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 100px;
}

.hero-scroll {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  font-family: var(--font-mono);
}
.hero-scroll-dot { animation: scroll-dot 2s ease-in-out infinite; }
@keyframes scroll-dot {
  0%   { transform: translateY(0); opacity: 1; }
  60%  { transform: translateY(6px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* SplitText masks */
.display .char-wrap { display: inline-block; overflow: hidden; vertical-align: baseline; }
.display .char { display: inline-block; }

/* ===== ABOUT META ===== */
.about-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2px;
  background: rgba(0,0,0,0.08);
  border-radius: 16px;
  overflow: hidden;
}
.about-meta > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 24px;
  background: var(--light);
}
.about-meta .micro {
  color: var(--text-mut-lt);
  font-size: 11px;
  letter-spacing: 0.1em;
}
.about-meta strong {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--near-black);
}

/* ===== ECOSYSTEM — product hero (CeroClawd) ===== */
.product-hero {
  position: relative;
  margin: 40px auto 40px;
  padding: 100px 40px;
  max-width: var(--max-wide);
  width: calc(100% - 80px);
  background:
    radial-gradient(ellipse 800px 400px at 50% 100%, rgba(41, 151, 255, 0.18), transparent 60%),
    linear-gradient(180deg, #0a0a0c 0%, #141418 100%);
  border-radius: 28px;
  text-align: center;
  overflow: hidden;
  box-shadow: 0 40px 80px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.05);
}
.product-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 60% 80% at 50% 50%, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 60% 80% at 50% 50%, black 30%, transparent 75%);
  pointer-events: none;
}
@media (max-width: 640px) {
  .product-hero { padding: 60px 24px; width: calc(100% - 44px); }
}
.product-hero-inner { position: relative; z-index: 1; }

/* ===== VIDEO CARD (founder intro) ===== */
.video-card {
  position: relative;
  margin: 40px auto 80px;
  max-width: 1200px;
  width: calc(100% - 80px);
  aspect-ratio: 16 / 9;
  border-radius: 28px;
  overflow: hidden;
  background: #0c0616;
  box-shadow:
    0 40px 100px rgba(138, 44, 226, 0.25),
    0 20px 50px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  isolation: isolate;
}
.video-card-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
@media (max-width: 640px) {
  .video-card { width: calc(100% - 44px); border-radius: 22px; }
}

/* Mute toggle button (top-right) */
.video-mute {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--white);
  cursor: pointer;
  transition: background 200ms ease, transform 200ms ease, opacity 200ms ease;
  opacity: 0.9;
}
.video-mute:hover { background: rgba(0, 0, 0, 0.75); opacity: 1; transform: scale(1.06); }
.video-mute:active { transform: scale(0.95); }

/* Label bottom-left */
.video-label {
  position: absolute;
  bottom: 20px;
  left: 24px;
  z-index: 2;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
  opacity: 0.95;
}

/* CTA bottom-right: "click para sonido" */
.video-sound-cta {
  position: absolute;
  bottom: 18px;
  right: 18px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px 10px 14px;
  background: rgba(255, 255, 255, 0.95);
  color: #111;
  border-radius: 980px;
  font-family: var(--font-text);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: transform 220ms cubic-bezier(.2,.8,.2,1), background 200ms ease, opacity 300ms ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  animation: cta-pulse 2.8s ease-in-out infinite;
}
.video-sound-cta:hover { background: var(--white); transform: translateY(-1px) scale(1.03); }
.video-sound-cta:active { transform: translateY(0) scale(0.98); }
.video-sound-cta[hidden] { display: none !important; }

@keyframes cta-pulse {
  0%, 100% { box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3), 0 0 0 0 rgba(255, 255, 255, 0.4); }
  50%      { box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3), 0 0 0 10px rgba(255, 255, 255, 0); }
}

@media (max-width: 640px) {
  .video-mute { width: 36px; height: 36px; top: 12px; right: 12px; }
  .video-label { bottom: 14px; left: 16px; font-size: 10px; }
  .video-sound-cta { bottom: 12px; right: 12px; padding: 8px 14px 8px 12px; font-size: 12px; }
}
.tile-tag {
  display: inline-block;
  padding: 5px 12px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue-bright);
  background: rgba(41, 151, 255, 0.12);
  border: 1px solid rgba(41, 151, 255, 0.3);
  border-radius: 980px;
  margin-bottom: 24px;
}
.tile-headline {
  font-family: var(--font-display);
  font-size: clamp(44px, 7vw, 86px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin: 0 0 14px;
  color: var(--white);
  background: linear-gradient(180deg, #ffffff 0%, #a5a9b3 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.tile-sub {
  font-family: var(--font-display);
  font-size: clamp(18px, 2.2vw, 26px);
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: -0.018em;
  color: var(--text-dim-dark);
  margin: 0 0 32px;
}
.tile-ctas {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.tile-meta {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
}

/* ===== GRID PRODUCTS ===== */
.grid-products {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 720px)  { .grid-products { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .grid-products { grid-template-columns: repeat(3, 1fr); } }

.tile {
  position: relative;
  padding: 32px 30px 36px;
  background: var(--dark-surface-1);
  border-radius: 20px;
  transition: transform 400ms cubic-bezier(.2, .8, .2, 1), background 300ms ease;
  display: flex;
  flex-direction: column;
  min-height: 290px;
  overflow: hidden;
}
.tile:hover { background: var(--dark-surface-3); transform: translateY(-4px); }
.tile-accent {
  background: linear-gradient(150deg, #1a2140 0%, #1c1c24 60%);
}
.tile-accent:hover { background: linear-gradient(150deg, #243060 0%, #1e1e28 60%); }

/* Tile with background video (Cortex card) */
.tile-video {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: #0a0a10;
}
.tile-video:hover { background: #0a0a10; }
.tile-video-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.42;
  filter: saturate(120%) contrast(108%);
  transition: opacity 320ms ease;
  pointer-events: none;
}
.tile-video:hover .tile-video-bg { opacity: 0.55; }
.tile-video-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(10,10,16,0.55) 0%, rgba(10,10,16,0.25) 45%, rgba(10,10,16,0.85) 100%),
    radial-gradient(ellipse 400px 300px at 80% 100%, rgba(41, 151, 255, 0.22), transparent 70%);
}
.tile-video .tile-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.tile-video .tile-desc,
.tile-video .tile-stack { color: rgba(255,255,255,0.85); }
.tile-video .tile-desc { flex: 1; }

.tile-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim-dark);
  margin-bottom: 18px;
}
.pulse {
  width: 7px; height: 7px;
  border-radius: 50%;
  box-shadow: 0 0 10px currentColor;
}
.pulse.live  { background: #2db670; color: #2db670; animation: pulse-dot 2.4s ease-in-out infinite; }
.pulse.build { background: #f5c518; color: #f5c518; }

.tile-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin: 0 0 12px;
  color: var(--white);
}
.tile-desc {
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: -0.015em;
  color: var(--text-dim-dark);
  margin: 0 0 20px;
  flex: 1;
}
.tile-stack {
  font-size: 10px;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.1em;
  margin: 0 0 18px;
}
.tile .learn { margin-top: auto; }

/* ===== TIMELINE ===== */
.timeline {
  display: flex;
  flex-direction: column;
}
.tl-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 40px;
  padding: 40px 0;
  border-top: 1px solid rgba(0,0,0,0.1);
  align-items: start;
}
.tl-row:last-child { border-bottom: 1px solid rgba(0,0,0,0.1); }

.tl-when {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 4px;
}
.tl-year {
  color: var(--text-mut-lt);
  font-size: 12px;
  letter-spacing: 0.06em;
}
.tl-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 980px;
  background: var(--blue);
  color: var(--white);
  font-size: 10px;
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  width: fit-content;
}
.tl-role {
  font-family: var(--font-display);
  font-size: clamp(24px, 2.6vw, 32px);
  font-weight: 600;
  letter-spacing: -0.022em;
  line-height: 1.1;
  margin: 0 0 6px;
  color: var(--near-black);
}
.tl-where {
  font-size: 15px;
  font-weight: 500;
  color: var(--blue-link);
  margin: 0 0 14px;
}
.tl-desc {
  font-size: 17px;
  line-height: 1.55;
  letter-spacing: -0.015em;
  color: var(--text-dim-lt);
  margin: 0 0 18px;
  max-width: 680px;
}
.tl-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tl-tags span {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--text-dim-lt);
  padding: 4px 10px;
  background: rgba(0,0,0,0.04);
  border-radius: 980px;
}

@media (max-width: 720px) {
  .tl-row { grid-template-columns: 1fr; gap: 10px; padding: 30px 0; }
}

/* ===== CERTIFICATE — HERO SECTION ===== */
.scene-cert .section-head { text-align: center; margin-left: auto; margin-right: auto; }
.scene-cert .section-head .h-section-sub { margin-left: auto; margin-right: auto; }

.cert-stage {
  position: relative;
  padding: 60px 40px 80px;
  perspective: 1600px;
  overflow: hidden;
}
.cert-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 800px 500px at 50% 50%, rgba(41,151,255,0.15), transparent 60%);
  pointer-events: none;
}
.cert-wrap {
  position: relative;
  max-width: 780px;
  margin: 0 auto;
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 60px 120px rgba(0,0,0,0.7),
    0 20px 40px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.12);
  transform-style: preserve-3d;
  background: #fafafa;
  will-change: transform;
}
.cert-img {
  width: 100%;
  height: auto;
  display: block;
}
.cert-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  background: rgba(0,0,0,0.03);
  border-top: 1px solid rgba(0,0,0,0.08);
  color: var(--text-mut-lt);
  font-size: 10px;
}
@media (max-width: 640px) {
  .cert-stage { padding: 30px 20px 50px; }
  .cert-caption { flex-direction: column; gap: 4px; text-align: center; }
}

.creds-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 20px;
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}
@media (min-width: 720px) { .creds-grid { grid-template-columns: repeat(3, 1fr); } }

.cred-card {
  background: var(--dark-surface-1);
  border-radius: 14px;
  padding: 22px 24px;
  transition: background 240ms ease, transform 240ms ease;
}
.cred-card:hover { background: var(--dark-surface-3); transform: translateY(-2px); }
.cred-year {
  color: var(--text-dim-dark);
  font-size: 11px;
  margin: 0 0 10px;
}
.cred-card h4 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
  color: var(--white);
}
.cred-org {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  margin: 0;
}

/* ===== STACK ===== */
.stack-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
  background: rgba(0,0,0,0.08);
  border-radius: 16px;
  overflow: hidden;
}
@media (min-width: 600px) { .stack-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .stack-grid { grid-template-columns: repeat(3, 1fr); } }

.stack-col {
  background: var(--light);
  padding: 28px 30px 30px;
}
.stack-label {
  display: block;
  color: var(--blue-link);
  margin: 0 0 16px;
  font-size: 11px;
}
.stack-col ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.stack-col li {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--near-black);
  line-height: 1.25;
}

/* ===== CONTACT ===== */
.scene-contact { padding-bottom: 140px; }
.scene-contact .section-head { text-align: center; }

.contact-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-bottom: 80px;
}

.contact-links {
  max-width: 720px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: rgba(255,255,255,0.08);
  border-radius: 16px;
  overflow: hidden;
}
@media (min-width: 720px) { .contact-links { grid-template-columns: 1fr 1fr; } }

.contact-links a {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 18px;
  align-items: center;
  padding: 22px 26px;
  background: var(--dark-surface-1);
  transition: background 240ms ease;
}
.contact-links a:hover { background: var(--dark-surface-3); }
.contact-links .mono {
  font-size: 10px;
  color: rgba(255,255,255,0.5);
  opacity: 1;
}
.contact-links strong {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--white);
}

@media (max-width: 600px) {
  .contact-links a { grid-template-columns: 1fr; gap: 4px; }
}

/* ===== FOOTER ===== */
.footer {
  background: var(--black);
  color: rgba(255,255,255,0.5);
  padding: 40px 0;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  letter-spacing: -0.01em;
}
.footer p { margin: 0; }
.footer .mono { opacity: 0.6; font-size: 10px; }

/* ===== REVEAL STATES (GSAP hooks) ===== */
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  will-change: opacity, transform;
}

/* Fallback if JS fails: show content after 500ms */
.no-js [data-reveal] { opacity: 1; transform: none; }

/* Reduced motion — respect OS preference */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}
