/*
 * Bubble Hero — scoped styles for the temporary 20-year campaign block.
 * All selectors are prefixed with `.bubble-hero` so the rules cannot leak
 * into the rest of the site. Loaded only when the block is rendered (via
 * ACF `enqueue_style` in functions/blocks/register-blocks.php).
 */

.bubble-hero {
    position: relative;
    width: 100%;
    height: 100vh;
    height: 100svh;
    /* Default for small viewports — ramps up at the JS breakpoints below
       so the hero feels right on every screen size from phone to Full HD. */
    max-height: 500px;
    overflow: hidden;
}

@media (min-width: 768px) {
    .bubble-hero {
        max-height: 550px;
    }
}
@media (min-width: 1600px) {
    .bubble-hero {
        max-height: 650px;
    }
}

.bubble-hero__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    user-select: none;
    -webkit-user-drag: none;
}

@media (min-width: 768px) {
    .bubble-hero__bg {
        transform: scale(1.2);
    }
}

@media (min-width: 1200px) {
    .bubble-hero__bg {
        transform: scale(1.2);
    }
}
@media (min-width: 1600px) {
    .bubble-hero__bg {
        transform: scale(1.2);
    }
}
@media (min-width: 1920px) {
    .bubble-hero__bg {
        transform: scale(1);
    }
}

.bubble-hero__canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0;
    transition: opacity 320ms ease-out;
    pointer-events: none;
}

.bubble-hero__canvas.is-ready {
    opacity: 1;
    /* Pop-on-click easter egg: enable pointer events only after the
       canvas is ready so bubbles can be raycast-clicked. */
    pointer-events: auto;
    touch-action: pan-y;
    cursor: pointer;
}

/* Only the size — color/weight/family/letter-spacing stay theme-managed via .title. */
.bubble-hero .title {
    font-size: clamp(48px, 5.2vw, 76px);
    line-height: 1.04;
}

/* Headline wrapper sits absolute over the hero so the canvas stays full-bleed
   underneath, but its inner `.container > .row > .col` follows the theme's
   Bootstrap grid (matches txt01 etc.) so the headline lines up with every
   other module on the page. */
.bubble-hero__headline-wrap {
    position: absolute;
    /* Top spacing has to clear the site navigation on both mobile and
       desktop — otherwise the headline collides with the sticky nav. */
    top: 80px;
    left: 0;
    right: 0;
    z-index: 2;
    pointer-events: none;
}

@media (min-width: 1200px) {
    .bubble-hero__headline-wrap {
        top: 100px;
    }
}
@media (min-width: 1600px) {
    .bubble-hero__headline-wrap {
        top: 110px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bubble-hero__canvas { display: none; }
}
