/* ==========================================================================
   Prof. Bubbles Responsive Stylesheet
   Created to unify all mobile and tablet layouts across pages.
   ========================================================================== */

/* ==========================================================================
   Global Text Readability & Image Overlay Enhancements
   ========================================================================== */
/* Add strong but subtle text shadows to all hero title texts for clear contrast */
.hero-content h1,
.hero-content .subtitle,
.hero-content p,
.hero-content-family .hero-title,
.hero-content-family .hero-subtitle,
.hero-single .hero-title,
.hero-single .hero-subtitle {
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.75), 0 1px 3px rgba(0, 0, 0, 0.9) !important;
}

/* Darken the overlay on the 2nd slide (Alchemy) for better readability */
.slide-alchemy .img-overlay-solid,
.slide-alchemy .hero-overlay {
    background-color: rgba(15, 20, 30, 0.55) !important;
}

/* ==========================================================================
   1. TABLET & MOBILE VIEWPORTS (max-width: 991px)
   ========================================================================== */
@media (max-width: 991px) {

    /* --- Sticky Navigation Header & Logo Fixes --- */
    .navbar-default {
        height: 70px !important;
    }

    .navbar-header {
        height: 70px !important;
        position: relative !important;
    }

    .pb-logo-new {
        position: absolute !important;
        left: 15px !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        z-index: 1000 !important;
        line-height: 1 !important;
        margin: 0 !important;
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
    }

    .pb-logo-new img {
        max-height: 60px !important;
        width: auto !important;
        display: block !important;
    }

    .navbar-toggle {
        margin-right: 15px !important;
        margin-top: 14px !important;
        margin-bottom: 14px !important;
        float: right !important;
    }

    /* --- Slider Height Adjustment for Tablets & Mobile --- */
    #slides,
    #slides .slides-container,
    #slides .parallax,
    #slides.slide-alchemy {
        height: 80vh !important;
        min-height: 560px !important;
    }

    #slides .parallax {
        background-size: cover !important;
        background-position: center center !important;
        background-repeat: no-repeat !important;
    }

    /* Position the hero content relative to the top of the header bar to avoid button overlaps */
    #slides .hero-content,
    .slide-home .hero-content,
    .slide-alchemy .hero-content,
    .slide-events .hero-content,
    .slide-comedy .hero-content,
    .slide-moments .hero-content,
    .slide-family .hero-content,
    .hero-content-family,
    html[lang="de"] .slide-home .hero-content,
    html[lang="en"] .slide-home .hero-content {
        position: absolute !important;
        left: 24px !important;
        right: 24px !important;
        width: auto !important;
        max-width: none !important;
        top: 115px !important;
        transform: none !important;
        padding: 0 !important;
        text-align: left !important;
        margin: 0 !important;
    }

    /* Reset Bootstrap container padding inside absolute hero-content to prevent pushing and wrapping */
    .hero-content .container,
    #slides .hero-content .container {
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        width: 100% !important;
        max-width: none !important;
    }

    .hero-content .row,
    #slides .hero-content .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .hero-content [class*="col-"],
    #slides .hero-content [class*="col-"] {
        width: 100% !important;
        max-width: none !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* --- Tablet Typography --- */
    h1,
    .hero-single .hero-title,
    .hero-content-family .hero-title,
    .hero-content .hero-title,
    .slide-home .hero-content h1,
    .slide-alchemy .hero-content h1,
    .slide-events .hero-content h1,
    .slide-comedy .hero-content h1,
    .slide-moments .hero-content h1,
    .slide-family .hero-content h1 {
        font-size: 36px !important;
        line-height: 1.15 !important;
        letter-spacing: -0.02em !important;
        margin-top: 0 !important;
    }

    h2,
    .pb-section-heading {
        font-size: 28px !important;
        line-height: 1.2 !important;
        letter-spacing: -0.02em !important;
    }

    .hero-single .hero-subtitle,
    .hero-content-family .hero-subtitle,
    .hero-content .hero-subtitle,
    .hero-content p,
    .slide-home .hero-content .subtitle,
    .slide-alchemy .hero-content .subtitle,
    .slide-events .hero-content .subtitle,
    .slide-comedy .hero-content .subtitle,
    .slide-moments .hero-content .subtitle,
    .slide-family .hero-content .subtitle {
        font-size: 16px !important;
        line-height: 1.4 !important;
        margin-top: 10px !important;
    }

    /* --- Card Columns Stack Fix (Homepage & Familie Page) --- */
    .show-door-row {
        flex-direction: column !important;
        margin-top: 40px !important;
        gap: 24px !important;
    }

    .show-door-row>div {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
    }

    .show-door {
        margin-bottom: 0 !important;
    }

    /* --- Hero CTA Band & Curve Adjustments --- */
    .hero-curve {
        height: 70px !important;
        bottom: -5px !important;
    }

    .hero-cta-band {
        left: 24px !important;
        right: 24px !important;
        bottom: 75px !important;
        z-index: 25 !important;
    }
}

/* ==========================================================================
   2. MOBILE ONLY VIEWPORTS (max-width: 768px)
   ========================================================================== */
