/**
 * Apple-style footer — v1.3.2
 * Layout: brand full row, then 3 wide columns (not 4 squeezed).
 */

body.bth-apple-template .bth-apple-main,
body.bth-apple-template .site-footer.bth-apple-footer {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  box-sizing: border-box;
}

body.bth-apple-template .site-footer.bth-apple-footer {
  background: #f5f5f7;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  color: #6e6e73;
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

body.bth-apple-template .site-footer.bth-apple-footer a {
  color: #424245;
  text-decoration: none;
  transition: color 0.2s ease;
}

body.bth-apple-template .site-footer.bth-apple-footer a:hover {
  color: #1d1d1f;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-inner {
  max-width: min(1200px, 100%);
  margin: 0 auto;
  padding: 40px 36px max(24px, env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}

/* Stack: brand row, then 3 columns */
body.bth-apple-template .site-footer.bth-apple-footer .footer-top {
  display: flex !important;
  flex-direction: column;
  gap: 28px;
  align-items: stretch;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px 28px;
  padding-bottom: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-brand__main {
  flex: 1 1 260px;
  min-width: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-brand .logo-img--footer {
  display: block;
  height: 52px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
  margin: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-social {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 0 0 auto;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-social__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border-radius: 980px;
  background: rgba(0, 0, 0, 0.05);
  color: #1d1d1f;
  font-size: 14px;
  font-weight: 500;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-social__link:hover {
  background: rgba(0, 0, 0, 0.09);
  color: #1d1d1f;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-social__icon {
  display: block;
  width: 20px;
  height: 20px;
}

/* Three equal-ish columns; Locations wider */
body.bth-apple-template .site-footer.bth-apple-footer .footer-columns {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr) minmax(0, 0.9fr);
  gap: 32px 40px;
  align-items: start;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-col {
  min-width: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-heading {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #1d1d1f;
  line-height: 1.3;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list > li {
  margin: 0 0 16px;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list > li:last-child {
  margin-bottom: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list__label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #86868b;
  margin-bottom: 8px;
  line-height: 1.45;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list__links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-list__links a {
  display: block;
  font-size: 15px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-cert-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  margin-top: 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-cert-logos img {
  display: block;
  height: auto;
  max-height: 64px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

/* Bottom zone: menu + copyright aligned right (like formal site) */
body.bth-apple-template .site-footer.bth-apple-footer .footer-bottom {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  width: 100%;
}

/* Fallback if partial not updated yet (no .footer-bottom wrapper) */
body.bth-apple-template .site-footer.bth-apple-footer .footer-inner > .footer-nav {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-bottom .footer-nav {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-nav {
  margin: 0;
  padding: 0;
  width: 100%;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0 28px;
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list li {
  margin: 0;
}

/* No pipe separators — they bunch up when wrapped */
body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list li::after {
  display: none !important;
  content: none !important;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list a {
  font-size: 15px;
  color: #424245;
  white-space: nowrap;
  padding: 6px 0;
}

body.bth-apple-template .site-footer.bth-apple-footer .footer-copy {
  margin: 12px 0 0;
  text-align: right;
  align-self: flex-end;
  width: 100%;
  font-size: 13px;
  line-height: 1.55;
  color: #86868b;
}

body.bth-apple-template .screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Kill legacy 4-column footer rules if still in apple-home.css */
body.bth-apple-template .site-footer.bth-apple-footer .footer-grid {
  display: block !important;
  grid-template-columns: none !important;
}

@media (max-width: 1024px) {
  body.bth-apple-template .site-footer.bth-apple-footer .footer-columns {
    grid-template-columns: 1fr 1fr;
    gap: 36px 32px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-col--locations {
    grid-column: 1 / -1;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-brand {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 734px) {
  body.bth-apple-template .site-footer.bth-apple-footer .footer-inner {
    padding: 14px 24px max(16px, env(safe-area-inset-bottom, 0px)) !important;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-top {
    gap: 10px !important;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-brand {
    display: block !important;
    gap: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-brand__main {
    display: block !important;
    margin-bottom: 30px !important; /* ~one-finger space */
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-columns {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-brand .logo-img--footer {
    height: 50px !important;
    width: auto !important;
    max-width: 230px !important;
    display: block !important;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-social {
    margin-top: 0 !important;
    gap: 8px !important;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-bottom {
    margin-top: 32px;
    padding-top: 20px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-col--locations {
    grid-column: auto;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px 20px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-nav__list a {
    white-space: nowrap;
    font-size: 15px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-copy {
    text-align: right;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-list__links a {
    font-size: 16px;
  }

  body.bth-apple-template .site-footer.bth-apple-footer .footer-heading {
    font-size: 18px;
  }
}
