
/* ============================================================
   Fuentes autoalojadas
   Antes se pedían a fonts.googleapis.com, lo que enviaba la IP del
   visitante a Google en cada carga, antes de cualquier consentimiento.
   Ahora salen de este dominio. Almarai e Instrument Serif son de
   licencia abierta (OFL), y sólo se incluyen los subconjuntos latinos.
   ============================================================ */
@font-face {
  font-family: 'Almarai';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('fonts/almarai-latin-300.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: 'Almarai';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/almarai-latin-400.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: 'Almarai';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/almarai-latin-700.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: 'Almarai';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('fonts/almarai-latin-800.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: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/instrument-serif-latin-ext-400-italic.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: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/instrument-serif-latin-400-italic.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: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/instrument-serif-latin-ext-400.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: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/instrument-serif-latin-400.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: 'Scotch Display Condensed';
  src: url('fonts/ScotchDisplayCond-Md.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'Scotch Display Condensed';
  src: url('fonts/ScotchDisplayCond-Sm.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}
/* ============================================================
   Prisma - cinematic redesign of Luis Quintero's portfolio
   No build step. Pure CSS recreation of a dark / cream / moody
   Tailwind + framer-motion design. Shared across all pages.
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  /* única pila sans del proyecto */
  --font-sans: 'Almarai', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  --black: #000000;
  --about-card: #101010;
  --feature-card: #212121;
  --cream: #E1E0CC;          /* primary text */
  --cream-accent: #DEDBC8;   /* utility accent (text-primary) */
  --gray-400: #9b9a90;
  --gray-500: #75746c;
  --nav-link: rgba(225, 224, 204, 0.8);
  --line: rgba(225, 224, 204, 0.12);
  --check: #8db98a;          /* muted green for checklist marks */
  --radius-lg: 2rem;
  --radius-md: 1rem;
  --ease-cinematic: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-card: cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1400px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* {
  margin: 0;
  font-family: var(--font-sans);
}
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--black);
  color: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip; /* clip (not hidden) so position:sticky keeps working */
  line-height: 1.4;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
.serif { font-family: 'Instrument Serif', Georgia, 'Times New Roman', serif; font-style: italic; }

/* ---------- Noise textures (SVG feTurbulence) ---------- */
.noise-overlay {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.bg-noise {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Layout helpers ---------- */
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
@media (max-width: 640px) { .wrap { padding: 0 18px; } }

/* ============================================================
   NAVBAR - black pill hanging from top center
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  display: flex; align-items: center;
  gap: 12px;
  background: var(--black);
  border-radius: 0 0 1rem 1rem;
  padding: 10px 16px;
}
@media (min-width: 768px) {
  .nav { border-radius: 0 0 1.5rem 1.5rem; padding: 12px 32px; gap: 14px; }
}
.nav .brand {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--cream);
  font-weight: 800; letter-spacing: -0.02em;
  font-size: 15px;
}
.nav .brand .dot { color: var(--cream-accent); }
.nav .brand svg { width: 15px; height: 18px; color: var(--cream); }
.nav-links {
  display: flex; align-items: center;
  gap: 12px;
  font-size: 10px;
}
@media (min-width: 640px) { .nav-links { gap: 24px; font-size: 12px; } }
@media (min-width: 768px) { .nav-links { gap: 40px; font-size: 14px; } }
.nav-links a {
  color: var(--nav-link);
  transition: color 200ms ease;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active { color: var(--cream); }
.nav .sep { width: 1px; height: 16px; background: var(--line); }
.lang {
  display: inline-flex; align-items: center;
  font-size: 10px; letter-spacing: 0.06em;
  color: var(--nav-link);
}
@media (min-width: 640px) { .lang { font-size: 12px; } }
.lang .opt { padding: 0 4px; transition: color 200ms ease; }
.lang .opt.on { color: var(--cream); }
.lang .opt.off { color: rgba(225,224,204,0.35); }

@media (max-width: 560px) {
  .nav-links a.hide-sm { display: none; }
}

/* ---------- Menú lateral (mobile) ---------- */
/* El botón hamburguesa y el drawer solo existen/visibles en mobile.
   Los crea prisma.js clonando los enlaces y el toggle EN/ES del nav. */
.nav-burger { display: none; }
@media (max-width: 640px) {
  /* notch: barra (70% del ancho) con marca a la izquierda y burger a la derecha */
  .nav {
    left: 50%; transform: translateX(-50%);
    width: 70vw;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 18px;
  }
  .nav > .sep, .nav > .nav-links { display: none; }
  /* el conmutador EN/ES se queda siempre visible en el header, centrado en la
     barra: se saca del flujo (absolute + translateX) para que quede en el punto
     medio exacto, sin que lo desplacen los anchos de la marca y del burger,
     que se reparten a los lados con el space-between del .nav */
  .nav > .lang { display: inline-flex; position: absolute; left: 50%; transform: translateX(-50%);
    font-size: 11px; letter-spacing: 0.08em; }
  .nav > .lang .opt { padding: 0 3px; }
  .nav-burger {
    display: inline-flex; align-items: center; justify-content: center;
    width: 30px; height: 30px; margin: -3px -6px -3px 0; padding: 0;
    color: var(--cream); background: transparent; border: 0; cursor: pointer;
    border-radius: 8px; -webkit-tap-highlight-color: transparent;
  }
  .nav-burger svg { width: 20px; height: 20px; }
}

.nav-scrim {
  position: fixed; inset: 0; z-index: 68;
  background: rgba(0, 0, 0, 0.55);
  opacity: 0; visibility: hidden;
  transition: opacity 300ms cubic-bezier(0.16, 1, 0.3, 1), visibility 300ms;
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
}
.nav-scrim.is-open { opacity: 1; visibility: visible; }

.nav-drawer {
  position: fixed; top: 0; right: 0; z-index: 70;
  height: 100vh; height: 100dvh; width: min(82vw, 300px);
  display: flex; flex-direction: column;
  padding: 22px 24px calc(24px + env(safe-area-inset-bottom));
  background: var(--black);
  box-shadow: -24px 0 60px -20px rgba(0, 0, 0, 0.7);
  transform: translateX(100%);
  transition: transform 360ms cubic-bezier(0.16, 1, 0.3, 1);
  overscroll-behavior: contain;
}
.nav-drawer.is-open { transform: none; }

.nav-drawer-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 34px; }
.nav-drawer-brand { display: inline-flex; align-items: center; color: var(--cream); font-weight: 800; letter-spacing: -0.02em; font-size: 16px; }
.nav-drawer-brand .dot { color: var(--cream-accent); }
.nav-drawer-close { width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; color: var(--cream); background: transparent; border: 0; cursor: pointer; border-radius: 8px; margin: -6px -6px -6px 0; -webkit-tap-highlight-color: transparent; }
.nav-drawer-close svg { width: 20px; height: 20px; }

.nav-drawer-links { display: flex; flex-direction: column; }
.nav-drawer-links a {
  color: var(--nav-link); font-size: 22px; font-weight: 700; letter-spacing: -0.01em;
  padding: 15px 0; border-bottom: 1px solid var(--line);
  transition: color 200ms ease;
}
.nav-drawer-links a:hover, .nav-drawer-links a.active { color: var(--cream); }

.nav-drawer-foot { margin-top: auto; padding-top: 24px; }
.nav-drawer-foot .lang { display: inline-flex; align-items: center; font-size: 16px; letter-spacing: 0.08em; color: var(--nav-link); }
.nav-drawer-foot .lang .opt { padding: 0 6px; }
.nav-drawer-foot .lang .opt.on { color: var(--cream); }
.nav-drawer-foot .lang .opt.off { color: rgba(225, 224, 204, 0.35); }

@media (prefers-reduced-motion: reduce) {
  .nav-scrim, .nav-drawer { transition: none; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero { height: 100svh; min-height: 600px; padding: 16px; }
@media (min-width: 768px) { .hero { padding: 24px; } }
.hero-frame {
  position: relative;
  width: 100%; height: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: radial-gradient(120% 120% at 30% 10%, #2a2622 0%, #14110e 45%, #050505 100%);
}
@media (min-width: 768px) { .hero-frame { border-radius: var(--radius-lg); } }
.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero-frame .noise-overlay {
  position: absolute; inset: 0; z-index: 1;
  opacity: 0.7; mix-blend-mode: overlay; pointer-events: none;
}
.hero-frame .grad {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.30) 0%, transparent 40%, rgba(0,0,0,0.60) 100%);
}

.hero-content {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
  padding: 0 28px 28px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
  align-items: end;
}
@media (max-width: 860px) {
  .hero-content { grid-template-columns: 1fr; gap: 20px; padding: 0 20px 22px; }
}
.hero-heading { grid-column: span 8; }
.hero-side { grid-column: span 4; display: flex; flex-direction: column; gap: 18px; }
@media (max-width: 860px) {
  .hero-heading, .hero-side { grid-column: 1 / -1; }
}

.hero-giant {
  color: var(--cream);
  font-weight: 500;
  line-height: 0.85;
  letter-spacing: -0.07em;
  font-size: 26vw;
  position: relative;
  display: inline-block;
}
@media (min-width: 640px) { .hero-giant { font-size: 24vw; } }
@media (min-width: 768px) { .hero-giant { font-size: 22vw; } }
@media (min-width: 1024px) { .hero-giant { font-size: 20vw; } }
@media (min-width: 1280px) { .hero-giant { font-size: 19vw; } }
@media (min-width: 1536px) { .hero-giant { font-size: 20vw; } }
.hero-giant .star {
  position: absolute;
  top: 0.65em; right: -0.3em;
  font-size: 0.31em;
  color: var(--cream);
}
.hero-desc {
  color: rgba(225, 224, 204, 0.70);
  font-size: 12px;
  line-height: 1.2;
}
@media (min-width: 640px) { .hero-desc { font-size: 14px; } }
@media (min-width: 768px) { .hero-desc { font-size: 16px; } }

.btn-pill {
  display: inline-flex; align-items: center; gap: 8px;
  align-self: flex-start;
  background: var(--cream-accent);
  color: #000;
  font-weight: 700;
  border-radius: 999px;
  padding: 6px 6px 6px 20px;
  font-size: 14px;
  transition: gap 220ms var(--ease-cinematic);
}
@media (min-width: 640px) { .btn-pill { font-size: 16px; } }
.btn-pill:hover { gap: 12px; }
.btn-pill .circle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  background: #000; color: var(--cream);
  border-radius: 999px;
  transition: transform 220ms var(--ease-cinematic);
}
@media (min-width: 640px) { .btn-pill .circle { width: 40px; height: 40px; } }
.btn-pill:hover .circle { transform: scale(1.10); }
.btn-pill .circle svg { width: 18px; height: 18px; }

/* ============================================================
   GENERIC SECTION HEADERS (page heads on inner pages)
   ============================================================ */
.eyebrow {
  display: inline-block;
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--cream-accent);
}
.section { padding: 110px 0; }
@media (max-width: 640px) { .section { padding: 80px 0; } }

/* ============================================================
   ABOUT (landing section)
   ============================================================ */
.about { background: var(--black); padding: 8px; }
.about-card {
  background: var(--about-card);
  border-radius: var(--radius-lg);
  text-align: center;
  padding: 110px 28px;
}
@media (max-width: 640px) { .about-card { padding: 72px 20px; border-radius: var(--radius-md); } }
.about-label { color: var(--cream-accent); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; }
@media (min-width: 640px) { .about-label { font-size: 12px; } }
.about-heading {
  max-width: 820px; margin: 22px auto 0;
  font-size: clamp(30px, 6vw, 76px);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.02em;
  color: var(--cream);
}
.about-heading .serif { font-weight: 400; }
.about-body {
  max-width: 720px; margin: 40px auto 0;
  font-size: 13px; line-height: 1.7;
  color: var(--cream-accent);
}
@media (min-width: 640px) { .about-body { font-size: 15px; } }
@media (min-width: 768px) { .about-body { font-size: 17px; } }

/* ============================================================
   FEATURES (landing section)
   ============================================================ */
.features {
  position: relative;
  min-height: 100vh;
  background: var(--black);
  padding: 110px 0 130px;
  overflow: hidden;
}
.features .bg-noise {
  position: absolute; inset: 0; z-index: 0;
  opacity: 0.15; pointer-events: none;
}
.features .wrap { position: relative; z-index: 1; }
.features-head {
  font-size: clamp(20px, 3.4vw, 38px);
  font-weight: 400; line-height: 1.15;
  letter-spacing: -0.01em;
  max-width: 900px;
  margin-bottom: 48px;
}
.features-head .l1 { color: var(--cream); }
.features-head .l2 { color: var(--gray-500); }

.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 768px) { .feature-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } }
@media (min-width: 1024px) {
  .feature-grid { grid-template-columns: repeat(4, 1fr); gap: 4px; height: 480px; }
}

.fcard {
  position: relative;
  background: var(--feature-card);
  border-radius: 18px;
  overflow: hidden;
  padding: 22px;
  display: flex; flex-direction: column;
  min-height: 360px;
}
@media (min-width: 1024px) { .fcard { min-height: 0; height: 100%; } }

/* card 1 - video */
.fcard.video { padding: 0; }
.fcard.video video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 0;
}
.fcard.video .vfallback {
  position: absolute; inset: 0; z-index: 0;
  background: radial-gradient(120% 100% at 50% 0%, #3a342c 0%, #1a1813 55%, #0c0b09 100%);
}
.fcard.video .vlabel {
  position: relative; z-index: 1;
  margin-top: auto; padding: 22px;
  color: var(--cream);
  font-size: 18px; font-weight: 700; letter-spacing: -0.01em;
}
.fcard.video .vgrad {
  position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, transparent 55%);
}

