/* Enhanced Booking System Styles */

/* Time Slots Styling */
.time-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
}

.time-slot {
    min-height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.time-slot:hover:not(.disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.time-slot.active {
    background: linear-gradient(135deg, #ff69b4, #ff1493) !important;
    border-color: #ff1493 !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(255, 105, 180, 0.4);
}

/* Occupied Slots */
.occupied-slots-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.occupied-slot {
    background: #dc3545;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.875rem;
    border: none;
    cursor: not-allowed;
    opacity: 0.8;
}

/* Service Selection Enhancement */
.service-card.selected {
    border: 2px solid #ff69b4 !important;
    box-shadow: 0 8px 25px rgba(255, 105, 180, 0.3) !important;
    transform: translateY(-8px) !important;
    background: linear-gradient(135deg, #fff, #fff5f8) !important;
}

.service-card.selected .service-icon {
    color: #ff69b4;
    transform: scale(1.1);
}

/* Admin Override Styling */
.conflict-warning {
    border-left: 4px solid #ffc107;
    background: linear-gradient(135deg, #fff3cd, #fef7e0);
}

.admin-override-section {
    background: linear-gradient(135deg, #f8d7da, #fdf2f2);
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
}

.override-checkbox {
    transform: scale(1.2);
    margin-left: 0.5rem;
}

/* Admin Slots Display */
.admin-slots-display {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    border: 1px solid #dee2e6;
}

.slot-status-available {
    background: #28a745;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.875rem;
    margin: 0.125rem;
    display: inline-block;
}

.slot-status-occupied {
    background: #dc3545;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.875rem;
    margin: 0.125rem;
    display: inline-block;
}

.slot-status-outside {
    background: #6c757d;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.875rem;
    margin: 0.125rem;
    display: inline-block;
}

/* Booking Form Enhancement */
.booking-form {
    background: linear-gradient(135deg, #fff, #fafbfc);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.booking-form .card-header {
    background: linear-gradient(135deg, #ff69b4, #ff1493);
    border-radius: 12px 12px 0 0;
}

/* Enhanced Alerts */
.alert-enhanced {
    border-radius: 8px;
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

.alert-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: currentColor;
}

.alert-success.alert-enhanced {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    color: #155724;
}

.alert-warning.alert-enhanced {
    background: linear-gradient(135deg, #fff3cd, #fef7e0);
    color: #856404;
}

.alert-danger.alert-enhanced {
    background: linear-gradient(135deg, #f8d7da, #f1b2b7);
    color: #721c24;
}

.alert-info.alert-enhanced {
    background: linear-gradient(135deg, #d1ecf1, #bee5eb);
    color: #0c5460;
}

/* Animation Classes */
.fade-in {
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Conflict Details Styling */
.conflict-details {
    background: #fff;
    border-radius: 6px;
    padding: 0.75rem;
    margin-top: 0.5rem;
    border-left: 3px solid #ffc107;
}

.conflict-item {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    background: #fff5f5;
    border-radius: 4px;
    margin-bottom: 0.5rem;
    border: 1px solid #fed7d7;
}

.conflict-item:last-child {
    margin-bottom: 0;
}

.conflict-icon {
    color: #e53e3e;
    margin-left: 0.5rem;
    font-size: 1.2rem;
}

/* Loading Enhancement */
.booking-loading {
    position: relative;
    overflow: hidden;
}

.booking-loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: loading-shimmer 1.5s infinite;
}

@keyframes loading-shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .time-slots-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 0.5rem;
    }
    
    .time-slot {
        min-height: 40px;
        font-size: 0.875rem;
    }
    
    .service-card.selected {
        transform: translateY(-4px) !important;
    }
    
    .occupied-slots-grid {
        gap: 0.25rem;
    }
    
    .admin-slots-display {
        padding: 0.75rem;
    }
}

/* RTL Support */
[dir="rtl"] .time-slots-grid,
[dir="rtl"] .occupied-slots-grid {
    direction: rtl;
}

[dir="rtl"] .conflict-details {
    border-left: none;
    border-right: 3px solid #ffc107;
}

[dir="rtl"] .conflict-icon {
    margin-left: 0;
    margin-right: 0.5rem;
}

/* Print Styles */
@media print {
    .time-slot,
    .occupied-slot {
        box-shadow: none !important;
        border: 1px solid #ccc !important;
    }
    
    .service-card.selected {
        border: 2px solid #000 !important;
        box-shadow: none !important;
        transform: none !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .time-slot.active {
        background: #000 !important;
        color: #fff !important;
        border: 2px solid #fff !important;
    }
    
    .service-card.selected {
        border: 3px solid #000 !important;
        background: #fff !important;
    }
}