/**
 * Booking Process Optimizer CSS
 * Consolidated styling - removes conflicts with main stylesheet
 */

/* Progress Indicator - Hidden by default, only shows when needed */
.booking-progress {
    display: none;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(248, 249, 250, 0.8);
    border-radius: 4px;
    border: 1px solid #e9ecef;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: #e9ecef;
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: #1a7b89;
    border-radius: 2px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    font-size: 12px;
    color: #6c757d;
    text-align: center;
}

/* Form Validation - Minimal styling to preserve original design */
input.error,
select.error,
textarea.error {
    border-color: #dc3545 !important;
}

.error-message {
    color: #dc3545;
    font-size: 12px;
    margin-top: 5px;
    display: block;
}

/* Loading States */
.loading-spinner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #6c757d;
    font-size: 14px;
}

.loading-spinner::before {
    content: '';
    width: 16px;
    height: 16px;
    border: 2px solid #e9ecef;
    border-top: 2px solid #1a7b89;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Auto-save Indicators */
.auto-save-indicator {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #28a745;
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

.draft-loaded-indicator {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #17a2b8;
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

.offline-indicator {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #ffc107;
    color: #212529;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Error Messages */
.booking-error {
    background: #f8d7da;
    color: #721c24;
    padding: 12px 16px;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 14px;
}

/* Mobile Optimization */
@media (max-width: 768px) {
    .booking-form.mobile-optimized {
        padding: 15px;
    }
    
    .booking-form.mobile-optimized .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 12px;
    }
    
    .booking-form.mobile-optimized .btn {
        width: 100%;
        padding: 15px;
        font-size: 16px;
    }
    
    .booking-progress {
        margin-bottom: 20px;
        padding: 15px;
    }
    
    .progress-text {
        font-size: 12px;
    }
    
    .auto-save-indicator,
    .draft-loaded-indicator,
    .offline-indicator {
        top: 10px;
        right: 10px;
        left: 10px;
        text-align: center;
    }
}

/* Minimal styling - preserves original design */

/* Fix button text to stay on one line */
.paybtn {
    white-space: nowrap !important;
    text-overflow: ellipsis;
    overflow: hidden;
}
