/*
Theme Name: Agency 15 Custom Theme
Author: Agency 15
Author URI: https://agency15.com/
Description: Custom theme developed by Agency 15 - The agency you love to work with.
Version: 1.0
Requires at least: 5.2
Requires PHP: 8.4
License: GNU General Public License v3 or Later
License URI: https://www.gnu.org/licenses/gpl.html
Text Domain: agency15
*/

/* ── Brand Colors & Layout Variables ── */
:root {
    --color-navy:           #13294B;
    --color-gold:           #AF6D04;
    --color-gold-light:     #D8AF5B;
    --color-blue:           #738CBD;
    --color-white:          #FFFFFF;
    --color-tan:            #F5F0E8;
    --border-radius:        8px;
    --container-max-width:  1200px;
    --section-pad-y:        2.5rem;
    --section-pad-x:        2rem;
    --network-bar-height:   44px;
}

/* ── Content section spacing toggles ──
   Each flexible-content section is wrapped in .cs-wrap by the loop. Editors can
   collapse the top/bottom space per block (e.g. when stacking on a matching
   background) via the "Remove top/bottom spacing" toggles. */
.cs-wrap--no-top > .content-section    { padding-top: 0; }
.cs-wrap--no-bottom > .content-section { padding-bottom: 0; }

/* ── Utility: Navy accent border frame ── */
.navy-frame {
    border-radius: 25px;
    border-right: 15px solid var(--color-navy);
    border-bottom: 15px solid var(--color-navy);
}

/* ── Base Reset ── */
body, html {
    overflow-x: hidden;
    margin: 0;
    scroll-behavior: smooth;
}

/* ── Global Typography & Background ── */
body {
    font-family: 'Work Sans', sans-serif;
    background-color: var(--color-tan);
    background-image: url('assets/images/Background-Graphic-Gold.svg');
    background-repeat: no-repeat;
    background-position: center top;
    background-size: cover;
    background-attachment: fixed;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Domine', serif;
}

/* ── Search: nav form (mobile only) ── */
#nav-search {
    display: block;
}

#search-modal {
    display: none; /* overridden below when not [hidden] */
}

#search-toggle {
    appearance: none;
    background: none;
    border: none;
}


/* ── Search: modal (desktop only) ── */
@media (min-width: 768px) {
    #nav-search {
        display: none;
    }

    #search-modal {
        display: flex;
        position: fixed;
        inset: 0;
        z-index: 9999;
        align-items: center;
        justify-content: center;
        background: rgba(0, 0, 0, 0.5);
    }

    #search-modal[hidden] {
        display: none;
    }

    #search-modal-inner {
        position: relative;
        background: var(--color-navy);
        padding: 3rem;
        width: min(620px, 90vw);
        border-radius: 25px;
        font-family: 'Work Sans', sans-serif;
    }

    #search-modal-close {
        position: absolute;
        top: 1rem;
        right: 1.25rem;
        background: none;
        border: none;
        font-size: 1.75rem;
        line-height: 1;
        cursor: pointer;
        color: rgba(255, 255, 255, 0.6);
        transition: color 0.2s ease;
    }

    #search-modal-close:hover {
        color: var(--color-white);
    }

    .search-form {
        display: flex;
        gap: 0.75rem;
        align-items: center;
    }

    .search-field {
        flex: 1;
        font-family: 'Work Sans', sans-serif;
        font-size: 1rem;
        padding: 0.85rem 1.5rem;
        border-radius: 50px;
        border: none;
        background: rgba(255, 255, 255, 0.12);
        color: var(--color-white);
        outline: none;
        transition: background 0.2s ease;
    }

    .search-field::placeholder {
        color: rgba(255, 255, 255, 0.45);
    }

    .search-field:focus {
        background: rgba(255, 255, 255, 0.2);
    }

    .search-submit {
        flex-shrink: 0;
        font-family: 'Work Sans', sans-serif;
    }
}

.custom-logo-link {
    padding: 0;
    max-width: 185px;

    img {
        max-width: 100%;
        height: auto;
    }
}

