﻿/**
 * Common header + footer styles for AFC Theme.
 * Loaded on every page (see functions.php).
 */

:root {
    --afc-sans: "Roboto", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    --afc-ink: #102a43;
    --afc-navy: #0b1f33;
    --afc-navy-2: #0e2740;
    --afc-red: #c0392b;
    --afc-red-2: #a5281b;
    --afc-teal: #0f766e;
    --afc-gold: #f4b942;
    --afc-cloud: #f4f8fb;
    --afc-line: rgba(255, 255, 255, .12);
    --afc-muted: #3f3f3f;
}

/* ---------- Layout ---------- */

.container,
.container-sm,
.container-md,
.container-lg,
.container-xl,
.container-xxl {
    /* mobile + tablet */
    width: 88%;
    max-width: 88%;
}

/* ---------- Header ---------- */

.site-header {
    position: relative;
    z-index: 20;
    background: #fff;
    box-shadow: 0 2px 14px rgba(11, 31, 51, .08);
}

.site-header__bar .navbar {
    padding-block: .5rem;
}

.site-header__logo {
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    font-family: var(--afc-sans);
    font-weight: 900;
    color: var(--afc-navy);
}
/* header img.custom-logo {
    width: 280px;
    height: auto;
} */

.site-header__logo img,
.site-header__logo .custom-logo {
    max-height: 54px;
    max-width: 100%;
    width: auto;
    height: auto;
}

div#primary-menu {
    justify-content: flex-end;
}

.brand-mark {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 50%;
    color: var(--afc-navy);
    background: var(--afc-gold);
    font-family: var(--afc-sans);
    font-size: 1.2rem;
    font-weight: 900;
}

.site-header__menu {
    gap: .25rem;
}

.site-header__menu .nav-link,
.site-header__menu a {
    display: block;
    padding: .5rem .9rem;
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--afc-navy);
    text-decoration: none;
}

.site-header__menu a:hover,
.site-header__menu .nav-link:hover,
.site-header__menu .current-menu-item>a,
.site-header__menu .current-menu-ancestor>a,
.site-header__menu .current_page_item>a,
.site-header__menu .nav-link.active {
    color: var(--afc-red);
}

.site-header__quote {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.btn-quote,
.site-header__quote .btn {
    padding: .7rem 1.4rem;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    border-radius: 2px;
    background: var(--afc-red);
    border-color: var(--afc-red);
    color: #fff;
}

.btn-quote:hover,
.site-header__quote .btn:hover {
    background: var(--afc-red-2);
    border-color: var(--afc-red-2);
    color: #fff;
}

.navbar-toggler {
    border-color: rgba(11, 31, 51, .2);
}

/* Header sub-menu bar */

.site-header__sub {
    background: #f6f6f6;
    border-top: 1px solid rgb(202 202 202 / 12%);
}

.site-subnav__menu {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    justify-content: flex-end;
}

.site-subnav__menu li {
    margin: 0;
}

.site-subnav__menu a {
    display: block;
    padding: 0 1.15rem;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #9d9ea0;
    text-decoration: none;
    border-bottom: 3px solid transparent;
}

.site-subnav__menu a:hover,
.site-subnav__menu .current-menu-item>a {
    color: var(--afc-red);
}

/* ---------- Footer ---------- */

.site-footer {
    color: #d9e2ec;
    background: var(--afc-navy);
    padding: 20px 0;
}

.site-footer a {
    color: #fff;
    text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus {
    color: #d94a37;
}

.site-footer__main {
    align-items: center;
}

.site-footer__logo img,
.site-footer__logo .custom-logo {
    max-height: 80px;
    width: auto;
}

/* Middle: footer navigation menu */
.site-footer__nav {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.site-footer__menu-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .5rem 1.75rem;
    padding: 0;
    margin: 0;
    list-style: none;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.site-footer__menu-list a {
    display: inline-block;
    padding: .15rem 0;
}

/* Right: footer widget area */
.site-footer__right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: .5rem;
    font-size: .8rem;
    text-align: right;
}

.site-footer__right .widget {
    margin-bottom: 0;
}

.site-footer__right img {
    max-height: 64px;
    width: auto;
}

.site-footer__copyright {
    margin-top: 10px;
    padding-top: 1.25rem;
    border-top: 1px solid var(--afc-line);
    text-align: center;
    color: #9fb3c8;
    font-size: .8rem;
}

.site-footer .widget {
    margin-bottom: 1rem;
}

.site-footer .widget-title {
    color: var(--afc-gold);
    font-size: .8rem;
    letter-spacing: .1em;
    text-transform: uppercase;
}

section#block-8 {
    display: block;
}

section#block-8 .footerimgTxt {
    display: flex;
    align-content: center;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
}

