/**
 * Community Page Enhanced Styles
 * Gatitas Mimosas
 */

:root {
  --glass-surface: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-highlight: rgba(255, 255, 255, 0.15);
  --neon-gold: #ffd700;
  --neon-pink: #ff007f;
  --neon-blue: #00f3ff;
}

/* --- Layout Base --- */
.container {
  max-width: 1400px; /* Wider container for premium feel */
  margin: 0 auto;
  padding: 0 2rem;
}

.relative-z {
  position: relative;
  z-index: 10;
}

/* Backgrounds */
.glow-bg-top {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 600px;
  background: radial-gradient(
    circle at center,
    rgba(255, 0, 85, 0.12) 0%,
    transparent 60%
  );
  pointer-events: none;
  z-index: 0;
}

.glow-bg-bottom {
  position: absolute;
  bottom: -200px;
  right: 0;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    circle,
    rgba(255, 215, 0, 0.05) 0%,
    transparent 70%
  );
  pointer-events: none;
  z-index: 0;
}

/* --- Hero Section --- */
.community-hero {
  text-align: center;
  padding: 8rem 1rem 5rem;
  position: relative;
  z-index: 10;
}

.pill-badge {
  display: inline-block;
  padding: 8px 20px;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--glass-border);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 3px;
  margin-bottom: 2rem;
  color: var(--brand-gold);
  backdrop-filter: blur(10px);
  text-transform: uppercase;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
}

.hero-title {
  font-family: "Outfit", sans-serif;
  font-size: clamp(3.5rem, 9vw, 8rem); /* Massive text */
  font-weight: 900;
  line-height: 0.9;
  margin-bottom: 2rem;
  text-transform: uppercase;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.text-gradient {
  /* Gradient from White to Gold to Transparent (Fade) */
  background: linear-gradient(
    180deg,
    #ffffff 20%,
    #ffd700 70%,
    rgba(255, 215, 0, 0.1) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  /* Removed drop-shadow glow */
}

.hero-subtitle {
  font-size: 1.3rem;
  color: rgba(255, 255, 255, 0.6);
  max-width: 700px;
  margin: 0 auto;
  font-weight: 300;
  letter-spacing: 0.5px;
  line-height: 1.6;
}

/* --- Bento Grid --- */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: 280px 280px; /* Two rows */
  gap: 1.5rem;
  margin-bottom: 6rem;
}

/* Responsive Grid */
@media (max-width: 1200px) {
  .bento-grid {
    grid-template-rows: 350px 250px;
  }
}
@media (max-width: 900px) {
  .bento-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 300px); /* Stack vertically */
  }
}
@media (max-width: 600px) {
  .bento-grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
}

/* Card Styles */
.bento-card {
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  border-radius: 30px; /* Softer corners */
  position: relative;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.bento-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--glass-highlight);
  transform: translateY(-8px);
  box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.6);
}

/* Tournaments: Span 2 cols, 2 rows */
.card-tournaments {
  grid-column: span 2;
  grid-row: span 2;
  padding: 2.5rem;
}
@media (max-width: 900px) {
  .card-tournaments {
    grid-column: span 2;
  }
}
@media (max-width: 600px) {
  .card-tournaments {
    grid-column: span 1;
    min-height: 450px;
  }
}

/* Background de la card de torneos */
.card-bg--tournaments {
  background-image: url("/assets/images/community_events.png");
}

.card-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 1s ease;
}
.bento-card:hover .card-bg {
  transform: scale(1.15);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.9) 10%,
    rgba(0, 0, 0, 0.3) 60%,
    rgba(0, 0, 0, 0.1) 100%
  );
  z-index: 1;
}

.card-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.card-content.centered {
  align-items: center;
  justify-content: center;
  text-align: center;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: #ff0055;
  border-radius: 50%;
  margin-right: 8px;
  box-shadow: 0 0 15px #ff0055;
  display: inline-block;
}
.label {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: white;
  text-transform: uppercase;
}

.card-tournaments h3 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
  line-height: 1;
}
.card-tournaments p {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2rem;
  max-width: 400px;
}

.btn-glass-sm {
  padding: 1rem 2rem;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 12px;
  color: white;
  font-weight: 700;
  text-decoration: none;
  backdrop-filter: blur(10px);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: 0.3s;
}
.btn-glass-sm:hover {
  background: white;
  color: black;
}

