/* ============================================================
   CBA Listados - Estilos
   ============================================================ */

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    background: #f4f6f9;
    color: #222;
    line-height: 1.4;
}
.oculto { display: none !important; }

/* ----------- Login ----------- */
.pantalla-login {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #1e3a8a, #0ea5e9);
}
.caja-login {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 380px;
}
.caja-login h1 { margin: 0 0 5px 0; color: #1e3a8a; }
.caja-login .subtitulo { color: #666; margin-top: 0; margin-bottom: 24px; }
.caja-login label { display: block; margin-bottom: 8px; font-weight: 600; font-size: 14px; }
.caja-login input[type=password] {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    margin-bottom: 16px;
}
.caja-login button {
    width: 100%;
    padding: 12px;
    background: #1e3a8a;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    font-weight: 600;
}
.caja-login button:hover { background: #1e40af; }
.error {
    background: #fee2e2;
    color: #991b1b;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 14px;
}

/* ----------- Cabecera ----------- */
.cabecera {
    background: #1e3a8a;
    color: #fff;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.cabecera h1 { margin: 0; font-size: 20px; }
.cabecera .temporada {
    font-size: 13px;
    background: rgba(255,255,255,0.2);
    padding: 2px 10px;
    border-radius: 20px;
    margin-left: 8px;
    font-weight: normal;
}
.cabecera nav { display: flex; gap: 8px; align-items: center; }
.tab {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}
.tab.activo { background: #fff; color: #1e3a8a; font-weight: 600; }
.tab:hover:not(.activo) { background: rgba(255,255,255,0.1); }
.salir {
    color: #fff;
    text-decoration: none;
    padding: 8px 16px;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    font-size: 14px;
}
.salir:hover { background: rgba(255,255,255,0.1); }

/* ----------- Campana de cambios (altas/bajas de jugadores) ----------- */
.btn-cambios {
    position: relative;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    color: #fff;
    padding: 8px 12px;
    font-size: 16px;
    cursor: pointer;
    line-height: 1;
}
.btn-cambios:hover { background: rgba(255,255,255,0.1); }
.badge-cambios {
    position: absolute;
    top: -7px;
    right: -7px;
    background: #dc2626;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid #1e3a8a;
}
.lista-cambios { list-style: none; margin: 0; padding: 0; }
.lista-cambios li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #eef0f3;
}
.lista-cambios li:last-child { border-bottom: none; }
.cambio-info { flex: 1 1 auto; }
.cambio-fecha { color: #888; font-size: 13px; margin-top: 2px; }
.badge-alta {
    background: #d1fae5; color: #065f46;
    font-weight: 700; font-size: 11px;
    padding: 1px 7px; border-radius: 4px;
    margin-right: 6px;
}
.badge-baja {
    background: #fee2e2; color: #991b1b;
    font-weight: 700; font-size: 11px;
    padding: 1px 7px; border-radius: 4px;
    margin-right: 6px;
}
.btn-ok-cambio {
    flex: 0 0 auto;
    background: #1e3a8a;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}
.btn-ok-cambio:hover { background: #16296b; }

/* ----------- Contenido ----------- */
main {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}
.panel-tab { background: #fff; padding: 24px; border-radius: 10px; box-shadow: 0 1px 3px rgba(0,0,0,0.06); }
.cabecera-seccion {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 10px;
}
.cabecera-seccion h2, .cabecera-seccion h3 { margin: 0; }
.ayuda { color: #666; font-size: 14px; margin-top: -8px; margin-bottom: 14px; }
.cargando { color: #888; font-style: italic; }

/* ----------- Botones ----------- */
.btn-primario, .btn-secundario, .btn-exportar, .btn-volver, .btn-peligro {
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    border: 1px solid transparent;
    font-weight: 500;
}
.btn-primario { background: #1e3a8a; color: #fff; }
.btn-primario:hover { background: #1e40af; }
.btn-secundario { background: #fff; color: #374151; border-color: #d1d5db; }
.btn-secundario:hover { background: #f3f4f6; }
.btn-exportar { background: #059669; color: #fff; }
.btn-exportar:hover { background: #047857; }
.btn-peligro { background: #dc2626; color: #fff; }
.btn-peligro:hover { background: #b91c1c; }
.btn-volver {
    background: transparent;
    color: #1e3a8a;
    border: none;
    padding: 8px 0;
    font-size: 14px;
    margin-bottom: 14px;
}
.btn-volver:hover { text-decoration: underline; }

/* ----------- Grid equipos ----------- */
.grid-equipos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
}

/* ----------- Secciones por grupo ----------- */
/* Colores: Minibasket = rosa, Femenino = naranja, Masculino = azul */
.seccion-grupo { margin-bottom: 28px; }
.seccion-grupo:last-child { margin-bottom: 0; }
.titulo-grupo {
    margin: 0 0 14px 0;
    padding-bottom: 6px;
    font-size: 18px;
    border-bottom: 2px solid currentColor;
    display: flex;
    align-items: center;
    gap: 8px;
}
.titulo-grupo .contador {
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    border-radius: 20px;
    padding: 2px 10px;
    line-height: 1.4;
    white-space: nowrap;
}
/* Color de fondo de la pastilla, explícito por grupo */
.titulo-MINIBASKET .contador { background: #db2777; }
.titulo-FEMENINO   .contador { background: #ea580c; }
.titulo-MASCULINO  .contador { background: #1d4ed8; }

.titulo-MINIBASKET { color: #db2777; }   /* rosa */
.titulo-FEMENINO   { color: #ea580c; }   /* naranja */
.titulo-MASCULINO  { color: #1d4ed8; }   /* azul */

/* Barra de filtro por grupo */
.barra-equipos {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.filtro-grupos {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

/* Buscadores */
.buscador {
    padding: 8px 14px;
    border: 1px solid #d1d5db;
    border-radius: 20px;
    font-size: 14px;
    font-family: inherit;
    min-width: 280px;
    flex: 1 1 240px;
    max-width: 360px;
}
.buscador:focus {
    outline: none;
    border-color: #1e3a8a;
    box-shadow: 0 0 0 3px rgba(30,58,138,0.1);
}
.buscador-tabla {
    display: block;
    margin-bottom: 14px;
    border-radius: 6px;
    max-width: 100%;
    width: 100%;
}
.chip-filtro {
    flex: 0 0 auto;
    width: auto;
    height: auto;
    align-self: center;
    padding: 7px 16px;
    border-radius: 20px;
    border: 1px solid #d1d5db;
    background: #fff;
    color: #374151;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
}
.chip-filtro:hover { background: #f3f4f6; }
.chip-filtro.activo { color: #fff; border-color: transparent; }
.chip-filtro.activo[data-grupo="TODOS"]      { background: #1e3a8a; }
.chip-MINIBASKET.activo { background: #db2777; }
.chip-FEMENINO.activo   { background: #ea580c; }
.chip-MASCULINO.activo  { background: #1d4ed8; }

.card-equipo {
    position: relative;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
    transition: box-shadow .15s, transform .15s, background .15s, border-color .15s;
}
.card-equipo:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateY(-2px);
    border-color: #1e3a8a;
}
.card-equipo h3 { margin: 0 0 6px 0; color: #1e3a8a; font-size: 16px; padding-right: 30px; }
.card-equipo .cat { color: #666; font-size: 13px; margin: 0 0 10px 0; }
.card-equipo .entrenador-card {
    font-size: 13px;
    color: #374151;
    margin: 0 0 8px 0;
}
.card-equipo .etq-entrenador {
    font-weight: 700;
    font-size: 11px;
    letter-spacing: .5px;
    color: #1e3a8a;
}
.card-equipo .stats {
    display: flex;
    gap: 14px;
    font-size: 13px;
    color: #555;
}
.card-equipo .stats b { color: #1e3a8a; }

/* Coincidencia de jugador al buscar en la página principal */
.coincidencias-jugador {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px dashed #e5e7eb;
    font-size: 12px;
    color: #444;
}
.etiqueta-coincidencia {
    display: inline-block;
    background: #fef3c7;
    color: #92400e;
    font-weight: 700;
    font-size: 10px;
    letter-spacing: .5px;
    padding: 1px 6px;
    border-radius: 4px;
    margin-right: 4px;
}

/* Borde de color de tarjeta según grupo */
.card-equipo.grupo-MINIBASKET { border-left: 5px solid #db2777; }
.card-equipo.grupo-FEMENINO   { border-left: 5px solid #ea580c; }
.card-equipo.grupo-MASCULINO  { border-left: 5px solid #1d4ed8; }
.card-equipo.grupo-MINIBASKET:hover { border-color: #db2777; }
.card-equipo.grupo-FEMENINO:hover   { border-color: #ea580c; }
.card-equipo.grupo-MASCULINO:hover  { border-color: #1d4ed8; }

/* Equipo confirmado: fondo y borde verde + tick en la esquina */
.card-equipo.equipo-confirmado {
    background: #ecfdf5;
    border-color: #10b981;
}
.card-equipo.equipo-confirmado:hover {
    border-color: #059669;
    box-shadow: 0 4px 14px rgba(16,185,129,0.25);
}
.tick-confirmado {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 26px;
    height: 26px;
    background: #10b981;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    box-shadow: 0 2px 6px rgba(16,185,129,0.4);
}

/* Bloque del check "Equipo confirmado" dentro del modal de editar */
.bloque-confirmado {
    margin-top: 22px;
    padding: 16px 18px;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    border-radius: 10px;
}
.check-confirmado {
    display: flex !important;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    margin: 0 !important;
}
.check-confirmado input[type=checkbox] {
    width: 22px !important;
    height: 22px !important;
    margin: 0;
    cursor: pointer;
    accent-color: #10b981;
    flex: 0 0 auto;
}
.check-confirmado .texto-confirmado {
    font-size: 17px;
    font-weight: 700;
    color: #047857;
}
.ayuda-confirmado {
    margin: 10px 0 0 0;
    font-size: 13px;
    color: #555;
}

/* ----------- Vista equipo ----------- */
.cabecera-equipo { border-bottom: 2px solid #e5e7eb; padding-bottom: 12px; margin-bottom: 16px; }
.cabecera-equipo h2 { margin: 0; color: #1e3a8a; }
.categoria-equipo { color: #666; margin: 4px 0 0 0; }
.acciones-equipo {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 24px;
    padding: 12px;
    background: #f9fafb;
    border-radius: 8px;
}
.subseccion { margin-top: 28px; padding-top: 20px; border-top: 1px solid #f0f0f0; }

/* ----------- Tablas ----------- */
.tabla {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    font-size: 14px;
}
.tabla th {
    background: #f9fafb;
    padding: 10px 12px;
    text-align: left;
    border-bottom: 2px solid #e5e7eb;
    font-weight: 600;
    font-size: 13px;
    color: #374151;
}
.tabla td {
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f0;
}
.tabla tr:hover td { background: #fafbfc; }
.tabla .acciones {
    white-space: nowrap;
    text-align: right;
}
.tabla button {
    margin-left: 4px;
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 4px;
    cursor: pointer;
    border: 1px solid #d1d5db;
    background: #fff;
}
.tabla button.editar:hover { background: #eff6ff; border-color: #3b82f6; }
.tabla button.borrar { color: #dc2626; }
.tabla button.borrar:hover { background: #fee2e2; border-color: #dc2626; }
.sin-datos {
    text-align: center;
    padding: 30px;
    color: #888;
    background: #fafbfc;
    border-radius: 6px;
    border: 1px dashed #d1d5db;
}

/* tipo técnico */
.tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .5px;
}
.tag-ENTRENADOR { background: #dbeafe; color: #1e40af; }
.tag-AYUDANTE   { background: #fef3c7; color: #92400e; }
.tag-DELEGADO   { background: #d1fae5; color: #065f46; }

/* ----------- Modal ----------- */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    padding: 20px;
    backdrop-filter: blur(2px);
    overflow-y: auto;
}
.modal-contenido {
    background: #fff;
    border-radius: 14px;
    padding: 0;
    max-width: 720px;
    width: 100%;
    max-height: calc(100vh - 40px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 70px rgba(0,0,0,0.35);
    animation: modal-aparece .18s ease-out;
}
@keyframes modal-aparece {
    from { opacity: 0; transform: translateY(12px) scale(.98); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-contenido h3 {
    margin: 0;
    color: #fff;
    background: #1e3a8a;
    padding: 20px 32px;
    font-size: 22px;
    font-weight: 600;
    flex: 0 0 auto;
}
.modal-cuerpo {
    padding: 26px 32px;
    overflow-y: auto;
    flex: 1 1 auto;
    min-height: 0;
}
.modal-cuerpo label {
    display: block;
    margin-top: 22px;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 15px;
    color: #1f2937;
}
.modal-cuerpo label:first-child,
.modal-cuerpo .grid-2 > div:nth-child(-n+2) label { margin-top: 0; }
.modal-cuerpo input, .modal-cuerpo select, .modal-cuerpo textarea {
    width: 100%;
    padding: 15px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    font-size: 17px;
    font-family: inherit;
    background: #fff;
    transition: border-color .12s, box-shadow .12s;
}
.modal-cuerpo input:hover, .modal-cuerpo select:hover {
    border-color: #94a3b8;
}
.modal-cuerpo input:focus, .modal-cuerpo select:focus, .modal-cuerpo textarea:focus {
    outline: none;
    border-color: #1e3a8a;
    box-shadow: 0 0 0 3px rgba(30,58,138,0.15);
}
.modal-pie {
    display: flex;
    justify-content: flex-end;
    gap: 14px;
    padding: 18px 32px;
    border-top: 1px solid #eef0f3;
    background: #fafbfc;
    flex: 0 0 auto;
}
.modal-pie button {
    padding: 14px 28px;
    font-size: 16px;
}
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px 24px;
}
@media (max-width: 560px) {
    .grid-2 { grid-template-columns: 1fr; }
    .modal-cuerpo .grid-2 > div:nth-child(2) label { margin-top: 22px; }
    .modal-contenido h3 { padding: 20px 22px; font-size: 20px; }
    .modal-cuerpo { padding: 24px 22px; }
    .modal-pie { padding: 18px 22px; }
}

/* Tabla especial de exportación FBM (elegir médico por jugador) */
.tabla-export-fbm select, .tabla-export-fbm input[type=date] {
    padding: 6px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 13px;
    width: 100%;
}

/* ----------- Listado simple de equipos ----------- */
.listado-equipos {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: eq;
}
.listado-item {
    counter-increment: eq;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 16px;
    border-bottom: 1px solid #eef0f3;
    cursor: pointer;
    transition: background .12s;
}
.listado-item:hover { background: #f3f6fb; }
.listado-item:last-child { border-bottom: none; }
.listado-item::before {
    content: counter(eq);
    flex: 0 0 auto;
    min-width: 26px;
    font-size: 13px;
    font-weight: 700;
    color: #94a3b8;
}
.punto-grupo {
    flex: 0 0 auto;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}
.grupo-punto-MINIBASKET { background: #db2777; }
.grupo-punto-FEMENINO   { background: #ea580c; }
.grupo-punto-MASCULINO  { background: #1d4ed8; }
.listado-nombre {
    flex: 1 1 auto;
    font-size: 16px;
    color: #1f2937;
}
.listado-tick {
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    background: #10b981;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
}

/* ----------- Importación de Excel ----------- */
.tabla-mapeo td { padding: 8px 12px; }
.tabla-mapeo .campo-destino {
    font-weight: 600;
    color: #1e3a8a;
    width: 40%;
}
.tabla-mapeo select {
    width: 100%;
    padding: 9px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
}
.previa-import {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #eef0f3;
}

/* ----------- Tarjeta de resumen por grupo ----------- */
.card-resumen {
    border-radius: 10px;
    padding: 16px 14px;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 130px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    user-select: none;
}
.card-resumen .resumen-numero {
    font-size: 38px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 4px;
    letter-spacing: -1px;
}
.card-resumen .resumen-etiqueta {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    opacity: .95;
}
.card-resumen .resumen-sep {
    width: 40px;
    height: 1px;
    background: rgba(255,255,255,0.4);
    margin: 10px 0;
}
.card-resumen .resumen-secundario {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1px;
    opacity: .95;
}
.card-resumen .resumen-secundario b {
    font-weight: 800;
    font-size: 15px;
}
.resumen-MINIBASKET { background: linear-gradient(135deg, #db2777, #be185d); }
.resumen-FEMENINO   { background: linear-gradient(135deg, #ea580c, #c2410c); }
.resumen-MASCULINO  { background: linear-gradient(135deg, #1d4ed8, #1e3a8a); }

/* ----------- Banner de totales del club ----------- */
.banner-club {
    background: linear-gradient(135deg, #1e3a8a, #0ea5e9);
    color: #fff;
    border-radius: 12px;
    padding: 18px 24px;
    margin-bottom: 22px;
    box-shadow: 0 6px 18px rgba(30,58,138,0.25);
}
.banner-titulo {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    opacity: .85;
    margin-bottom: 10px;
}
.banner-cifras {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.banner-cifra {
    flex: 1 1 0;
    min-width: 100px;
    background: rgba(255,255,255,0.12);
    border-radius: 8px;
    padding: 10px 14px;
    display: flex;
    align-items: baseline;
    gap: 10px;
}
.banner-num {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -1px;
}
.banner-etq {
    font-size: 13px;
    font-weight: 600;
    opacity: .9;
    letter-spacing: .3px;
}
@media (max-width: 520px) {
    .banner-cifra { min-width: 0; flex: 1 1 100%; }
}

/* ----------- Tarjetas de Becas por grupo ----------- */
.grid-becas-grupos {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
    margin-top: 8px;
}
.card-beca-grupo {
    border-radius: 14px;
    padding: 28px 22px;
    color: #fff;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0,0,0,0.10);
    transition: transform .15s, box-shadow .15s;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    user-select: none;
}
.card-beca-grupo:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(0,0,0,0.18);
}
.beca-grupo-titulo {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: .5px;
    margin-bottom: 14px;
    opacity: .95;
}
.beca-grupo-numero {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -2px;
}
.beca-grupo-etiqueta {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    opacity: .9;
    margin-top: 6px;
}
.beca-grupo-sep {
    width: 50px;
    height: 1px;
    background: rgba(255,255,255,0.4);
    margin: 14px 0;
}
.beca-grupo-total {
    font-size: 14px;
    font-weight: 500;
    opacity: .95;
}
.beca-grupo-total b { font-weight: 800; }

.beca-MINIBASKET { background: linear-gradient(135deg, #db2777, #be185d); }
.beca-FEMENINO   { background: linear-gradient(135deg, #ea580c, #c2410c); }
.beca-MASCULINO  { background: linear-gradient(135deg, #1d4ed8, #1e3a8a); }

/* Pie de tabla (totales) en becas */
.tabla tfoot td {
    border-top: 2px solid #e5e7eb;
    padding: 12px;
    background: #f9fafb;
}
.modal-cuerpo textarea {
    resize: vertical;
    min-height: 70px;
}

/* ============================================================
   ADMINISTRACIÓN (inscripciones y pagos)
   ============================================================ */
.sub-tabs {
    display: flex;
    gap: 8px;
    border-bottom: 2px solid #e5e7eb;
    margin-bottom: 4px;
}
.sub-tab {
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    padding: 10px 18px;
    font-size: 15px;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    margin-bottom: -2px;
}
.sub-tab:hover { color: #1e3a8a; }
.sub-tab.activo { color: #1e3a8a; border-bottom-color: #1e3a8a; }

/* Tarjeta contador de inscripciones */
.tarjeta-contador {
    background: linear-gradient(135deg, #1e3a8a, #0ea5e9);
    color: #fff;
    border-radius: 12px;
    padding: 20px 24px;
    margin: 16px 0 22px;
    box-shadow: 0 6px 18px rgba(30,58,138,0.25);
}
.contador-grande { font-size: 40px; font-weight: 800; line-height: 1; }
.contador-de { font-size: 20px; font-weight: 600; opacity: .8; }
.contador-etq { font-size: 14px; font-weight: 600; opacity: .9; margin-top: 4px; letter-spacing: .3px; }
.barra-progreso {
    margin-top: 14px;
    height: 10px;
    background: rgba(255,255,255,0.25);
    border-radius: 6px;
    overflow: hidden;
}
.barra-relleno {
    height: 100%;
    background: #fff;
    border-radius: 6px;
    transition: width .3s;
}
.contador-pct { text-align: right; font-size: 13px; font-weight: 700; margin-top: 4px; }

/* Fila de mini-contadores (pagos) */
.fila-contadores {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 16px 0 22px;
}
.mini-contador {
    flex: 1 1 0;
    min-width: 110px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 14px 16px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.mini-num { font-size: 26px; font-weight: 800; color: #1e3a8a; line-height: 1; }
.mini-de { font-size: 15px; font-weight: 600; color: #9ca3af; }
.mini-etq { font-size: 12px; font-weight: 600; color: #6b7280; margin-top: 4px; text-transform: uppercase; letter-spacing: .5px; }

/* Bloques por equipo */
.bloque-equipo-admin { margin-bottom: 24px; }
.titulo-equipo-admin {
    margin: 0 0 8px 0;
    font-size: 15px;
    color: #1f2937;
    padding: 6px 12px;
    background: #f3f4f6;
    border-radius: 6px;
    border-left: 4px solid #1e3a8a;
}
.titulo-equipo-admin.grupo-borde-MINIBASKET { border-left-color: #db2777; }
.titulo-equipo-admin.grupo-borde-FEMENINO   { border-left-color: #ea580c; }
.titulo-equipo-admin.grupo-borde-MASCULINO  { border-left-color: #1d4ed8; }
.mini-cat { font-size: 12px; font-weight: 400; color: #888; margin-left: 6px; }

/* Checks de administración */
.chk-admin { width: 18px; height: 18px; cursor: pointer; accent-color: #10b981; }
.chk-grande { width: 22px; height: 22px; }
.tabla-pagos th, .tabla-pagos td { padding: 8px 10px; }
.obs-pagos {
    width: 100%;
    min-width: 140px;
    padding: 6px 8px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: 13px;
    font-family: inherit;
}

/* Sección admin dentro de la ficha del jugador */
.bloque-admin-ficha {
    margin-top: 20px;
    padding: 16px 18px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}
.bloque-admin-titulo {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #1e3a8a;
    margin-bottom: 10px;
}
.check-linea {
    display: flex !important;
    align-items: center;
    gap: 8px;
    margin: 6px 0 !important;
    font-weight: 500 !important;
    cursor: pointer;
}
.check-linea input { width: 18px; height: 18px; accent-color: #10b981; margin: 0; }
.admin-pagos-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px 16px;
    margin: 10px 0;
}

/* Tabla de revisión de importación */
.rev-titulo { margin: 18px 0 6px; font-size: 14px; }
.rev-ok { color: #059669; }
.rev-duda { color: #d97706; }
.rev-no { color: #9ca3af; }
.tabla-revision td { padding: 7px 10px; font-size: 13px; vertical-align: top; }
.rev-flecha { text-align: center; color: #9ca3af; font-weight: 700; }
.rev-equipo { color: #888; font-size: 12px; }
.rev-fnac { color: #9ca3af; font-size: 12px; }
.rev-motivo { font-size: 11px; color: #d97706; margin-top: 2px; }
.rev-noencontrado { opacity: .7; }
.rev-sinmatch { color: #9ca3af; font-style: italic; }
.rev-select { width: 100%; padding: 6px 8px; border: 1px solid #d1d5db; border-radius: 5px; font-size: 13px; }

/* ----------- Equipos plegables en administración ----------- */
.cabecera-plegable {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: #f3f4f6;
    border: none;
    border-left: 4px solid #1e3a8a;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
    text-align: left;
    transition: background .12s;
}
.cabecera-plegable:hover { background: #e9edf3; }
.cabecera-plegable.grupo-borde-MINIBASKET { border-left-color: #db2777; }
.cabecera-plegable.grupo-borde-FEMENINO   { border-left-color: #ea580c; }
.cabecera-plegable.grupo-borde-MASCULINO  { border-left-color: #1d4ed8; }
.flecha-plegable {
    font-size: 11px;
    color: #6b7280;
    transition: transform .15s;
    flex: 0 0 auto;
}
.cabecera-plegable.abierto .flecha-plegable { transform: rotate(90deg); }
.nombre-equipo-plegable { flex: 1 1 auto; }
.contador-equipo {
    flex: 0 0 auto;
    background: #1e3a8a;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    padding: 3px 12px;
    border-radius: 20px;
    min-width: 52px;
    text-align: center;
}
.contador-equipo.contador-completo { background: #10b981; }
.contenido-plegable { padding: 6px 2px 10px; }

/* Etiquetas de la revisión de pagos */
.revp-importe { font-size: 12px; color: #6b7280; margin-top: 3px; }
.badge-anual {
    background: #d1fae5; color: #065f46;
    font-weight: 700; font-size: 11px;
    padding: 1px 7px; border-radius: 4px;
}
.badge-insc {
    background: #dbeafe; color: #1e40af;
    font-weight: 700; font-size: 11px;
    padding: 1px 7px; border-radius: 4px;
}

/* ----------- Banda de total general de becas ----------- */
#total-becas-general { margin-top: 18px; }
.banda-total-becas {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    background: linear-gradient(135deg, #1e3a8a, #0ea5e9);
    color: #fff;
    border-radius: 12px;
    padding: 18px 26px;
    box-shadow: 0 6px 18px rgba(30,58,138,0.22);
}
.banda-total-etq {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    opacity: .9;
}
.banda-total-datos {
    font-size: 16px;
    font-weight: 500;
}
.banda-total-num {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -.5px;
}
.banda-total-sep {
    margin: 0 10px;
    opacity: .5;
}

/* ----------- Bloque de impago en la ficha ----------- */
.bloque-impago-ficha {
    margin-top: 16px;
    padding: 16px 18px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 10px;
}
.check-impago span { color: #b91c1c; font-weight: 700 !important; }
.bloque-impago-ficha label { color: #7f1d1d; }
.bloque-impago-ficha input[type=text],
.bloque-impago-ficha select,
.bloque-impago-ficha textarea {
    border-color: #fca5a5;
}

/* Banda resumen de impagados */
.banda-impagados {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: #fff;
    border-radius: 12px;
    padding: 16px 24px;
    margin: 16px 0 20px;
    box-shadow: 0 6px 18px rgba(220,38,38,0.22);
}
.banda-impagados-etq {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    opacity: .9;
}
.banda-impagados-num { font-size: 22px; font-weight: 800; }

/* ----------- Ropa ----------- */
.bloque-ropa-ficha {
    margin-top: 16px;
    padding: 16px 18px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
}
.check-ropa span { color: #166534; font-weight: 700 !important; }
.bloque-ropa-ficha label { color: #166534; }
.bloque-ropa-ficha textarea { border-color: #86efac; }
.chk-ropa { width: 18px; height: 18px; cursor: pointer; accent-color: #16a34a; }
.obs-ropa {
    width: 100%;
    min-width: 140px;
    padding: 6px 8px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: 13px;
    font-family: inherit;
}
.banda-ropa {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    background: linear-gradient(135deg, #16a34a, #15803d);
    color: #fff;
    border-radius: 12px;
    padding: 16px 24px;
    margin: 16px 0 20px;
    box-shadow: 0 6px 18px rgba(22,163,74,0.22);
}
.banda-ropa-etq { font-size: 13px; font-weight: 700; letter-spacing: 1.5px; opacity: .9; }
.banda-ropa-num { font-size: 22px; font-weight: 800; }
.revr-equipo { font-size: 11px; color: #9ca3af; margin-top: 2px; }

/* Badge "ya anotado" en revisión de ropa */
.badge-anotado {
    background: #d1fae5; color: #065f46;
    font-weight: 700; font-size: 11px;
    padding: 1px 7px; border-radius: 4px;
    margin-left: 4px;
}
.rev-anotado { opacity: .75; }
