/* ==========================================================================
   1. VARIABLES Y BASE (De Index)
   ========================================================================== */
:root {
    --vcg-green-primary: #28a745;
    --vcg-green-dark: #1e7e34;
    --vcg-green-light: #d1e7dd;
    --vcg-bg: #f0f2f5;
    --vcg-white: #ffffff;
    --vcg-border: #edf0f2;
    --vcg-text: #333;
    --vcg-text-muted: #6c757d;
    --vcg-blue-dark: #191970;
    /* TIPOGRAFÍAS */
    --font-main: 'Roboto', sans-serif;
    --font-data: 'Roboto Condensed', sans-serif;
}

body {
    background-color: var(--vcg-bg);
    font-family: 'Segoe UI', Roboto, sans-serif;
    font-family: var(--font-main);
    color: var(--vcg-text);
    margin: 0;
}

button:focus, input:focus{
    outline: none;
    box-shadow:none !important;
}

.font-tabla{
    font-family: var(--font-data);
}

.main-container {
    max-width: 850px;
    margin: 0 auto;
    padding: 15px;
}


[v-cloak] { display: none !important; }

/* ==========================================================================
   2. COMPONENTES COMUNES (Unificados)
   ========================================================================== */

/* Tarjeta base - Prima el diseño de Index con sombras */
.vc-card {
    background: var(--vcg-white);
    /* border-radius: 12px; */
    border: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    margin-bottom: 20px;
    overflow: hidden;
}

/* Handicap Box - Unificado usando el verde claro de Index */
.hdp-box {
    background-color: var(--vcg-green-light);
    color: var(--vcg-green-dark);
    border-radius: 8px;
    padding: 8px 15px;
    display: inline-block;
}

/* Items de Torneo (Lista) */
.tournament-item {
    border-left: 4px solid var(--vcg-green-primary);
    transition: all 0.2s ease;
    background: var(--vcg-white);
}
.tournament-item:hover { 
    background-color: #f8f9fa; 
    transform: translateX(3px);
}

/* Botones con estilo Pill */
.btn {
    border-radius: 50px !important;
    font-weight: 700;
    transition: all 0.2s;
}

.btn-success {
    background-color: var(--vcg-green-primary) !important;
    border-color: var(--vcg-green-primary) !important;
}


/* ==========================================================================
   3. MENÚ PRINCIPAL (Grid)
   ========================================================================== */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 15px;
}

@media (min-width: 768px) {
    .menu-grid { grid-template-columns: repeat(3, 1fr); }
}

.menu-item {
    background: var(--vcg-white);
    border: 1px solid var(--vcg-border);
    border-radius: 10px;
    padding: 18px 10px;
    text-align: center;
    text-decoration: none;
    color: #444;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.menu-item:hover {
    border-color: var(--vcg-green-primary);
    background-color: #f8fff9;
    color: var(--vcg-green-primary);
    transform: translateY(-2px);
}

.menu-item i {
    display: block;
    font-size: 1.6rem;
    margin-bottom: 8px;
    color: var(--vcg-green-primary);
}

/* ==========================================================================
   4. ESPECÍFICO CALENDARIO (Adaptado a Index)
   ========================================================================== */
.semana-container { 
    background: var(--vcg-white); 
    padding: 10px 0; 
    border-bottom: 1px solid #eee; 
    position: sticky; 
    top: 0; 
    z-index: 100; 
}

.semana-scroll { 
    display: flex; 
    overflow-x: auto; 
    gap: 10px; 
    padding: 5px 15px; 
    scrollbar-width: none; 
}
.semana-scroll::-webkit-scrollbar { display: none; }

.dia-item {
    min-width: 60px; 
    height: 75px; 
    background: #f1f3f5; 
    border-radius: 15px;
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    justify-content: center;
    cursor: pointer; 
    border: 2px solid transparent; 
    transition: 0.3s;
}

.dia-item.active {
    background: var(--vcg-green-primary); 
    color: white;
    box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3); 
    border-color: var(--vcg-green-primary);
}

.dia-nombre { font-size: 0.7rem; text-transform: uppercase; opacity: 0.8; }
.dia-numero { font-size: 1.2rem; font-weight: 800; }

.club-logo-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    border: 1px solid var(--vcg-border);
}

/* Badges de Score en Calendario */
.score-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
    padding: 4px 8px;
    border-radius: 6px;
    background: #eee;
}
.score-badge .label { font-size: 0.55rem; font-weight: bold; text-transform: uppercase; }
.score-badge .value { font-size: 0.9rem; font-weight: 800; }

