/* ====== FUENTES Y RESET BÁSICO ====== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background-color: #050607;
  color: #e5e5e5;
  line-height: 1.5;
}

/* Títulos tipo Dota (serif dramática) */
h1, h2, h3, h4 {
  font-family: "Cinzel", "Times New Roman", serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ====== CONTENEDOR PRINCIPAL ====== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 16px 64px;
}

/* ====== HERO CON VIDEO DE FONDO ====== */
.hero {
  position: relative;
  height: 320px;
  overflow: hidden;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.1) contrast(1.1) brightness(0.8);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 0%, rgba(210, 145, 60, 0.4), transparent 55%),
              radial-gradient(circle at 80% 100%, rgba(0, 0, 0, 0.7), transparent 55%),
              linear-gradient(to bottom, rgba(0, 0, 0, 0.7), #050607 80%);
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 10%;
  color: #fdf3e5;
  text-shadow: 0 0 18px rgba(0, 0, 0, 0.9);
}

.hero-content h1 {
  font-size: 40px;
  margin-bottom: 8px;
  color: #f1c27d;
}

.hero-content p {
  max-width: 540px;
  font-size: 15px;
  color: #f0e0c0;
}

/* Pequeña línea debajo del título */
.hero-content h1::after {
  content: "";
  display: block;
  width: 60px;
  height: 2px;
  margin-top: 8px;
  background: linear-gradient(to right, #D2913C, transparent);
}

/* ====== NAV / ENCABEZADO SUPERIOR ====== */
.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 10%;
  background: linear-gradient(to bottom, #101217, transparent);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-logo img {
  width: 28px;
  height: 28px;
}

.header-logo span {
  font-family: "Cinzel", serif;
  color: #f1c27d;
  font-size: 18px;
  letter-spacing: 0.1em;
}

.header-status {
  font-size: 13px;
  color: #c4c4c4;
}

.header-status strong {
  color: #f2a644;
}

/* ====== SECCIÓN DE BIENVENIDA ====== */
.welcome-section {
  margin-top: 24px;
  background: radial-gradient(circle at top left, rgba(210, 145, 60, 0.15), transparent 50%),
              #0b0d10;
  border-radius: 12px;
  border: 1px solid #262a30;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.65);
}

.welcome-banner {
  width: 100%;
  height: 180px;
  overflow: hidden;
  position: relative;
}

.welcome-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.7) saturate(1.2);
}

.welcome-content {
  padding: 20px 24px 24px;
}

.welcome-content h2 {
  font-size: 22px;
  color: #f4d39a;
  margin-bottom: 12px;
}

.welcome-content p {
  font-size: 14px;
  line-height: 1.7;
  color: #c5c8cf;
  margin-bottom: 12px;
}

.welcome-content p strong {
  color: #f2a644;
}

.welcome-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.feature {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: rgba(242, 166, 68, 0.08);
  border: 1px solid #323844;
  border-radius: 8px;
  font-size: 13px;
  color: #f5deb3;
}

.feature-icon {
  font-size: 18px;
}

@media (max-width: 600px) {
  .welcome-banner {
    height: 120px;
  }

  .welcome-content h2 {
    font-size: 18px;
  }

  .welcome-content p {
    font-size: 13px;
  }

  .welcome-features {
    grid-template-columns: 1fr;
  }
}

/* ====== SECCIONES ====== */
.section {
  margin-top: 32px;
  background: radial-gradient(circle at top left, rgba(210, 145, 60, 0.12), transparent 50%),
              #0b0d10;
  border-radius: 12px;
  border: 1px solid #262a30;
  padding: 18px 20px 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.65);
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title span.icon {
  font-size: 18px;
}

.section-title h2 {
  font-size: 18px;
  color: #f4d39a;
}

.section-subtitle {
  font-size: 12px;
  color: #a8acb6;
}

/* Línea decorativa */
.section-divider {
  height: 1px;
  margin: 8px 0 12px;
  background: linear-gradient(to right, rgba(210, 145, 60, 0.9), transparent);
  opacity: 0.8;
}

/* ====== GRID PRINCIPAL ====== */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