@media (max-width: 768px) {

    #shows.shows-section {
        padding: 90px 0;
        margin-top: -5px !important;
        z-index: 28;
    }

    /* --- Slider Height Adjustment for Mobile Phones --- */
    #slides,
    #slides .slides-container,
    #slides .parallax,
    #slides.slide-alchemy {
        height: 80vh !important;
        min-height: 500px !important;
    }

    #slides .parallax {
        background-size: contain !important;
        background-position: center bottom !important;
        background-repeat: no-repeat !important;
    }

    /* --- Set mobile background images for the home page slider --- */
    .slide-home {
        background-image: url(../img/mobile/prof-bubbles-bag-hero-mobile.jpg) !important;
        background-color: #000;
    }

    .slides-container .slide-alchemy {
        background-image: url(../img/mobile/prof-bubbles-lighttable-mobile.jpg) !important;
        background-color: #000;
    }

    .slide-events {
        background-image: url(../img/mobile/prof-bubbles-corporate-mobile.jpg) !important;
        background-color: #000;
    }

    .slide-comedy {
        background-image: url(../img/mobile/prof-bubbles-comedy-mobile.jpg) !important;
        background-color: #000;
    }

    .slide-moments {
        background-image: url(../img/mobile/prof-bubbles-kib-mobile.jpg) !important;
        background-color: #000;
    }

    /* --- Mobile background image for Familie page hero --- */
    .slide-family {
        background-image: url(../img/mobile/prof-bubbles-bag-hero-mobile.jpg) !important;
        background-color: #000;
    }

    /* --- Mobile background image for Alchemy subpage --- */
    .alchemy-hero-bg img {
        content: url(../img/mobile/alchemy_hero_mobile.jpg) !important;
        background-color: #000;
        transform: none !important;
        margin-top: -150px;
    }

    /* Hide the title logo overlay on mobile since it's already baked into alchemy_hero_mobile.jpg */
    .alchemy-title-logo {
        display: none !important;
    }

    /* Fade transition fix for slide contents (reliant on .current-slide class) */
    #slides .slides-container>div:not(.current-slide) .hero-content {
        opacity: 0 !important;
        pointer-events: none !important;
    }

    #slides .slides-container>div.current-slide .hero-content {
        opacity: 1 !important;
        transition: opacity 0.5s ease-in-out !important;
    }

    /* Shift content slightly higher on smaller mobile viewports */
    #slides .hero-content,
    .slide-home .hero-content,
    .slide-alchemy .hero-content,
    .slide-events .hero-content,
    .slide-comedy .hero-content,
    .slide-moments .hero-content,
    .slide-family .hero-content,
    .hero-content-family,
    html[lang="de"] .slide-home .hero-content,
    html[lang="en"] .slide-home .hero-content {
        top: 125px !important;
        transform: none !important;
    }

    /* --- Mobile Typography --- */
    h1,
    .hero-single .hero-title,
    .hero-content-family .hero-title,
    .hero-content .hero-title,
    .slide-home .hero-content h1,
    .slide-alchemy .hero-content h1,
    .slide-events .hero-content h1,
    .slide-comedy .hero-content h1,
    .slide-moments .hero-content h1,
    .slide-family .hero-content h1 {
        font-size: 26px !important;
        line-height: 1.15 !important;
        margin-top: 0 !important;
    }

    #slides .hero-content h1,
    .hero-title {
        max-width: 100% !important;
    }

    h2,
    .pb-section-heading {
        font-size: 22px !important;
        line-height: 1.2 !important;
    }

    .hero-single .hero-subtitle,
    .hero-content-family .hero-subtitle,
    .hero-content .hero-subtitle,
    .hero-content p,
    .slide-home .hero-content .subtitle,
    .slide-alchemy .hero-content .subtitle,
    .slide-events .hero-content .subtitle,
    .slide-comedy .hero-content .subtitle,
    .slide-moments .hero-content .subtitle,
    .slide-family .hero-content .subtitle {
        font-size: 14px !important;
        line-height: 1.35 !important;
        margin-top: 8px !important;
    }

    .pb-lead,
    #alchemy-intro .pb-lead {
        font-size: 18px !important;
        line-height: 1.45 !important;
    }

    .pb-image-break blockquote,
    .alchemy-quote-overlay blockquote,
    .pb-family-quote-break blockquote,
    .pb-family-quote-break-2 blockquote {
        font-size: 19px !important;
        line-height: 1.35 !important;
    }

    /* --- Mobile CTA Band Button Stacking --- */
    .hero-cta-band {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 10px !important;
        bottom: 75px !important;
    }

    .hero-cta-band .pb-btn {
        width: 100% !important;
        text-align: center !important;
        margin: 0 !important;
        padding: 12px 16px !important;
        font-size: 14px !important;
    }

    /* --- Alchemy Subpage Hero Logo Centering --- */
    .alchemy-poster-content {
        left: 50% !important;
        bottom: 120px !important;
        width: calc(100% - 48px) !important;
        max-width: 400px !important;
        transform: translateX(-50%) !important;
    }

    .alchemy-title-logo {
        width: 100% !important;
        height: auto !important;
    }

    .alchemy-trailer-cta {
        position: absolute !important;
        left: 50% !important;
        right: auto !important;
        bottom: 125px !important;
        transform: translateX(-50%) !important;
        width: auto !important;
        z-index: 35 !important;
    }
}