/* ==========================================================================
   Madera Viva — sitio con movimiento
   Dos modos:
   · base (sin JS o con "reducir movimiento"): todo visible, en flujo normal.
   · html.motion (lo activa js/site.js): escenas fijas guiadas por el scroll.
   ========================================================================== */

:root {
  --nogal: #8B6549;
  --nogal-osc: #6E4F38;
  --arena: #D5C1A4;
  --marfil: #F0EAE0;
  --marfil-claro: #F7F3EC;
  --carbon: #292724;
  --tinta: #1D1B19;
  --noche: #151311;
  --texto: #4A4540;
  --muted: #6B635B;
  --linea: #E0D3C0;
  --luz: #FFD9A0;
  --luz-clara: #FFF1DA;
  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans: 'Montserrat', Arial, Helvetica, sans-serif;
  --pad: clamp(20px, 4.2vw, 64px);
  --ease: cubic-bezier(.16, 1, .3, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
html:not(.motion) { scroll-behavior: smooth; }
body {
  background: var(--noche);
  color: var(--texto);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video, canvas { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--nogal); color: var(--marfil-claro); }

/* Lenis */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

.wrap { width: 100%; max-width: 1360px; margin: 0 auto; padding: 0 var(--pad); }

/* ---------- Tipografía compartida ---------- */
.eyebrow {
  font-family: var(--sans); font-size: 11px; font-weight: 500;
  letter-spacing: .32em; text-transform: uppercase; color: var(--nogal);
}
.display {
  font-family: var(--serif); font-weight: 500; color: inherit;
  font-size: clamp(38px, 6vw, 92px); line-height: 1.02; letter-spacing: -.012em;
  text-wrap: balance;
}
.display em { font-style: italic; color: var(--nogal); }
.lead { font-size: clamp(16px, 1.25vw, 18.5px); line-height: 1.7; max-width: 56ch; }
.sec-head { display: grid; gap: 22px; max-width: 980px; }
.sec-head.center { margin: 0 auto; text-align: center; justify-items: center; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 56px; padding: 7px 7px 7px 26px; border-radius: 999px;
  border: 1px solid transparent; cursor: pointer; text-decoration: none;
  font-family: var(--sans); font-size: 11.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  transition: background .3s ease, color .3s ease, border-color .3s ease, transform .5s var(--ease);
}
.btn .ico {
  width: 42px; height: 42px; border-radius: 50%; flex: 0 0 42px;
  display: grid; place-items: center; transition: transform .6s var(--ease);
}
.btn .ico svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.btn:hover .ico { transform: rotate(-45deg); }
.btn-luz { background: var(--arena); color: var(--carbon); }
.btn-luz .ico { background: var(--carbon); color: var(--arena); }
.btn-luz:hover { background: var(--luz-clara); }
.btn-linea { padding: 7px 26px; border-color: rgba(240, 234, 224, .38); color: var(--marfil); }
.btn-linea:hover { border-color: var(--marfil); background: rgba(240, 234, 224, .08); }
.btn-block { width: 100%; }
.btn:disabled { opacity: .6; cursor: wait; }

/* ---------- Capas fijas ---------- */
.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.led-progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 80; pointer-events: none; }
.led-progress i {
  display: block; height: 100%; transform: scaleX(0); transform-origin: left center;
  background: linear-gradient(90deg, rgba(255, 217, 160, 0), var(--luz) 60%, var(--luz-clara));
  box-shadow: 0 0 12px rgba(255, 205, 140, .8);
}

@keyframes breathe { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }

/* ==========================================================================
   NAVEGACIÓN
   ========================================================================== */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 70; transition: transform .6s var(--ease); }
.nav::before {
  content: ''; position: absolute; inset: 0; opacity: 0; transition: opacity .4s ease;
  background: rgba(21, 19, 17, .74); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(213, 193, 164, .12);
}
.nav.scrolled::before { opacity: 1; }
.nav.is-hidden { transform: translateY(-110%); }
.nav-in { position: relative; display: flex; align-items: center; justify-content: space-between; height: 76px; padding: 0 var(--pad); }
.nav-logo img { height: 42px; width: auto; }
.nav-links { display: flex; align-items: center; gap: clamp(18px, 2.6vw, 38px); list-style: none; }
.nav-links a {
  position: relative; text-decoration: none; font-size: 11.5px; font-weight: 500;
  letter-spacing: .2em; text-transform: uppercase; color: var(--marfil); transition: color .25s ease;
}
.nav-links a:not(.nav-cta)::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -7px; height: 1px; background: var(--luz);
  transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease);
}
.nav-links a:not(.nav-cta):hover::after { transform: scaleX(1); transform-origin: left; }
.nav-cta { border: 1px solid rgba(240, 234, 224, .45); padding: 12px 20px; border-radius: 999px; transition: background .3s ease, color .3s ease, border-color .3s ease; }
.nav-cta:hover { background: var(--arena); border-color: var(--arena); color: var(--carbon) !important; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; width: 44px; height: 44px; position: relative; z-index: 2; }
.nav-toggle span { position: absolute; left: 9px; right: 9px; height: 1.5px; background: var(--marfil); transition: transform .5s var(--ease), top .5s var(--ease); }
.nav-toggle span:nth-child(1) { top: 17px; }
.nav-toggle span:nth-child(2) { top: 26px; }
.nav.open .nav-toggle span:nth-child(1) { top: 21.5px; transform: rotate(45deg); }
.nav.open .nav-toggle span:nth-child(2) { top: 21.5px; transform: rotate(-45deg); }

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .nav-logo { position: relative; z-index: 2; }
  .nav-links {
    position: fixed; inset: 0; height: 100vh; height: 100dvh; z-index: 1;
    flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px;
    padding: 90px var(--pad) 40px; background: var(--noche);
    clip-path: inset(0 0 100% 0); visibility: hidden;
    transition: clip-path .8s var(--ease), visibility 0s .8s;
  }
  .nav.open .nav-links { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path .8s var(--ease), visibility 0s; }
  .nav-links li { overflow: hidden; }
  .nav-links a {
    display: block; font-family: var(--serif); font-size: clamp(38px, 11vw, 60px); font-weight: 500;
    letter-spacing: -.01em; text-transform: none; line-height: 1.22;
    transform: translateY(110%); transition: transform .9s var(--ease);
  }
  .nav.open .nav-links a { transform: none; }
  .nav.open .nav-links li:nth-child(2) a { transition-delay: .05s; }
  .nav.open .nav-links li:nth-child(3) a { transition-delay: .1s; }
  .nav.open .nav-links li:nth-child(4) a { transition-delay: .15s; }
  .nav.open .nav-links li:nth-child(5) a { transition-delay: .2s; }
  .nav.open .nav-links li:nth-child(6) a { transition-delay: .25s; }
  .nav-links a:not(.nav-cta)::after { display: none; }
  .nav-cta { border: 0; padding: 0; border-radius: 0; font-style: italic; color: var(--arena) !important; }
  .nav-cta:hover { background: none; }
  .nav.open::before { opacity: 0; }
}

