/* ============================================
   MUNDIAL 2026 - AUTH PAGE STYLES
   ============================================ */

.auth-page {
  background: linear-gradient(135deg, #0A0D1A 0%, #0F1628 40%, #1A1F3E 100%);
  min-height: 100svh; /* ✅ FIX real para móviles */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  position: relative;
  overflow: hidden; /* ✅ el body NO hace scroll */
}


/* Animated grid background */
.auth-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: gridMove 20s linear infinite;
}

/* Radial glow */
.auth-page::after {
  content: '';
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(200,16,46,0.12) 0%, transparent 70%);
  pointer-events: none;
}

@keyframes gridMove {
  0% { transform: translateY(0); }
  100% { transform: translateY(50px); }
}

/* PARTICLES */
.particles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.particle {
  position: absolute;
  bottom: -50px;
  animation: floatUp linear infinite;
}

@keyframes floatUp {
  0% { transform: translateY(0) rotate(0deg); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(-110vh) rotate(360deg); opacity: 0; }
}

/* MAIN CONTAINER */
.auth-container {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 460px;
  background: rgba(17,24,39,0.85);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 
    0 0 0 1px rgba(255,255,255,0.04),
    0 20px 80px rgba(0,0,0,0.6),
    0 0 60px rgba(200,16,46,0.08);
    
  max-height: calc(100svh - 32px); /* ✅ nunca se sale */
  overflow-y: auto;                /* ✅ scroll interno */
}

/* HERO */
.auth-hero {
  padding: 40px 32px 28px;
  text-align: center;
  background: linear-gradient(180deg, rgba(26,31,94,0.8) 0%, rgba(17,24,39,0.4) 100%);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  position: relative;
  overflow: hidden;
}

.auth-hero::before {
  content: '';
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(255,215,0,0.06) 0%, transparent 70%);
}

.trophy-icon {
  font-size: 52px;
  display: block;
  margin-bottom: 8px;
  animation: float 4s ease-in-out infinite;
  filter: drop-shadow(0 0 20px rgba(255,215,0,0.3));
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-8px); }
}

.auth-title {
  font-family: 'Bebas Neue', cursive;
  font-size: 52px;
  letter-spacing: 4px;
  line-height: 0.95;
  color: #FFFFFF;
  text-shadow: 0 0 30px rgba(255,215,0,0.3);
}

.year-highlight {
  color: #FFD700;
  font-size: 38px;
  letter-spacing: 8px;
  text-shadow: 0 0 20px rgba(255,215,0,0.5);
}

.auth-subtitle {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-top: 8px;
  font-weight: 500;
}

.host-flags {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
}

.host-flags img {
  width: 40px;
  height: 28px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,0.15);
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
  transition: transform 0.2s;
}

.host-flags img:hover { transform: scale(1.15); }

/* TABS */
.auth-tabs {
  display: flex;
  padding: 12px 16px;
  gap: 6px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.auth-tab {
  flex: 1;
  padding: 10px;
  background: none;
  border: 1px solid transparent;
  border-radius: 10px;
  color: rgba(255,255,255,0.45);
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.auth-tab:hover {
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.05);
}

.auth-tab.active {
  background: rgba(200,16,46,0.2);
  border-color: rgba(200,16,46,0.4);
  color: #FFFFFF;
}

/* FORM */
.auth-form-section {
  padding: 24px 28px 4px;
}

.auth-form .form-group {
  margin-bottom: 16px;
}

.auth-form .form-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 7px;
}

.auth-form .form-group input {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 12px 14px;
  color: #FFFFFF;
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.auth-form .form-group input:focus {
  border-color: rgba(200,16,46,0.6);
  background: rgba(200,16,46,0.05);
  box-shadow: 0 0 0 3px rgba(200,16,46,0.12);
}

.auth-form .form-group input::placeholder {
  color: rgba(255,255,255,0.2);
}

/* Password toggle */
.password-wrapper {
  position: relative;
}

.password-wrapper input {
  padding-right: 44px;
}

.toggle-pass {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255,255,255,0.35);
  cursor: pointer;
  font-size: 14px;
  padding: 4px;
  transition: color 0.2s;
}

.toggle-pass:hover { color: rgba(255,255,255,0.7); }

/* Submit button */
.auth-form .btn-primary {
  width: 100%;
  justify-content: center;
  padding: 14px;
  font-size: 15px;
  border-radius: 12px;
  background: linear-gradient(135deg, #C8102E, #9B0A22);
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  position: relative;
  overflow: hidden;
}

.auth-form .btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.auth-form .btn-primary:hover::before { opacity: 1; }
.auth-form .btn-primary:hover { box-shadow: 0 8px 30px rgba(200,16,46,0.5); }

.btn-loader { display: none; }
.btn-loader.visible { display: inline-flex; }

.forgot-link {
  text-align: center;
  padding: 10px 0 16px;
  font-size: 12px;
}

.forgot-link a {
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.2s;
}

.forgot-link a:hover { color: rgba(255,255,255,0.75); }

/* AUTH ALERT */
.auth-alert {
  margin: 0 28px 16px;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: slideUp 0.3s ease;
}

.auth-alert.success {
  background: rgba(0,166,80,0.15);
  border: 1px solid rgba(0,166,80,0.3);
  color: #4ADE80;
}

.auth-alert.error {
  background: rgba(200,16,46,0.15);
  border: 1px solid rgba(200,16,46,0.3);
  color: #FF6B6B;
}

/* INFO TEXT */
.info-text {
  font-size: 13px;
  color: rgba(255,255,255,0.45);
  text-align: center;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* TOURNAMENT STATS */
.tournament-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(255,255,255,0.06);
}

.stat-item {
  padding: 16px 8px;
  text-align: center;
  border-right: 1px solid rgba(255,255,255,0.06);
  transition: background 0.2s;
}

.stat-item:last-child { border-right: none; }
.stat-item:hover { background: rgba(255,255,255,0.03); }

.stat-num {
  display: block;
  font-family: 'Bebas Neue', cursive;
  font-size: 26px;
  letter-spacing: 1px;
  color: #FFD700;
  line-height: 1;
}

.stat-label {
  display: block;
  font-size: 10px;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 3px;
  font-weight: 600;
}

@keyframes slideUp {
  from { transform: translateY(10px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
@media (max-height: 760px) {
  .auth-hero {
    padding: 28px 20px 20px;
  }

  .trophy-icon {
    font-size: 40px;
    margin-bottom: 4px;
  }

  .auth-title {
    font-size: 38px;
    letter-spacing: 3px;
  }

  .year-highlight {
    font-size: 28px;
    letter-spacing: 6px;
  }

  .host-flags img {
    width: 30px;
    height: 22px;
  }
}
@media (max-height: 760px) {
  .auth-form-section {
    padding: 18px 20px 4px;
  }

  .auth-form .form-group {
    margin-bottom: 12px;
  }

  .forgot-link {
    padding: 8px 0 12px;
  }
}