/* Discord Card */
.card-discord {
  background: linear-gradient(135deg, #5865f2 0%, #404eed 100%);
  grid-column: span 1;
  grid-row: span 1;
  border: none;
}
.card-discord .logo-main {
  font-size: 3.5rem;
  margin-bottom: 1rem;
}
.card-discord h3 {
  font-size: 1.4rem;
  font-weight: 800;
}
.card-discord p {
  margin-bottom: 1.5rem;
  opacity: 0.9;
}

.btn-discord {
  background: white;
  color: #5865f2;
  padding: 0.8rem 1.5rem;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.9rem;
  text-decoration: none;
  transition: transform 0.2s;
}
.btn-discord:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}
.bg-icon {
  position: absolute;
  font-size: 12rem;
  right: -3rem;
  bottom: -4rem;
  opacity: 0.15;
  transform: rotate(-20deg);
  pointer-events: none;
}

/* Small Cards: Streamers & Art & Legends */
.card-streamers,
.card-art,
.card-legends {
  padding: 2rem;
}
.icon-box {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 1rem;
}
.icon-box.purple {
  background: rgba(157, 78, 221, 0.2);
  color: #9d4edd;
  border: 1px solid rgba(157, 78, 221, 0.2);
}
.icon-box.pink {
  background: rgba(255, 0, 127, 0.2);
  color: #ff007f;
  border: 1px solid rgba(255, 0, 127, 0.2);
}

/* Leyendas: Diseño Premium Mejorado con Imagen */
.card-legends {
  background: black; /* Fallback */
  border: 1px solid rgba(255, 215, 0, 0.3);
  position: relative;
  overflow: hidden;
}

/* Overlay específico para Leyendas para tintar la imagen de manera dorada/oscura */
.legends-overlay {
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.9) 10%,
    rgba(0, 0, 0, 0.3) 60%,
    rgba(0, 0, 0, 0.1) 100%
  );
  z-index: 1;
}

.card-legends::before {
  /* Pattern opcional encima de la imagen */
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1h2v2H1V1zm4 0h2v2H5V1zm4 0h2v2H9V1zm4 0h2v2h-2V1zm4 0h2v2h-2V1zM1 5h2v2H1V5zm4 0h2v2H5V5zm4 0h2v2H9V5zm4 0h2v2h-2V5zm4 0h2v2h-2V5zM1 9h2v2H1V9zm4 0h2v2H5V9zm4 0h2v2H9V9zm4 0h2v2h-2V9zm4 0h2v2h-2V9zM1 13h2v2H1v-2zm4 0h2v2H5v-2zm4 0h2v2H9v-2zm4 0h2v2h-2v-2zm4 0h2v2h-2v-2zM1 17h2v2H1v-2zm4 0h2v2H5v-2zm4 0h2v2H9v-2zm4 0h2v2h-2v-2zm4 0h2v2h-2v-2z' fill='%23ffd700' fill-opacity='0.05' fill-rule='evenodd'/%3E%3C/svg%3E");
  opacity: 0.6;
  pointer-events: none;
  z-index: 1; /* Encima de la imagen, debajo del contenido */
}

.card-legends:hover {
  border-color: #ffd700;
  box-shadow: 0 0 30px rgba(255, 215, 0, 0.2);
  transform: translateY(-8px);
}

.card-legends:hover .card-bg {
  transform: scale(1.1); /* Efecto zoom en la imagen */
}

.icon-box.gold {
  background: linear-gradient(135deg, #ffd700 0%, #ffb900 100%);
  color: #000;
  border: none;
  box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

.card-legends h3 {
  color: #ffd700;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.link-arrow {
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
  font-size: 0.9rem;
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: 0.3s;
}
.link-arrow:hover {
  color: white;
  gap: 10px;
}

/* --- TEAMS SHOWCASE SECTION --- */
.teams-showcase {
  margin-bottom: 8rem;
  padding-top: 2rem;
  border-top: 1px solid var(--glass-border);
}

.showcase-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 3rem;
}

.showcase-header h3 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  font-family: "Outfit";
  font-weight: 800;
}
.showcase-header p {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.5);
}