/* ==========================================================================
   HERO — video de fondo; al bajar se funde en la pantalla blanca
   ========================================================================== */
.hero { position: relative; background: var(--noche); color: var(--marfil); }
.hero-stage { position: relative; }
.hero-top { position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden; }
.hero-media {
  position: absolute; inset: 0; transform-origin: 50% 60%;
  background: #0f0d0b url('../img/hero/poster.jpg') center / cover;
}
.hero-video { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.4s ease; }
.hero-video.is-playing { opacity: 1; }
.hero-scrim {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, rgba(15, 13, 11, .96) 0%, rgba(15, 13, 11, .88) 24%, rgba(15, 13, 11, .52) 42%, rgba(15, 13, 11, .12) 62%, rgba(15, 13, 11, .04) 80%),
    linear-gradient(to bottom, rgba(15, 13, 11, .6), rgba(15, 13, 11, 0) 22%),
    linear-gradient(to right, rgba(15, 13, 11, .5), rgba(15, 13, 11, 0) 58%);
}
.hero-ui {
  position: relative; z-index: 2; min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 120px var(--pad) clamp(26px, 4.5vh, 52px);
}
.hero-behind { background: var(--marfil-claro); color: var(--carbon); padding: clamp(80px, 13vh, 150px) var(--pad) 0; }
.behind-in { max-width: 1180px; margin: 0 auto; display: grid; gap: 26px; justify-items: center; text-align: center; }
.behind-in .display { font-size: clamp(38px, 6.4vw, 104px); }
@media (max-width: 760px) { .hero-media { background-image: url('../img/hero/poster-v.jpg'); } }

.hero-copy { position: relative; width: 100%; }
.hero-eyebrow { color: var(--arena); }
/* Titular contenido: se mide por el ancho y por el alto para quedarse en la franja de abajo,
   lejos de las letras grandes de la película que van al centro */
.hero-title {
  font-family: var(--serif); font-weight: 500; color: var(--marfil);
  font-size: clamp(30px, min(3.5vw, 5.6vh), 58px); line-height: 1.04; letter-spacing: -.01em;
  margin: .3em 0 .5em; text-shadow: 0 2px 30px rgba(0, 0, 0, .55);
}
.hero-title .ln { display: block; overflow: hidden; padding: .05em .06em .16em; margin: -.05em -.06em -.16em; }
.hero-title.is-in .ln { overflow: visible; }
.hero-title .ln-in { display: inline-block; position: relative; will-change: transform; }
.ln-luz .ln-in { font-style: italic; color: var(--luz-clara); text-shadow: 0 0 22px rgba(255, 205, 140, .7), 0 0 70px rgba(255, 176, 96, .45); }
.hero-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 26px 56px; flex-wrap: wrap; }
.hero-sub { max-width: 440px; color: rgba(240, 234, 224, .86); font-size: clamp(15px, 1.2vw, 17.5px); }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Entrada del titular: oculto hasta que el script lo anima (o 2.5 s como respaldo) */
html.js:not(.ready) .hero-title .ln-in { transform: translateY(118%); }
html.js:not(.ready) .hero-eyebrow, html.js:not(.ready) .hero-foot { opacity: 0; }

/* --- con movimiento: el video queda fijo y la pantalla blanca entra al bajar --- */
html.motion .hero { height: 190vh; }
html.motion .hero-stage { position: sticky; top: 0; height: 100vh; height: 100lvh; overflow: hidden; }
html.motion .hero-top { position: absolute; inset: 0; min-height: 0; }
html.motion .hero-ui { position: absolute; inset: 0 0 auto 0; height: 100vh; height: 100svh; min-height: 0; }
html.motion .hero-behind { position: absolute; inset: 0; z-index: 5; padding: 0 var(--pad); display: grid; place-items: center; opacity: 0; pointer-events: none; }
html.motion .behind-in { margin-bottom: calc(100lvh - 100svh); }

