/* ==========================================================================
   Site footer (includes/footer.php), charcoal background (master spec 3/4.3)
   ========================================================================== */

.site-footer {
    background: var(--ph-dark);
    color: #d9d6d6;
    font-size: .95rem;
    padding: 64px 0 calc(28px + env(safe-area-inset-bottom));
}

.site-footer a {
    color: var(--ph-white);
    text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus-visible { color: var(--ph-white); text-decoration: underline; }

.site-footer :focus-visible { outline-color: var(--ph-white); }

.site-footer__top {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.25rem;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid var(--ph-dark-border);
}

.site-footer__brand img {
    width: 84px;
    height: 84px;
}

.site-footer__brandline {
    max-width: 34ch;
    margin: 1rem 0 0;
    line-height: 1.6;
}

.site-footer__label {
    display: block;
    margin: 0 0 .75rem;
    font-family: var(--ph-font-heading);
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ph-white);
}

/* Regional Headquarters (accordion on phones) */
.site-footer__hq summary {
    list-style: none;
    cursor: default;
}

.site-footer__hq summary::-webkit-details-marker { display: none; }

.site-footer__offices {
    display: grid;
    gap: 1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer__offices strong {
    display: block;
    margin-bottom: .15rem;
    font-weight: 600;
    color: var(--ph-white);
}

.site-footer__offices address {
    margin: 0;
    font-size: .88rem;
    line-height: 1.55;
}

.site-footer__contact {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin: 0 0 1.75rem;
}

.site-footer__links {
    display: grid;
    gap: .15rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.site-footer__links a,
.site-footer__cookie-settings {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
}

.site-footer__cookie-settings {
    padding: 0;
    border: 0;
    background: none;
    color: var(--ph-white);
    font: inherit;
    cursor: pointer;
}

.site-footer__cookie-settings:hover { text-decoration: underline; }

.social-list {
    display: flex;
    gap: .6rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.social-list a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: var(--ph-radius);
    background: var(--ph-dark-2);
    color: var(--ph-white);
    font-size: 1.05rem;
    transition: background-color .2s ease;
}

.social-list a:hover,
.social-list a:focus-visible {
    background: var(--ph-red-strong);
    text-decoration: none;
}

.site-footer__bottom { padding-top: 1.5rem; }

.site-footer__disclaimer {
    max-width: 90ch;
    margin: 0 0 1rem;
    font-size: .8rem;
    line-height: 1.6;
    color: #d9d6d6;
}

.site-footer__legal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.site-footer__copyright {
    margin: 0;
    font-size: .82rem;
    color: #d9d6d6;
}

.back-to-top {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    min-height: 44px;
    padding: .5rem 1rem;
    border-radius: 4px;
    background: var(--ph-dark-2);
    font-family: var(--ph-font-heading);
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.site-footer .back-to-top:hover { background: var(--ph-red-strong); text-decoration: none; }

@media (min-width: 768px) {
    .site-footer__top {
        grid-template-columns: 1fr 1fr;
        column-gap: 3rem;
    }
}

@media (min-width: 768px) and (max-width: 1199.98px) {
    .site-footer__offices { grid-template-columns: 1fr 1fr; column-gap: 1.5rem; }
}

@media (min-width: 1200px) {
    .site-footer__top {
        grid-template-columns: 1.1fr 2fr 1fr auto;
        align-items: start;
    }

    .site-footer__offices { grid-template-columns: 1fr 1fr; column-gap: 2rem; }
}

/* Phones: Regional Headquarters becomes a tap-to-open accordion */
@media (max-width: 767.98px) {
    .site-footer__hq {
        border-block: 1px solid var(--ph-dark-border);
        padding-block: .25rem;
    }

    .site-footer__hq summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        min-height: 44px;
        margin: 0;
        cursor: pointer;
    }

    .site-footer__hq summary::after {
        content: "+";
        font-size: 1.25rem;
        line-height: 1;
    }

    .site-footer__hq[open] summary::after { content: "\2212"; }

    .site-footer__hq[open] .site-footer__offices { padding-bottom: 1rem; }
}