.fcard .ficon {
  width: 40px; height: 40px; border-radius: 10px;
  object-fit: cover;
  background: #2e2e2e;
  margin-bottom: auto;
}
@media (min-width: 640px) { .fcard .ficon { width: 48px; height: 48px; } }
.fcard .ftitle {
  margin-top: 24px;
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  color: var(--cream);
  font-size: 19px; font-weight: 700; letter-spacing: -0.01em;
}
.fcard .ftitle .num {
  font-size: 11px; color: var(--gray-500); font-weight: 400;
  letter-spacing: 0.1em;
}
.fcard .fchecks {
  list-style: none; padding: 0; margin: 16px 0 0;
  display: flex; flex-direction: column; gap: 10px;
}
.fcard .fchecks li {
  display: flex; align-items: flex-start; gap: 8px;
  color: var(--gray-400); font-size: 12.5px; line-height: 1.35;
}
.fcard .fchecks li svg { width: 14px; height: 14px; color: var(--cream-accent); flex-shrink: 0; margin-top: 2px; }
.fcard .flearn {
  margin-top: 18px;
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--cream-accent); font-size: 12px; font-weight: 700;
  transition: gap 200ms ease;
}
.fcard .flearn:hover { gap: 10px; }
.fcard .flearn svg { width: 13px; height: 13px; transform: rotate(-45deg); }

/* ============================================================
   INNER PAGE HEAD
   ============================================================ */
.page-head { padding: 160px 0 40px; }
.page-head h1 {
  font-size: clamp(40px, 8vw, 96px);
  font-weight: 500; line-height: 0.92; letter-spacing: -0.04em;
  color: var(--cream); margin-top: 18px;
}
.page-head h1 .serif { font-weight: 400; }
.page-head .lede {
  margin-top: 26px; max-width: 620px;
  color: var(--cream-accent); font-size: clamp(15px, 1.4vw, 19px); line-height: 1.5;
}

/* ============================================================
   PROJECTS GRID (inner page)
   ============================================================ */