@media (max-width: 900px) {
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* ====== TARJETAS ====== */
.card {
  background: radial-gradient(circle at top, rgba(255, 255, 255, 0.04), transparent 55%),
              #111319;
  border-radius: 10px;
  border: 1px solid #2b3139;
  padding: 14px 14px 16px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.8);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.card-header h3 {
  font-size: 14px;
  color: #f4d39a;
}

.card-header span {
  font-size: 11px;
  color: #9ea3ae;
}

/* ====== TABLA RANKING ====== */
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.table thead {
  background: linear-gradient(to right, rgba(210, 145, 60, 0.12), transparent);
}

.table thead th {
  padding: 6px 8px;
  text-align: left;
  font-weight: 500;
  color: #f7e1b4;
  border-bottom: 1px solid #30363f;
}

.table tbody tr {
  border-bottom: 1px solid #242931;
}

.table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.01);
}

.table tbody tr:hover {
  background: linear-gradient(to right, rgba(210, 145, 60, 0.12), transparent);
}

.table td {
  padding: 6px 8px;
  color: #d0d0d0;
}

.table td.pos {
  color: #f2a644;
  font-weight: 600;
}

.medal-icon {
  width: 20px;
  height: 20px;
  vertical-align: middle;
  margin-right: 4px;
}

/* ====== CARDS DE JUGADORES ====== */
.players-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.player-card {
  position: relative;
  background: radial-gradient(circle at top, rgba(242, 166, 68, 0.12), transparent 60%),
              #12151d;
  border: 1px solid #323844;
  border-radius: 10px;
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: transform 0.2s, border-color 0.2s;
  overflow: hidden;
}

/* IMAGEN DE FONDO DEL ROL (DIFUMINADA) */
.player-card::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
  height: 100%;
  background-size: 120px;
  background-position: right -10px center;
  background-repeat: no-repeat;
  opacity: 0.40;
  filter: blur(0px);
  pointer-events: none;
  z-index: 0;
}

/* Imágenes específicas por rol */
.player-card[data-role="carry"]::before {
  background-image: url('imgp/role_carry.png');
}

.player-card[data-role="mid"]::before {
  background-image: url('imgp/role_mid.png');
}

.player-card[data-role="off"]::before {
  background-image: url('imgp/role_off.png');
}

.player-card[data-role="soft"]::before {
  background-image: url('imgp/role_soft.png');
}

.player-card[data-role="hard"]::before {
  background-image: url('imgp/role_hard.png');
}

.player-card:hover {
  transform: translateY(-2px);
  border-color: #d2913c;
}

.player-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.player-name {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #f5deb3;
  font-weight: 500;
}

.player-role {
  font-size: 11px;
  color: #f2a644;
}

.player-stats {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #c5c8cf;
}

.player-stats div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.player-stats .label {
  color: #7d8087;
  font-size: 10px;
}

.player-stats .value {
  color: #f2a644;
  font-weight: 600;
}

/* ====== MATCH HISTORY ====== */
.match-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-item {
  border-radius: 8px;
  background: #12151d;
  border: 1px solid #2b3139;
  padding: 10px 12px;
  font-size: 12px;
  transition: border-color 0.2s;
}

.match-item:hover {
  border-color: #d2913c;
}

.match-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

.match-winner {
  color: #7ed321;
  font-weight: 600;
}

.match-meta {
  font-size: 11px;
  color: #a8acb6;
}

.match-teams {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid #1f242b;
}

.match-team {
  font-size: 11px;
  color: #c5c8cf;
}

.match-team strong {
  color: #f2a644;
  display: block;
  margin-bottom: 2px;
}

/* ====== ESTADÍSTICAS DE PARTIDAS ====== */
.match-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin: 8px 0;
  padding: 8px;
  background: rgba(242, 166, 68, 0.05);
  border-radius: 6px;
  border: 1px solid #1f242b;
}

.stat-item {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
}

.stat-label {
  color: #a8acb6;
}

.stat-value {
  color: #f2a644;
  font-weight: 600;
}

/* ====== BADGES / PILL ====== */
.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.badge-primary {
  background: linear-gradient(to right, #D2913C, #F2A644);
  color: #1b1208;
}

.badge-muted {
  background: #1f242b;
  color: #9ea3ae;
}

/* ====== FOOTER ====== */
.footer {
  margin-top: 32px;
  padding: 16px 0 0;
  font-size: 11px;
  color: #7d8087;
  text-align: center;
  border-top: 1px solid #1a1e23;
}