section#block-8 .footerimgTxt p {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    text-align: left;
    margin: 0;
}

/* ---------- Shared utilities ---------- */

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.screen-reader-text:focus {
    position: fixed;
    top: 10px;
    left: 10px;
    z-index: 100000;
    width: auto;
    height: auto;
    padding: .5rem 1rem;
    clip: auto;
    background: #fff;
    color: var(--afc-navy);
}


/* ---------- "Request a Quote" popup ---------- */

.afc-quote-popup .modal-content {
    border: 0;
    border-radius: 4px;
    border-top: 4px solid var(--afc-red);
	background: #122335d6;
}

.afc-quote-popup .modal-header {
    align-items: flex-start;
    border-bottom: 0;
    padding-bottom: 0;
}

.afc-quote-popup .modal-title {
    color: #fff;
    font-weight: 400;
    text-align: center;
}
.afc-quote-popup button.btn-close {
    background-color: #fff;
    opacity: 1;
}
.afc-quote-popup .modal-body form {
    margin: 0;
}


@media (max-width: 991.98px) {
    .site-header__logo img,
    .site-header__logo .custom-logo {
        max-height: 44px;
    }

    .site-header__collapse {
        padding-top: .75rem;
    }

    .site-header__quote {
        margin-top: .5rem;
    }

    .site-footer__nav,
    .site-footer__right {
        justify-content: flex-start;
        align-items: flex-start;
        text-align: left;
    }

    .site-footer__menu-list {
        justify-content: flex-start;
    }

    .container,
    .container-sm,
    .container-md,
    .container-lg,
    .container-xl,
    .container-xxl {
        width: 88%;
        max-width: 88%;
    }
}

@media (max-width: 480px) {
    .site-header__logo img,
    .site-header__logo .custom-logo {
        max-height: 34px;
    }
}
/* WPForms: message textarea shows 3 lines (field CSS class "afc-message-3-rows") */
.wpforms-container .afc-message-3-rows textarea {
    height: calc(3 * 1.5em + 1.5rem);
    min-height: 0;
    line-height: 1.5;
    resize: vertical;
}

/* Mobile + tablet: containers span the full width (padding keeps the gutters) */
@media (max-width: 991.98px) {
    .container,
    .container-sm,
    .container-md,
    .container-lg,
    .container-xl,
    .container-xxl {
        width: 100%;
        max-width: 100%;
    }
}

/* Header sub-menu bar: dropdown on tablet + mobile */
.site-subnav__toggle {
    display: none;
}

@media (max-width: 991.98px) {
    .site-header__sub {
        position: relative;
    }

    .site-subnav__toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: .8rem 0;
        background: none;
        border: 0;
        font-size: .75rem;
        font-weight: 700;
        letter-spacing: .1em;
        text-transform: uppercase;
        color: var(--afc-navy);
    }

    .site-subnav__toggle-icon {
        width: .55rem;
        height: .55rem;
        border-right: 2px solid var(--afc-red);
        border-bottom: 2px solid var(--afc-red);
        transform: rotate(45deg);
        transition: transform .2s;
    }

    .site-header__sub.is-open .site-subnav__toggle-icon {
        transform: rotate(-135deg);
    }

    .site-subnav__panel {
        display: none;
        border-top: 1px solid rgba(0, 0, 0, .08);
    }

    .site-header__sub.is-open .site-subnav__panel {
        display: block;
    }

    .site-header__sub .site-subnav__menu {
        flex-direction: column;
        flex-wrap: nowrap;
        justify-content: flex-start;
    }

    .site-header__sub .site-subnav__menu a {
        padding: .75rem 0;
        font-size: .72rem;
        border-bottom: 1px solid rgba(0, 0, 0, .06);
    }
}

