.site-footer {
  background-color: var(--color-primary);
  color: var(--white);
  position: relative;
  width: 100%;
  margin-top: 2rem;
  font-family: var(--font-body);
}

/* Container de Fundo SVG Rotativo */
.footer-bg-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

.footer-bg-container svg {
  position: absolute;
  pointer-events: none;
  top: 50%;
  left: 50%;
  width: 1900px;
  height: 1900px;
  transform: translate(-50%, -50%) rotate(0deg);
  opacity: 0.1; /* Bem sutil para não interferir nos textos */
  animation: rotate-footer-bg 70s linear infinite;
  transform-origin: center center;
}

@keyframes rotate-footer-bg {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Container da onda SVG e Logo */
.footer-wave-container {
  position: relative;
  width: 100%;
  height: 80px;
  background-color: transparent;
  margin-top: -80px;
  overflow: visible;
  z-index: 3; /* Fica acima do fundo rotativo */
}

.footer-wave-container svg {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 80px;
  display: block;
}

/* Distintivo do Logo simplificado flutuante */
.footer-logo-badge {
  position: absolute;
  bottom: 35px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  background-color: var(--color-primary);
  padding: 22px;
  border-radius: 50%;
  width: 90px;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer-logo-badge img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

/* Container de Conteúdo */
.footer-content-container {
  padding: 3.5rem 1.2rem 2rem 1.2rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  text-align: left; /* Alinhado à esquerda no mobile */
  position: relative;
  z-index: 2; /* Fica acima do fundo rotativo */
}

/* Ordem das Colunas no Mobile */
.footer-col-links {
  order: 1;
}
.footer-col-contact {
  order: 2;
}
.footer-col-main {
  order: 3;
}

/* Colunas do Rodapé */
.footer-col h3 {
  color: var(--white);
  font-family: var(--font-title);
  font-size: var(--font-size-h2);
  font-weight: 600;
  margin-bottom: 0.5rem;
  position: relative;
  display: inline-block;
  line-height: var(--lh-title);
}

/* Coluna Contato */
.footer-col-contact .footer-address {
  font-size: var(--font-size-body);
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 0.8rem;
  line-height: var(--lh-body);
}

.footer-col-contact .footer-phone,
.footer-col-contact .footer-email {
  font-size: var(--font-size-body);
  font-weight: 500;
  margin-bottom: 0.6rem;
}

.footer-col-contact a {
  color: var(--white);
  opacity: 1;
  transition: opacity 0.2s ease;
}

.footer-col-contact a:hover {
  opacity: 0.8;
}

.footer-socials {
  display: flex;
  justify-content: flex-start; /* Alinhado à esquerda no mobile */
  gap: 1rem;
}

.footer-socials .social-link {
  font-size: var(--font-size-body);
  font-weight: 500;
  color: var(--white);
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.footer-socials .social-link:hover {
  color: var(--white);
  opacity: 0.85;
}

.footer-socials .social-link .arrow-svg {
  display: inline-block;
  vertical-align: middle;
  transition: transform 0.2s ease;
}

.footer-socials .social-link:hover .arrow-svg {
  transform: translateX(3px);
}

/* Coluna Central / Principal */
.footer-col-main .footer-title {
  color: var(--white);
  font-family: var(--font-title);
  font-size: var(--font-size-h1);
  font-weight: 700;
  line-height: var(--lh-title);
  margin-bottom: 0.8rem;
}

.footer-col-main .footer-tagline {
  font-size: var(--font-size-body-sm);
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2rem;
  line-height: var(--lh-body);
}

/* Coluna Links */
.footer-menu {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-menu a {
  color: var(--color-bg-canvas);
  font-size: var(--font-size-body);
  transition:
    color 0.2s ease,
    padding-left 0.2s ease;
  display: inline-block;
}

.footer-menu a:hover {
  color: var(--white);
}

/* Barra inferior (Copyright & Políticas) na cor da marca sobre fundo claro */
.footer-bottom-bar {
  background-color: transparent;
  padding: 0.8rem 1rem;
  position: relative;
  z-index: 1; /* Fica acima do fundo rotativo */
}

.footer-bottom-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--font-size-legend);
  color: #ffffff;
  font-weight: 400;
  opacity: 0.9;
}

.policy-link {
  color: #ffffff;
  opacity: 0.9;
  transition: opacity 0.2s ease;
}

.policy-link:hover {
  opacity: 1;
}

.footer-copyright {
  text-align: center;
}

/* Media Queries para Telas Maiores (Desktop / Tablets) */
@media (min-width: 769px) {
  .site-footer {
    margin-top: 4rem;
  }

  .footer-wave-container {
    height: 100px;
    margin-top: -100px;
  }

  .footer-logo-badge {
    bottom: 30px;
    width: 150px;
    height: auto;
  }

  .footer-content-container {
    max-width: 1520px;
    margin: 0 auto;
    padding: 5rem 1.5rem 4rem 1.5rem;
    grid-template-columns: 1fr 1.3fr 1fr;
    gap: 2rem;
    text-align: left;
    justify-content: center;
  }

  /* Alinhamentos Desktop */
  .footer-col-contact {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    order: 0; /* Restaura ordem padrão no desktop */
  }

  .footer-socials {
    justify-content: flex-start;
  }

  .footer-col-main {
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    order: 0; /* Restaura ordem padrão no desktop */
  }

  .footer-col-main .footer-title {
    line-height: var(--lh-title);
  }

  .footer-col-links {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    order: 0; /* Restaura ordem padrão no desktop */
  }

  .footer-menu {
    align-items: flex-end;
  }

  .footer-bottom-container {
    flex-direction: row;
    justify-content: center;
    width: 100%;
  }

  .footer-copyright {
    align-items: center;
    justify-content: center;
    text-align: center;
    display: flex;
    gap: 0.7rem;
  }
}

/* Margem ajustada especificamente quando o rodapé vem logo após a Galeria 3D (evita colisão com elementos 3D) */
.galeria-3d + .site-footer {
  margin-top: 10rem;
}

@media (min-width: 769px) {
  .galeria-3d + .site-footer {
    margin-top: 18rem;
  }
}
