/* Rakion Hero - web V28.4.102: sistema de diseno comun (portada y cuenta).
   Fuentes propias (subconjunto de TeX Gyre, licencia GUST; ver assets/fonts/LICENCIAS.txt). Sin nada de terceros. */
@font-face { font-family: "Hero Display"; src: url("../fonts/HeroDisplay-Bold.woff") format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Hero Cond"; src: url("../fonts/HeroCond-Bold.woff") format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Hero Cond"; src: url("../fonts/HeroCond-Regular.woff") format("woff"); font-weight: 400; font-display: swap; }

:root {
  --bg-0: #050506;
  --bg-1: #0a0b0e;
  --bg-2: #111318;
  --panel: rgba(14, 15, 20, 0.88);
  --panel-solid: #101217;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.16);
  --red: #e3192c;
  --red-2: #ff3a4f;
  --red-deep: #6e0610;
  --ember: #ff7a18;
  --gold: #ffc54a;
  --gold-2: #ffe7a8;
  --text: #f5eee8;
  --muted: #bdb5ad;
  --dim: #807970;
  --ok: #38d27c;
  --warn: #ffb020;
  --err: #ff5266;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  --ui: "Hero Cond", "Arial Narrow", "Roboto Condensed", system-ui, sans-serif;
  --display: "Hero Display", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --fire: linear-gradient(180deg, #fff6dc 0%, #ffd36a 34%, #ff8a1e 66%, #c9300c 100%);
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg-0);
  color: var(--text);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* ---------- capas de fondo ---------- */
.fondo {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(120% 70% at 50% -10%, rgba(227, 25, 44, 0.20), transparent 60%),
    linear-gradient(180deg, rgba(5, 5, 6, 0.55), rgba(5, 5, 6, 0.92) 55%, var(--bg-0)),
    url("../img/content.jpg") center 30% / cover no-repeat,
    var(--bg-0);
}
canvas.brasas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }

/* ---------- tipografia ---------- */
.titulo-fuego {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.02;
  margin: 0;
  background: var(--fire);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 0 rgba(60, 14, 4, 0.9)) drop-shadow(0 0 22px rgba(255, 106, 18, 0.28));
}
.etiqueta {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--ui); font-weight: 700; font-size: 13px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-2);
}
.etiqueta::before { content: ""; width: 26px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.etiqueta.centro::after { content: ""; width: 26px; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); }
.texto-suave { color: var(--muted); }

/* ---------- botones ---------- */
.btn {
  --h: 54px;
  position: relative; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: var(--h); padding: 0 26px;
  border: 1px solid transparent; border-radius: 12px;
  font-family: var(--ui); font-weight: 700; font-size: 17px; letter-spacing: 0.08em; text-transform: uppercase;
  text-decoration: none; cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent;
  transition: transform .18s ease, box-shadow .25s ease, background-color .25s ease, border-color .25s ease, opacity .2s;
  overflow: hidden;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.btn-rojo {
  color: #fff;
  background: linear-gradient(180deg, #ff4054 0%, #d9142a 48%, #8f0a18 100%);
  border-color: rgba(255, 120, 130, 0.45);
  box-shadow: 0 10px 28px rgba(227, 25, 44, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.btn-rojo::after {
  content: ""; position: absolute; inset: -40% auto -40% -60%; width: 40%; z-index: -1;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-18deg); transition: left .6s ease;
}
.btn-rojo:hover::after { left: 130%; }
.btn-rojo:hover { box-shadow: 0 14px 36px rgba(227, 25, 44, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.4); }
.btn-oro {
  color: #1b0d02;
  background: linear-gradient(180deg, #ffe7a3 0%, #ffc54a 45%, #ff8a1e 100%);
  border-color: rgba(255, 231, 168, 0.7);
  box-shadow: 0 10px 28px rgba(255, 138, 30, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.btn-oro:hover { box-shadow: 0 14px 36px rgba(255, 138, 30, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.7); }
.btn-borde {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--line-2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.btn-borde:hover { border-color: rgba(255, 197, 74, 0.55); background: rgba(255, 197, 74, 0.06); }
.btn-chico { --h: 42px; padding: 0 16px; font-size: 15px; border-radius: 10px; }
.btn-ancho { width: 100%; }
.btn .giro { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: girar .8s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }

/* ---------- barra superior ---------- */
.barra {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px var(--gutter);
  padding-top: max(12px, env(safe-area-inset-top));
  transition: background-color .3s ease, border-color .3s ease, backdrop-filter .3s;
  border-bottom: 1px solid transparent;
}
.barra.solida { background: rgba(6, 6, 8, 0.82); border-bottom-color: var(--line); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.barra .marca { display: inline-flex; align-items: center; text-decoration: none; }
.barra .marca img { height: 40px; width: auto; filter: drop-shadow(0 0 12px rgba(255, 90, 20, 0.35)); }
.barra nav { display: flex; align-items: center; gap: 6px; }
.barra nav a.enlace {
  font-family: var(--ui); font-weight: 700; font-size: 15px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted); text-decoration: none; padding: 10px 12px; border-radius: 8px; transition: color .2s, background-color .2s;
}
.barra nav a.enlace:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
@media (max-width: 760px) {
  .barra nav a.enlace { display: none; }
  .barra .marca img { height: 34px; }
}

/* ---------- tarjetas / paneles ---------- */
.panel {
  position: relative;
  background: linear-gradient(180deg, rgba(22, 23, 30, 0.92), rgba(12, 13, 17, 0.94));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.panel::before {
  content: ""; position: absolute; left: 18px; right: 18px; top: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 58, 79, 0.75), rgba(255, 197, 74, 0.6), rgba(255, 58, 79, 0.75), transparent);
}

/* ---------- avisos ---------- */
.aviso {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 14px; border-radius: 10px; font-size: 15px; line-height: 1.45;
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.04);
}
.aviso svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.aviso.error { border-color: rgba(255, 82, 102, 0.45); background: rgba(255, 82, 102, 0.09); color: #ffd7dc; }
.aviso.ok { border-color: rgba(56, 210, 124, 0.45); background: rgba(56, 210, 124, 0.09); color: #d4f7e3; }
.aviso.info { border-color: rgba(255, 197, 74, 0.38); background: rgba(255, 197, 74, 0.07); color: #fff0cc; }

/* ---------- ventana modal ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center; padding: 18px;
  background: rgba(3, 3, 5, 0.72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .25s ease;
}
.modal.abierta { opacity: 1; }
.modal .caja {
  width: min(560px, 100%); max-height: calc(100dvh - 36px); overflow: auto;
  padding: 28px clamp(18px, 4vw, 32px) 24px;
  transform: translateY(14px) scale(0.98); transition: transform .3s cubic-bezier(.2, .9, .3, 1.2);
}
.modal.abierta .caja { transform: none; }
.modal .cerrar {
  position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04); cursor: pointer;
}
.modal .cerrar:hover { border-color: var(--line-2); background: rgba(255, 255, 255, 0.08); }
.modal .cerrar svg { width: 18px; height: 18px; }

/* ---------- pie ---------- */
.pie {
  margin-top: 64px; padding: 28px var(--gutter) max(28px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; justify-content: space-between;
  color: var(--dim); font-size: 14px;
}
.pie img { height: 30px; width: auto; opacity: .9; }
.pie nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.pie a { color: var(--muted); text-decoration: none; }
.pie a:hover { color: var(--text); }

/* ---------- iconos de servicio de descarga ---------- */
.serv { --c: #888; }
.serv-mega { --c: #e0303a; }
.serv-mediafire { --c: #2f7de1; }
.serv-drive { --c: #1fa463; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
