/* ==========================================================================
   Monreal footer  ([monreal_footer] – monreal-extensions/footer.php)
   ========================================================================== */

#brx-footer .mf {
      --mf-bg: #013b49;
      --mf-bg-deep: #012d38;
      --mf-gold: #bd997e;
      --mf-text: #f3f1ed;
      --mf-muted: rgba(243, 241, 237, 0.7);
      --mf-line: rgba(189, 153, 126, 0.22);
      --mf-gutter: clamp(16px, 4vw, 40px);
      --mf-sidebar: 0px;

      width: 100%;
      background: var(--mf-bg);
      color: var(--mf-muted);
      font-family: "Montserrat", sans-serif;
      font-size: 1.5rem;
      line-height: 1.6;
}

/* Above 1290px the page content is centred beside the fixed sidebar (spacer 150px) */
@media (min-width: 1291px) {
      #brx-footer .mf {
            --mf-sidebar: 150px;
      }
}

@media (prefers-reduced-motion: no-preference) {
      html {
            scroll-behavior: smooth;
      }
}

.mf *,
.mf *::before,
.mf *::after {
      box-sizing: border-box;
}

.mf a {
      color: inherit;
      text-decoration: none;
}

.mf a:focus-visible {
      outline: 1px solid var(--mf-gold);
      outline-offset: 4px;
}

.mf p,
.mf ul,
.mf address {
      margin: 0;
      padding: 0;
      font-style: normal;
}

/* Same content column as the page (1152px, centred next to the sidebar) */
.mf__main,
.mf__bottom {
      padding-right: var(--mf-sidebar);
}

.mf__inner {
      width: min(1152px, 100% - 2 * var(--mf-gutter));
      margin: 0 auto;
}

.mf__icon {
      width: 1.6rem;
      height: 1.6rem;
      flex-shrink: 0;
}

.mf__sr {
      position: absolute;
      width: 1px;
      height: 1px;
      overflow: hidden;
      clip: rect(0 0 0 0);
      white-space: nowrap;
}

/* ---- Main area ----------------------------------------------------------- */

.mf__main {
      position: relative;
      padding-top: clamp(56px, 7vw, 96px);
      padding-bottom: clamp(48px, 6vw, 80px);
}

/* hairline in gold at the very top */
.mf__main::before {
      content: "";
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, var(--mf-gold) 20%, var(--mf-gold) 80%, transparent);
      opacity: 0.5;
}

.mf__grid {
      display: grid;
      grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
      gap: 56px clamp(32px, 4vw, 64px);
}

/* Brand column */
.mf__brand {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      gap: 28px;
}

.mf__logo {
      display: inline-flex;
      color: var(--mf-gold);
      transition: color 0.25s;
}

.mf__logo:hover {
      color: var(--mf-text);
}

.mf__logo-svg {
      width: 112px;
      height: 112px;
}

.mf__claim {
      display: flex;
      flex-direction: column;
      font-family: "EBGaramond", Georgia, serif;
      color: var(--mf-text);
      line-height: 1.1;
}

.mf__claim-pre {
      font-size: 1.8rem;
      letter-spacing: 0.2em;
      color: var(--mf-gold);
      margin-bottom: 6px;
}

.mf__claim-main {
      font-size: clamp(2.8rem, 2.4vw, 3.4rem);
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.02em;
      text-wrap: balance;
}

.mf__contact {
      display: grid;
      gap: 18px;
}

.mf__contact-item {
      display: flex;
      align-items: flex-start;
      gap: 14px;
      line-height: 1.5;
}

.mf__contact-item .mf__icon {
      margin-top: 0.2em;
      color: var(--mf-gold);
}

.mf__contact .mf__contact-item .mf__icon {
      width: 36px;
      height: 36px;
      margin-top: 0;
      padding: 9px;
      border: 1px solid var(--mf-line);
      border-radius: 50%;
      transition: border-color 0.2s;
}

.mf__contact-label {
      display: block;
      font-size: 1.1rem;
      letter-spacing: 0.18em;
      text-transform: uppercase;
      color: rgba(243, 241, 237, 0.45);
}

a.mf__contact-item {
      transition: color 0.2s;
}

a.mf__contact-item:hover {
      color: var(--mf-text);
}

a.mf__contact-item:hover .mf__icon {
      border-color: var(--mf-gold);
}

/* Right-hand side: link columns + contact / CTA row */
.mf__side {
      display: flex;
      flex-direction: column;
}

/* Link columns */
.mf__nav,
.mf__reach {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      column-gap: 24px;
}

.mf__nav {
      row-gap: 40px;
      padding-top: 8px;
      font-size: 1.45rem;
}

.mf__reach {
      row-gap: 40px;
      margin-top: 48px;
      padding-top: 40px;
      border-top: 1px solid var(--mf-line);
}

.mf__reach-contact {
      grid-column: 1 / 3;
}

.mf__reach-address {
      grid-column: 3 / 5;
}

.mf__maplink {
      margin-top: 18px;
      margin-left: 50px; /* aligned with the text next to the round icon */
      font-size: 1.3rem;
      color: var(--mf-gold);
}

/* CTA under the claim in the brand column */
.mf__brand-cta {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      margin-top: 4px;
}

