/* ==========================================================================
   COMPONENTS — header, footer, botão flutuante de WhatsApp e cards genéricos
   Zanette & Zanette Advogados
   ========================================================================== */

/* --------------------------------------------------------------------------
   HEADER
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--branco);
  box-shadow: var(--sombra);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding-block: .6rem;
}

.header-logo {
  flex-shrink: 0;
  display: flex;
}

.header-logo img {
  height: 63px;
  width: auto;
}

/* --- Menu de navegação (mobile-first: painel lateral) ------------------- */
.nav-menu {
  position: fixed;
  top: 0;
  right: -100%;
  height: 100vh;
  width: min(320px, 85vw);
  background-color: var(--azul-marinho);
  padding: 5.5rem 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow-y: auto;
  transition: right .3s ease;
}

.nav-menu.nav-aberto {
  right: 0;
  box-shadow: -12px 0 30px rgba(0, 0, 0, .3);
}

.nav-item a,
.nav-dropdown-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  width: 100%;
  padding: .9rem 0;
  color: var(--branco);
  font-weight: 600;
  font-size: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  text-align: left;
}

.nav-dropdown-seta {
  flex-shrink: 0;
  transition: transform .25s ease;
}

.nav-item-dropdown.aberto .nav-dropdown-seta {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  max-height: 0;
  overflow: hidden;
  padding-left: 1rem;
  transition: max-height .3s ease;
}

/* Regra de abertura do mobile isolada em max-width para não vazar pro
   desktop (lá o mecanismo é display:none/block, ver media query abaixo). */
@media (max-width: 1023.98px) {
  .nav-item-dropdown.aberto .nav-dropdown-menu {
    max-height: 400px;
  }
}

.nav-dropdown-menu li a {
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  font-weight: 500;
  font-size: .92rem;
  color: var(--dourado-claro);
}

.header-cta {
  flex-shrink: 0;
  display: none;
}

/* --- Hambúrguer (visível apenas no mobile) ------------------------------ */
.header-hamburguer {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  padding: 0;
  z-index: 1100;
}

.header-hamburguer span {
  display: block;
  width: 100%;
  height: 2.5px;
  background-color: var(--azul-marinho);
  border-radius: 2px;
  transition: transform .25s ease, opacity .25s ease;
}

.header-hamburguer.ativo span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.header-hamburguer.ativo span:nth-child(2) { opacity: 0; }
.header-hamburguer.ativo span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* --- Desktop (≥1024px): menu horizontal, dropdown em hover -------------- */
@media (min-width: 1024px) {
  .nav-menu {
    position: static;
    flex-direction: row;
    align-items: center;
    height: auto;
    width: auto;
    overflow: visible;
    background: none;
    padding: 0;
    gap: clamp(1rem, 2.2vw, 1.85rem);
    right: auto;
  }

  .nav-item a,
  .nav-dropdown-toggle {
    width: auto;
    color: var(--azul-marinho);
    border-bottom: none;
    padding: .5rem 0;
    font-size: .95rem;
  }

  .nav-item-dropdown {
    position: relative;
  }

  .nav-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    max-height: none;
    overflow: visible;
    background-color: var(--branco);
    box-shadow: var(--sombra);
    border-radius: var(--radius);
    padding: .5rem;
    min-width: 280px;
  }

  .nav-item-dropdown:hover .nav-dropdown-menu,
  .nav-item-dropdown.aberto .nav-dropdown-menu {
    display: block;
  }

  .nav-dropdown-menu li a {
    color: var(--azul-marinho);
    padding: .65rem .8rem;
    border-bottom: none;
    border-radius: 8px;
  }

  .nav-dropdown-menu li a:hover {
    background-color: var(--cinza-claro);
  }

  .header-cta {
    display: inline-flex;
  }

  .header-hamburguer {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  background-color: var(--azul-profundo);
  color: var(--branco);
  padding-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
}

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

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

.footer-logo {
  height: 144px;
  width: auto;
  margin-bottom: 1.4rem;
}

.footer-descricao {
  font-size: .9rem;
  color: rgba(255, 255, 255, .75);
}

.footer-oab {
  font-size: .82rem;
  color: var(--dourado-claro);
  font-weight: 600;
  margin-top: .5rem;
}

.footer-col h4 {
  color: var(--dourado);
  font-size: .95rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: .65rem;
}

.footer-col a {
  color: rgba(255, 255, 255, .85);
  font-size: .92rem;
  transition: color .2s ease;
}

.footer-col a:hover {
  color: var(--dourado-claro);
}

