/* HERO SECTION STYLES */

.hero {
    padding: 140px 0 100px;
    background: linear-gradient(135deg, #f8faff 0%, #e2e8f0 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 70% 30%, rgba(102, 126, 234, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.hero-content {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 60px;
    align-items: center;
}

.hero-text {
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    color: var(--text-dark);
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(90deg, #667eea, #764ba2, #f093fb, #667eea);
    background-size: 300% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientFlow 8s linear infinite;
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 48px;
    max-width: 540px;
}

.hero-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

/* Comparison Slider */
.hero-visual {
    position: relative;
    z-index: 2;
}

.before-after-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    background: #fff;
}

.comparison-slider-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
    background: #eee;
    overflow: hidden;
    cursor: ew-resize;
    user-select: none;
}

.before-image,
.after-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    user-select: none;
}

.before-image img,
.after-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

/* After is the base layer (full width) */
.after-image {
    z-index: 1;
}

/* Before is the top layer (dynamic width) */
.before-image {
    width: 50%;
    overflow: hidden;
    z-index: 2;
    border-right: none;
}

.image-label {
    position: absolute;
    bottom: 20px;
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 4px;
    backdrop-filter: blur(4px);
    z-index: 3;
}

.before-label {
    left: 20px;
}

.after-label {
    right: 20px;
}

.slider-divider {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 3px;
    background: white;
    z-index: 10;
    pointer-events: none;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    transform: translateX(-50%);
}

.slider-handle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 54px;
    height: 54px;
    background: white;
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    z-index: 11;
    pointer-events: auto;
    cursor: grab;
    transition: transform 0.2s, box-shadow 0.2s;
}

.slider-handle:hover {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.3);
}

.slider-handle:active {
    cursor: grabbing;
    transform: translate(-50%, -50%) scale(0.95);
}

.slider-handle svg {
    width: 28px;
    height: 28px;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 3rem;
    }
}

@media (max-width: 991px) {
    .hero {
        padding: 100px 0 60px;
        text-align: center;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .hero-content .hero-text {
        order: 1;
    }

    .hero-content .hero-visual {
        order: 2;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-actions .btn {
        width: 100%;
    }
}