  body {
  background-color: #00215E;
  background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI1MCIgaGVpZ2h0PSI1MCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSIjRkZDQzAwIiBzdHJva2U9IiNGRkNDMDAiIHN0cm9rZS13aWR0aD0iMSIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PHBvbHlnb24gcG9pbnRzPSIxMiw yID E1IDkgMjIgOSAxNyAxNCAxOSAyMSAxMiAxNyA1IDIxIDcgMTQgMiA5IDkgOSIvPjwvc3ZnPg==');
  background-repeat: repeat;
  background-size: 190px 190px;
  color: white;
  font-family: 'Roboto', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  margin: 0; padding: 0;
  display: flex; flex-direction: column; align-items: center;
  min-height: 100vh;
}

  header {
  background-color: #F5B041;
  color: #00215E;
  padding: 15px;
  font-weight: 700;
  font-size: 1.8em;
  width: 100%;
  text-align: center;

  font-family: 'Impact', 'Arial Black', sans-serif
}

  #datos-partido {
    background-color: #001B3D;
    padding: 10px 20px;
    width: 100%;
    max-width: 1100px;
    box-sizing: border-box;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
  }
  #datos-partido input {
    padding: 8px 12px;
    font-size: 1em;
    border-radius: 6px;
    border: none;
    width: 200px;
    max-width: 100%;
    font-weight: 500;
  }
  #datos-partido button {
    background-color: #F5B041;
    color: #00215E;
    font-weight: 700;
    border: none;
    border-radius: 6px;
    padding: 10px 18px;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  #datos-partido button:hover {
    background-color: #d59431;
  }

  #contenedor {
    display: flex;
    flex-direction: row;
    gap: 20px;
    margin: 20px;
    max-width: 1100px;
    width: 100%;
    box-sizing: border-box;
  }
  #formacionSelector {
    flex: 1;
    max-width: 220px;
    display: flex;
    flex-direction: column;
  }
  #formacionSelector label {
    font-weight: 700;
    font-size: 1.1em;
  }
  #formacionSelector select,
  #formacionSelector input[type="text"] {
    margin-top: 8px;
    width: 100%;
    font-size: 1em;
    border-radius: 6px;
    border: none;
    padding: 8px;
    font-weight: 500;
    box-sizing: border-box;
  }
  #formacionSelector button {
    margin-top: 12px;
    width: 100%;
    font-weight: 700;
    padding: 12px;
    background-color: #F5B041;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  #formacionSelector button:hover {
    background-color: #d59431;
  }
  #formacionSelector button.firebase-btn {
    background-color: #1A73E8;
    color: white;
  }
  #formacionSelector button.firebase-btn:hover {
    background-color: #155cb0;
  }

#cancha {
  position: relative;
  flex: 3;
  background-color: #004400;
  border: 3px solid #F5B041;
  border-radius: 14px;
  height: 480px;       /* altura reducida */
  min-width: 480px;    /* ancho mínimo reducido */
  box-shadow: 0 0 10px #F5B041;
}

#titulo-equipos { 
  background-color: #003060;
  color: #F5B041;
  padding: 10px 20px;
  border-radius: 8px;
  text-align: center;
  font-weight: 700;
  font-size: 1.5em;
  margin-bottom: 15px;
}


.posicion {
  position: absolute;
  background-color: #F5B041;
  color: #00215E;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 0.85em;
  font-weight: 700;
  width: auto;           /* ancho automático según el contenido */
  min-width: 80px;       /* opcional, evita que se achique demasiado */
  max-width: 180px;      /* opcional, limita extremos para no romper la cancha */
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-sizing: border-box;
  box-shadow: 0 0 6px rgba(0,0,0,0.4);
  white-space: nowrap;   /* evita salto de línea */
  text-align: center;    /* centra el texto */
  transform: translate(-50%, -50%); /* mantiene centrado en la posición */
}


  .posicion label {
    font-size: 0.75em;
  }
  select.jugador-select {
    font-size: 0.85em;
    border-radius: 6px;
    border: 1px solid #ccc;
    padding: 6px 8px;
    font-weight: 500;
  }

  #equipos-enviados {
    background-color: #001B3D;
    padding: 20px 30px;
    width: 100%;
    max-width: 1100px;
    box-sizing: border-box;
    border-radius: 14px;
    margin-top: 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
  }
  #equipos-enviados h2 {
    color: #F5B041;
    width: 100%;
    margin-top: 0;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 700;
    font-size: 1.5em;
  }

  .equipo-container {
    background-color: #003060;
    border-radius: 12px;
    padding: 15px 20px;
    width: 320px;
    box-sizing: border-box;
    box-shadow: 0 0 10px #F5B041AA;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .info-partido {
  background-color: #0033a0; /* azul más intenso */
  padding: 10px;
  border-radius: 8px;
  color: rgb(210, 171, 0);
  font-family: 'Montserrat', sans-serif; /* ← nueva fuente */
  font-weight: 600;        /* un poco menos que 700 si querés que no grite tanto */
  font-size: 1.1em;        /* un poco más grande para destacar */
  text-align: center;
  margin-bottom: 1rem;
  line-height: 1.5;        /* mejora la lectura */
}

  /* Mini-cancha */
