/* ---------------------------------------------------------
   SimpleWebCore Parallax Module
   Works with simplewebcore/public/js/parallax.js
   Apps opt-in via: <section class="swc-parallax" data-bg="...">
--------------------------------------------------------- */

/* Parallax container */
.swc-parallax {
    position: relative;
    overflow: hidden;        /* Ensures background doesn't spill out */
}

/* Background layer inserted by JS */
.swc-parallax-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;            /* Slightly taller for smoother movement */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    will-change: transform;  /* GPU acceleration */
    z-index: -1;             /* Behind content */
    pointer-events: none;    /* Prevents accidental interaction */
}

/* Content inside parallax sections stays above background */
.swc-parallax > * {
    position: relative;
    z-index: 1;
}

/* Optional: reduce parallax intensity on small screens */
@media (max-width: 768px) {
    .swc-parallax-bg {
        height: 110%;
    }
}