.btn-glass-outline {
  padding: 0.8rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50px;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: 0.3s;
}
.btn-glass-outline:hover {
  border-color: white;
  color: white;
}

/* The Track Container - Hide Scrollbar */
.teams-slider-wrapper {
  overflow: hidden; /* Hide scroll manual */
  padding: 2rem 0 4rem;
  margin: 0;
  width: 100%;
  position: relative;
  /* Mask for fade effect on edges */
  mask-image: linear-gradient(
    to right,
    transparent,
    black 10%,
    black 90%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    black 10%,
    black 90%,
    transparent
  );
}

.teams-slider {
  display: flex;
  gap: 2rem;
  width: max-content;
  /* Animation */
  animation: scroll 40s linear infinite;
  padding-right: 0; /* Remove explicit padding as we duplicate */
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-340px * 8 - 16rem));
  } /* Card Width (340) * 8 original items + gaps. Adjusted via JS roughly or calc */
  /* 
       Note: A more robust way is pure CSS with 50% move if cloned exactly once.
       Let's assume the JS clones the set twice (original + clone + clone). 
       Actually, standard marquee moves -50% if content is perfectly doubled.
    */
}

/* Adjust animation based on content size automatically is tricky in pure CSS without known width.
   Let's refine: The JS duplicates content. 
   If original width is W, we want to move by -W.
   For now, trust the visual, but let's make it smoother.
*/
.teams-slider {
  animation: scroll 60s linear infinite;
}

@keyframes scroll {
  to {
    /* Move by roughly half the total width (assuming 3 sets of items) */
    transform: translateX(-33.33%);
  }
}

/* SQUAD CARDS */
.squad-card {
  width: 320px;
  height: 420px;
  background: linear-gradient(
    160deg,
    rgba(255, 255, 255, 0.05) 0%,
    rgba(255, 255, 255, 0.01) 100%
  );
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 2rem;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.4s ease;
  cursor: pointer;
}

.squad-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at top right,
    rgba(255, 255, 255, 0.1),
    transparent 50%
  );
  opacity: 0;
  transition: 0.5s;
}
.squad-card:hover {
  transform: translateY(-10px);
  border-color: rgba(255, 255, 255, 0.2);
  background: linear-gradient(
    160deg,
    rgba(255, 255, 255, 0.08) 0%,
    rgba(255, 255, 255, 0.02) 100%
  );
}
.squad-card:hover::before {
  opacity: 1;
}

/* Rank Specific Colors */
.rank-gold {
  border-top: 4px solid #ffd700;
}
.rank-silver {
  border-top: 4px solid #c0c0c0;
}
.rank-diamond {
  border-top: 4px solid #b9f2ff;
}
.rank-plat {
  border-top: 4px solid #00f3ff;
}
.rank-emerald {
  border-top: 4px solid #50c878;
}

.squad-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.squad-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: #111;
  color: white;
  font-size: 2.5rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.div-badge {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.3);
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 1px;
}

.squad-info h4 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  font-family: "Outfit";
  font-weight: 700;
}

.stats-row {
  display: flex;
  gap: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.stat span {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
  font-weight: 700;
  letter-spacing: 1px;
}
.stat strong {
  font-size: 1.2rem;
  color: white;
  font-weight: 500;
}

/* 
   ========================================
   TEAM PROFILE / DETAIL PAGE STYLES 
   ========================================
*/

/* Team Detail Specific Styles */
body.community_team_detail {
  background-color: #1a050a; /* Fallback deep background */
  color: #ffeff4;
  min-height: 100vh;
}

.team-profile-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 5rem;
  gap: 2rem;
}

.team-profile-logo {
  width: 150px;
  height: 150px;
  background: #111;
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  font-weight: 800;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}
.team-profile-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-profile-info h1 {
  font-size: 4rem;
  font-family: "Outfit";
  font-weight: 800;
  margin: 1rem 0 0.5rem;
  line-height: 1;
  text-transform: uppercase;
  text-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}
.team-profile-info p {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.6);
}

/* ROSTER LAYOUTS */

/* 1. Main Row (Titulares) */
.roster-main-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.player-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: all 0.3s ease;
  cursor: default;
  position: relative;
  overflow: hidden;
}

