/**
 * Enhanced Contact Form Styles
 * Advanced styling for interactive contact form components
 */

/* Simplified Form Progress Indicator */
.form-progress {
    background: #f8fafc;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
    display: none; /* Hide the complex progress indicator */
}

/* Simplified Form Field Styling */
.form-control {
    position: relative;
    margin-bottom: 20px;
}

.form-control input,
.form-control textarea,
.form-control select {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 12px 16px;
    background: white;
    font-size: 14px;
    width: 100%;
}

.form-control input:focus,
.form-control textarea:focus,
.form-control select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.field-focused {
    /* Remove transform animations */
}

.field-focused input,
.field-focused textarea,
.field-focused select {
    /* Remove excessive shadows */
}

/* Simplified Validation States */
.input-error {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
}

.input-success {
    border-color: #10b981 !important;
    background-color: #f0fdf4 !important;
}

.field-error {
    color: #ef4444;
    font-size: 12px;
    margin-top: 4px;
}

.field-success {
    color: #10b981;
    font-size: 12px;
    margin-top: 4px;
}

/* Simplified Character Counter */
.character-counter {
    font-size: 11px;
    color: #6b7280;
    text-align: right;
    margin-top: 4px;
    display: none; /* Hide character counters for cleaner look */
}

.character-counter.text-warning {
    color: #f59e0b;
}

.character-counter.text-error {
    color: #ef4444;
}

/* Service Suggestions */
.service-suggestions {
    max-height: 200px;
    overflow-y: auto;
    border-radius: 8px;
    margin-top: 4px;
    animation: suggestionsSlideIn 0.2s ease-out;
}

@keyframes suggestionsSlideIn {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.suggestion-item {
    transition: all 0.2s ease;
}

.suggestion-item:hover {
    background: #f3f4f6 !important;
    transform: translateX(4px);
}

.suggestion-item strong {
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.1);
    padding: 1px 3px;
    border-radius: 3px;
}

/* Auto-save Notification */
.auto-save-notification {
    animation: notificationSlideIn 0.5s ease-out;
    border-radius: 12px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    background: rgba(59, 130, 246, 0.05);
}

@keyframes notificationSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Simplified Form Card */
.enhanced-form-card {
    background: white;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: box-shadow 0.2s ease;
}

.enhanced-form-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Simplified Submit Button */
.enhanced-submit-btn {
    background: #3b82f6;
    border: none;
    border-radius: 6px;
    padding: 12px 24px;
    font-weight: 600;
    font-size: 14px;
    color: white;
    transition: background-color 0.2s ease;
    cursor: pointer;
}

.enhanced-submit-btn:hover {
    background: #2563eb;
}

.enhanced-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.enhanced-submit-btn:disabled:hover {
    background: #3b82f6;
}

/* Simplified Urgency Toggle */
.urgency-toggle {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 8px 0;
}

.urgency-indicator {
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

.urgency-toggle.urgent .urgency-indicator {
    color: #ef4444;
}

/* Form Alerts Enhancement */
.alert {
    border-radius: 12px;
    border: 1px solid transparent;
    animation: alertSlideIn 0.4s ease-out;
}

@keyframes alertSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: #047857;
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #dc2626;
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #2563eb;
}

/* Loading Animation */
.loading-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .form-progress {
        padding: 16px;
    }
    
    .progress-steps {
        flex-direction: column;
        gap: 16px;
    }
    
    .step-line {
        width: 4px;
        height: 40px;
    }
    
    .step {
        flex-direction: row;
        gap: 12px;
    }
    
    .step-label {
        margin-top: 0;
        margin-left: 8px;
    }
    
    .step-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .form-control input,
    .form-control textarea,
    .form-control select {
        padding: 12px;
    }
}

@media (max-width: 640px) {
    .enhanced-form-card {
        margin: 16px;
        border-radius: 16px;
    }
    
    .form-progress {
        margin: -16px -16px 24px -16px;
        border-radius: 16px 16px 0 0;
    }
    
    .enhanced-submit-btn {
        width: 100%;
        padding: 14px;
        font-size: 14px;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .form-control input,
    .form-control textarea,
    .form-control select {
        border-width: 3px;
    }
    
    .step-icon {
        border-width: 4px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Focus visible improvements */
.form-control input:focus-visible,
.form-control textarea:focus-visible,
.form-control select:focus-visible,
.enhanced-submit-btn:focus-visible {
    outline: 3px solid #3b82f6;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .form-progress,
    .enhanced-submit-btn,
    .service-suggestions,
    .auto-save-notification {
        display: none;
    }
    
    .form-control input,
    .form-control textarea,
    .form-control select {
        border: 1px solid #000;
        background: white;
    }
} 