/******* SITE DEFAULTS *************/
html body {
    --primary-color-rgb: 26, 60, 130;
    --secondary-color-rgb: 198, 147, 56;
    --tertiary-color-rgb: 240, 234, 214;

    --default-white-rgb: 255, 255, 255;
    --default-black-rgb: 0, 0, 0;

    --title-font-family: 'Niconne', cursive;
    --body-font-family: 'Lato', sans-serif;

    --last-break-point: 50.99rem;
    --site-max-width: 1920px;
    --site-container-max-width: 2440px;

    --slideshow-height: min(56.25vw, 810px);
    --slideshow-width: min(100vw, 1440px);

    --slideshow-height-mobile: 56.25vw;
    --slideshow-width-mobile: 100vw;

    --ql-num-boxes: 5;

    --section-navigation-bg: initial;
    --section-header-bg: #f1f1f1;
    --section-feature-background: #f1f1f1;
}

html body.site-home {
    --section-above-bg: var(--secondary-color);
}

html body {
    --side-menu-bg: var(--primary-color);
    --side-menu-bg-hover: var(--secondary-color);
    --side-menu-font-size-desktop: min(1.25vw, 1.25rem);
    --side-menu-font-family: var(--body-font-family);
    --side-menu-font-weight: 400;

    --section-page-surround-bg: #f1f1f1;
    --section-container-top-bg: #f1f1f1;
    --section-top-bg: var(--primary-color);
    --section-navigation-bg: var(--primary-color);
    --section-slideshow-bg: #f1f1f1;
    --section-header-bg: #f1f1f1;
    --section-above-bg: #f1f1f1;
    --section-feature-bg: #f1f1f1;
    --section-showcase-bg: #f1f1f1;
    --section-utility-bg: #f1f1f1;
    --section-container-main-bg: #f1f1f1;
    --section-sidebar-bg: transparent;
    --section-mainbar-bg: transparent;
    --section-aside-bg: transparent;
    --section-expanded-bg: #f1f1f1;
    --section-extension-bg: #f1f1f1;
    --section-bottom-bg: #f1f1f1;
    --section-container-footer-bg: #f1f1f1;
    --section-footer-bg: var(--primary-color);
    --section-copyright-bg: var(--primary-color);
    --section-offcanvas-bg: var(--primary-color);
    --section-offcanvas-bg-overlay: rgba(0, 0, 0, .25);
}

html body #g-navigation {
    --main-menu-text-color: var(--default-white);
    --main-menu-text-color-hover: var(--default-white);
    --main-menu-bg: transparent;
    --navigation-floating-social-padding: min(1vw, 1rem);
}

.g-array-item-text {
    margin: 0 !important;
    padding: 0 !important;
}

h2 {
    font-variant-caps: normal;
    font-family: var(--body-font-family);
}

blockquote {
    font-size: 2rem;
    color: var(--primary-color);
}

/* NAVIGATION */

#g-navigation {
    border-bottom: 0;
}

/*  */

/* Position the wrapper absolutely within the relative section header */
.j-social-icons {
    position: absolute;
    top: 0;
    right: 1rem;
    z-index: 20;
    width: auto;
    /* Ensure it sits above other content */
}

/* Style the content box to look like a tab */
.j-social-icons .g-content {
    background-color: #ffffff;
    padding: 12px 25px;
    border-bottom-left-radius: 6px;
    border-bottom-right-radius: 6px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Reset margins on the social items container to ensure centering in the tab */
.j-social-icons .g-social-items {
    margin: 0;
    column-gap: 20px;
    align-items: center;
}

/* Style the links/icons - Override white text with dark blue */
.j-social-icons a,
.j-social-icons span {
    color: rgb(26, 60, 130);
    transition: all 0.3s ease;
    display: inline-block;
    font-size: 1.5rem;
}

/* Hover Effects */
.j-social-icons a:hover,
.j-social-icons a:hover span {
    color: rgb(198, 147, 56);
    /* Gold accent color found in existing styles */
    transform: translateY(-1px);
    cursor: pointer;
}

/* Mobile Breakpoint Styles */
@media (max-width: 50.99rem) {
    .j-social-icons {
        position: relative;
        top: auto;
        right: auto;
        width: 100%;
        display: flex;
        justify-content: center;
    }

    /* Remove the white tab look on mobile */
    .j-social-icons .g-content {
        background-color: transparent;
        box-shadow: none;
        padding: 10px 0;
        border-radius: 0;
    }

    /* Revert icons to white on mobile (since background is blue) */
    .j-social-icons a,
    .j-social-icons span {
        color: #ffffff;
    }
}

/*  */

/* --- Variables & Scope --- */
.blue-logo {
    --primary: var(--primary-color-rgb);
    /* Navy */
    --secondary: var(--secondary-color-rgb);
    /* Goldenrod */
    --tertiary: var(--tertiary-color-rgb);
    /* Ivory/Taupe */
    --white: 255, 255, 255;
    /* White */

    /* 1. Layout & Stacking Context (Z-Index Fix) */
    position: relative !important;
    z-index: 1000 !important;
    overflow: visible !important;
    /* Changed from 'hidden' so dropdowns can spill out */
    border-bottom: 1px solid rgba(var(--primary), 0.1);
}

/* --- Content Layering --- */
/* Z-Index increased to sit on top of background AND page content */
.blue-logo .g-container {
    position: relative !important;
    z-index: 1001 !important;
}

.g-main-nav {
    font-family: var(--body-font-family) !important;
    padding-top: 1rem;
}

.g-main-nav .g-toplevel>li.g-parent>.g-menu-item-container:after {
    margin-left: 0 !important;
}

/* --- Logo Styling --- */
.blue-logo .g-grid {
    justify-content: center !important;
}

.blue-logo .g-logo {
    justify-content: center !important;
    margin: 0 auto;
    width: 100%;
    transform: none !important;
    transition: none !important;
}

/* Bigger Logo (User Settings) */
.blue-logo .g-logo img {
    display: block;
    margin: 0 auto;
    height: auto !important;
    width: 100% !important;
    min-width: 400px !important;
    max-width: 1000px !important;
}

/* --- Main Navigation Items --- */
.blue-logo .g-main-nav .g-toplevel {
    justify-content: center !important;
}

.blue-logo .g-menu-item-container {
    color: white !important;
    font-weight: 700;
    letter-spacing: 1.5px !important;
    padding: 15px 20px !important;
    border: none !important;
    transition: color 0.3s ease;
}

.g-main-nav .g-toplevel>li .g-menu-item-title {
    font-size: min(1.25vw, 20px);
    font-weight: bold;
}

.blue-logo .g-toplevel>.g-menu-item>.g-menu-item-container:hover {
    color: rgb(var(--secondary)) !important;
    background: transparent !important;
}

.blue-logo .g-logo {
    padding-top: 1rem;
}

/* Underline Animation */
.blue-logo .g-toplevel>.g-menu-item>.g-menu-item-container {
    position: relative;
}

.blue-logo .g-toplevel>.g-menu-item>.g-menu-item-container::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 10px;
    left: 50%;
    background-color: rgb(var(--secondary));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.blue-logo .g-toplevel>.g-menu-item:hover>.g-menu-item-container::after {
    width: 50%;
}

/* --- Dropdowns --- */
.blue-logo .g-dropdown {
    background-color: rgb(var(--white)) !important;
    border-top: 3px solid rgb(var(--secondary));
    border-radius: 0 0 4px 4px;
    box-shadow: 0 10px 25px rgba(var(--primary), 0.15) !important;
    padding: 10px 0;
    min-width: 240px !important;
    z-index: 1002 !important;
    /* Ensure dropdown sits above container */
}

/* Dropdown Links */
.blue-logo .g-dropdown .g-menu-item-container,
.blue-logo .g-dropdown .g-menu-item-content {
    color: rgb(var(--primary)) !important;
}

.blue-logo .g-sublevel .g-menu-item-container {
    font-size: 0.9rem !important;
    padding: 12px 25px !important;
    font-weight: 600 !important;
    border-left: 3px solid transparent !important;
    display: block;
}

/* Dropdown Hover */
.blue-logo .g-sublevel .g-menu-item-container:hover {
    background-color: rgba(var(--tertiary), 0.4);
    color: rgb(var(--secondary)) !important;
    border-left: 3px solid rgb(var(--secondary)) !important;
    padding-left: 30px !important;
}

/* --- Mobile Styles --- */
@media (max-width: 50.99rem) {
    .blue-logo {
        padding-top: 20px !important;
        padding-bottom: 20px !important;
    }

    .blue-logo .g-logo img {
        min-width: unset !important;
        max-width: 80% !important;
    }

    .blue-logo .g-main-nav {
        background-color: rgba(255, 255, 255, 0.95) !important;
    }

    .blue-logo .g-dropdown {
        box-shadow: none !important;
        border-top: none;
        background-color: rgba(var(--tertiary), 0.3) !important;
    }
}

/* Slideshow */

/*  */

/* 1. Establish positioning context on the main container */
.overlay-slideshow .g-container {
    position: relative;
}

/* 2. Position the grid containing the image absolutely to the bottom-left */
.overlay-slideshow .g-grid:has(.img-wrapper) {
    position: absolute;
    bottom: 3rem;
    /* Adjust distance from bottom */
    left: 3rem;
    /* Adjust distance from left */
    top: auto;
    /* Reset vertical alignment */
    transform: none;
    /* Reset any centering transforms */
    width: auto;
    /* Let content define width */
    z-index: 20;
    /* Ensure above slideshow */
    pointer-events: none;
    /* Allow clicking through to slide controls */
}

/* 3. Reset wrapper margins causing offset issues */
.overlay-slideshow .img-wrapper {
    margin: 0 !important;
    /* Override the existing -80px margin */
    display: block;
    width: auto;
}

/* 4. Style the SVG/Image (Remove box, set size) */
.overlay-slideshow .img-wrapper img {
    /* Remove existing heavy borders and backgrounds */
    border: none !important;
    background-color: transparent !important;
    box-shadow: none !important;

    /* Size appropriate for a corner label */
    max-width: 50%;
    height: auto;

    /* Optional: Add drop shadow for readability */
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

/* 5. Mobile Adjustments */
@media (max-width: 50.99rem) {
    .overlay-slideshow .g-grid:has(.img-wrapper) {
        bottom: 0.5rem;
        left: 50%;
        transform: translate(-50%, 0);
        width: 100%;
    }

    .overlay-slideshow .img-wrapper img {
        max-width: 75%;
        width: 1000px;
        display: grid;
        margin: auto;
    }

    .site-home #g-slideshow .swiper-pagination-bullets {
        display: none;
    }
}

/*  */

/* Scope: .fullwidth-swiper 
   Goal: Center crop images and add interaction states
*/

/* Force images to fill the slide and center the crop */
.fullwidth-swiper .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Navigation Arrow Hover Effects */
/* Targeting direct children divs of swiper-navigation to avoid using specific IDs */
.fullwidth-swiper .swiper-navigation>div:hover {
    background-color: rgba(0, 0, 0, 0.6);
    border-color: #ffffff;
    opacity: 1;
}

/* Pagination Dot Hover Effects */
.fullwidth-swiper .swiper-pagination-bullet:hover {
    background-color: #ffffff;
    opacity: 1;
}

/*  */

/* Header */

.site-home #g-header {
    padding: 2.5% !important;
}


