/* Fuentes autoalojadas (antes Google Fonts — la web no hace peticiones a servidores externos) */
@font-face { font-family:'Bebas Neue'; font-style:normal; font-weight:400; font-display:swap; src:url('/fonts/bebas-neue-400.woff2') format('woff2'); }
@font-face { font-family:'Rajdhani'; font-style:normal; font-weight:300; font-display:swap; src:url('/fonts/rajdhani-300.woff2') format('woff2'); }
@font-face { font-family:'Rajdhani'; font-style:normal; font-weight:400; font-display:swap; src:url('/fonts/rajdhani-400.woff2') format('woff2'); }
@font-face { font-family:'Rajdhani'; font-style:normal; font-weight:500; font-display:swap; src:url('/fonts/rajdhani-500.woff2') format('woff2'); }
@font-face { font-family:'Rajdhani'; font-style:normal; font-weight:600; font-display:swap; src:url('/fonts/rajdhani-600.woff2') format('woff2'); }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --white:      #FAFAF8;
  --warm-white: #F5F3F0;
  --cream:      #EDE9E3;
  --sand:       #D4C9B8;
  --sage:       #6A6A67;
  --sage-light: #B0B0AE;
  --black:      #0C0C0A;
  --dark:       #1A1A18;
  --grey-800:   #2E2E2C;
  --grey-600:   #5A5A58;
  --grey-400:   #2A2826;
  --grey-200:   #D8D6D2;
  --grey-100:   #ECEAE6;
  --font-serif: 'Bebas Neue', sans-serif;
  --font-sans:  'Rajdhani', sans-serif;
  --ease:       cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-out:   cubic-bezier(0.16, 1, 0.3, 1);
}

html { scroll-behavior: smooth; font-size: 16px; }
html, body { overflow-x: hidden; width: 100%; }
body { background: var(--white); color: var(--grey-800); font-family: var(--font-sans); font-weight: 300; -webkit-font-smoothing: antialiased; }
*, *::before, *::after { box-sizing: border-box; }
img, video, iframe { max-width: 100%; height: auto; }

/* INTRO — persianas + contador de carga */
#intro { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; height: 100dvh; z-index: 10000; overflow: hidden;
         animation: introFin .01s linear 2.6s both; }   /* red de seguridad: se retira aunque falle el JS */
@keyframes introFin { to { visibility: hidden; pointer-events: none; } }
body.intro-abierta { overflow: hidden; }

.intro-blinds { position: absolute; inset: 0; display: flex; }
.intro-blind { flex: 1; background: var(--black); border-right: 1px solid rgba(255,255,255,.04);
               animation: blindUp .85s cubic-bezier(.76,0,.24,1) both; }
.intro-blind:nth-child(odd) { animation-name: blindDown; }
.intro-blind:nth-child(1) { animation-delay: 1.25s; }
.intro-blind:nth-child(2) { animation-delay: 1.32s; }
.intro-blind:nth-child(3) { animation-delay: 1.39s; }
.intro-blind:nth-child(4) { animation-delay: 1.46s; }
.intro-blind:nth-child(5) { animation-delay: 1.53s; }
.intro-blind:nth-child(6) { animation-delay: 1.60s; }
.intro-blind:nth-child(7) { animation-delay: 1.67s; }
.intro-blind:nth-child(8) { animation-delay: 1.74s; }
@keyframes blindUp   { 0% { transform: translateY(0); }  100% { transform: translateY(-101%); } }
@keyframes blindDown { 0% { transform: translateY(0); }  100% { transform: translateY(101%); } }

.intro-panel { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
               padding: 0 1.5rem; text-align: center; animation: introPanelOut .45s var(--ease) 1.2s both; }
@keyframes introPanelOut { to { opacity: 0; } }
.intro-logo { width: clamp(78px, 9vw, 128px); height: clamp(78px, 9vw, 128px); object-fit: contain;
              filter: invert(1); mix-blend-mode: screen; margin-bottom: 2.2rem; animation: fadeIn .8s var(--ease) both; }
