/* ==========================================================================
   Site footer

   Two bands: the quality marks strip on white, then the main footer over a
   statue photograph washed out by a near-opaque white overlay.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Quality marks
   -------------------------------------------------------------------------- */

.marks {
    padding: 60px 0 40px;
}

.marks__inner {
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: 15px;
}

.marks__title {
    margin-bottom: 30px;
    text-align: center;
}

/* Continuous marquee: the logo list is duplicated in the markup and the
   track scrolls exactly half its width, so the loop is seamless. */
.marks__viewport {
    overflow: hidden;
    padding-inline: 30px;
}

.marks__track {
    display: flex;
    width: max-content;
    animation: marks-scroll 45s linear infinite;
}

@keyframes marks-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

.marks__item {
    display: flex;
    flex: 0 0 260px;
    align-items: center;
    justify-content: center;
    height: 120px;
    padding-inline: 5px;
}

.marks__item img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* --------------------------------------------------------------------------
   Disclaimer
   -------------------------------------------------------------------------- */

.footer-disclaimer__inner {
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: 15px;
}

.footer-disclaimer p {
    margin-bottom: 25px;
    font-family: var(--font-body);
    font-size: 18px;
    line-height: 1.5;
    color: var(--color-text);
}

/* --------------------------------------------------------------------------
   Main footer
   -------------------------------------------------------------------------- */

.site-footer__main {
    position: relative;
    padding-top: 100px;
    background-color: var(--color-secondary);
    background-image: url("../images/general-images/footer-background.jpg");
    background-position: center center;
    background-size: cover;
}

.site-footer__main::before {
    content: "";
    position: absolute;
    inset: 0;
    background-color: rgba(255, 255, 255, 0.68);
    opacity: 0.97;
}

.site-footer__inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: 15px;
}

.footer-grid {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 70px;
}

/* --- Brand column --- */

.footer-brand {
    flex: 0 0 25%;
    text-align: center;
}

.footer-brand__logo img {
    width: 225px;
    max-width: 100%;
    margin-inline: auto;
}

.footer-brand__tagline {
    margin: 10px 0 20px;
    font-family: var(--font-body);
    font-size: 21px;
    font-weight: 700;
    line-height: 1.5;
    color: var(--color-maroon-mid);
}

.footer-social {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.footer-social .social-link {
    width: 18px;
    height: 18px;
    background-color: var(--color-maroon-mid);
}

.footer-social .social-link:hover,
.footer-social .social-link:focus-visible {
    background-color: var(--color-accent);
}

/* --- Link columns --- */

.footer-col {
    flex: 0 0 25%;
}

.footer-col--links {
    flex-basis: 30%;
}

.footer-col--badge {
    flex-basis: 20%;
}

.footer-col__title {
    margin-bottom: 15px;
    font-family: var(--font-card-title);
    font-size: 24px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--color-maroon-mid);
}

.footer-list li + li {
    margin-top: 10px;
}

.footer-list a,
.footer-list span {
    font-family: var(--font-card-title);
    font-size: 18px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--color-maroon-mid);
    transition: color 0.3s;
}

.footer-list a:hover,
.footer-list a:focus-visible {
    color: var(--color-accent);
}

/* --- SRA digital badge --- */

.sra-badge {
    max-width: 275px;
}

.sra-badge__frame {
    position: relative;
    height: 0;
    padding-bottom: 59.1%;
    overflow: hidden;
}

.sra-badge__frame iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* --- Regulatory strip --- */

.footer-legal {
    padding: 15px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.footer-legal p {
    font-family: var(--font-body);
    font-size: 14px;
    line-height: 1.6;
    color: var(--color-maroon-mid);
}

/* --------------------------------------------------------------------------
   Tablet
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {

    .marks {
        padding: 50px 30px 30px;
    }

    .marks__inner,
    .footer-disclaimer__inner,
    .site-footer__inner {
        padding-inline: 0;
    }

    .footer-disclaimer {
        padding: 70px 30px;
    }

    .footer-disclaimer p {
        font-size: 17px;
    }

    .marks__viewport {
        padding-inline: 0;
    }

    .marks__item {
        flex-basis: 210px;
        height: 100px;
    }

    .site-footer__main {
        padding: 70px 30px 0;
    }

    .footer-grid {
        margin-bottom: 70px;
    }

    /* Brand spans the full width above the columns, as on the existing site */
    .footer-brand {
        flex: 0 0 100%;
        margin-bottom: 50px;
    }

    .footer-col {
        flex-basis: 39%;
    }

    .footer-col--links {
        flex-basis: 39%;
    }

    .footer-col--badge {
        flex-basis: 22%;
    }

    .footer-list a,
    .footer-list span {
        font-size: 17px;
    }
}

/* --------------------------------------------------------------------------
   Mobile
   -------------------------------------------------------------------------- */

@media (max-width: 767px) {

    .marks {
        padding: 40px 20px 20px;
    }

    .marks__item {
        flex-basis: 220px;
        height: 110px;
    }

    .footer-disclaimer {
        padding: 20px;
    }

    .footer-disclaimer p {
        font-size: 16px;
    }

    .site-footer__main {
        padding: 70px 20px 0;
    }

    .footer-grid {
        gap: 40px;
        margin-bottom: 50px;
    }

    .footer-brand,
    .footer-col,
    .footer-col--links,
    .footer-col--badge {
        flex-basis: 100%;
        margin-bottom: 0;
    }

    .footer-legal {
        padding: 17px 0;
    }
}

/* --------------------------------------------------------------------------
   Reduced motion — stop the marquee and let the logos wrap
   -------------------------------------------------------------------------- */

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

    .marks__track {
        flex-wrap: wrap;
        justify-content: center;
        width: 100%;
        animation: none;
    }

    .marks__track [aria-hidden="true"] {
        display: none;
    }
}