@media (max-width: 760px) {
  .hero-ui { padding-top: 100px; padding-bottom: 92px; }
  .hero-title { font-size: clamp(30px, 8.8vw, 40px); line-height: 1.06; }
  .hero-actions { width: 100%; }
  .hero-actions .btn { flex: 1 1 100%; }
  .hero-actions .btn-linea { justify-content: center; min-height: 50px; }
}

/* ==========================================================================
   ESENCIA
   ========================================================================== */
.esencia { position: relative; background: var(--marfil-claro); color: var(--carbon); padding: clamp(70px, 11vh, 130px) 0 clamp(100px, 15vh, 190px); }
.statement {
  font-family: var(--serif); font-weight: 500; color: var(--carbon);
  font-size: clamp(30px, 4.7vw, 74px); line-height: 1.12; letter-spacing: -.012em;
  max-width: 1180px; margin: 0 auto; text-align: center; text-wrap: balance;
}
.statement .w { display: inline-block; }
.pill {
  display: inline-block; width: 1.9em; height: .8em; border-radius: 999px;
  background-size: cover; background-position: center; vertical-align: -.05em; margin: 0 .06em;
  box-shadow: inset 0 0 0 1px rgba(41, 39, 36, .08);
}
.esencia-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(40px, 7vw, 120px); align-items: center; margin-top: clamp(80px, 13vh, 170px); }
.esencia-fotos { position: relative; padding: 0 0 18% 0; }
.foto { overflow: hidden; border-radius: 6px; background: var(--marfil); }
.foto img { width: 100%; height: 116%; object-fit: cover; margin-top: -8%; }
.foto-a { width: 66%; aspect-ratio: 4 / 5; }
.foto-b { position: absolute; right: 0; bottom: 0; width: 56%; aspect-ratio: 4 / 3; box-shadow: 0 30px 70px rgba(41, 39, 36, .28); }
.esencia-texto .lead { color: var(--texto); font-size: clamp(17px, 1.5vw, 21px); }
.valores { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; list-style: none; }
.valores li {
  font-size: 10.5px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--nogal);
  border: 1px solid var(--arena); border-radius: 999px; padding: 9px 16px;
}
.cita {
  margin-top: 46px; padding-left: 28px; border-left: 2px solid var(--nogal);
  font-family: var(--serif); font-style: italic; font-size: clamp(24px, 2.6vw, 36px); line-height: 1.3; color: var(--carbon);
}
@media (max-width: 860px) {
  .esencia-grid { grid-template-columns: 1fr; }
  .esencia-fotos { padding-bottom: 22%; }
}

/* ==========================================================================
   FILAS DE PALABRAS
   ========================================================================== */
.marquee { background: var(--noche); padding: clamp(46px, 9vh, 110px) 0 0; overflow: hidden; }
.mq-row { overflow: hidden; white-space: nowrap; }
.mq-track {
  display: inline-flex; align-items: center; gap: .42em; padding-right: .42em; will-change: transform;
  font-family: var(--serif); font-weight: 500; font-style: italic;
  font-size: clamp(56px, 10.5vw, 168px); line-height: 1.16;
}
.mq-track span { color: transparent; -webkit-text-stroke: 1px rgba(213, 193, 164, .5); padding: 0 .04em; }
.mq-track span.tex {
  -webkit-text-stroke: 0; font-style: normal;
  background: url('../img/tex/burl.webp') center / 900px auto; -webkit-background-clip: text; background-clip: text; color: transparent;
}
.mq-track i { flex: 0 0 auto; width: .78em; height: .3em; border-radius: 999px; background: var(--nogal); opacity: .8; }

/* ==========================================================================
   SERVICES — full-screen carousel
   ========================================================================== */
.tour { background: var(--noche); color: var(--marfil); }
.tour-intro { display: grid; gap: 24px; padding-top: clamp(70px, 11vh, 140px); padding-bottom: clamp(50px, 8vh, 100px); }
.tour-intro .eyebrow { color: var(--arena); }
.tour-intro .lead { color: rgba(240, 234, 224, .76); }
.tour-track { position: relative; }
.tour-stage { position: relative; }