.site-home .g-container:has(.ql-veiled) {
    max-width: 1200px !important;
}

/* ql-v */

@media only screen and (min-width: 50.99rem) {
    .ql-veiled {
        margin: 0;
        padding: 0;
    }

    .ql-veiled>.g-content {
        margin: 0;
        padding: 0;
    }

    .ql-veiled>.g-content>div {
        margin: 0;
        padding: 0;
    }

    .ql-veiled .g-blockcontent {
        margin: 0;
        padding: 0;
    }

    .ql-veiled .g-blockcontent-subcontent {
        margin: 0;
        padding: 0;
        display: flex;
        flex-direction: row;
        gap: 7%;
    }

    .ql-veiled .g-blockcontent-subcontent-block {
        margin: 0;
        padding: 0;
        flex: 1;
        position: relative;
        overflow: hidden;
        border-radius: 50%;
        box-shadow: 4px 4px 8px rgba(0, 0, 0, .4);
        transition: .3s all ease-in-out;
    }

    .ql-veiled .g-blockcontent-subcontent-block:hover {
        transform: scale(1.05);
    }

    .ql-veiled .g-blockcontent-subcontent-block-content {
        margin: 0;
        padding: 0;
        transition: .3s all ease-in-out;
    }

    .ql-veiled .g-blockcontent-subcontent-img {
        margin: 0;
        padding: 0;
        width: 100%;
        aspect-ratio: 1/1;
        object-fit: cover;
        object-position: center;
        height: auto;
        transition: .3s all ease-in-out;
    }

    .ql-veiled .g-blockcontent-subcontent-title {
        margin: 0;
        padding: min(1vw, 1rem) min(3vw, 3rem);
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        background: rgba(var(--primary-color-rgb), .75);
        transition: .3s all ease-in-out;
        min-height: 1px;
        height: 100%;
    }

    .ql-veiled .g-blockcontent-subcontent-title-text {
        margin: 0;
        padding: 0;
        font-size: min(2vw, 2rem);
        line-height: 1;
        color: var(--default-white);
        font-weight: 400;
        font-family: var(--body-font-family);
        text-align: center;
        transition: .3s all ease-in-out;
        line-height: 1.25;
    }
}

@media only screen and (max-width: 50.99rem) {
    .ql-veiled .g-blockcontent-subcontent {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        /* Allows the 3rd and 4th item to wrap to a second row */
        justify-content: center;
        gap: 1rem;
        /* Space between the circles */
        padding: 1rem 0;
    }

    .ql-veiled .g-blockcontent-subcontent-block {
        margin: 0;
        padding: 0;
        position: relative;
        overflow: hidden;
        border-radius: 50%;
        box-shadow: 4px 4px 10px rgba(0, 0, 0, .3);

        /* Calculate width for 2 columns: (100% - gap) / 2 */
        width: calc(50% - 0.5rem);
        max-width: 185px;
        /* Prevents them from getting too huge on tablets */
        aspect-ratio: 1/1;
    }

    .ql-veiled .g-blockcontent-subcontent-img {
        width: 100%;
        height: 100%;
        aspect-ratio: 1/1;
        object-fit: cover;
        display: block;
    }

    .ql-veiled .g-blockcontent-subcontent-title {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 100%;
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        /* Center text vertically for better fit in smaller circles */
        background: rgba(26, 60, 130, 0.6) !important;
        border-radius: 50%;
        padding: 15%;
        /* Keeps text away from the edges of the circle */
    }

    .ql-veiled .g-blockcontent-subcontent-title-text {
        /* Use clamp so text scales slightly based on screen width */
        font-size: clamp(0.9rem, 4.5vw, 1.2rem);
        color: #ffffff !important;
        line-height: 1.2;
        text-align: center;
        font-weight: 600;
        margin-bottom: 0 !important;
    }

    /* Adjust gold line for the smaller mobile scale */
    .ql-veiled .g-blockcontent-subcontent-title-text::after {
        width: 40px;
        height: 2px;
        bottom: -8px;
    }

}

