/* Shared footer: brand, navigation, then the particle sphere. */
.site-footer {
  padding: clamp(56px, 6vw, 96px) 0 clamp(80px, 6vw, 104px);
}

.site-footer .site-footer-top {
  grid-template-columns: minmax(140px, 0.7fr) minmax(440px, 1.65fr) minmax(180px, 1fr);
  gap: clamp(28px, 3vw, 48px);
  align-items: start;
  padding-top: 0;
}

.site-footer .site-footer-brand img {
  width: clamp(140px, 14vw, 220px);
  max-width: 100%;
}

.site-footer .site-footer-nav-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 2vw, 32px);
  min-width: 0;
  justify-content: center;
}

.site-footer .site-footer-links a {
  white-space: normal;
  font-size: 14px;
}

.site-footer-sphere {
  position: relative;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 1;
  align-self: center;
  justify-self: end;
  color: var(--jd-particle-color, var(--fg-default));
  pointer-events: auto;
}

.site-footer-sphere > svg,
.site-footer-sphere > canvas {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.site-footer-sphere > canvas { visibility: hidden; }
.site-footer-sphere[data-ready] > canvas { visibility: visible; }
.site-footer-sphere[data-ready] > svg { visibility: hidden; }

html[data-theme="light"] .site-footer {
  border-top: 1px solid var(--border-default);
  background: var(--bg-canvas);
}

html[data-theme="light"] .site-footer::before {
  content: none;
}

html[data-theme="light"] .site-footer-brand img {
  content: url("/_assets/img/brand/derivatives/jadey-logo-dark.svg");
}

@media (max-width: 1100px) {
  .site-footer .site-footer-top {
    grid-template-columns: minmax(0, 1fr) minmax(170px, 0.4fr);
    gap: 36px;
  }

  .site-footer-brand-name { grid-column: 1; grid-row: 1; }
  .site-footer .site-footer-nav-grid { grid-column: 1; grid-row: 2; }
  .site-footer-sphere { grid-column: 2; grid-row: 1 / 3; }
}

@media (max-width: 700px) {
  .site-footer .site-footer-top { grid-template-columns: minmax(0, 1fr); }
  .site-footer .site-footer-nav-grid { gap: 28px 24px; }
  .site-footer-sphere { grid-column: 1; grid-row: 3; width: 200px; }
}

@media (max-width: 480px) {
  .site-footer .site-footer-nav-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