.mini-cancha {
    position: relative;
    background: linear-gradient(90deg, #004080, #003060);
    border: 2px solid #F5B041;
    border-radius: 10px;
    width: 300px;
    height: 260px; /* Aumentamos altura */
    margin-bottom: 15px;
    box-shadow: 0 0 8px #F5B041AA;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 12px;
}

.mini-cancha .fila {
    display: flex;
    justify-content: center;
    gap: 40px; /* Aumentamos separación horizontal */
    margin: 12px 0; /* Aumentamos separación vertical */
}

.mini-cancha .jugador {
    background-color: #FFD700;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    color: #000;
    box-shadow: 0 0 4px #00000088;
}



  .mini-posicion {
  position: absolute;
  background-color: #F5B041;
  color: #00215E;
  border-radius: 6px;
  padding: 4px 6px;
  font-size: 0.7em;
  font-weight: 700;
  width: auto;
  min-width: 60px;       /* opcional: para que no se achique demasiado */
  max-width: 140px;      /* opcional: para limitar extremos */
  box-sizing: border-box;
  white-space: nowrap;   /* evita que el texto haga salto de línea */
  overflow: visible;     /* permite que todo el texto se vea */
  text-align: center;
  transform: translate(-50%, -50%);
}


  .mini-posicion label {
    display: none;
}
  .mini-posicion span {
    display: block;
    margin-top: 3px;
  }

  .botones-voto {
    margin-top: 10px;
    display: flex;
    gap: 12px;
  }
  .botones-voto button {
    background-color: #F5B041;
    border: none;
    color: #00215E;
    font-weight: 700;
    cursor: pointer;
    border-radius: 6px;
    padding: 8px 14px;
    font-size: 0.9em;
    transition: background-color 0.3s ease;
  }
  .botones-voto button:hover:not(:disabled) {
    background-color: #d59431;
  }
  .botones-voto button:disabled {
    opacity: 0.5;
    cursor: default;
  }
  .votos {
    margin-top: 5px;
    font-size: 0.85em;
  }

  /* Estilos para 11 ideal */
#once-ideal {
  background-color: #001B3D;
  width: 100%;
  max-width: 1100px;
  box-sizing: border-box;
  border-radius: 14px;
  margin-top: 40px;
  padding: 20px 30px;
}
#once-ideal h2 {
  color: #F5B041;         /* Amarillo Boca */
  margin-top: 0;
  margin-bottom: 25px;
  text-align: center;
  font-weight: 700;       /* Negrita */
  font-size: 1.8em;       /* Un poquito más grande */
  font-family: 'Montserrat', sans-serif;  /* Nueva fuente */
  letter-spacing: 1px;    /* Espaciado entre letras para darle más estilo */
  text-transform: uppercase; /* MAYÚSCULAS para que quede más deportivo */
}

#cancha-ideal {
  position: relative;
  background: linear-gradient(90deg, #004080, #003060);
  border: 3px solid #F5B041;
  border-radius: 14px;
  height: 420px;
  min-width: 600px;
  margin: 0 auto;
  box-shadow: 0 0 10px #F5B041;
}
.posicion-ideal {
  position: absolute;
  background-color: #F5B041;
  color: #00215E;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 0.9em;
  font-weight: 700;
  width: 140px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-sizing: border-box;
  box-shadow: 0 0 6px rgba(0,0,0,0.4);

  /* Centrar el texto dentro de la caja */
  align-items: center;
  text-align: center;

  /* Centrar la caja en la posición exacta */
  transform: translate(-50%, -50%);
}


  .posicion-ideal label {
    display: none;
}
  .posicion-ideal span {
    font-weight: 600;
  }

  #equipos-firebase {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  padding: 0.5rem;
}

.equipo-container {
  background: #f9f9f9;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 1rem;
  box-shadow: 0 0 5px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
  #equipos-firebase {
    grid-template-columns: 1fr;
  }
}

.boton-me-gusta {
  background: linear-gradient(90deg, #0033A0 0%, #FFC72C 100%);
  border: none;
  color: #fff;
  padding: 6px 12px;
  font-weight: bold;
  cursor: pointer;
  border-radius: 5px;
  margin-top: 10px;
  transition: background 0.3s ease;
  user-select: none;
}

.boton-me-gusta:hover {
  background: linear-gradient(90deg, #00277A 0%, #FFB800 100%);
}

.titulo-principal {
  text-align: center;
  margin-top: 15px;
  font-family: 'Impact', 'Arial Black', sans-serif;
}

.titulo-principal h1 {
  font-size: 3em;
  font-weight: bold;
  margin-bottom: 8px;
  color: #06080a; /* Azul Boca */
  text-shadow: 3px 3px 0 #fcbf00, 5px 5px 0 #000000; /* Amarillo y un toque de sombra negra */
  letter-spacing: 2px;
}

.titulo-principal p {
  font-size: 1.3em;
  font-weight: bold;
  color: #f7ae03; /* Amarillo Boca */
  text-shadow: 2px 2px 0 #0033a0, 4px 4px 0 #000000; /* Azul y sombra negra */
  letter-spacing: 1px;
}

.equipo-container {
  background: #0033a0; /* Azul Boca */
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 1rem;
  box-shadow: 0 0 5px rgba(0,0,0,0.1);
  color: #ffcc00; /* Amarillo Boca */
}

.boton-compartir {
  background-color: #F5B041;
  color: #00215E;
  border: none;
  padding: 6px 12px;
  margin-top: 6px;
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.boton-compartir:hover {
  background-color: #d59431;
}

.titulo-filtro {
  font-family: 'Montserrat', sans-serif; /* misma fuente que “Once Ideal” */
  font-weight: 700;
  font-size: 1.2em;
  text-align: center;
  color: #ffffff; /* amarillo Boca */
  margin-bottom: 1rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-shadow: 1px 1px 2px #000000; /* sombra para resaltar */
}

.select-filtro {
  display: block;
  margin: 0 auto 1rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 1em;
  padding: 5px 10px;
  border-radius: 6px;
  border: 1px solid #F5B041;
  background-color: #0033A0;
  color: #F5B041;
  font-weight: 700;
}
