/* Shatterfall web. Tres estilos en prueba, en <html data-style="…">:
   synthwave (el del logo, recomendado), cine (sobrio y oscuro) y hud (interfaz de recreativa). */

:root {
  --bg: #0b0618;
  --bg-2: #140a2b;
  --panel: rgba(28, 14, 58, 0.72);
  --text: #f3eefe;
  --muted: #b9acd9;
  --accent: #ff2fb4;
  --accent-2: #22e6ff;
  --sun: linear-gradient(180deg, #ffe45c 0%, #ff8a3d 45%, #ff2fb4 100%);
  --line: rgba(255, 47, 180, 0.35);
  --glow: 0 0 18px rgba(255, 47, 180, 0.55), 0 0 42px rgba(34, 230, 255, 0.25);
  --radius: 14px;
  --font-head: "Crivon", "Orbitron", system-ui, sans-serif;
  --font-body: "Exo 2", system-ui, sans-serif;
  --head-weight: 900;
  --head-case: uppercase;
  --head-spacing: 0.02em;
  --clip: none;
}

html[data-style="cine"] {
  --bg: #050507;
  --bg-2: #0d0d12;
  --panel: rgba(255, 255, 255, 0.04);
  --text: #f5f5f7;
  --muted: #9a9aa6;
  --accent: #ff3d9a;
  --accent-2: #7fdcff;
  --line: rgba(255, 255, 255, 0.12);
  --glow: none;
  --radius: 4px;
  --font-head: "Exo 2", system-ui, sans-serif;
  --head-weight: 800;
  --head-spacing: -0.01em;
}

html[data-style="hud"] {
  --bg: #060a12;
  --bg-2: #0a1220;
  --panel: rgba(10, 30, 48, 0.78);
  --text: #e6fbff;
  --muted: #8fb3c2;
  --accent: #ff9a1f;
  --accent-2: #2ef2ff;
  --line: rgba(46, 242, 255, 0.4);
  --glow: 0 0 14px rgba(46, 242, 255, 0.45);
  --radius: 0;
  --font-head: "Rajdhani", system-ui, sans-serif;
  --head-weight: 700;
  --head-spacing: 0.08em;
  --clip: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 18px 100%, 0 calc(100% - 18px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 18px/1.6 var(--font-body);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
.wrap { width: min(1180px, 100% - 40px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--text); color: var(--bg); padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }
html { font-synthesis: none; } /* Crivon tiene un solo peso y ya es cursiva */
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }

/* Navegación */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; gap: 24px;
  padding: 14px clamp(16px, 4vw, 40px);
  transition: background 0.3s, backdrop-filter 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.is-solid { background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(12px); border-color: var(--line); }
.nav__brand, .footer__brand {
  font: 400 30px/1 "Crivon", "Exo 2", system-ui, sans-serif; text-transform: uppercase;
  color: #fff; text-decoration: none; white-space: nowrap;
  text-shadow: 0 0 1px var(--accent-2), 0 0 14px color-mix(in srgb, var(--accent-2) 55%, transparent);
}
.nav__links { display: flex; gap: 32px; margin-left: auto; font-weight: 600; font-size: 18px; letter-spacing: 0.02em; }
@media (max-width: 1100px) { .nav__links { gap: 20px; font-size: 16px; } .nav__brand { font-size: 26px; } }
.nav__links a { text-decoration: none; color: var(--muted); transition: color 0.2s; }
.nav__links a:hover { color: var(--text); }
.nav__cta { color: var(--accent) !important; }
.lang { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
html[data-style="hud"] .lang, html[data-style="cine"] .lang { border-radius: 0; }
.lang button {
  background: none; border: 0; color: var(--muted); font: 600 15px var(--font-body);
  padding: 8px 14px; cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--accent); color: #fff; }

/* Portada */
.hero {
  position: relative; min-height: 100svh; display: grid; place-items: center;
  text-align: center; overflow: hidden; isolation: isolate;
  padding: 110px 20px 90px;
}
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -3; }
.hero__shade {
  position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(ellipse at 50% 40%, rgba(11, 6, 24, 0.25), rgba(11, 6, 24, 0.85) 70%),
    linear-gradient(180deg, rgba(11, 6, 24, 0.55) 0%, transparent 30%, transparent 60%, var(--bg) 100%);
}
.hero__grid {
  position: absolute; left: -50%; right: -50%; bottom: -10%; height: 45%; z-index: -1;
  background-image:
    linear-gradient(var(--accent) 2px, transparent 2px),
    linear-gradient(90deg, var(--accent) 2px, transparent 2px);
  background-size: 80px 80px;
  transform: perspective(500px) rotateX(62deg);
  transform-origin: 50% 100%;
  opacity: 0.22;
  mask-image: linear-gradient(180deg, transparent, #000 60%);
  animation: grid 2.4s linear infinite;
}
@keyframes grid { to { background-position: 0 80px; } }
.hero__content { max-width: 920px; }
.hero__logo img { width: 100%; height: auto; }
.hero__logo { margin: 0 auto 8px; width: min(820px, 100%); filter: drop-shadow(0 8px 40px rgba(255, 47, 180, 0.35)); }
.hero__headline {
  font: var(--head-weight) clamp(15px, 2vw, 20px) / 1.3 var(--font-head);
  text-transform: uppercase; letter-spacing: 0.22em; color: var(--accent-2);
  margin: 0 0 14px; display: none;
}
.hero__pitch { font-size: clamp(17px, 2.1vw, 21px); color: var(--text); max-width: 680px; margin: 0 auto 32px; text-shadow: 0 2px 16px rgba(0, 0, 0, 0.8); }
.hero__ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero__scroll { position: absolute; bottom: 26px; left: 50%; translate: -50% 0; width: 26px; height: 42px; border: 2px solid var(--muted); border-radius: 14px; }
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--accent-2); animation: wheel 1.6s ease-in-out infinite; }
@keyframes wheel { 50% { transform: translateY(12px); opacity: 0.2; } }

/* Botones */
.btn {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 220px; padding: 14px 28px; text-decoration: none;
  font: 700 17px/1.2 var(--font-head); text-transform: uppercase; letter-spacing: 0.06em;
  border-radius: 999px; transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
  clip-path: var(--clip);
}
.btn small { font: 600 12px var(--font-body); letter-spacing: 0.08em; opacity: 0.85; margin-top: 4px; }
.btn--primary { background: linear-gradient(90deg, var(--accent), #ff7a3d); color: #fff; box-shadow: var(--glow); }
.btn--ghost { border: 2px solid var(--accent-2); color: var(--accent-2); }
.btn:hover { transform: translateY(-2px); }
.btn.is-disabled { cursor: default; opacity: 0.8; }
.btn.is-disabled:hover { transform: none; }

/* Secciones */
section { position: relative; }
.about, .features, .gallery, .play, .demo { padding: clamp(70px, 10vw, 130px) 0; }
.eyebrow { margin: 0 0 10px; font: 700 13px var(--font-body); text-transform: uppercase; letter-spacing: 0.3em; color: var(--accent); }
.title {
  margin: 0 0 22px; font: var(--head-weight) clamp(30px, 4.6vw, 54px) / 1.08 var(--font-head);
  text-transform: var(--head-case); letter-spacing: var(--head-spacing); max-width: 860px;
}
.lead { color: var(--muted); max-width: 640px; margin: 0 0 40px; font-size: 19px; }

.about { background: linear-gradient(180deg, var(--bg), var(--bg-2)); }
.about__text { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; color: var(--muted); max-width: 980px; }
.about__text p { margin: 0; }
.stats { list-style: none; padding: 0; margin: 56px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stats li { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; clip-path: var(--clip); }
.stats b { display: block; font: 900 clamp(26px, 3.4vw, 40px)/1 var(--font-head); color: var(--accent-2); margin-bottom: 8px; text-shadow: var(--glow); }
.stats span { color: var(--muted); font-size: 15px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; clip-path: var(--clip); transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s; }
.card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--glow); }
.card img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; height: auto; }
.card__body { padding: 20px 22px 24px; }
.card h3 { margin: 0 0 8px; font: 700 20px/1.25 var(--font-head); text-transform: var(--head-case); letter-spacing: var(--head-spacing); }
.card p { margin: 0; color: var(--muted); font-size: 16px; }

.gallery { background: linear-gradient(180deg, var(--bg), var(--bg-2) 50%, var(--bg)); }
.shots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.shot { padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; cursor: zoom-in; background: #000; clip-path: var(--clip); }
.shot--wide { grid-column: span 2; grid-row: span 2; }
.shot img { width: 100%; height: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform 0.5s; }
.shot:hover img { transform: scale(1.05); }

.play__inner { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.keys { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.keys li { display: flex; align-items: center; gap: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; clip-path: var(--clip); }
.keys span { margin-left: 6px; color: var(--muted); font-size: 16px; }
kbd {
  min-width: 40px; height: 40px; padding: 0 8px; display: inline-grid; place-items: center;
  font: 700 16px var(--font-head); color: var(--text);
  border: 1px solid var(--accent-2); border-bottom-width: 3px; border-radius: 8px; background: rgba(0, 0, 0, 0.35);
}
html[data-style="hud"] kbd { border-radius: 0; }

.demo { text-align: center; overflow: hidden; isolation: isolate; }
.demo::before {
  content: ""; position: absolute; left: 50%; top: 18%; width: min(620px, 90vw); aspect-ratio: 1; translate: -50% 0;
  border-radius: 50%; background: var(--sun); opacity: 0.16; filter: blur(30px); z-index: -1;
}
.demo__inner { display: flex; flex-direction: column; align-items: center; }
.demo__icon { width: 112px; margin-bottom: 26px; border-radius: 24px; box-shadow: var(--glow); }
.demo .lead { margin-inline: auto; }

.footer { border-top: 1px solid var(--line); padding: 40px 0 50px; color: var(--muted); font-size: 15px; }
.footer__inner { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.footer .footer__brand { font-size: 26px; margin-bottom: 8px; }
.footer p { margin: 0; }
.footer__small { font-size: 13px; opacity: 0.75; }

.lightbox { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.92); display: grid; place-items: center; padding: 20px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-height: 92vh; width: auto; box-shadow: var(--glow); }
.lightbox__close { position: absolute; top: 14px; right: 18px; background: none; border: 0; color: #fff; font-size: 44px; line-height: 1; cursor: pointer; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* Tráiler */
.trailer { padding: clamp(70px, 10vw, 130px) 0 0; }
/* Reproductor ancho: YouTube elige la calidad según el tamaño del reproductor. */
.trailer__frame { width: min(1440px, 100vw - 40px); margin-left: 50%; translate: -50% 0; }
.trailer__note { text-align: center; }
.trailer__frame {
  position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); background: #000; box-shadow: var(--glow); clip-path: var(--clip);
}
.trailer__frame img, .trailer__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }
.trailer__frame img { filter: brightness(0.6); }
.trailer__play {
  position: absolute; inset: 0; margin: auto; width: max-content; height: max-content;
  display: flex; align-items: center; gap: 14px; padding: 16px 30px; cursor: pointer;
  font: 700 18px var(--font-head); text-transform: uppercase; letter-spacing: 0.08em; color: #fff;
  background: color-mix(in srgb, var(--accent) 85%, transparent); border: 0; border-radius: 999px;
  box-shadow: var(--glow); clip-path: var(--clip); transition: transform 0.15s;
}
.trailer__play:hover { transform: scale(1.05); }
.trailer__icon { font-size: 22px; }
.trailer__soon {
  display: none; position: absolute; left: 50%; top: 50%; translate: -50% -50%; margin: 0;
  font: 700 clamp(18px, 2.4vw, 26px) var(--font-head); text-transform: uppercase; letter-spacing: 0.2em; color: var(--text);
  padding: 12px 26px; border: 1px solid var(--line); background: rgba(0, 0, 0, 0.45); white-space: nowrap;
}
.trailer__frame.is-soon .trailer__play { display: none; }
.trailer__frame.is-soon .trailer__soon { display: block; }
.trailer__note { color: var(--muted); font-size: 14px; margin: 14px 0 0; }
html[data-style="cine"] .trailer__play, html[data-style="hud"] .trailer__play { border-radius: 0; }
html[data-style="cine"] .trailer__play { background: #fff; color: #050507; }
html[data-style="cine"] .trailer__frame { box-shadow: none; }

/* —— Variante «cine»: sobria, oscura, titular grande y sin neón —— */
html[data-style="cine"] .hero { place-items: end start; text-align: left; padding-bottom: 120px; }
html[data-style="cine"] .hero__content { max-width: 1180px; width: 100%; padding-left: clamp(0px, 4vw, 40px); }
html[data-style="cine"] .hero__logo { width: min(300px, 60%); margin: 0 0 22px; filter: none; }
html[data-style="cine"] .hero__headline {
  display: block; color: var(--text); letter-spacing: -0.01em; text-transform: uppercase;
  font: italic 800 clamp(36px, 5.4vw, 76px) / 0.98 var(--font-head); margin-bottom: 22px; max-width: 900px;
}
html[data-style="cine"] .hero__pitch { margin: 0 0 34px; color: #d4d4dc; }
html[data-style="cine"] .hero__ctas { justify-content: flex-start; }
html[data-style="cine"] .hero__grid { display: none; }
html[data-style="cine"] .hero__shade { background: linear-gradient(90deg, rgba(5, 5, 7, 0.85) 0%, rgba(5, 5, 7, 0.35) 60%, rgba(5, 5, 7, 0.2)), linear-gradient(180deg, transparent 50%, var(--bg)); }
html[data-style="cine"] .btn { border-radius: 2px; font-family: var(--font-body); letter-spacing: 0.12em; }
html[data-style="cine"] .btn--primary { background: #fff; color: #050507; }
html[data-style="cine"] .btn--ghost { border-color: rgba(255, 255, 255, 0.5); color: #fff; }
html[data-style="cine"] .title { font-style: italic; }
html[data-style="cine"] .stats b { color: var(--text); }
html[data-style="cine"] .card { background: none; border: 0; }
html[data-style="cine"] .card__body { padding: 16px 0 0; }
html[data-style="cine"] .card:hover { box-shadow: none; transform: none; }
html[data-style="cine"] .card:hover img { filter: brightness(1.12); }
html[data-style="cine"] .shot { border: 0; }
html[data-style="cine"] .demo::before { opacity: 0.08; }
html[data-style="cine"] .eyebrow { color: var(--muted); }

/* —— Variante «hud»: interfaz de recreativa, esquinas cortadas y líneas de barrido —— */
html[data-style="hud"] body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 80;
  background: repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 3px);
}
html[data-style="hud"] .hero__grid { background-image: linear-gradient(var(--accent-2) 1px, transparent 1px), linear-gradient(90deg, var(--accent-2) 1px, transparent 1px); opacity: 0.3; }
html[data-style="hud"] .hero__headline { display: block; letter-spacing: 0.35em; color: var(--accent); }
html[data-style="hud"] .hero__content { border: 1px solid var(--line); background: rgba(6, 10, 18, 0.55); padding: 34px clamp(18px, 4vw, 48px) 40px; clip-path: var(--clip); position: relative; }
html[data-style="hud"] .hero__content::before { content: "NEON08-02 · HARD · ×8"; position: absolute; top: 10px; left: 16px; font: 700 12px var(--font-head); letter-spacing: 0.2em; color: var(--accent-2); opacity: 0.8; }
html[data-style="hud"] .btn { border-radius: 0; font-family: var(--font-head); font-size: 19px; letter-spacing: 0.16em; }
html[data-style="hud"] .btn--primary { background: var(--accent); color: #120800; box-shadow: 0 0 22px rgba(255, 154, 31, 0.55); }
html[data-style="hud"] .title { font-size: clamp(34px, 5vw, 60px); }
html[data-style="hud"] .title::before { content: "▸ "; color: var(--accent); }
html[data-style="hud"] .stats b { color: var(--accent); text-shadow: 0 0 14px rgba(255, 154, 31, 0.5); }
html[data-style="hud"] .eyebrow { color: var(--accent-2); }
html[data-style="hud"] .eyebrow::before { content: "// "; }
html[data-style="hud"] .demo__icon { border-radius: 0; }

/* Móvil */
@media (max-width: 900px) {
  .cards { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .play__inner, .about__text { grid-template-columns: 1fr; }
  .shots { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  .nav { gap: 12px; }
  .nav__links { display: none; }
  .lang { margin-left: auto; }
  .nav__brand { font-size: 24px; }
  .cards, .keys { grid-template-columns: 1fr; }
  .shots { grid-template-columns: 1fr; }
  .shot--wide { grid-column: auto; grid-row: auto; }
  .btn { min-width: 0; width: 100%; }
  .hero__ctas { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
