/* --- CRO Improvements (Prolijo & Professional) --- */

/* Pulse Animation for CTAs */
@keyframes pulse-glow {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 86, 179, 0.4);
    }

    /* Adjusted color for blue theme */
    70% {
        box-shadow: 0 0 0 10px rgba(0, 86, 179, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(0, 86, 179, 0);
    }
}

.btn-pulse {
    animation: pulse-glow 2s infinite;
}

/* Multi-Step Form Container */
.multi-step-form {
    position: relative;
    overflow: hidden;
    background: var(--color-white);
    padding: 2.5rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-gray-200);
}

.form-step {
    display: none;
    animation: fadeIn 0.2s ease;
}

.form-step.active {
    display: block;
}

/* Step Indicators */
.step-indicators {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 32px;
}

.step-dot {
    width: 40px;
    height: 4px;
    background: var(--color-gray-200);
    border-radius: 4px;
    transition: background 0.3s ease;
}

.step-dot.active {
    background: var(--color-primary);
}

.step-dot.completed {
    background: #10b981;
    /* Success Green */
}

/* Form Inputs (Professional Look) */
.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-gray-900);
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.multi-step-form input,
.multi-step-form select {
    width: 100%;
    padding: 1rem 1.25rem;
    background: var(--color-gray-50);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--radius-sm);
    color: var(--color-gray-900);
    font-family: var(--font-secondary);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.multi-step-form input:focus,
.multi-step-form select:focus {
    background: var(--color-white);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(0, 86, 179, 0.08);
    /* Subtle focus ring */
    outline: none;
}

.multi-step-form input::placeholder {
    color: var(--color-gray-500);
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 16px;
    margin-top: 2rem;
}

.form-actions .btn {
    flex: 1;
    justify-content: center;
}

.btn-back {
    background: transparent;
    border: 2px solid var(--color-gray-200);
    color: var(--color-gray-500);
    font-weight: 600;
}

.btn-back:hover {
    border-color: var(--color-gray-500);
    color: var(--color-gray-900);
}

.btn-next {
    width: 100%;
}

/* Mobile Sticky CTA */
.sticky-cta {
    position: fixed;
    bottom: 24px;
    /* Floating slightly above bottom */
    left: 16px;
    right: 16px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 0;
    /* Let button handle padding */
    z-index: 1000;
    transform: translateY(150%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border-radius: 100px;
    /* Pill shape */
    display: flex;
    justify-content: center;
    overflow: hidden;
}

.sticky-cta.visible {
    transform: translateY(0);
}

.sticky-cta .btn {
    width: 100%;
    margin: 0;
    border-radius: 100px;
    padding: 16px 24px;
    font-size: 1rem;
}

@media (min-width: 769px) {
    .sticky-cta {
        display: none !important;
    }
}

/* --- WHATSAPP FLOATING BUTTON (New Feature) --- */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    /* Symmetrical with Chat (Left) */
    right: 24px;
    /* Independent on the Right */
    width: 60px;
    height: 60px;
    background-color: #25D366;
    /* Official WhatsApp Green */
    color: #FFF;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 4px 25px rgba(37, 211, 102, 0.4);
    z-index: 10000;
    /* Above everything */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.whatsapp-float:hover {
    transform: scale(1.1) rotate(10deg);
    box-shadow: 0 10px 40px rgba(37, 211, 102, 0.6);
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
    fill: currentColor;
}

/* Mobile Adjustment */
@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 100px;
        /* Keep it high enough */
        right: 16px;
        /* Align with typical mobile margins */
        width: 50px;
        height: 50px;
    }

    .whatsapp-float svg {
        width: 26px;
        height: 26px;
    }
}

/* TYPEWRITER CURSOR EFFECT */
#typewriter {
    display: inline-block;
    min-height: 1.2em;
    /* Prevent vertical collapse */
    vertical-align: bottom;
}

#typewriter::after {
    content: '|';
    color: #00d4ff;
    animation: blinkCursor 0.8s infinite;
    margin-left: 2px;
    font-weight: 400;
}

