/**
 * Nexa footer wordmark — do NOT use theme class `.logo` here: theme sets
 * `#footer .logo { mix-blend-mode: difference; fixed height }` which hides PNGs.
 * Link uses only `.nexa-footer-logo`.
 */
footer.component.component--footer.footer#footer,
#footer.footer.component--footer {
  display: block !important;
  overflow: hidden !important;
  padding-top: max(26px, min(2.85vw, 40px)) !important;
  padding-bottom: max(26px, min(2.85vw, 40px)) !important;
}

#footer .container {
  padding-left: clamp(12px, 3vw, 28px) !important;
  padding-right: clamp(12px, 3vw, 28px) !important;
  box-sizing: border-box !important;
  max-width: 100% !important;
}

#footer .columns.--centered {
  overflow: visible !important;
}

#footer .nexa-footer-logo-cell {
  flex: 0 0 auto;
  min-width: 128px;
  overflow: visible !important;
}

#footer a.nexa-footer-logo {
  display: inline-flex !important;
  align-items: center;
  justify-content: flex-start;
  text-decoration: none !important;
  width: auto !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  max-width: 100%;
  line-height: 0;
  overflow: visible !important;
  mix-blend-mode: normal !important;
  isolation: isolate;
  filter: none !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#footer a.nexa-footer-logo:focus-visible {
  outline: 2px solid rgba(212, 175, 55, 0.65);
  outline-offset: 4px;
}

#footer a.nexa-footer-logo > img {
  display: block !important;
  width: 118px !important;
  height: auto !important;
  max-height: none !important;
  max-width: 100% !important;
  aspect-ratio: 3334 / 1324;
  object-fit: contain;
  opacity: 1 !important;
  visibility: visible !important;
  mix-blend-mode: normal !important;
  filter: none !important;
  flex-shrink: 0;
}

/* Cocoa-brown circles */
#footer .link.--round .circle {
  background-color: #5c3d2e !important;
  background-image: none !important;
  color: #fdf8f3 !important;
}

@media (min-width: 1101px) {
  #footer .container {
    position: relative;
  }

  #footer .columns.--centered {
    display: grid !important;
    grid-template-columns: minmax(128px, max-content) minmax(0, 1fr) auto auto;
    align-items: center !important;
    column-gap: clamp(0.65rem, 1.5vw, 1.25rem);
    row-gap: 0.5rem;
    width: 100%;
  }

  #footer .nexa-footer-logo-cell {
    grid-column: 1;
    justify-self: start;
    align-self: center !important;
  }

  #footer .nexa-footer-logo-cell + .columns__item {
    grid-column: 2;
    justify-self: center;
    min-width: 0;
  }

  #footer .nexa-footer-logo-cell + .columns__item + .columns__item {
    grid-column: 3;
    justify-self: end;
    text-align: right;
  }

  #footer .nexa-footer-logo-cell + .columns__item + .columns__item + .columns__item {
    grid-column: 4;
    justify-self: end;
  }

  #footer .flex {
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: wrap;
    justify-content: center;
    gap: clamp(0.65rem, 2vw, 1.5rem);
    margin-bottom: 0 !important;
  }

  #footer .link.--round + .link.--round {
    margin-left: 0 !important;
  }

  #footer a.nexa-footer-logo > img {
    width: clamp(104px, 12vw, 128px) !important;
  }
}

@media (max-width: 1100px) {
  #footer .columns.--centered {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: clamp(0.65rem, 3vw, 1rem);
  }

  #footer .nexa-footer-logo-cell {
    order: -1;
    width: 100%;
    min-width: 0 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center;
  }

  #footer a.nexa-footer-logo {
    justify-content: center !important;
  }

  #footer .nexa-footer-logo-cell + .columns__item {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  #footer .copyright {
    text-align: center;
  }

  #footer .nexa-footer-logo-cell + .columns__item + .columns__item {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  #footer .nexa-footer-logo-cell + .columns__item + .columns__item + .columns__item {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  #footer a.nexa-footer-logo > img {
    width: clamp(120px, 46vw, 168px) !important;
  }
}

/* Back to top — circle ring + frosted blur (scroll handled by nexa-back-to-top.js). */
#footer .nexa-back-to-top {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  padding: 0;
  margin: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 50%;
  box-sizing: border-box;
  color: rgba(248, 244, 236, 0.95);
  -webkit-tap-highlight-color: transparent;
}

#footer .nexa-back-to-top__blur {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(212, 175, 55, 0.45);
  background: rgba(22, 18, 14, 0.38);
  transform-origin: center;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 8px 24px rgba(0, 0, 0, 0.28);
  pointer-events: none;
  z-index: 0;
}

#footer .nexa-back-to-top i {
  position: relative;
  z-index: 1;
  font-size: 1.08rem;
  line-height: 1;
  pointer-events: none;
}

#footer .nexa-back-to-top:hover .nexa-back-to-top__blur {
  border-color: rgba(232, 212, 160, 0.65);
  background: rgba(28, 22, 18, 0.48);
}

#footer .nexa-back-to-top:active .nexa-back-to-top__blur {
  transform: scale(0.96);
}

#footer .nexa-back-to-top:focus {
  outline: none;
}

#footer .nexa-back-to-top:focus-visible {
  outline: 2px solid rgba(212, 175, 55, 0.75);
  outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  #footer .nexa-back-to-top:active .nexa-back-to-top__blur {
    transform: none;
  }
}