.stops { display: grid; gap: 10px; }
.stop { position: relative; height: 84vh; height: 84svh; overflow: hidden; display: flex; align-items: flex-end; }
.stop-media { position: absolute; inset: 0; overflow: hidden; isolation: isolate; }
.stop-inner { position: absolute; inset: 0; transform-origin: 50% 55%; }
.stop-inner img, .stop-inner video, .stop-inner canvas, .stop-inner picture { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.stop-inner canvas.seq { display: none; }
/* Sombra para leer las letras sobre cualquier foto: fuerte abajo a la izquierda */
.stop-media::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to top, rgba(10, 8, 7, .96) 0%, rgba(10, 8, 7, .84) 18%, rgba(10, 8, 7, .5) 40%, rgba(10, 8, 7, .12) 60%, rgba(10, 8, 7, 0) 72%),
    linear-gradient(to right, rgba(10, 8, 7, .66) 0%, rgba(10, 8, 7, .26) 40%, rgba(10, 8, 7, 0) 64%),
    linear-gradient(to bottom, rgba(10, 8, 7, .62), rgba(10, 8, 7, 0) 24%);
}
.stop-shade { position: absolute; inset: 0; background: #0c0a09; opacity: 0; pointer-events: none; z-index: 1; }
.stop-copy { position: relative; z-index: 2; width: 100%; max-width: 1020px; padding: 0 var(--pad) clamp(40px, 8vh, 92px); }
.stop-copy h3 {
  font-family: var(--serif); font-weight: 600; color: #FBF7F0;
  font-size: clamp(42px, 6.6vw, 108px); line-height: .96; letter-spacing: -.015em; margin: 0 0 .24em; text-wrap: balance;
  text-shadow: 0 2px 30px rgba(0, 0, 0, .55), 0 1px 3px rgba(0, 0, 0, .4);
}
.stop-desc {
  max-width: 42ch; color: #F4EFE7; font-weight: 500;
  font-size: clamp(16px, 1.4vw, 20px); line-height: 1.6; text-shadow: 0 1px 14px rgba(0, 0, 0, .7);
}
.badge {
  display: inline-block; margin-top: 20px; padding: 8px 14px; border-radius: 999px;
  font-size: 10px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase;
  color: var(--carbon); background: var(--luz); box-shadow: 0 0 26px rgba(255, 200, 130, .45);
}
.stop-cta { margin-top: 26px; }
.tour-hud, .tour-cursor { display: none; }
.nota-ref { padding-top: 18px; padding-bottom: 18px; font-size: 11px; letter-spacing: .08em; color: rgba(240, 234, 224, .38); }

/* --- con movimiento: carrusel --- */
html.motion .tour-stage {
  height: 100vh; height: 100svh; min-height: 560px; overflow: hidden;
  touch-action: pan-y; -webkit-user-select: none; user-select: none; cursor: pointer;
}
html.motion .stops { position: absolute; inset: 0; display: block; }
html.motion .stop { position: absolute; inset: 0; height: auto; visibility: hidden; overflow: visible; }
html.motion .stop.is-on { visibility: visible; }
html.motion .stop-copy { padding-bottom: clamp(44px, 8vh, 90px); padding-right: 300px; pointer-events: none; }
html.motion .stop-copy > * { opacity: 0; transform: translateY(26px); transition: opacity .35s ease, transform .35s ease; }
html.motion .stop.is-active .stop-copy { pointer-events: auto; }
html.motion .stop.is-active .stop-copy > * { opacity: 1; transform: none; transition: opacity .9s ease, transform 1.1s var(--ease); }
html.motion .stop.is-active .stop-copy > *:nth-child(1) { transition-delay: .12s; }
html.motion .stop.is-active .stop-copy > *:nth-child(2) { transition-delay: .2s; }
html.motion .stop.is-active .stop-copy > *:nth-child(3) { transition-delay: .3s; }
html.motion .stop.is-active .stop-copy > *:nth-child(4) { transition-delay: .4s; }
html.motion .stop-inner canvas.seq { display: block; opacity: 0; transition: opacity .5s ease; }
html.motion .stop-inner canvas.seq.is-ready { opacity: 1; }

html.motion .tour-hud { display: block; position: absolute; inset: 0; z-index: 30; pointer-events: none; }
.tour-top { position: absolute; left: var(--pad); right: var(--pad); top: 88px; }
.tour-bars { display: flex; gap: 6px; pointer-events: auto; }
.tour-bars button { flex: 1 1 0; height: 22px; background: none; border: 0; cursor: pointer; position: relative; }
.tour-bars button::before, .tour-bars button::after { content: ''; position: absolute; left: 0; right: 0; top: 10px; height: 2px; border-radius: 2px; }
.tour-bars button::before { background: rgba(240, 234, 224, .28); }
.tour-bars button::after { background: var(--luz-clara); box-shadow: 0 0 10px rgba(255, 205, 140, .8); transform: scaleX(var(--f, 0)); transform-origin: left; }
.tour-meta { display: flex; justify-content: space-between; margin-top: 6px; font-size: 10.5px; font-weight: 600; letter-spacing: .28em; text-transform: uppercase; color: rgba(240, 234, 224, .82); text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }
.tour-count b { font-weight: 600; color: var(--luz-clara); }
.tour-index { position: absolute; right: var(--pad); top: 50%; transform: translateY(-50%); list-style: none; display: grid; gap: 8px; text-align: right; pointer-events: auto; }
.tour-index button {
  background: none; border: 0; cursor: pointer; padding: 2px 0;
  font-family: var(--serif); font-size: 21px; font-weight: 500; line-height: 1.2; color: rgba(240, 234, 224, .66);
  text-shadow: 0 1px 12px rgba(0, 0, 0, .75);
  transition: color .4s ease; display: inline-flex; align-items: center; gap: 12px;
}
.tour-index button::after { content: ''; width: 0; height: 1.5px; background: var(--luz); transition: width .6s var(--ease); box-shadow: 0 0 8px rgba(255, 205, 140, .9); }
.tour-index button:hover { color: #fff; }
.tour-index li.on button { color: var(--luz-clara); font-style: italic; font-weight: 600; }
.tour-index li.on button::after { width: 34px; }
.tour-ctrl { position: absolute; right: max(var(--pad), 96px); bottom: clamp(40px, 7.5vh, 86px); display: flex; gap: 10px; pointer-events: auto; }
.tc-btn {
  width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  border: 1px solid rgba(240, 234, 224, .45); background: rgba(21, 19, 17, .5);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); color: var(--marfil);
  transition: background .3s ease, color .3s ease, border-color .3s ease, transform .5s var(--ease);
}
.tc-btn:hover { background: var(--arena); border-color: var(--arena); color: var(--carbon); }
.tc-btn:active { transform: scale(.94); }
.tc-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
#tourPause .i-play { display: none; fill: currentColor; stroke: none; }
#tourPause[aria-pressed="true"] .i-play { display: block; }
#tourPause[aria-pressed="true"] .i-pause { display: none; }

/* Etiqueta "Siguiente" que sigue al cursor */
@media (hover: hover) and (pointer: fine) {
  html.motion .tour-cursor {
    display: flex; align-items: center; gap: 8px; position: absolute; left: 0; top: 0; z-index: 40; pointer-events: none;
    padding: 11px 16px 11px 18px; border-radius: 999px; background: var(--arena); color: var(--carbon);
    font-size: 10.5px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; white-space: nowrap;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .35); opacity: 0; transition: opacity .25s ease; will-change: transform;
  }
  html.motion .tour-cursor.is-on { opacity: 1; }
  .tour-cursor svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
}
@media (max-width: 1024px) {
  .tour-index { display: none; }
  html.motion .stop-copy { padding-right: var(--pad); padding-bottom: 120px; }
  .tour-ctrl { right: auto; left: var(--pad); bottom: 36px; }
}
@media (max-width: 760px) {
  .stop-copy h3 { font-size: clamp(38px, 11.4vw, 62px); }
  .tour-top { top: 84px; }
  .tc-btn { width: 46px; height: 46px; }
  html.motion .stop-copy { padding-bottom: 96px; }
  .tour-ctrl { bottom: 24px; }
}