.mf__cta-text {
      max-width: 30ch;
      margin-bottom: 24px !important;
      font-family: "EBGaramond", Georgia, serif;
      font-size: 2rem;
      line-height: 1.35;
      color: var(--mf-text);
}

.mf__cta {
      display: inline-flex;
      align-items: center;
      gap: 12px;
      padding: 14px 24px;
      border: 1px solid var(--mf-gold);
      color: var(--mf-text) !important;
      font-size: 1.4rem;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      transition: background-color 0.25s, color 0.25s;
}

.mf__cta .mf__icon {
      transition: transform 0.25s;
}

.mf__cta:hover {
      background: var(--mf-gold);
      color: var(--mf-bg) !important;
}

.mf__cta:hover .mf__icon {
      transform: translateX(4px);
}

.mf__heading {
      margin-bottom: 22px !important;
      font-size: 1.2rem;
      letter-spacing: 0.22em;
      text-transform: uppercase;
      color: var(--mf-gold);
}

.mf__links {
      list-style: none;
      display: grid;
      gap: 14px;
}

.mf__link {
      position: relative;
      display: inline-block;
      line-height: 1.35;
      transition: color 0.2s;
}

.mf__link::after {
      content: "";
      position: absolute;
      left: 0;
      bottom: -3px;
      width: 100%;
      height: 1px;
      background: var(--mf-gold);
      transform: scaleX(0);
      transform-origin: left;
      transition: transform 0.25s;
}

.mf__link:hover {
      color: var(--mf-text);
}

.mf__link:hover::after {
      transform: scaleX(1);
}

/* ---- Bottom bar ---------------------------------------------------------- */

.mf__bottom {
      background: var(--mf-bg-deep);
      border-top: 1px solid var(--mf-line);
}

.mf__bar {
      display: grid;
      grid-template-columns: 1fr auto 1fr;
      align-items: center;
      gap: 12px 24px;
      min-height: 64px;
      padding: 16px 0;
      font-size: 1.3rem;
}

.mf__poweredby {
      justify-self: start;
      display: inline-flex;
      line-height: 0;
      opacity: 0.75;
      transition: opacity 0.2s;
}

.mf__poweredby:hover {
      opacity: 1;
}

.mf__poweredby img {
      width: 88px;
      height: auto;
}

.mf__copyright {
      text-align: center;
      letter-spacing: 0.04em;
}

.mf__totop {
      justify-self: end;
      display: inline-flex;
      align-items: center;
      gap: 10px;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      font-size: 1.2rem;
      transition: color 0.2s;
}

.mf__totop .mf__icon {
      width: 30px;
      height: 30px;
      padding: 6px;
      border: 1px solid var(--mf-line);
      border-radius: 50%;
      transition: border-color 0.2s, transform 0.25s;
}

.mf__totop:hover {
      color: var(--mf-text);
}

.mf__totop:hover .mf__icon {
      border-color: var(--mf-gold);
      transform: translateY(-2px);
}

/* ---- Responsive ---------------------------------------------------------- */

@media (max-width: 1100px) {
      .mf__grid {
            grid-template-columns: 1fr;
      }

      /* Brand on one line: logo | claim | address */
      .mf__brand {
            display: grid;
            grid-template-columns: auto 1fr auto;
            grid-template-areas: "logo claim cta";
            align-items: center;
            column-gap: 32px;
            row-gap: 28px;
            padding-bottom: 48px;
            border-bottom: 1px solid var(--mf-line);
      }

      .mf__logo { grid-area: logo; }
      .mf__claim { grid-area: claim; }
      .mf__brand-cta { grid-area: cta; margin-top: 0; }

      .mf__brand-cta .mf__cta-text {
            max-width: 26ch;
            font-size: 1.8rem;
      }

      .mf__logo-svg {
            width: 96px;
            height: 96px;
      }
}

@media (max-width: 820px) {
      .mf__brand {
            grid-template-columns: auto 1fr;
            grid-template-areas:
                  "logo claim"
                  "cta cta";
      }

      .mf__nav,
      .mf__reach {
            grid-template-columns: repeat(2, minmax(0, 1fr));
      }

      .mf__reach-contact {
            grid-column: 1 / 2;
      }

      .mf__reach-address {
            grid-column: 2 / 3;
      }
}

@media (max-width: 478px) {
      .mf__brand {
            grid-template-columns: 1fr;
            grid-template-areas: "logo" "claim" "cta";
            justify-items: start;
      }

      /* Phones: large, centred logo */
      .mf__logo {
            justify-self: center;
            justify-content: center;
            margin-bottom: 8px;
      }

      .mf__logo-svg {
            width: 150px;
            height: 150px;
      }

      .mf__nav {
            column-gap: 20px;
      }

      .mf__reach {
            grid-template-columns: 1fr;
      }

      .mf__reach-contact,
      .mf__reach-address {
            grid-column: 1 / -1;
      }

      .mf__brand,
      .mf__brand-cta {
            justify-items: stretch;
            align-items: stretch;
      }

      .mf__cta {
            justify-content: center;
      }

      .mf__bar {
            grid-template-columns: 1fr;
            justify-items: center;
            row-gap: 18px;
            text-align: center;
            padding: 24px 0;
      }

      .mf__poweredby,
      .mf__totop {
            justify-self: center;
      }

      .mf__totop {
            order: -1;
      }

      .mf__poweredby {
            order: 1;
      }
}
