/* ============================
   CONTENEDOR GENERAL
   ============================ */
.esbs-dashboard {
    max-width: 900px;
    margin: 0 auto;
    display: grid;
    gap: 24px;
    padding: 10px;
}

/* ============================
   TARJETAS
   ============================ */
.esbs-card {
    background: #ffffff;
    padding: 22px;
    border-radius: 14px;
    border: 1px solid #e6e6e6;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.esbs-card h3 {
    margin-top: 0;
    font-size: 20px;
    font-weight: 600;
    color: #222;
}

/* ============================
   CAMPOS
   ============================ */
.esbs-field {
    margin-bottom: 16px;
}

.esbs-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    color: #333;
}

.esbs-field input[type="text"],
.esbs-field input[type="file"] {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    background: #fafafa;
}

/* ============================
   BOTONES
   ============================ */
.esbs-btn-primary,
.esbs-btn-secondary {
    padding: 10px 18px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    transition: 0.2s ease;
}

.esbs-btn-primary {
    background: #0073aa;
    color: white;
}

.esbs-btn-primary:hover {
    background: #005f8a;
}

.esbs-btn-secondary {
    background: #f2f2f2;
    color: #333;
}

.esbs-btn-secondary:hover {
    background: #e2e2e2;
}

/* ============================
   FILTRO
   ============================ */
.esbs-filter {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    margin-bottom: 16px;
}

/* ============================
   TABLA (solo contenedor)
   ============================ */
.esbs-table-wrapper {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e6e6e6;
    background: #fff;
    padding: 10px;
}

/* ============================
   SHORTCODE PÚBLICO — CONTENEDOR
   ============================ */
.esbs-public-dashboard {
    max-width: 900px;
    margin: 0 auto;
    display: grid;
    gap: 24px;
    padding: 10px;
}

/* ============================
   TARJETAS
   ============================ */
.esbs-public-card {
    background: #ffffff;
    padding: 22px;
    border-radius: 14px;
    border: 1px solid #e6e6e6;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.esbs-public-card h3 {
    margin-top: 0;
    font-size: 20px;
    font-weight: 600;
    color: #222;
}

/* ============================
   CAMPOS
   ============================ */
.esbs-public-field {
    margin-bottom: 16px;
}

.esbs-public-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    color: #333;
}

.esbs-public-field input[type="text"] {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    background: #fafafa;
}

/* ============================
   BOTÓN
   ============================ */
.esbs-public-btn {
    padding: 10px 18px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    transition: 0.2s ease;
    background: #0073aa;
    color: white;
}

.esbs-public-btn:hover {
    background: #005f8a;
}

/* ============================
   FILTRO
   ============================ */
.esbs-public-filter {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    margin-bottom: 16px;
}

/* ============================
   TABLA
   ============================ */
.esbs-public-table-wrapper {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e6e6e6;
    background: #fff;
    padding: 10px;
}

/* ============================
   TOTAL
   ============================ */
   
.esbs-total-row {
    background: #eef7ff;
    font-weight: 700;
    border-top: 2px solid #0073aa;
    border-bottom: 2px solid #0073aa;
}

/* ============================
   TABLA DE STATS
   ============================ */

.esbs-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 40px;
}

.esbs-table th,
.esbs-table td {
    border: 1px solid #ddd;
    padding: 6px 8px;
    text-align: center;
}

.esbs-table th {
    position: relative;
    user-select: none;
    background: #f4f4f4;
    font-weight: bold;
}

.esbs-table th.asc::after {
    content: " ▲";
    font-size: 12px;
}

.esbs-table th.desc::after {
    content: " ▼";
    font-size: 12px;
}

.esbs-table tbody tr:nth-child(odd) {
    background-color: #fafafa;
}

.esbs-table tbody tr:nth-child(even) {
    background-color: #ffffff;
}

.esbs-table tbody tr:hover {
    background-color: #e8f4ff;
	
}

/* ==========================================
   Mejoras para el panel de administración
   ========================================== */

.wrap .esbs-bateo-dashboard,
.wrap .esbs-pitcheo-dashboard {
    max-width: 700px;          /* limita el ancho para que no se estire demasiado */
    margin: 0 auto 60px;       /* espacio debajo de cada sección */
}

