/* ============================================================
   KINGDOM · Hero Cinematográfico (Dark Fantasy AAA)
   ============================================================ */
.hero {
  position: relative;
  z-index: 2;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 40px) 0 120px;
  overflow: visible;
}

.hero-bgwrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

/* Panorámica cinematográfica de la fortaleza de Aden / Goddard */
.hero-bg {
  position: absolute;
  inset: -5%;
  background: url("../assets/images/backgrounds/hero-bg-aden.webp") center 28% / cover no-repeat;
  filter: brightness(0.68) saturate(0.92) contrast(1.1);
  animation: kenburns 36s var(--ease) infinite alternate;
}

@keyframes kenburns {
  from { transform: scale(1) translateY(0); }
  to { transform: scale(1.08) translateY(-2%); }
}

/* Graduado gótico multicapa: noche azulada, calidez de antorchas y scrim de lectura */
.hero-grade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, #070503f2 0%, #090604e0 32%, #09060477 62%, #09060433 100%),
    linear-gradient(180deg, #05080ecc 0%, transparent 28%, transparent 62%, #070503 100%),
    radial-gradient(100% 70% at 75% 65%, rgba(224, 106, 44, 0.2) 0%, transparent 60%),
    linear-gradient(180deg, rgba(26, 18, 10, 0.4), rgba(7, 5, 3, 0.6));
}

.hero-grade::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(85% 55% at 70% 82%, rgba(244, 160, 60, 0.12), transparent 60%);
}

/* Niebla volumétrica en dos capas con movimiento suave */
.hero-fog {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}

.hero-fog::before,
.hero-fog::after {
  content: "";
  position: absolute;
  left: -35%;
  right: -35%;
  height: 65%;
  bottom: -8%;
  background: radial-gradient(60% 100% at 50% 100%, rgba(205, 184, 140, 0.22), transparent 72%);
  filter: blur(32px);
  animation: fogDrift 28s linear infinite;
}

.hero-fog::after {
  bottom: 6%;
  height: 48%;
  opacity: 0.65;
  animation-duration: 42s;
  animation-direction: reverse;
  background: radial-gradient(55% 100% at 42% 100%, rgba(138, 155, 176, 0.2), transparent 75%);
}

@keyframes fogDrift {
  from { transform: translateX(-6%); }
  50% { transform: translateX(6%); }
  to { transform: translateX(-6%); }
}

#fx-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 3;
  pointer-events: none;
}

.hero-vignette {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  box-shadow: inset 0 0 240px 70px rgba(5, 3, 2, 0.88);
}

.hero-grain {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background-image: var(--noise);
  opacity: 0.055;
  mix-blend-mode: overlay;
}

/* Guerrero monumental S-grade en primer plano con desborde */
.hero-char {
  position: absolute;
  z-index: 6;
  right: max(2vw, calc((100vw - 1340px) / 2));
  bottom: -58px;
  height: min(96svh, 890px);
  width: auto;
  pointer-events: none;
  animation: charFloat 7.5s ease-in-out infinite;
}

.hero-char img {
  height: 100%;
  width: auto;
  object-fit: contain;
  filter:
    drop-shadow(0 25px 45px rgba(0, 0, 0, 0.95))
    drop-shadow(0 0 35px rgba(224, 106, 44, 0.25))
    drop-shadow(0 0 15px rgba(244, 220, 148, 0.2));
}

/* Aura de retroiluminación épica detrás del guerrero */
.hero-char-glow {
  position: absolute;
  top: 15%;
  left: 20%;
  right: 15%;
  bottom: 25%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(244, 160, 60, 0.22) 0%, rgba(224, 80, 20, 0.1) 45%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: -1;
  animation: charGlowPulse 5s ease-in-out infinite alternate;
}

@keyframes charGlowPulse {
  from { opacity: 0.6; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1.08); }
}

@keyframes charFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* Contenido editorial noble a la izquierda */
.hero-content {
  position: relative;
  z-index: 7;
  width: min(var(--maxw), 100% - 48px);
  margin-inline: auto;
  max-width: var(--maxw);
}

.hero-inner {
  max-width: 620px;
}

.hero-crest-wrap {
  margin-bottom: 16px;
}

.hero-crest {
  width: 58px;
  height: 58px;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.85)) drop-shadow(0 0 16px rgba(244, 220, 148, 0.3));
}

