/* ---- Global layout to account for fixed navbar ---- */
/* =========================
   Base Styles
========================= */

body {
    margin-top: 0;
    color: #222;
    font-family: "stevie-sans", sans-serif;
    font-weight: 400;
    font-style: normal;
    line-height: 1.6;
}


/* =========================
   Body Typography
========================= */

p {
    font-family: "stevie-sans", sans-serif;
    font-weight: 400;
    margin: 0;
}

strong, b, .btn {
    font-weight: 700;
}

em, i {
    font-style: italic;
}


/* =========================
   Headings
========================= */

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: "jubilat-variable", serif;
    font-weight: 500;
    font-style: normal;
    font-variation-settings: "wght" 500;
    line-height: 1.2;
    margin: 0;
    letter-spacing: 0.5px;
}

h1, .h1 { font-size: calc(16px * 1.3 * 1.3 * 1.3 * 1.3 * 1.3); }
h2, .h2 { font-size: calc(16px * 1.3 * 1.3 * 1.3 * 1.3); }
h3, .h3 { font-size: calc(16px * 1.3 * 1.3 * 1.3); }
h4, .h4 { font-size: calc(16px * 1.3 * 1.3) }
h5, .h5 { font-size: calc(16px * 1.3) }
h6, .h6 { font-size: 16px; }

/* =========================
   Optional Refinements
========================= */

body, h1, h2, h3, h4, h5, h6 {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
.container, .container-fluid, .container-lg, .container-md, .container-sm, .container-xl, .container-xxl {
    --bs-gutter-x: 3rem;
}

.text-shadow {
    text-shadow: 0 2px 6px rgba(0, 0, 0, 1);
}
.box-shadow {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 1);
}

/* ---- Navbar base styles ---- */
.bsafe-navbar {
    position: absolute; 
    top: 0;
    left: 0;
    width: 100%;
    background-color: transparent;
    z-index: 10;
}

.navbar-dark .navbar-toggler {
    border-color: rgba(255, 255, 255, 1) !important;
    background-color: #1f1f4d !important;
}
.navbar-dark .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

@media (min-width: 992px) {
    .navbar-expand-lg .navbar-nav .nav-link {
        padding-right: 12px;
        padding-left: 12px;
    }
}

@media (max-width: 767px) {
    .bsafe-navbar {
        position: sticky;
        top: 0;
        z-index: 1030; /* Bootstrap navbar level */
    }
}

/* Logo sizing */
.bsafe-logo {
    width: 130px;
    height: auto;
}

.bsafe-logo-sm {
    width: 80px;
    height: auto;
}

/* Nav links (desktop + offcanvas) */
.bsafe-navbar .nav-item {
    font-weight: 600;
}
.offcanvas {
    --bs-offcanvas-width: 300px !important;
    text-align: right;
}

.bsafe-navbar .nav-link {
    color: #ffffff;
}

.bsafe-navbar .nav-link:hover,
.bsafe-navbar .nav-link:focus,
.bsafe-navbar .nav-link.active {
    color: #f1f1f1;
}

/* Offcanvas styling (mobile menu) */
.bsafe-offcanvas {
    background-color: #29286b;
    color: #ffffff;
}

.bsafe-offcanvas .offcanvas-header {
    justify-content: flex-end;
}

.bsafe-offcanvas .nav-link {
    color: #ffffff;
}

.bsafe-offcanvas .nav-link:hover,
.bsafe-offcanvas .nav-link:focus,
.bsafe-offcanvas .nav-link.active {
    color: #f1f1f1;
}

/* =========================
   Top Utility Bar
========================= */

.bsafe-topbar {
    background-color: #1f1f4d; /* slightly darker than main nav */
    padding: 0.4rem 0;
}
.bsafe-topbar-nav-links {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.bsafe-topbar .btn {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
}

/* Outline light button */
.btn-bsafe-outline-light {
    border: 1px solid #ffffff;
    color: #ffffff;
    background: transparent;
}

.btn-bsafe-outline-light:hover {
    background: #ffffff;
    color: #29286b;
}

/* Emergency button */
.btn-bsafe-emergency {
    background-color: #c0392b;
    color: #ffffff;
    border: 1px solid #c0392b;
}

.btn-bsafe-emergency:hover {
    background-color: #a93226;
    border-color: #a93226;
    color: #ffffff;
}

/* Button */
.btn {
    font-weight: 600;
    padding: 0.45rem 1.25rem;
    border-radius: 5px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease, color 0.3s ease;
}
  
.btn-bsafe-light {
    border: 1px solid #ffffff;
    color: #29286b;
    background-color: #ffffff;
}
.btn-bsafe-light:hover,
.btn-bsafe-light:focus {
    background-color: #29286b;
    color: #ffffff;
    border-color: #ffffff;
}

/* Toggler icon visibility on custom background */
.navbar-dark .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
    height: 50px;
}

