/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f1f5f9;
  color: #ffffff;
}

/* Rodapé principal */
.footer {
  position: relative;
  background: linear-gradient(180deg, #0b7a45 0%, #0a3d24 100%);
  padding: 0;
  margin-top: 40px;
  overflow-x: hidden;
}

/* Onda decorativa no topo do rodapé */
.footer-wave {
  position: absolute;
  top: -59px;
  left: 0;
  width: 100%;
  line-height: 0;
  transform: translateY(1px);
}

.footer-wave svg {
  width: 100%;
  height: 60px;
  display: block;
}

.footer-wave path {
  fill: #0b7a45;
}

.footer-top {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding: 55px 20px 30px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  align-items: start;
  gap: 40px;
}

.footer-grid>* {
  min-width: 0;
}

.footer-col h3,
.footer-brand h2 {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 18px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1.2;
  position: relative;
  padding-bottom: 10px;
}

.footer-col h3::after,
.footer-brand h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 34px;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.55);
}

.footer-brand h2 {
  font-size: 18px;
  margin: 0;
  padding-bottom: 0;
  min-width: 0;
  white-space: normal;
  overflow-wrap: break-word;
}

.footer-brand h2::after {
  display: none;
}

.footer-brand__head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.footer-brand__logo {
  height: 64px;
  width: 64px;
  object-fit: contain;
  background: transparent;
  flex-shrink: 0;
}

.footer-brand p {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.7;
}

.footer-social {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.footer-social a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  background: #ffffff;
  color: #0b7a45;
  transform: translateY(-4px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.2);
}

/* Listas de links */
.footer-links {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  transition: color 0.3s ease, gap 0.3s ease, padding-left 0.3s ease;
}

.footer-links a i {
  font-size: 10px;
  width: 16px;
  flex-shrink: 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.55);
  transition: transform 0.3s ease;
}

.footer-links a:hover {
  color: #ffffff;
  padding-left: 4px;
}

.footer-links a:hover i {
  color: #ffffff;
  transform: translateX(3px);
}

/* Bloco de contato */
.footer-contact {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
  margin-bottom: 16px;
  min-width: 0;
}

.footer-contact li>span,
.footer-contact li {
  overflow-wrap: break-word;
  word-break: break-word;
}

.footer-contact li i {
  color: rgba(255, 255, 255, 0.55);
  width: 16px;
  text-align: center;
  margin-top: 3px;
  flex-shrink: 0;
}

.footer-contact a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
}

.footer-contact a:hover {
  color: #ffffff;
  text-decoration: underline;
}

/* Metadados */
.footer-meta {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 15px 20px;
  display: flex;
  justify-content: center;
  gap: 40px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-meta i {
  color: rgba(255, 255, 255, 0.6);
  margin-right: 5px;
}

/* Créditos */
.footer-creditos {
  background-color: #082a19;
  padding: 18px 20px;
  text-align: center;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-creditos a {
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: color 0.3s ease;
}

.footer-creditos a:hover {
  color: #ffffff;
}

.footer-creditos img {
  height: 22px;
}

/* Botão Voltar ao Topo */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: #0b7a45;
  color: #ffffff;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: all 0.3s ease;
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: #0f9d58;
  transform: translateY(-4px);
}

@media (max-width: 991px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 30px 40px;
  }
}

@media (max-width: 768px) {
  .footer-wave {
    top: -29px;
  }

  .footer-wave svg {
    height: 30px;
  }

  .footer-top {
    padding: 40px 20px 20px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
    text-align: center;
  }

  .footer-col h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

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

  .footer-links a {
    justify-content: center;
  }

  .footer-contact li {
    justify-content: center;
    text-align: left;
  }

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

  .footer-meta {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .back-to-top {
    right: 16px;
    bottom: 16px;
    width: 42px;
    height: 42px;
  }
}