/* ==========================================================================
   MATERIALES
   ========================================================================== */
.materiales { background: var(--marfil-claro); color: var(--carbon); padding: clamp(96px, 15vh, 190px) 0; }
.mats { display: flex; gap: 14px; margin-top: clamp(44px, 8vh, 90px); }
.mat { position: relative; flex: 1 1 0; min-width: 0; height: min(76vh, 760px); overflow: hidden; border-radius: 6px; color: var(--marfil); transition: flex-grow .9s var(--ease); }
.mat-img { position: absolute; inset: 0; }
.mat-img img { position: absolute; left: 0; top: -8%; width: 100%; height: 116%; object-fit: cover; transition: transform 1.4s var(--ease); }
.mat::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15, 13, 11, .86), rgba(15, 13, 11, .12) 55%, rgba(15, 13, 11, .25)); pointer-events: none; }
.mat-info { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; padding: clamp(20px, 2.4vw, 36px); }
.mat-n { font-size: 11px; font-weight: 500; letter-spacing: .3em; color: var(--luz); }
.mat h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(42px, 4.8vw, 78px); line-height: 1; margin: .12em 0 .16em; }
.mat p { max-width: 30ch; font-size: 14.5px; line-height: 1.6; color: rgba(240, 234, 224, .86); }
@media (hover: hover) and (min-width: 861px) {
  .mats:hover .mat { flex-grow: .82; }
  .mats .mat:hover { flex-grow: 1.7; }
  .mat:hover .mat-img img { transform: scale(1.05); }
}
@media (max-width: 860px) {
  .mats { flex-direction: column; }
  .mat { height: 66vh; height: 66svh; flex: none; }
}

/* ==========================================================================
   PROCESS
   ========================================================================== */
.proceso { background: var(--tinta); color: var(--marfil); padding: clamp(96px, 15vh, 190px) 0; }
.proceso .eyebrow, .agendar .eyebrow { color: var(--arena); }
.pasos-wrap { position: relative; margin-top: clamp(60px, 10vh, 120px); padding-top: 46px; }
.led { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: rgba(213, 193, 164, .16); border-radius: 2px; }
.led i {
  position: absolute; inset: 0; border-radius: 2px; transform: scaleX(var(--p, 1)); transform-origin: left center;
  background: linear-gradient(90deg, var(--luz), var(--luz-clara));
  box-shadow: 0 0 14px 2px rgba(255, 205, 140, .7), 0 0 50px 8px rgba(255, 176, 96, .32);
}
.pasos { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(20px, 3vw, 56px); list-style: none; }
.paso { position: relative; }
.paso::before {
  content: ''; position: absolute; top: -52px; left: 0; width: 13px; height: 13px; border-radius: 50%;
  background: var(--luz-clara); border: 1px solid var(--luz-clara);
  box-shadow: 0 0 0 6px rgba(255, 217, 160, .12), 0 0 22px 4px rgba(255, 200, 130, .8);
  transition: background .5s ease, border-color .5s ease, box-shadow .5s ease;
}
.paso-n {
  display: block; font-family: var(--serif); font-weight: 500; font-size: clamp(70px, 8.4vw, 136px); line-height: .9;
  color: var(--arena); -webkit-text-stroke: 1px transparent; text-shadow: 0 0 40px rgba(255, 190, 110, .3);
  transition: color .7s ease, -webkit-text-stroke-color .7s ease, text-shadow .7s ease;
}
.paso h3 { font-size: 13.5px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; margin: 24px 0 10px; transition: opacity .6s ease; }
.paso p { font-size: 14.5px; line-height: 1.65; color: rgba(240, 234, 224, .72); max-width: 30ch; transition: opacity .6s ease; }
html.motion .paso:not(.on)::before { background: var(--tinta); border-color: rgba(213, 193, 164, .5); box-shadow: none; }
html.motion .paso:not(.on) .paso-n { color: transparent; -webkit-text-stroke-color: rgba(213, 193, 164, .36); text-shadow: none; }
html.motion .paso:not(.on) h3, html.motion .paso:not(.on) p { opacity: .32; }
@media (max-width: 860px) {
  .pasos-wrap { padding-top: 0; padding-left: 36px; }
  .led {
    left: 4px; right: auto; top: 6px; bottom: 6px; width: 3px; height: auto;
    z-index: 2; overflow: visible; border-radius: 999px;
  }
  .led i {
    display: block; transform: scaleY(var(--p, 1)); transform-origin: center top;
    background: linear-gradient(180deg, var(--luz), var(--luz-clara));
    will-change: transform; backface-visibility: hidden;
  }
  .led::after {
    content: ''; position: absolute; left: 50%; top: var(--p-y, 100%);
    width: 12px; height: 12px; border-radius: 50%; pointer-events: none;
    background: var(--luz-clara); transform: translate(-50%, -50%);
    box-shadow: 0 0 0 6px rgba(255, 217, 160, .12), 0 0 18px 5px rgba(255, 200, 130, .9);
    will-change: top;
  }
  .pasos { position: relative; z-index: 1; grid-template-columns: 1fr; gap: 52px; }
  .paso::before { left: -38px; top: 22px; z-index: 3; }
  .paso h3 { margin-top: 14px; }
}

