/* Keep the original illustration, cropping only its old top footer strip. */
.xb-footer__artwork {
  overflow: hidden;
}
.xb-footer__artwork .xbotnow-footer-art {
  display: block;
  width: 100%;
  height: auto;
  margin: -4.4% 0 0;
  -webkit-mask-image: linear-gradient(to bottom, black 92%, transparent);
  mask-image: linear-gradient(to bottom, black 92%, transparent);
}

footer.xb-footer {
  /* ---- Set these two from the site's existing CSS ---- */
  --xb-brand: var(--a2, #3b6cf6);
  --xb-ink: var(--tx, #1d2330);
  /* Brand colour used for TEXT (tagline, link hover). Auto-darkened so even
     bright brands (orange, yellow, cyan) stay readable on the light background.
     If the brand colour itself has 4.5:1+ contrast on the footer background,
     you may set this to var(--xb-brand) instead. */
  --xb-brand-text: color-mix(in srgb, var(--xb-brand) 55%, #000000);
  /* ---- Everything below is derived; normally leave as is ---- */
  --xb-footer-bg: color-mix(in srgb, var(--xb-brand) 3%, #ffffff);
  --xb-footer-text: color-mix(in srgb, var(--xb-ink) 80%, #ffffff);
  --xb-footer-heading: var(--xb-ink);
  --xb-footer-muted: color-mix(in srgb, var(--xb-ink) 68%, #ffffff);
  --xb-footer-accent: var(--xb-brand-text);
  --xb-footer-line: color-mix(in srgb, var(--xb-brand) 18%, #ffffff);

  border: 0;
  background: var(--xb-footer-bg);
  color: var(--xb-footer-text);
  font: 15px/1.6 var(--font-sans);
  box-sizing: border-box;
  text-align: start;
  padding: 0;
  margin: 0;
}
/* Education wraps its original footer in a narrower content container. */
body > .wrap > footer.xb-footer {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
}
.xb-footer__inner {
  box-sizing: content-box;
  max-width: 1160px;
  margin: 0 auto;
  padding: clamp(20px, 3vw, 36px) 24px 28px;
}

.xb-footer__top {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) repeat(5, minmax(120px, 1fr));
  gap: 32px;
}
.xb-footer .xb-footer__brand-name {
  color: var(--xb-footer-heading);
  font-size: 20px; font-weight: 800; letter-spacing: .04em;
  text-decoration: none;
}
.xb-footer__tagline { color: var(--xb-footer-accent); font-weight: 600; margin: 6px 0 10px; }
.xb-footer__about { margin: 0; max-width: 300px; }

/* Some page styles hide or lay out every nav as the mobile header. */
.xb-footer .xb-footer__col {
  display: block;
  min-width: 0;
  overflow: visible;
  white-space: normal;
  font: inherit;
}
.xb-footer .xb-footer__col h2 {
  color: var(--xb-footer-heading);
  font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  margin: 4px 0 14px;
}
.xb-footer__col ul { list-style: none; margin: 0; padding: 0; }
.xb-footer__col li + li { margin-top: 8px; }

.xb-footer a { color: var(--xb-footer-text); text-decoration: none; }
.xb-footer a:hover { color: var(--xb-footer-accent); text-decoration: underline; }
.xb-footer a:focus-visible {
  outline: 2px solid var(--xb-footer-accent); outline-offset: 3px; border-radius: 2px;
}

.xb-footer__bottom {
  border-top: 1px solid var(--xb-footer-line);
  margin-top: 32px; padding-top: 18px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  color: var(--xb-footer-muted); font-size: 13px;
}
.xb-footer__bottom p { margin: 0; }

/* Tablet: brand on its own row, links in 3 columns */
@media (max-width: 1040px) {
  .xb-footer__top { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .xb-footer__brand { grid-column: 1 / -1; }
}
/* Phone: 2 columns */
@media (max-width: 560px) {
  .xb-footer__inner { padding: 20px 20px 24px; }
  .xb-footer__top { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 20px; }
  .xb-footer__bottom { flex-direction: column; }
}
