/* ==========================================================================
   ESMERION - CUENTA REGRESIVA 8 DE OCTUBRE
   Paleta inspirada en el Logo y Banner Oficial:
   - Verde Esmeralda Neón (#00ff87, #10b981)
   - Cian Eléctrico (#00f5d4, #38bdf8)
   - Lilas, Lavandas y Púrpura Cósmico (#d8b4fe, #c084fc, #a855f7, #7e22ce)
   - Fondo Universo Violeta Profundo (#0a0414, #120726)
   ========================================================================== */

:root {
  /* Verde Esmeralda Neón (Extraído del logo y el orbe cósmico) */
  --esmerion-green: #00ff87;
  --esmerion-green-light: #6ee7b7;
  --esmerion-green-glow: rgba(0, 255, 136, 0.788);
  --esmerion-cyan: #00f5d4;

  /* Tonalidades de Lila y Púrpura */
  --lilac-50: #faf5ff;
  --lilac-100: #f3e8ff;
  --lilac-200: #e9d5ff;
  --lilac-300: #d8b4fe;
  --lilac-400: #c084fc;
  --lilac-500: #a855f7;
  --lilac-600: #9333ea;
  --lilac-700: #7e22ce;
  --lilac-800: #581c87;
  --lilac-900: #3b0764;
  --lilac-950: #120726;

  /* Fondos Cósmicos */
  --bg-deep: #080312;
  --bg-surface: #120726;
  --bg-card: rgba(18, 7, 36, 0.78);
  --bg-card-hover: rgba(28, 11, 54, 0.88);

  /* Bordes Neón Cristalinos */
  --border-esmerion: rgba(0, 255, 135, 0.25);
  --border-lilac: rgba(192, 132, 252, 0.25);
  --border-subtle: rgba(216, 180, 254, 0.12);

  /* Sombras y Luces Neón */
  --glow-esmerion: 0 0 25px rgba(0, 255, 135, 0.35);
  --glow-lilac: 0 0 30px rgba(168, 85, 247, 0.4);
  --glow-hybrid: 0 0 35px rgba(0, 255, 135, 0.25), 0 0 50px rgba(192, 132, 252, 0.3);

  /* Tipografías */
  --font-main: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Space Grotesk', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* Reset y Base */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-deep);
  color: var(--lilac-100);
  font-family: var(--font-main);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  background-image:
    radial-gradient(circle at 80% 20%, rgba(0, 255, 135, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 20% 40%, rgba(168, 85, 247, 0.18) 0%, transparent 55%),
    radial-gradient(circle at 50% 80%, rgba(126, 34, 206, 0.15) 0%, transparent 60%);
  background-attachment: fixed;
}

/* Canvas de Partículas */
.ambient-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* Orbes de Brillo Ambiental */
.glow-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.18;
  animation: floatOrb 20s ease-in-out infinite alternate;
}

.glow-orb-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.35), transparent 70%);
  top: -120px;
  left: 45%;
  transform: translateX(-50%);
}

.glow-orb-2 {
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(0, 255, 135, 0.22), transparent 70%);
  top: 30%;
  right: -80px;
  animation-duration: 24s;
  animation-delay: -6s;
}

.glow-orb-3 {
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(126, 34, 206, 0.28), transparent 70%);
  bottom: 0%;
  left: -90px;
  animation-duration: 28s;
  animation-delay: -12s;
}

@keyframes floatOrb {
  0% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(35px, -35px) scale(1.08);
  }

  100% {
    transform: translate(-30px, 30px) scale(0.95);
  }
}

/* Capa de la Aplicación */
.app-wrapper {
  position: relative;
  z-index: 2;
}

/* Clases Utilitarias */
.font-mono {
  font-family: var(--font-mono);
}

.text-esmerion-green {
  color: var(--esmerion-green) !important;
}

.text-lilac-light {
  color: var(--lilac-200) !important;
}