/* ==========================================================================
   PROYECTOS
   ========================================================================== */
.proyectos { background: var(--marfil); color: var(--carbon); padding: clamp(96px, 15vh, 180px) 0; }
.proyectos .lead { color: var(--muted); }
.galeria { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 300px; gap: 14px; margin-top: clamp(40px, 7vh, 80px); }
.galeria.vacia { display: none; }
.galeria figure { position: relative; overflow: hidden; background: var(--marfil-claro); cursor: zoom-in; border-radius: 6px; }
.galeria figure.alto { grid-row: span 2; }
.galeria figure.ancho { grid-column: span 2; }
.galeria img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.galeria figure:hover img { transform: scale(1.05); }
.galeria figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 18px 14px;
  background: linear-gradient(transparent, rgba(41, 39, 36, .78));
  color: var(--marfil); font-family: var(--serif); font-style: italic; font-size: 19px;
  opacity: 0; transform: translateY(8px); transition: opacity .3s ease, transform .3s ease;
}
.galeria figure:hover figcaption { opacity: 1; transform: none; }
.proy-cta { margin-top: clamp(40px, 7vh, 80px); display: grid; justify-items: center; gap: 28px; text-align: center; }
.ig-big {
  display: inline-flex; align-items: center; gap: .36em; text-decoration: none; color: var(--carbon);
  font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 5.2vw, 82px); line-height: 1.05; letter-spacing: -.01em;
}
.ig-big img { width: .82em; height: .82em; flex: 0 0 auto; transition: transform .8s var(--ease); }
.ig-big em { color: var(--nogal); background: linear-gradient(currentColor, currentColor) left 96% / 0 1px no-repeat; transition: background-size .7s var(--ease); }
.ig-big:hover em { background-size: 100% 1px; }
.ig-big:hover img { transform: rotate(-12deg) scale(1.08); }
.link-wa { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--nogal); }
.link-wa img { width: 26px; height: 26px; }
.lightbox { position: fixed; inset: 0; z-index: 150; background: rgba(20, 19, 17, .93); display: none; align-items: center; justify-content: center; padding: 30px; cursor: zoom-out; }
.lightbox.on { display: flex; }
.lightbox img { max-height: 88vh; max-width: 92vw; width: auto; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
@media (max-width: 960px) { .galeria { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 220px; } }
@media (max-width: 640px) {
  .galeria { grid-auto-rows: 170px; gap: 8px; }
  .galeria figcaption { opacity: 1; transform: none; font-size: 16px; padding: 30px 12px 10px; }
}

/* ---------- Planificador por presupuesto (Stackline) ---------- */
/* Más ancho que las demás secciones (.wrap llega a 1360 px): el planificador tiene
   tres columnas y aprovecha la pantalla, con un margen lateral más chico. */
.planificador-wrap { width: 100%; max-width: 1920px; margin: 0 auto; padding: 0 clamp(12px, 2vw, 32px); }
/* embed.js pone el bloque dentro; si no carga, el div queda vacío y no ocupa espacio. */
#planificador { padding: clamp(64px, 10vh, 120px) 0; }
#planificador:empty { display: none; }

/* ==========================================================================
   AGENDA TU VISITA
   ========================================================================== */
.agendar { position: relative; background: var(--noche); color: var(--marfil); padding: clamp(96px, 14vh, 170px) 0 clamp(96px, 14vh, 170px); overflow: clip; }
.agendar-logo { display: flex; justify-content: center; margin-bottom: clamp(34px, 5vh, 56px); }
.agendar-logo-card {
  display: grid; place-items: center; width: clamp(150px, 16vw, 210px); padding: 16px 20px;
  background: #fff; border-radius: 4px; box-shadow: 0 16px 42px rgba(0, 0, 0, .3);
}
.agendar-logo-card img { width: 100%; height: auto; }
html.motion .agendar { padding-top: clamp(72px, 10vh, 110px); }
.agendar-grid { display: grid; grid-template-columns: .92fr 1.08fr; gap: clamp(40px, 6vw, 100px); align-items: start; margin-top: clamp(50px, 9vh, 100px); }
.agendar-persona { position: relative; }
.video-frame { position: relative; width: min(340px, 74%); border-radius: 6px; overflow: hidden; background: #1d1b19; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); }
.video-frame video { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; background: #1d1b19; }
.video-frame.landscape { width: 100%; }
.video-frame.landscape video { aspect-ratio: 16 / 9; }
.vplay, .vbar { display: none; }
.video-frame.custom video { cursor: pointer; }
.video-frame.custom .vplay {
  position: absolute; left: 14px; top: 14px; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px 9px 10px; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(240, 234, 224, .42); background: rgba(21, 19, 17, .55); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  font-size: 10.5px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--marfil);
  transition: background .3s ease, border-color .3s ease;
}
.video-frame.custom .vplay:hover { background: rgba(21, 19, 17, .82); border-color: var(--marfil); }
.vplay svg { width: 20px; height: 20px; fill: currentColor; }
.vplay .i-pause { display: none; }
.video-frame.is-playing .vplay .i-pause { display: block; }
.video-frame.is-playing .vplay .i-play { display: none; }
.video-frame.custom .vbar { display: block; position: absolute; left: 0; right: 0; top: 0; height: 2px; z-index: 2; background: rgba(240, 234, 224, .16); }
.vbar b { position: absolute; inset: 0; transform: scaleX(0); transform-origin: left center; background: var(--luz-clara); box-shadow: 0 0 10px rgba(255, 205, 140, .9); }

/* Tarjeta de presentación */
.tarjeta-wrap { position: relative; z-index: 2; width: min(440px, 100%); margin: -150px 0 0 auto; padding: 0 0 18px 18px; }
.tarjeta-wrap::before {
  content: ''; position: absolute; left: 0; bottom: 0; right: 18px; top: 18px;
  background: url('../img/material-madera.jpg') center / cover; transform: rotate(-2.2deg);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .4);
}
.tarjeta {
  position: relative; display: grid; grid-template-columns: 1fr auto; gap: 0 22px;
  background: radial-gradient(ellipse 90% 80% at 85% 0%, rgba(139, 101, 73, .4), transparent 60%), var(--carbon);
  color: var(--marfil); padding: 30px 30px 26px; aspect-ratio: 1.75 / 1;
  box-shadow: 0 24px 50px rgba(0, 0, 0, .45), inset 0 0 0 1px rgba(213, 193, 164, .16);
  transition: transform .6s var(--ease);
}
.tarjeta-wrap:hover .tarjeta { transform: translate(-3px, -3px); }
.tarjeta::after { content: ''; position: absolute; inset: 10px; border: 1px solid rgba(213, 193, 164, .22); pointer-events: none; }
.tarjeta-logo { width: 58px; height: auto; grid-column: 2; grid-row: 1 / span 2; justify-self: end; opacity: .95; }
.tarjeta-nombre { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 40px; line-height: 1; color: var(--marfil); }
.tarjeta-rol { margin-top: 8px; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--arena); }
.tarjeta-linea { grid-column: 1 / -1; height: 1px; margin: 18px 0 14px; background: linear-gradient(90deg, var(--arena), transparent); opacity: .6; }
.tarjeta-datos { grid-column: 1 / -1; list-style: none; display: grid; gap: 9px; position: relative; z-index: 1; }
.tarjeta-datos a { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--marfil); font-size: 14.5px; letter-spacing: .02em; transition: color .2s ease; }
.tarjeta-datos a:hover { color: var(--arena); }
.tarjeta-datos .ico { width: 26px; height: 26px; border-radius: 50%; flex: 0 0 26px; display: inline-flex; align-items: center; justify-content: center; background: rgba(240, 234, 224, .08); border: 1px solid rgba(213, 193, 164, .3); }
.tarjeta-datos .ico svg { width: 13px; height: 13px; fill: var(--arena); }
.tarjeta-datos .ico img { width: 26px; height: 26px; }
.tarjeta-datos .ico.img { background: none; border: 0; }
.tarjeta-datos strong { font-family: var(--serif); font-size: 21px; font-weight: 600; letter-spacing: .03em; }