.work-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
  padding-bottom: 130px;
}
@media (max-width: 820px) { .work-grid { grid-template-columns: 1fr; } }
.work-card {
  position: relative;
  background: var(--feature-card);
  border-radius: 20px; overflow: hidden;
  padding: 22px;
  transition: transform 320ms var(--ease-card);
  display: flex; flex-direction: column;
}
.work-card:hover { transform: translateY(-4px); }
.work-card .shot {
  border-radius: 14px; overflow: hidden;
  aspect-ratio: 16 / 10;
  display: flex; align-items: center; justify-content: center;
}
.work-card .pills { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.work-card .tag {
  font-size: 11px; letter-spacing: 0.04em;
  background: rgba(225,224,204,0.10); color: var(--cream-accent);
  border-radius: 6px; padding: 4px 10px;
}
.work-card h3 {
  margin-top: 14px;
  color: var(--cream); font-size: clamp(20px, 2vw, 27px);
  font-weight: 700; line-height: 1.12; letter-spacing: -0.02em;
}
.work-card h3 .arrow { display: inline-block; transition: transform 220ms ease; }
.work-card:hover h3 .arrow { transform: translate(3px, -3px); }
.work-card p.desc { margin-top: 10px; color: var(--gray-400); font-size: 14px; line-height: 1.5; }

/* phone mock surfaces reused from legacy, recolored for dark bg */
.surf {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.surf-dark  { background: radial-gradient(120% 120% at 50% 0%, #2b2b2e 0%, #161618 60%, #0d0d0f 100%); }
.surf-amber { background: radial-gradient(120% 120% at 50% 0%, #5a4632 0%, #2c2017 60%, #140e0a 100%); }
.surf-blue  { background: radial-gradient(120% 120% at 50% 0%, #2a3550 0%, #161d2e 60%, #0b0e16 100%); }
.surf-ember { background: radial-gradient(120% 120% at 50% 0%, #6a2f24 0%, #2a100c 55%, #140605 100%); }
.surf-stone { background: radial-gradient(120% 120% at 50% 0%, #44423d 0%, #232220 60%, #121110 100%); }

.phone {
  width: 34%; aspect-ratio: 9 / 19.5;
  background: #0c0c0d; border-radius: 14% / 6.4%;
  padding: 5px;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.7), inset 0 0 0 1.5px #2a2a2c;
  position: relative; transform: translateY(3%);
}
.phone .screen { width: 100%; height: 100%; border-radius: 11% / 5%; overflow: hidden; position: relative; }
.phone .notch { position: absolute; top: 2.5%; left: 50%; transform: translateX(-50%); width: 32%; height: 4.5%; background: #0c0c0d; border-radius: 999px; z-index: 3; }
.screen-inner { position: absolute; inset: 0; display: flex; flex-direction: column; }

/* mini phone screen content (shared by projects + case studies) */
.scr { position:absolute; inset:0; display:flex; flex-direction:column; padding:13% 9% 9%; color:#E1E0CC; font-size:6px; }
.scr .t { font-size:5px; letter-spacing:.15em; opacity:.5; }
.scr .big { font-size:12px; font-weight:700; letter-spacing:-.03em; line-height:1.05; margin-top:6px; }
.scr .sub { font-size:5.5px; opacity:.7; margin-top:4px; line-height:1.3; }
.scr .bars { margin-top:auto; display:flex; flex-direction:column; gap:4px; }
.scr .bar { height:6px; border-radius:3px; background:rgba(225,224,204,.16); }
.scr .bar.b2 { width:78%; } .scr .bar.b3 { width:55%; }
.scr .pill { margin-top:8px; text-align:center; padding:5px 0; border-radius:999px; background:#E1E0CC; color:#111; font-size:6px; font-weight:700; }

/* ============================================================
   CASE STUDY
   ============================================================ */
.cs-hero { padding: 160px 0 60px; }
.cs-hero .meta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 26px; }
.cs-hero h1 {
  font-size: clamp(36px, 6.5vw, 88px);
  font-weight: 500; line-height: 0.95; letter-spacing: -0.04em; color: var(--cream);
  max-width: 1100px;
}
.cs-hero .tagline { margin-top: 26px; max-width: 640px; color: var(--cream-accent); font-size: clamp(16px,1.5vw,21px); line-height: 1.5; }
.cs-cover {
  margin: 50px 0; border-radius: var(--radius-lg); overflow: hidden;
  aspect-ratio: 16 / 8; display: flex; align-items: center; justify-content: center;
}
/* En mobile se mantiene el 16/8 del desktop: las portadas son videos 2:1 y con
   un ratio vertical (el 4/5 que usaban los antiguos mockups de teléfono) se
   recortaban a una franja central. Así se ve el encuadre completo. */
@media (max-width: 640px) { .cs-cover { border-radius: var(--radius-md); } }
/* keep the whole phone visible inside the wide cover (don't crop the screen) */
.cs-cover .phone { width: auto; height: 84%; transform: none; }
@media (max-width: 640px) { .cs-cover .phone { height: auto; width: 52%; } }
/* Video de banner que cubre por completo la portada del case study */
.cs-cover-video { width: 100%; height: 100%; object-fit: cover; display: block; }
.cs-overview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 30px 24px 70px; border-bottom: 1px solid var(--line); }
@media (max-width: 720px) { .cs-overview { grid-template-columns: repeat(2, 1fr); } }
.cs-overview .item .k { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--gray-500); }
.cs-overview .item .v { margin-top: 8px; color: var(--cream); font-size: 15px; line-height: 1.4; }
.cs-section { padding: 70px 0; border-bottom: 1px solid var(--line); }
.cs-section .grid2 { display: grid; grid-template-columns: minmax(0,0.8fr) minmax(0,1.2fr); gap: 50px; align-items: start; }
@media (max-width: 820px) { .cs-section .grid2 { grid-template-columns: 1fr; gap: 22px; } }
.cs-section h2 { font-size: clamp(26px,3vw,42px); font-weight: 500; letter-spacing: -0.03em; line-height: 1.02; color: var(--cream); }
.cs-section p { color: var(--cream-accent); font-size: clamp(15px,1.3vw,18px); line-height: 1.6; }
.cs-section p + p { margin-top: 18px; }
.cs-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 70px 0; }
@media (max-width: 600px) { .cs-stats { grid-template-columns: 1fr; } }
.cs-stat { background: var(--feature-card); border-radius: 18px; padding: 26px; }
.cs-stat .n { font-size: clamp(34px,4vw,54px); font-weight: 500; letter-spacing: -0.035em; line-height: 0.95; color: var(--cream); }
.cs-stat .l { margin-top: 8px; font-size: 13px; color: var(--gray-400); line-height: 1.35; }
.cs-quote { padding: 80px 0; text-align: center; }
.cs-quote p { font-size: clamp(24px,3.4vw,44px); font-weight: 400; line-height: 1.15; letter-spacing: -0.02em; color: var(--cream); max-width: 980px; margin: 0 auto; }
.cs-quote .who { margin-top: 26px; color: var(--gray-400); font-size: 14px; }
.cs-next { padding: 70px 0 0; }
.cs-next a { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.cs-next .k { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gray-500); }
.cs-next h3 { margin-top: 10px; font-size: clamp(28px,4vw,56px); font-weight: 500; letter-spacing: -0.03em; color: var(--cream); }
.cs-next:hover h3 { color: var(--cream-accent); }

/* ============================================================
   FOOTER
   ============================================================ */
.foot { background: var(--black); padding: 110px 0 50px; border-top: 1px solid var(--line); }
.foot .big {
  font-size: clamp(38px, 7vw, 96px);
  font-weight: 500; line-height: 0.95; letter-spacing: -0.04em; color: var(--cream);
}
.foot .big .serif { font-weight: 400; }
.foot .contact {
  margin-top: 40px; display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center;
}
.foot .mail {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--cream-accent); color: #000;
  border-radius: 999px; padding: 12px 22px; font-weight: 700; font-size: 15px;
  transition: transform 200ms ease;
}
.foot .mail:hover { transform: translateY(-2px); }
.foot .avail { color: var(--gray-400); font-size: 13px; }
.foot-grid {
  margin-top: 70px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  border-top: 1px solid var(--line); padding-top: 36px;
}
@media (max-width: 720px) { .foot-grid { grid-template-columns: repeat(2, 1fr); gap: 30px 16px; } }
.foot-grid .head { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gray-500); margin-bottom: 14px; }
.foot-grid .links { display: flex; flex-direction: column; gap: 10px; }
.foot-grid .links a { color: var(--cream-accent); font-size: 14px; transition: color 160ms ease; }
.foot-grid .links a:hover { color: var(--cream); }
.foot-grid .located { color: var(--cream-accent); font-size: 14px; line-height: 1.6; }
.foot-grid .clock { color: var(--gray-500); }
.foot-grid .logo-cell svg { width: 46px; height: 54px; color: #3a3a36; }
.foot .baseline {
  margin-top: 50px; display: flex; justify-content: space-between; gap: 12px;
  color: var(--gray-500); font-size: 12px; flex-wrap: wrap;
}

/* ============================================================
   ANIMATION PRIMITIVES (driven by prisma.js)
   ============================================================ */
/* word pull-up: each .word starts pushed down + transparent */
.pullup-multi { display: flex; flex-wrap: wrap; }
.about-heading.pullup-multi { justify-content: center; }
.seg { display: contents; }
.word {
  display: inline-block;
  white-space: pre;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 650ms var(--ease-cinematic), opacity 650ms var(--ease-cinematic);
  transition-delay: calc(var(--i, 0) * 80ms);
}
.is-in .word { transform: translateY(0); opacity: 1; }

/* generic fade-up */
[data-fade] {
  opacity: 0; transform: translateY(20px);
  transition: opacity 800ms var(--ease-cinematic), transform 800ms var(--ease-cinematic);
  transition-delay: var(--fade-delay, 0ms);
}
[data-fade].is-in { opacity: 1; transform: translateY(0); }

/* card entrance */
[data-card] {
  opacity: 0; transform: scale(0.95);
  transition: opacity 700ms var(--ease-card), transform 700ms var(--ease-card);
  transition-delay: calc(var(--c, 0) * 150ms);
}
[data-card].is-in { opacity: 1; transform: scale(1); }

/* scroll-linked characters: opacity set inline by JS */
.schar { transition: opacity 120ms linear; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .word, [data-fade], [data-card] { transition: none !important; transform: none !important; opacity: 1 !important; }
  .schar { opacity: 1 !important; }
  [data-stack-card] { transform: none !important; }
}

/* ============================================================
   MODULE: big section heading (Services / Projects)
   ============================================================ */
.module-h {
  font-size: clamp(3rem, 12vw, 150px);
  font-weight: 800; text-transform: uppercase;
  letter-spacing: -0.04em; line-height: 0.85;
  color: var(--cream); text-align: center;
}
.module-h .serif { font-weight: 400; text-transform: none; letter-spacing: -0.02em; }
.module-sub {
  text-align: center; margin: 22px auto 0; max-width: 560px;
  color: var(--cream-accent); font-size: clamp(15px, 1.4vw, 19px); line-height: 1.55;
}

/* ============================================================
   MODULE: SERVICES
   ============================================================ */
.services-sec { padding: 150px 0 90px; }
.svc-list { max-width: 1100px; margin: 54px auto 0; }
.svc-row {
  display: grid; grid-template-columns: auto 1fr; gap: 30px; align-items: baseline;
  padding: 42px 0; border-top: 1px solid var(--line);
}
.svc-row:last-child { border-bottom: 1px solid var(--line); }
.svc-row .num {
  font-weight: 800; font-size: clamp(3rem, 9vw, 130px); line-height: 0.8;
  letter-spacing: -0.05em; color: var(--cream);
  min-width: clamp(70px, 11vw, 180px);
}
.svc-row .name {
  font-size: clamp(1.1rem, 2.2vw, 2.1rem); text-transform: uppercase;
  letter-spacing: 0.01em; color: var(--cream); font-weight: 700; line-height: 1.05;
}
.svc-row .desc {
  margin-top: 14px; max-width: 660px; color: var(--gray-400);
  font-size: clamp(0.9rem, 1.5vw, 1.18rem); line-height: 1.55;
}
@media (max-width: 640px) {
  .svc-row { grid-template-columns: 1fr; gap: 8px; padding: 30px 0; }
  .svc-row .num { font-size: 56px; }
}

/* ============================================================
   MODULE: PROJECT STACK (sticky cards that scale on scroll)
   ============================================================ */
.projects-stack-sec { padding: 60px 0 120px; }
.pstack { position: relative; margin-top: 56px; }
.pstack-card {
  position: sticky; top: 96px;
  border: 2px solid var(--cream); background: var(--black);
  border-radius: 40px; padding: 20px;
  transform-origin: top center; will-change: transform;
}
@media (min-width: 768px) { .pstack-card { top: 120px; border-radius: 56px; padding: 30px; } }
.pstack-card + .pstack-card { margin-top: 44px; }
.pcard-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; flex-wrap: wrap; margin-bottom: 22px;
}
.pcard-top .left { display: flex; align-items: baseline; gap: 18px; min-width: 0; }
.pcard-top .pnum {
  font-weight: 800; font-size: clamp(2.4rem, 6vw, 86px); line-height: 0.78;
  letter-spacing: -0.05em; color: var(--cream);
}
.pcard-top .cat { font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gray-500); }
.pcard-top .pname { font-size: clamp(1.3rem, 3vw, 2.3rem); font-weight: 700; letter-spacing: -0.02em; color: var(--cream); line-height: 1.05; }
.pcard-media { display: grid; grid-template-columns: 40% 1fr; gap: 16px; }
.pcard-media .col1 { display: flex; flex-direction: column; gap: 16px; }
.pcard-media img { width: 100%; object-fit: cover; border-radius: 28px; display: block; background: var(--feature-card); }
@media (min-width: 768px) { .pcard-media img { border-radius: 40px; } }
.pcard-media .col1 .m1 { height: clamp(130px, 16vw, 230px); }
.pcard-media .col1 .m2 { height: clamp(160px, 22vw, 340px); }
.pcard-media .col2 img { height: 100%; min-height: clamp(306px, 38vw, 586px); }
@media (max-width: 640px) {
  .pcard-media { grid-template-columns: 1fr; }
  .pcard-media .col1 .m1, .pcard-media .col1 .m2 { height: 200px; }
  .pcard-media .col2 img { min-height: 240px; }
}

.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  border: 2px solid var(--cream); color: var(--cream);
  border-radius: 999px; padding: 10px 22px;
  text-transform: uppercase; letter-spacing: 0.12em; font-size: 12.5px; font-weight: 700;
  white-space: nowrap; transition: background 200ms ease;
}
.btn-ghost:hover { background: rgba(225, 224, 204, 0.10); }

/* ============================================================
   MODULE: JOURNAL (featured post + 3-card grid, viewfinder hover)
   ============================================================ */
.journal-sec { padding: 150px 0 70px; }
.journal-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 30px 50px; flex-wrap: wrap; margin-bottom: 44px;
}
.journal-head .jh-left { min-width: 0; }
.badge-chip {
  display: inline-block; background: rgba(225, 224, 204, 0.08);
  color: var(--cream-accent); border-radius: 8px; padding: 6px 13px;
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
}
.journal-h {
  margin-top: 18px;
  font-size: clamp(40px, 6vw, 64px); font-weight: 800;
  letter-spacing: -0.04em; line-height: 0.92; color: var(--cream);
}
.journal-head .jh-right {
  display: flex; align-items: flex-end; gap: 26px; flex-wrap: wrap;
}
.journal-sub { max-width: 480px; color: var(--gray-400); font-size: 17px; font-weight: 300; line-height: 1.5; }
@media (max-width: 768px) { .journal-head { flex-direction: column; align-items: flex-start; } }

.btn-cream {
  display: inline-flex; align-items: center; white-space: nowrap;
  background: var(--cream-accent); color: #000;
  border-radius: 40px; padding: 13px 26px; font-size: 14px; font-weight: 700;
  transition: transform 200ms ease;
}
.btn-cream:hover { transform: scale(1.03); }

/* viewfinder media (shared by featured + cards) */
.vhover { position: relative; overflow: hidden; }
.vhover > video, .vhover > img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  background: var(--feature-card);
  transition: transform 0.5s cubic-bezier(0.33, 1, 0.68, 1);
}
.vhover:hover > video, .vhover:hover > img { transform: scale(1.08); }
.vhover .voverlay {
  position: absolute; inset: 0; background: rgba(0, 0, 0, 0.25);
  opacity: 0; transition: opacity 0.4s ease; pointer-events: none;
}
.vhover:hover .voverlay { opacity: 1; }
.vhover .vplus {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.7);
  width: 70px; height: 70px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.3s ease, transform 0.3s ease; pointer-events: none;
}
.vhover:hover .vplus { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.vhover .vplus svg { width: 26px; height: 26px; color: #fff; }
.vhover .corner { position: absolute; width: 12px; height: 12px; border: 1.5px solid rgba(255, 255, 255, 0.65); pointer-events: none; }
.vhover .corner.tl { top: 15px; left: 15px; border-right: none; border-bottom: none; }
.vhover .corner.tr { top: 15px; right: 15px; border-left: none; border-bottom: none; }
.vhover .corner.bl { bottom: 15px; left: 15px; border-right: none; border-top: none; }
.vhover .corner.br { bottom: 15px; right: 15px; border-left: none; border-top: none; }

/* category badge */
.cat-badge {
  display: inline-block; border-radius: 999px; color: #fff;
  font-size: 11px; font-weight: 700; padding: 4px 12px;
  text-transform: capitalize; white-space: nowrap;
}

/* featured post */
.feat-post {
  display: grid; grid-template-columns: 1fr 1fr;
  border: 1px solid var(--line); border-radius: 24px; overflow: hidden;
  min-height: 520px; background: var(--feature-card); margin-bottom: 25px;
}
.feat-post .media { position: relative; min-height: 320px; }
.feat-post .fbody { padding: 56px; display: flex; flex-direction: column; }
.must-read {
  align-self: flex-start; background: var(--cream-accent); color: #000;
  border-radius: 20px; padding: 5px 14px; font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.06em;
}
.feat-title { margin-top: 26px; font-size: clamp(28px, 3.4vw, 46px); font-weight: 700; letter-spacing: -0.02em; line-height: 1.04; color: var(--cream); }
.feat-desc { margin-top: 20px; color: var(--gray-400); font-size: 17px; line-height: 1.55; max-width: 460px; }
.feat-foot { margin-top: auto; padding-top: 34px; display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.feat-foot .author { color: var(--cream-accent); font-size: 14px; }
@media (max-width: 1024px) {
  .feat-post { grid-template-columns: 1fr; }
  .feat-post .fbody { padding: 40px; }
  .feat-post .media { min-height: 300px; }
}
@media (max-width: 768px) { .feat-post .fbody { padding: 30px; } }

/* 3-card grid */
.journal-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 25px; }
.jcard .media { aspect-ratio: 16 / 10; border-radius: 20px; }
.jcard .jrow { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-top: 16px; }
.jcard .jtitle { font-size: 17px; font-weight: 700; line-height: 1.25; color: var(--cream); }
@media (max-width: 1024px) { .journal-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) { .journal-grid { grid-template-columns: 1fr; } }

/* ============================================================
   MODULE: WORK CARDS (simple project cards, replaces the stack)
   ============================================================ */
.work-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin-top: 56px; }
@media (max-width: 820px) { .work-cards { grid-template-columns: 1fr; } }
.wcard {
  background: var(--feature-card); border: 1px solid var(--line);
  border-radius: 24px; overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform 300ms var(--ease-card);
}
.wcard:hover { transform: translateY(-5px); }
.wcard-img { position: relative; overflow: hidden; aspect-ratio: 4 / 3; }
.wcard-img img { width: 100%; height: 100%; object-fit: cover; display: block; background: #1a1a1a; transition: transform 0.6s var(--ease-card); }
.wcard:hover .wcard-img img { transform: scale(1.05); }
.wcard-img .cat-badge { position: absolute; top: 16px; left: 16px; }
.wcard-body { padding: 28px 30px 30px; display: flex; flex-direction: column; flex: 1; }
.wcard-title { font-size: clamp(1.3rem, 2vw, 1.9rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; color: var(--cream); }
.wcard-desc { margin-top: 14px; color: var(--gray-400); font-size: 15px; line-height: 1.55; }
.wcard-cta {
  margin-top: 26px; align-self: flex-start;
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--cream); font-size: 13px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em;
  border-bottom: 1px solid var(--cream); padding-bottom: 3px;
  transition: gap 200ms ease, color 200ms ease, border-color 200ms ease;
}
.wcard-cta:hover { gap: 12px; color: var(--cream-accent); border-color: var(--cream-accent); }

/* ============================================================
   PAGE TRANSITIONS (View Transitions API, smart-animate style)
   ============================================================ */
@view-transition { navigation: auto; }

/* Elementos persistentes: el navegador los interpola en vez de cruzarlos */
.nav { view-transition-name: site-nav; }
.foot { view-transition-name: site-foot; }

::view-transition-old(root) { animation: vt-out 260ms cubic-bezier(0.4, 0, 0.2, 1) both; }
::view-transition-new(root) { animation: vt-in 380ms cubic-bezier(0.16, 1, 0.3, 1) both; }
::view-transition-old(site-nav), ::view-transition-new(site-nav),
::view-transition-old(site-foot), ::view-transition-new(site-foot) {
  animation: none; mix-blend-mode: normal;
}

@keyframes vt-out { to { opacity: 0; transform: translateY(-14px) scale(0.994); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(18px) scale(0.994); } }

/* Fallback para navegadores sin View Transitions */
body.page-leaving { opacity: 0; transform: translateY(-10px); }
body { transition: opacity 220ms ease, transform 220ms ease; }

@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
  body.page-leaving { opacity: 1; transform: none; }
}

/* ============================================================
   FOOTER GLASS (compartido por todas las páginas)
   ============================================================ */
.foot-card {
  --g-blur: 28px; --g-sat: 180%;
  --g-tint: linear-gradient(150deg, rgba(255,255,255,0.13), rgba(255,255,255,0.05) 45%, rgba(255,255,255,0.09));
  --g-tint-hover: linear-gradient(150deg, rgba(255,255,255,0.19), rgba(255,255,255,0.08) 45%, rgba(255,255,255,0.14));
  --g-edge: rgba(255,255,255,0.16);
  --g-edge-hover: rgba(255,255,255,0.24);
  --g-edge-top: rgba(255,255,255,0.26);
  --g-edge-hi: rgba(255,255,255,0.55);
  --g-glow: rgba(225,224,204,0.16);
  --g-shadow: 0 28px 66px -18px rgba(0,0,0,0.62);
  --g-shadow-hover: 0 40px 90px -18px rgba(0,0,0,0.75);
  --g-focus: var(--cream-accent);
  position: relative; isolation: isolate;
  border-radius: 24px; padding: 64px 56px 56px;
  background: var(--g-tint);
  backdrop-filter: blur(var(--g-blur)) saturate(var(--g-sat));
  -webkit-backdrop-filter: blur(var(--g-blur)) saturate(var(--g-sat));
  box-shadow: 0 0 0 1px var(--g-edge), 0 1px 0 var(--g-edge-top) inset, var(--g-shadow);
  transition: background 300ms cubic-bezier(0.25, 0.1, 0.25, 1),
              box-shadow 300ms cubic-bezier(0.25, 0.1, 0.25, 1),
              transform 300ms cubic-bezier(0.25, 0.1, 0.25, 1);
}
.foot-card::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit; z-index: -1;
  padding: 1px;
  background: linear-gradient(140deg, var(--g-edge-hi), transparent 38%, transparent 62%, var(--g-edge-hi));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none;
}
.foot-card::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; z-index: -1;
  background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 0%), var(--g-glow), transparent 70%);
  opacity: 0; pointer-events: none;
  transition: opacity 300ms cubic-bezier(0.25, 0.1, 0.25, 1);
}
.foot-card:hover, .foot-card:focus-within {
  transform: translateY(-3px) scale(1.02);
  background: var(--g-tint-hover);
  box-shadow: 0 0 0 1px var(--g-edge-hover), 0 1px 0 var(--g-edge-top) inset, var(--g-shadow-hover);
}
.foot-card:hover::after, .foot-card:focus-within::after { opacity: 1; }
.foot-card :is(a, button):focus-visible { outline: 2px solid var(--g-focus); outline-offset: 3px; border-radius: 999px; }
@media (max-width: 720px) { .foot-card { padding: 40px 26px; border-radius: 20px; } }