.text-lilac-accent {
  color: var(--lilac-300) !important;
}

.text-lilac-muted {
  color: rgba(233, 213, 255, 0.7) !important;
}

.bg-lilac-subtle {
  background-color: rgba(168, 85, 247, 0.18) !important;
}

.border-lilac-subtle {
  border-color: var(--border-subtle) !important;
}

/* ==========================================================================
   HEADER Y LOGO
   ========================================================================== */
.brand-logo-img {
  height: 48px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 14px rgba(0, 255, 135, 0.45)) drop-shadow(0 0 25px rgba(168, 85, 247, 0.3));
  transition: transform 0.3s ease, filter 0.3s ease;
}

.brand-logo-img:hover {
  transform: scale(1.04);
  filter: drop-shadow(0 0 20px rgba(0, 255, 135, 0.65)) drop-shadow(0 0 35px rgba(192, 132, 252, 0.5));
}

.target-chip {
  background: rgba(18, 7, 38, 0.7);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-lilac);
  border-radius: 50px;
  padding: 7px 20px;
  font-size: 0.9rem;
  color: var(--lilac-200);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.pulse-indicator {
  width: 9px;
  height: 9px;
  background-color: var(--esmerion-green);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 0 rgba(0, 255, 135, 0.7);
  animation: pulseNeon 2s infinite;
}

@keyframes pulseNeon {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 255, 135, 0.7);
  }

  70% {
    box-shadow: 0 0 0 10px rgba(0, 255, 135, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(0, 255, 135, 0);
  }
}

/* ==========================================================================
   FONDO PRINCIPAL: BANNER OFICIAL (ESTRICTAMENTE CENTRADO EN TODOS LOS DISPOSITIVOS)
   ========================================================================== */
.bg-banner-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  /* Soporte dynamic viewport móvil */
  min-height: -webkit-fill-available;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bg-banner-img {
  width: 100%;
  height: 100%;
  min-width: 100%;
  min-height: 100%;
  object-fit: cover;
  object-position: center center !important;
  /* Siempre centrado simétricamente */
  filter: brightness(0.85) contrast(1.08) saturate(1.12);
  margin: auto;
}

.bg-banner-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 50%, rgba(8, 3, 18, 0.05) 0%, rgba(8, 3, 18, 0.35) 85%),
    linear-gradient(180deg,
      rgba(8, 3, 18, 0.45) 0%,
      transparent 25%,
      transparent 70%,
      rgba(8, 3, 18, 0.7) 100%);
  pointer-events: none;
}

/* En dispositivos móviles se mantiene el centrado exacto y se ajusta la protección de lectura */
@media (max-width: 767.98px) {
  .bg-banner-img {
    object-position: center center !important;
    filter: brightness(0.82) contrast(1.08) saturate(1.12);
  }

  .bg-banner-overlay {
    background:
      linear-gradient(180deg,
        rgba(8, 3, 18, 0.5) 0%,
        rgba(8, 3, 18, 0.18) 25%,
        rgba(8, 3, 18, 0.3) 65%,
        rgba(8, 3, 18, 0.85) 100%);
  }
}

/* Espaciado responsivo del contenido central (sustituye múltiples <br>) */
.hero-main-container {
  padding-top: clamp(2.5rem, 9vh, 6.5rem) !important;
}

/* ==========================================================================
   HERO LOGO SHOWCASE
   ========================================================================== */
.hero-brand-showcase {
  display: inline-block;
  perspective: 1000px;
}

.hero-main-logo {
  max-width: 460px;
  width: 90%;
  height: auto;
  filter: drop-shadow(0 0 25px rgba(0, 255, 135, 0.5)) drop-shadow(0 0 45px rgba(168, 85, 247, 0.45));
  transition: transform 0.4s ease, filter 0.4s ease;
}

