/* LOCKED GLOBAL CHROME — see CHROME-LOCK.md. Liquid chrome: flowing, shining palette fill for the global header and footer.
   Palette: Smoke Whisper #ECE7D5, Weathered Steel #837D75, Duststone Clay #806055,
   Cinder Red #A33633, Obsidian Veil #30292A. Colours are pinned (not theme vars)
   so dark mode does not invert them. */
:root {
    --lq-smoke: #ECE7D5;
    --lq-steel: #837D75;
    --lq-clay: #806055;
    --lq-cinder: #A33633;
    --lq-obsidian: #30292A;
}

/* Light liquid for the header (dark text stays readable). */
.sb-header.sb-global-header {
    background-color: var(--lq-smoke);
    background-image:
        linear-gradient(115deg, transparent 38%, rgba(255, 255, 255, .55) 47%, rgba(255, 255, 255, .1) 53%, transparent 62%),
        radial-gradient(60% 140% at 15% 50%, rgba(163, 54, 51, .28), transparent 60%),
        radial-gradient(50% 160% at 85% 40%, rgba(128, 96, 85, .32), transparent 62%),
        linear-gradient(100deg, #ECE7D5 0%, #d9d1c1 18%, #ECE7D5 34%, #cbc3b6 52%, #ECE7D5 68%, #e0cfc6 84%, #ECE7D5 100%);
    background-size: 250% 100%, 220% 100%, 220% 100%, 300% 100%;
    background-repeat: no-repeat, no-repeat, no-repeat, repeat-x;
    animation: sbLiquidFlow 16s ease-in-out infinite alternate;
    border-bottom-color: rgba(48, 41, 42, .18);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

/* Dark liquid for the footer, and for the header in dark mode. */
.sb-footer.sb-global-footer,
[data-theme="dark"] .sb-header.sb-global-header {
    background-color: var(--lq-obsidian);
    background-image:
        linear-gradient(115deg, transparent 40%, rgba(236, 231, 213, .16) 48%, rgba(236, 231, 213, .03) 53%, transparent 60%),
        radial-gradient(45% 70% at 20% 30%, rgba(163, 54, 51, .55), transparent 65%),
        radial-gradient(40% 80% at 80% 70%, rgba(128, 96, 85, .5), transparent 65%),
        radial-gradient(35% 60% at 55% 15%, rgba(131, 125, 117, .35), transparent 70%),
        linear-gradient(100deg, #30292A 0%, #3d3233 22%, #30292A 40%, #4a2c2c 60%, #30292A 78%, #3a3434 100%);
    background-size: 250% 100%, 200% 200%, 200% 200%, 200% 200%, 300% 100%;
    background-repeat: no-repeat, no-repeat, no-repeat, no-repeat, repeat-x;
    animation: sbLiquidFlowDark 18s ease-in-out infinite alternate;
    border-bottom-color: rgba(236, 231, 213, .12);
}

.sb-footer.sb-global-footer {
    color: #cfc8b8;
}

@keyframes sbLiquidFlow {
    0% {
        background-position: 160% 0, 0% 50%, 100% 50%, 0% 50%;
    }

    50% {
        background-position: 50% 0, 60% 50%, 30% 50%, 50% 50%;
    }

    100% {
        background-position: -60% 0, 100% 50%, 0% 50%, 100% 50%;
    }
}

@keyframes sbLiquidFlowDark {
    0% {
        background-position: 160% 0, 0% 0%, 100% 100%, 50% 0%, 0% 50%;
    }

    50% {
        background-position: 50% 0, 70% 60%, 20% 40%, 10% 80%, 50% 50%;
    }

    100% {
        background-position: -60% 0, 100% 100%, 0% 0%, 90% 30%, 100% 50%;
    }
}

@media (prefers-reduced-motion: reduce) {

    .sb-header.sb-global-header,
    .sb-footer.sb-global-footer {
        animation: none;
    }
}

/* ==========================================================================
   LOCKED GLOBAL FOOTER LAYOUT — see CHROME-LOCK.md before editing.
   Single source of truth for footer layout on desktop, tablet and mobile.
   ========================================================================== */
.sb-footer.sb-global-footer {
    padding: 64px 0 0 !important;
    text-align: left;
}

.sb-global-footer .sb-footer-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 48px !important;
    align-items: start;
    text-align: left !important;
}

.sb-global-footer .sb-footer-grid {
    border-bottom: 0 !important;
    padding-bottom: 0 !important;
}

.sb-global-footer .sb-footer-grid>* {
    min-width: 0;
    text-align: left !important;
}

.sb-global-footer .sb-footer-logo {
    display: inline-block;
    margin: 0 0 16px;
}

.sb-global-footer .sb-footer-logo img {
    display: block;
    width: 100%;
    max-width: 260px;
    height: auto;
    border-radius: 10px;
}

.sb-global-footer .sb-footer-desc {
    color: #d9d2c2 !important;
    opacity: 1 !important;
    font-size: 15px;
    line-height: 1.7;
    margin: 0 0 14px;
    max-width: 380px;
}

.sb-global-footer .sb-footer-motto {
    color: #f0c96a !important;
    margin: 0 0 18px;
}

.sb-global-footer .sb-footer-social {
    display: flex !important;
    gap: 12px;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none;
    justify-content: flex-start !important;
}

.sb-global-footer .sb-footer-heading {
    color: #ECE7D5 !important;
    font-size: 14px;
    letter-spacing: .14em;
    text-transform: uppercase;
    margin: 0 0 18px !important;
    padding: 0 0 10px;
    border-bottom: 1px solid rgba(236, 231, 213, .16);
    text-align: left !important;
}

.sb-global-footer .sb-footer-links {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    display: grid;
    gap: 10px;
}

.sb-global-footer .sb-footer-links li {
    margin: 0 !important;
    padding: 0 !important;
    text-align: left !important;
}

.sb-global-footer .sb-footer-links a {
    color: #cfc8b8 !important;
    font-size: 15px;
    text-decoration: none;
    transition: color .2s, padding-left .2s;
}

.sb-global-footer .sb-footer-links a:hover {
    color: #ffffff !important;
    padding-left: 4px;
}

.sb-global-footer .sb-footer-email {
    display: block;
    margin: 22px 0 0 !important;
    color: #f0c96a !important;
    font-weight: 600;
    word-break: break-word;
    text-align: left !important;
}

.sb-global-footer .sb-footer-email--alt {
    margin-top: 8px !important;
    font-weight: 400;
}

.sb-global-footer .sb-footer-bottom {
    display: flex !important;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 8px 24px;
    margin: 48px 0 0 !important;
    padding: 20px 0 24px !important;
    border-top: 1px solid rgba(236, 231, 213, .16);
}

.sb-global-footer .sb-footer-bottom p {
    margin: 0 !important;
    color: #b9b1a1 !important;
    opacity: 1 !important;
    font-size: 13px;
}

/* Tablet: brand full width on top, two link columns below */
@media (max-width: 1024px) {
    .sb-global-footer .sb-footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px 32px !important;
    }

    .sb-global-footer .sb-footer-brand {
        grid-column: 1 / -1;
        max-width: none !important;
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 8px 32px;
        align-items: start;
    }

    .sb-global-footer .sb-footer-brand .sb-footer-logo {
        grid-row: span 3;
        margin: 0;
    }

    .sb-global-footer .sb-footer-logo img {
        max-width: 220px;
    }
}

/* Mobile: one clean centred column */
@media (max-width: 640px) {
    .sb-footer.sb-global-footer {
        padding-top: 44px !important;
    }

    .sb-global-footer .sb-footer-grid {
        grid-template-columns: 1fr;
        gap: 32px !important;
    }

    .sb-global-footer .sb-footer-grid>*,
    .sb-global-footer .sb-footer-heading,
    .sb-global-footer .sb-footer-links li,
    .sb-global-footer .sb-footer-email {
        text-align: center !important;
    }

    .sb-global-footer .sb-footer-brand {
        display: flex;
        flex-direction: column;
        align-items: center;
        max-width: none !important;
        width: 100%;
        margin: 0 auto;
        text-align: center !important;
    }

    .sb-global-footer .sb-footer-brand>* {
        margin-left: auto !important;
        margin-right: auto !important;
        text-align: center !important;
    }

    .sb-global-footer .sb-footer-logo {
        display: block;
        margin: 0 auto 14px;
        max-width: 220px;
    }

    .sb-global-footer .sb-footer-desc {
        margin-left: auto;
        margin-right: auto;
    }

    .sb-global-footer .sb-footer-social {
        justify-content: center !important;
        padding: 0 !important;
        width: 100%;
    }

    .sb-global-footer .sb-footer-links {
        grid-template-columns: 1fr 1fr;
        gap: 10px 16px;
    }

    .sb-global-footer .sb-footer-links a:hover {
        padding-left: 0;
    }

    .sb-global-footer .sb-footer-bottom {
        flex-direction: column;
        text-align: center;
        margin-top: 36px !important;
    }
}
/* Header menu: dark ink on the light liquid header */
html:not([data-theme="dark"]) .sb-global-header .sb-nav-link {
    color: var(--lq-obsidian, #30292A) !important;
    font-weight: 600;
}
html:not([data-theme="dark"]) .sb-global-header .sb-nav-link:hover,
html:not([data-theme="dark"]) .sb-global-header .sb-nav-link.active {
    color: var(--lq-cinder, #A33633) !important;
}

/* Connected Branches: all three names on one line */
.sb-global-footer .sb-footer-links.sb-footer-branches {
    display: flex !important;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0;
    white-space: nowrap;
}
.sb-global-footer .sb-footer-branches li + li::before {
    content: "·";
    margin: 0 7px;
    color: #f0c96a;
}
.sb-global-footer .sb-footer-branches li {
    display: inline-flex !important;
    align-items: center;
    width: auto !important;
}
.sb-global-footer .sb-footer-branches a {
    display: inline !important;
    padding: 0 !important;
    font-size: 12.5px !important;
}
.sb-global-footer .sb-footer-branches a:hover {
    padding-left: 0;
}

/* Bottom bar: copyright and place side by side at every width */
.sb-global-footer .sb-footer-bottom {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center !important;
    gap: 0 !important;
    text-align: center;
}
.sb-global-footer .sb-footer-bottom p + p::before {
    content: "·";
    margin: 0 10px;
    color: #f0c96a;
}
@media (max-width: 640px) {
    .sb-global-footer .sb-footer-links.sb-footer-branches {
        justify-content: center;
        grid-template-columns: none;
    }
    .sb-global-footer .sb-footer-branches a {
        font-size: 11.5px !important;
    }
    .sb-global-footer .sb-footer-bottom p {
        font-size: 11px !important;
        line-height: 1.5;
    }
    .sb-global-footer .sb-footer-bottom p + p::before {
        margin: 0 6px;
    }
}