@keyframes blinkCursor {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* --- Visual Enhancements (Gradient Text & Button Shine) --- */

/* 1. Animated Gradient Text */
.text-gradient-animate {
    background: linear-gradient(to right,
            #0056b3 0%,
            #00d4ff 50%,
            /* Brighter Cyan */
            #0056b3 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    /* Vendor prefix for WebKit browsers */
    background-clip: text;
    /* Standard property */
    -webkit-text-fill-color: transparent;
    /* Vendor prefix for WebKit browsers */
    color: transparent;
    /* Fallback */
    animation: gradientFlow 2.5s linear infinite;
    /* Slightly faster */
    font-weight: 800;
    /* Ensure it's bold enough */
    display: inline-block;
    /* Fix for background-clip sometimes behaving oddly on inline elements */
    padding-bottom: 5px;
    /* Prevent clipping */
}

@keyframes gradientFlow {
    0% {
        background-position: 0% center;
    }

    100% {
        background-position: 200% center;
    }
}

/* 2. Premium Button Micro-interactions */
.btn {
    position: relative;
    overflow: hidden;
    /* For the shine effect */
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    z-index: 1;
    /* Ensure text is above pseudo-element */
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 86, 179, 0.2);
    /* Colored shadow */
}

.btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 10px rgba(0, 86, 179, 0.2);
}

/* Shine Effect on Hover */
.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.3) 50%,
            rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    transition: none;
    z-index: -1;
}

.btn:hover::after {
    animation: shinePass 0.75s;
}

@keyframes shinePass {
    0% {
        left: -100%;
    }

    100% {
        left: 200%;
    }
}

/* --- SERVICE BOXES (Static Gradient Border + 3D Tilt Ready) --- */

/* 1. Base Card Structure */
.service-box {
    position: relative;
    background: transparent !important;
    border: none !important;
    border-radius: var(--radius-lg);
    overflow: hidden;
    z-index: 0;
    transition: transform 0.1s ease-out;
    /* Super snappy 3D Tilt */
    display: flex;
    flex-direction: column;
    padding: 3rem !important;
    height: 100%;
}

/* 2. The Static Gradient Border (Design Only - No Animation) */
.service-box::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    padding: 1px;
    /* Border width */
    background: linear-gradient(135deg, rgba(2, 60, 117, 0.5), #00d4ff);
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    z-index: 1;
    pointer-events: none;
}

/* 3. The Static Mesh Background (Design Only) */
.service-box::before {
    content: '';
    position: absolute;
    inset: 2px;
    border-radius: calc(var(--radius-lg) - 2px);
    background-image:
        radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(135deg, #0f172a 0%, #172a4f 100%);
    background-size: 20px 20px, 100% 100%;
    z-index: -1;
}

/* 4. Portfolio Preview Image */
.service-box__preview {
    position: absolute;
    top: 2px;
    left: 2px;
    right: 2px;
    bottom: 2px;
    border-radius: calc(var(--radius-lg) - 2px);
    background-size: cover;
    background-position: center;
    opacity: 0;
    z-index: -1;
    transition: opacity 0.5s ease;
    mix-blend-mode: overlay;
}

/* 5. Hover Logic */
.service-box:hover {
    /* Transform handled by JS 3D Tilt for perspective */
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.3);
}

.service-box:hover .service-box__preview {
    opacity: 0.3;
}

/* 6. Typography & Visuals */
.service-box>* {
    position: relative;
    z-index: 2;
}

.service-box__title {
    color: #ffffff;
    font-size: 1.6rem;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.service-box__desc {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.service-box__list {
    margin-top: auto;
}

.service-box__list li {
    color: #e2e8f0;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

.service-box__list li .service-box__dot {
    background-color: #00d4ff;
    box-shadow: 0 0 8px #00d4ff;
    flex-shrink: 0;
}

/* Icon Container */
.service-box__icon {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 64px;
    height: 64px;
    margin-bottom: 2.5rem;
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
}

.service-box__icon svg {
    color: #fff !important;
    width: 32px;
    height: 32px;
    filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.6));
}

@media (min-width: 769px) {
    .services-boxes__grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr);
        gap: 48px;
    }
}