/* --- Container & Layout --- */
/* Center the grid items */
.ql-veiled .g-blockcontent-subcontent {
    justify-content: center;
}

/* Ensure the link covers the entire circle on all devices */
.ql-veiled .g-blockcontent-buttons {
    margin: 0;
    padding: 0;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100%;
    width: 100%;
    opacity: 0;
    z-index: 10;
}

.ql-veiled .g-blockcontent-buttons a {
    margin: 0;
    padding: 0;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100%;
    width: 100%;
    cursor: pointer;
    display: block;
}

/* --- Circular Card Styling --- */
/* Target the individual blocks to ensure they are circular and handle overflow */
.ql-veiled .g-blockcontent-subcontent-block {
    position: relative;
    border-radius: 50%;
    overflow: hidden;
    /* Clips the image and overlay to the circle */
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    /* Soft drop shadow */
    background-color: #000;
    /* Dark background behind image */
    cursor: pointer;
}

/* --- Image Styling --- */
/* Ensure image fills the circle */
.ql-veiled .g-blockcontent-subcontent-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-out;
    /* Smooth zoom effect */
}

/* Hover Effect: Zoom the image slightly */
.ql-veiled .g-blockcontent-subcontent-block:hover .g-blockcontent-subcontent-img {
    transform: scale(1.03);
}

/* --- Overlay & Title Styling --- */
/* The H4 acts as the colored overlay */
.ql-veiled .g-blockcontent-subcontent-title {
    /* Override existing blue text color to White */
    color: #ffffff !important;
    /* Ensure the background matches the screenshot blue with opacity */
    background-color: rgba(26, 60, 130, 0.6) !important;
    border-radius: 50%;
    /* Matches container shape */
    transition: background-color 0.3s ease;
}

/* Hover Effect: Lighten overlay slightly for interactivity */
.ql-veiled .g-blockcontent-subcontent-block:hover .g-blockcontent-subcontent-title {
    background-color: rgba(26, 60, 130, 0.7) !important;
}

/* --- Text & Gold Underline --- */
.ql-veiled .g-blockcontent-subcontent-title-text {
    color: #ffffff !important;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    /* Improves legibility */

    /* Setup for the underline */
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
    /* Space between text and line */
}

/* The Gold Underline (#c69338) */
.ql-veiled .g-blockcontent-subcontent-title-text::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    /* Centers the line */
    width: 75px;
    /* Fixed width for a decorative look */
    height: 3px;
    background-color: #c69338;
    border-radius: 2px;
}

/*  */

/* Feature */

@media (max-width: 50.99rem) {

    .withmaxwidth:not(.sponsorshippage) #g-feature>.g-container {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .withmaxwidth:not(.sponsorshippage) #g-utility>.g-container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .withmaxwidth:not(.sponsorshippage) #g-container-main>.g-container {
        padding: 1rem 1.5rem !important;
    }

    .withmaxwidth:not(.sponsorshippage) #g-footer>.g-container {
        padding: 0 !important;
    }

    #g-footer>.g-container>.g-grid>.g-block {
        padding: 0 !important;
    }

    .footer-title h1 {
        font-size: 2.5rem !important;
    }

}

/* Layout & Container Styling */
.horizontal-calendar .gcaltohtml {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    padding: 2rem;
    background-color: #f0f0f0;
}

.horizontal-calendar .cc-date-event-container {
    display: flex;
    flex: 1 1 calc(33.333% - 1.5rem);
    min-width: 300px;
    height: auto;
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Sidebar Date Block */
.horizontal-calendar .cc-dateblockformat {
    background-color: rgb(var(--primary-color-rgb));
    color: #fff;
    width: 80px;
    min-width: 80px;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0;
    border-radius: 0;
    border-right: 4px solid #c69338;
}

.horizontal-calendar .cc-monthformat {
    font-size: 0.85rem;
    margin-bottom: 2px;
    opacity: 0.9;
}

.horizontal-calendar .cc-dayformat {
    font-size: 1.8rem;
    line-height: 1;
}

/* Event Content Area */
.horizontal-calendar .cc-eventblock {
    flex-grow: 1;
    background: transparent;
    border: none;
    margin: 0;
    padding: 1.5rem;
    height: auto;
    max-height: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.horizontal-calendar .event {
    height: auto;
    padding: 0;
    margin: 0;
    border: none;
}

.horizontal-calendar .event+.event {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

.horizontal-calendar .cc-timeofday {
    color: #666;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.horizontal-calendar .cc-title {
    color: rgb(var(--primary-color-rgb));
    font-size: 1.25rem;
    font-weight: 600;
    height: auto;
    white-space: normal;
    overflow: visible;
}

.horizontal-calendar .cc-title:hover {
    opacity: 0.8;
}

/* Mobile Responsiveness */
@media (max-width: 50.99rem) {
    .horizontal-calendar .cc-date-event-container {
        flex: 1 1 100%;
        min-width: 100%;
    }

    .horizontal-calendar .gcaltohtml {
        padding: 1.5rem 1.5rem;
        gap: 1rem;
    }
}

/*BOTTOM*/

#g-bottom {
    position: relative;
    z-index: 10;
}

#g-bottom>.g-container {
    padding: 2rem 0 !important;
}

#g-bottom .admod td {
    padding-top: 0 !important;
}

.search-page #searchForm .btn {
    background: var(--primary-color);
}

.grid-articles .g-array-item-text a:not(a.button) {
    color: var(--primary-color);
}

.grid-articles .g-array-item-text a {
    color: var(--primary-color);
}

@media only screen and (max-width: 50.99rem) {
    .admod.adside tbody {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-items: center;
        gap: .5rem .5rem;
    }
}

@media only screen and (max-width: 50.99rem) {
    body#site-grid.newslayout #g-container-main>.g-container {
        padding: 2rem 1rem !important;
    }

    body#site-grid.newslayout #g-container-main #g-mainbar {
        margin: 0 !important;
        padding: 0 !important;
    }

    #site-grid.newslayout .grid-mobile-stacked .g-item-title {
        --grid-title-font-size: 3vw;
    }
}

@media only screen and (max-width: 50.99rem) {
    body .side-menu-particle .g-blockcontent-subcontent-title-text {
        --side-menu-font-size-desktop: 4vw;
    }
}


@media only screen and (min-width: 50.99rem) {
    .site-sub #g-aside {
        padding-top: 2rem !important;
    }
}

/*  */

/* calendar mockup */

/* Variables and Section Setup */
.calendar-section {
    --p-rgb: 26, 60, 130;
    --s-rgb: 198, 147, 56;
    --t-rgb: 240, 234, 214;
    --w-rgb: 255, 255, 255;
    --b-rgb: 0, 0, 0;

    background-color: rgb(var(--w-rgb));
    padding-bottom: 3rem;
    /* Space at bottom */
}

/* Title Banner - Full Width */
.calendar-section h1 {
    background-color: rgb(var(--p-rgb));
    color: rgb(var(--w-rgb));
    text-align: center;
    padding: 1.5rem 1rem;
    width: 100%;
    margin: 0;
    border: none;
    font-family: var(--title-font-family, sans-serif);
    /* Fallback added */
    font-size: 4.5rem;
}

/* Button - Centered and Compact */
.calendar-section a.button {
    display: table;
    /* Shrinks to fit content */
    margin: 2rem auto 0 auto;
    width: auto;
    min-width: 200px;
    max-width: 100%;

    /* Visual Styles */
    background-color: rgb(var(--p-rgb));
    color: rgb(var(--w-rgb));
    border: 1px solid rgb(var(--p-rgb));
}

