/* Styles personnalisés pour les modals */
.modal-xl {
    max-width: 95%;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
}

.nav-tabs-custom {
    border-bottom: 2px solid #dee2e6;
}

.nav-tabs-custom .nav-link {
    border: none;
    border-bottom: 3px solid transparent;
    color: #6c757d;
    font-weight: 500;
    padding: 12px 20px;
    transition: all 0.3s ease;
}

.nav-tabs-custom .nav-link:hover {
    border-bottom-color: #007bff;
    color: #007bff;
    background: rgba(0, 123, 255, 0.05);
}

.nav-tabs-custom .nav-link.active {
    color: #007bff;
    background: rgba(0, 123, 255, 0.1);
    border-bottom-color: #007bff;
    font-weight: 600;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card {
    transition: all 0.3s ease;
    border-radius: 8px;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Styles pour les day cards dans le modal */
.day-checkbox-container {
    position: relative;
}

.day-checkbox-container .day-checkbox {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.day-label {
    cursor: pointer;
    display: block;
    margin: 0;
}

.day-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 15px 12px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    min-height: 90px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.day-card:hover {
    border-color: #007bff;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
    transform: translateY(-2px);
}

.day-icon {
    font-size: 20px;
    color: #6c757d;
    margin-bottom: 6px;
    transition: color 0.3s ease;
}

.day-name {
    font-size: 14px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 3px;
    transition: color 0.3s ease;
}

.check-indicator {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 20px;
    height: 20px;
    background: #28a745;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s ease;
}

.check-indicator i {
    color: white;
    font-size: 12px;
}

/* État sélectionné */
.day-checkbox-container.selected .day-card {
    border-color: #28a745;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3);
}

.day-checkbox-container.selected .day-icon,
.day-checkbox-container.selected .day-name {
    color: white;
}

.day-checkbox-container.selected .check-indicator {
    opacity: 1;
    transform: scale(1);
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid white;
}

/* Styles pour les sections d'examens */
.bg-warning.bg-opacity-10 {
    background-color: rgba(255, 193, 7, 0.1) !important;
}

.bg-info.bg-opacity-10 {
    background-color: rgba(13, 202, 240, 0.1) !important;
}

.bg-danger.bg-opacity-10 {
    background-color: rgba(220, 53, 69, 0.1) !important;
}

/* Duplicate modal styles */
.duplicate-option {
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.duplicate-option:hover {
    border-color: #007bff;
    transform: translateY(-2px);
}

.duplicate-option.border-primary {
    border-color: #007bff !important;
}

/* Timeline styles */
.timeline-preview {
    position: relative;
    padding-left: 20px;
}

.timeline-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    position: relative;
}

.timeline-marker {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 15px;
    position: relative;
    z-index: 2;
}

.timeline-item:not(:last-child)::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 12px;
    width: 2px;
    height: calc(100% + 15px);
    background: #dee2e6;
    z-index: 1;
}

.timeline-content h6 {
    margin: 0;
    font-size: 14px;
}

.timeline-content small {
    font-size: 12px;
}

/* Working days display */
.working-days-display {
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-xl {
        max-width: 98%;
        margin: 10px;
    }

    .nav-tabs-custom .nav-link {
        padding: 8px 12px;
        font-size: 14px;
    }

    .day-card {
        min-height: 75px;
        padding: 12px 8px;
    }

    .day-icon {
        font-size: 16px;
    }

    .day-name {
        font-size: 12px;
    }

    .timeline-preview {
        padding-left: 15px;
    }

    .timeline-marker {
        width: 10px;
        height: 10px;
        margin-right: 10px;
    }

    .timeline-item:not(:last-child)::before {
        left: 4px;
    }
}

/* Animation */
.card-body {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Form validation styles */
.is-invalid {
    border-color: #dc3545;
}

.is-valid {
    border-color: #28a745;
}

/* Loading states */
.btn .spinner-border {
    width: 1rem;
    height: 1rem;
}