.intro-num { font-family: var(--font-serif); font-size: clamp(3rem, 7vw, 5.6rem); font-weight: 300; color: #fff; line-height: 1; letter-spacing: .04em; }
.intro-bar { width: min(240px, 46vw); height: 1px; background: rgba(255,255,255,.18); margin-top: 1.6rem; position: relative; overflow: hidden; }
.intro-bar span { position: absolute; inset: 0; background: var(--sage-light); transform-origin: left; transform: scaleX(0);
                  animation: introLoad 1.2s cubic-bezier(.5,0,.2,1) both; }
@keyframes introLoad { to { transform: scaleX(1); } }
.intro-label { font-size: .68rem; letter-spacing: .4em; text-transform: uppercase; color: rgba(255,255,255,.42); margin-top: 1.4rem; }
@keyframes fadeIn { from{opacity:0;transform:scale(.92)} to{opacity:1;transform:none} }
/* Si el visitante pide menos movimiento, no hay intro */
@media (prefers-reduced-motion: reduce) { #intro { display: none; } }

/* SCROLL PROGRESS */
.scroll-progress { position: fixed; top: 0; left: 0; height: 1px; background: var(--sage); z-index: 2000; width: 0%; transition: width .1s linear; }

/* CURSOR */
.cursor { position: fixed; top: 0; left: 0; width: 7px; height: 7px; background: var(--sage); border-radius: 50%; pointer-events: none; z-index: 9999; transform: translate(-50%,-50%); transition: width .3s, height .3s, opacity .3s; }
.cursor-ring { position: fixed; top: 0; left: 0; width: 32px; height: 32px; border: 1px solid var(--sage); border-radius: 50%; pointer-events: none; z-index: 9998; transform: translate(-50%,-50%); transition: transform .12s, width .3s, height .3s, opacity .3s; opacity: .5; }
.cursor.hover { width: 0; height: 0; opacity: 0; }
.cursor-ring.hover { width: 56px; height: 56px; opacity: .8; }
/* En móvil/tablet táctil no hay ratón: fuera el cursor personalizado */
@media (hover: none), (pointer: coarse) { .cursor, .cursor-ring { display: none !important; } }

/* NAV */
nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; display: flex; align-items: center; justify-content: space-between; padding: 1.6rem 4rem; transition: background .5s, padding .4s, border-color .5s; border-bottom: 1px solid transparent; }
nav.scrolled { background: rgba(250,250,248,.94); backdrop-filter: blur(20px); padding: 1rem 4rem; border-bottom-color: var(--grey-100); }
.nav-logo { display: flex; align-items: center; text-decoration: none; }
.nav-logo img { height: 52px; width: 52px; object-fit: contain; transition: height .3s; filter: invert(1); mix-blend-mode: screen; }
nav.scrolled .nav-logo img { height: 44px; width: 44px; filter: none; mix-blend-mode: multiply; }
.nav-links { display: flex; gap: 2.5rem; list-style: none; }
.nav-links a { font-size: .95rem; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; color: rgba(255,255,255,.65); transition: color .3s; font-weight: 400; }
nav.scrolled .nav-links a { color: var(--grey-400); }
nav.scrolled .nav-links a:hover { color: var(--dark); }
.nav-links a:hover { color: var(--white); }
.nav-cta { position: relative; overflow: hidden; font-size: 1.2rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; color: #0C0C0A; background: #e0b93d; border: 1px solid #e0b93d; padding: .65rem 1.6rem; transition: all .3s; box-shadow: 0 0 0 0 rgba(224,185,61,.5); }
.nav-cta:hover { background: #f0cc55; color: #0C0C0A; border-color: #f0cc55; box-shadow: 0 0 0 4px rgba(224,185,61,.25); }
.nav-cta:active { transform: scale(.96); }
.nav-cta::after { content: ''; position: absolute; inset: 0; border: 1px solid rgba(255,255,255,.7); transform: scaleX(0); transform-origin: left; opacity: 0; pointer-events: none; }
.nav-cta:hover::after { animation: sealSweep .7s var(--ease-out); }
nav.scrolled .nav-cta { color: #0C0C0A; }
.nav-cta { flex-shrink: 0; white-space: nowrap; }
@media (max-width: 1560px) and (min-width: 1025px) {
  nav, nav.scrolled { padding-left: 2rem; padding-right: 2rem; }
  .nav-links { gap: 1.5rem; }
  .nav-links a { font-size: .82rem; letter-spacing: .1em; }
  .nav-cta { font-size: 1rem; padding: .55rem 1.2rem; }
}
@media (max-width: 1240px) and (min-width: 1025px) {
  .nav-links { gap: .95rem; }
  .nav-links a { font-size: .74rem; letter-spacing: .06em; }
  .nav-cta { font-size: .9rem; padding: .5rem .9rem; letter-spacing: .1em; }
}
.nav-hamburger { display: none; }
#mobile-btn { display: none; position: fixed; top: 14px; right: 16px; z-index: 2000; flex-direction: column; gap: 6px; cursor: pointer; padding: 10px; background: rgba(30,30,28,.85); border-radius: 6px; border: none; }
#mobile-btn span { width: 28px; height: 3px; background: #ffffff; display: block; border-radius: 2px; }
@media (max-width: 1024px) { #mobile-btn { display: flex; } }

/* MOBILE MENU */
.mobile-menu { position: fixed; inset: 0; background: var(--white); z-index: 2500; display: flex; flex-direction: column; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s; }
.mobile-menu.open { opacity: 1; visibility: visible; }
.mobile-menu ul { list-style: none; text-align: center; }
.mobile-menu ul li { margin: 1.2rem 0; }
.mobile-menu ul li a { font-family: var(--font-serif); font-size: 2.2rem; font-weight: 300; color: var(--dark); text-decoration: none; letter-spacing: .04em; transition: color .3s; }
.mobile-menu ul li a:hover { color: var(--sage); }
.mobile-close { position: absolute; top: 2rem; right: 2rem; font-size: 1.4rem; color: var(--grey-600); cursor: pointer; background: none; border: none; }

/* HERO */
#hero { min-height: 100vh; position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 10rem 4rem 6rem; text-align: center; }
.hero-bg { position: absolute; inset: 0; background: linear-gradient(160deg, #0e0e0c 0%, #1a1a18 60%, #0c0c0a 100%); }
.hero-bg-rotator { position: absolute; inset: 0; overflow: hidden; }
.hero-bg-slide { position: absolute; inset: 0; background-size: cover; background-position: center; background-repeat: no-repeat; opacity: 0; transform: translateX(1.5%) scale(1.01); transition: opacity 3s ease-in-out, transform 3.4s ease-in-out; filter: grayscale(.3) brightness(.75); }
.hero-bg-slide.is-active { opacity: .55; transform: translateX(0) scale(1.03); }
.hero-overlay { position: absolute; inset: 0; background: rgba(10,10,8,.55); }
.hero-fade { display: none; }
/* Logo centrado */
.hero-logo-wrap { position: relative; z-index: 2; margin-bottom: 3.5rem; animation: logoIn 1.2s var(--ease-out) .6s both; padding: 0; }
.hero-logo-rays { position: absolute; top: 50%; left: 50%; width: 0; height: 0; z-index: 1; pointer-events: none; }
.hero-ray { position: absolute; top: 0; left: 0; height: var(--th); width: var(--len); background: linear-gradient(to right, rgba(255,255,255,.9), rgba(255,255,255,0)); transform-origin: 0 50%; opacity: 0; animation: rayPulse var(--dur) ease-in-out infinite; animation-delay: var(--del); }
@keyframes rayPulse { 0%,100% { opacity: 0; transform: rotate(var(--a)) scaleX(.3); } 50% { opacity: .75; transform: rotate(var(--a)) scaleX(1); } }
.hero-logo-flash { position: absolute; inset: -4%; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.9) 0%, rgba(255,255,255,.35) 22%, rgba(255,255,255,0) 55%); opacity: 0; transform: scale(.3); pointer-events: none; z-index: 1; }
.hero-logo-flash.flash-active { animation: coinFlashBurst .9s ease-out; }
@keyframes coinFlashBurst { 0% { opacity:0; transform:scale(.3); } 18% { opacity:1; transform:scale(1.2); } 45% { opacity:.55; transform:scale(1); } 100% { opacity:0; transform:scale(1.35); } }
.hero-logo-flip { width: 373px; height: 373px; position: relative; perspective: 1000px; cursor: pointer; z-index: 2; -webkit-tap-highlight-color: transparent; }
.hero-logo-flip-inner { position: relative; width: 100%; height: 100%; transition: transform .9s cubic-bezier(.4,.2,.2,1); transform-style: preserve-3d; }
.hero-logo-flip.is-flipped .hero-logo-flip-inner { transform: rotateY(180deg); }
.hero-logo-face { position: absolute; inset: 0; border-radius: 50%; overflow: hidden; backface-visibility: hidden; box-shadow: 0 0 70px 18px rgba(255,255,255,.14); }
.hero-logo-face-back { transform: rotateY(180deg); }
.hero-logo-img { width: 373px; height: 373px; object-fit: contain; display: block; transform: scale(1.32); }
.hero-logo-img-back { filter: invert(1); }
@keyframes logoIn { from{opacity:0;transform:scale(.8) rotate(-8deg)} to{opacity:1;transform:none} }
@keyframes rotateSlow { to{transform:rotate(360deg)} }
/* Línea decorativa bajo el logo */
.hero-divider { position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; gap: 1rem; margin-bottom: 2rem; width: 100%; }
.hero-divider-line { width:40px; flex:none; height:1px; background:rgba(255,255,255,.6); display:block; }
.hero-divider span { font-size:.75rem; letter-spacing:.2em; text-transform:uppercase; color:#ffffff; white-space:nowrap; font-weight:500; text-shadow: 0 1px 8px rgba(0,0,0,.8); }
.hero-content { position: relative; z-index: 2; max-width: 700px; }
.hero-title { font-family: var(--font-serif); font-size: clamp(2.6rem, 5.5vw, 5.2rem); font-weight: 300; line-height: 1.08; color: #ffffff; margin-bottom: 1.6rem; letter-spacing: .02em; text-shadow: 0 2px 20px rgba(0,0,0,.8); }
.hero-nw { white-space: nowrap; }
@media (max-width: 700px) { .hero-divider span.hero-lema { white-space: normal; text-align: center; max-width: 240px; line-height: 1.6; } }
@media (min-width: 701px) { .hero-title { margin-left: -90px; margin-right: -90px; } }
@media (max-width: 700px) { .hero-nw { white-space: normal; } }
.hero-title em { font-style: normal; color: rgba(196,208,195,.9); }
.hero-sub { font-size: 1.2rem; font-weight: 500; color: #ffffff; letter-spacing: .04em; line-height: 1.8; max-width: 440px; margin: 0 auto; text-shadow: 0 1px 16px rgba(0,0,0,.9); }
.hero-actions { margin-top: 3rem; display: flex; gap: 1.8rem; align-items: center; justify-content: center; }
.btn-primary { position: relative; overflow: hidden; font-size: .95rem; letter-spacing: .2em; text-transform: uppercase; text-decoration: none; padding: 1rem 2.8rem; background: var(--sage); color: var(--white); font-weight: 400; transition: all .35s; }
.btn-primary:hover { background: var(--sage-light); color: var(--dark); transform: translateY(-2px); }
.btn-primary:active { transform: scale(.97); }
.btn-primary::after { content: ''; position: absolute; inset: 0; border: 1px solid rgba(255,255,255,.7); transform: scaleX(0); transform-origin: left; opacity: 0; pointer-events: none; }
.btn-primary:hover::after { animation: sealSweep .7s var(--ease-out); }
@keyframes sealSweep { 0% { transform: scaleX(0); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }
.btn-ghost { font-size: .95rem; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; color: rgba(255,255,255,.80); display: flex; align-items: center; gap: .7rem; transition: color .3s; }
.btn-ghost::after { content: '↓'; }
.btn-ghost:hover { color: var(--white); }
/* Datos flotantes en esquinas */
.hero-corner { position: absolute; z-index: 2; animation: fadeUp 1s var(--ease) 2.2s both; }
.hero-corner-bl { bottom: 4rem; left: 4rem; text-align: left; }
.hero-corner-br { bottom: 4rem; right: 4rem; text-align: right; }
.hero-corner-label { font-size: .58rem; letter-spacing: .3em; text-transform: uppercase; color: var(--grey-600); display: block; margin-bottom: .3rem; }
.hero-corner-value { font-family: var(--font-serif); font-size: 1.1rem; font-weight: 300; color: rgba(255,255,255,.55); }
.hero-scroll { position: absolute; bottom: 4rem; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; flex-direction: column; align-items: center; gap: .6rem; animation: fadeUp 1s var(--ease) 2.4s both; }
.hero-scroll-line { width: 1px; height: 50px; background: linear-gradient(to bottom, transparent, var(--sage)); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100%{opacity:.3} 50%{opacity:1} }
@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* SECTIONS */
section { position: relative; }
.section-label { font-size: clamp(1.2rem, .95rem + .7vw, 1.55rem); letter-spacing: .38em; text-transform: uppercase; color: var(--sage); margin-bottom: .5rem; display: flex; align-items: center; gap: .8rem; }
.section-label::before { content: ''; width: 28px; height: 1px; background: var(--sage); }
.section-title { font-family: var(--font-serif); font-size: clamp(2rem, 3.8vw, 3.2rem); font-weight: 300; line-height: 1.1; color: var(--dark); clip-path: inset(0 0 0 0); }
.section-title.pre-reveal { clip-path: inset(0 100% 0 0); transition: clip-path 1.1s var(--ease-out); }
.section-title.pre-reveal.visible { clip-path: inset(0 0 0 0); }
.section-title em { font-style: normal; color: var(--sage); }
.section-body { font-size: 1rem; line-height: 1.95; color: var(--grey-400); font-weight: 400; }

/* PHILOSOPHY */
#philosophy { padding: 5rem 4rem 6rem; display: grid; grid-template-columns: 1fr 1fr; gap: 8rem; align-items: center; background: var(--white); }
.philosophy-left { }
.philosophy-left .section-title { margin-bottom: 2rem; }
.philosophy-left .section-body { margin-bottom: 2rem; }
.philosophy-quote { font-family: var(--font-serif); font-size: 1.3rem; font-weight: 300; font-style: italic; color: var(--grey-600); line-height: 1.6; border-left: 2px solid var(--sage-light); padding-left: 1.5rem; margin: 2.5rem 0; }
.weekly-activity-actions { display: flex; align-items: center; gap: 1.2rem; margin-top: 1rem; flex-wrap: wrap; }
.weekly-activity-video { font: inherit; font-size: .95rem; letter-spacing: .2em; text-transform: uppercase; color: var(--sage); background: none; border: 1px solid rgba(139,158,138,.4); padding: 1rem 1.6rem; cursor: pointer; transition: all .3s; }
.weekly-activity-video:hover { background: var(--sage); color: var(--white); border-color: var(--sage); }
.philosophy-right.weekly-visual { height: 560px; }
.weekly-carousel { position: relative; width: 100%; height: 100%; overflow: hidden; cursor: pointer; }
.weekly-carousel-track { position: absolute; inset: 0; }
.weekly-carousel-slide { position: absolute; inset: 0; overflow: hidden; opacity: 0; transition: opacity 1.4s ease-in-out; }
.weekly-carousel-slide.is-active { opacity: 1; }
.weekly-carousel-slide .wcs-backdrop { position: absolute; inset: -20px; background-size: cover; background-position: center; background-repeat: no-repeat; filter: blur(28px) brightness(.65); transform: scale(1.15); }
.weekly-carousel-slide .wcs-fg { position: absolute; inset: 0; background-size: contain; background-position: center; background-repeat: no-repeat; transform: scale(1.03); transition: transform 6s ease-in-out; }
.weekly-carousel-slide.is-active .wcs-fg { transform: scale(1); }
.weekly-visual-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(10,10,8,.85) 0%, transparent 45%); }
.weekly-visual-tag { position: absolute; left: 1.8rem; bottom: 1.6rem; z-index: 1; font-family: var(--font-serif); font-size: 1.8rem; font-weight: 300; color: var(--white); }

/* INSPIRE STRIP */
.inspire-strip { background: var(--dark); padding: 5rem 4rem; text-align: center; }
.inspire-strip p { font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.4rem); font-weight: 300; font-style: italic; color: rgba(255,255,255,.7); letter-spacing: .02em; line-height: 1.5; }
.inspire-strip p em { color: var(--sage-light); font-style: normal; }

/* TECH */
#tech { padding: 10rem 4rem 5rem; background: var(--warm-white); }
.tech-header { text-align: center; max-width: 600px; margin: 0 auto 6rem; }
.tech-header .section-label { justify-content: center; }
.tech-header .section-label::before { display: none; }
.tech-header .section-title { margin-bottom: 1.5rem; }
.tech-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; background: var(--white); }
.tech-step { position: relative; overflow: hidden; min-height: 380px; display: flex; flex-direction: column; justify-content: flex-end; padding: 2rem 1.6rem; background: var(--white); }
.tech-step-bg { position: absolute; inset: 20px 20px 20px 20px; background-image: var(--bg); background-size: cover; background-position: center 22%; filter: brightness(.72) saturate(1.05); transition: transform .6s var(--ease-out); }
.tech-step:hover .tech-step-bg { transform: scale(1.05); }
.tech-step::after { content: ''; position: absolute; inset: 20px; background: linear-gradient(180deg, rgba(0,0,0,.12) 0%, rgba(0,0,0,.30) 42%, rgba(0,0,0,.66) 74%, rgba(0,0,0,.86) 100%); pointer-events: none; }
.tech-step:nth-child(2) .tech-step-bg { background-position: center center; }
.tech-step:nth-child(4) .tech-step-bg { background-position: 62% 40%; }
.tech-step-num { position: relative; z-index: 2; font-family: var(--font-serif); font-size: 4rem; font-weight: 300; color: rgba(255,255,255,.42); line-height: 1; margin-bottom: 1.5rem; text-shadow: 0 2px 12px rgba(0,0,0,.45); }
.tech-step h3 { position: relative; z-index: 2; font-family: var(--font-serif); font-size: 1.15rem; font-weight: 400; color: #fff; margin-bottom: .8rem; text-shadow: 0 1px 10px rgba(0,0,0,.55); }
.tech-step p { position: relative; z-index: 2; font-size: 1.2rem; line-height: 1.8; color: rgba(255,255,255,.92); font-weight: 400; text-shadow: 0 1px 8px rgba(0,0,0,.6); }
.tech-highlight { margin-top: 6rem; position: relative; overflow: hidden; padding: 3.5rem; background-image: url('/fotoslegio/tech-bg/tech-highlight-bg.jpg'); background-size: cover; background-position: center; }
.tech-highlight::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(250,250,248,.55) 0%, rgba(250,250,248,.72) 100%); pointer-events: none; }
.tech-highlight-grid { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem 2.4rem; }
.tech-highlight-item { background: rgba(250,250,248,.88); padding: 1.8rem 2rem; }
.tech-highlight-item h3 { font-family: var(--font-serif); font-size: 1.1rem; font-weight: 400; color: var(--dark); margin-bottom: .5rem; }
.tech-highlight-item p { font-size: 1.2rem; line-height: 1.8; color: var(--grey-400); font-weight: 400; }

/* ACTIVITIES */
#activities { padding: 2.5rem 4rem 10rem; background: var(--white); }
.activities-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 6rem; }
.activities-header .section-label { margin-bottom: 1.2rem; }
.activities-header .section-title { max-width: 420px; }
.activities-header p { font-size: 1.2rem; line-height: 1.8; color: var(--grey-400); max-width: 280px; text-align: right; }
.activities-group-label { font-size: clamp(1.2rem, .95rem + .85vw, 1.7rem); letter-spacing: .34em; text-transform: uppercase; color: var(--grey-400); margin-bottom: 1.6rem; padding-bottom: 1rem; border-bottom: 1px solid var(--grey-100); }
.activities-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; margin-bottom: 6rem; }
.activities-grid.three { grid-template-columns: repeat(3, 1fr); }
.activities-grid.five { grid-template-columns: repeat(5, 1fr); }
.activity-card { position: relative; overflow: hidden; cursor: pointer; aspect-ratio: 3/4; background: var(--cream); transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out); }
.activity-card:hover { transform: translateY(-6px); box-shadow: 0 20px 34px -16px rgba(10,10,8,.45); z-index: 2; }
.activity-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.activity-card:hover img { transform: scale(1.06); }
.activity-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(10,10,8,.92) 0%, rgba(10,10,8,.1) 60%, transparent 100%); transition: background .4s; }
.activity-card:hover .activity-overlay { background: linear-gradient(to top, rgba(10,10,8,.96) 0%, rgba(10,10,8,.2) 60%, transparent 100%); }
.activity-content { position: absolute; bottom: 0; left: 0; right: 0; padding: 2rem 1.8rem; transform: translateY(8px); transition: transform .4s var(--ease); }
.activity-card:hover .activity-content { transform: none; }
.activity-num { font-size: .58rem; letter-spacing: .3em; color: var(--sage-light); text-transform: uppercase; margin-bottom: .5rem; display: block; }
.activity-name { font-family: var(--font-serif); font-size: 1.35rem; font-weight: 300; color: var(--white); line-height: 1.1; margin-bottom: .5rem; }
.activity-desc { font-size: 1.2rem; color: rgba(255,255,255,.45); line-height: 1.6; max-height: 0; overflow: hidden; transition: max-height .4s var(--ease), opacity .3s; opacity: 0; }
.activity-card:hover .activity-desc { max-height: 80px; opacity: 1; }
.activity-tag { display: inline-block; font-size: .6rem; letter-spacing: .18em; text-transform: uppercase; border: 1px solid rgba(196,208,195,.4); color: var(--sage-light); padding: .3rem .8rem; margin-top: .8rem; opacity: 0; transition: opacity .3s .1s; }
.activity-card:hover .activity-tag { opacity: 1; }

