/* Utilities for the functional contact form */

/* Replicate original contact form padding for our new container */
.contact-form-container {
    padding: 60px 40px;
}

/* Error States (used by JS) */
.border-red-500 {
    border-color: #ef4444 !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.text-red-500 {
    color: #ef4444 !important;
}

.focus\:border-red-500:focus {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
}

/* Valid/Default States */
.border-gray-200 {
    border-color: #e5e7eb;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.focus\:border-indigo-500:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Error Message Styling */
.error-message {
    font-size: 0.875rem;
    line-height: 1.25rem;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.error-message span {
    display: inline-block;
}

/* Loading States */
.opacity-75 {
    opacity: 0.75;
    transition: opacity 0.2s ease;
}

.cursor-not-allowed {
    cursor: not-allowed !important;
}

.hidden {
    display: none !important;
}

/* Success View */
.success-view {
    animation: fadeIn 0.3s ease-in;
}

.success-icon {
    animation: scaleIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Spinner Animation */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0);
    }
    to {
        transform: scale(1);
    }
}

.fa-spinner {
    animation: spin 1s linear infinite;
    display: inline-block;
}

/* Smooth transitions for form inputs */
.contact-form-container input,
.contact-form-container select,
.contact-form-container textarea {
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

/* Responsive adjustments matching original style */
@media (max-width: 768px) {
    .contact-form-container {
        padding: 40px 20px;
    }
}