/* ==========================================================================
   5. DROPDOWNS Y UTILIDADES (UI Moderna)
   ========================================================================== */
.dropdown-menu {
    border: none !important;
    border-radius: 1.25rem !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
    animation: menuAppear 0.3s ease-out;
}

.badge-hora {
    background-color: #f0f7f0;
    color: var(--vcg-green-dark);
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid var(--vcg-green-light);
    font-weight: 500;
}

.badge-hora:hover {
    background-color: var(--vcg-green-primary);
    color: white;
}

/* ==========================================================================
   6. TÍTULOS Y CABECERAS (UI Structure)
   ========================================================================== */

/* Título de sección (ej: "PRÓXIMOS TORNEOS") */
.section-title {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--vcg-green-dark);
    text-transform: uppercase;
    padding: 20px 20px 5px 20px;
    letter-spacing: 0.8px; /* Un poco más de aire para legibilidad */
    display: flex;
    align-items: center;
}

/* Opcional: una línea sutil al lado del título para un look más moderno */
.section-title::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--vcg-border);
    margin-left: 15px;
    opacity: 0.5;
}

/* Cabecera Logo (Navbar) */
.logo-header img {
    height: 45px;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

/* Cabecera de Perfil con degradado */
.profile-header {
    background: linear-gradient(135deg, var(--vcg-green-primary) 0%, var(--vcg-green-dark) 100%);
    color: white;
    padding: 22px;
    border-radius: 0 0 20px 20px; /* Redondeamos solo la base */
    margin-bottom: 15px;
}

/* Animaciones */
@keyframes menuAppear {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fs-06 { font-size: 0.6rem; }
.fs-07 { font-size: 0.7rem; }
.fs-08 { font-size: 0.8rem; }
.fs-09 { font-size: 0.9rem; }
.puntero { cursor: pointer !important; }

/* Clase de utilidad por si quieres usarla manualmente en el HTML */
.text-condensed {
    font-family: var(--font-data) !important;
}

/* Aplicación automática a tus componentes actuales */
.dia-numero, 
.hdp-box span, 
.score-badge .value, 
.badge-hora,
.tournament-item .fs-08, /* Datos del torneo */
.clasificacion-tabla td { 
    font-family: var(--font-data);
    font-weight: 700; 
    letter-spacing: -0.3px; /* Mejora el look de los números pegados */
}

/* Los títulos de sección se ven muy bien en Condensed también */
.section-title {
    font-family: var(--font-data);
    font-weight: 800;
    letter-spacing: 0.5px;
}





/* ==========================================================================
   7. RESULTADOS Y CLASIFICACIONES (Leaderboard)
   ========================================================================== */
.table-golf, .table-golf th, .table-golf td {
    box-sizing: border-box; /* Fundamental para que el cálculo sea exacto */
}

/* --- CONFIGURACIÓN BASE --- */
.tabla-resultados {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-data);
}

.tabla-resultados td, 
.tabla-resultados th {
    vertical-align: middle;
    box-sizing: border-box;
    padding: 8px 4px;
}

/* --- MÓVIL (Por defecto: < 550px) --- */

/* 1. Posición */
.tabla-resultados .col-pos {
    width: 35px;
    min-width: 35px;
    text-align: center;
}

/* 2. Nombre / Jugador (Elástico) */
.tabla-resultados .col-nombre {
    width: auto;
    /* Restamos columnas fijas + paddings del contenedor (15+15) */
    min-width: calc(100vw - 180px);
    max-width: calc(100vw - 180px);
    text-align: left;
    white-space: normal; /* Permite 2 líneas para gente mayor */
    word-break: break-word;
    line-height: 1.2;
    /* font-size: 1.1rem; */
    font-weight: 300;
    padding-left: 10px !important;
    /* color:silver; */
    font-family: var(--font-data);
}

/* 3. Completados / Thru */
.tabla-resultados .col-completados {
    width: 45px;
    min-width: 45px;
    text-align: center;
    color: var(--vcg-text-muted);
}

/* 4. Score y ValorF (Totales) */
.tabla-resultados .col-score, 
.tabla-resultados .col-valorF {
    width: 60px;
    min-width: 60px;
    text-align: center;
    font-weight: bold;
    font-size: 1.1rem;
    white-space: nowrap;
}
.tabla-resultados .col-neto , .tabla-resultados .col-bruto{
    width: 90px;
    min-width: 90px;
}

/* 5. Columnas de Rondas (Scroll Lateral) */
/* Se aplica a las col-estrecha que no son las fijas anteriores */
.tabla-resultados .col-estrecha:not(.col-pos):not(.col-nombre):not(.col-completados):not(.col-score):not(.col-valorF) {
    min-width: 90px;
    text-align: center;
    background-color: #f8f9fa; /* Gris sutil para notar la zona de scroll */
    border-left: 1px solid #dee2e6;
}

/* --- MODO PANTALLA GRANDE (Tablet / Desktop > 550px) --- */
@media (min-width: 551px) {
    .tabla-resultados .col-nombre {
        min-width: auto;
        max-width: none;
        width: 100%;       /* El nombre se expande todo lo posible */
        white-space: nowrap; /* Todo en una línea */
    }

    .tabla-resultados .col-pos, 
    .tabla-resultados .col-completados, 
    .tabla-resultados .col-score, 
    .tabla-resultados .col-valorF, 
    .tabla-resultados .col-estrecha {
        width: 1%;         /* Se ajustan al contenido mínimo */
        min-width: auto;
        white-space: nowrap;
        background-color: transparent !important;
        border-left: none !important;
        padding: 10px 15px; /* Más espacio para lectura cómoda */
    }
}


/* Badges de Resultado (Score) */
.badge-golf {
    display: inline-block;
    padding: 4px 6px;
    font-size: 0.85rem;
    font-weight: 700;
    min-width: 32px;
    text-align: center;
    border-radius: 4px;
    line-height: 1.2em;
    font-family: var(--font-data);
}

/* Colores específicos de Score */
.bg-par { background-color: #f8f9fa; color: #6c757d; border: 1px solid #dee2e6; }
.bg-subpar { background-color: #d9534f; color: white; } /* Rojo */
.bg-overpar { background-color: #212529; color: white; } /* Negro/Gris muy oscuro */
.bg-puntos { background-color: var(--vcg-green-primary); color: white; } /* Verde para stableford */
.bg-bruto{background-color: #495057; color: white;}

.recto-derecha {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

/* Cabeceras Verticales (para ahorrar espacio) */
.th-vertical {
    height: 100px;
    vertical-align: bottom;
    padding-bottom: 10px;
}
.vertical-text {
    writing-mode: vertical-lr;
    transform: rotate(180deg);
    text-align: left;
    margin: 0 auto;
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

/* ==========================================================================
   8. BUSCADOR Y FILTROS (Interactividad)
   ========================================================================== */

.barra-filtros-container {
    background-color: var(--vcg-white);
    border-top: 1px solid var(--vcg-border);
    position: sticky;
    top: 0;
    z-index: 1020;
}

/* Animaciones del Buscador */
.search-transition {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scaleX(0.5);
    opacity: 0;
    width: 0%;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    visibility: hidden;
    pointer-events: none;
}

.search-open {
    width: 100% !important;
    opacity: 1 !important;
    transform: translate(-50%, -50%) scaleX(1) !important;
    visibility: visible !important;
    pointer-events: all !important;
}

.rounded-start-pill { border-top-left-radius: 50px !important; border-bottom-left-radius: 50px !important; }
.rounded-end-pill { border-top-right-radius: 50px !important; border-bottom-right-radius: 50px !important; }

/* ==========================================================================
   9. UTILIDADES EXTRA
   ========================================================================== */
.filaCategoria {
    background: linear-gradient(135deg, var(--vcg-green-primary) 0%, var(--vcg-green-dark) 100%);
    color: white;
    font-weight: bold;
}

.animate-pulse { animation: pulse-white 2s infinite ease-in-out; }
@keyframes pulse-white {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.02); }
    100% { opacity: 1; transform: scale(1); }
}

.avatar-liga { 
    width: 40px; height: 40px; 
    border-radius: 10px; 
    object-fit: cover; 
    border: 1px solid var(--vcg-border); 
}


/* Animación de brillo */
@keyframes shimmer {
    0% { background-position: -468px 0; }
    100% { background-position: 468px 0; }
}

.skeleton-row td {
    background: #f6f7f8;
    background-image: linear-gradient(to right, #f6f7f8 0%, #edeef1 20%, #f6f7f8 40%, #f6f7f8 100%);
    background-repeat: no-repeat;
    background-size: 800px 104px;
    height: 45px; /* Altura similar a tus filas reales */
    border-bottom: 5px solid white; /* Espaciador */
    animation: shimmer 1.5s infinite linear;
}

/* Diferentes anchos para las barritas dentro de la celda */
.skeleton-text {
    height: 12px;
    background: #e2e5e7;
    border-radius: 10px;
    display: inline-block;
}

/* para cuando resultados esta dentro de apuntame */
/* Quitamos márgenes y bordes superiores al hijo */
.apuntame-container .resultados-hijo-wrapper {
    border-top: 1px solid var(--vcg-border);
    margin-top: 10px;
    background: white;
}

/* Reducimos el padding de la cabecera de la tabla en el hijo */
.apuntame-container .table-golf thead th {
    background-color: #f8f9fa !important;
    border-top: none !important;
    font-size: 0.7rem;
    color: #888;
}

/* Hacemos que la columna "pegajosa" coincida con el fondo */
.apuntame-container .col-nombre {
    background-color: white !important;
}

/* Ocultamos elementos que sobran en la vista de inscripción */
/* Por ejemplo, si en resultados tienes un buscador o filtros que aquí no quieres */
.apuntame-container .barra-filtros-container {
    display: none; 
}

/*para las utilidades */
.dropdown-menu-desplegable {
    list-style: none; /* Quita los puntos */
    padding-left: 0;  /* Elimina el margen que deja el navegador para los puntos */
    margin: 0;
}

.dropdown-menu-desplegable li {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 1px solid #f0f0f0; /* Una línea sutil entre opciones */
    transition: background 0.2s;
}

.dropdown-menu-desplegable li:last-child {
    border-bottom: none; /* El último no lleva línea */
}

.dropdown-menu-desplegable li:hover {
    background-color: #f8f9fa; /* Efecto al pasar el ratón o tocar */
}

/*el tiempo*/
.bg-success-light {
    background-color: rgba(25, 135, 84, 0.1);
}

.no-scrollbar::-webkit-scrollbar {
    /* display: none; */
}

.hora-activa {
    background-color: rgba(25, 135, 84, 0.1) !important;
    border-radius: 10px;
    transition: background-color 0.3s ease;
}

.hoyo-salida {
    /* background-color: rgba(25, 135, 84, 0.6) !important; */
    background-color: #79B48F !important;
    /* border-radius: 10px; */
    transition: background-color 0.3s ease;
}
.border-tarjeta{
    /* border: 1px solid rgba(25, 135, 84, 0.2) !important; */
    border: 1px solid #79B48F !important;

}
.eltiempo-page .card {
    transition: transform 0.2s ease;
}

.eltiempo-page .card:active {
    transform: scale(0.98);
}

.table-responsive {
    cursor: grab;
}

.table-responsive:active {
    cursor: grabbing;
}

/* Redondear las esquinas de la tabla en móvil */
.rounded-4 {
    border-radius: 1.2rem !important;
}

/* Animación para los iconos de viento */
.bi-arrow-up {
    display: block;
    line-height: 1;
}

/* Estilo para el texto de los días no seleccionados */
.btn-white {
    background-color: #ffffff;
    color: #6c757d;
}

@keyframes pulse-red {
    0% { opacity: 1; }
    50% { opacity: 0.4; }
    100% { opacity: 1; }
}
.animate-pulse {
    animation: pulse-red 2s infinite;
}

#radarTiempo2 {
    filter: grayscale(0.2) contrast(1.1); /* Toque estético para que no brille tanto */
}

/* Tarjeta juego*/

/* Colores de recorridos con texto blanco para legibilidad */
.recorrido-verde { background-color: #28a745 !important; color: white; }
.recorrido-naranja { background-color: #fd7e14 !important; color: white; }
.recorrido-rojo { background-color: #dc3545 !important; color: white; }
.recorrido-azul { background-color: #007bff !important; color: white; }
.recorrido-amarillo { background-color: #ffc107 !important; color: black; }

/* Ajuste general de la tabla */
.table th, .table td {
    padding: 8px 4px !important;
}

a{
    color: var(--vcg-green-dark)
}
.hover-transparent-success {
    text-decoration: none;
    cursor:pointer;
    background:
        /* linear-gradient(to right,  var(--bs-warning), var(--bs-warning)), */
        linear-gradient(to right,  transparent, transparent),
        linear-gradient(to right, var(--bs-success), var(--bs-success), var(--bs-success));
    background-size: 100% 0.1em, 0 0.1em;
    background-position: 100% 100%, 0 100%;
    background-repeat: no-repeat;
    transition: background-size 400ms;
    padding-bottom: 2px; /* Espacio para que el subrayado luzca más */
    display: inline-block;
}
.hover-transparent-success:hover,
.hover-transparent-success:focus {
    background-size: 0 0.2em, 100% 0.2em;
}

/*golf play*/
/* Forzamos el contenedor principal al borde de la pantalla */
.gp-main-wrapper-play {
    width: calc(100% +  30px);
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    overflow-x: hidden; /* Evita scrolls raros verticales */
    /*compensar los margenes del main-container */
    margin-left: -15px !important;
     /* margin-right: -60px !important;  */
}

/* Eliminamos el radio y márgenes de la card para que pegue al borde */
.gp-main-wrapper-play .card {
    border-radius: 0 !important;
    margin-bottom: 0 !important;
    border-left: none !important;
    border-right: none !important;
}

.sticky-name-play{
    position: sticky;
    left: 0;
    /* Calculamos el ancho basándonos en el contenedor de la tabla */
    /* Usamos 92vw aprox para que ocupe casi todo el ancho del móvil sin salirse */
    width: 94vw; 
    z-index: 5;
    background-color: #f8f9fa; /* Color bg-light */
    display: block; /* Necesario para que el sticky funcione en celdas */
}
.table-responsive-play{
    position: relative;
    overflow-x: auto;
}

/*golfplay*/
/* Clase base para que todos midan lo mismo */
.clsResultados {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    font-weight: bold;
    font-size: 1.1rem;
    line-height: 1;
    border-radius: 50%;
}

.par { background-color: var(--vcg-text-muted); color: var(--vcg-white); } /* Gris */
.birdie {background-color: var(--bs-danger); color: var(--vcg-white); } /* Rojo Círculo */
.eagle { 
    background-color: #ffb81c; color: var(--vcg-white);
    border: 3px double white !important; /* El clásico doble círculo */
}
.bogy { background-color: var(--bs-dark); color: var(--vcg-white); border-radius: 0%; } /* Negro Cuadrado */
.doublebogy { 
    background-color: var(--vcg-blue-dark); color: var(--vcg-white); border-radius: 0%;
    border: 3px double white !important; /* Doble cuadrado */
}
.raya-x { color: var(--bs-gray-500); font-weight: normal; } /* Estilo para la X */


/* para los rankings*/
.tabla-rankings {
    table-layout: fixed !important; /* Fundamental para que respeten el % */
    width: 100% !important;
    min-width: 400px; /* Asegura que no se aplaste demasiado en móviles micro */
}

/* Columna 1: POS */
.tabla-rankings th:nth-child(1),
.tabla-rankings td:nth-child(1) {
    width: 45px;
    text-align: center;
    padding-left: 8px;
}

/* Columna 2: NOMBRE */
.tabla-rankings th:nth-child(2),
.tabla-rankings td:nth-child(2) {
    width: auto; /* Que use el resto del espacio disponible */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Columna 3: SCORE (o la que toque tercera) */
.tabla-rankings th:nth-child(3),
.tabla-rankings td:nth-child(3) {
    width: 75px;
    text-align: center;
    font-weight: bold;
}

/* A partir de la cuarta columna: Columnas extra con scroll */
.tabla-rankings th:nth-child(n+4),
.tabla-rankings td:nth-child(n+4) {
    width: 100px; /* Ancho fijo para que "fuercen" el scroll hacia la derecha */
    text-align: center;
    color: #666;
}

/*categorias en resultados*/
.separator-row {
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}
.separator-row td {
    background-color: #343a40 !important; /* Gris muy oscuro */
    color: white !important;
}

/* Animaciones del Modal */
.modal-fade { animation: fadeIn 0.3s ease-out; }
.modal-pop { animation: modalZoom 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }

@keyframes modalZoom {
    from { transform: scale(0.85); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Transición para el cambio de tarjeta entre rondas */
.fade-ronda-enter-active, .fade-ronda-leave-active {
    transition: all 0.2s ease;
}
.fade-ronda-enter-from, .fade-ronda-leave-to {
    opacity: 0;
    transform: translateY(10px);
}

/* Efecto de pulsación en botones de ronda */
.ronda-btn { transition: all 0.2s ease; cursor: pointer; }
.ronda-btn:active { transform: scale(0.95); }