.hero-main-logo:hover {
  transform: translateY(-3px) scale(1.03);
  filter: drop-shadow(0 0 35px rgba(0, 255, 135, 0.75)) drop-shadow(0 0 60px rgba(192, 132, 252, 0.6));
}

/* Status Pill */
.status-pill {
  background: rgba(22, 9, 42, 0.75);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-lilac);
  padding: 6px 18px;
  border-radius: 100px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  font-size: 50px;
}

@media (max-width: 768px) {
  .status-pill {
    font-size: 35px;
    /* Móvil */
  }
}

.status-badge-green {
  background: rgba(0, 255, 135, 0.15);
  color: var(--esmerion-green);
  border: 1px solid rgba(0, 255, 135, 0.3);
}

/* Tipografía Hero */
.hero-title {
  letter-spacing: -0.025em;
  line-height: 1.18;
  color: var(--esmerion-green);
  text-shadow:
    0 0 25px rgba(0, 255, 136, 0.65),
    0 0 50px rgba(0, 255, 136, 0.35),
    0 4px 28px rgba(0, 0, 0, 0.95);
}

.hero-title span {
  color: inherit;
  text-shadow: inherit;
}

.hero-subtitle {
  color: var(--lilac-100);
  max-width: 720px;
  font-size: 1.15rem;
  background: rgba(14, 6, 28, 0.5);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 10px 24px;
  border-radius: 50px;
  border: 1px solid rgba(192, 132, 252, 0.25);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.85);
}

/* ==========================================================================
   GRILLA Y TARJETAS DEL CONTEO REGRESIVO
   ========================================================================== */
.countdown-section {
  position: relative;
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-width: 920px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .countdown-grid {
    grid-template-columns: repeat(4, 1fr) 0.95fr;
    gap: 18px;
  }
}

.countdown-card {
  perspective: 1000px;
}

