/* Styles pour la page calendrier */

.calendar-page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.calendar-header {
    text-align: center;
    margin-bottom: 30px;
}

.calendar-header h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 2.5em;
    font-weight: 600;
}

.calendar-header p {
    color: #666;
    font-size: 1.1em;
    margin: 0;
}

.calendar-wrapper {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    margin-bottom: 30px;
}

#calendar {
    min-height: 600px;
}

.calendar-legend {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.calendar-legend h3 {
    margin-bottom: 15px;
    color: #333;
    font-size: 1.2em;
}

.legend-items {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9em;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    display: inline-block;
}

.cours-category {
    background-color: #007cba;
}

/* Styles pour FullCalendar */
.fc-event {
    cursor: pointer;
    border-radius: 4px;
    padding: 2px 4px;
    font-size: 12px;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

.fc-event:hover {
    opacity: 0.8;
}

.fc-toolbar-title {
    font-size: 1.5em !important;
    font-weight: 600;
    color: #333;
}

.fc-button-primary {
    background-color: #007cba !important;
    border-color: #007cba !important;
    font-weight: 500;
}

.fc-button-primary:hover {
    background-color: #005a87 !important;
    border-color: #005a87 !important;
}

.fc-button-primary:focus {
    box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.3) !important;
}

.fc-daygrid-day.fc-day-today {
    background-color: rgba(0, 124, 186, 0.1) !important;
}

.fc-daygrid-day-number {
    font-weight: 500;
}

.fc-col-header-cell {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #333;
}

.fc-daygrid-day.fc-day-past {
    background-color: #f8f9fa;
}

.fc-daygrid-day.fc-day-future {
    background-color: #ffffff;
}

/* Styles pour les événements */
.fc-event-main {
    padding: 2px 6px;
}

.fc-event-title {
    font-weight: 500;
    line-height: 1.2;
}

/* Styles pour les popover d'événements */
.fc-popover {
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.fc-popover-header {
    background-color: #007cba;
    color: white;
    border-radius: 6px 6px 0 0;
}

/* Responsive */
@media (max-width: 768px) {
    .calendar-page-container {
        padding: 10px;
    }
    
    .calendar-header h1 {
        font-size: 2em;
    }
    
    .calendar-wrapper {
        padding: 10px;
    }
    
    .fc-toolbar {
        flex-direction: column;
        gap: 10px;
    }
    
    .fc-toolbar-chunk {
        display: flex;
        justify-content: center;
    }
    
    .fc-toolbar-title {
        font-size: 1.2em !important;
    }
    
    .legend-items {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .calendar-page-container {
        padding: 5px;
    }
    
    .calendar-header h1 {
        font-size: 1.5em;
    }
    
    .calendar-wrapper {
        padding: 5px;
    }
    
    .fc-button {
        font-size: 0.8em;
        padding: 4px 8px;
    }
}

/* Animation de chargement */
.calendar-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    color: #666;
}

.calendar-loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Styles pour la boîte d'information au survol */
.calendar-event-tooltip {
    position: absolute;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    padding: 15px;
    max-width: 280px;
    z-index: 1000;
    font-size: 13px;
    line-height: 1.4;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
    /* Reset des styles globaux */
    margin: 0;
    font-family: inherit;
    text-align: left;
}

.calendar-event-tooltip.show {
    opacity: 1;
    visibility: visible;
}

.calendar-event-tooltip-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    gap: 10px;
}

.calendar-event-tooltip-image {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
}

.calendar-event-tooltip-title {
    font-weight: 600;
    color: #333;
    margin: 0;
    font-size: 14px;
    line-height: 1.3;
    /* Reset des styles globaux pour h2/h3/h4 */
    padding: 0;
    border: none;
    background: none;
    text-transform: none;
    letter-spacing: normal;
    font-family: inherit;
}

.calendar-event-tooltip-content {
    color: #666;
    /* Reset des styles globaux */
    margin: 0;
    padding: 0;
    border: none;
    background: none;
}

.calendar-event-tooltip-row {
    display: flex;
    justify-content: space-between;
    margin: 5px 0;
    align-items: center;
}

.calendar-event-tooltip-label {
    font-weight: 500;
    color: #555;
    min-width: 80px;
}

.calendar-event-tooltip-value {
    color: #333;
    text-align: right;
}

.calendar-event-tooltip-price {
    font-weight: 600;
    color: #007cba;
    font-size: 14px;
}

.calendar-event-tooltip-schedule {
    background: #f8f9fa;
    padding: 8px;
    border-radius: 4px;
    margin: 8px 0;
    text-align: center;
    font-weight: 500;
    color: #007cba;
}

.calendar-event-tooltip-professeur {
    font-style: italic;
    color: #666;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #eee;
}

/* Responsive pour la tooltip */
@media (max-width: 768px) {
    .calendar-event-tooltip {
        max-width: 250px;
        padding: 12px;
        font-size: 12px;
    }
    
    .calendar-event-tooltip-image {
        width: 40px;
        height: 40px;
    }
    
    .calendar-event-tooltip-title {
        font-size: 13px;
    }
} 