/* ======================
   IMPORTAR FUENTES
====================== */
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=VT323&display=swap');

/* ======================
   VARIABLES GLOBALES (paleta del watch party)
====================== */
:root {
  --bg:          #080810;
  --bg2:         #0d0d1a;
  --surface:     #12121f;
  --surface2:    #1a1a2e;
  --border:      #2a2a4a;
  --border-glow: #7c3aed;
  --text:        #d4d4f0;
  --text-dim:    #6b6b9a;
  --purple:      #7c3aed;
  --purple-light: #a855f7;
  --purple-bright:#c084fc;
  --purple-glow:  #9333ea;
  --neon:        #e879f9;
  --neon-dim:    #701a75;
  --green:       #4ade80;
  --danger:      #f87171;
  --gold:        #fbbf24;
  --font-pixel:  'Press Start 2P', monospace;
  --font-vt:     'VT323', monospace;
  --font-body:   'VT323', monospace;
  --radius:      4px;
  --radius-lg:   8px;
}

/* ======================
   RESETEO Y GLOBALES
====================== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 18px;
  overflow-x: hidden;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Scrollbar personalizado */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--purple); border-radius: 2px; }

/* ======================
   ANIMACIONES
====================== */
@keyframes pulse-border {
  0%, 100% { border-color: var(--border-glow); box-shadow: 0 0 6px var(--purple-glow); }
  50%       { border-color: var(--neon);        box-shadow: 0 0 14px var(--neon); }
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.3} }
@keyframes fadeIn { from{opacity:0;transform:translateY(6px)} to{opacity:1;transform:none} }
@keyframes float {
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(-8px)}
}
@keyframes logo-glow {
  0%,100%{text-shadow:0 0 8px var(--purple),0 0 20px var(--purple-glow)}
  50%{text-shadow:0 0 16px var(--neon),0 0 40px var(--neon-dim),0 0 60px var(--purple)}
}

/* ======================
   NAVBAR CON ANIMACIÓN RESPIRANDO Y TEXTO NEÓN
====================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(180deg, var(--purple) 0%, var(--surface) 100%);
  border-bottom: 2px solid var(--purple-bright);
  padding: 0 20px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(0,0,0,0.6), 0 0 15px var(--purple-glow);
  overflow-x: auto;
  overflow-y: hidden;
  /* Animación de respiración en la sombra/borde */
  animation: navbar-breathe 3s ease-in-out infinite;
}

@keyframes navbar-breathe {
  0%, 100% {
    box-shadow: 0 4px 20px rgba(0,0,0,0.6), 0 0 15px var(--purple-glow);
    border-color: var(--purple-bright);
  }
  50% {
    box-shadow: 0 4px 25px rgba(0,0,0,0.7), 0 0 30px var(--neon);
    border-color: var(--neon);
  }
}

.navbar::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--neon), transparent);
  animation: breathe-line 3s ease-in-out infinite;
}