.navbar-dark .navbar-toggler-icon {
    /* use default Bootstrap white icon for dark navbars */
    background-image: var(--bs-navbar-toggler-icon-bg);
}

@media (max-width: 767.98px) {

    /* Top Bar */
    .bsafe-topbar {
        height: 75px;
    }
    .bsafe-topbar-nav-links {
        display: none;
    }

    /* Navbar: Nudge logo into the blue bar area */
    .bsafe-main-nav {
        margin-top: -70px; /* Adjusted to center logo better on the topbar */
        z-index: 11;
    }

    .bsafe-logo-sm {
        width: 75px;
        filter: drop-shadow(0px 2px 3px rgba(0,0,0,0.3));
    }

    /* Hero: Split screen 50/50 */
    .bsafe-hero {
        display: flex;
        flex-direction: column;
        height: auto; 
        min-height: 100vh;
        background-position: center top;
        background-size: 100% 50vh; /* Image stays in top half */
    }

    /* Remove the desktop gradient overlay on mobile */
    .bsafe-hero::before {
        display: none; 
    }

    /* The Blue Content Box */
    .bsafe-hero-bottom-content {
        position: relative; /* Removes the 'absolute' behavior from desktop */
        left: 0;
        bottom: 0;
        top: 50vh; /* This pushes the box to start exactly halfway down */
        width: 100%;
        background-color: #29286b;
        padding: 40px 24px;
        margin: 0;
        z-index: 2;
    }

    /* Typography Scale-down */
    .bsafe-hero-bottom-content h1 { 
        font-size: calc(16px * 1.3 * 1.3 * 1.3); /* H3 size */
        text-shadow: none;
    }
    .bsafe-hero-bottom-content h2 { 
        font-size: calc(16px * 1.3 * 1.3); /* H4 size */
        text-shadow: none;
        margin-bottom: 15px;
    }
    .bsafe-hero-bottom-content .h4 { 
        font-size: 18px; 
        text-shadow: none;
        line-height: 1.4;
    }

    p, li {
        font-size: 20px;
    }

    /* Mobile Button Style */
    .bsafe-hero-bottom-content .btn-bsafe-blue {
        background-color: transparent;
        border: 2px solid #ffffff;
        color: #ffffff;
        width: 100%;
        margin-top: 10px;
    }
}

/* =========================================================
   Blue Button (Custom CTA)
   ========================================================= */

.btn-bsafe-blue {
    border: 1px solid #29286b;
    background-color: #29286b;
    color: #ffffff;
    padding: 0.55rem 1.4rem;
    border-radius: 5px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.btn-bsafe-blue:hover,
.btn-bsafe-blue:focus {
    background-color: #ffffff;
    color: #29286b;
    border-color: #29286b;
}

/* =========================================================
   Full-Image Hero (Bottom-Left Text Variant)
   ========================================================= */

.bsafe-hero {
    position: relative;
    width: 100%;
    height: 100vh; 
    background-image: url('../img/pool-by-lake-warm.webp');
    background-size: cover;
    background-position: bottom;
    background-repeat: no-repeat;
    color: #ffffff;
    overflow: hidden;
}

/* Gradient Overlay for Top Navbar Visibility */
.bsafe-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom, 
        rgba(57, 148, 255, 0.6) 0%, 
        rgba(57, 148, 255, 0) 15%
    );
    z-index: 1;
}

.bi-telephone-fill {
    margin-right: 15px;
}

/* Text block */
.bsafe-hero-top-content {
    display: none;
}

.bsafe-hero-bottom-content {
    position: absolute;
    left: 40px;
    bottom: 40px;
    z-index: 2;
    color: #ffffff;
    text-align: left;
    padding-top: 150px;
    display: grid;
    gap: 20px;
}