/* Button Hover State */
.calendar-section a.button:hover {
    background-color: rgb(var(--s-rgb));
    border-color: rgb(var(--s-rgb));
    color: rgb(var(--w-rgb));
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(var(--s-rgb), 0.4);
}

/* Grid Wrapper */
.calendar-section .events-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    padding: 3rem 2rem 0 2rem;
    margin: 0 auto;
}

#custom-6396-particle {
    padding-bottom: 3rem;
}

/* Event Card Styling */
.calendar-section .event-card {
    background-color: rgb(var(--w-rgb));
    border-left: 5px solid rgb(var(--s-rgb));
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    /* Subtle shadow */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    border-radius: 4px;
}

/* Card Hover Effect */
.calendar-section .event-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(var(--p-rgb), 0.1);
}

/* Date Badge */
.calendar-section .event-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 65px;
    height: 65px;
    background-color: rgba(var(--p-rgb), 0.06);
    border-radius: 6px;
    color: rgb(var(--p-rgb));
    line-height: 1.1;
    flex-shrink: 0;
}

.calendar-section .event-date .day {
    font-size: 1.6rem;
    font-weight: 700;
}

.calendar-section .event-date .month {
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 600;
}

/* Event Info Text */
.calendar-section .event-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.calendar-section .event-title {
    margin: 0 0 0.4rem 0;
    font-size: 1.5rem;
    color: rgb(var(--p-rgb));
    line-height: 1.3;
    font-weight: 700;
    font-family: var(--body-font-family, sans-serif);
    /* Applied as requested */
    text-decoration-color: rgb(var(--s-rgb));
    /* For any potential underline styles */
}

.calendar-section .event-meta {
    font-size: 0.85rem;
    color: rgba(var(--b-rgb), 0.6);
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Mobile Responsiveness */
@media (max-width: 50.99rem) {
    .calendar-section .events-wrapper {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .calendar-section .event-card {
        padding: 1.25rem;
    }
}

/*  */

/* Reset rigid positioning and dimensions from base styles */
.immaculate-heart .hero-banner,
.immaculate-heart .hero-content,
.immaculate-heart .hero-text-wrapper,
.immaculate-heart .hero-image,
.immaculate-heart h1,
.immaculate-heart .cta-button,
.immaculate-heart img {
    box-sizing: border-box;
    width: auto;
    height: auto;
    min-height: 0;
    max-width: none;
    transform: none;
    perspective: none;
}

/* Container Adjustments */
.immaculate-heart .g-container {
    max-width: 1400px;
    /* Constrain ultra-wide width */
    margin: 0 auto;
    height: auto;
    display: block;
}

.immaculate-heart .g-block {
    flex-basis: auto;
    width: 100%;
}

/* Hero Banner Layout */
.immaculate-heart .hero-banner {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    justify-content: space-between;
    /* Dark blue base color ensures no white flashes if images load slow */
    background-color: rgb(20, 40, 90);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    margin: 2rem 1rem;
    margin: 0 2.5% !important;
}

/* --- REVISED CONTENT SIDE START (Blur & Overlay) --- */
.immaculate-heart .hero-content {
    flex: 1 1 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 4rem 4rem;
    position: relative;
    /* Essential for overlay positioning */
    overflow: hidden;
    /* Keeps the blur edges contained */
}

/* Layer 1: The Background Image (Blurred) */
.immaculate-heart .hero-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Replace this URL with your actual background texture image */
    background-image: url('/images/stories/template/cross-pendant.jpg');
    background-size: cover;
    background-position: center;
    /* This creates the frosted effect */
    filter: blur(10px);
    /* Scaling up slightly prevents white edges from the blur filter */
    transform: scale(1.1);
    z-index: 1;
}

/* Layer 2: The Blue Overlay */
.immaculate-heart .hero-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Adjust the last number (0.9) to make the blue more or less transparent */
    background: linear-gradient(105deg, rgba(26, 60, 130, 0.9) 0%, rgba(20, 40, 90, 0.95) 100%);
    z-index: 2;
}

/* Layer 3: The Content Wrapper (Must be on top) */
.immaculate-heart .hero-text-wrapper {
    width: 100%;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
    text-align: left;
    position: relative;
    z-index: 3;
    /* Lifts content above the blur/overlay */
}

/* --- REVISED CONTENT SIDE END --- */


/* Typography Overrides */
.immaculate-heart h1 {
    font-size: 4.5rem;
    line-height: 1.1;
    color: #ffffff;
    margin: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    font-weight: 400;
    /* Script fonts usually look better with normal weight */
}

/* Button Styling */
.immaculate-heart .cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    color: rgb(26, 60, 130);
    border: 2px solid #ffffff;
    border-radius: 4px;
    /* Slightly sharper radius to match screenshot */
    padding: 0.8rem 2rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    font-weight: 600;
    font-size: 1.25rem;
}

.immaculate-heart .cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
    background-color: transparent;
    color: #ffffff;
}

/* Icon inside button */
.immaculate-heart .cta-button i {
    display: block;
    font-size: 1.25rem;
    margin-right: 0.5rem;
    /* Space between icon and text */
}

/* Image Side (Right side) */
.immaculate-heart .hero-image {
    flex: 1 1 50%;
    position: relative;
    min-height: 450px;
    background-color: #fff;
    /* Fallback */
}

.immaculate-heart .hero-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    object-position: center 25%;
}

/* Mobile Breakpoint */
@media (max-width: 50.99rem) {
    .immaculate-heart .hero-banner {
        flex-direction: column;
        margin: 1rem;
    }

    .immaculate-heart .hero-content {
        padding: 3rem 1.5rem;
        align-items: center;
        text-align: center;
    }

    .immaculate-heart .hero-text-wrapper {
        align-items: center;
        text-align: center;
    }

    .immaculate-heart h1 {
        font-size: 2.5rem;
    }

    .immaculate-heart .hero-image {
        width: 100%;
        min-height: 300px;
        flex: none;
    }
}

/*  */

/* Scoped Styles for Meet The Sisters */
.meet-the-sisters {
    --primary: rgb(26, 60, 130);
    --secondary: rgb(198, 147, 56);
    --tertiary: rgb(240, 234, 214);
    --white: rgb(255, 255, 255);
    --black: rgb(0, 0, 0);
    padding: 4rem 2rem;
}