.main-card {
  width: 200px; /* Uniform width */
  padding: 2rem 1rem;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.03) 0%,
    rgba(0, 0, 0, 0.2) 100%
  );
}

.player-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
}

.player-avatar {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, #222 0%, #111 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 1rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.player-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.player-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

/* 2. Secondary Sections (Subs & Staff) */
.secondary-section {
  margin-bottom: 3rem;
  text-align: center;
}

.section-title-sm {
  font-size: 1.2rem;
  opacity: 0.6;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  font-family: "Outfit";
  letter-spacing: 2px;
}

.roster-grid-sm {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.sm-card {
  padding: 1.5rem;
  min-width: 150px;
}
.sm-card h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

/* Badges */
.role-badge {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 50px;
  letter-spacing: 1px;
}

.role-badge-top {
  background: rgba(224, 79, 95, 0.1);
  color: #e04f5f;
  border: 1px solid rgba(224, 79, 95, 0.2);
}
.role-badge-jungle {
  background: rgba(80, 200, 120, 0.1);
  color: #50c878;
  border: 1px solid rgba(80, 200, 120, 0.2);
}
.role-badge-mid {
  background: rgba(157, 0, 255, 0.1);
  color: #9d00ff;
  border: 1px solid rgba(157, 0, 255, 0.2);
}
.role-badge-adc {
  background: rgba(0, 243, 255, 0.1);
  color: #00f3ff;
  border: 1px solid rgba(0, 243, 255, 0.2);
}
.role-badge-support {
  background: rgba(255, 215, 0, 0.1);
  color: #ffd700;
  border: 1px solid rgba(255, 215, 0, 0.2);
}

.section-title {
  font-size: 2rem;
  font-weight: 800;
  font-family: "Outfit";
  text-transform: uppercase;
  margin-bottom: 2rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.8);
}

/* 
    ========================================
    STREAMERS PAGE (OFFLINE VIBE)
    ========================================
 */
.page-streamers {
  background-color: #0b0205; /* Deeper black/purple */
  background-image:
    linear-gradient(rgba(157, 78, 221, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(157, 78, 221, 0.05) 1px, transparent 1px);
  background-size: 50px 50px;
  min-height: 100vh;
  color: #e0d0db;
  overflow: hidden;
}

/* Offline Player Container */
.offline-player-container {
  max-width: 900px;
  margin: 4rem auto;
  position: relative;
  border: 1px solid rgba(157, 78, 221, 0.3);
  background:
    linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
    url("../../images/en-construccion.png");
  background-size: cover;
  background-position: center;
  border-radius: 8px;
  aspect-ratio: 16/9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 50px rgba(157, 78, 221, 0.15);
}

/* Glitch Text Effect */
.glitch-text {
  font-size: 5rem;
  font-weight: 900;
  text-transform: uppercase;
  position: relative;
  color: white;
  letter-spacing: 5px;
  font-family: "Outfit";
  text-shadow:
    2px 2px 0px #ff00ff,
    -2px -2px 0px #00ffff;
  animation: glitch-skew 1s cubic-bezier(0.25, 0.46, 0.45, 0.94) both infinite;
}

@keyframes glitch-skew {
  0% {
    transform: translate(0);
  }
  10% {
    transform: translate(-2px, -2px);
  }
  20% {
    transform: translate(2px, 2px);
  }
  30% {
    transform: translate(-2px, 2px);
  }
  40% {
    transform: translate(2px, -2px);
  }
  50% {
    transform: translate(0);
  }
  100% {
    transform: translate(0);
  }
}

.offline-subtext {
  margin-top: 1rem;
  font-size: 1.5rem;
  color: #9d4edd;
  font-family: "Courier New", monospace;
  letter-spacing: 2px;
}

.loading-bar-container {
  width: 300px;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  margin-top: 2rem;
  border-radius: 2px;
  overflow: hidden;
}

.loading-bar {
  width: 0%;
  height: 100%;
  background: #00f3ff;
  animation: progress 3s ease-in-out infinite;
  box-shadow: 0 0 10px #00f3ff;
}

@keyframes progress {
  0% {
    width: 0%;
    opacity: 1;
  }
  50% {
    width: 100%;
    opacity: 1;
  }
  90% {
    opacity: 0;
  }
  100% {
    width: 0%;
    opacity: 0;
  }
}

/* Floating Emotes (Decoration) */
.floating-emote {
  position: absolute;
  font-size: 2rem;
  opacity: 0.2;
  animation: floatUp 8s linear infinite;
  pointer-events: none;
  color: #9d4edd; /* Tint them purple/theme color */
}

@keyframes floatUp {
  0% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }
  20% {
    opacity: 0.3;
  }
  80% {
    opacity: 0.3;
  }
  100% {
    transform: translateY(-10vh) rotate(360deg);
    opacity: 0;
  }
}

/* 
    ========================================
    ART GALLERY PAGE (MUSEUM VIBE)
    ========================================
 */
.page-gallery {
  background-color: #0f0f11; /* Dark Charcoal */
  min-height: 100vh;
  color: #f0f0f0;
  position: relative;
  overflow: hidden;
}

/* Spotlight Effect on top */
.spotlight-overlay {
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 80vh;
  background: radial-gradient(
    ellipse at center,
    rgba(255, 255, 255, 0.08) 0%,
    transparent 70%
  );
  pointer-events: none;
  z-index: 1;
}

.gallery-wall {
  max-width: 1200px;
  margin: 6rem auto;
  position: relative;
  z-index: 10;
  text-align: center;
}

.gallery-title-box {
  margin-bottom: 6rem;
  position: relative;
  display: inline-block;
}

.gallery-title {
  font-family: "Playfair Display", serif; /* Or fallback serif */
  font-size: 4rem;
  font-weight: 400;
  letter-spacing: 5px;
  color: #e0e0e0;
  text-transform: uppercase;
  position: relative;
}

.gallery-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 1px;
  background: #cba135; /* Gold accent */
  margin: 20px auto 0;
}

