/* ===================================
   SLOT MANAGEMENT CALENDAR STYLES
   =================================== */

/* Main Container */
.calendar-container {
    background: #fff;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slot Controls Section */
.slot-controls {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.slot-controls h4 {
    color: white;
    margin-bottom: 20px;
    font-weight: 600;
    font-size: 1.5rem;
}

/* Form Styling */
.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    font-size: 0.95rem;
}

.slot-controls .form-control {
    background: rgba(255,255,255,0.95);
    border: 2px solid transparent;
    border-radius: 8px;
    padding: 12px 15px;
    transition: all 0.3s;
    font-size: 1rem;
}

.slot-controls .form-control:focus {
    background: white;
    border-color: #ffd700;
    box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.2);
    outline: none;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, #ffd700 0%, #ff6b6b 100%);
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
    background: linear-gradient(135deg, #ffed4e 0%, #ff5252 100%);
}

.btn-danger {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    border: none;
    transition: all 0.3s;
}

.btn-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    border: none;
    transition: all 0.3s;
}

/* Calendar Styling */
.fc {
    background: white;
    border-radius: 10px;
    padding: 20px;
    border: none !important;
}

.fc-header-toolbar {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.fc-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border: none !important;
    padding: 8px 16px !important;
    border-radius: 6px !important;
    transition: all 0.3s !important;
}

.fc-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.fc-event {
    border-radius: 6px;
    padding: 5px 8px;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    font-weight: 500;
}

.fc-event:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 10;
}

.fc-day-today {
    background: rgba(102, 126, 234, 0.1) !important;
}

/* Legend */
.legend {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    color: #495057;
}

.legend-color {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Bulk Dates Container */
.bulk-dates-container {
    display: none;
    margin-top: 15px;
    padding: 20px;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    border: 2px dashed rgba(255,255,255,0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 500px;
    }
}

.date-chip {
    display: inline-flex;
    align-items: center;
    background: white;
    color: #667eea;
    padding: 8px 16px;
    border-radius: 20px;
    margin: 5px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

.date-chip:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.date-chip i {
    margin-left: 8px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.date-chip i:hover {
    opacity: 1;
}

/* Modal Styling */
.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px 10px 0 0;
    border-bottom: none;
}

.modal-content {
    border-radius: 10px;
    border: none;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.booking-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 15px;
    border-left: 4px solid #667eea;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.booking-card h5 {
    color: #495057;
    font-weight: 600;
    margin-bottom: 15px;
}

.booking-card p {
    margin-bottom: 8px;
    color: #6c757d;
}

/* Student List */
.student-list {
    list-style: none;
    padding: 0;
    margin-top: 15px;
}

.student-item {
    padding: 15px;
    background: white;
    margin: 8px 0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: all 0.3s;
}

.student-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.student-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.student-item strong {
    color: #495057;
    font-size: 1rem;
}

.student-item small {
    color: #6c757d;
    font-size: 0.875rem;
}

/* Custom Checkbox */
.custom-control-label {
    color: white;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
}

.custom-control-input:checked ~ .custom-control-label::before {
    background: linear-gradient(135deg, #ffd700 0%, #ff6b6b 100%);
    border-color: #ffd700;
}

/* Loading State */
.fc-loading {
    position: relative;
}

.fc-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    margin: -25px 0 0 -25px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .calendar-container {
        padding: 25px;
    }
}

@media (max-width: 992px) {
    .slot-controls h4 {
        font-size: 1.3rem;
    }
    
    .legend {
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .calendar-container {
        padding: 15px;
        border-radius: 10px;
    }
    
    .slot-controls {
        padding: 20px 15px;
        border-radius: 10px;
    }
    
    .slot-controls h4 {
        font-size: 1.2rem;
        margin-bottom: 15px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    .btn-primary {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
    
    .legend {
        flex-direction: column;
        gap: 12px;
        padding: 15px;
    }
    
    .legend-item {
        justify-content: center;
    }
    
    .fc {
        padding: 10px;
    }
    
    .fc-header-toolbar {
        flex-direction: column;
        gap: 10px;
        padding: 10px;
    }
    
    .fc-toolbar-chunk {
        display: flex;
        justify-content: center;
        width: 100%;
    }
    
    .fc-button {
        padding: 6px 12px !important;
        font-size: 0.875rem !important;
    }
    
    .date-chip {
        font-size: 12px;
        padding: 6px 12px;
    }
    
    .modal-dialog {
        margin: 10px;
    }
    
    .booking-card {
        padding: 15px;
    }
    
    .student-avatar {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .student-item {
        padding: 12px;
    }
}

@media (max-width: 576px) {
    .calendar-container {
        padding: 10px;
    }
    
    .slot-controls {
        padding: 15px 10px;
    }
    
    .slot-controls h4 {
        font-size: 1.1rem;
    }
    
    .form-control {
        font-size: 0.9rem;
        padding: 10px 12px;
    }
    
    .fc-event {
        font-size: 0.75rem;
        padding: 3px 5px;
    }
    
    .legend-item {
        font-size: 0.875rem;
    }
    
    .legend-color {
        width: 20px;
        height: 20px;
    }
}

/* Print Styles */
@media print {
    .slot-controls,
    .legend,
    .modal,
    .btn {
        display: none !important;
    }
    
    .calendar-container {
        box-shadow: none;
    }
    
    .fc {
        border: 1px solid #000;
    }
}

/* Accessibility */
.fc-button:focus,
.form-control:focus,
.btn:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Smooth Transitions */
* {
    transition: background-color 0.3s ease,
                color 0.3s ease,
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}

/* Custom Scrollbar */
.modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}