.oferta { padding: 24px 26px; border: 1px solid rgba(213, 193, 164, .3); border-radius: 6px; background: rgba(240, 234, 224, .04); }
.oferta strong { display: block; font-family: var(--serif); font-size: clamp(24px, 2.2vw, 30px); font-weight: 500; color: var(--luz-clara); line-height: 1.2; }
.oferta p { font-size: 14.5px; color: rgba(240, 234, 224, .72); margin-top: 6px; }
.cita-form { margin-top: 26px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.form-field { display: flex; flex-direction: column; gap: 9px; }
.form-wide { grid-column: 1 / -1; }
.form-field label { font-size: 10.5px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--arena); }
.form-field input, .form-field textarea {
  background: rgba(240, 234, 224, .05); border: 1px solid rgba(213, 193, 164, .24); border-radius: 4px; padding: 15px 16px;
  color: var(--marfil); font-family: var(--sans); font-size: 16px; outline: none; resize: vertical;
  transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;
}
.form-field input:focus, .form-field textarea:focus { border-color: var(--luz); background: rgba(240, 234, 224, .08); box-shadow: 0 0 0 3px rgba(255, 217, 160, .14), 0 0 26px rgba(255, 190, 110, .12); }
.form-field input::placeholder, .form-field textarea::placeholder { color: rgba(240, 234, 224, .34); }
.cita-form .btn { margin-top: 26px; }
.form-note { margin-top: 14px; font-size: 14px; color: rgba(240, 234, 224, .72); min-height: 1.6em; }
@media (max-width: 960px) {
  .agendar-grid { grid-template-columns: 1fr; }
  .video-frame { width: min(300px, 70%); }
  .tarjeta-wrap { margin-top: -110px; }
}
@media (max-width: 520px) {
  .form-grid { grid-template-columns: 1fr; }
  .video-frame { width: 72%; }
  .tarjeta-wrap { margin-top: -70px; }
  .tarjeta { aspect-ratio: auto; padding: 26px 22px 22px; }
  .tarjeta-nombre { font-size: 34px; }
  .tarjeta-logo { width: 46px; }
  .tarjeta-datos a { font-size: 13.5px; }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.pie > .wrap { container-type: inline-size; }
.pie { background: var(--noche); color: rgba(240, 234, 224, .72); padding: clamp(60px, 9vh, 110px) 0 34px; border-top: 1px solid rgba(213, 193, 164, .14); overflow: clip; }
.pie-tagline { font-family: var(--serif); font-style: italic; font-size: clamp(20px, 2vw, 28px); color: var(--arena); }
.pie-marca {
  font-family: var(--serif); font-weight: 600; text-transform: uppercase; white-space: nowrap;
  font-size: min(13vw, 176px); font-size: 14.2cqw; line-height: .92; letter-spacing: -.02em; margin: .08em 0 .12em -0.03em;
  background: url('../img/tex/burl.webp') 0% 50% / 130% auto; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: veta 36s ease-in-out infinite alternate;
}
@keyframes veta { to { background-position: 100% 50%; } }
.pie-fila { display: flex; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; padding-top: 28px; border-top: 1px solid rgba(213, 193, 164, .14); }
.foot-links, .foot-contacto { display: flex; gap: 12px 28px; flex-wrap: wrap; font-size: 13px; }
.pie a { text-decoration: none; color: rgba(240, 234, 224, .82); transition: color .25s ease; }
.pie a:hover { color: var(--luz-clara); }
.pie-legal { display: flex; justify-content: space-between; gap: 14px 40px; flex-wrap: wrap; margin-top: 44px; }
.copy { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: rgba(240, 234, 224, .42); }
.creditos { font-size: 11px; line-height: 1.6; color: rgba(240, 234, 224, .38); max-width: 70ch; }
.creditos a { color: rgba(240, 234, 224, .56); text-decoration: underline; text-underline-offset: 2px; }
@media (max-width: 760px) {
  .pie-marca { white-space: normal; font-size: 22vw; font-size: 24.6cqw; line-height: .86; background-size: 220% auto; }
  .pie-marca span { display: block; }
  .pie { padding-bottom: 96px; }
}

/* WhatsApp flotante */
.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 65;
  width: 56px; height: 56px; border-radius: 50%; background: var(--nogal);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .35); transition: transform .5s var(--ease), background .2s ease;
}
.wa-float:hover { transform: scale(1.08); background: var(--nogal-osc); }
.wa-float svg { width: 26px; height: 26px; fill: var(--marfil-claro); }

