/**
 * VyomCloud Contact Form Page Styles
 * ===================================
 * Custom styles for the contact page including:
 * - Glass morphism effects
 * - Floating label animations
 * - Mesh background gradients
 * - Glow border effects
 */

/* ============================================
   BASE STYLES
   ============================================ */
.contact-page-wrapper {
    font-family: 'Manrope', sans-serif;
}

/* ============================================
   GLASS MORPHISM EFFECTS
   ============================================ */
.glass-morphism {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-morphism-light {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

/* ============================================
   TEXT EFFECTS
   ============================================ */
.text-glow {
    text-shadow: 0 0 15px rgba(0, 105, 255, 0.4);
}

/* ============================================
   FLOATING LABEL ANIMATION
   ============================================ */
.floating-label-group {
    padding-top: 1.25rem;
}

.floating-label-group label {
    top: 1.75rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-label-group:focus-within label,
.floating-label-group input:not(:placeholder-shown)~label,
.floating-label-group textarea:not(:placeholder-shown)~label {
    transform: translateY(-1.5rem) scale(0.8);
    color: #0069ff;
}

/* ============================================
   MESH BACKGROUND GRADIENT
   ============================================ */
.bg-mesh {
    background-image:
        radial-gradient(at 0% 0%, rgba(0, 105, 255, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(0, 105, 255, 0.1) 0px, transparent 50%),
        radial-gradient(at 50% 50%, rgba(0, 105, 255, 0.05) 0px, transparent 50%);
}

/* ============================================
   GLOW BORDER EFFECT
   ============================================ */
.glow-border {
    position: relative;
}

.glow-border::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(45deg, transparent, rgba(0, 105, 255, 0.3), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* ============================================
   FORM INPUT STYLES
   ============================================ */
.contact-main input:focus,
.contact-main textarea:focus {
    outline: none;
    box-shadow: none;
}

/* Remove default focus ring from Tailwind forms plugin */
.contact-main input[type="text"]:focus,
.contact-main input[type="email"]:focus,
.contact-main input[type="tel"]:focus,
.contact-main textarea:focus {
    --tw-ring-color: transparent;
    --tw-ring-shadow: none;
}

/* ============================================
   FIELD VALIDATION STATES
   ============================================ */
.contact-main input.field-error,
.contact-main input.field-error:focus,
.contact-main textarea.field-error,
.contact-main textarea.field-error:focus {
    border-color: #ef4444 !important;
}

.contact-main input.field-success,
.contact-main input.field-success:focus,
.contact-main textarea.field-success,
.contact-main textarea.field-success:focus {
    border-color: #10b981 !important;
}

/* Field Error Messages */
.contact-field-error {
    display: none;
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    color: #ef4444;
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 4px;
    line-height: 1.3;
    font-family: 'Manrope', sans-serif;
    pointer-events: none;
}

.contact-field-error::before {
    content: '\26A0\0020';
}

/* Success Message Box */
.contact-success-box {
    display: none;
    text-align: center;
    padding: 2.5rem 1.5rem;
}

.contact-success-box .success-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.8rem;
    font-weight: bold;
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.3);
    animation: contactSuccessPulse 0.6s ease;
}

@keyframes contactSuccessPulse {
    0% {
        transform: scale(0);
        opacity: 0;
    }

    50% {
        transform: scale(1.15);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Error Message Box */
.contact-error-box {
    display: none;
    background: #fef2f2;
    border: 1.5px solid #fecaca;
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    color: #dc2626;
    font-weight: 500;
    font-size: 0.875rem;
    line-height: 1.4;
    font-family: 'Manrope', sans-serif;
}

.contact-error-box::before {
    content: '\26A0\0020';
    font-weight: 700;
}

/* Character Counter */
.contact-char-counter {
    text-align: right;
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 4px;
    font-weight: 500;
    font-family: 'Manrope', sans-serif;
}

/* Honeypot - hidden from humans */
.contact-hp-field {
    position: absolute;
    left: -9999px;
    top: -9999px;
}

/* ============================================
   HERO SECTION ANIMATIONS
   ============================================ */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.contact-hero .glass-morphism-light {
    animation: float 6s ease-in-out infinite;
}

/* ============================================
   CONTACT CARDS HOVER STATES
   ============================================ */
.contact-main .group:hover .size-16 {
    transform: scale(1.05);
}

/* ============================================
   SUPPORT CTA SECTION
   ============================================ */
.support-cta button {
    position: relative;
    overflow: hidden;
}

.support-cta button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.1),
            transparent);
    transition: left 0.5s ease;
}

.support-cta button:hover::before {
    left: 100%;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 1024px) {
    .contact-hero {
        padding-top: 6rem;
        padding-bottom: 8rem;
    }

    .contact-hero h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .contact-hero h1 {
        font-size: 2.5rem;
    }

    .contact-main {
        margin-top: -2rem;
    }

    .support-cta {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
}

/* ============================================
   ACCESSIBILITY - REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    .contact-hero .glass-morphism-light {
        animation: none;
    }

    .support-cta button::before {
        display: none;
    }

    * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}