/* =========================================================
   FINARCH — site footer 
   ========================================================= */

.fa-footer { line-height: normal; }

.fa-footer, .fa-footer * { box-sizing: border-box; }

:where(.fa-footer) :is(p, h1, h2, h3, h4, h5, h6) { color: inherit; }

.fa-footer {
    background-color: var(--fa-ink, #111111);
    color: #ffffff;
    padding: clamp(56px, 9vh, 110px) var(--fa-gutter, clamp(20px, 4.5vw, 72px)) clamp(26px, 4vh, 44px);
}

.fa-footer__inner {
    max-width: var(--fa-shell, 1560px);
    margin: 0 auto;
}

.fa-footer__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
    gap: clamp(32px, 4vw, 72px);
}

.fa-footer__col {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.fa-footer__logo img {
    display: block;
    height: clamp(24px, 2.6vw, 34px);
    width: auto;
}

/* Body copy matches the column links in size and colour. */
.fa-footer__about {
    margin: 22px 0 0;
    font-size: 14px;
    line-height: 1.68;
    color: rgba(255, 255, 255, .72);
    max-width: 36ch;
    text-wrap: pretty;
}

.fa-footer__about p {
    margin: 0;
    font: inherit;
    color: inherit;
}

.fa-footer__title {
    margin: 0 0 4px;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .5);
}

.fa-footer__link {
    font-size: 14px;
    color: rgba(255, 255, 255, .72);
    padding: 2px 0;
    text-decoration: none;
    transition: color .3s ease;
}

.fa-footer__link:hover { color: #ffffff; }

.fa-footer__platform-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: -.01em;
    color: #ffffff;
    text-decoration: none;
}

.fa-footer .fa-footer__text {
    margin: 0;
    font-family: var(--font-primary, 'Inter', system-ui, sans-serif);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.6;
    color: rgba(255, 255, 255, .72);
    max-width: 30ch;
}

.fa-footer__text p {
    margin: 0;
    font: inherit;
    color: inherit;
}

/* Links inside the rich-text fields, so they don't fall back to browser blue. */
.fa-footer__about a,
.fa-footer__text a {
    color: inherit;
    text-decoration: none;
    transition: color .3s ease;
}

.fa-footer__about a:hover,
.fa-footer__text a:hover { color: #ffffff; }

/* ---------- social ---------- */

.fa-footer__social {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
}

.fa-footer__social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .2);
    color: rgba(255, 255, 255, .72);
    font-size: 15px;
    text-decoration: none;
    transition: border-color .3s ease, color .3s ease, background .3s ease;
}

.fa-footer__social a:hover {
    border-color: var(--fa-accent, #54243D);
    background: var(--fa-accent, #54243D);
    color: #ffffff;
}

/* ---------- bottom bar ---------- */

.fa-footer__bottom {
    margin-top: clamp(38px, 6vh, 80px);
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, .14);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 14px 32px;
    align-items: center;
}

.fa-footer__legal {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 26px;
    align-items: center;
}

.fa-footer__legal a,
.fa-footer__legal span,
.fa-footer__copyright {
    font-size: 12px;
    color: rgba(255, 255, 255, .62);
    text-decoration: none;
}

.fa-footer__legal a:hover { color: #ffffff; }

.fa-footer__copyright { margin: 0; }

.fa-footer__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 12px 22px;
}

.fa-footer__credit {
    margin: 0;
    font-size: 12px;
    color: rgba(255, 255, 255, .45);
    text-align: center;
}

.fa-footer__credit a {
    color: rgba(255, 255, 255, .68);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, .2);
}

.fa-footer__credit a:hover { color: #ffffff; }

/* Stacked and left-aligned, like the Finmarket footer. */
@media (max-width: 860px) {
    .fa-footer__bottom {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .fa-footer__legal { justify-content: flex-start; }

    .fa-footer__meta { justify-content: flex-start; }

    .fa-footer__credit { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
    .fa-footer__link,
    .fa-footer__about a,
    .fa-footer__text a,
    .fa-footer__social a { transition: none; }
}