/* ==========================================================================
   Estados de entrada (solo con movimiento)
   ========================================================================== */
html.motion [data-reveal] { opacity: 0; transform: translateY(30px); }
html.motion [data-clip] { clip-path: inset(100% 0 0 0); }
html.motion [data-lines] { visibility: hidden; }
html.motion .split-line { overflow: hidden; padding-bottom: .12em; margin-bottom: -.12em; }

@media (prefers-reduced-motion: reduce) {
  .pie-marca { animation: none; }
  html { scroll-behavior: auto; }
}

/* ==========================================================================
   PARA EMPRESAS
   ========================================================================== */
.empresas { background: var(--marfil); color: var(--carbon); padding: clamp(96px, 15vh, 180px) 0; }
.empresas .lead { color: var(--texto); }
.emp-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 110px); align-items: start; }
.emp-head { position: sticky; top: 110px; }
.emp-head .display { font-size: clamp(38px, 5vw, 76px); }
.emp-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 26px; margin-top: 8px; }
.emp-mail { font-size: 14px; color: var(--nogal); text-decoration: none; border-bottom: 1px solid rgba(139, 101, 73, .35); transition: border-color .25s ease; }
.emp-mail:hover { border-color: var(--nogal); }
.sectores { list-style: none; border-top: 1px solid var(--linea); }
.sector { display: grid; grid-template-columns: 56px 1fr; gap: 0 18px; padding: clamp(24px, 3.4vh, 38px) 0; border-bottom: 1px solid var(--linea); }
.sector-n { font-size: 11px; font-weight: 500; letter-spacing: .3em; color: var(--nogal); padding-top: .9em; }
.sector h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(28px, 2.6vw, 40px); line-height: 1.08; color: var(--carbon); }
.sector p { margin-top: 8px; font-size: 15px; line-height: 1.65; color: var(--muted); max-width: 46ch; }
.garantias { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: clamp(56px, 9vh, 110px); }
.garantias li { padding: 24px 22px; border-radius: 6px; background: var(--marfil-claro); border: 1px solid var(--linea); display: grid; gap: 8px; align-content: start; }
.garantias strong { font-family: var(--serif); font-weight: 600; font-size: 22px; line-height: 1.15; color: var(--carbon); }
.garantias span { font-size: 14px; line-height: 1.6; color: var(--muted); }
.opcional { font-weight: 400; letter-spacing: .08em; text-transform: none; opacity: .7; }
@media (max-width: 1024px) { .garantias { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 860px) {
  .emp-grid { grid-template-columns: 1fr; }
  .emp-head { position: static; }
}
@media (max-width: 520px) {
  .garantias { grid-template-columns: 1fr; }
  .sector { grid-template-columns: 40px 1fr; }
}
