/* ── Footer — base ──────────────────────────────────────────────────
   Global footer rules (split out of header-styles.css 2026-06-21 — never
   a header concern). ──────────────────────────────────────────────── */
footer.wp-block-template-part {
    margin-top: 0;
}

/* a11y: enlarge footer text-link tap targets + vertical spacing (Lighthouse "touch targets").
   The policy/contact links are small-font links in tightly-stacked <p>s. */
footer.wp-block-template-part p a {
    display: inline-block;
    padding-block: 6px;
}

/* ── Footer — mobile reflow ─────────────────────────────────────────
   Desktop layout (4 columns: Logo, Contact, Information, Follow Ace) is left
   untouched. Below 781px switch the Columns block to a 2x2 CSS grid:
       row 1 │ Contact (left) │ Information (right)
       row 2 │ Logo    (left) │ Follow Ace + icons (right-aligned)
   Selector uses `footer .wp-block-columns.are-vertically-aligned-top` so it
   doesn't depend on a custom class (the Site Editor wipes manual classNames
   when an adjacent template part is saved). Was the last live rule in the
   retired card-styles.css; split into its own file 2026-06-21. ──────────── */
@media (max-width: 781px) {
    footer .wp-block-columns.are-vertically-aligned-top {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "contact info"
            "logo    follow";
        gap: var(--wp--preset--spacing--30);
        align-items: center;
    }
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column {
        flex-basis: auto !important;
        width: 100% !important;
    }
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(1) { grid-area: logo;    }
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(2) { grid-area: contact; }
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(3) { grid-area: info;    }
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(4) {
        grid-area: follow;
        text-align: left;
    }
    /* Logo image left-aligned within its half-width cell */
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(1) .wp-block-image {
        margin-left: 0 !important;
        margin-right: auto !important;
    }
    /* Follow heading left-aligned (lines up with INFORMATION column above) */
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(4) .wp-block-heading {
        text-align: left !important;
    }
    /* Social icons left-aligned */
    footer .wp-block-columns.are-vertically-aligned-top > .wp-block-column:nth-child(4) .wp-block-social-links {
        justify-content: flex-start !important;
    }
}
