/* Multi-Date Calendar Picker Styles */
.multi-date-calendar {
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Calendar Header */
.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    flex-wrap: wrap;
    gap: 1rem;
}

.calendar-navigation {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.nav-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

.nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.month-year {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    min-width: 200px;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.selection-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.9rem;
}

.selected-count {
    font-weight: 500;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.clear-btn {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.clear-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Calendar Grid */
.calendar-grid {
    padding: 1.5rem;
}

.weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.weekday {
    padding: 0.75rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.85rem;
    color: #6b7280;
    background: #f8fafc;
    border-radius: 6px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
}

.calendar-day {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 48px;
    padding: 0.5rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.calendar-day.empty {
    cursor: default;
}

.calendar-day.disabled {
    color: #d1d5db;
    cursor: not-allowed;
    background: #f9fafb;
}

.calendar-day.selectable {
    background: #f8fafc;
    border: 2px solid #e5e7eb;
    color: #374151;
}

.calendar-day.selectable:hover {
    background: #eff6ff;
    border-color: #3b82f6;
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

.calendar-day.today {
    background: #dbeafe;
    border-color: #3b82f6;
    color: #1e40af;
    font-weight: 600;
}

.calendar-day.selected {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
    border-color: #1d4ed8;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.calendar-day.selected::after {
    content: '✓';
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 0.7rem;
    font-weight: bold;
}

/* Selected Dates Panel */
.selected-dates-panel {
    padding: 1.5rem;
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
}

.selected-dates-panel h4 {
    margin: 0 0 1rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
}

.selected-dates-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    max-height: 120px;
    overflow-y: auto;
}

.selected-dates-list::-webkit-scrollbar {
    width: 4px;
}

.selected-dates-list::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 2px;
}

.selected-dates-list::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 2px;
}

.no-dates {
    color: #6b7280;
    font-style: italic;
    margin: 0;
}

.selected-date-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 0.85rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.date-text {
    color: #374151;
    font-weight: 500;
}

.remove-date {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: #fee2e2;
    color: #dc2626;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.75rem;
    transition: all 0.15s ease;
}

.remove-date:hover {
    background: #fecaca;
    transform: scale(1.1);
}

/* Action Panel */
.action-panel {
    padding: 1.5rem;
    border-top: 1px solid #e5e7eb;
    background: white;
}

.booking-options {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.option-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 150px;
}

.option-group label {
    font-weight: 500;
    color: #374151;
    font-size: 0.9rem;
}

.form-select {
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    background: white;
    color: #374151;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.form-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.cart-actions {
    text-align: center;
}

.add-to-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: #e5e7eb;
    color: #6b7280;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: not-allowed;
    transition: all 0.2s ease;
    min-width: 250px;
}

.add-to-cart-btn.enabled {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border-color: #059669;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.add-to-cart-btn.enabled:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

.add-to-cart-btn:disabled {
    opacity: 0.6;
}

.cart-status {
    margin-top: 1rem;
    min-height: 24px;
}

.cart-status div {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.status-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.status-warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fed7aa;
}

.status-info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

.status-loading {
    background: #f0f9ff;
    color: #0369a1;
    border: 1px solid #7dd3fc;
}

/* Responsive Design */
@media (max-width: 768px) {
    .multi-date-calendar {
        margin: 0 0.5rem;
        border-radius: 8px;
    }
    
    .calendar-header {
        flex-direction: column;
        padding: 1rem;
        text-align: center;
    }
    
    .calendar-navigation {
        order: 2;
        margin-top: 0.5rem;
    }
    
    .selection-info {
        order: 1;
        justify-content: center;
    }
    
    .calendar-grid {
        padding: 1rem;
    }
    
    .calendar-day {
        min-height: 44px;
        font-size: 0.9rem;
    }
    
    .booking-options {
        flex-direction: column;
        gap: 1rem;
    }
    
    .option-group {
        min-width: auto;
    }
    
    .add-to-cart-btn {
        min-width: auto;
        width: 100%;
        padding: 1rem 1.5rem;
    }
    
    .selected-dates-list {
        max-height: 100px;
    }
}

@media (max-width: 480px) {
    .calendar-days {
        gap: 0.25rem;
    }
    
    .calendar-day {
        min-height: 40px;
        font-size: 0.85rem;
    }
    
    .weekday {
        padding: 0.5rem;
        font-size: 0.75rem;
    }
    
    .month-year {
        font-size: 1.1rem;
        min-width: auto;
    }
    
    .nav-btn {
        width: 36px;
        height: 36px;
    }
}

/* Animation keyframes */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.selected-date-item {
    animation: fadeIn 0.2s ease;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.calendar-day.selected {
    animation: pulse 0.5s ease;
}

/* Loading spinner */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fa-spinner.fa-spin {
    animation: spin 1s linear infinite;
}

/* Focus styles for accessibility */
.calendar-day:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

.nav-btn:focus,
.clear-btn:focus,
.form-select:focus,
.add-to-cart-btn:focus,
.remove-date:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .calendar-day.selected {
        background: #000;
        color: #fff;
        border-color: #000;
    }
    
    .calendar-day.selectable:hover {
        background: #f0f0f0;
        border-color: #333;
    }
}