.meet-the-sisters .g-content-array {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

.meet-the-sisters .g-content-array>.g-grid {
    flex: 0 1 23%;
    height: auto !important;
    block-size: auto !important;
    margin-bottom: 0 !important;
}

.meet-the-sisters .g-block,
.meet-the-sisters .g-content {
    height: 100%;
}

/* Card Styling - Removed fixed aspect-ratio to prevent content clipping */
.meet-the-sisters .g-array-item {
    background-color: var(--primary);
    padding: 2rem;
    border-radius: 8px;
    width: 100%;
    gap: 0;
    height: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.meet-the-sisters .g-array-item-text p {
    margin: 0;
}

/* Image Styling - Perfect Circles */
.meet-the-sisters .g-array-item-image {
    height: auto !important;
    block-size: auto !important;
    width: 100%;
    margin-bottom: 1.5rem;
    flex: 0 0 auto;
    pointer-events: none;
}

.meet-the-sisters .g-array-item-image img {
    width: 100%;
    max-width: 220px;
    aspect-ratio: 1 / 1;
    /* Ensures image is square before rounding */
    border-radius: 50%;
    /* Creates the perfect circle */
    border: 4px solid var(--secondary);
    object-fit: cover;
}

/* Typography */
.meet-the-sisters .g-item-title {
    margin-bottom: 0.5rem;
    border-bottom: 2px solid var(--secondary);
    display: inline-block;
    padding-bottom: 0.25rem;
    flex-shrink: 0;
    font-size: clamp(1.5rem, 2vw, 2.5rem);
}

.meet-the-sisters .g-item-title a {
    color: var(--white);
    text-decoration: none;
    pointer-events: none;
}

/* Scrollable Text with Hidden Scrollbar */
.meet-the-sisters .g-array-item-text {
    color: var(--tertiary);
    margin-bottom: 1rem;
    max-height: 400px;
    overflow-y: auto;
    flex-grow: 1;
    -ms-overflow-style: none;
    /* IE and Edge */
    scrollbar-width: none;
    /* Firefox */
}

.meet-the-sisters .g-array-item-text::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, and Opera */
}

/* Buttons */
.meet-the-sisters .button {
    background-color: var(--secondary);
    color: var(--white);
    border: 2px solid var(--secondary);
    border-radius: 6px;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
    padding: 0.75rem 1.5rem;
    transition: background-color 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
}

.meet-the-sisters .button:hover {
    background-color: var(--white);
    border-color: var(--white);
    color: var(--primary);
}

/* Pagination */
.meet-the-sisters .g-content-array-pagination {
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.meet-the-sisters .pagination-button {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    border-radius: 6px;
}

.meet-the-sisters .pagination-button:hover {
    background-color: var(--primary);
    color: var(--white);
}

/* Tablet Layout (2 columns) */
@media (min-width: 51rem) and (max-width: 75rem) {
    .meet-the-sisters .g-content-array>.g-grid {
        flex: 0 1 45%;
    }
}

/* Mobile Breakpoint (1 column) */
@media (max-width: 50.99rem) {
    .meet-the-sisters {
        padding: 2rem 0rem;
    }

    .meet-the-sisters .g-content-array {
        flex-direction: column;
        align-items: center;
    }

    .meet-the-sisters .g-content-array>.g-grid {
        width: 100%;
        max-width: 450px;
        flex: none;
    }
}

/* Section Title (Unchanged as it sits on white usually) */
.section-title-container {
    --primary: rgb(26, 60, 130);
    --secondary: rgb(198, 147, 56);

    padding-bottom: 2rem;
    text-align: center;
    width: 100%;
}

.styled-heading {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 1rem;
    margin: 0;
    line-height: 1;
}

.styled-heading .text-script {
    font-family: var(--title-font-family, cursive);
    color: var(--primary);
    font-size: 5rem;
    font-weight: 400;
    font-variant-caps: normal;
}

.styled-heading .text-body {
    font-family: var(--body-font-family, sans-serif);
    color: var(--secondary);
    font-size: 3rem;
    font-weight: 300;
}

@media (max-width: 768px) {
    .styled-heading {
        flex-wrap: wrap;
    }

    .styled-heading .text-script {
        font-size: 4rem;
    }

    .styled-heading .text-body {
        font-size: 2.5rem;
    }
}

/*  */

/* Scoped Styles for Connect With Us Section */
.connect-with-us {
    --primary: rgb(26, 60, 130);
    /* Navy Blue */
    --secondary: rgb(198, 147, 56);
    /* Goldenrod */
    --white: rgb(255, 255, 255);

    max-width: 1200px;
    padding-top: 5%;
    margin: 0 auto;
    font-family: var(--body-font-family, sans-serif);
}

/* --- Header Styling --- */
.connect-with-us .connect-header {
    text-align: left;
    margin-bottom: 2rem;
}

.connect-with-us .section-title {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    /* UPDATED: Increased gap slightly for larger text */
    margin: 0;
    line-height: 1;
}

.connect-with-us .text-script {
    font-family: var(--title-font-family, cursive);
    color: var(--primary);
    font-size: 5rem;
    /* UPDATED: Increased from 4rem */
    font-weight: 400;
    font-variant-caps: normal;
}

.connect-with-us .text-body {
    font-family: var(--body-font-family, sans-serif);
    color: var(--secondary);
    font-size: 3rem;
    /* UPDATED: Increased from 2.5rem */
    font-weight: 300;
}

/* --- Grid Layout --- */
.connect-with-us .connect-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* 2 Columns */
    gap: 2rem;
}

/* --- Card Styling --- */
.connect-with-us .connect-card {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 4;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.connect-with-us .card-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.connect-with-us .connect-card:hover .card-bg {
    transform: scale(1.05);
}

/* Content Overlay */
.connect-with-us .card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    transition: background 0.3s ease;
    color: var(--white);
    pointer-events: none;
}

.connect-with-us .connect-card:hover .card-overlay {
    /* UPDATED: Increased hover opacity from 0.5 to 0.85 */
    background: rgba(0, 0, 0, 0.65);
}

/* Typography inside Card */
.connect-with-us .card-title {
    font-family: var(--title-font-family, cursive);
    font-size: 3rem;
    /* UPDATED: Increased from 2.5rem */
    font-weight: 400;
    margin: 0 0 1rem 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    color: var(--white);
}

.connect-with-us .card-desc {
    font-size: 1.2rem;
    /* UPDATED: Increased from 1rem */
    line-height: 1.6;
    margin-bottom: 1.5rem;
    max-width: 90%;
    color: var(--white);
}

/* Link Styling */
.connect-with-us .card-link {
    color: var(--white);
    text-decoration: none;
    text-transform: uppercase;
    font-weight: bold;
    font-size: 1.1rem;
    /* UPDATED: Increased from 0.9rem */
    letter-spacing: 1px;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
    pointer-events: auto;
}

.connect-with-us .card-link::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.connect-with-us .connect-card:hover .card-link {
    border-bottom-color: var(--secondary);
}

/* --- Mobile Responsiveness --- */
@media (max-width: 50.99rem) {
    .connect-with-us .connect-grid {
        grid-template-columns: 1fr;
    }

    .connect-with-us .section-title {
        flex-wrap: wrap;
        justify-content: center;
    }

    .connect-with-us .connect-header {
        text-align: center;
    }
}

/*  */

/* Scope */
.sister-footer {
    --primary-color-rgb: 26, 60, 130;
    --secondary-color-rgb: 198, 147, 56;
    --tertiary-color-rgb: 240, 234, 214;
    --default-white-rgb: 255, 255, 255;

    width: 100%;
    box-sizing: border-box;
}

/* Background & Section Spacing */
.sister-footer .footer-section {
    /* background-color: rgba(var(--primary-color-rgb), 1); */
    color: rgba(var(--tertiary-color-rgb), 1);
    padding: 3rem 1rem;
}

.sister-footer .footer-container {
    /* max-width: 1000px; */
    padding: 0 10%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: start;
    /* Centers everything horizontally */
    text-align: left;
}

/* --- LOGO (Top) --- */
.sister-footer .footer-logo {
    max-width: 1200px;
    /* Large, prominent logo */
    width: 100%;
    /* Responsive width */
    height: auto;
    margin-left: -10px;
    object-fit: contain;
    margin-bottom: 1.5rem;
    /* Space between logo and address */
}

/* --- ADDRESS (Middle) --- */
.sister-footer .footer-contact {
    width: 100%;
    margin-bottom: 1rem;
    /* Space between address and links divider */
}

.sister-footer .footer-contact p {
    margin: 0 0 0.5rem 0;
    line-height: 1.6;
    font-size: 1.15rem;
    /* Slightly larger text for readability */
    color: rgba(var(--tertiary-color-rgb), 1);
}

/* --- LINKS (Bottom) --- */
.sister-footer .footer-links {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 2rem;
    /* padding-top: 1rem; */
    /* border-top: 1px solid rgba(var(--tertiary-color-rgb), 0.3);  */
}

/* Link Styling */
.sister-footer a {
    color: rgba(var(--default-white-rgb), 1);
    text-decoration: none;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.sister-footer a:hover {
    color: rgba(var(--secondary-color-rgb), 1);
}

/* --- MOBILE BREAKPOINT --- */

@media (max-width: 50.99rem) {
    .sister-footer .footer-links {
        flex-direction: row;
        gap: 1rem;
    }

    .sister-footer .footer-logo {
        width: 100%;
        max-width: 400px;
        /* Slightly smaller max size for mobile */
    }
}

/*  */

.gold-underline {
    position: relative;
    line-height: 1;
    margin-top: 0;
}

.gold-underline::after {
    content: "";
    display: block;
    width: 220px;
    height: 4px;
    background-color: rgb(var(--secondary-color-rgb));
    margin: 12px auto 0;
}

/*  */

.bg-footer-j {
    position: relative;
}

#g-footer {
    position: relative;
    z-index: 100;
    background-image: url('/images/stories/template/footer-background.png');
    background-size: auto 100%;
    background-position: right center;
    background-repeat: no-repeat;
}

.footer-section {
    background-color: rgba(var(--primary-color-rgb), 0.5);
    /* 85% opacity overlay */
    backdrop-filter: blur(0px);
}

.footer-section h1 {
    color: white;
    font-size: 3vw;
    margin: 0;
    line-height: 1;
}

.footer-section p {
    margin: 0 !important;
}

.footer-container {
    gap: 1rem;
}

/*  */

@media (max-width: 50.99rem) {
    .g-offcanvas-toggle {
        display: grid;
        top: 0;
        left: 0;
        border-radius: 0 0 50% 0;
    }

    .footer-section {
        background-color: rgba(var(--primary-color-rgb), 0.75);
        /* 85% opacity overlay */
        backdrop-filter: blur(0px);
    }

    .footer-container {
        gap: 1.5rem;
    }
}

/*  */

/*  */

@media (max-width: 50.99rem) {
    #g-navigation .g-logo {
        max-width: initial;
        padding-top: 0;
    }

    #g-navigation {
        padding-bottom: 0 !important;
    }
}