.hero-tagline {
  font-family: var(--f-display);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-tagline::after {
  content: "";
  flex: 0 0 70px;
  height: 1px;
  background: linear-gradient(90deg, var(--gold-deep), transparent);
}

.hero-title {
  font-size: clamp(3.6rem, 9.5vw, 6.8rem);
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 0.94;
  margin: 0 0 18px;
  filter: drop-shadow(0 3px 0 #1a1005) drop-shadow(0 8px 26px rgba(0, 0, 0, 0.95));
}

.hero-title-text {
  display: inline-block;
  padding-right: 0.1em;
  margin-right: -0.1em;
  background: linear-gradient(180deg, #fff9e6 4%, #f4dc94 28%, #c8a24a 60%, #8a6a24 95%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 35px rgba(244, 220, 148, 0.25);
}

.hero-sub {
  font-size: 1.14rem;
  line-height: 1.55;
  color: var(--parch-2);
  max-width: 530px;
  margin: 0 0 28px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
}

/* Indicadores de estado del servidor en placa heráldica */
.hero-status {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.status-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 0.86rem;
  color: var(--parch-2);
  background: linear-gradient(180deg, #1e170eeb, #120d08f2);
  border: 1px solid var(--gold-shadow);
  border-radius: 2px;
  box-shadow: inset 0 1px 0 rgba(244, 220, 148, 0.15), 0 4px 12px rgba(0, 0, 0, 0.6);
}

.status-item strong {
  color: var(--gold-bright);
  font-family: var(--f-display);
  font-weight: 700;
}

.status-item .icon {
  width: 16px;
  height: 16px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 10px 2px rgba(111, 154, 78, 0.8);
  animation: dotPulse 2s infinite;
}

@keyframes dotPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.9); }
}

/* Placa del Countdown con remaches góticos */
.hero-countdown-plate {
  position: relative;
  background: linear-gradient(180deg, rgba(30, 22, 14, 0.85), rgba(16, 12, 8, 0.92));
  border: 1px solid var(--gold-shadow);
  border-radius: 3px;
  padding: 16px 20px 20px;
  margin-bottom: 34px;
  box-shadow:
    inset 0 1px 0 rgba(244, 220, 148, 0.18),
    inset 0 -10px 24px rgba(0, 0, 0, 0.6),
    0 12px 30px -10px rgba(0, 0, 0, 0.85);
}

.hero-countdown-plate::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(200, 162, 74, 0.14);
  pointer-events: none;
}

.plate-rivet {
  position: absolute;
  width: 6px;
  height: 6px;
  background: radial-gradient(circle, #f4dc94, #6a4f1e);
  border-radius: 50%;
  box-shadow: 0 1px 2px #000;
}

.plate-rivet.tl { top: 6px; left: 6px; }
.plate-rivet.tr { top: 6px; right: 6px; }
.plate-rivet.bl { bottom: 6px; left: 6px; }
.plate-rivet.br { bottom: 6px; right: 6px; }

.cd-title {
  font-family: var(--f-display);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 12px;
  text-shadow: 0 1px 4px #000;
}

.hero-countdown {
  display: flex;
  gap: 12px;
}

.cd-box {
  position: relative;
  min-width: 76px;
  padding: 14px 10px 11px;
  text-align: center;
  background: linear-gradient(180deg, #261c10, #130e08);
  border: 1px solid var(--gold-shadow);
  border-radius: 2px;
  box-shadow:
    inset 0 1px 0 rgba(244, 220, 148, 0.16),
    inset 0 -8px 16px rgba(0, 0, 0, 0.6),
    0 8px 20px -8px #000;
}

.cd-box::before {
  content: "";
  position: absolute;
  inset: 2px;
  border: 1px solid rgba(200, 162, 74, 0.18);
  border-radius: 1px;
  pointer-events: none;
}

.cd-num {
  font-family: var(--f-display);
  font-weight: 900;
  font-size: 2.1rem;
  line-height: 1;
  color: var(--gold-bright);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9), 0 0 15px rgba(244, 220, 148, 0.3);
}

.cd-label {
  font-family: var(--f-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--parch-dim);
  margin-top: 7px;
}

/* Botones CTA épicos */
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.hero-enter {
  opacity: 0;
  transform: translateY(22px);
  animation: heroIn 0.9s var(--ease) forwards;
  animation-delay: var(--d, 0s);
}

@keyframes heroIn {
  to {
    opacity: 1;
    transform: none;
  }
}

.hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  z-index: 7;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  font-family: var(--f-display);
  font-size: 0.62rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--parch-dim);
}

.hero-scroll .mouse {
  width: 22px;
  height: 34px;
  border: 1.5px solid var(--gold-deep);
  border-radius: 12px;
  position: relative;
}

.hero-scroll .mouse::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 7px;
  width: 3px;
  height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--gold);
  animation: scrollDot 1.8s var(--ease) infinite;
}

@keyframes scrollDot {
  0% { opacity: 0; transform: translateY(0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translateY(12px); }
}

/* ============================================================
   RESPONSIVE DESIGN DEL HERO
   ============================================================ */
@media (max-width: 1180px) {
  .hero-char {
    right: -2vw;
    height: min(84svh, 720px);
    opacity: 0.95;
  }
  .hero-inner {
    max-width: 540px;
  }
}

@media (max-width: 760px) {
  .hero {
    padding-bottom: 90px;
    align-items: flex-start;
  }
  .hero-char {
    position: absolute;
    right: -12vw;
    bottom: auto;
    top: calc(var(--nav-h) + 12px);
    height: 52svh;
    opacity: 0.32;
    z-index: 1;
    filter: drop-shadow(0 20px 40px #000);
  }
  .hero-grade {
    background:
      linear-gradient(180deg, #070503f5 0%, #070503cc 35%, #070503f2 100%),
      radial-gradient(120% 60% at 80% 20%, rgba(58, 42, 20, 0.4), transparent 60%);
  }
  .hero-content {
    padding-top: 32svh;
  }
  .hero-inner {
    max-width: 100%;
  }
  .hero-title {
    font-size: clamp(3rem, 15vw, 4.4rem);
  }
  .hero-countdown-plate {
    padding: 14px 12px 16px;
  }
  .hero-countdown {
    gap: 8px;
  }
  .cd-box {
    min-width: 0;
    flex: 1;
    padding: 11px 6px 9px;
  }
  .cd-num {
    font-size: 1.55rem;
  }
  .hero-scroll {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg,
  .hero-char,
  .hero-char-glow,
  .hero-fog::before,
  .hero-fog::after {
    animation: none;
  }
  .hero-enter {
    opacity: 1;
    transform: none;
    animation: none;
  }
}