/* ---------- Footer responsive ---------- */

/* Laptop: tighter spacing so the three columns fit */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .site-footer__menu-list {
        gap: .4rem 1.1rem;
        font-size: .74rem;
    }

    .site-footer .site-subnav__menu {
        justify-content: center;
    }

    .site-footer .site-subnav__menu a {
        padding: .6rem .7rem;
        letter-spacing: .08em;
    }
}

/* Tablet + mobile: stacked, centred */
@media (max-width: 991.98px) {
    .site-footer {
        padding: 2rem 0 1.25rem;
    }

    .site-footer__main {
        text-align: center;
        row-gap: 1.5rem;
    }

    .site-footer__logo,
    .site-footer__nav,
    .site-footer__right {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
    }

    .site-footer__logo img,
    .site-footer__logo .custom-logo {
        max-height: 64px;
        max-width: 100%;
    }

    .site-footer__menu-list {
        justify-content: center;
        gap: .4rem 1.25rem;
    }

    .site-footer .site-subnav__menu {
        justify-content: center;
    }

    .site-footer .site-subnav__menu a {
        padding: .6rem .8rem;
    }

    .site-footer__right img {
        max-width: 100%;
    }

    section#block-8 .footerimgTxt {
        justify-content: center;
        flex-wrap: wrap;
    }

    .site-footer__copyright {
        margin-top: 1rem;
    }
}

/* Mobile */
@media (max-width: 575.98px) {
    .site-footer__menu-list {
        flex-direction: column;
        gap: .25rem;
        font-size: .78rem;
    }

    .site-footer__menu-list a {
        padding: .4rem 0;
    }

    .site-footer .site-subnav__menu {
        flex-direction: column;
        align-items: center;
    }

    .site-footer .site-subnav__menu a {
        padding: .45rem 0;
        border-bottom: 0;
    }

    .site-footer__copyright {
        font-size: .75rem;
    }
}

/* Footer: two menus side by side, tighter spacing (tablet + mobile) */
@media (max-width: 991.98px) {
    .site-footer {
        padding: 1.25rem 0 .75rem;
    }

    .site-footer__main {
        row-gap: .75rem;
    }

    .site-footer__nav {
        flex-direction: row;
        align-items: flex-start;
        justify-content: center;
        gap: 1rem;
    }

    .site-footer__nav>nav {
        flex: 1 1 0;
        min-width: 0;
    }

    .site-footer__menu-list,
    .site-footer .site-subnav__menu {
        flex-direction: column;
        align-items: center;
        gap: 0;
        margin: 0;
    }

    .site-footer__menu-list a,
    .site-footer .site-subnav__menu a {
        padding: .3rem 0;
        border-bottom: 0;
        line-height: 1.3;
    }

    .site-footer__copyright {
        margin-top: .5rem;
        padding-top: .75rem;
    }
}

@media (max-width: 575.98px) {
    .site-footer__menu-list,
    .site-footer .site-subnav__menu {
        gap: 0;
    }

    .site-footer__menu-list a,
    .site-footer .site-subnav__menu a {
        padding: .25rem 0;
        font-size: .72rem;
    }
}

/* Footer: menu items listed inline (side by side), wrapping when needed */
@media (max-width: 991.98px) {
    .site-footer__nav {
        flex-direction: column;
        align-items: stretch;
        gap: .25rem;
    }

    .site-footer__nav>nav {
        flex: none;
        width: 100%;
    }

    .site-footer__menu-list,
    .site-footer .site-subnav__menu {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-items: center;
        gap: 0 1rem;
    }

    .site-footer__menu-list a,
    .site-footer .site-subnav__menu a {
        display: inline-block;
        padding: .25rem 0;
        font-size: .72rem;
        white-space: nowrap;
    }

    .site-footer .site-subnav__menu li {
        margin: 0;
    }
}
