/* Site footer, shared by every public page.
   The wordmark at the left, link columns at the right, each behind a hairline,
   then one closing row. Black, grey and white only. */

.sf {
    --sf-bg: var(--background, #0a0a0a);
    --sf-gutter: clamp(1.25rem, 4vw, 3rem);
    --sf-rail: min(75rem, calc(100% - var(--sf-gutter) - var(--sf-gutter)));
    --sf-text: #9a9a9a;
    --sf-strong: #f4f4f4;
    --sf-rule: #2e2e2e;
    padding: clamp(3.5rem, 7vw, 5.5rem) 0 clamp(2rem, 3.6vw, 2.75rem);
    background: var(--sf-bg);
    color: var(--sf-text);
    font-size: .9375rem;
    line-height: 1.5rem;
}
.sf-rail { width: var(--sf-rail); margin-inline: auto; }

.sf-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2.5rem 3rem;
}
.sf .sf-brand { margin: 0; color: var(--sf-strong); text-decoration: none; }

.sf-cols { display: flex; }
.sf-col {
    min-width: 10.5rem;
    padding: 0 clamp(1.25rem, 2.6vw, 2.5rem) .25rem 1.5rem;
    border-left: 1px solid var(--sf-rule);
}
.sf-col:last-child { min-width: 0; padding-right: 0; }
.sf-heading {
    margin: 0 0 1rem;
    color: var(--sf-strong);
    font-size: .8125rem;
    font-weight: 500;
    line-height: 1.25rem;
}
.sf-col ul { display: grid; gap: .7rem; margin: 0; padding: 0; list-style: none; }

.sf a,
.sf-news-toggle {
    color: inherit;
    text-decoration: none;
    transition: color 160ms ease;
}
.sf a:is(:hover, :focus-visible),
.sf-news-toggle:is(:hover, :focus-visible) { color: var(--sf-strong); }
.sf :is(a, button):focus-visible { outline: 2px solid var(--sf-strong); outline-offset: 3px; }
.sf-news-toggle {
    padding: 0;
    border: 0;
    background: none;
    font: inherit;
    cursor: pointer;
}

/* ── Newsletter: one row, opened from the Follow column ──── */

.sf-news {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-top: clamp(2rem, 4vw, 3rem);
    padding-top: 1.5rem;
    border-top: 1px solid var(--sf-rule);
}
.sf-news[hidden],
.sf-news .footer-newsletter-form[hidden] { display: none; }      /* the form gives way to the confirmation */
.sf-news-label { margin: 0; color: var(--sf-strong); }
.sf-news .footer-newsletter-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .625rem;
    margin: 0;
}
.sf .sf-news input[type="email"] {
    width: min(18rem, 60vw);
    height: 2.625rem;
    padding: 0 .9rem;
    border: 1px solid var(--sf-rule);
    border-radius: 0;
    background: transparent;
    color: var(--sf-strong);
    font: inherit;
}
.sf .sf-news input[type="email"]::placeholder { color: #6f6f6f; }
.sf .sf-news input[type="email"]:focus { border-color: var(--sf-strong); outline: 0; }
.sf .sf-news .footer-newsletter-btn {
    height: 2.625rem;
    padding: 0 1.25rem;
    border: 0;
    border-radius: 999px;
    background: var(--sf-strong);
    color: #0a0a0a;
    font: inherit;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 160ms ease;
}
.sf .sf-news .footer-newsletter-btn:hover { background: #fff; }
.sf .sf-news .footer-newsletter-btn:disabled { opacity: .6; cursor: default; }
.sf-news .footer-newsletter-error { flex-basis: 100%; margin: 0; color: #f0554e; font-size: .8125rem; }
.sf-news .footer-newsletter-success { margin: 0; color: var(--sf-strong); }
.sf-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

/* ── Closing row ───────────────────────────────────────── */

.sf-base {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .75rem 2rem;
    margin-top: clamp(2.5rem, 5.5vw, 4.5rem);
    font-size: .875rem;
}
.sf-base p { margin: 0; }
.sf-base ul { display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; margin: 0; padding: 0; list-style: none; }

@media (max-width: 899px) {
    .sf-top { flex-direction: column; }
    .sf-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.25rem 0; width: 100%; }
    .sf-col, .sf-col:last-child { min-width: 0; padding: 0 1rem .25rem 1.25rem; }
}
@media (prefers-reduced-motion: reduce) {
    .sf a, .sf-news-toggle, .sf .sf-news .footer-newsletter-btn { transition: none; }
}