@media (max-width: 767.98px) {
    .bsafe-hero {
        display: flex;
        flex-direction: column;
        height: 100dvh;
        background-image: none;
    }

    .bsafe-hero::before {
        display: none;
    }

    .bsafe-hero-top-content {
        display: block;
        flex: 1;
        background-image: url('../img/header-mobile-image.webp');
        background-size: cover;
        background-position: center;
    }

    .bsafe-hero-top-overlay {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 100%;
    }

    .mobile-hero-logo {
        max-width: 360px;
        width: 70%;
        padding: 30px;
    }

    .bsafe-hero-bottom-content {
        order: 2;
        position: relative;
        left: 0;
        bottom: 0;
        width: 100%;
        height: auto;
        background-color: #29286b;
        padding: 40px 24px;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: 24px;
        top: 0;
    }

    /* Typography Scale-down */
    .bsafe-hero-bottom-content h1 { 
        font-size: calc(16px * 1.3 * 1.3 * 1.3); 
        text-shadow: none;
        margin-bottom: 0;
    }
    .bsafe-hero-bottom-content h2 { 
        font-size: calc(16px * 1.3 * 1.3); 
        text-shadow: none;
        margin-bottom: 0;
    }
    .bsafe-hero-bottom-content .h4 { 
        font-size: 18px; 
        text-shadow: none;
        margin-bottom: 0 !important;
    }

    /* 5. Mobile Button */
    .bsafe-hero-bottom-content .btn-bsafe-blue {
        background-color: transparent;
        border: 2px solid #ffffff;
        color: #ffffff;
        margin-top: 0;
    }
}
@media (max-width: 481px) {
    .mobile-hero-logo {
        max-width: 90%;
        width: 90%;
    }
}

/* =========================
   About Section
========================= */

.bsafe-about {
    background-color: #ffffff;
    margin: 100px 0;
}

/* Content */
.bsafe-about-content {
    max-width: 560px;
}

.bsafe-eyebrow {
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #29286b;
    margin-bottom: 10px;
}

.bsafe-about h2 {
    margin-bottom: 20px;
}

.bsafe-about p {
    margin-bottom: 15px;
}

/* List */
.bsafe-about-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.bsafe-about-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
}

.bsafe-about-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #29286b;
    font-weight: bold;
}

/* Image */
.bsafe-about-image img {
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

/* =========================
   Mobile Adjustments
========================= */

@media (max-width: 991px) {
    .bsafe-eyebrow {
        text-align: center;
    }

    .bsafe-about {
        margin: 40px 0;
    }
    .bsafe-about h2 {
        text-align: center;
    }

    .bsafe-about-content {
        max-width: 100%;
    }
    .bsafe-about .row.reverse {
        flex-direction: column-reverse;
        --bs-gutter-y: 40px;
    }

    h2 { 
        font-size: calc(16px * 1.3 * 1.3 * 1.3); 
    }
    h3 { 
        font-size: calc(16px * 1.3 * 1.3 ); 
    }
    h4 { 
        font-size: calc(16px * 1.3 ); 
    }
    .btn-bsafe-blue {
        width: 100%;
    }
}

/* =========================
   Why Work With Us
========================= */

.bsafe-why {
    padding: 100px 0 80px;
    background-color: #f7f8fc; /* subtle contrast */
}

/* Item */
.bsafe-why-item {
    padding: 20px;
}

/* Icon */
.bsafe-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #29286b;
    border-radius: 50%;
    border: 2px solid #29286b;
}


/* Headings */
.bsafe-why h3 {
    margin-bottom: 10px;
}



/* =========================
   Mobile
========================= */

@media (max-width: 767.98px) {
    .bsafe-why {
        padding: 40px 0 20px;
    }

    .bsafe-why p {
        max-width: 100%;
    }
}


/* =========================
   Get Started Section
========================= */

.bsafe-start {
    padding: 100px 0;
    background-color: #fff; /* alternate from About */
}

/* Content */
.bsafe-start-content {
    max-width: 560px;
}