/* Swiper Premium Styles */

.j-swiper {
    position: relative;
    overflow: visible;
    padding: 1.5rem 0;
}

.j-swiper .g-content-array {
    overflow: visible;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: 2rem;
    justify-content: center;
}

.j-swiper .g-grid {
    flex: 0 0 calc(33.33% - 1.34rem) !important;
    margin: 0 !important;
    display: block !important;
}

@media (max-width: 768px) {
    .j-swiper .g-grid {
        flex: 0 0 100% !important;
    }
}

.j-swiper .g-array-item {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: transparent;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.j-swiper .g-array-item-image {
    position: relative;
    width: 100%;
    aspect-ratio: 5 / 3;
    border-radius: 0;
    overflow: hidden;
    box-shadow: 0 12px 36px -10px rgba(0, 0, 0, 0.2),
        0 4px 12px -4px rgba(0, 0, 0, 0.1);
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    background-color: #f8f9fa;
    background-image: url('/images/stories/apostolate/communitylife4.jpg');
    background-size: cover;
    background-position: center;
    margin-bottom: 1.5rem;
}

.j-swiper .g-array-item-image a {
    pointer-events: none !important;
    cursor: default !important;
}

.j-swiper .g-array-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.j-swiper .g-array-item-title {
    margin: 0 0 0.75rem 0;
}

.j-swiper .g-item-title,
.j-swiper .g-item-title a {
    font-family: inherit;
    /* Inherits the site's serif font */
    font-weight: 800;
    font-size: 1.75rem !important;
    line-height: 1.15;
    color: #1a3c82 !important;
    /* Context blue */
    text-decoration: none !important;
    transition: color 0.3s ease;
    display: block;
    border: none !important;
    /* Remove any underlines or borders from context */
    pointer-events: none !important;
    cursor: default !important;
}

.j-swiper .g-item-title a:hover {
    color: #1a3c82 !important;
}

.j-swiper .g-array-item-text {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #4b5563;
    margin: 0;
    opacity: 0.9;
}

/* Enhanced Navigation Buttons */
.j-swiper .g-content-array-pagination {
    /* margin-top: 2.5rem; */
    display: flex !important;
    justify-content: center;
    gap: 1.5rem;
}

.j-swiper .pagination-button {
    background: white !important;
    color: #1a3c82 !important;
    border: 2px solid #1a3c82 !important;
    border-radius: 0 !important;
    width: 50px !important;
    height: 50px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    padding: 0 !important;
    font-size: 0 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.j-swiper .pagination-button:after {
    content: '';
    width: 12px;
    height: 12px;
    border-top: 3px solid currentColor;
    border-right: 3px solid currentColor;
    display: block;
}

.j-swiper .pagination-button-prev:after {
    transform: rotate(-135deg);
    margin-left: 5px;
    /* Visual centering for rotated square */
}

.j-swiper .pagination-button-next:after {
    transform: rotate(45deg);
    margin-right: 5px;
    /* Visual centering for rotated square */
}

.j-swiper .pagination-button:hover:not(:disabled) {
    background: #1a3c82 !important;
    color: white !important;
    transform: scale(1.15) translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

.j-swiper .pagination-button:active:not(:disabled) {
    transform: scale(0.95);
}

.j-swiper .pagination-button:disabled {
    opacity: 0.25;
    cursor: not-allowed;
    border-color: #ccc !important;
    color: #ccc !important;
}

/*  */

/* Quote Box Styling - Scoped to .jp2-quote-box */

.jp2-quote-box {
    border: 1px solid #d1d5db;
    background-color: #ffffff;
    margin: 2rem 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    overflow: hidden;
}

.jp2-quote-box .quote-header {
    background-color: #1a3c82;
    color: #ffffff;
    padding: 10px 15px;
    font-weight: bold;
    font-size: 1.1rem;
    line-height: 1.2;
}

.jp2-quote-box .quote-content {
    display: flex;
    align-items: flex-start;
    padding: 20px;
    gap: 25px;
}

.jp2-quote-box .quote-image {
    flex-shrink: 0;
    max-width: 200px;
}

.jp2-quote-box .quote-image img {
    width: 100%;
    height: auto;
    display: block;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid #e5e7eb;
}

.jp2-quote-box .quote-text {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #374151;
    font-style: italic;
    margin: 0;
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
    .jp2-quote-box .quote-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .jp2-quote-box .quote-image {
        max-width: 180px;
        margin-bottom: 10px;
    }
}

/* Responsive Floated Images */
@media (max-width: 50.99rem) {

    img[style*="float: right"],
    img[style*="float:right"],
    img[style*="float: left"],
    img[style*="float:left"] {
        float: none !important;
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        margin: 0 auto 1.5rem !important;
    }
}

/* Responsive Side-by-Side/Stacking Layout */
@media (min-width: 64rem) {
    .mobile-stack-reverse {
        flex-direction: row !important;
        align-items: flex-start;
        gap: 30px;
    }

    .mobile-stack-reverse>div,
    .mobile-stack-reverse>ul {
        flex: 1;
        margin-bottom: 0 !important;
    }

    .mobile-stack-reverse img {
        width: 400px !important;
        float: none !important;
    }
}

/*  */

:root {
    --primary-color: rgb(26, 60, 130);
    --secondary-color: rgb(198, 147, 56);
    --tertiary-color: rgb(240, 234, 214);
}

/* Core Split Logic with Padding */
.split-container {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0;
    /* Gap handled by internal padding */
    margin: 40px 0;
    overflow: hidden;
}

.split-container.split-reversed {
    flex-direction: row-reverse;
}

/* Column Styles */
.split-col {
    flex: 1 1 350px;
    min-width: 0;
}

.split-text {
    padding: 40px;
    /* Internal padding for text */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.split-media {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    /* Padding around image */
}

.split-img {
    height: 100%;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    display: block;
}

/* Default Heading Style */
.split-heading {
    margin-top: 0;
    font-size: 2rem;
    font-weight: bold;
    text-transform: uppercase;
}

/* --- Template Variants --- */

/* 1. Primary Dark (Blue Background) */
.primary-dark {
    background-color: var(--primary-color);
    color: #fff;
}

.primary-dark .split-heading {
    color: var(--secondary-color);
}

/* 2. Gold Border (White Background) */
.gold-border {
    border: 2px solid var(--secondary-color);
    background-color: #fff;
}

.gold-border .split-heading {
    color: var(--primary-color);
    border-bottom: 2px solid var(--secondary-color);
    display: inline-block;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

/* 3. Cream Accent (Tertiary Background) */
.accent-cream {
    background-color: var(--tertiary-color);
    color: #333;
}

.accent-cream .split-heading {
    color: var(--primary-color);
}

/* Responsive Adjustments */
@media (max-width: 800px) {

    .split-container,
    .split-container.split-reversed {
        flex-direction: column !important;
    }

    .split-text {
        padding: 30px 20px;
    }

    .split-img {
        height: auto;
        width: 100%;
        max-height: 400px;
    }
}

/*  */

/* Layout 1: Floating Card Hero */
.hero-card-section {
    position: relative;
    padding: 60px 20px;
    background-color: var(--tertiary-color);
    display: flex;
    justify-content: center;
    border-radius: 12px;
}

.hero-card {
    background: #fff;
    max-width: 900px;
    display: flex;
    box-shadow: 0 15px 35px rgba(var(--primary-color-rgb), 0.15);
    border-radius: 8px;
    overflow: hidden;
    border-bottom: 4px solid var(--secondary-color);
}

.hero-card .text-panel {
    flex: 1;
    padding: 50px;
}

.hero-card .img-panel {
    flex: 0 0 300px;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Layout 2: Overlap Content */
/* Container for the overlap effect */
.overlap-container {
    position: relative;
    display: flex;
    align-items: center;
    margin: 60px 0;
    width: 100%;
}

/* The Background Image Wrap */
.overlap-image-wrap {
    flex: 0 0 70%;
    /* Image takes up 70% of the width */
    max-height: 500px;
    /* Limits the height of the section */
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 10px 10px 0px var(--tertiary-color);
}

.overlap-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Ensures different image sizes fill the area */
    display: block;
}

/* The Floating Text Card */
.overlap-card {
    flex: 0 0 45%;
    /* Card takes up 45% of the total width */
    margin-left: -15%;
    /* This creates the physical overlap */
    background: var(--primary-color);
    color: white;
    padding: 30px;
    border: 2px solid var(--secondary-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 2;
    border-radius: 4px;
}

/* Limit content inside the card */
.overlap-card h2 {
    margin-top: 0;
    color: var(--secondary-color);
    font-size: 1.5rem;
}

.overlap-card p {
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 0;
}

/* REVERSED: Card on Left, Image on Right */
.overlap-container.split-reversed {
    flex-direction: row-reverse;
}

.overlap-container.split-reversed .overlap-card {
    margin-left: 0;
    margin-right: -15%;
}

/* MOBILE FIX: No Overlap */
@media (max-width: 850px) {

    .overlap-container,
    .overlap-container.split-reversed {
        flex-direction: column;
    }

    .overlap-image-wrap,
    .overlap-card {
        flex: 1 1 100%;
        width: 100%;
        margin: 0;
    }

    .overlap-card {
        margin-top: -30px;
        /* Slight overlap for style, but safe */
        width: 90%;
    }
}

/* Responsive Fixes */
@media (max-width: 850px) {
    .hero-card {
        flex-direction: column;
    }

    .hero-card .img-panel {
        flex: none;
        height: 250px;
    }
}

/*  */

/* The "Full-Width Breakout" Utility */
.full-width-breakout {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

/* Ensure no horizontal scrollbars */
body {
    overflow-x: hidden;
}

/*  */

.banner-section.primary-bg {
    background-color: rgb(var(--primary-rgb));
    min-height: 300px;
    display: flex;
}

.banner-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    width: 100%;
    align-items: center;
}

.banner-text {
    flex: 1;
    padding: 60px;
}

.banner-title {
    color: rgb(var(--secondary-rgb));
    font-size: 2.5rem;
    /* Larger for 'Hero' feel */
    margin-bottom: 10px;
}

.banner-subtitle {
    color: white;
    font-size: 1.2rem;
    font-weight: 300;
}

.banner-media {
    flex: 0 0 300px;
    height: 100%;
}

.banner-media img {
    height: 300px;
    /* Matches banner height */
    width: auto;
    display: block;
}

/* Force breakout from padded Joomla containers */
.full-bleed {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -48vw;
    margin-right: -50vw;
}

/* Overlap Container Refinement */
.overlap-section {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 0;
    /* Huge vertical air */
    background: transparent;
    position: relative;
    /* Use full bleed to center relative to viewport */
}

.overlap-image-frame {
    flex: 0 0 60%;
    /* Adjusted to 60% */
    height: 500px;
    z-index: 1;
    overflow: hidden;
    border-radius: 2px;
}

.overlap-image-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.9);
}

.overlap-text-card {
    flex: 0 0 40%;
    /* Adjusted to 40% (60+40=100) */
    margin-left: -10%;
    /* Subtle overlap */
    z-index: 2;
    background: rgb(var(--primary-color-rgb));
    color: white;
    padding: 60px;
    /* Luxury internal padding */
    border: 1px solid rgb(var(--secondary-color-rgb));
    box-shadow: 10px 10px 30px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease;
}

/* Typographic Excellence */
.overlap-text-card h2 {
    color: rgb(var(--secondary-color-rgb));
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 25px;
    line-height: 1.1;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.overlap-text-card p {
    font-size: 1.1rem;
    line-height: 1.8;
    /* Let the text breathe */
    color: rgba(255, 255, 255, 0.85);
    margin: 0;
}

/* Responsive Logic */
@media (max-width: 992px) {
    .overlap-section {
        flex-direction: column;
        padding: 40px 3rem;
    }

    .overlap-image-frame {
        flex: 1 1 100% !important;
        width: 100% !important;
        height: 250px !important;
        max-height: 75vh !important;
        min-height: 0 !important;
    }

    .overlap-image-frame img {
        object-position: center center !important;
    }

    .overlap-text-card {
        flex: 1 1 100%;
        width: 90%;
        margin: -50px auto 0;
        /* Floating mobile overlap */
        padding: 40px;
        z-index: 5;
        left: auto;
        right: auto;
    }
}

.site-sub#site-grid #g-page-surround #g-container-main {
    padding-top: 2rem !important;
}

/*  */

/* Table Layout & Scoping */
.site-sub .table-container table {
    width: 100%;
    border-spacing: 0;
    table-layout: fixed;
}

/* Typography & Links */
.site-sub .table-container h6 {
    font-weight: 700;
    letter-spacing: 0.05em;
}

.site-sub .table-container a {
    text-decoration: none;
    font-weight: 600;
}

.site-sub .table-container a:hover {
    text-decoration: underline;
    opacity: 0.8;
}

/* iframe Responsiveness */
.site-sub .table-container iframe {
    border: none;
    border-radius: 4px;
    width: 100%;
}

/* Mobile Stacking Styles */
@media (max-width: 50.99rem) {
    .site-sub .table-container {
        height: auto !important;
    }

    .site-sub .table-container table,
    .site-sub .table-container tbody,
    .site-sub .table-container tr,
    .site-sub .table-container td {
        display: block !important;
        width: 100% !important;
        box-sizing: border-box;
    }

    .site-sub .table-container td {
        padding: 1rem 0;
    }

    .site-sub .table-container h6 {
        height: auto !important;
        margin-top: 0;
    }

    .site-sub .table-container p {
        height: auto !important;
        width: 100% !important;
    }
}

/*  */

/* 1. The Wrapper Class */
.story-profile {
    display: flex !important;
    /* Align items to the top - this ensures that if the image is sticky, it starts at the top. */
    align-items: flex-start !important;
    justify-content: space-between;
    gap: 4rem;
    max-width: 1600px;
    margin: 60px auto !important;
    padding: 40px !important;
    height: auto !important;

    /* Required for sticky - ensure all ancestors allow overflow */
    overflow: visible !important;
}

/* Ensure common Joomla/Gantry containers don't clip the sticky behavior */
#g-main,
#g-mainbar,
#g-page-surround {
    overflow: visible !important;
}

/* 2. Text Column (60% width) */
.story-profile .split-col.split-text {
    flex: 0 0 60% !important;
    width: 60% !important;
    height: auto !important;
    padding: 0 !important;
    /* Center text vertically relative to the image in short sections */
    align-self: center !important;
}

/* 3. Media Column - Sticky Logic */
.story-profile .split-col.split-media {
    flex: 0 0 30% !important;
    max-width: 380px;
    margin: 0;
    padding: 0 !important;

    /* Sticky behavior */
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 120px;
    /* Increased to clear sticky headers */
    z-index: 10;

    /* Visual Constraints */
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
    height: auto !important;
    align-self: flex-start !important;
}

/* Ensure image fills the sticky frame */
.story-profile .split-col.split-media img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

/* 4. Layout Detection & Direction */
/* Handles 'split-reversed' or manual placement using :has() */
.story-profile.split-reversed {
    flex-direction: row-reverse !important;
}

.story-profile:has(.split-media:first-child) {
    flex-direction: row-reverse !important;
}


.story-profile:has(.split-media:last-child) {
    flex-direction: row !important;
}


/* 5. Typography Polish */
.story-profile .split-heading {
    font-size: 2.2rem !important;
    margin-bottom: 24px !important;
    height: auto !important;
    color: #1a3c82;
}

.story-profile .split-body p,
.story-profile .split-body ul {
    line-height: 1.8 !important;
    margin-bottom: 1.2rem;
    height: auto !important;
}

/* 6. Responsive: Disable sticky on mobile for better flow */
@media (max-width: 900px) {

    .story-profile,
    .story-profile.split-reversed,
    .story-profile.split-container,
    .story-profile.split-container.split-reversed {
        flex-direction: column-reverse !important;
        padding: 20px !important;
        gap: 2rem;
    }

    .story-profile:has(.split-media:last-child) {
        justify-content: center;
    }

    .story-profile:has(.split-media:first-child) {
        flex-direction: column-reverse !important;
        padding: 20px !important;
        gap: 2rem;
    }

    .story-profile .split-col.split-text,
    .story-profile .split-col.split-media {
        flex: 0 0 100% !important;
        width: 100% !important;
        position: static !important;
        /* Disable sticky on small screens */
    }

    .split-container.accent-cream.story-profile {
        flex-direction: column-reverse !important;
    }
}

/* --- .j-swiper Horizontal Scroll Styles --- */

.j-swiper .g-content-array {
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    align-items: flex-start !important;
    overflow-x: auto !important;
    padding-bottom: 1.5rem !important;
    scrollbar-width: thin;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;

    /* Full-bleed breakout aligned with container edge */
    width: 100% !important;
    box-sizing: content-box !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    padding-left: calc(50vw - 50%) !important;
    padding-right: calc(50vw - 50%) !important;
    scroll-padding-left: calc(50vw - 50%) !important;
    scroll-padding-right: calc(50vw - 50%) !important;
}

.j-swiper .g-content-array:active {
    cursor: grabbing;
}

.j-swiper .g-content-array::-webkit-scrollbar {
    height: 8px;
}

.j-swiper .g-content-array::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}

.j-swiper .g-content-array::-webkit-scrollbar-thumb {
    background: rgba(26, 60, 130, 0.4);
    border-radius: 4px;
}

.j-swiper .g-content-array::-webkit-scrollbar-thumb:hover {
    background: rgba(26, 60, 130, 0.8);
}

.j-swiper .g-grid {
    flex: 0 0 calc(33.333% - 21.44px) !important;
    max-width: calc(33.333% - 21.44px) !important;
    scroll-snap-align: start;
}

.j-swiper .g-array-item-image {
    overflow: hidden !important;
    display: block;
}

.j-swiper .g-array-item-image img {
    transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1), opacity 0.5s ease !important;
}

.j-swiper .g-array-item-image a:hover img {
    transform: scale(1.05) !important;
    opacity: 0.9 !important;
}

.j-swiper .g-item-title a {
    transition: color 0.3s ease;
}

.j-swiper .g-item-title a:hover {
    color: rgb(198, 147, 56) !important;
}

@media (max-width: 50.99rem) {
    .j-swiper .g-grid {
        flex: 0 0 calc(85% - 16px) !important;
        max-width: calc(85% - 16px) !important;
        scroll-snap-align: center;
    }

    .j-swiper .g-content-array {
        scroll-padding: 0 7.5% !important;
        scroll-snap-type: x mandatory !important;
    }

    .site-sub:has(.j-swiper) .g-content-array .g-grid:not(:first-child) .g-content {
        padding-top: 0 !important;
    }
}

.site-sub.outline-13.withmaxwidth.site #g-mainbar>div>div>div.g-content {
    padding: 0 !important;
}

