/* ==========================
   MENU FLUTUANTE (PILL)
   ========================== */
.main-header {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%); /* Puxa o menu perfeitamente para o centro */
  width: calc(100% - 40px); /* Mantém uma margem de segurança no mobile */
  max-width: 1160px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-radius: var(--border-radius-pill);
  box-shadow: var(--shadow-card);
  z-index: 1000;
  transition: all 0.3s ease;
}

.header-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 25px;
}

.logo img {
  height: 35px;
  display: block;
}

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
}

.nav-links a {
  color: var(--color-dark);
  font-weight: var(--weight-medium);
  font-size: 0.95rem;
  text-decoration: none !important; /* Força remoção de linhas no menu */
  transition: color 0.3s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-primary);
}

/* FOOTER */
.main-footer {
  background-color: #020e1d; /* Tom ainda mais escuro para o rodapé */
  color: var(--color-white);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}

.footer-logo {
  height: 45px;
  margin-bottom: 20px;
}
.footer-brand p {
  color: #8a9bae;
  font-weight: var(--weight-light);
}

.footer-links h4,
.footer-social h4 {
  margin-bottom: 20px;
  font-weight: var(--weight-regular);
}
.footer-links ul,
.footer-social ul {
  list-style: none;
}
.footer-links li,
.footer-social li {
  margin-bottom: 12px;
}
.footer-links a,
.footer-social a {
  color: #8a9bae;
  font-weight: var(--weight-light);
}
.footer-links a:hover,
.footer-social a:hover {
  color: var(--color-white);
}
/* ==========================
   MENU FLUTUANTE (PILL)
   ========================== */
.floating-header-wrapper {
  position: fixed;
  top: 20px;
  left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  justify-content: center;
  padding: 0 20px;
  pointer-events: none; /* Permite clicar nos espaços vazios ao lado do menu */
}

.main-header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-radius: var(--border-radius-pill);
  width: 100%;
  max-width: 1160px;
  box-shadow: var(--shadow-card);
  pointer-events: auto; /* Reativa o clique no menu */
  transition: all 0.3s ease;
}

.header-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 25px;
}

.logo img {
  height: 35px;
  display: block;
}

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
}

.nav-links a {
  color: var(--color-dark);
  font-weight: var(--weight-medium);
  font-size: 0.95rem;
  text-decoration: none !important;
  border: none !important;
  transition: color 0.3s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-primary);
}

/* ==========================
   RODAPÉ (FOOTER)
   ========================== */
.main-footer {
  background-color: var(--color-dark);
  color: var(--color-white);
  padding: 80px 0 40px;
  position: relative;
  overflow: hidden;
}

/* Detalhe de fundo suave no rodapé */
.main-footer::before {
  content: "";
  position: absolute;
  top: -150px;
  right: -100px;
  width: 400px;
  height: 400px;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.03) 0%,
    transparent 70%
  );
  border-radius: 50%;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 50px;
  position: relative;
  z-index: 2;
}

.footer-logo {
  height: 45px;
  margin-bottom: 25px;
}

.footer-brand p {
  color: #a0aec0;
  font-weight: var(--weight-regular);
  max-width: 300px;
  font-size: 0.95rem;
}

.footer-links h4,
.footer-social h4 {
  margin-bottom: 25px;
  font-weight: var(--weight-semibold);
  font-size: 1.1rem;
  color: var(--color-white);
}

.footer-links ul,
.footer-social ul {
  list-style: none;
}

.footer-links li,
.footer-social li {
  margin-bottom: 15px;
}

.footer-links a,
.footer-social a {
  color: #a0aec0;
  font-weight: var(--weight-regular);
  font-size: 0.95rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-links a:hover,
.footer-social a:hover {
  color: var(--color-white);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #718096;
  font-size: 0.85rem;
}

/* ==========================================
   MENU MOBILE + RESPONSIVE HEADER/FOOTER
   ========================================== */

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: none;
  border-radius: 12px;
  background: var(--color-light);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.3s;
}

.nav-toggle:hover {
  background: #e2e8f0;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--color-dark);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.btn-header-cta {
  padding: 10px 24px !important;
  font-size: 0.9rem !important;
  white-space: nowrap;
  flex-shrink: 0;
}

body.nav-open {
  overflow: hidden;
}

@media (max-width: 991px) {
  .floating-header-wrapper {
    top: 12px;
    padding: 0 12px;
  }

  .main-header {
    border-radius: 24px;
  }

  .header-wrapper {
    padding: 10px 16px;
    gap: 12px;
    flex-wrap: wrap;
  }

  .logo img {
    height: 30px;
  }

  .nav-toggle {
    display: flex;
    margin-left: auto;
  }

  .header-nav {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
    order: 3;
    padding: 8px 0 4px;
    border-top: 1px solid #e2e8f0;
    margin-top: 4px;
  }

  .header-nav.is-open {
    display: flex;
  }

  .nav-links {
    flex-direction: column;
    gap: 0;
    width: 100%;
  }

  .nav-links li {
    border-bottom: 1px solid #f0f4f8;
  }

  .nav-links a {
    display: block;
    padding: 14px 4px;
    font-size: 1rem;
  }

  .btn-header-cta {
    width: 100%;
    margin-top: 12px;
    justify-content: center;
  }

  .main-footer {
    padding: 56px 0 32px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 36px;
    margin-bottom: 36px;
  }

  .footer-brand p {
    max-width: none;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

@media (max-width: 767px) {
  .floating-header-wrapper {
    top: 8px;
    padding: 0 8px;
  }

  .header-wrapper {
    padding: 8px 12px;
  }

  .main-footer {
    padding: 28px 0 16px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px 20px;
    margin-bottom: 16px;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-logo {
    height: 32px;
    margin-bottom: 10px;
  }

  .footer-brand p {
    font-size: 0.8rem;
    line-height: 1.45;
    margin: 0;
  }

  .footer-links h4,
  .footer-social h4 {
    margin-bottom: 8px;
    font-size: 0.85rem;
  }

  .footer-links li,
  .footer-social li {
    margin-bottom: 6px;
  }

  .footer-links a,
  .footer-social a {
    font-size: 0.78rem;
    gap: 6px;
  }

  .footer-links a i,
  .footer-social a i {
    font-size: 0.75rem;
  }

  .footer-bottom {
    padding-top: 12px;
    gap: 4px;
    font-size: 0.72rem;
  }

  .footer-bottom p:last-child {
    display: none;
  }
}

/* Botão flutuante WhatsApp */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1100;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25d366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.45);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.whatsapp-float img {
  width: 28px;
  height: 28px;
  filter: brightness(0) invert(1);
}

.whatsapp-float:hover {
  transform: scale(1.06);
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.55);
}

@media (max-width: 767px) {
  .whatsapp-float {
    bottom: 16px;
    right: 16px;
    width: 52px;
    height: 52px;
  }

  .whatsapp-float img {
    width: 26px;
    height: 26px;
  }
}

@media (min-width: 992px) {
  .header-wrapper {
    gap: 24px;
  }

  .header-nav {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 28px;
  }

  .nav-links {
    margin-right: auto;
  }
}