.card-glass {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-lilac);
  border-radius: 24px;
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.card-glass::before {
  content: '';
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 100%;
  background: radial-gradient(circle at 50% 0%, rgba(0, 255, 135, 0.12), transparent 70%);
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.countdown-card:hover .card-glass {
  transform: translateY(-6px);
  border-color: rgba(0, 255, 135, 0.45);
  box-shadow: var(--glow-hybrid), 0 16px 40px rgba(0, 0, 0, 0.6);
  background: var(--bg-card-hover);
}

/* Anillo SVG de Progreso Circular */
.circle-progress-wrapper {
  position: relative;
  width: 130px;
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.progress-ring {
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
}

.progress-ring-circle {
  transition: stroke-dashoffset 0.35s ease;
  stroke-dasharray: 339.292;
  stroke-dashoffset: 0;
}

.counter-number-box {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.counter-val {
  font-size: 2.75rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.04em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.counter-label {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--lilac-300);
  margin-top: 10px;
}

/* Tarjeta especial para Milisegundos */
.card-ms {
  grid-column: span 2;
}

@media (min-width: 768px) {
  .card-ms {
    grid-column: span 1;
  }
}

.ms-glass {
  height: 100%;
  min-height: 190px;
  background: linear-gradient(145deg, rgba(30, 11, 56, 0.7), rgba(12, 5, 24, 0.85));
  border: 1px dashed rgba(0, 255, 135, 0.35);
}

.ms-glass:hover {
  border-color: var(--esmerion-green);
}

.ms-indicator-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.ms-badge {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  background: rgba(0, 255, 135, 0.15);
  color: var(--esmerion-green);
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid rgba(0, 255, 135, 0.3);
}

.ms-val {
  font-size: 2.6rem;
  background: linear-gradient(135deg, var(--esmerion-green), #ffffff, var(--lilac-300));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
  display: inline-block;
  min-width: 80px;
}

/* ==========================================================================
   BOTONES Y ACCIONES RÁPIDAS
   ========================================================================== */
.btn-esmerion-gradient {
  background: linear-gradient(135deg, #00ff87 0%, #a855f7 100%);
  color: #0b0314;
  border: none;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: all 0.3s ease;
  box-shadow: 0 4px 18px rgba(0, 255, 135, 0.35);
}

.btn-esmerion-gradient:hover {
  background: linear-gradient(135deg, #10b981 0%, #c084fc 100%);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(0, 255, 135, 0.5), 0 0 30px rgba(168, 85, 247, 0.4);
}

.btn-outline-esmerion {
  background: rgba(0, 255, 135, 0.08);
  color: var(--esmerion-green);
  border: 1px solid rgba(0, 255, 135, 0.3);
  transition: all 0.25s ease;
}

.btn-outline-esmerion:hover {
  background: rgba(0, 255, 135, 0.2);
  color: #ffffff;
  border-color: var(--esmerion-green);
  box-shadow: 0 0 20px rgba(0, 255, 135, 0.35);
}

.btn-outline-lilac {
  background: rgba(168, 85, 247, 0.1);
  color: var(--lilac-200);
  border: 1px solid var(--border-lilac);
  transition: all 0.25s ease;
}

.btn-outline-lilac:hover {
  background: rgba(168, 85, 247, 0.25);
  color: #ffffff;
  border-color: var(--lilac-400);
  box-shadow: 0 0 15px rgba(168, 85, 247, 0.35);
}

/* Feature Cards */
.feature-card {
  background: rgba(20, 8, 38, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 255, 135, 0.35);
  background: rgba(28, 12, 52, 0.75);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(0, 255, 135, 0.15);
}

.feature-icon-wrapper {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(0, 255, 135, 0.18), rgba(168, 85, 247, 0.25));
  border: 1px solid rgba(0, 255, 135, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--esmerion-green);
  font-size: 1.3rem;
}

/* Celebración Final */
.celebration-box {
  background: rgba(28, 10, 52, 0.85);
  backdrop-filter: blur(20px);
  border: 2px solid var(--esmerion-green);
  box-shadow: var(--glow-hybrid);
  max-width: 650px;
  animation: zoomIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.celebration-icon {
  font-size: 3.5rem;
  color: var(--esmerion-green);
  animation: bounce 2s infinite;
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0);
  }

  40% {
    transform: translateY(-16px);
  }

  60% {
    transform: translateY(-8px);
  }
}

@keyframes zoomIn {
  from {
    opacity: 0;
    transform: scale(0.85);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Redes Sociales y Footer */
.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid var(--border-subtle);
  color: var(--lilac-200);
  transition: all 0.25s ease;
  text-decoration: none;
}

.social-icon:hover {
  background: var(--esmerion-green);
  color: #0b0314;
  border-color: var(--esmerion-green);
  transform: translateY(-2px);
  box-shadow: 0 0 15px rgba(0, 255, 135, 0.6);
}

/* Toast Personalizado */
.bg-dark-esmerion {
  background-color: #15062c !important;
  border: 1px solid rgba(0, 255, 135, 0.35) !important;
  box-shadow: 0 0 25px rgba(0, 255, 135, 0.3);
}

/* Responsive Tweaks */
@media (max-width: 768px) {
  .brand-logo-img {
    height: 38px;
  }

  .hero-title {
    font-size: 2.3rem;
  }

  .banner-card-glow {
    border-radius: 16px;
  }
}

@media (max-width: 576px) {
  .hero-title {
    font-size: 2rem;
  }

  .circle-progress-wrapper {
    width: 105px;
    height: 105px;
  }

  .progress-ring {
    width: 105px;
    height: 105px;
  }

  .progress-ring-bg,
  .progress-ring-circle {
    cx: 52.5;
    cy: 52.5;
    r: 44;
    stroke-dasharray: 276.46;
  }

  .counter-val {
    font-size: 2rem;
  }

  .card-glass {
    padding: 16px 8px;
    border-radius: 18px;
  }

  .counter-label {
    font-size: 0.75rem;
  }
}