@media (max-width: 1023px) {
    .custom-logo-link {
        max-width: 120px;
        padding: 5px;
        box-sizing: border-box;
    }
}

.mobile-menu-toggle {
    appearance: none;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
}

#header {
    box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.15);
    position: fixed;
    background-color: #fff;
    z-index: 5;
    width: 100%;
    top: var(--network-bar-height);
    left: 0px;
    height: 112px;
}

#container {
    margin-top: calc(112px + var(--network-bar-height));
}

.admin-bar {
    #header {
        top: calc(32px + var(--network-bar-height));
    }
}

@media (max-width: 1023px) {
    #header {
        height: 63px;
    }

    #container {
        margin-top: calc(63px + var(--network-bar-height));
    }

    #header .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0 20px;
    }
}

@media (min-width: 1024px) {
    .sub-menu {
        display: none;
    }

    #header {
        display: flex;

        .container {
            width: 100%;
            max-width: 1200px;
            margin: 0 auto;
            padding: 0px 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        nav {
            display: flex;
            align-items: center;
            justify-content: space-between;
            height: 100%;

            .menu-main-menu-container {
                height: 100%;
            }

            ul#menu-main-menu {
                display: flex;
                list-style-type: none;
                height: 100%;

                li.menu-item {
                    height: 100%;

                    > a {
                        height: 100%;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        box-sizing: border-box;
                    }
                }
            }
        }
    }

    .menu-item-has-children {
        position: relative;
    }

    .menu-item-has-children > .sub-menu {
        list-style-type: none;
        z-index: 3;
        display: none;
        position: absolute;
        left: -50px;
        width: 160px;
        background: var(--color-navy);
        color: var(--color-white);
        text-align: center;
        text-decoration: none;
        padding: 15px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);

        a {
            display: block;
            color: var(--color-white);
            text-align: center;
            text-decoration: none;
            padding: 10px 0px;
        }
    }

    .menu-item-has-children:hover > .sub-menu {
        display: block;
    }
}

/* ── HubSpot form font override ── */
.hs-form-html * {
    font-family: 'Work Sans', sans-serif !important;
}

/* ── Mobile: reduce horizontal padding/margin from 2rem → 1rem ── */
@media (max-width: 767px) {

    /* Content sections */
    .pts,
    .exp-sections,
    .card-selector,
    .latest-posts,
    .job-listings,
    .map-embed,
    .make-payment-header,
    .triple-content,
    .account-center,
    .btn-list,
    .content-block,
    .form-content,
    .hero-banner__inner,
    .hero-banner__panel-outer,
    .intro-banner,

    /* Insights / archive pages */
    .insights-header,
    .insights-featured-wrap,
    .insights-body,
    .events-intro-wrap,

    /* Careers */
    .careers-jobs,

    /* Single industry */
    .ind-services,
    .ind-child-panel,
    .ind-opt-content,
    .ind-insights,

    /* Single event */
    .evt-content,
    .evt-panelists,
    .evt-panelists__header,
    .evt-registration,

    /* Single news */
    .news-hero-wrap,
    .news-hero,

    /* Single service */
    .svc-hero__content,
    .svc-content-wrap,
    .svc-orgs,
    .svc-insight,
    .svc-leaders,

    /* Single post */
    .ins-hero-wrap,
    .ins-content-wrap,
    .ins-bio,

    /* Single job */
    .job-page,

    /* Single staff */
    .staff-hero,
    .staff-content-section,
    .staff-related,

    /* Search / 404 */
    .search-results-page,
    .search-results__empty,
    .not-found-page,

    /* Footer */
    #footer {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    /* Industry sub-section uses margin instead of padding */
    .ind-sub {
        margin-left: 1rem !important;
        margin-right: 1rem !important;
    }

    /* Fixed background via ::before (background-attachment: fixed broken on iOS) */
    body {
        background-image: none;
    }

    body::before {
        content: '';
        position: fixed;
        inset: 0;
        background-color: var(--color-tan);
        background-image: url('assets/images/Background-Graphic-Gold.svg');
        background-repeat: no-repeat;
        background-position: center top;
        background-size: cover;
        z-index: -1;
        pointer-events: none;
    }
}