/* 
 * Man With A Van - Before/After Gallery Section
 */

/* White */
.gallery-section {
    background-color: var(--color-white);
    color: var(--text-primary);
    position: relative;
    z-index: 4;
    padding: var(--section-padding-y-lg) 0;
    overflow: hidden;
    border-top: var(--section-divider);
}

.gallery-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at top left, rgba(0, 102, 204, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

.gallery-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
    position: relative;
    z-index: 1;
    visibility: visible !important;
    opacity: 1 !important;
}

.gallery-item {
    background: var(--color-white);
    border: 2px solid var(--border-dark);
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s var(--ease-out);
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: var(--color-gold);
}

.gallery-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    width: 100%;
    height: 300px;
    overflow: hidden;
    position: relative;
}

.gallery-before,
.gallery-after {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-before-wrapper,
.gallery-after-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.gallery-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    z-index: 3;
    cursor: ew-resize;
    background: rgba(212, 175, 55, 0.1);
    border-right: 3px solid var(--color-gold);
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-slider::before {
    content: '⟷';
    color: var(--color-gold);
    font-size: 2rem;
    font-weight: bold;
    background: var(--color-black);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.gallery-content {
    padding: 1.5rem;
}

.gallery-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-black);
}

.gallery-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.gallery-service {
    background: rgba(212, 175, 55, 0.1);
    color: var(--color-gold);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.gallery-date {
    color: var(--text-secondary);
}

/* Simple comparison view (alternative) */
.gallery-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    height: 300px;
}

.gallery-comparison img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-label {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 1rem;
    background: rgba(0, 0, 0, 0.8);
    color: var(--color-white);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 4px;
    white-space: nowrap;
}

.gallery-label-before {
    left: 10px;
    transform: none;
}

.gallery-label-after {
    right: 10px;
    left: auto;
    transform: none;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .gallery-section {
        padding: 60px 0;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .gallery-images {
        grid-template-columns: 1fr;
        height: auto;
        min-height: 250px;
    }

    .gallery-before-wrapper,
    .gallery-after-wrapper {
        height: 250px;
    }

    .gallery-comparison {
        height: 250px;
    }
}