/* =====================================================
   GANANDO SIEMPRE — FRONTEND CSS v9 (COLORES DE MARCA)
   Verde lima oficial: #C7F301   |   Gris oficial: #303030
   ===================================================== */

.gs-horario-main-wrapper {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    max-width: 1200px;
    margin: 20px auto;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 25px rgba(0,0,0,0.1);
}

.gs-horario-container {
    display: flex;
    min-height: 600px;
}

/* Sidebar Izquierdo (30%) */
.gs-sidebar-assignments {
    flex: 0 0 30%;
    background: #f8f9fa;
    border-right: 1px solid #e1e8ed;
    padding: 25px;
    box-sizing: border-box;
}

.gs-sidebar-header h3 {
    margin: 0 0 20px 0;
    color: #303030;
    font-size: 1.25rem;
    font-weight: 800;
    border-bottom: 3px solid #C7F301;
    padding-bottom: 10px;
}

.gs-assignments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.gs-assignment-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.gs-assignment-icon-wrapper {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.gs-assignment-title {
    font-weight: 700;
    color: #303030;
    font-size: 0.9rem;
}

/* Contenido Principal (70%) */
.gs-main-schedule-content {
    flex: 0 0 70%;
    padding: 30px;
    box-sizing: border-box;
    background: #ffffff;
    display: flex;
    flex-direction: column;
}

.gs-header-box {
    margin-bottom: 25px;
    text-align: left;
    border-left: 5px solid #C7F301;
    padding-left: 20px;
}

.gs-header-box h2 {
    margin: 0;
    color: #303030;
    font-size: 22px;
    font-weight: 800;
}

/* =====================================================
   AVISO: SIN HORARIO ASIGNADO
   ===================================================== */
.gs-no-horario-box {
    text-align: center;
    padding: 55px 30px 45px;
    border: 2px dashed #eee;
    border-radius: 12px;
}

.gs-no-horario-icon {
    font-size: 44px;
    margin-bottom: 12px;
    line-height: 1;
}

.gs-no-horario-pill {
    display: inline-block;
    background: #303030;
    color: #C7F301;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 7px 20px;
    border-radius: 20px;
    margin-bottom: 18px;
}

.gs-no-horario-text {
    font-size: 15px;
    font-weight: bold;
    color: #303030;
    max-width: 460px;
    margin: 0 auto;
    line-height: 1.7;
}

/* =====================================================
   PESTAÑAS DE MES
   ===================================================== */
.gs-meses-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.gs-mes-tab-btn {
    background: #f8f9fa;
    color: #303030;
    border: 2px solid #e1e8ed;
    border-radius: 10px !important;
    padding: 10px 18px;
    cursor: pointer;
    font-weight: 800;
    font-size: 12px;
    text-transform: uppercase;
    transition: all 0.2s;
    overflow: hidden;
}

.gs-mes-tab-btn:hover {
    border-color: #C7F301;
}

.gs-mes-tab-btn.active {
    background: #303030;
    color: #C7F301;
    border-color: #303030;
}

/* Acordeón Semanal */
.gs-accordion-item {
    margin-bottom: 15px;
    border: 1px solid #e1e8ed;
    border-radius: 10px;
    overflow: hidden;
}

.gs-accordion-header {
    background: #ffffff;
    padding: 15px 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.gs-accordion-header:hover {
    background: #f7ffe0;
}

.gs-week-title {
    font-weight: 800;
    color: #303030;
}

.gs-toggle-icon {
    color: #303030;
}

/* --- ESTRUCTURA DE SCROLL INTERNO --- */

.gs-accordion-content {
    background: #f1f5f9;
    padding: 15px;
}

.gs-loading, .gs-loading-initial {
    padding: 30px;
    text-align: center;
    color: #6b7280;
    font-weight: 600;
}

.gs-empty-week-msg {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px;
    color: #6b7280;
    font-weight: 600;
    font-size: 13px;
}

/* Contenedor principal con altura fija y scroll vertical.
   El scroll vertical queda pegado justo al lado de la columna
   "Dom" porque la grilla ya no fuerza un ancho mínimo mayor al
   del contenedor: siempre cabe completa sin scroll horizontal. */
.gs-grid-container-wrapper {
    height: 500px !important;
    max-height: 500px !important;
    overflow-y: scroll !important;
    overflow-x: hidden !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 12px !important;
    background: #ffffff !important;
    position: relative !important;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05) !important;
}

.gs-schedule-view {
    display: grid !important;
    grid-template-columns: 70px repeat(7, 1fr) !important;
    width: 100% !important;
    background: #fff !important;
}

/* Cabecera fija de la tabla — fondo gris de marca. Por defecto letras
   blancas; solo "Hora" y la columna del día actual van en verde oficial,
   así el alumno ubica de inmediato en qué día de la semana está. */
.gs-view-header {
    background: #303030 !important;
    color: #ffffff !important;
    padding: 14px 4px !important;
    text-align: center !important;
    font-weight: 800 !important;
    font-size: 12px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important;
    border-right: 1px solid rgba(255,255,255,0.1) !important;
    text-transform: uppercase !important;
}

.gs-view-header.gs-hora-col {
    color: #C7F301 !important;
}

/* Columna del día actual: texto en verde oficial para concentrarse en hoy */
.gs-view-header.gs-today-col {
    background: #1f1f1f !important;
    color: #C7F301 !important;
    box-shadow: inset 0 -3px 0 #C7F301 !important;
}

/* Etiquetas de tiempo (columna izquierda) — gris de marca en vez de azul grisáceo */
.gs-view-time {
    background: #f8fafc !important;
    padding: 12px 0 !important;
    text-align: center !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-right: 1px solid #e2e8f0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #303030 !important;
}

/* Celdas de la grilla */
.gs-view-slot {
    height: 50px !important;
    border-bottom: 1px solid #f1f5f9 !important;
    border-right: 1px solid #f1f5f9 !important;
    font-size: 10px !important;
    padding: 6px !important;
    text-align: center !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1.2 !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    transition: background 0.2s !important;
}

/* Resalta toda la columna del día de hoy para ubicarse rápido */
.gs-view-slot.gs-today-col {
    box-shadow: inset 3px 0 0 #C7F301, inset -3px 0 0 #C7F301 !important;
}

.gs-view-slot.has-action {
    cursor: pointer !important;
    text-shadow: 0 1px 2px rgba(0,0,0,0.4) !important;
}

.gs-view-slot.has-action:hover {
    filter: brightness(1.1) !important;
}

/* =====================================================
   MODAL / POPUP — TAMAÑO Y DISEÑO SIEMPRE UNIFORME
   ===================================================== */
.gs-modal {
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.gs-modal-content {
    background-color: #ffffff;
    width: 90%;
    max-width: 380px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 15px 50px rgba(0,0,0,0.4);
    position: relative;
}

.gs-modal-header-bar {
    padding: 24px 20px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    gap: 6px;
}

.gs-modal-header-title {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.25;
}

.gs-modal-header-time {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.92;
    line-height: 1.6;
}

.gs-close {
    position: absolute;
    top: 12px;
    right: 16px;
    font-size: 26px;
    line-height: 1;
    color: #ffffff;
    opacity: 0.85;
    cursor: pointer;
    z-index: 2;
}

.gs-close:hover {
    opacity: 1;
}

/* Cuerpo del modal: altura mínima fija para que TODOS los popups
   (nutrición, entrenamiento, descanso) se vean del mismo tamaño. */
.gs-modal-body {
    min-height: 230px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 22px;
    padding: 30px 28px;
    box-sizing: border-box;
}

/* Todos los íconos del modal comparten exactamente el mismo tamaño */
.gs-modal-icon-circle {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: #f4f4f4;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.gs-modal-icon-circle img {
    max-width: 52px;
    max-height: 52px;
    object-fit: contain;
}

.gs-modal-icon-circle .dashicons {
    font-size: 46px;
    width: 46px;
    height: 46px;
    color: #303030;
}

.gs-modal-btn {
    display: inline-block;
    text-align: center;
    color: #ffffff !important;
    text-decoration: none;
    font-weight: 800;
    font-size: 15px;
    letter-spacing: 0.5px;
    padding: 14px 34px;
    border-radius: 10px;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: transform 0.15s, filter 0.15s;
}

.gs-modal-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
}

.gs-descanso-msg {
    text-align: center;
    font-weight: 800;
    font-size: 15px;
    color: #303030;
    line-height: 1.6;
    margin: 0;
}

/* Scrollbar personalizado — verde lima de marca, ubicado justo
   al lado de la columna Domingo ya que la grilla no desborda. */
.gs-grid-container-wrapper::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
.gs-grid-container-wrapper::-webkit-scrollbar-track {
    background: #f1f5f9;
}
.gs-grid-container-wrapper::-webkit-scrollbar-thumb {
    background: #303030;
    border-radius: 5px;
    border: 2px solid #f1f5f9;
}
.gs-grid-container-wrapper::-webkit-scrollbar-thumb:hover {
    background: #1a1a1a;
}
.gs-grid-container-wrapper {
    scrollbar-width: thin;
    scrollbar-color: #303030 #f1f5f9;
}

/* Mobile Responsiveness */
@media (max-width: 992px) {
    .gs-horario-container {
        flex-direction: column;
    }
    .gs-sidebar-assignments {
        flex: none;
        width: 100%;
    }
    .gs-main-schedule-content {
        flex: none;
        width: 100%;
    }
    .gs-schedule-view {
        grid-template-columns: 60px repeat(7, minmax(70px, 1fr)) !important;
        min-width: 620px !important;
    }
    .gs-grid-container-wrapper {
        overflow-x: auto !important;
    }
}
