.site-footer {
  position: relative;
  z-index: 2;
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 2.25rem 0 1.25rem;
  margin-top: auto;
  isolation: isolate;
  overflow: hidden;
}

@media (max-width: 767px) {
  .site-footer {
    padding: 1.5rem 0 0.875rem;
  }
}

.footer-decor {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-inner {
  position: relative;
  z-index: 1;
}

@media (max-width: 767px) {
  .site-footer .footer-inner {
    padding-inline: max(1.25rem, env(safe-area-inset-left, 0px))
      max(1.25rem, env(safe-area-inset-right, 0px));
  }
}

.footer-decor-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(36px);
  opacity: 0.55;
  will-change: transform;
}

.footer-decor-blob--1 {
  width: clamp(8rem, 22vw, 14rem);
  height: clamp(8rem, 22vw, 14rem);
  top: -30%;
  right: 6%;
  background: rgb(169 214 229 / 0.55);
  animation: footer-float-a 14s ease-in-out infinite;
}

.footer-decor-blob--2 {
  width: clamp(7rem, 18vw, 11rem);
  height: clamp(7rem, 18vw, 11rem);
  bottom: -20%;
  left: 4%;
  background: rgb(149 184 162 / 0.45);
  animation: footer-float-b 18s ease-in-out infinite;
}

.footer-decor-blob--3 {
  width: clamp(5rem, 12vw, 8rem);
  height: clamp(5rem, 12vw, 8rem);
  top: 40%;
  left: 42%;
  background: rgb(244 199 184 / 0.4);
  animation: footer-float-c 12s ease-in-out infinite;
}

.footer-decor-line {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--calm) 20%,
    var(--trust) 50%,
    var(--warm) 80%,
    transparent
  );
  background-size: 200% 100%;
  animation: footer-shimmer 6s ease-in-out infinite;
}

@keyframes footer-float-a {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-12px, 10px, 0) scale(1.06); }
}

@keyframes footer-float-b {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(14px, -8px, 0) scale(1.08); }
}

@keyframes footer-float-c {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-8px, -10px, 0); }
}

@keyframes footer-shimmer {
  0%, 100% { background-position: 100% 0; opacity: 0.6; }
  50% { background-position: 0% 0; opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .footer-decor-blob,
  .footer-decor-line {
    animation: none;
  }
}

@media (max-width: 767px) {
  .footer-decor-blob--3 {
    left: auto;
    right: -8%;
    top: 55%;
  }
}

.footer-grid {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 767px) {
  .footer-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.875rem 1.25rem;
    margin-bottom: 1rem;
    margin-inline: auto;
    width: 100%;
    max-width: 18.5rem;
    align-items: start;
    justify-items: center;
    text-align: center;
  }

  .footer-grid > :nth-child(1) {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

  .footer-grid > :nth-child(2),
  .footer-grid > :nth-child(3) {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .footer-grid > :nth-child(4) {
    grid-column: 1 / -1;
    justify-self: center;
    width: max-content;
    max-width: 100%;
    text-align: center;
  }

  .footer-brand-row {
    justify-content: center;
  }

  .footer-brand-text {
    align-items: center;
  }

  .footer-desc {
    text-align: center;
    max-width: 18.5rem;
  }

  .footer-social {
    justify-content: center;
  }
}

@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
}

.footer-brand {
  margin-bottom: 0.75rem;
}

.footer-brand-row {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.footer-brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  min-width: 0;
}

.footer-logo-icon {
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  display: block;
  object-fit: contain;
}

@media (max-width: 767px) {
  .footer-logo-icon {
    width: 2.25rem;
    height: 2.25rem;
  }
}

.footer-brand-uk {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--text);
}

.footer-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  line-height: 1.5;
}

.footer-social {
  display: flex;
  gap: 0.5rem;
}

.footer-social a {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-sm);
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background 0.2s, color 0.2s;
}

.footer-social a:hover {
  background: var(--calm);
  color: var(--white);
}

.footer-title {
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.footer-link {
  display: block;
  font-size: 0.875rem;
  color: var(--text-muted);
  padding: 0.1875rem 0;
  line-height: 1.35;
  transition: color 0.2s;
}

.footer-link:hover { color: var(--calm-dark); }

.footer-bottom {
  padding-top: 1.125rem;
  border-top: 1px solid var(--border);
  font-size: 0.75rem;
  color: var(--text-light);
  text-align: center;
}

.footer-tech {
  display: block;
  margin-top: 0.375rem;
  opacity: 0.7;
}

@media (max-width: 767px) {
  .footer-desc {
    font-size: 0.8125rem;
    margin-bottom: 0.5rem;
    line-height: 1.4;
  }

  .footer-social a {
    width: 2.25rem;
    height: 2.25rem;
  }

  .footer-title {
    font-size: 0.8125rem;
    margin-bottom: 0.25rem;
  }

  .footer-link {
    font-size: 0.8125rem;
    padding: 0.0625rem 0;
    line-height: 1.3;
  }

  .footer-bottom {
    padding-top: 0.875rem;
  }
}

@media (min-width: 768px) {
  .footer-bottom {
    text-align: left;
  }
}