.frame-container {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  perspective: 1000px;
}

.empty-frame {
  width: 250px;
  height: 350px;
  border: 15px solid #222;
  border-color: #2a2a2a #1a1a1a #1a1a1a #2a2a2a; /* Bevel effect */
  background: #111;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  transform: rotateY(0deg);
  transition: transform 0.5s ease;
}

.empty-frame:hover {
  transform: rotateY(5deg) scale(1.05);
}

/* Gold Frame Variation */
.empty-frame.gold {
  border-color: #5c4814 #3b2e0d #3b2e0d #5c4814;
  box-shadow: 0 0 30px rgba(203, 161, 53, 0.1);
  background:
    linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)),
    url("../../images/en-construccion.png");
  background-size: cover;
  background-position: center;
}

.frame-content {
  opacity: 0.3;
  color: #555;
  font-family: serif;
  font-style: italic;
  font-size: 1.5rem;
}

.rope {
  position: absolute;
  top: -60px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 60px;
  background: rgba(255, 255, 255, 0.1);
}
.rope::after {
  content: "";
  width: 8px;
  height: 8px;
  background: #333;
  border-radius: 50%;
  position: absolute;
  top: 0;
  left: -3px;
}

.curator-note {
  margin-top: 5rem;
  font-family: serif;
  font-size: 1.2rem;
  color: #888;
  font-style: italic;
}

/* ===========================================
   RESPONSIVE: MEJORAS PARA DISPOSITIVOS MOVILES
   =========================================== */

/* Tablets y pantallas medianas */
@media (max-width: 900px) {
  .container {
    padding: 0 1.5rem;
  }

  .community-hero {
    padding: 6rem 1rem 3rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
    padding: 0 1rem;
  }

  /* Showcase header: apilar verticalmente */
  .showcase-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    text-align: left;
  }

  .showcase-header h3 {
    font-size: 2rem;
  }

  .showcase-header p {
    font-size: 1rem;
  }

  .btn-glass-outline {
    align-self: flex-start;
  }

  /* Reducir tamaño de squad cards en tablet */
  .squad-card {
    width: 280px;
    height: 360px;
    padding: 1.5rem;
  }

  .squad-icon {
    width: 65px;
    height: 65px;
    font-size: 2rem;
  }

  .squad-info h4 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }
}