@keyframes breathe-line {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

.nav-content {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.nav-links {
  display: flex;
  gap: 24px;                     /* más espacio entre enlaces */
  align-items: center;
}

.nav-links a {
  color: #ffffff;                /* blanco puro */
  text-decoration: none;
  font-family: var(--font-pixel);
  font-size: 0.75rem;           /* más grande */
  letter-spacing: 0.12em;       /* más espaciado */
  text-transform: uppercase;
  position: relative;
  white-space: nowrap;
  padding: 8px 14px;
  transition: color 0.3s, text-shadow 0.3s;
  /* Efecto neón blanco base */
  text-shadow: 0 0 8px rgba(255,255,255,0.6), 0 0 15px rgba(255,255,255,0.3);
  animation: text-breathe 2.5s ease-in-out infinite;
}

/* Animación de respiración en el texto */
@keyframes text-breathe {
  0%, 100% {
    text-shadow: 0 0 8px rgba(255,255,255,0.6), 0 0 15px rgba(255,255,255,0.3);
  }
  50% {
    text-shadow: 0 0 14px rgba(255,255,255,0.9), 0 0 25px rgba(255,255,255,0.5);
  }
}

.nav-links a:hover {
  color: var(--neon);           /* morado neón al pasar el ratón */
  text-shadow: 0 0 12px var(--neon), 0 0 25px var(--neon-dim), 0 0 40px var(--purple-glow);
  animation: none;              /* quita la animación de respiración al hacer hover */
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--neon);
  box-shadow: 0 0 8px var(--neon);
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

/* Ajuste del botón móvil */
.mobile-menu-button {
  display: none;
  color: #fff;
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  text-shadow: 0 0 8px rgba(255,255,255,0.7);
  cursor: pointer;
}

@media screen and (max-width: 768px) {
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background: var(--surface);
    padding: 10px 0;
    gap: 0;
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    padding: 14px 20px;
    font-size: 0.65rem;
    animation: none;            /* sin animación en menú móvil para mayor legibilidad */
    text-shadow: 0 0 5px rgba(255,255,255,0.5);
  }

  .mobile-menu-button {
    display: block;
  }
}
/* ======================
   BOTONES
====================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: var(--radius);
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  line-height: 1;
  letter-spacing: 0.05em;
  transition: all 0.15s;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  border: none;
  cursor: pointer;
  text-decoration: none;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.06);
  opacity: 0;
  transition: opacity 0.15s;
}

.btn:hover::after { opacity: 1; }
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--purple);
  color: #fff;
  box-shadow: 0 0 12px rgba(124,58,237,0.5), inset 0 1px 0 rgba(255,255,255,0.12);
}

.btn-primary:hover {
  background: var(--purple-glow);
  box-shadow: 0 0 20px rgba(147,51,234,0.7);
}

.btn-ghost {
  background: transparent;
  color: var(--text-dim);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  border-color: var(--purple);
  color: var(--text);
}

.btn-danger {
  background: #7f1d1d;
  color: var(--danger);
  border: 1px solid var(--danger);
  box-shadow: 0 0 8px rgba(248,113,113,0.3);
}

.btn-danger:hover {
  background: var(--danger);
  color: #000;
}

.btn-green {
  background: #14532d;
  color: var(--green);
  border: 1px solid var(--green);
}

.btn-green:hover {
  background: var(--green);
  color: #000;
}

.btn-neon {
  background: var(--neon-dim);
  color: var(--neon);
  border: 1px solid var(--neon);
  box-shadow: 0 0 10px rgba(232,121,249,0.3);
}

.btn-neon:hover {
  background: var(--neon);
  color: #000;
  box-shadow: 0 0 20px rgba(232,121,249,0.7);
}

.btn-sm { padding: 7px 12px; font-size: 0.5rem; }

/* ======================
   HERO (index.html)
====================== */
.hero {
  padding-top: 120px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(124,58,237,0.18) 0%, transparent 60%), var(--bg);
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(0,0,0,0.15) 3px, rgba(0,0,0,0.15) 4px);
  pointer-events: none;
  z-index: 0;
}

.hero-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
  text-align: center;
  position: relative;
  z-index: 1;
}

.profile-img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--purple);
  box-shadow: 0 0 30px rgba(124,58,237,0.4);
  margin-bottom: 2rem;
  animation: float 3s ease-in-out infinite;
}

.title {
  font-family: var(--font-pixel);
  font-size: clamp(1rem, 4vw, 1.6rem);
  line-height: 1.8;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, var(--purple-bright), var(--neon));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: logo-glow 3s ease-in-out infinite;
  margin-bottom: 1rem;
}

.subtitle {
  font-family: var(--font-vt);
  font-size: 1.5rem;
  color: var(--text-dim);
  letter-spacing: 0.05em;
  margin-bottom: 2rem;
}

