/* One public footer contract: brand, locale/currency controls, then utility links.
   Page styles may set surrounding space, but not a competing footer layout. */
.roamnessa-site-footer {
  box-sizing: border-box;
  direction: ltr;
  width: min(1180px, calc(100% - 56px));
  margin: var(--space-8) auto 0;
  padding: var(--space-6) 0 var(--space-7);
  border-top: 1px solid var(--color-border);
  display: grid;
  /* The locale controls belong in the visual space between the brand and
     the link group—not at the mathematical center of the viewport. */
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-5);
}

.roamnessa-site-footer .brand {
  display: inline-flex;
  align-items: center;
  gap: var(--brand-wordmark-gap);
  width: max-content;
  color: var(--color-ink-900);
  font: 800 italic 17px/1 "Funnel Sans", Arial, sans-serif;
  letter-spacing: -.8px;
  text-decoration: none;
}

.roamnessa-site-footer .brand-mark { width: var(--brand-mark-size); height: var(--brand-mark-size); flex: 0 0 var(--brand-mark-size); object-fit: contain; margin: 0; }
.roamnessa-site-footer .footer-controls { justify-self: center; display: flex; gap: 12px; }
.roamnessa-site-footer .footer-links { justify-self: end; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 24px; }
.roamnessa-site-footer .footer-links a {
  color: var(--color-ink-900);
  font: 700 13px/1.3 "Funnel Sans", Arial, sans-serif;
  text-decoration: none;
}
.roamnessa-site-footer .footer-links a:hover,
.roamnessa-site-footer .footer-links a:focus-visible { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 760px) {
  .roamnessa-site-footer {
    width: min(100% - 36px, 520px);
    margin-top: var(--space-6);
    grid-template-columns: 1fr;
    justify-items: center;
    gap: var(--space-5);
    padding: var(--space-6) 0;
  }
  .roamnessa-site-footer .footer-controls,
  .roamnessa-site-footer .footer-links { justify-self: center; }
  /* Safari can paint an outline around the open <details> box instead of the
     rounded summary. A shadow keeps the keyboard focus ring on the pill. */
  .roamnessa-site-footer .footer-controls summary:focus-visible {
    outline: none !important;
    box-shadow: 0 0 0 3px var(--color-focus-ring) !important;
  }
  .roamnessa-site-footer .footer-controls .language-options {
    right: auto;
    left: 50%;
    width: min(205px, calc(100vw - 32px));
    transform: translateX(-50%);
  }
  .roamnessa-site-footer .footer-links { justify-content: center; gap: 14px 20px; }
}