/* SCHEDULE */
#schedule { padding: 10rem 4rem; background: var(--warm-white); }
.schedule-header { text-align: center; max-width: 560px; margin: 0 auto 5rem; }
.schedule-header .section-label { justify-content: center; }
.schedule-header .section-label::before { display: none; }
.schedule-header .section-title { margin-bottom: 1.2rem; }
.schedule-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.schedule-day { background: var(--white); }
.schedule-day-header { background: var(--dark); padding: 1.2rem 1.5rem; }
.schedule-day-name { font-family: var(--font-serif); font-size: 1rem; font-weight: 300; color: var(--white); }
.schedule-day-sub { font-size: 1.2rem; letter-spacing: .18em; text-transform: uppercase; color: var(--sage-light); margin-top: .2rem; }
.schedule-slots { padding: .8rem; display: flex; flex-direction: column; gap: .4rem; min-height: 320px; }
.schedule-slot { padding: .8rem 1rem; border-left: 3px solid; opacity: 0; transform: translateY(22px) scale(.9); transition: opacity .55s var(--ease-out), transform .55s var(--ease-out); }
.schedule-grid.visible .schedule-slot { opacity: 1; transform: none; }
.schedule-grid.reveal { transition-duration: .25s; }
.schedule-slot-time { font-size: .6rem; letter-spacing: .12em; color: var(--grey-600); text-transform: uppercase; margin-bottom: .3rem; }
/* Colores por actividad */
.s-mma       { background: #FFCACA; border-left-color: #D44040; }
.s-grappling { background: #C8DAFF; border-left-color: #3D65C4; }
.s-jiujitsu  { background: #C2EDD6; border-left-color: #2E9A60; }
.s-judo      { background: #DDD0FF; border-left-color: #6A44CC; }
.s-k1        { background: #FFE0B0; border-left-color: #D4820A; }
.s-boxeo     { background: #FFD0C0; border-left-color: #C04A28; }
.s-fullbody  { background: #D4CEFF; border-left-color: #5548B8; }
.s-silat     { background: #C4E0CA; border-left-color: #2E7040; }
.s-kids      { background: #FFE5C8; border-left-color: #D47820; }
.s-openmat   { background: #C2E4FF; border-left-color: #2878B8; }
.s-special   { background: #E0E0E0; border-left-color: #888888; border-left-style: dashed; }
.schedule-slot-name { font-size: 1rem; font-weight: 500; color: var(--dark); line-height: 1.3; }
.schedule-slot-time { font-size: 1.2rem; letter-spacing: .1em; color: var(--grey-400); text-transform: uppercase; margin-bottom: .3rem; font-weight: 500; }
.schedule-slot-name { font-size: 1.2rem; font-weight: 500; color: var(--dark); line-height: 1.3; }
.schedule-legend { display: flex; gap: 2rem; margin-top: 2rem; justify-content: center; }
.legend-item { display: flex; align-items: center; gap: .6rem; font-size: .95rem; color: var(--grey-400); letter-spacing: .08em; }
.legend-dot { width: 10px; height: 10px; border-radius: 50%; }
.legend-dot.adult { background: var(--sage-light); }
.legend-dot.kids { background: #C4A882; }
.legend-dot.special { background: var(--grey-400); }

/* GALLERY MODAL */
#activityModal { position: fixed; inset: 0; background: rgba(10,10,8,.97); z-index: 6000; display: flex; flex-direction: column; opacity: 0; visibility: hidden; transform: scale(.94); transform-origin: 50% 50%; transition: opacity .4s, visibility .4s, transform .45s var(--ease-out); overflow-y: auto; }
#activityModal.open { opacity: 1; visibility: visible; transform: scale(1); }
.activity-modal-header { display: flex; justify-content: space-between; align-items: center; padding: 2.5rem 4rem; border-bottom: 1px solid rgba(255,255,255,.07); position: sticky; top: 0; background: rgba(10,10,8,.97); z-index: 10; }
.activity-modal-title { font-family: var(--font-serif); font-size: 2rem; font-weight: 300; color: var(--white); }
.activity-modal-title span { color: var(--sage-light); font-style: normal; }
.activity-modal-desc { font-size: 1.2rem; color: rgba(255,255,255,.75); margin-top: .4rem; max-width: 500px; line-height: 1.7; }
.activity-modal-close { color: var(--white); font-size: 1.6rem; cursor: pointer; background: none; border: none; opacity: .5; transition: opacity .3s; }
.activity-modal-close:hover { opacity: 1; }
.activity-modal-body { padding: 3rem 4rem; display: grid; grid-template-columns: repeat(3,1fr); gap: 4px; }
.activity-modal-img { overflow: hidden; aspect-ratio: 1; cursor: pointer; }
.activity-modal-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); filter: grayscale(10%); }
.activity-modal-img:hover img { transform: scale(1.05); filter: grayscale(0); }

/* LIGHTBOX */
#lightbox { position: fixed; inset: 0; background: rgba(10,10,8,.98); z-index: 7000; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s; }
#lightbox.open { opacity: 1; visibility: visible; }
.lightbox-img { max-width: 88vw; max-height: 85vh; object-fit: contain; }
.lightbox-close { position: absolute; top: 2rem; right: 2rem; color: var(--white); font-size: 1.8rem; cursor: pointer; background: none; border: none; opacity: .5; transition: opacity .3s; }
.lightbox-close:hover { opacity: 1; }

/* VIDEO LIGHTBOX */
#videoLightbox { position: fixed; inset: 0; background: rgba(6,6,5,.97); z-index: 7500; display: flex; align-items: center; justify-content: center; padding: 2rem; opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s; }
#videoLightbox.open { opacity: 1; visibility: visible; }
#videoLightbox video { max-width: 92vw; max-height: 86vh; width: auto; height: auto; background: #000; box-shadow: 0 20px 60px rgba(0,0,0,.6); }
.vlightbox-close { position: absolute; top: 1.6rem; right: 1.6rem; width: 46px; height: 46px; border-radius: 50%; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.2); color: var(--white); font-size: 1.3rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background .25s; }
.vlightbox-close:hover { background: rgba(255,255,255,.2); }
.video-card { cursor: pointer; }

#chatbotToggle { position: fixed; right: 1.6rem; bottom: 1.6rem; width: 56px; height: 56px; border-radius: 50%; background: var(--black); color: #fff; border: 1px solid rgba(255,255,255,.15); cursor: pointer; z-index: 8000; box-shadow: 0 4px 16px rgba(0,0,0,.4); display: flex; align-items: center; justify-content: center; transition: transform .2s, background .2s; }
#chatbotToggle:hover { transform: translateY(-2px); background: var(--dark); }
#chatbotPanel { position: fixed; right: 1.6rem; bottom: 5.6rem; width: min(340px, calc(100vw - 3.2rem)); max-height: min(480px, calc(100vh - 8rem)); background: var(--dark); border: 1px solid rgba(255,255,255,.1); border-radius: 12px; box-shadow: 0 8px 32px rgba(0,0,0,.5); display: flex; flex-direction: column; overflow: hidden; z-index: 8000; opacity: 0; visibility: hidden; transform: translateY(12px); transition: opacity .25s, visibility .25s, transform .25s; }
#chatbotPanel.open { opacity: 1; visibility: visible; transform: translateY(0); }

/* ALTA FAB (burbuja flotante "Darme de alta") */
#altaToggle { position: fixed; left: 1.6rem; bottom: 1.6rem; height: 52px; padding: 0 1.3rem 0 1.1rem; border-radius: 30px; background: var(--sage); color: #fff; border: none; cursor: pointer; z-index: 8000; box-shadow: 0 4px 16px rgba(0,0,0,.35); display: flex; align-items: center; gap: .55rem; font-size: .85rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; transition: transform .2s, background .2s; }
#altaToggle:hover { transform: translateY(-2px); background: #e0b93d; color: var(--dark); }
#altaToggle svg { width: 20px; height: 20px; flex-shrink: 0; }
#altaPanel { position: fixed; left: 1.6rem; bottom: 5.4rem; width: min(280px, calc(100vw - 3.2rem)); background: var(--dark); border: 1px solid rgba(255,255,255,.1); border-radius: 12px; box-shadow: 0 8px 32px rgba(0,0,0,.5); padding: 1.3rem; z-index: 8000; opacity: 0; visibility: hidden; transform: translateY(12px); transition: opacity .25s, visibility .25s, transform .25s; }
#altaPanel.open { opacity: 1; visibility: visible; transform: translateY(0); }
#altaPanel h4 { color: #fff; font-size: 1rem; margin-bottom: .3rem; font-weight: 600; }
#altaPanel p { color: rgba(255,255,255,.65); font-size: .85rem; line-height: 1.5; margin-bottom: 1rem; }
#altaPanel .app-badges-row { flex-direction: column; }
#altaPanel .app-badge { justify-content: center; }
@media (max-width: 1024px) { #altaToggle { bottom: 5.6rem; } #altaPanel { bottom: 9.4rem; } }
.chatbot-header { background: var(--black); color: var(--white); padding: .9rem 1.1rem; display: flex; justify-content: space-between; align-items: center; font-size: .85rem; letter-spacing: .04em; border-bottom: 1px solid rgba(255,255,255,.08); }
.chatbot-close { background: none; border: none; color: var(--white); opacity: .6; cursor: pointer; font-size: 1rem; }
.chatbot-close:hover { opacity: 1; }
.chatbot-messages { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: .6rem; font-size: .82rem; line-height: 1.5; background: var(--dark); }
.chatbot-msg { padding: .6rem .8rem; border-radius: 10px; max-width: 85%; white-space: pre-wrap; }
.chatbot-msg-bot { background: var(--grey-800); color: var(--white); align-self: flex-start; }
.chatbot-msg-user { background: var(--sage-light); color: var(--black); align-self: flex-end; }
.chatbot-msg-error { background: #3a2222; color: #f0bcbc; align-self: flex-start; }
.chatbot-messages a { color: var(--sage-light); }
.chatbot-msg-user a { color: var(--black); }
.chatbot-form { display: flex; border-top: 1px solid rgba(255,255,255,.1); }
.chatbot-form input { flex: 1; border: none; padding: .8rem 1rem; font-size: .82rem; outline: none; background: var(--grey-800); color: var(--white); }
.chatbot-form input::placeholder { color: rgba(255,255,255,.4); }
.chatbot-form button { background: var(--sage); color: var(--white); border: none; width: 46px; cursor: pointer; font-size: 1rem; }
.chatbot-form button:disabled { opacity: .5; cursor: not-allowed; }

/* INSTALACIONES — carrusel con fundido */
#space { padding: 5rem 4rem 14rem; background: var(--warm-white); }
.space-header { text-align: center; max-width: 620px; margin: 0 auto 4rem; }
.space-header .section-label { justify-content: center; }
.space-header .section-label::before { display: none; }
.space-header .section-title { margin-bottom: .9rem; }
.space-slider { position: relative; max-width: 1280px; margin: 0 auto; aspect-ratio: 16/9; overflow: hidden; background: var(--cream); box-shadow: 0 30px 80px rgba(0,0,0,.14); }
.space-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s var(--ease); }
.space-slide.active { opacity: 1; }
.space-slide img { width: 100%; height: 100%; object-fit: cover; }
.space-frame { position: absolute; inset: 0; box-shadow: inset 0 0 120px rgba(10,10,8,.35); pointer-events: none; }
/* Flechas para pasar fotos a mano */
.space-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 4; width: 52px; height: 52px;
             display: flex; align-items: center; justify-content: center; padding: 0;
             background: rgba(12,12,10,.42); backdrop-filter: blur(6px); border: 1px solid rgba(255,255,255,.25);
             color: #fff; font-family: var(--font-sans); font-size: 1.5rem; font-weight: 400; line-height: 1;
             cursor: pointer; opacity: .8; transition: background .3s, opacity .3s, border-color .3s; }
.space-nav:hover { background: rgba(12,12,10,.85); border-color: rgba(255,255,255,.5); opacity: 1; }
.space-prev { left: 1.2rem; }
.space-next { right: 1.2rem; }
.space-slider { touch-action: pan-y; }
.space-counter { position: absolute; right: 1.2rem; bottom: 1.1rem; z-index: 4; font-size: .72rem; letter-spacing: .16em;
                 color: rgba(255,255,255,.85); background: rgba(12,12,10,.45); backdrop-filter: blur(6px);
                 padding: .35rem .7rem; pointer-events: none; }
@media (max-width: 640px) {
  .space-nav { width: 42px; height: 42px; font-size: 1.2rem; }
  .space-prev { left: .6rem; }
  .space-next { right: .6rem; }
  .space-counter { right: .6rem; bottom: .6rem; font-size: .65rem; }
}
.space-dots { display: flex; gap: .4rem; justify-content: center; margin-top: 1.8rem; flex-wrap: wrap; }
.space-dot { width: 24px; height: 24px; border-radius: 50%; background: none; border: none; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; -webkit-tap-highlight-color: transparent; }
.space-dot::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: var(--grey-200); transition: background .35s, transform .35s; }
.space-dot:hover::before { background: var(--sage-light); }
.space-dot.active::before { background: var(--sage); transform: scale(1.35); }

/* HERO VIDEO DE FONDO */
.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .30; mix-blend-mode: luminosity; z-index: 0; }

/* VIDEOS — galería dinámica tipo reels */
#weights { padding-bottom: 2.5rem; }
#videos { padding: 6rem 4rem 6rem; background: var(--dark); position: relative; overflow: hidden; }
.videos-header { text-align: center; max-width: 620px; margin: 0 auto 5rem; }
.videos-header .section-label { justify-content: center; color: var(--sage-light); }
.videos-header .section-label::before { display: none; }
.videos-header .section-title { color: var(--white); margin-bottom: 1.2rem; }
.videos-header .section-title em { color: var(--sage-light); }
.videos-header p { font-size: 1rem; line-height: 1.9; color: rgba(255,255,255,.65); }
.videos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; max-width: 1100px; margin: 0 auto; }
.video-card { position: relative; aspect-ratio: 9/16; overflow: hidden; background: var(--black); border: 1px solid rgba(255,255,255,.08); transition: transform .6s var(--ease-out), border-color .4s, box-shadow .6s; }
.video-card-wide { aspect-ratio: 1080/608; max-width: 900px; margin: 2rem auto 0; }
.video-card-wide video { object-fit: cover; }
.video-card:hover { transform: translateY(-8px); border-color: rgba(139,158,138,.5); box-shadow: 0 24px 60px rgba(0,0,0,.55); }
.video-card video { width: 100%; height: 100%; object-fit: cover; display: block; filter: grayscale(18%); transition: filter .6s; }
.video-card:hover video { filter: grayscale(0); }
.video-shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(10,10,8,.85) 0%, rgba(10,10,8,.05) 55%, transparent 100%); pointer-events: none; transition: background .5s; }
.video-card:hover .video-shade { background: linear-gradient(to top, rgba(10,10,8,.7) 0%, transparent 60%); }
.video-meta { position: absolute; left: 0; right: 0; bottom: 0; padding: 1.6rem 1.4rem; pointer-events: none; }
.video-meta .v-num { font-size: .58rem; letter-spacing: .3em; text-transform: uppercase; color: var(--sage-light); display: block; margin-bottom: .4rem; }
.video-meta .v-name { font-family: var(--font-serif); font-size: 1.4rem; font-weight: 300; color: var(--white); letter-spacing: .03em; }
.video-meta .v-desc { font-size: .85rem; color: rgba(255,255,255,.6); line-height: 1.6; margin-top: .4rem; max-height: 0; overflow: hidden; opacity: 0; transition: max-height .5s var(--ease), opacity .4s; }
.video-card:hover .v-desc { max-height: 60px; opacity: 1; }

/* CONTACT */
#contact { padding: 6rem 4rem 10rem; background: var(--white); display: grid; grid-template-columns: 1fr 1fr; gap: 8rem; align-items: center; }
.contact-text .section-title { margin-bottom: 1.5rem; }
.contact-text .section-body { margin-bottom: 3rem; }
.contact-info { display: flex; flex-direction: column; gap: 1.2rem; }
.contact-info-item { display: flex; gap: 1.5rem; align-items: flex-start; border-top: 1px solid var(--grey-100); padding-top: 1.2rem; }
.contact-info-label { font-size: 1.2rem; letter-spacing: .22em; text-transform: uppercase; color: var(--sage); min-width: 80px; margin-top: .15rem; }
.contact-info-value { font-size: 1rem; color: var(--grey-600); line-height: 1.6; font-weight: 400; }
.contact-info-value a { color: inherit; text-decoration: none; transition: color .3s; }
.contact-info-value a:hover { color: var(--sage); }
.app-badge { display: inline-flex; align-items: center; gap: .5rem; padding: .6rem 1.1rem; border: 1.5px solid var(--sage); border-radius: 8px; color: var(--sage); font-weight: 600; letter-spacing: .03em; text-decoration: none; font-size: 1rem; transition: background .3s, color .3s; }
.app-badge:hover { background: var(--sage); color: #fff; }
.app-badges-row { display: flex; gap: .8rem; flex-wrap: wrap; }
.app-badge-light { font-size: .82rem; padding: .45rem .85rem; border-color: rgba(255,255,255,.75); color: #fff; text-shadow: none; }
.app-badge-light:hover { background: #fff; color: var(--dark); }
.tech-step .app-badges-row { position: relative; z-index: 2; margin-top: .9rem; justify-content: center; width: 100%; }
.contact-form-side { }
.form-group { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1.2rem; }
.form-group label { font-size: 1.2rem; letter-spacing: .14em; text-transform: uppercase; color: var(--grey-400); font-weight: 500; }
.form-group input, .form-group select, .form-group textarea { border: 1px solid var(--grey-200); background: var(--warm-white); padding: .9rem 1rem; font-family: var(--font-sans); font-size: 1.2rem; font-weight: 300; color: var(--dark); outline: none; transition: border-color .3s; resize: none; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--sage); background: var(--white); }
.form-group textarea { height: 120px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-submit { width: 100%; padding: 1.1rem; background: var(--dark); color: var(--white); border: none; font-family: var(--font-sans); font-size: .95rem; letter-spacing: .22em; text-transform: uppercase; cursor: pointer; transition: background .3s; margin-top: .5rem; }
.form-submit:hover { background: var(--sage); }

/* FOOTER */
footer { background: var(--dark); padding: 5rem 4rem 3rem; }
.footer-top { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 5rem; margin-bottom: 4rem; }
.footer-logo { font-family: var(--font-serif); font-size: 1.8rem; font-weight: 300; letter-spacing: .28em; color: var(--white); margin-bottom: 1.2rem; }
.footer-brand p { font-size: 1.2rem; color: rgba(255,255,255,.80); line-height: 1.8; max-width: 240px; }
.footer-col h3 { font-size: 1.2rem; letter-spacing: .28em; text-transform: uppercase; color: var(--sage-light); margin-bottom: 1.4rem; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: .8rem; }
.footer-col ul li a { font-size: 1.2rem; color: rgba(255,255,255,.80); text-decoration: none; transition: color .3s; }
.footer-col ul li a:hover { color: var(--white); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.06); padding-top: 2rem; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem 2rem; }
.footer-bottom > p:first-child { font-size: 1.2rem; color: rgba(255,255,255,.75); letter-spacing: .07em; }
.footer-legal { flex-basis: 100%; order: 3; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.5); }
.footer-legal a, .footer-legal span { color: rgba(255,255,255,.6); text-decoration: none; transition: color .3s; }
.footer-legal a:hover { color: var(--sage-light); }
.footer-credit { flex-basis: 100%; order: 4; font-size: .72rem; letter-spacing: .06em; color: rgba(255,255,255,.58); }
.footer-socials { display: flex; gap: 1.5rem; order: 2; }
.footer-socials a { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.80); text-decoration: none; transition: color .3s; }
.footer-socials a:hover { color: var(--sage-light); }
/* NEWSLETTER (suscripción con doble confirmación, newsletter.php) */
.nl-box { border-top: 1px solid rgba(255,255,255,.06); padding: 2.6rem 0 2.8rem; display: grid; grid-template-columns: 1fr 1.3fr; gap: 3rem; align-items: start; }
.nl-box h3 { font-family: var(--font-serif); font-size: 2rem; letter-spacing: .08em; color: var(--white); margin-bottom: .6rem; font-weight: 400; }
.nl-box > div > p { font-size: 1.1rem; color: rgba(255,255,255,.75); line-height: 1.6; }
.nl-form { display: flex; flex-direction: column; gap: .9rem; }
.nl-fila { display: flex; gap: .6rem; }
.nl-fila input[type=email] { flex: 1; min-width: 0; padding: .95rem 1rem; background: transparent; border: 1px solid rgba(255,255,255,.25); color: var(--white); font-family: var(--font-sans); font-size: 1.05rem; }
.nl-fila input[type=email]::placeholder { color: rgba(255,255,255,.45); }
.nl-fila button { padding: .95rem 1.4rem; background: var(--white); color: var(--black); border: none; font-family: var(--font-sans); font-size: .9rem; letter-spacing: .2em; text-transform: uppercase; cursor: pointer; transition: background .3s; white-space: nowrap; }
.nl-fila button:hover { background: var(--sand); }
.nl-acepto { display: flex; gap: .7rem; align-items: flex-start; font-size: .95rem; color: rgba(255,255,255,.72); line-height: 1.5; }
.nl-acepto input { margin-top: .3rem; flex-shrink: 0; width: 18px; height: 18px; }
.nl-acepto a { color: var(--sage-light); }
.nl-msg { font-size: 1rem; display: none; }
@media (max-width: 900px) { .nl-box { grid-template-columns: 1fr; gap: 1.6rem; } }
@media (max-width: 480px) { .nl-fila { flex-direction: column; } }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(36px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.reveal.visible { opacity: 1; transform: none; }
.reveal-left { opacity: 0; transform: translateX(-36px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.reveal-left.visible { opacity: 1; transform: none; }
.reveal-right { opacity: 0; transform: translateX(36px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.reveal-right.visible { opacity: 1; transform: none; }
[data-delay="1"] { transition-delay: .1s !important; }
[data-delay="2"] { transition-delay: .2s !important; }
[data-delay="3"] { transition-delay: .3s !important; }
[data-delay="4"] { transition-delay: .4s !important; }

@media (prefers-reduced-motion: reduce) {
  .section-title { clip-path: inset(0 0 0 0) !important; transition: none !important; }
  .activity-card, .activity-card:hover, .activity-card img { transition: none !important; transform: none !important; }
  #activityModal { transform: none !important; transition: opacity .2s, visibility .2s !important; }
  .hero-bg-slide { transition: opacity .2s !important; transform: none !important; }
  .schedule-slot { transition: none !important; opacity: 1 !important; transform: none !important; }
  .nav-cta::after, .btn-primary::after { display: none !important; }
  .nav-cta:active, .btn-primary:active { transform: none !important; }
}

/* RESPONSIVE */
@media (max-width: 1024px) {
  nav { display: none; }
  #mobile-btn { display: flex; }
  #hero, #philosophy, #tech, #space, #activities, #schedule, #videos, #contact, footer { padding-left: 2rem; padding-right: 2rem; }
  #space { padding-top: 6rem; padding-bottom: 6rem; }
  .space-slider { aspect-ratio: 4/3; }
  #videos { padding-top: 6rem; padding-bottom: 6rem; }
  .videos-grid { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
  #philosophy { grid-template-columns: 1fr; gap: 4rem; }
  .philosophy-right { grid-template-columns: 1fr 1fr; }
  .tech-steps { grid-template-columns: 1fr 1fr; }
  .tech-highlight-grid { grid-template-columns: 1fr; }
  .activities-grid { grid-template-columns: repeat(2, 1fr); }
  .activities-grid.three { grid-template-columns: repeat(2, 1fr); }
  .activities-grid.five { grid-template-columns: repeat(2, 1fr); }
  .activities-header { flex-direction: column; gap: 2rem; }
  .activities-header p { text-align: left; }
  .schedule-grid { grid-template-columns: 1fr 1fr; }
  #contact { grid-template-columns: 1fr; gap: 5rem; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 3rem; }
  .activity-modal-body { grid-template-columns: repeat(2,1fr); padding: 2rem; }
  .activity-modal-header { padding: 1.5rem 2rem; }
}
@media (max-width: 640px) {
  #hero { height: auto; min-height: 100vh; padding-top: 80px; padding-bottom: 3rem; justify-content: flex-start; padding-left: 1rem; padding-right: 1rem; }
  .hero-actions { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 1rem; }
  .hero-divider-line { display: block; width: 24px; }
  .hero-divider span { font-size: .65rem; letter-spacing: .15em; }
  .reveal, .reveal-left, .reveal-right, .schedule-slot { opacity: 1 !important; transform: none !important; }
  .section-title { clip-path: inset(0 0 0 0) !important; }
  p, h1, h2, h3, h4, h5, li, span, a { word-break: break-word; overflow-wrap: break-word; }
  img { max-width: 100%; height: auto; display: block; }
  .schedule-grid { grid-template-columns: 1fr; }
  #tech { padding: 4rem 1.2rem; }
  .tech-header { margin-bottom: 2.5rem; }
  .tech-steps { grid-template-columns: 1fr; }
  .tech-step { min-height: 260px; }
  .tech-highlight { margin-top: 2.5rem; }
  .tech-step-bg { inset: 12px; }
  .tech-step::after { inset: 12px; }
  .tech-highlight { background-image: none !important; padding: 0; }
  .tech-highlight::before { content: ''; display: block; width: 100%; height: 160px; background-image: url('/fotoslegio/tech-bg/tech-highlight-bg.jpg'); background-size: cover; background-position: center; }
  .tech-highlight::after { display: none; }
  .tech-highlight-grid { position: static; grid-template-columns: 1fr; gap: 2px; padding: 0; }
  .tech-highlight-item { background: var(--white); padding: 1.4rem 1.2rem; }
  .philosophy-right.weekly-visual { height: 340px; }
  #philosophy, #tech, #space, #activities, #schedule, #videos, #contact, footer { padding-left: 1.2rem; padding-right: 1.2rem; }
  .space-slider { aspect-ratio: 3/4; max-width: 380px; }
  .videos-grid { grid-template-columns: 1fr; max-width: 380px; }
  .video-card .v-desc { max-height: 60px; opacity: 1; }
  .hero-corner { display: none; }
  .hero-bg-slide.slide-guerrero { background-position: 20% center !important; background-size: cover !important; background-repeat: no-repeat !important; }
  .hero-actions { display: flex; flex-direction: column; align-items: center; gap: 1rem; width: 100%; }
  .hero-logo-wrap { margin-left: auto; margin-right: auto; display: flex; justify-content: center; margin-top: 0; }
  .hero-logo-flip { width: 213px; height: 213px; }
  .hero-logo-face { box-shadow: 0 0 40px 10px rgba(255,255,255,.14); }
  .hero-logo-img { width: 213px; height: 213px; }
  .hero-title { font-size: 2.8rem; }
  .tech-steps { grid-template-columns: 1fr; }
  .activities-grid { grid-template-columns: 1fr; }
  .activities-grid.three, .activities-grid.five { grid-template-columns: 1fr; }
  .schedule-grid { grid-template-columns: 1fr; }
  .philosophy-right { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .activity-modal-body { grid-template-columns: 1fr; }
}

/* COOKIE BANNER */
.cookie-banner { position: fixed; left: 1.2rem; right: 1.2rem; bottom: 1.2rem; z-index: 4000;
  max-width: 640px; margin: 0 auto; background: var(--dark); border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px; padding: 1.4rem 1.5rem; box-shadow: 0 20px 60px rgba(0,0,0,.5);
  font-family: var(--font-sans); color: rgba(255,255,255,.82); font-weight: 300;
  transform: translateY(140%); transition: transform .45s var(--ease); }
.cookie-banner.show { transform: translateY(0); }
.cookie-banner h3 { font-family: var(--font-serif); font-weight: 300; font-size: 1.3rem; letter-spacing: .04em; color: var(--white); margin-bottom: .35rem; }
.cookie-banner p { font-size: .92rem; line-height: 1.6; margin-bottom: 1rem; }
.cookie-banner a { color: var(--sage-light); }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.cookie-actions button { font-family: var(--font-sans); font-weight: 500; font-size: .78rem; letter-spacing: .12em;
  text-transform: uppercase; padding: .6rem 1.1rem; border-radius: 6px; cursor: pointer; border: 1px solid rgba(255,255,255,.2); background: transparent; color: var(--white); transition: background .25s, border-color .25s; }
.cookie-actions button:hover { border-color: rgba(255,255,255,.5); }
.cookie-actions .cookie-accept { background: var(--white); color: var(--black); border-color: var(--white); }
.cookie-actions .cookie-accept:hover { background: var(--cream); }
.cookie-actions .cookie-config { margin-left: auto; border: none; text-decoration: underline; padding: .6rem .3rem; color: rgba(255,255,255,.6); }
.cookie-prefs { display: none; margin: .2rem 0 1rem; padding: .8rem 0 0; border-top: 1px solid rgba(255,255,255,.1); }
.cookie-prefs.open { display: block; }
.cookie-prefs label { display: flex; align-items: center; gap: .7rem; font-size: .88rem; padding: .4rem 0; }
.cookie-prefs input { accent-color: var(--sage-light); width: 16px; height: 16px; }
.cookie-prefs label span.desc { color: rgba(255,255,255,.55); font-size: .82rem; }
@media (max-width: 520px) {
  .cookie-actions { flex-direction: column; align-items: stretch; }
  .cookie-actions button { width: 100%; }
  .cookie-actions .cookie-config { margin-left: 0; }
}

/* ---- Antes atributos style="" en el HTML (sacados por la CSP: style-src 'self') ---- */
.mobile-menu ul li a.ci-1 { color:var(--sage); }
.ci-2 { --a:5deg; --len:275px; --th:3.2px; --dur:4.5s; --del:0s; }
.ci-3 { --a:32deg; --len:105px; --th:5.6px; --dur:3.2s; --del:.6s; }
.ci-4 { --a:58deg; --len:195px; --th:2.4px; --dur:6s; --del:1.3s; }
.ci-5 { --a:79deg; --len:310px; --th:4px; --dur:3.8s; --del:.2s; }
.ci-6 { --a:108deg; --len:80px; --th:6.4px; --dur:5.1s; --del:2.1s; }
.ci-7 { --a:135deg; --len:250px; --th:1.6px; --dur:4s; --del:.9s; }
.ci-8 { --a:160deg; --len:145px; --th:4.8px; --dur:6.5s; --del:1.7s; }
.ci-9 { --a:190deg; --len:340px; --th:3.2px; --dur:3.5s; --del:0s; }
.ci-10 { --a:214deg; --len:120px; --th:2.4px; --dur:5.8s; --del:.4s; }
.ci-11 { --a:242deg; --len:220px; --th:5.6px; --dur:4.3s; --del:2.6s; }
.ci-12 { --a:268deg; --len:65px; --th:4px; --dur:3s; --del:1.1s; }
.ci-13 { --a:305deg; --len:285px; --th:1.6px; --dur:5.5s; --del:.3s; }
.ci-14 { background: var(--dark); padding: 2.5rem 4rem; display: flex; align-items: center; justify-content: center; gap: 1.5rem; }
.ci-15 { flex:1; height:1px; background: linear-gradient(to right, transparent, rgba(139,158,138,.5)); }
.ci-16 { font-family:'Bebas Neue',sans-serif; font-size:1.15rem; letter-spacing:.5em; color:rgba(139,158,138,.85); white-space:nowrap; }
.ci-17 { flex:1; height:1px; background: linear-gradient(to left, transparent, rgba(139,158,138,.5)); }
.ci-18 { margin-top:1.2rem; }
.ci-19 { --bg:url('/fotoslegio/tech-bg/tech-bg-01.jpg'); }
.ci-20 { --bg:url('/fotoslegio/tech-bg/tech-bg-02.jpg'); }
.ci-21 { --bg:url('/fotoslegio/tech-bg/tech-bg-03.jpg'); }
.ci-22 { --bg:url('/fotoslegio/tech-bg/tech-bg-04.jpg'); }
.ci-23 { color:var(--grey-600); text-decoration:underline; }
.ci-24 { text-align:center; margin-top:5rem; font-family:var(--font-serif); font-size:clamp(1.3rem,2.4vw,2rem); font-weight:300; color:var(--grey-600); line-height:1.6; letter-spacing:.02em; }
.ci-25 { font-style:normal; color:var(--sage); }
.ci-26 { margin-top:2px; }
.ci-27 { margin-top:5rem; }
.ci-28 { margin-top:1rem; }
.ci-29 { max-width:1200px; margin:2.5rem auto 0; padding:0 1rem; }
.ci-30 { width:100%; height:auto; display:block; border-radius:20px; box-shadow:0 20px 50px -20px rgba(0,0,0,.35); }
.ci-31 { position:absolute; left:-9999px; }
.ci-32 { display:none; margin-bottom:12px; font-size:14px; }
.ci-33 { height:80px; width:auto; object-fit:contain; filter:invert(1); mix-blend-mode:screen; opacity:.85; margin-bottom:1.4rem; display:block; }
/* #cookieSaveBtn: oculto hasta abrir preferencias (antes style="display:none").
   index-3.js pone style.display='' al abrir y 'none' al cerrar: con el panel abierto manda la 2.ª regla. */
#cookieSaveBtn { display: none; }
#cookiePrefs.open ~ .cookie-actions #cookieSaveBtn { display: inline-block; }