/* contraste invertido dentro de la card */
.foot-card .eyebrow { color: rgba(225, 224, 204, 0.55); }
.foot-card .big { color: #fff; }
.foot-card .big .serif { color: var(--cream-accent); }
.foot-card .btn-reveal { background: var(--cream-accent); color: #000; }
.foot-card .btn-reveal .circle { background: rgba(0, 0, 0, 0.88); color: var(--cream-accent); }
.foot-card .btn-ghost { background: rgba(255, 255, 255, 0.06); color: #fff; border-color: rgba(255, 255, 255, 0.22); }
.foot-card .btn-ghost .circle { background: rgba(255, 255, 255, 0.14); color: #fff; }

/* los tres botones de contacto: misma altura y espaciado */
.foot .contact { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 0; }
.contact-actions .btn-reveal {
  box-sizing: border-box; height: 52px; font-size: 15px; font-weight: 700;
  display: inline-flex; align-items: center; border-radius: 999px;
  padding: 0 20px 0 6px; text-transform: none; letter-spacing: normal;
  transition: gap 220ms var(--ease-cinematic), transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.contact-actions .btn-ghost { padding: 0 19px 0 5px; }
.foot .baseline { margin-top: 28px; }

/* footer suelto (páginas sin la banda oscura): fondo con ruido y aura propios */
.foot--solo { position: relative; overflow: hidden; border-top: none; padding-top: 60px; }
.foot--solo > .bg-noise { position: absolute; inset: 0; z-index: 0; opacity: 0.15; pointer-events: none; }
.foot--solo > .wrap { position: relative; z-index: 1; }
.foot--solo::before {
  content: ''; position: absolute; z-index: 0; pointer-events: none;
  width: 90vw; height: 70vh; left: 50%; top: 40%;
  background: radial-gradient(closest-side, rgba(225, 224, 204, 0.16), rgba(225, 224, 204, 0.06) 55%, transparent 75%);
  filter: blur(90px);
  animation: aura-drift 30s ease-in-out infinite alternate;
}
@media (prefers-reduced-motion: reduce) {
  .foot-card, .foot-card::after { transition: none; }
  .foot-card:hover, .foot-card:focus-within { transform: none; }
  .foot--solo::before { animation: none; transform: translate(-50%, -50%); }
}
@keyframes aura-drift {
  0%   { transform: translate(-70%, -60%) scale(1); }
  50%  { transform: translate(-40%, -35%) scale(1.18); }
  100% { transform: translate(-25%, -55%) scale(0.94); }
}

/* ---------------- Botón text-reveal (compartido) ---------------- */
.btn-reveal { box-sizing: border-box; text-transform: none; letter-spacing: normal;
  transition: gap 220ms var(--ease-cinematic), transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1); }
.btn-reveal:hover { transform: scale(1.02); gap: 8px; }
.btn-reveal:active { transform: scale(0.96); }
.btn-reveal .circle svg { transition: transform 300ms cubic-bezier(0.34, 1.56, 0.64, 1); }
.btn-reveal:hover .circle svg { transform: rotate(-45deg); }
.btn-reveal:hover .circle { transform: none; }
.btn-reveal .reveal-clip { display: block; height: 1.3em; overflow: hidden; }
.btn-reveal .reveal-stack { display: flex; flex-direction: column;
  transition: transform 300ms cubic-bezier(0.34, 1.56, 0.64, 1); }
.btn-reveal .reveal-stack > span { display: block; height: 1.3em; line-height: 1.3; white-space: nowrap; }
.btn-reveal:hover .reveal-stack { transform: translateY(-1.3em); }

/* placeholder de portada en los case studies */
.cs-slot { display: flex; align-items: flex-end; width: 100%; height: 100%; padding: 20px;
  border-radius: 18px; background-color: #191919;
  background-image: repeating-linear-gradient(135deg, rgba(225,224,204,0.05) 0 10px, transparent 10px 20px); }
.cs-slot span { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px;
  letter-spacing: 0.06em; color: rgba(225,224,204,0.45); }

/* ============================================================
   ABOUT EN CLARO (por defecto)
   Solo redefine los tokens dentro de las secciones de la página,
   así el nav y el footer siguen oscuros como en el resto del sitio.
   ============================================================ */
body.light-page { background: #fafafa; }
body.light-page .page-head,
body.light-page .intro,
body.light-page .exp-wrap,
body.light-page .skills-wrap {
  --black: #fafafa;
  --about-card: #f1f0ec;
  --feature-card: #ffffff;
  --cream: #171717;
  --cream-accent: #4a4a46;
  --gray-400: #737373;
  --gray-500: #6b6b67;
  --line: rgba(23, 23, 23, 0.12);
  --check: #4f7a4c;
  background: #fafafa;
  color: #171717;
}
/* El retrato mantiene su superficie oscura: su texto sigue siendo crema */
body.light-page .portrait .ticket, body.light-page .portrait .ticket span { color: #E1E0CC; }
/* Los chips numerados usan un par explícito, no un token que aquí es color de texto */
body.light-page .skill-card .group .num { background: #171717; color: #fafafa; }
body.light-page .grain, body.light-page .bg-noise:not(.foot .bg-noise) { opacity: 0.05; }

/* ============================================================
   CASE STUDY EN CLARO
   Igual que about: los tokens se redefinen solo en las secciones
   de la página, así el nav sigue oscuro. Pares texto/superficie
   que no son token-driven se declaran explícitos.
   ============================================================ */
body.light-page .cs-hero,
body.light-page .cs-overview,
body.light-page .cs-section,
body.light-page .cs-stats,
body.light-page .cs-quote {
  --black: #fafafa;
  --about-card: #f1f0ec;
  --feature-card: #ffffff;
  --cream: #171717;
  --cream-accent: #4a4a46;
  --gray-400: #737373;
  --gray-500: #6b6b67;
  --line: rgba(23, 23, 23, 0.12);
  --check: #4f7a4c;
  background: #fafafa;
  color: #171717;
}
body.light-page .cs-quote p { color: #171717; }
/* la portada mantiene su superficie oscura: su etiqueta sigue en crema */
body.light-page .cs-slot span { color: rgba(225,224,204,0.45); }
body.light-page .cs-next { border-color: rgba(23,23,23,0.14); }
body.light-page .cs-next h3 { color: #171717; }

/* footer claro en las páginas de tema claro */
body.light-page .foot--solo { background: #fafafa; }
body.light-page .foot--solo > .bg-noise { opacity: 0.05; }
body.light-page .foot--solo::before { background: radial-gradient(closest-side, rgba(23,23,23,0.07), rgba(23,23,23,0.03) 55%, transparent 75%); }
body.light-page .foot-card {
  --g-tint: linear-gradient(150deg, rgba(255,255,255,0.62), rgba(255,255,255,0.34) 45%, rgba(255,255,255,0.52));
  --g-tint-hover: linear-gradient(150deg, rgba(255,255,255,0.78), rgba(255,255,255,0.46) 45%, rgba(255,255,255,0.64));
  --g-edge: rgba(255,255,255,0.55);
  --g-edge-hover: rgba(255,255,255,0.72);
  --g-edge-top: rgba(255,255,255,0.92);
  --g-edge-hi: rgba(255,255,255,0.95);
  --g-glow: rgba(255,255,255,0.6);
  --g-shadow: 0 18px 50px -14px rgba(23,23,23,0.24);
  --g-shadow-hover: 0 28px 66px -14px rgba(23,23,23,0.30);
  --g-focus: #171717;
}
body.light-page .foot-card .eyebrow { color: #6b6b67; }
body.light-page .foot-card .big { color: #171717; }
body.light-page .foot-card .big .serif { color: #4a4a46; }
body.light-page .foot-card .btn-reveal { background: #171717; color: #fafafa; }
body.light-page .foot-card .btn-reveal .circle { background: #fafafa; color: #171717; }
body.light-page .foot-card .btn-ghost { background: transparent; color: #171717; border-color: rgba(23,23,23,0.24); }
body.light-page .foot-card .btn-ghost .circle { background: rgba(23,23,23,0.10); color: #171717; }
body.light-page .foot .baseline { color: #6b6b67; }

/* CHIPS DEL META-ROW + barra del eyebrow (case studies) */
.cs-hero .meta-row { display: flex; flex-wrap: wrap; gap: 8px; }
.cs-hero .tag {
  display: inline-flex; align-items: center;
  padding: 4px 10px; border-radius: 6px;
  font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  background: rgba(225, 224, 204, 0.10); color: var(--cream-accent);
}
body.light-page .cs-hero .tag { background: rgba(23, 23, 23, 0.06); color: #4a4a46; }
.eyebrow .bar { display: inline-block; width: 22px; height: 1px; margin-right: 10px;
  vertical-align: middle; background: currentColor; opacity: 0.5; }

/* volver a todos los proyectos (case studies) */
.cs-back-row { margin-top: 8px; margin-bottom: 28px; }
.cs-back {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 700;
  color: var(--cream-accent);
  padding: 10px 18px; border-radius: 999px;
  border: 1px solid var(--line);
  transition: gap 220ms var(--ease-cinematic), color 220ms ease, border-color 220ms ease, background 220ms ease;
}
.cs-back:hover { gap: 14px; color: var(--cream); border-color: var(--cream); }
.cs-back .arw { transition: transform 300ms var(--ease-cinematic); }
.cs-back:hover .arw { transform: translateX(-3px); }
body.light-page .cs-back { color: #4a4a46; border-color: rgba(23,23,23,0.20); }
body.light-page .cs-back:hover { color: #171717; border-color: #171717; background: rgba(23,23,23,0.04); }

/* fila del título con el botón de volver al lado */
.cs-titlerow { display: flex; align-items: baseline; justify-content: flex-start; gap: 16px; }
.cs-titlerow h1 { flex: 1 1 auto; }
.cs-titlerow .cs-back-icon { align-self: center; }
@media (max-width: 720px) {
  .cs-titlerow { flex-direction: column; align-items: flex-start; gap: 16px; }
  .cs-titlerow .cs-back-icon { align-self: flex-start; order: -1; }
}

/* botón icónico de volver, junto al título */
.cs-back-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; flex: 0 0 auto;
  border-radius: 999px; border: 1px solid var(--line);
  color: var(--cream-accent);
  transition: color 220ms ease, border-color 220ms ease, background 220ms ease, transform 300ms var(--ease-cinematic);
}
.cs-back-icon svg { width: 18px; height: 18px; }
.cs-back-icon:hover { color: var(--cream); border-color: var(--cream); transform: translateX(-3px); }
body.light-page .cs-back-icon { color: #4a4a46; border-color: rgba(23,23,23,0.20); }
body.light-page .cs-back-icon:hover { color: #171717; border-color: #171717; background: rgba(23,23,23,0.04); }

/* ============================================================
   SEO · utilidades y módulos nuevos
   Añadido por la optimización de buscadores. Los módulos usan los
   mismos tokens que el resto, así heredan el tema claro/oscuro.
   ============================================================ */

/* Texto que ven los lectores de pantalla y los buscadores, no el ojo.
   Lo usa el H1 de la home, que visualmente es sólo la palabra «luis». */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap; border: 0;
}
.hero-h1 { margin: 0; font: inherit; }

/* Encabezados añadidos sólo por jerarquía: no deben cambiar de aspecto */
.exp-row .role .role-h { font: inherit; margin: 0; }
.skill-card h3.group { margin-top: 0; font-weight: inherit; }

/* Etiqueta de sección en los casos de estudio (métricas y cita) */
.cs-minih {
  margin: 0; font-family: var(--font-sans); font-size: 11px; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; color: var(--gray-500);
}
.cs-results { padding-top: 70px; }
.cs-results .cs-stats { padding-top: 18px; }
.cs-quote .cs-minih { text-align: center; margin-bottom: 26px; }

/* ---- TL;DR: respuesta directa, CTA y cinco puntos clave ---- */
.seo-brief { background: var(--black); color: var(--cream); padding: 56px 0 64px; }
.seo-brief__lead {
  margin: 0; max-width: 70ch; font-size: clamp(17px, 1.6vw, 21px);
  line-height: 1.5; color: var(--cream); text-wrap: pretty;
}
.seo-brief__cta { margin: 20px 0 0; }
.seo-brief__cta a {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
  font-size: 15px; font-weight: 700; color: var(--cream);
  border-bottom: 1px solid var(--line); padding-bottom: 3px;
  transition: border-color .25s var(--ease-card);
}
.seo-brief__cta a:hover { border-bottom-color: currentColor; }
.seo-brief__h2 {
  margin: 36px 0 0; font-size: 11px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gray-500);
}
.seo-brief__list {
  margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 10px;
  max-width: 82ch;
}
.seo-brief__list li {
  position: relative; padding-left: 22px; font-size: 16px; line-height: 1.5;
  color: var(--cream-accent); text-wrap: pretty;
}
.seo-brief__list li::before {
  content: ""; position: absolute; left: 0; top: .66em; width: 10px; height: 1px;
  background: currentColor; opacity: .55;
}

/* ---- Hub de clusters temáticos (página de Work) ---- */
.seo-clusters { background: var(--black); color: var(--cream); }
.seo-clusters > .work-rail { padding: 72px 24px 80px; }
@media (min-width: 768px) { .seo-clusters > .work-rail { padding: 88px 40px 96px; } }
.seo-clusters h2 {
  margin: 0; font-family: 'Scotch Display Condensed', Georgia, serif;
  font-weight: 600; font-size: clamp(28px, 3.6vw, 46px); line-height: 1.05;
  letter-spacing: -0.02em; color: var(--cream);
}
.seo-clusters__lead {
  margin: 14px 0 0; max-width: 60ch; font-size: 17px; line-height: 1.5;
  color: var(--gray-400); text-wrap: pretty;
}
.seo-clusters__grid {
  margin-top: 40px; display: grid; gap: 28px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.seo-cluster { scroll-margin-top: 110px; }
.seo-cluster h3 {
  margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gray-500);
}
.seo-cluster > p {
  margin: 10px 0 0; font-size: 15px; line-height: 1.5; color: var(--cream-accent);
  text-wrap: pretty;
}
.seo-cluster ul { margin: 14px 0 0; padding: 0; list-style: none; }
.seo-cluster li + li { margin-top: 8px; }
.seo-cluster a, .seo-related__list a {
  font-size: 17px; font-weight: 700; color: var(--cream); text-decoration: none;
  border-bottom: 1px solid transparent; transition: border-color .25s var(--ease-card);
}
.seo-cluster a:hover, .seo-related__list a:hover { border-bottom-color: currentColor; }
.seo-nda {
  margin-left: 6px; font-size: 10px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--gray-500); white-space: nowrap;
}

/* ---- Trabajo relacionado (radios del cluster, en cada caso) ---- */
.seo-related { background: var(--black); color: var(--cream); padding: 64px 0 72px; }
.seo-related h2 {
  margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gray-500);
}
.seo-related h3 {
  margin: 10px 0 0; font-family: 'Scotch Display Condensed', Georgia, serif;
  font-weight: 600; font-size: clamp(24px, 3vw, 38px); line-height: 1.05;
  letter-spacing: -0.02em; color: var(--cream);
}
.seo-related__list {
  margin: 22px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap;
  gap: 10px 28px;
}

/* ---- los módulos nuevos en las páginas de tema claro ---- */
body.light-page .seo-brief,
body.light-page .seo-clusters,
body.light-page .seo-related,
body.light-page .cs-results {
  --black: #fafafa;
  --about-card: #f1f0ec;
  --feature-card: #ffffff;
  --cream: #171717;
  --cream-accent: #4a4a46;
  --gray-400: #737373;
  --gray-500: #6b6b67;
  --line: rgba(23, 23, 23, 0.12);
  background: #fafafa;
  color: #171717;
}

/* Encabezados promovidos sólo por jerarquía: conservan el aspecto anterior */
.features-head h2.l1 { margin: 0; font: inherit; color: var(--cream); }
.fcard .ftitle .ftitle-h { margin: 0; font: inherit; }
.cc-btn .cc-text h3.cc-label { margin: 0; font-size: 15px; font-weight: 700; }

/* ---- FAQ del pie ---- */
.foot-faq { margin-top: 64px; border-top: 1px solid var(--line); padding-top: 48px; }
.foot-faq__head .eyebrow { color: var(--gray-500); }
.foot-faq__head h2 {
  margin: 10px 0 0; font-family: 'Scotch Display Condensed', Georgia, serif;
  font-weight: 600; font-size: clamp(26px, 3.2vw, 40px); line-height: 1.05;
  letter-spacing: -0.02em; color: var(--cream);
}
.foot-faq__list { margin-top: 28px; max-width: 900px; }
.faq-item { border-top: 1px solid var(--line); }
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-item > summary {
  list-style: none; cursor: pointer; padding: 18px 34px 18px 0; position: relative;
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary h3 {
  margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -0.01em;
  line-height: 1.35; color: var(--cream); text-wrap: pretty;
}
/* el signo + gira a × al abrir */
.faq-item > summary::after {
  content: "+"; position: absolute; right: 2px; top: 16px;
  font-size: 20px; line-height: 1; color: var(--gray-500);
  transition: transform .3s var(--ease-card);
}
.faq-item[open] > summary::after { transform: rotate(45deg); }
.faq-item > summary:focus-visible { outline: 2px solid var(--cream-accent); outline-offset: 2px; border-radius: 4px; }
.faq-item > p {
  margin: 0; padding: 0 44px 22px 0; max-width: 74ch;
  font-size: 16px; line-height: 1.55; color: var(--cream-accent); text-wrap: pretty;
}
@media (prefers-reduced-motion: reduce) {
  .faq-item > summary::after { transition: none; }
}

/* ---- botón de compartir ---- */
.foot-share { margin-top: 36px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.foot-share__btn {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer;
  font-family: var(--font-sans); font-size: 13px; font-weight: 700;
  letter-spacing: .02em; color: var(--cream);
  background: transparent; border: 1px solid var(--line);
  border-radius: 999px; padding: 9px 16px;
  transition: border-color .25s var(--ease-card), transform .25s var(--ease-card);
}
.foot-share__btn:hover { border-color: currentColor; transform: translateY(-1px); }
.foot-share__btn:active { transform: scale(.97); }
.foot-share__btn:focus-visible { outline: 2px solid var(--cream-accent); outline-offset: 2px; }
.foot-share__btn svg { width: 15px; height: 15px; flex-shrink: 0; }
.foot-share__msg { font-size: 12px; color: var(--gray-400); }
.foot-share__msg.is-bad { color: #d08b84; }
@media (prefers-reduced-motion: reduce) {
  .foot-share__btn { transition: none; }
  .foot-share__btn:hover, .foot-share__btn:active { transform: none; }
}

/* la sección de FAQ propia de Contacto, que no tiene footer */
.foot--faqonly { padding-top: 0; padding-bottom: 60px; }
.foot--faqonly .foot-faq { margin-top: 0; }

/* ---- FAQ y compartir en las páginas de tema claro ----
   .foot--solo se aclara con un color explícito, pero los tokens de texto
   siguen siendo los oscuros, así que aquí se redeclaran. */
body.light-page .foot-faq,
body.light-page .foot-share {
  --cream: #171717;
  --cream-accent: #4a4a46;
  --gray-400: #737373;
  --gray-500: #6b6b67;
  --line: rgba(23, 23, 23, 0.14);
}
body.light-page .foot-share__msg.is-bad { color: #b3261e; }
/* «Next project» pasa a H2 para que el nombre del proyecto siguiente (H3) no
   quede colgando por encima de su propio nivel. El aspecto no cambia. */
/* Sólo margen y peso: el tamaño y las mayúsculas los pone .cs-next .k, y un
   font:inherit aquí ganaría por especificidad y las borraría. */
.cs-next h2.k { margin: 0; font-weight: inherit; }

/* ============================================================
   NDA · diálogo de contraseña
   Estaba en el <style> de projects.html, pero la puerta ahora vive en
   nda.js y funciona en todas las páginas, así que el estilo también
   tiene que estar disponible en todas.
   ============================================================ */
  /* ============================================================
     Popup NDA (Dryft): se abre al hacer clic en la tarjeta, con
     blur sobre el fondo. OJO: es client-side, NO es seguridad real
     (el contenido y la contraseña viven en el cliente); funciona
     como disuasorio y aviso de confidencialidad.
     ============================================================ */
  .nda-overlay { position: fixed; inset: 0; z-index: 90; display: flex; align-items: center; justify-content: center; padding: 24px;
    background: rgba(10, 10, 11, 0.55);
    -webkit-backdrop-filter: blur(14px) saturate(140%); backdrop-filter: blur(14px) saturate(140%);
    opacity: 0; visibility: hidden; transition: opacity 320ms cubic-bezier(0.16,1,0.3,1), visibility 320ms; }
  .nda-overlay.is-open { opacity: 1; visibility: visible; }
  .nda-card { width: 100%; max-width: 420px; text-align: center; color: #171717; background: #ffffff;
    border: 1px solid rgba(23,23,23,0.10); border-radius: 24px; padding: 40px 32px;
    box-shadow: 0 40px 90px -24px rgba(0,0,0,0.45);
    transform: translateY(14px) scale(0.98); transition: transform 320ms cubic-bezier(0.16,1,0.3,1); }
  .nda-overlay.is-open .nda-card { transform: none; }
  .nda-ic { display: inline-flex; width: 48px; height: 48px; align-items: center; justify-content: center; border-radius: 14px; background: #f2f1ed; color: #171717; margin-bottom: 20px; }
  .nda-ic svg { width: 24px; height: 24px; }
  .nda-card h2 { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.25; color: #171717; }
  .nda-card > p { margin-top: 12px; color: #737373; font-size: 15px; line-height: 1.5; text-wrap: pretty; }
  .nda-form { margin-top: 24px; display: flex; flex-direction: column; gap: 12px; }
  .nda-form input { font-family: var(--font-sans); font-size: 15px; text-align: center; color: #171717; background: #fafafa;
    border: 1px solid rgba(23,23,23,0.14); border-radius: 12px; padding: 13px 15px; transition: border-color 200ms ease, box-shadow 200ms ease; }
  .nda-form input::placeholder { color: #a3a3a3; letter-spacing: normal; -webkit-text-security: none; text-security: none; }
  /* enmascarado por CSS en vez de type="password": evita el gestor de contraseñas */
  .nda-masked { -webkit-text-security: disc; text-security: disc; letter-spacing: 0.18em; }
  .nda-form input:focus { outline: none; border-color: #171717; box-shadow: 0 0 0 3px rgba(23,23,23,0.07); }
  .nda-form button { font-family: var(--font-sans); font-weight: 700; font-size: 15px; cursor: pointer; color: #fafafa; background: #171717;
    border: 0; border-radius: 999px; height: 48px; transition: transform 200ms cubic-bezier(0.34,1.56,0.64,1); }
  .nda-form button:hover { transform: translateY(-2px); }
  .nda-form button:active { transform: scale(0.97); }
  .nda-error { min-height: 1em; margin: 2px 0 0; font-size: 13px; color: #b3261e; }
  /* estado inválido con el lenguaje visual del sitio (sustituye al tooltip nativo) */
  .nda-form input.is-invalid { border-color: #b3261e; box-shadow: 0 0 0 3px rgba(179,38,30,0.10); animation: nda-shake 400ms cubic-bezier(0.36,0.07,0.19,0.97); }
  @keyframes nda-shake { 10%,90%{transform:translateX(-1px)} 20%,80%{transform:translateX(2px)} 30%,50%,70%{transform:translateX(-4px)} 40%,60%{transform:translateX(4px)} }
  @media (prefers-reduced-motion: reduce) { .nda-form input.is-invalid { animation: none; } }
  .nda-close { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
    color: #737373; background: transparent; border: 0; border-radius: 8px; cursor: pointer; transition: color 200ms ease; }
  .nda-close:hover { color: #171717; }
  .nda-close svg { width: 18px; height: 18px; }
  .nda-card { position: relative; }
  @media (prefers-reduced-motion: reduce) {
    .nda-overlay, .nda-card { transition: none; }
  }

/* El nombre del proyecto que se va a desbloquear, para que quede claro */
.nda-project { margin-top: 6px; font-size: 12px; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; color: #171717; }
.nda-project:empty { display: none; }

/* ---- TL;DR plegado ----
   El contenido de un <details> cerrado sigue en el HTML y Google lo indexa, así
   que plegarlo no cuesta posicionamiento. La respuesta y el CTA quedan fuera,
   visibles: son la parte que responde a la intención de búsqueda. */
.seo-brief__details { margin-top: 30px; border-top: 1px solid var(--line); }
.seo-brief__details > summary {
  list-style: none; cursor: pointer; padding: 16px 30px 16px 0; position: relative;
  display: block; width: fit-content;
}
.seo-brief__details > summary::-webkit-details-marker { display: none; }
.seo-brief__details > summary .seo-brief__h2 { margin: 0; }
.seo-brief__details > summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; margin-top: -0.5em;
  font-size: 17px; line-height: 1; color: var(--gray-500);
  transition: transform .3s var(--ease-card);
}
.seo-brief__details[open] > summary::after { transform: rotate(45deg); }
.seo-brief__details > summary:hover .seo-brief__h2 { color: var(--cream); }
.seo-brief__details > summary:focus-visible {
  outline: 2px solid var(--cream-accent); outline-offset: 3px; border-radius: 4px;
}
.seo-brief__details .seo-brief__list { margin: 2px 0 26px; }
@media (prefers-reduced-motion: reduce) {
  .seo-brief__details > summary::after { transition: none; }
}

/* ============================================================
   LEGAL · privacidad y términos
   Los dos idiomas viven en la página y se alternan según html[lang],
   que es el atributo que escribe applyLang() en prisma.js. Un documento
   legal es demasiado largo para el diccionario de claves, y así el texto
   queda legible en el código fuente para quien tenga que revisarlo.
   ============================================================ */
[data-lang-block] { display: none; }
html[lang="en"] [data-lang-block="en"],
html[lang="es"] [data-lang-block="es"] { display: block; }
/* Sin JS el atributo lang del documento ya es "en", así que se ve el inglés
   y nunca aparecen los dos idiomas a la vez. */

.legal { background: var(--black); color: var(--cream); padding: 10px 0 100px; }
body.light-page .legal {
  --black: #fafafa;
  --cream: #171717;
  --cream-accent: #4a4a46;
  --gray-400: #737373;
  --gray-500: #6b6b67;
  --line: rgba(23, 23, 23, 0.12);
  background: #fafafa;
  color: #171717;
}
.legal-doc { max-width: 76ch; }
.legal-updated {
  margin: 0 0 44px; font-size: 13px; letter-spacing: .02em; color: var(--gray-500);
}
.legal-doc h2 {
  margin: 52px 0 14px; font-family: 'Scotch Display Condensed', Georgia, serif;
  font-weight: 600; font-size: clamp(24px, 2.8vw, 34px); line-height: 1.1;
  letter-spacing: -0.02em; color: var(--cream);
}
.legal-doc h2:first-of-type { margin-top: 0; }
.legal-doc h3 {
  margin: 30px 0 10px; font-size: 16px; font-weight: 700; letter-spacing: -0.01em;
  color: var(--cream);
}
.legal-doc p {
  margin: 0 0 16px; font-size: 16px; line-height: 1.62; color: var(--cream-accent);
  text-wrap: pretty;
}
.legal-doc a { color: var(--cream); text-decoration: underline; text-underline-offset: 3px; }
.legal-doc a:hover { text-decoration-thickness: 2px; }
.legal-doc strong { color: var(--cream); font-weight: 700; }
.legal-doc em { font-style: italic; }
.legal-doc code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .88em;
  padding: 2px 5px; border-radius: 5px; background: var(--feature-card);
  color: var(--cream);
}
body.light-page .legal-doc code { background: rgba(23, 23, 23, 0.06); }
.legal-doc ul { margin: 0 0 16px; padding: 0; list-style: none; }
.legal-doc ul li {
  position: relative; padding-left: 22px; margin-bottom: 9px; font-size: 16px;
  line-height: 1.6; color: var(--cream-accent); text-wrap: pretty;
}
.legal-doc ul li::before {
  content: ""; position: absolute; left: 0; top: .72em; width: 10px; height: 1px;
  background: currentColor; opacity: .55;
}
/* la lista de resumen de cada documento, algo más marcada */
.legal-tldr { border-left: 2px solid var(--line); padding-left: 22px !important; }
.legal-tldr li { padding-left: 0 !important; }
.legal-tldr li::before { display: none; }

.legal-table {
  width: 100%; margin: 6px 0 26px; border-collapse: collapse; font-size: 15px;
  text-align: left;
}
.legal-table th, .legal-table td {
  padding: 11px 14px 11px 0; border-bottom: 1px solid var(--line);
  vertical-align: top; line-height: 1.5;
}
.legal-table th {
  font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gray-500); white-space: nowrap;
}
.legal-table td { color: var(--cream-accent); }
.legal-table td:first-child { color: var(--cream); padding-right: 20px; }
@media (max-width: 640px) {
  .legal-table, .legal-table tbody, .legal-table tr, .legal-table td { display: block; width: 100%; }
  .legal-table thead { display: none; }
  .legal-table tr { border-bottom: 1px solid var(--line); padding: 12px 0; }
  .legal-table td { border: 0; padding: 2px 0; }
  .legal-table td:first-child { font-weight: 700; }
}

/* enlaces legales en la línea de cierre del pie */
.baseline-legal { display: flex; gap: 8px; align-items: center; }
.baseline-legal a { color: inherit; text-decoration: none; border-bottom: 1px solid transparent; }
.baseline-legal a:hover { border-bottom-color: currentColor; }
/* Envoltorio neutro: un elemento con display propio como hijo directo de
   <details> puede ignorar el ocultado del navegador al estar cerrado. */
.seo-brief__body { display: block; }

/* ============================================================
   CONSENTIMIENTO · aviso de cookies
   Barra fina abajo, no un modal: no tapa el contenido ni se interpone
   en lo primero que ve alguien que entra a juzgar el diseño.
   Los dos botones son idénticos a propósito. Hacer «Aceptar» más
   llamativo que «Rechazar» es un patrón oscuro y anula el consentimiento.
   ============================================================ */
.consent {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 95;
  background: rgba(16, 16, 16, 0.92);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  border-top: 1px solid rgba(225, 224, 204, 0.14);
  color: var(--cream);
  transform: translateY(100%);
  transition: transform .42s var(--ease-cinematic);
}
.consent.is-open { transform: none; }
.consent__inner {
  max-width: var(--wrap); margin: 0 auto; padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px 28px; flex-wrap: wrap;
}
.consent__text {
  margin: 0; flex: 1 1 380px; min-width: 0;
  font-size: 13.5px; line-height: 1.5; color: rgba(225, 224, 204, 0.82);
  text-wrap: pretty;
}
.consent__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
/* mismo tamaño, mismo color, mismo peso: ninguno destaca sobre el otro */
.consent__btn {
  font-family: var(--font-sans); font-size: 13px; font-weight: 700;
  letter-spacing: .01em; cursor: pointer;
  color: #171717; background: var(--cream-accent);
  border: 1px solid var(--cream-accent); border-radius: 999px;
  padding: 9px 20px; min-width: 104px;
  transition: transform .22s var(--ease-card), opacity .22s ease;
}
.consent__btn:hover { transform: translateY(-1px); opacity: .9; }
.consent__btn:active { transform: scale(.97); }
.consent__btn:focus-visible { outline: 2px solid #fafafa; outline-offset: 2px; }
.consent__link {
  font-size: 12.5px; color: rgba(225, 224, 204, 0.6); text-decoration: none;
  border-bottom: 1px solid transparent; padding-bottom: 1px; white-space: nowrap;
}
.consent__link:hover { color: var(--cream); border-bottom-color: currentColor; }
@media (max-width: 560px) {
  .consent__inner { padding: 14px 18px; }
  .consent__actions { width: 100%; }
  .consent__btn { flex: 1 1 0; min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .consent { transition: none; }
  .consent__btn { transition: none; }
  .consent__btn:hover, .consent__btn:active { transform: none; }
}

/* el enlace para cambiar de opinión, en la línea de cierre */
.baseline-cookies {
  font-family: var(--font-sans); font-size: inherit; color: inherit;
  background: none; border: 0; padding: 0; cursor: pointer;
  border-bottom: 1px solid transparent;
}
.baseline-cookies:hover { border-bottom-color: currentColor; }
.baseline-cookies:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }

/* el aviso de privacidad junto al botón de enviar */
.form-note a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