/* Image */
.bsafe-start-image img {
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

/* Detail blocks */
.bsafe-start-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.bsafe-start-item h4 {
    margin-bottom: 5px;
}

/* =========================
   Mobile
========================= */

@media (max-width: 767.98px) {
    .bsafe-start {
        padding: 60px 0;
        text-align: center;
    }

    .bsafe-start-content {
        max-width: 100%;
    }
}

/* =========================
   FAQ Section
========================= */

.bsafe-faq {
    padding: 100px 0;
    background-color: #ffffff;
    max-width: 850px;
    margin-left: auto;
    margin-right: auto;
}

/* Accordion base */
.bsafe-accordion .accordion-item {
    border: none;
    border-bottom: 1px solid #e5e7eb;
    padding: 40px 0;
}

/* Buttons */
.bsafe-accordion .accordion-button {
    font-family: "jubilat-variable", serif;
    font-weight: 500;
    font-variation-settings: "wght" 500;
    letter-spacing: 0.5px;
    background-color: transparent;
    color: #222;
    padding: 20px 0;
    box-shadow: none;
}

.bsafe-accordion .accordion-button span {
    padding-right: 10px;
}

/* Remove default Bootstrap arrow background */
.bsafe-accordion .accordion-button::after {
    transform: scale(0.8);
}

/* Hover */
.bsafe-accordion .accordion-button:hover {
    color: #A3A5D1;
}

/* Expanded state */
.bsafe-accordion .accordion-button:not(.collapsed) {
    color: #398fd5;
    background: transparent;
}

/* Body */
.bsafe-accordion .accordion-body {
    padding: 0 0 20px 0;
    max-width: 700px;
}

/* Smooth animation */
.bsafe-accordion .accordion-button::after {
    transition: transform 0.25s ease;
}

/* Default (collapsed) */
.bsafe-accordion .accordion-button.collapsed::after {
    transform: rotate(0deg);
}

/* Expanded (ACTIVE) */
.bsafe-accordion .accordion-button:not(.collapsed)::after {
    transform: rotate(90deg);
}

/* Mobile */
@media (max-width: 767.98px) {
    .bsafe-faq {
        padding: 60px 0;
    }
}

/* =========================
   Footer Section
========================= */
.bsafe-footer {
    background-color: #0c2d48; /* adjust to your brand blue */
    color: #ffffff;
}

.bsafe-footer a {
    color: #ffffff;
    text-decoration: none;
}

.bsafe-footer a:hover {
    text-decoration: underline;
}

.bsafe-footer h5 {
    margin-bottom: 15px;
}

.bsafe-footer-brand img {
    width: 100px;
    height: auto;
}

.bsafe-footer-bottom {
    background-color: #092033;
}

@media (max-width: 991px) {
    .bsafe-footer {
        text-align: center;
    }
}

/* =========================
   Banner Hero
========================= */
.bsafe-hero-banner {
    background-image: url('../img/pool-water-bg.webp');
    min-height: 320px;
    padding: 200px 0 80px 0;
}

.bsafe-hero-banner .lead {
    margin: 0 auto;
}

.bsafe-start p {
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}
@media (max-width: 991px) {
    .bsafe-hero-banner h1 {
        font-size: calc( 16px * 1.3 * 1.3 * 1.3 * 1.3 );
    }
}
@media (max-width: 768px) {
    .bsafe-hero-banner {
        padding: 80px 0 80px 0;
    }
}

/* =========================
   Gallery
========================= */
.bsafe-gallery .gallery-img {
    width: 100%;
    aspect-ratio: 1 / 1;   /* Forces perfect square */
    object-fit: cover;     /* Crops nicely */
    border-radius: 6px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bsafe-gallery .gallery-img:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

/* =========================
   Scrolling Gallery
========================= */

.bsafe-scroll-gallery {
    overflow: hidden;
    width: 100%;
    background-color: #388fd5;
    padding: 50px 0 100px 0;
}

.bsafe-scroll-gallery .scroll {
    overflow: hidden;
    width: 100%;
}

.bsafe-scroll-gallery .inner-scroll {
    display: flex;
    width: max-content;
    animation: scrollGallery 35s linear infinite;
}

.bsafe-scroll-gallery span {
    display: inline-block;
    padding: 0 10px;
}

.bsafe-scroll-gallery img {
    width: 250px;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 6px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bsafe-scroll-gallery img:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.scroller-header {
    margin-bottom: 40px;
}

@keyframes scrollGallery {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}


@media (max-width: 767.98px) {
    .bsafe-scroll-gallery {
        padding: 20px 0 40px 0;
    }
    .scroller-header {
        margin-bottom: 20px;
    }
}