/* Moviles */
@media (max-width: 600px) {
  .container {
    padding: 0 1rem;
  }

  /* Hero section compacto para movil */
  .community-hero {
    padding: 5rem 0.75rem 2.5rem;
  }

  .pill-badge {
    padding: 6px 14px;
    font-size: 0.7rem;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
  }

  .hero-title {
    font-size: clamp(2.2rem, 12vw, 3.5rem);
    margin-bottom: 1.5rem;
  }

  .hero-subtitle {
    font-size: 0.95rem;
    line-height: 1.5;
    padding: 0 0.5rem;
  }

  /* Bento grid: ajustes adicionales en movil */
  .bento-grid {
    gap: 1rem;
    margin-bottom: 4rem;
  }

  .bento-card {
    border-radius: 20px;
  }

  .card-tournaments {
    min-height: 380px;
    padding: 1.5rem;
  }

  .card-tournaments h3 {
    font-size: 1.8rem;
  }

  .card-tournaments p {
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
  }

  .btn-glass-sm {
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
    gap: 8px;
  }

  /* Discord card en movil */
  .card-discord {
    min-height: 280px;
  }

  .card-discord .logo-main {
    font-size: 2.5rem;
  }

  .card-discord h3 {
    font-size: 1.2rem;
  }

  .card-discord p {
    font-size: 0.9rem;
    margin-bottom: 1rem;
  }

  .btn-discord {
    padding: 0.7rem 1.2rem;
    font-size: 0.85rem;
  }

  /* Cards pequeñas: streamers y art */
  .card-streamers,
  .card-art {
    padding: 1.5rem;
    min-height: 180px;
  }

  .icon-box {
    width: 48px;
    height: 48px;
    font-size: 1.5rem;
    border-radius: 12px;
  }

  .card-streamers h3,
  .card-art h3 {
    font-size: 1.1rem;
  }

  .card-streamers p,
  .card-art p {
    font-size: 0.85rem;
  }

  .link-arrow {
    font-size: 0.85rem;
  }

  /* Teams showcase: diseño completamente vertical en movil */
  .teams-showcase {
    margin-bottom: 5rem;
    padding-top: 1.5rem;
  }

  .showcase-header {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
    margin-bottom: 2rem;
    text-align: center;
  }

  .showcase-header > div {
    text-align: center;
  }

  .showcase-header h3 {
    font-size: 1.5rem;
    line-height: 1.2;
  }

  .showcase-header p {
    font-size: 0.9rem;
  }

  .btn-glass-outline {
    align-self: center;
    width: 100%;
    text-align: center;
    padding: 0.9rem 1rem;
    font-size: 0.9rem;
  }

  /* Slider de equipos responsive */
  .teams-slider-wrapper {
    padding: 1.5rem 0 3rem;
    /* Quitar mascara en movil para mejor visibilidad */
    mask-image: none;
    -webkit-mask-image: none;
  }

  .teams-slider {
    gap: 1rem;
  }

  /* Squad cards mucho mas compactas en movil */
  .squad-card {
    width: 260px;
    height: 320px;
    padding: 1.25rem;
    border-radius: 18px;
  }

  .squad-icon {
    width: 56px;
    height: 56px;
    font-size: 1.6rem;
    border-radius: 14px;
  }

  .squad-info h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
  }

  .stats-row {
    gap: 1.5rem;
    padding-top: 1rem;
  }

  .stat span {
    font-size: 0.65rem;
  }

  .stat strong {
    font-size: 1rem;
  }

  /* Efectos glow reducidos en movil para mejor rendimiento */
  .glow-bg-top {
    height: 400px;
    opacity: 0.7;
  }

  .glow-bg-bottom {
    width: 400px;
    height: 400px;
    opacity: 0.5;
  }
}

/* Pantallas muy pequeñas (menos de 380px) */
@media (max-width: 380px) {
  .hero-title {
    font-size: 2rem;
  }

  .showcase-header h3 {
    font-size: 1.3rem;
  }

  .squad-card {
    width: 240px;
    height: 300px;
  }

  .squad-icon {
    width: 50px;
    height: 50px;
    font-size: 1.4rem;
  }

  .squad-info h4 {
    font-size: 1.15rem;
  }
}

/* ===========================================
   RESPONSIVE: DETALLE DE EQUIPO (ROSTER)
   =========================================== */