/* Hyper-specificity fix to remove right padding ONLY when there is no sidebar (#g-aside) */
@media only screen and (min-width: 50.99rem) {
    body.site-sub #g-page-surround #g-container-main:not(:has(#g-aside)) #g-mainbar#g-mainbar .g-grid .g-block .g-content {
        padding-right: 0 !important;
        padding-inline-end: 0 !important;
    }
}

/* Pagination Fix: Prevent next and previous buttons from overflowing on mobile */
@media (max-width: 50.99rem) {
    .site-home .g-content-array-pagination {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        height: auto !important;
        block-size: auto !important;
        gap: 15px !important;
        width: 100% !important;
    }

    .site-home .pagination-button {
        float: none !important;
        flex: 1 !important;
        min-width: 0 !important;
        font-size: 16px !important;
        padding: 10px 12px !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        text-align: center !important;
        margin: 0 !important;
    }

    .site-home .g-content-array-pagination .clearfix {
        display: none !important;
    }
}

/*  */

.pwa-logo img {
    background: white;
    width: 75%;
    margin: auto;
    border-radius: 1rem;
    padding: 1rem;
    display: grid;
}

@media only screen and (max-width: 50.99rem) {
    @media (display-mode: standalone) {
        .site #g-top {
            margin-top: 85pt !important;
        }

        #g-top-nav {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            width: 100%;
            height: 85pt !important;
            background: rgba(var(--primary-color-rgb));
            z-index: 1000;
            box-shadow: var(--default-box-shadow);
        }
    }
}