/* ======================
   BOTONES DE REDES SOCIALES (MÁS GRANDES)
====================== */
.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.social-links a {
  font-family: var(--font-pixel);
  font-size: 1.5rem;
  text-decoration: none;
  padding: 24px 40px;
  border-radius: var(--radius);
  letter-spacing: 0.08em;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.social-links a:hover {
  transform: translateY(-3px);
}

.social-links .kick     { background: var(--purple); color: #fff; box-shadow: 0 0 12px rgba(124,58,237,0.5); }
.social-links .twitch   { background: #1a1a2e; color: #a855f7; border: 1px solid #a855f7; }
.social-links .instagram { background: linear-gradient(45deg, #E1306C, #C13584); color: #fff; }
.social-links .twitter  { background: #1a1a2e; color: #e879f9; border: 1px solid #e879f9; }
.social-links .email    { background: #1a1a2e; color: #f87171; border: 1px solid #f87171; }
.social-links .tiktok   { background: #1a1a2e; color: #c084fc; border: 1px solid #c084fc; }
.social-links .discord  { background: #5865F2; color: #fff; }
.social-links .youtube  { background: #FF0000; color: #fff; }

/* ======================
   LOGIN CON KICK (mantenido para compatibilidad con otras páginas)
====================== */
.kick-login-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  background: var(--purple);
  border: 1px solid var(--purple-light);
  border-radius: var(--radius);
  color: #fff;
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  box-shadow: 0 0 20px rgba(124,58,237,0.5);
  transition: all 0.2s;
  cursor: pointer;
  text-decoration: none;
  margin-top: 10px;
}

.kick-login-btn:hover {
  background: var(--neon-dim);
  border-color: var(--neon);
  box-shadow: 0 0 30px rgba(232,121,249,0.5);
}

.user-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 14px;
  font-family: var(--font-vt);
  font-size: 1.1rem;
  color: var(--purple-bright);
  margin-top: 10px;
}

.user-badge img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--purple-bright);
}

.logout-link {
  font-family: var(--font-vt);
  font-size: 0.9rem;
  color: var(--text-dim);
  cursor: pointer;
  text-decoration: underline;
  border: none;
  background: none;
  margin-left: 10px;
}

.logout-link:hover {
  color: var(--danger);
}

/* ======================
   SECCIONES COMUNES
====================== */
.section {
  padding: 120px 2rem 4rem;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--purple-bright);
  letter-spacing: 0.05em;
  margin-bottom: 2rem;
  text-transform: uppercase;
  animation: logo-glow 3s ease-in-out infinite;
}

/* ======================
   ABOUT PAGE
====================== */
.about-container {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 1000px;
  margin: 0 auto;
}

.about-image {
  flex: 0 0 300px;
  max-width: 300px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 0 20px rgba(124,58,237,0.3);
  border: 1px solid var(--border);
}

.about-image img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

.about-text {
  flex: 1;
  max-width: 600px;
  text-align: left;
  line-height: 1.8;
  font-family: var(--font-vt);
  font-size: 1.2rem;
  color: var(--text);
}

.about-text strong {
  color: var(--purple-bright);
}

.about-text em {
  color: var(--neon);
  font-style: italic;
}

@media (max-width: 768px) {
  .about-container {
    flex-direction: column;
    text-align: center;
  }
  .about-text {
    text-align: center;
  }
}

/* ======================
   GALLERY
====================== */
.gallery-container {
  padding-top: 120px;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 50px;
  text-align: center;
}

.gallery-title {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--purple-bright);
  margin-bottom: 2rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  padding: 0 1rem;
}

.gallery-item {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  transition: transform 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
}

.gallery-item:hover {
  transform: scale(1.03);
  border-color: var(--purple);
}

.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.gallery-item .info {
  padding: 15px;
  text-align: left;
}

.gallery-item .info h3 {
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  color: var(--purple-bright);
  margin-bottom: 5px;
}

.gallery-item .info p {
  font-family: var(--font-vt);
  font-size: 1rem;
  color: var(--text-dim);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.modal.open {
  display: flex;
}

.modal-content {
  max-width: 90%;
  max-height: 90vh;
}

.modal-image {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.modal-description {
  font-family: var(--font-vt);
  color: var(--text);
  text-align: center;
  padding: 15px;
  font-size: 1.2rem;
}

.close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: var(--text);
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  font-family: var(--font-pixel);
}

.close:hover {
  color: var(--purple-bright);
}

/* ======================
   EN VIVO PAGE
====================== */
.live-wrapper {
  padding-top: 100px;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-bottom: 2rem;
}

.live-title {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--purple-bright);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 1rem;
}

.live-grid {
  display: flex;
  gap: 1rem;
  height: 80vh;
  min-height: 500px;
  padding: 0 1rem;
}

.player-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.stream-embed {
  flex: 1;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: 100%;
}

.chat-panel {
  width: 380px;
  flex-shrink: 0;
}

.chat-frame {
  width: 100%;
  height: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

@media (max-width: 768px) {
  .live-grid {
    flex-direction: column;
    height: auto;
  }

  .player-panel {
    height: 350px;
  }

  .chat-panel {
    width: 100%;
    height: 500px;
  }
}

/* ======================
   LEADERBOARD (top.html)
====================== */
.top-wrapper {
  padding-top: 120px;
  max-width: 900px;
  margin: 0 auto;
  padding-bottom: 3rem;
  text-align: center;
}

.top-title {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--purple-bright);
  margin-bottom: 2rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.podium {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 1.5rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.podium-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  width: 180px;
  transition: transform 0.3s ease;
}

.podium-card:hover {
  transform: translateY(-5px);
}

.podium-card.first {
  border-color: var(--gold);
  box-shadow: 0 0 20px rgba(251,191,36,0.2);
  transform: scale(1.08);
}

.podium-card.first:hover {
  transform: scale(1.12);
}

.podium-card img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--purple);
  margin-bottom: 10px;
}

.podium-card.first img {
  border-color: var(--gold);
  box-shadow: 0 0 15px rgba(251,191,36,0.4);
}

.podium-card .pos {
  font-family: var(--font-pixel);
  font-size: 0.55rem;
  color: var(--text-dim);
  margin-bottom: 6px;
}

.podium-card .name {
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  color: var(--text);
  margin-bottom: 4px;
  word-break: break-word;
}

.podium-card .amount {
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  color: var(--gold);
}

.crown {
  font-size: 1.8rem;
  animation: float 2s ease-in-out infinite;
}

.donor-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}

.donor-table th,
.donor-table td {
  padding: 12px;
  text-align: left;
  font-family: var(--font-vt);
  font-size: 1rem;
}

.donor-table th {
  background: var(--purple);
  color: #fff;
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.donor-table tr:nth-child(even) {
  background: var(--bg2);
}

.donor-table tr:hover {
  background: rgba(124,58,237,0.1);
}

.donor-table img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.loading-msg {
  font-family: var(--font-vt);
  color: var(--text-dim);
  font-size: 1.2rem;
  padding: 30px;
}

.error-msg {
  font-family: var(--font-vt);
  color: var(--danger);
  font-size: 1.1rem;
  padding: 30px;
}

.empty-msg {
  font-family: var(--font-vt);
  color: var(--text-dim);
  font-size: 1.2rem;
  padding: 30px;
}

/* ======================
   WATCH PARTY PAGE
====================== */
.watchparty-wrapper {
  padding-top: 100px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 28px;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(124,58,237,0.18) 0%, transparent 60%), var(--bg);
  position: relative;
  overflow: hidden;
}

.watchparty-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(0,0,0,0.15) 3px, rgba(0,0,0,0.15) 4px);
  pointer-events: none;
  z-index: 0;
}

