/* ============ VARIABLES ============ */
:root{
  --bg: #0A0D12;
  --bg-soft: #10151C;
  --navy: #0B3D5C;
  --orange: #F2994A;
  --orange-dark: #DB7C2A;
  --cream: #F3ECE1;
  --cream-soft: #EAE1D2;
  --ink: #17140F;
  --white: #FFFFFF;
  --muted: rgba(255,255,255,.62);
  --muted-soft: rgba(255,255,255,.4);
  --border-dark: rgba(255,255,255,.14);
  --whatsapp: #25D366;
  --whatsapp-dark: #1DA851;
  --shadow-lg: 0 30px 70px -20px rgba(0,0,0,.5);
  --ease: cubic-bezier(.22,.61,.36,1);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

*{ box-sizing: border-box; }
html,body{ height:100%; }
body{
  margin:0;
  font-family: var(--sans);
  color: var(--white);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
h1,h2,h3,h4{ margin:0; font-family: var(--serif); font-weight:600; color:#fff; }
p{ margin: 0 0 1em; }
a{ color: inherit; text-decoration: none; }
ul{ list-style:none; margin:0; padding:0; }
img{ max-width:100%; display:block; }
button{ font-family:inherit; background:none; border:none; color:inherit; cursor:pointer; }

/* ============ BUTTONS ============ */
.btn{
  display: inline-flex; align-items:center; justify-content:center; gap:8px;
  font-weight:700; border:1.5px solid transparent; border-radius:100px;
  cursor:pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease, border-color .15s ease;
  white-space:nowrap; font-family: var(--sans);
}
.btn-sm{ padding:9px 18px; font-size:.85rem; }
.btn-lg{ padding:16px 30px; font-size:1rem; }
.btn-primary{ background: var(--orange); color: var(--ink); }
.btn-primary:hover{ background: var(--orange-dark); color:#fff; transform: translateY(-1px); box-shadow: 0 10px 24px rgba(242,153,74,.3); }
.btn-ghost{ border-color: rgba(255,255,255,.35); color:#fff; }
.btn-ghost:hover{ border-color:#fff; background: rgba(255,255,255,.08); }
.btn-whatsapp{ background: var(--whatsapp); color:#fff; }
.btn-whatsapp:hover{ background: var(--whatsapp-dark); transform: translateY(-1px); box-shadow: 0 10px 24px rgba(37,211,102,.3); }
.btn-block{ width:100%; padding:15px 20px; font-size:.98rem; border-radius:12px; }
.btn:focus-visible{ outline: 2px solid var(--orange); outline-offset: 3px; }

/* ============ HUD (overlay fijo) ============ */
.hud{ position:fixed; z-index: 900; }
.hud-top{
  top:0; left:0; right:0;
  display:flex; align-items:center; justify-content:space-between;
  padding: 16px 28px;
}
.logo{ display:flex; align-items:center; gap:9px; }
.logo-icon{ width:36px; height:36px; flex-shrink:0; }
.logo-text{ font-weight:600; font-size:.95rem; color:#fff; font-family: var(--serif); }
.hud-actions{ display:flex; align-items:center; gap:10px; }
.hud-btn{
  display:flex; align-items:center; gap:7px;
  padding:9px 16px; border-radius:100px; font-weight:700; font-size:.82rem;
  background: rgba(10,13,18,.55); border:1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(8px); color:#fff; transition: background .15s ease, border-color .15s ease;
}
.hud-btn:hover{ border-color: var(--orange); }
.hud-btn .icon{ width:16px; height:16px; }
.hud-btn-whatsapp{ background: rgba(37,211,102,.16); border-color: rgba(37,211,102,.4); }

/* ============ NAV DE PROFUNDIDAD ============ */
.depth-nav{ top:50%; right:26px; transform: translateY(-50%); }
.depth-nav ul{ display:flex; flex-direction:column; gap:16px; align-items:flex-end; }
.depth-dot{
  position:relative; display:flex; align-items:center; gap:10px;
  width:9px; height:9px; border-radius:50%;
  background: rgba(255,255,255,.3); transition: background .25s ease, transform .25s ease;
}
.depth-dot span{
  position:absolute; right:22px; top:50%; transform: translateY(-50%);
  font-size:.72rem; font-weight:700; letter-spacing:.03em; white-space:nowrap;
  color: var(--muted); opacity:0; transition: opacity .2s ease;
  background: rgba(10,13,18,.7); padding:4px 10px; border-radius:6px; backdrop-filter: blur(6px);
}
.depth-dot:hover span, .depth-dot:focus-visible span{ opacity:1; }
.depth-dot.active{ background: var(--orange); transform: scale(1.5); }
.depth-dot:focus-visible{ outline: 2px solid var(--orange); outline-offset:4px; }

/* ============ PISTA DE SCROLL ============ */
.scroll-hint{
  left:50%; bottom:26px; transform: translateX(-50%);
  display:flex; flex-direction:column; align-items:center; gap:4px;
  font-size:.72rem; font-weight:700; letter-spacing:.04em; text-transform:uppercase;
  color: var(--muted); pointer-events:none;
  transition: opacity .5s ease;
}
.scroll-hint.hidden{ opacity:0; }
.scroll-hint-arrow{ font-size:1.3rem; color: var(--orange); animation: bob 1.6s ease-in-out infinite; }
@keyframes bob{ 0%,100%{ transform: translateY(0);} 50%{ transform: translateY(6px);} }

/* ============ MOTOR DE ESCENAS ============ */
.scene-stack{ position:relative; width:100%; height:100vh; height:100dvh; }
.scene{
  position:fixed; inset:0; width:100%; height:100vh; height:100dvh;
  overflow:hidden;
  opacity:0; pointer-events:none; z-index:1;
  transform: scale(.82); filter: blur(16px);
  transition: opacity 1s var(--ease), transform 1s var(--ease), filter 1s var(--ease);
  will-change: transform, opacity, filter;
  background: var(--bg);
}
.scene[data-state="active"]{ opacity:1; transform: scale(1); filter: blur(0); z-index:5; pointer-events:auto; }
.scene[data-state="behind"]{ opacity:0; transform: scale(1.22); filter: blur(18px); z-index:2; }

.scene-bg{ position:absolute; inset:0; z-index:0; }
.scene-bg-photo img{ width:100%; height:100%; object-fit:cover; object-position:65% 55%; }
.scene-bg-overlay{
  position:absolute; inset:0;
  background: linear-gradient(180deg, rgba(10,13,18,.5) 0%, rgba(10,13,18,.72) 55%, rgba(10,13,18,.94) 100%);
}
.scene-bg-road svg, .scene-bg-map svg{ width:100%; height:100%; }
.scene-bg-dots{
  background-image: radial-gradient(circle, rgba(255,255,255,.07) 1.5px, transparent 1.5px);
  background-size: 28px 28px;
}
.scene-bg-quote{
  position:absolute; top:-22vh; left:-4vw;
  font-family: var(--serif); font-size: 60vh; font-weight:600;
  color: rgba(242,153,74,.07); line-height:1; user-select:none;
}

.scene-content{
  position:relative; z-index:1; height:100%; width:100%;
  overflow-y:auto; -webkit-overflow-scrolling:touch;
}
/* Envoltorio interno: centra el contenido cuando cabe en pantalla,
   y si es más alto que la pantalla, crece y permite scroll interno
   en vez de recortarlo por arriba y por abajo. */
.scene-content-inner{
  box-sizing:border-box; min-height:100%;
  display:flex; flex-direction:column; justify-content:center;
  padding: 13vh 8vw; max-width:1320px; margin:0 auto;
}

.scene-eyebrow{
  display:inline-block; color: var(--orange); font-weight:800; letter-spacing:.08em;
  text-transform:uppercase; font-size:.76rem; margin-bottom:16px;
}
.scene-eyebrow::before{ content:"—"; margin-right:8px; color: var(--orange); }
.scene-heading{ font-size: clamp(2.1rem, 5.4vw, 3.9rem); line-height:1.02; letter-spacing:-.01em; margin-bottom:20px; }

/* ============ HERO ============ */
.hero-content{ max-width:720px; align-items:flex-start; text-align:left; }
.hero-title{ font-size: clamp(2.3rem, 6.6vw, 4.7rem); line-height:1.03; letter-spacing:-.015em; margin-bottom:22px; }
.hero-lede{ font-size:1.08rem; color: var(--muted); max-width:460px; margin-bottom:30px; }
.hero-cta{ display:flex; flex-wrap:wrap; gap:14px; }
.hero-stats{
  position:absolute; left:0; right:0; bottom:0; z-index:2;
  display:flex; border-top:1px solid rgba(255,255,255,.14);
  background: rgba(10,13,18,.55); backdrop-filter: blur(10px);
}
.hero-stats div{
  flex:1; text-align:center; padding: 18px 10px; border-right:1px solid rgba(255,255,255,.1);
  display:flex; flex-direction:column; gap:4px;
}
.hero-stats div:last-child{ border-right:none; }
.hero-stats strong{ font-family: var(--serif); font-size:1.6rem; color: var(--orange); }
.hero-stats strong em{ font-style:normal; font-size:1rem; color: var(--muted); }
.hero-stats span{ font-size:.72rem; text-transform:uppercase; letter-spacing:.05em; color: var(--muted); }

/* ============ CONFIANZA ============ */
.scene-confianza{ background: radial-gradient(ellipse at 50% 100%, rgba(242,153,74,.09), transparent 60%), var(--bg); }
.scene-bg-road{ opacity:.9; }
.confianza-content{ max-width: 980px; }
.trust-list{ margin-top:12px; display:grid; grid-template-columns:1fr 1fr; gap:0 48px; border-bottom:1px solid var(--border-dark); }
.trust-list li{
  display:grid; grid-template-columns: 46px 1fr; align-items:baseline; gap:14px;
  padding: 18px 0; border-top:1px solid var(--border-dark);
}
.trust-num{ font-family: var(--serif); font-size:1.3rem; color: rgba(242,153,74,.5); }
.trust-list h3{ font-size:1.05rem; margin-bottom:.3em; }
.trust-list p{ color: var(--muted); font-size:.88rem; margin:0; }

/* ============ SERVICIOS ============ */
.scene-servicios{ background: var(--bg-soft); }
.servicios-content{ max-width:1100px; }
.services-list{ display:grid; grid-template-columns: repeat(4,1fr); gap:0 32px; margin-top:8px; }
.service-item{ padding:20px 0; border-top:1px solid var(--border-dark); transition: border-color .2s ease; }
.service-item:hover{ border-color: var(--orange); }
.service-item h3{ font-size:1.08rem; margin-bottom:.35em; }
.service-item p{ font-size:.84rem; color: var(--muted); margin:0; }

/* ============ OPINIONES ============ */
.scene-opiniones{ background: var(--bg); }
.opiniones-content{ max-width:760px; }
.rating-huge{ font-family: var(--serif); font-size: clamp(3rem,9vw,5.4rem); color:#fff; margin: 4px 0 30px; line-height:1; }
.rating-huge em{ font-style:normal; font-size:1.3rem; color: var(--muted); margin-left:6px; }
.review-quote{
  font-family: var(--serif); font-size: clamp(1.15rem,2.4vw,1.5rem); font-weight:500;
  border-left: 2px solid var(--orange); padding-left:22px; margin: 0 0 22px; color:#fff; line-height:1.4;
}
.review-quote-alt{ color: var(--muted); border-left-color: rgba(255,255,255,.25); }
.review-summary{ font-size:.88rem; color: var(--muted-soft); margin-top:8px; }

/* ============ NOSOTROS ============ */
.scene-nosotros{ background: var(--bg); }
.nosotros-content{ max-width:680px; }
.nosotros-heading{ font-size: clamp(2.4rem,7vw,4.6rem); }
.nosotros-lede{ font-size:1.05rem; color: var(--muted); max-width:480px; }

/* ============ CONTACTO ============ */
.scene-contacto{ background: var(--cream); color: var(--ink); }
.scene-contacto .scene-eyebrow, .scene-contacto .scene-eyebrow::before{ color: var(--orange-dark); }
.scene-contacto .scene-heading{ color: var(--ink); }
.contacto-content{ display:grid; grid-template-columns:.85fr 1.15fr; gap:56px; align-items:center; max-width:1180px; }
.contacto-info p{ color: rgba(23,20,15,.65); }
.contact-list{ margin-top:22px; display:flex; flex-direction:column; gap:16px; }
.contact-list li{ display:flex; align-items:flex-start; gap:12px; font-weight:600; }
.contact-list .icon{ width:20px; height:20px; color: var(--orange-dark); flex-shrink:0; margin-top:2px; }
.contact-list a:hover{ color: var(--orange-dark); }

.contact-form{
  background:#fff; border:1px solid rgba(23,20,15,.1); border-radius:18px;
  padding:30px; box-shadow: var(--shadow-lg);
}
.contact-form h3{ color: var(--ink); margin-bottom:18px; font-size:1.2rem; }
.form-row{ margin-bottom:14px; }
.form-row-2{ display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.form-row label{ display:block; font-size:.8rem; font-weight:700; margin-bottom:5px; color: var(--ink); }
.form-row input, .form-row textarea{
  width:100%; padding:11px 13px; border:1px solid rgba(23,20,15,.15); border-radius:9px;
  font-family:inherit; font-size:.92rem; color: var(--ink); background: var(--cream-soft);
}
.form-row input:focus, .form-row textarea:focus{ outline:none; border-color: var(--navy); background:#fff; }

/* ============ FINAL / CIERRE ============ */
.scene-final{ background: var(--bg); }
.final-content{ align-items:center; text-align:center; max-width:800px; }
.final-heading{ font-size: clamp(2.4rem,7vw,4.4rem); margin-bottom:26px; }
.final-content .hero-cta{ justify-content:center; margin-bottom:56px; }
.final-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:24px; width:100%; max-width:520px; margin-bottom:36px; text-align:left; }
.footer-nav{ display:flex; flex-direction:column; gap:9px; }
.footer-nav h4{ font-family: var(--sans); font-size:.72rem; text-transform:uppercase; letter-spacing:.06em; color: var(--muted-soft); margin-bottom:4px; }
.footer-nav a, .link-btn{ font-size:.88rem; color: var(--muted); text-align:left; }
.footer-nav a:hover, .link-btn:hover{ color: var(--orange); }
.final-copy{ font-size:.78rem; color: var(--muted-soft); margin:0; }

/* ============ WHATSAPP FLOTANTE ============ */
.whatsapp-float{
  position: fixed; bottom:24px; right:24px; z-index:850;
  width:56px; height:56px; background: var(--whatsapp); border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  box-shadow: 0 10px 25px rgba(0,0,0,.35); transition: transform .15s ease;
}
.whatsapp-float:hover{ transform: scale(1.08); }
.whatsapp-float svg{ width:28px; height:28px; color:#fff; }

/* ============ COOKIE BANNER ============ */
.cookie-banner{
  position:fixed; left:16px; right:16px; bottom:16px; max-width:600px; margin:0 auto;
  background: rgba(10,13,18,.92); backdrop-filter: blur(10px); color: rgba(255,255,255,.9);
  border-radius:16px; padding:18px 20px; display:flex; align-items:center; gap:16px; flex-wrap:wrap;
  justify-content:space-between; box-shadow: var(--shadow-lg); z-index:950;
  transform: translateY(140%); transition: transform .35s ease; border:1px solid rgba(255,255,255,.12);
  pointer-events:none; /* deja pasar los clics a la navegación que quede debajo */
}
.cookie-banner.show{ transform: translateY(0); }
.cookie-banner p{ margin:0; font-size:.84rem; color: rgba(255,255,255,.82); flex:1 1 300px; pointer-events:auto; }
.cookie-banner a{ text-decoration:underline; }
.cookie-banner button{ pointer-events:auto; }

/* ============ PÁGINAS LEGALES (scroll normal) ============ */
body.legal-page{ overflow:auto; background: var(--cream); }
.site-header{
  position: sticky; top:0; z-index:500; background: rgba(10,13,18,.94);
  backdrop-filter: blur(8px); border-bottom:1px solid var(--border-dark);
}
.header-inner{ display:flex; align-items:center; justify-content:space-between; gap:20px; padding:14px 24px; max-width:1180px; margin:0 auto; }
.legal-content{ max-width:780px; margin:0 auto; padding:56px 24px 90px; background: var(--cream); color: var(--ink); }
.legal-content h1{ font-size:2.1rem; margin-bottom:.3em; color: var(--ink); }
.legal-content .updated{ color: rgba(23,20,15,.55); font-size:.85rem; margin-bottom:2.5em; }
.legal-content h2{ font-size:1.25rem; margin-top:1.6em; margin-bottom:.5em; color: var(--ink); }
.legal-content p, .legal-content li{ color: rgba(23,20,15,.78); font-family: var(--sans); margin-bottom:.8em; }
.legal-content ul{ list-style:disc; padding-left:1.4em; margin-bottom:1em; }
.legal-content a{ color: var(--orange-dark); font-weight:700; text-decoration:underline; }
.back-home{ display:inline-flex; align-items:center; gap:6px; font-weight:700; color: var(--orange-dark); margin-bottom:20px; }
.site-footer{ background: var(--bg); }
.footer-bottom{ padding:22px 24px; text-align:center; font-size:.82rem; color: var(--muted-soft); max-width:1180px; margin:0 auto; }

/* ============ RESPONSIVE ============ */
@media (max-width: 980px){
  .depth-nav{ top:auto; right:50%; bottom:16px; transform: translateX(50%); }
  .depth-nav ul{ flex-direction:row; align-items:center; gap:12px; }
  .depth-dot span{ display:none; }
  .scene-content-inner{ padding: 11vh 6vw; }
  .services-list{ grid-template-columns: repeat(2,1fr); }
  .contacto-content{ grid-template-columns:1fr; gap:32px; }
  .final-grid{ grid-template-columns: repeat(3,1fr); max-width:100%; }
  .hero-stats strong{ font-size:1.25rem; }
}

@media (max-width: 640px){
  .hud-top{ padding:12px 16px; }
  .hud-btn span{ display:none; }
  .hud-btn{ padding:10px; }
  .logo-text{ font-size:.85rem; }
  .hero-content{ padding-bottom:110px; }
  .hero-stats{ flex-wrap:wrap; }
  .hero-stats div{ flex:1 1 50%; border-right:none; border-bottom:1px solid rgba(255,255,255,.1); }
  .trust-list{ grid-template-columns:1fr; }
  .services-list{ grid-template-columns:1fr; }
  .form-row-2{ grid-template-columns:1fr; }
  .final-grid{ grid-template-columns:1fr 1fr; }
  .scene-bg-quote{ font-size:40vh; }
  .whatsapp-float{ width:50px; height:50px; bottom:18px; right:18px; }
  .whatsapp-float svg{ width:24px; height:24px; }
}

@media (max-height: 620px){
  .scene-content-inner{ padding-top: 9vh; padding-bottom: 9vh; }
  .hero-stats{ position:static; margin-top:24px; }
}

/* Movimiento reducido: cambios instantáneos, sin animación de profundidad */
@media (prefers-reduced-motion: reduce){
  .scene{ transition-duration: .01s; }
  .scroll-hint-arrow{ animation:none; }
  html{ scroll-behavior:auto; }
}
