/*
 * Site footer (shared/_footer): a frosted panel under the page card, in the same light
 * palette. Navy text and gold-deep headings. Phones: brand, the two link groups side by side,
 * then contact. 768px: brand on top, three groups below. 1200px: four columns (narrower,
 * and the tagline and the longest link wrap).
 */

.mx-footer {
  border: 1px solid color-mix(in srgb, var(--mx-color-surface) 70%, transparent);
  border-radius: 28px;
  background: color-mix(in srgb, var(--mx-color-surface) 45%, transparent);
  color: var(--mx-color-muted);
  backdrop-filter: blur(20px) saturate(1.1);
}

.mx-footer__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--mx-space-xl) var(--mx-space-lg);
  padding: var(--mx-space-xxl) var(--mx-space-md) var(--mx-space-xl);
}

.mx-footer__brand {
  grid-column: 1 / -1;
}

/* The emblem with a navy wordmark: the full logo's gold wordmark is too pale on white. */
.mx-footer__logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--mx-color-navy);
  text-decoration: none;
}

.mx-footer__logo img {
  width: 44px;
}

.mx-footer__name {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mx-footer__wordmark {
  font-family: var(--mx-font-display);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.mx-footer__tagline {
  margin-top: var(--mx-space-md);
  color: var(--mx-color-navy);
  font-family: var(--mx-font-display);
  font-size: 1.25rem;
  font-style: italic;
}

/*
 * Instagram and email as round icon buttons under the tagline; 44px targets. A white rim like
 * the panel's own edge, not the warm line colour, which reads muddy on the cool frost.
 */
.mx-footer__social {
  display: flex;
  gap: 12px;
  margin: var(--mx-space-md) 0 0;
  padding: 0;
  list-style: none;
}

.mx-footer__social-link {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--mx-color-surface);
  border-radius: var(--mx-rounded-pill);
  background: color-mix(in srgb, var(--mx-color-surface) 55%, transparent);
  box-shadow: var(--mx-shadow-sm);
  transition: border-color 160ms ease, background-color 160ms ease;
}

.mx-footer__social-link:hover,
.mx-footer__social-link:focus-visible {
  border-color: var(--mx-color-gold-deep);
  background: var(--mx-color-surface);
}

.mx-footer__social .mx-footer__icon {
  width: 20px;
  height: 20px;
}

.mx-footer__heading {
  margin: 0 0 var(--mx-space-xs);
  color: var(--mx-color-gold-deep);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.mx-footer__links {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* 44px tall targets; the underline arrives on hover and focus. */
.mx-footer__links a {
  display: inline-block;
  padding: 10px 0;
  color: var(--mx-color-navy);
  font-size: 0.9375rem;
  line-height: 1.5;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 5px;
  transition: text-decoration-color 160ms ease;
}

.mx-footer__links a:hover,
.mx-footer__links a:focus-visible,
.mx-footer__links a[aria-current="page"] {
  text-decoration-color: var(--mx-color-gold-deep);
}

/* Contact: a gold line icon beside each channel, lined up with the first line of text. */
.mx-footer__contact {
  grid-column: 1 / -1;
}

.mx-footer__contact address {
  font-style: normal;
}

.mx-footer__channel {
  display: grid;
  grid-template-columns: 18px auto;
  column-gap: 12px;
  justify-content: start;
  justify-items: start;
}

.mx-footer__icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: var(--mx-color-gold-deep);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mx-footer__channel .mx-footer__icon {
  margin-top: 12px;
}

.mx-footer__icon-dot {
  fill: var(--mx-color-gold-deep);
  stroke: none;
}

.mx-footer__base {
  padding: 0 var(--mx-space-md) calc(var(--mx-space-lg) + env(safe-area-inset-bottom));
  font-size: 0.8125rem;
}

/* The divider sits on the text, so it lines up with the columns above. */
.mx-footer__base p {
  padding-top: var(--mx-space-lg);
  border-top: 1px solid var(--mx-color-line);
}

@media (min-width: 768px) {
  .mx-footer {
    border-radius: 40px;
  }

  .mx-footer__inner {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 64px var(--mx-space-xl) var(--mx-space-xxl);
  }

  .mx-footer__contact {
    grid-column: auto;
  }

  .mx-footer__base {
    padding-inline: var(--mx-space-xl);
  }
}

@media (min-width: 1200px) {
  .mx-footer__inner {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.1fr);
  }

  .mx-footer__brand {
    grid-column: auto;
  }
}