/* Tablets */
@media (max-width: 900px) {
  /* Header del equipo */
  .team-profile-header {
    margin-bottom: 3rem;
    gap: 1.5rem;
  }

  .team-profile-logo {
    width: 120px;
    height: 120px;
    font-size: 3rem;
    border-radius: 24px;
  }

  .team-profile-info h1 {
    font-size: 2.8rem;
  }

  .team-profile-info p {
    font-size: 1rem;
  }

  /* Roster principal: 3 columnas en tablet */
  .roster-main-row {
    gap: 1rem;
  }

  .player-card.main-card {
    width: 180px;
    padding: 1.5rem 1rem;
  }

  .player-avatar {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }

  .player-card h3 {
    font-size: 1rem;
  }

  .section-title {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
  }
}

/* Moviles */
@media (max-width: 600px) {
  /* Container del detalle */
  .container.relative-z {
    padding-top: 6rem !important;
    padding-bottom: 3rem !important;
  }

  /* Header del equipo compacto */
  .team-profile-header {
    margin-bottom: 2.5rem;
    gap: 1rem;
  }

  .team-profile-logo {
    width: 100px;
    height: 100px;
    font-size: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.4);
  }

  .team-profile-info h1 {
    font-size: 2rem;
    margin: 0.5rem 0 0.3rem;
  }

  .team-profile-info p {
    font-size: 0.9rem;
  }

  /* Titulo de seccion */
  .section-title {
    font-size: 1.4rem;
    margin-bottom: 1.25rem;
    letter-spacing: 1px;
  }

  /* Roster principal: grid de 2 columnas en movil */
  .roster-main-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    justify-items: center;
    margin-bottom: 2.5rem;
  }

  /* Tarjetas de jugador compactas */
  .player-card {
    border-radius: 16px;
  }

  .player-card.main-card {
    width: 100%;
    max-width: 160px;
    padding: 1.25rem 0.75rem;
  }

  .player-avatar {
    width: 52px;
    height: 52px;
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
    border-radius: 50%;
  }

  .player-card h3 {
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
    word-break: break-word;
  }

  .role-badge {
    font-size: 0.6rem;
    padding: 3px 8px;
  }

  .role-badge img {
    width: 16px !important;
    height: 16px !important;
  }

  /* Secciones secundarias (suplentes y staff) */
  .secondary-section {
    margin-bottom: 2rem;
  }

  .section-title-sm {
    font-size: 1rem;
    margin-bottom: 1rem;
    letter-spacing: 1.5px;
  }

  .roster-grid-sm {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    justify-items: center;
  }

  .player-card.sm-card {
    width: 100%;
    max-width: 140px;
    padding: 1rem 0.5rem;
    min-width: auto;
  }

  .sm-card h3 {
    font-size: 0.85rem;
  }

  /* Boton de volver */
  .btn-glass-outline {
    padding: 0.8rem 1.2rem;
    font-size: 0.85rem;
  }
}

/* Pantallas muy pequenas */
@media (max-width: 380px) {
  .team-profile-logo {
    width: 80px;
    height: 80px;
    font-size: 2rem;
  }

  .team-profile-info h1 {
    font-size: 1.6rem;
  }

  .section-title {
    font-size: 1.2rem;
  }

  .player-card.main-card {
    max-width: 140px;
    padding: 1rem 0.5rem;
  }

  .player-avatar {
    width: 44px;
    height: 44px;
    font-size: 1.1rem;
  }

  .player-card h3 {
    font-size: 0.85rem;
  }
}

/* ===========================================
   CLASES UTILITARIAS PARA ELIMINAR INLINE STYLES
   =========================================== */

/* Mensaje cuando no hay contenido */
.empty-message {
  color: rgba(255, 255, 255, 0.3);
  text-align: center;
  padding: 2rem;
}

.empty-message--light {
  color: white;
}

.empty-message--grid-full {
  grid-column: 1 / -1;
}

/* Bento cards que son enlaces */
.bento-card-link {
  text-decoration: none;
  color: inherit;
}

/* Squad icon con imagen */
.squad-icon {
  overflow: hidden;
}

.squad-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Container con padding vertical */
.container--padded {
  padding-top: 8rem;
  padding-bottom: 5rem;
}

.container--padded-bottom {
  padding-bottom: 8rem;
}

/* Role badge con icono de posicion */
.role-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
}

.role-badge img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