.footer-enderecos li {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .15rem;
  font-size: .87rem;
  color: rgba(255, 255, 255, .7);
  padding-bottom: .9rem;
  margin-bottom: .9rem;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.footer-enderecos li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.footer-enderecos li strong {
  color: var(--branco);
  font-size: .92rem;
}

/* --------------------------------------------------------------------------
   BOTÃO "VER NO MAPA" — logo abaixo do endereço/CEP, no rodapé e nos
   cards de "Nossos escritórios" (sobre.html). A cor muda conforme o
   fundo (aqui, escuro); a variante clara fica em pages.css junto do
   .escritorio-card.
   -------------------------------------------------------------------------- */
.btn-ver-mapa {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  margin-top: .75rem;
  padding: .45rem .9rem;
  border-radius: 999px;
  border: 1.5px solid currentColor;
  font-size: .95rem;
  font-weight: 600;
  transition: background-color .2s ease, color .2s ease, opacity .2s ease;
}

.footer-enderecos .btn-ver-mapa {
  color: var(--dourado-claro);
}

.footer-enderecos .btn-ver-mapa:hover,
.footer-enderecos .btn-ver-mapa:focus-visible {
  background-color: var(--dourado-claro);
  color: var(--azul-marinho);
}

/* Reforço pra faixas estreitas onde o botão ainda divide espaço em
   2 colunas (ex.: 481–639px nos cards de escritório): um pouco menos
   de padding/gap, sem mexer no tamanho da fonte (que precisa continuar
   igual ou maior que o resto do texto). */
@media (max-width: 639.98px) {
  .btn-ver-mapa {
    gap: .3rem;
    padding: .4rem .7rem;
  }
}

.footer-redes {
  display: flex;
  gap: .85rem;
  margin-top: 1.35rem;
}

.footer-redes a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, .08);
  color: var(--branco);
  transition: background-color .2s ease, color .2s ease;
}

.footer-redes a:hover {
  background-color: var(--dourado);
  color: var(--azul-marinho);
}

/* No mobile o rodapé fica centralizado (logo, OAB, cada coluna e as
   redes sociais); no desktop (>=1024px) continua alinhado à esquerda,
   sem nenhuma regra daqui entrando em jogo. */
@media (max-width: 1023.98px) {
  .footer-sobre,
  .footer-col {
    text-align: center;
  }

  .footer-logo {
    margin-inline: auto;
  }

  .footer-col ul,
  .footer-enderecos li {
    align-items: center;
  }

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12);
  padding-block: 1.75rem;
}

.footer-bottom .container {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  text-align: center;
}

.footer-legal {
  font-size: .78rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, .6);
  max-width: 820px;
  margin-inline: auto;
}

.footer-copyright {
  font-size: .78rem;
  color: rgba(255, 255, 255, .45);
}

@media (min-width: 640px) {
  .footer-bottom .container {
    text-align: left;
    margin-inline: 0;
  }

  .footer-legal {
    margin-inline: 0;
  }
}

/* --------------------------------------------------------------------------
   BOTÃO FLUTUANTE DE WHATSAPP
   -------------------------------------------------------------------------- */
.whats-flutuante {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background-color: var(--verde-whats-botao);
  color: var(--branco);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(37, 211, 102, .45);
  z-index: 1200;
  animation: pulso-whats 2.4s ease-in-out infinite;
  transition: transform .2s ease;
}

.whats-flutuante:hover {
  transform: scale(1.08);
}

@keyframes pulso-whats {
  0% { box-shadow: 0 6px 20px rgba(37, 211, 102, .45), 0 0 0 0 rgba(37, 211, 102, .5); }
  70% { box-shadow: 0 6px 20px rgba(37, 211, 102, .45), 0 0 0 16px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 6px 20px rgba(37, 211, 102, .45), 0 0 0 0 rgba(37, 211, 102, 0); }
}

@media (min-width: 640px) {
  .whats-flutuante {
    right: 2rem;
    bottom: 2rem;
    width: 62px;
    height: 62px;
  }
}

/* --------------------------------------------------------------------------
   CARDS GENÉRICOS
   -------------------------------------------------------------------------- */
.card {
  background-color: var(--branco);
  border-radius: var(--radius);
  box-shadow: var(--sombra);
  padding: 2rem 1.75rem;
  transition: transform .25s ease, box-shadow .25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 40px rgba(10, 31, 60, .16);
}

.card-icone {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background-color: var(--cinza-claro);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.card-icone img {
  width: 28px;
  height: 28px;
}

.card h3 {
  margin-bottom: .65rem;
}

.card p {
  font-size: .94rem;
  color: var(--cinza-texto);
  margin-bottom: 1rem;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-weight: 600;
  font-size: .9rem;
  color: var(--dourado-texto);
}