.watchparty-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 20px;
}

.watchparty-icon {
  font-size: 4rem;
  animation: float 3s ease-in-out infinite;
  filter: drop-shadow(0 0 15px var(--purple));
}

.watchparty-title {
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--purple-bright);
  line-height: 2;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.watchparty-sub {
  font-family: var(--font-vt);
  font-size: 1.3rem;
  color: var(--text-dim);
  max-width: 500px;
  line-height: 1.6;
}

.watchparty-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 36px;
  border-radius: var(--radius);
  font-family: var(--font-pixel);
  font-size: 0.65rem;
  letter-spacing: 0.05em;
  text-decoration: none;
  background: var(--purple);
  color: #fff;
  box-shadow: 0 0 20px rgba(124,58,237,0.5);
  transition: all 0.2s;
  margin-top: 10px;
}

.watchparty-btn:hover {
  background: var(--neon-dim);
  border-color: var(--neon);
  box-shadow: 0 0 30px rgba(232,121,249,0.5);
  transform: translateY(-2px);
}

.watchparty-btn .btn-icon {
  font-size: 1.5rem;
}

/* ======================
   FOOTER
====================== */
footer {
  text-align: center;
  padding: 20px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  font-family: var(--font-vt);
  font-size: 0.9rem;
  color: var(--text-dim);
  margin-top: auto;
}

footer a {
  color: var(--purple-bright);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

/* ======================
   BACK BUTTON
====================== */
.back-button {
  position: fixed;
  top: 80px;
  left: 20px;
  z-index: 999;
}

.back-button a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-dim);
  text-decoration: none;
  border-radius: 50%;
  font-size: 16px;
  transition: all 0.15s;
}

.back-button a:hover {
  border-color: var(--purple);
  color: var(--text);
}

/* ======================
   UTILIDADES
====================== */
.text-center { text-align: center; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }

/* ======================
   SUGERENCIAS (VIDEOS RECIENTES EN INDEX)
====================== */
.suggestions-section {
  max-width: 1200px;
  margin: 3rem auto;
  padding: 0 2rem 4rem;
  text-align: center;
}

.suggestions-title {
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  color: var(--purple-bright);
  margin-bottom: 2rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.suggestions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
  justify-items: center;
}