/* Role badge para suplentes */
.role-badge--sub {
  background: rgba(255, 255, 255, 0.1);
  color: #aaa;
}

/* Role badge para staff */
.role-badge--staff {
  background: #444;
  color: white;
}

/* Seccion de volver - footer de pagina */
.page-back-section {
  margin-top: 5rem;
  text-align: center;
}

/* ===========================================
   TEAMS GRID LAYOUT (Lista completa de equipos)
   =========================================== */
.teams-grid-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  justify-items: center;
}

.teams-grid-layout .squad-card {
  width: 100%;
  max-width: 340px;
}

@media (max-width: 600px) {
  .teams-grid-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .teams-grid-layout .squad-card {
    max-width: 100%;
  }
}

/* ===========================================
   STREAMERS PAGE - ESTILOS ADICIONALES
   =========================================== */

/* Hero con padding reducido para streamers */
.community-hero--compact {
  padding-bottom: 2rem;
}

/* Pill badge variante morada (Twitch) */
.pill-badge--purple {
  border-color: #9d4edd;
  color: #9d4edd;
  background: rgba(157, 78, 221, 0.1);
}

/* Texto con color morado */
.text-purple {
  color: #9d4edd;
}

/* Seccion de info de construccion */
.construction-info {
  text-align: center;
  margin-top: 2rem;
  position: relative;
  z-index: 10;
}

.construction-text {
  font-family: "Courier New", monospace;
  color: rgba(255, 255, 255, 0.5);
  max-width: 600px;
  margin: 0 auto 2rem;
}

/* Boton variante morada */
.btn-glass-sm--purple {
  background: rgba(157, 78, 221, 0.1);
  border-color: #9d4edd;
}

/* Emotes flotantes con posicion */
.floating-emote--left-10 {
  left: 10%;
}
.floating-emote--left-20 {
  left: 20%;
}
.floating-emote--right-15 {
  right: 15%;
}
.floating-emote--right-25 {
  right: 25%;
}

.floating-emote--delay-0 {
  animation-delay: 0s;
}
.floating-emote--delay-1 {
  animation-delay: 1s;
}
.floating-emote--delay-2 {
  animation-delay: 2s;
}
.floating-emote--delay-4 {
  animation-delay: 4s;
}

/* ===========================================
   ART GALLERY - ESTILOS ADICIONALES
   =========================================== */

/* Subtitulo de galeria */
.gallery-subtitle {
  font-family: serif;
  font-style: italic;
  color: #888;
  margin-top: 1rem;
}

/* Frame destacado (dorado) */
.empty-frame--featured {
  transform: scale(1.1);
}

.empty-frame--featured .rope {
  height: 40px;
  top: -40px;
}

.empty-frame--featured .frame-content {
  color: #cba135;
}

/* Boton de salir de galeria */

/* ===========================================
   IMPROVED LEGENDS CARD STYLES
   (Mobile & Light Mode Overrides)
   =========================================== */

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .card-legends {
    min-height: 250px;
    padding: 1.5rem;
  }

  .card-legends h3 {
    font-size: 1.8rem;
  }

  .card-legends p {
    font-size: 1rem;
    max-width: 90%;
  }

  .card-legends .icon-box {
    width: 45px;
    height: 45px;
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
  }
}

/* Light Mode Support */
html[data-theme="light"] .card-legends {
  background: #fff;
  border-color: rgba(255, 215, 0, 0.6);
  box-shadow: 0 5px 20px rgba(255, 215, 0, 0.15);
}

html[data-theme="light"] .legends-overlay {
  /* Dark overlay to support white text even in light mode */
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.9) 10%,
    rgba(0, 0, 0, 0.3) 60%,
    rgba(0, 0, 0, 0.1) 100%
  );
}

html[data-theme="light"] .card-legends h3 {
  color: #ffd700; /* Bright native gold */
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

html[data-theme="light"] .card-legends p {
  color: #fff !important; /* White text requested */
  font-weight: 500;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

html[data-theme="light"] .card-legends .link-arrow {
  color: rgba(255, 255, 255, 0.9) !important;
  font-weight: 500;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

html[data-theme="light"] .card-legends .link-arrow:hover {
  color: #ffd700;
}

html[data-theme="light"] .card-legends::before {
  opacity: 0.1; /* Faint pattern on light mode */
}

