/**
 * ============================================================================
 * FORMS BLOCK CSS - Lead Capture Forms Styling
 * ============================================================================
 *
 * Custom styles to complement lead-tracking plugin forms
 * Works with Tailwind CSS utility classes
 */

/* ============================================================================
 * FORM CONTAINER ENHANCEMENTS
 * ============================================================================ */

.contact-form-section {
    scroll-margin-top: 100px;
}

/* Form card shadow and border enhancements */
.lt-form-wrapper {
    position: relative;
}

/* Two-column layout responsive adjustments */
@media (max-width: 1024px) {
    .contact-form-two-column {
        grid-template-columns: 1fr;
    }
}

/* ============================================================================
 * CONTACT INFO ICONS
 * ============================================================================ */

.contact-info-icon {
    flex-shrink: 0;
    color: #2563eb; /* primary blue */
}

.contact-info-icon svg {
    filter: drop-shadow(0 2px 4px rgba(37, 99, 235, 0.1));
}

/* ============================================================================
 * TRUST SIGNALS & BADGES
 * ============================================================================ */

.trust-signals-list {
    list-style: none;
    padding: 0;
}

.trust-signals-list li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
}

.trust-signals-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 0;
    color: #10b981; /* green-500 */
    font-weight: bold;
    font-size: 18px;
}

/* ============================================================================
 * INSTANT QUOTE CTA STYLES
 * ============================================================================ */

.instant-quote-cta {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    position: relative;
    overflow: hidden;
}

.instant-quote-cta::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.1); }
}

.instant-quote-features {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.instant-quote-features span {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

/* ============================================================================
 * FORM FIELD ENHANCEMENTS
 * ============================================================================ */

/* Focus states for better accessibility */
.lt-form input:focus,
.lt-form textarea:focus,
.lt-form select:focus {
    outline: none;
    ring: 2px;
    ring-color: #2563eb;
    border-color: #2563eb;
}

/* Placeholder styling */
.lt-form input::placeholder,
.lt-form textarea::placeholder {
    color: #9ca3af; /* gray-400 */
    opacity: 1;
}

/* ============================================================================
 * SUBMIT BUTTON ENHANCEMENTS
 * ============================================================================ */

.lt-submit-button {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.lt-submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
}

.lt-submit-button:active {
    transform: translateY(0);
}

/* Loading state */
.lt-submit-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.lt-submit-button.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* ============================================================================
 * SUCCESS/ERROR MESSAGES
 * ============================================================================ */

.lt-form-messages {
    margin-top: 16px;
}

.lt-success {
    background: #d1fae5; /* green-100 */
    color: #065f46; /* green-800 */
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 4px solid #10b981; /* green-500 */
}

.lt-error {
    background: #fee2e2; /* red-100 */
    color: #991b1b; /* red-800 */
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 4px solid #ef4444; /* red-500 */
}

/* ============================================================================
 * SOCIAL MEDIA ICONS
 * ============================================================================ */

.social-media-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f3f4f6; /* gray-100 */
    transition: all 0.3s ease;
}

.social-media-links a:hover {
    background: #2563eb; /* primary */
    color: white;
    transform: translateY(-2px);
}

/* ============================================================================
 * MOBILE RESPONSIVENESS
 * ============================================================================ */

@media (max-width: 768px) {
    .instant-quote-cta {
        padding: 24px 16px;
    }

    .instant-quote-cta h2 {
        font-size: 24px;
    }

    .instant-quote-cta p {
        font-size: 16px;
    }

    .contact-info-section {
        margin-bottom: 32px;
    }

    .lt-form-wrapper {
        padding: 24px 16px;
    }
}

/* ============================================================================
 * CALLRAIL PHONE NUMBER STYLING
 * ============================================================================ */

.callrail-phone {
    font-weight: 700;
    color: #2563eb;
    transition: color 0.3s ease;
}

.callrail-phone:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

/* ============================================================================
 * FORM HONEYPOT (SPAM PROTECTION)
 * ============================================================================ */

.lt-honeypot-hidden,
.lt-honeypot-field {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* ============================================================================
 * ACCESSIBILITY ENHANCEMENTS
 * ============================================================================ */

/* Focus visible for keyboard navigation */
.lt-form a:focus-visible,
.lt-form button:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

/* Screen reader only text */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ============================================================================
 * FORM CARD GLASSMORPHIC EFFECT
 * ============================================================================ */

.form-card-glass {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* ============================================================================
 * HERO FORM - GLASSMORPHIC STYLING
 * ============================================================================ */

/* Hero form container with glassmorphic background */
.hero-glassmorphic-form {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Hero form input fields - white text on glass background */
.hero-glassmorphic-form input[type="text"],
.hero-glassmorphic-form input[type="email"],
.hero-glassmorphic-form input[type="tel"],
.hero-glassmorphic-form textarea,
.hero-glassmorphic-form select {
    background: rgba(255, 255, 255, 0.2) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    color: white !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Placeholder text for hero forms */
.hero-glassmorphic-form input::placeholder,
.hero-glassmorphic-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Focus state for hero form inputs */
.hero-glassmorphic-form input:focus,
.hero-glassmorphic-form textarea:focus,
.hero-glassmorphic-form select:focus {
    background: rgba(255, 255, 255, 0.25) !important;
    border-color: rgba(245, 158, 11, 0.6) !important;
    ring: 2px;
    ring-color: rgba(245, 158, 11, 0.4);
    outline: none;
}

/* Labels in hero forms */
.hero-glassmorphic-form label {
    color: white !important;
    font-weight: 600;
}

/* Success/Error messages in hero forms */
.hero-glassmorphic-form .form-message-success {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: white;
    backdrop-filter: blur(10px);
}

.hero-glassmorphic-form .form-message-error {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: white;
    backdrop-filter: blur(10px);
}

/* ============================================================================
 * PRINT STYLES
 * ============================================================================ */

@media print {
    .lt-form,
    .instant-quote-cta,
    .social-media-links {
        display: none;
    }

    .contact-info-section {
        page-break-inside: avoid;
    }
}