.wrap .esbs-bateo-card,
.wrap .esbs-pitcheo-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 24px 28px;        /* más espacio interno */
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    margin-bottom: 40px;       /* separación entre bateo y pitcheo */
}

/* Separación entre campos (más aire) */
.esbs-bateo-field,
.esbs-pitcheo-field {
    margin-bottom: 24px;       /* antes era ~16px, ahora más separado */
}

/* Botones más grandes y con separación */
.esbs-bateo-btn,
.esbs-pitcheo-btn {
    padding: 12px 24px;        /* botones más cómodos */
    font-size: 15px;
    min-width: 140px;          /* evitan que queden muy estrechos */
    margin-right: 12px;        /* separación entre Subir y Recalcular */
    margin-top: 8px;           /* un poco de espacio arriba */
    border-radius: 6px;
    transition: all 0.2s ease;
}

.esbs-bateo-btn:hover,
.esbs-pitcheo-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,115,170,0.2);
}

/* Títulos de sección */
.wrap h2 {
    margin: 40px 0 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #0073aa;
    color: #1d2327;
}

/* Input file y selects con mejor aspecto */
.esbs-bateo-field input[type="file"],
.esbs-pitcheo-field input[type="file"],
.esbs-bateo-field select,
.esbs-pitcheo-field select,
.esbs-bateo-field input[type="text"],
.esbs-pitcheo-field input[type="text"] {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #8c8f94;
    border-radius: 6px;
    font-size: 15px;
    background: #fdfdfd;
}

/* ============================
   TOP 5 — CONTENEDOR
   ============================ */
.esbs-top5 {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0 40px;
    background: #ffffff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

/* ============================
   TOP 5 — CABECERA
   ============================ */
.esbs-top5 thead th {
    background: #0073aa;
    color: #fff;
    padding: 10px;
    font-size: 15px;
    text-align: center;
    border-right: 1px solid rgba(255,255,255,0.2);
}

.esbs-top5 thead th:last-child {
    border-right: none;
}

/* ============================
   TOP 5 — FILAS
   ============================ */
.esbs-top5 tbody tr:nth-child(odd) {
    background: #f7f7f7;
}

.esbs-top5 tbody tr:nth-child(even) {
    background: #ffffff;
}

.esbs-top5 tbody tr:hover {
    background: #e8f4ff;
}

/* ============================
   TOP 5 — CELDAS
   ============================ */
.esbs-top5 td {
    padding: 8px 10px;
    border: 1px solid #e0e0e0;
    text-align: center;
    font-size: 14px;
}

/* ============================
   TOP 5 — TÍTULO
   ============================ */
.esbs-top5-title {
    font-size: 20px;
    font-weight: 700;
    margin: 30px 0 10px;
    color: #0073aa;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================
   TOP 5 — POSICIÓN DESTACADA
   ============================ */
.esbs-top5 tbody tr:first-child {
    background: #fff7d6 !important;
    font-weight: 700;
}

.esbs-top5 tbody tr:first-child td {
    border-top: 2px solid #ffcc00;
    border-bottom: 2px solid #ffcc00;
}

/* ============================
   TABLA DE LÍDERES
   ============================ */

.esbs-lideres-title {
    text-align: center;
    font-size: 26px;
    font-weight: 700;
    margin: 30px 0 20px;
    color: #0073aa;
}

.esbs-lideres-table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
    margin-bottom: 40px;
}

.esbs-lideres-table th {
    background: #0073aa;
    color: #fff;
    padding: 10px;
    font-size: 15px;
    text-align: center;
}

.esbs-lideres-table td {
    padding: 10px;
    border: 1px solid #e0e0e0;
    text-align: center;
    font-size: 15px;
}

.esbs-lideres-table tbody tr:nth-child(odd) {
    background: #fafafa;
}

.esbs-lideres-table tbody tr:nth-child(even) {
    background: #ffffff;
}

.esbs-lideres-table tbody tr:hover {
    background: #e8f4ff;
}

.esbs-lideres-section {
    background: #eef7ff;
    font-weight: 700;
    text-align: center;
    padding: 12px;
    font-size: 16px;
    color: #0073aa;
}