.video-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.3s ease, border-color 0.3s ease;
  text-decoration: none;
  display: block;
  width: 100%;
  max-width: 260px;
}

.video-card:hover {
  transform: scale(1.03);
  border-color: var(--purple);
}

.video-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
}

.video-card .video-title {
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  color: var(--text);
  padding: 10px;
  text-align: left;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* ======================
   WIDGET FLOTANTE (ÚLTIMO VIDEO)
====================== */
.yt-widget {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 999;
  background: var(--surface);
  border: 2px solid var(--purple-bright);
  border-radius: var(--radius-lg);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 320px;
  box-shadow: 0 0 20px rgba(124,58,237,0.4), 0 8px 20px rgba(0,0,0,0.6);
  animation: widget-float 4s ease-in-out infinite;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  color: var(--text);
}

.yt-widget:hover {
  transform: scale(1.03);
  border-color: var(--neon);
  box-shadow: 0 0 30px var(--neon), 0 12px 24px rgba(0,0,0,0.7);
}

@keyframes widget-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.yt-widget .widget-icon {
  font-size: 2rem;
  color: #FF0000;
  filter: drop-shadow(0 0 6px rgba(255,0,0,0.5));
}

.yt-widget .widget-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.yt-widget .widget-label {
  font-family: var(--font-pixel);
  font-size: 0.45rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.yt-widget .widget-title {
  font-family: var(--font-vt);
  font-size: 1rem;
  color: var(--text);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.yt-widget .widget-link {
  font-family: var(--font-pixel);
  font-size: 0.4rem;
  color: var(--neon);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

@media (max-width: 768px) {
  .yt-widget {
    bottom: 10px;
    left: 10px;
    max-width: 260px;
    padding: 10px 12px;
    gap: 8px;
  }
  .yt-widget .widget-icon { font-size: 1.5rem; }
  .yt-widget .widget-title { font-size: 0.9rem; }
}
/* Botón de menú móvil mejorado */
.mobile-menu-button {
  display: none;
  color: #fff;
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  text-shadow: 0 0 8px rgba(255,255,255,0.7);
  cursor: pointer;
  padding: 8px 12px;
  background: rgba(124,58,237,0.3);
  border: 1px solid var(--purple-bright);
  border-radius: var(--radius);
  transition: all 0.2s;
}

.mobile-menu-button:hover {
  background: rgba(124,58,237,0.6);
  text-shadow: 0 0 12px rgba(255,255,255,0.9);
}

@media screen and (max-width: 768px) {
  .mobile-menu-button {
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .mobile-menu-button::before {
    content: '☰';
    font-size: 1.2rem;
  }
}
/* ======================
   BOTÓN MENÚ MÓVIL (definición canónica)
====================== */
.mobile-menu-button {
  display: none;
  color: #fff;
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  text-shadow: 0 0 8px rgba(255,255,255,0.7);
  cursor: pointer;
  padding: 10px 16px;
  background: rgba(124,58,237,0.4);
  border: 1px solid var(--purple-bright);
  border-radius: var(--radius);
  transition: all 0.2s;
  align-items: center;
  gap: 8px;
}

.mobile-menu-button:hover {
  background: rgba(124,58,237,0.7);
  text-shadow: 0 0 14px rgba(255,255,255,0.9);
}

.mobile-menu-button::before {
  content: '☰';
  font-size: 1.4rem;
}

/* ======================
   RESPONSIVE — TABLET (≤ 900px)
====================== */
@media screen and (max-width: 900px) {
  /* Navbar: ocultamos hamburguesa y links desplegables.
     La navegacion movil la maneja el FAB inferior (script.js). */
  .mobile-menu-button {
    display: none !important;
  }

  .nav-links,
  .nav-links.active {
    display: none !important;
  }

  /* Hero / Inicio */
  .hero {
    padding-top: 90px;
  }

  .hero-content {
    padding: 1.5rem;
  }

  .profile-img {
    width: 140px;
    height: 140px;
  }

  .social-links {
    gap: 0.75rem;
  }

  .social-links a {
    font-size: 1.1rem;
    padding: 16px 24px;
    gap: 10px;
  }

  /* About */
  .section {
    padding: 100px 1.5rem 3rem;
  }

  .about-container {
    flex-direction: column;
    text-align: center;
  }

  .about-image {
    flex: 0 0 auto;
    max-width: 240px;
  }

  .about-text {
    text-align: center;
  }

  /* En Vivo */
  .live-wrapper {
    padding-top: 90px;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .live-grid {
    flex-direction: column;
    height: auto;
    padding: 0 0.5rem;
  }

  .player-panel {
    width: 100%;
    /* Mantiene relación de aspecto 16:9 sin distorsión */
    height: auto;
    aspect-ratio: 16 / 9;
    flex-shrink: 0;
  }

  .stream-embed {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: var(--radius-lg);
  }

  .chat-panel {
    width: 100%;
    height: 55vh;
    min-height: 350px;
    flex-shrink: 0;
  }

  .chat-frame {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: var(--radius-lg);
  }

  /* Troleos / Gallery */
  .gallery-container {
    padding-top: 100px;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
    padding: 0;
  }

  /* Top Donadores */
  .top-wrapper {
    padding-top: 100px;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .podium {
    gap: 1rem;
  }

  .podium-card {
    width: 140px;
    padding: 14px;
  }

  .donor-table th,
  .donor-table td {
    padding: 8px 6px;
    font-size: 0.9rem;
  }

  /* Afiliados */
  .affiliates-container {
    padding-top: 100px;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .affiliates-grid {
    gap: 1.5rem;
    padding: 0;
  }

  .affiliate-card {
    width: 260px;
  }

  /* Suggestions / video cards en index */
  .suggestions-section {
    padding: 0 1rem 3rem;
  }

  .suggestions-grid {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
  }
}

/* ======================
   RESPONSIVE — MÓVIL (≤ 600px)
====================== */
@media screen and (max-width: 600px) {
  /* Navbar */
  .navbar {
    padding: 0 12px;
  }

  /* Hero */
  .profile-img {
    width: 110px;
    height: 110px;
    margin-bottom: 1.2rem;
  }

  .title {
    font-size: clamp(0.8rem, 5vw, 1.2rem);
  }

  .social-links {
    gap: 0.6rem;
  }

  .social-links a {
    font-size: 0.85rem;
    padding: 12px 16px;
    gap: 8px;
  }

  /* Sections */
  .section {
    padding: 90px 1rem 2.5rem;
  }

  /* En Vivo — el player no se distorsiona, respeta 16:9 */
  .player-panel {
    aspect-ratio: 16 / 9;
    height: auto !important;
    min-height: unset;
  }

  .chat-panel {
    height: 50vh;
    min-height: 300px;
  }

  /* Gallery */
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .gallery-item iframe {
    height: 180px;
  }

  /* Podium más compacto */
  .podium-card {
    width: 110px;
    padding: 10px;
  }

  .podium-card .pos {
    font-size: 0.45rem;
  }

  .podium-card .name {
    font-size: 0.4rem;
  }

  .podium-card .amount {
    font-size: 0.55rem;
  }

  /* Tabla donadores */
  .donor-table th,
  .donor-table td {
    padding: 6px 4px;
    font-size: 0.85rem;
  }

  /* Afiliados: una columna */
  .affiliates-grid {
    flex-direction: column;
    align-items: center;
  }

  .affiliate-card {
    width: 100%;
    max-width: 340px;
  }

  /* Suggestions */
  .suggestions-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  /* Widget YouTube */
  .yt-widget {
    bottom: 8px;
    left: 8px;
    max-width: calc(100vw - 16px);
    padding: 8px 10px;
    gap: 8px;
  }

  .widget-thumb {
    width: 72px !important;
    height: 44px !important;
  }

  .widget-title {
    font-size: 0.85rem !important;
  }

  /* Watch Party */
  .watchparty-wrapper {
    padding-top: 90px;
  }

  .watchparty-title {
    font-size: 0.65rem;
  }

  .watchparty-sub {
    font-size: 1.1rem;
  }

  .watchparty-btn {
    padding: 12px 24px;
    font-size: 0.55rem;
  }

  /* Footer */
  footer {
    font-size: 0.8rem;
    padding: 15px;
  }
}

/* ======================
   RESPONSIVE — MÓVIL PEQUEÑO (≤ 380px)
====================== */
@media screen and (max-width: 380px) {
  .social-links a {
    font-size: 0.75rem;
    padding: 10px 12px;
  }

  .podium {
    gap: 0.6rem;
  }

  .podium-card {
    width: 90px;
    padding: 8px;
  }

  .suggestions-grid {
    grid-template-columns: 1fr;
  }

  .yt-widget {
    max-width: calc(100vw - 16px);
  }
}