/* ==========================================================================
   Agência Pet — cabeçalho, menu mobile, rodapé e botões flutuantes
   Copiado do Site Brasil (layout.css). Na loja o HTML do cabeçalho/rodapé vem do build (templates/layout.js).
   Todas as classes começam com "ap-" para não colidir com o CSS de cada página.
   ========================================================================== */

:root {
  --ap-header-h: 80px;
  --ap-maxw: 1200px;
  --ap-gutter: clamp(20px, 5vw, 48px);
  --ap-font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ap-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --ap-purple-50: #F5F0FB;
  --ap-purple-400: #9668D2;
  --ap-purple-500: #7A45C4;
  --ap-purple-600: #5E2BA8;
  --ap-purple-700: #4A208A;
  --ap-teal-50: #E6F7F8;
  --ap-teal-300: #4EC1CA;
  --ap-teal-400: #22A8B3;
  --ap-teal-500: #0B8D99;
  --ap-teal-600: #006F7A;
  --ap-teal-700: #00555E;
  --ap-ink-950: #14101C;
  --ap-ink-700: #4A4358;
  --ap-ink-200: #E9E7ED;
  --ap-danger: #D44C4C;
  --ap-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ap-ring: 0 0 0 3px rgba(122, 69, 196, 0.25);
}

.ap-header,
.ap-mobile-menu,
.ap-footer {
  font-family: var(--ap-font);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

.ap-header *,
.ap-mobile-menu *,
.ap-footer *,
.ap-wa-float,
.ap-to-top {
  box-sizing: border-box;
}

.ap-header a,
.ap-mobile-menu a,
.ap-footer a {
  text-decoration: none;
}

.ap-wrap {
  width: 100%;
  max-width: var(--ap-maxw);
  margin-inline: auto;
  padding-inline: var(--ap-gutter);
}

/* ---------- botões ---------- */
.ap-btn {
  font-family: var(--ap-font);
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1;
  padding: 14px 24px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
  transition: background 200ms var(--ap-ease), box-shadow 200ms var(--ap-ease), transform 120ms var(--ap-ease);
}

.ap-btn svg {
  width: 18px;
  height: 18px;
  transition: transform 200ms var(--ap-ease);
}

.ap-btn:focus-visible {
  outline: none;
  box-shadow: var(--ap-ring);
}

.ap-header .ap-btn-teal,
.ap-footer .ap-btn-teal {
  background: var(--ap-teal-500);
  color: #fff;
  box-shadow: 0 12px 30px rgba(11, 141, 153, .28);
}

.ap-header .ap-btn-teal:hover,
.ap-footer .ap-btn-teal:hover {
  background: var(--ap-teal-600);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(11, 141, 153, .42);
}

.ap-header .ap-btn-teal:hover svg {
  transform: translateX(3px);
}

.ap-footer .ap-btn-wa,
.ap-mobile-menu .ap-btn-wa {
  background: #1FAE54;
  color: #fff;
  box-shadow: 0 10px 26px rgba(31, 174, 84, .32);
}

.ap-footer .ap-btn-wa:hover,
.ap-mobile-menu .ap-btn-wa:hover {
  background: #189447;
  color: #fff;
}

/* ==========================================================================
   CABEÇALHO
   ========================================================================== */
.ap-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--ap-header-h);
  z-index: 100;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, .72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: background 200ms var(--ap-ease), box-shadow 200ms var(--ap-ease), border-color 200ms var(--ap-ease);
}

.ap-header.scrolled {
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 2px 6px rgba(38, 15, 71, 0.06), 0 1px 2px rgba(38, 15, 71, 0.04);
  border-bottom-color: var(--ap-ink-200);
}

/* reserva o espaço do cabeçalho fixo para o conteúdo não ficar escondido embaixo dele */
.ap-header-space {
  height: var(--ap-header-h);
}

.ap-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.ap-brand {
  flex: none;
}

.ap-brand img {
  height: 40px;
  width: auto;
  display: block;
}

.ap-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, .6);
  border: 1px solid rgba(20, 16, 28, .1);
  padding: 6px;
  border-radius: 999px;
}

.ap-header .ap-nav-link {
  font-family: var(--ap-font);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ap-ink-700);
  padding: 9px 16px;
  border-radius: 999px;
  background: none;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: background 200ms var(--ap-ease), color 200ms var(--ap-ease);
}

.ap-header .ap-nav-link:hover {
  color: var(--ap-ink-950);
  background: rgba(20, 16, 28, .05);
}

.ap-header .ap-nav-link:focus-visible {
  outline: none;
  box-shadow: var(--ap-ring);
}

.ap-header .ap-nav-link.active,
.ap-header .ap-nav-link.active:hover {
  background: var(--ap-ink-950);
  color: #fff;
}

.ap-nav-link svg {
  width: 14px;
  height: 14px;
  transition: transform 200ms var(--ap-ease);
}

.ap-has-drop {
  position: relative;
}

.ap-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  padding-top: 12px;
  transform: translateX(-50%) translateY(8px);
  opacity: 0;
  visibility: hidden;
  transition: all 200ms var(--ap-ease);
  z-index: 30;
}

.ap-dropdown-panel {
  background: #fff;
  border: 1px solid var(--ap-ink-200);
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(38, 15, 71, 0.10), 0 4px 8px rgba(38, 15, 71, 0.04);
  padding: 8px;
  min-width: 260px;
}

.ap-has-drop:hover .ap-dropdown,
.ap-has-drop:focus-within .ap-dropdown,
.ap-has-drop.open .ap-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.ap-has-drop:hover .ap-nav-link svg,
.ap-has-drop.open .ap-nav-link svg {
  transform: rotate(180deg);
}

.ap-header .ap-dropdown a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ap-ink-700);
  transition: background 120ms var(--ap-ease), color 120ms var(--ap-ease);
}

.ap-header .ap-dropdown a:hover,
.ap-header .ap-dropdown a.active {
  background: var(--ap-teal-50);
  color: var(--ap-teal-700);
}

.ap-dropdown a svg {
  width: 17px;
  height: 17px;
  color: var(--ap-teal-600);
  flex: none;
}

.ap-header-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ap-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ap-ink-950);
  padding: 4px;
}

.ap-menu-toggle svg {
  width: 26px;
  height: 26px;
  display: block;
}

/* ---------- menu mobile ---------- */
.ap-mobile-menu {
  position: fixed;
  inset: var(--ap-header-h) 0 0 0;
  background: #fff;
  z-index: 99;
  transform: translateX(100%);
  visibility: hidden;
  transition: transform 320ms var(--ap-ease), visibility 320ms;
  display: flex;
  flex-direction: column;
  padding: 32px var(--ap-gutter);
  gap: 8px;
  overflow-y: auto;
}

.ap-mobile-menu.open {
  transform: translateX(0);
  visibility: visible;
}

.ap-mobile-menu a:not(.ap-btn) {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -.02em;
  text-transform: lowercase;
  color: var(--ap-ink-950);
  padding: 16px 0;
  border-bottom: 1px solid var(--ap-ink-200);
}

.ap-mobile-menu a.ap-sub {
  font-size: 1.125rem;
  font-weight: 600;
  text-transform: none;
  padding-left: 16px;
  color: var(--ap-ink-700);
}

.ap-mobile-menu a.active {
  color: var(--ap-purple-600);
}

.ap-mobile-menu .ap-btn {
  margin-top: 24px;
  justify-content: center;
}

/* ==========================================================================
   RODAPÉ
   ========================================================================== */
.ap-footer {
  background: var(--ap-ink-950);
  color: rgba(255, 255, 255, .7);
  padding-top: clamp(56px, 8vw, 90px);
}

.ap-footer-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(32px, 6vw, 80px);
}

.ap-foot-h {
  font-family: var(--ap-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ap-teal-300);
  margin: 0 0 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ap-foot-h::after {
  content: "";
  height: 1px;
  flex: 1;
  background: rgba(255, 255, 255, .12);
}

.ap-addr-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.ap-addr-tab {
  font-family: var(--ap-font);
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .7);
  padding: 9px 16px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 200ms var(--ap-ease);
}

.ap-addr-tab.active {
  background: rgba(122, 69, 196, .25);
  border-color: var(--ap-purple-400);
  color: #fff;
}

.ap-addr-body {
  display: none;
  font-size: 0.9375rem;
  line-height: 1.9;
  color: rgba(255, 255, 255, .72);
}

.ap-addr-body.active {
  display: block;
}

.ap-addr-body .ap-nm {
  color: #fff;
  font-weight: 700;
}

.ap-foot-lead {
  margin: 0 0 24px;
  font-weight: 600;
  color: #fff;
  font-size: 1.125rem;
}

.ap-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.ap-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ap-field.full {
  grid-column: 1 / -1;
}

.ap-field>label {
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, .85);
}

.ap-req {
  color: var(--ap-danger);
}

.ap-field input[type=text],
.ap-field input[type=tel] {
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .05);
  color: #fff;
  font-size: 0.9375rem;
  font-family: var(--ap-font);
  transition: all 200ms var(--ap-ease);
}

.ap-field input::placeholder {
  color: rgba(255, 255, 255, .4);
}

.ap-field input:focus {
  outline: none;
  border-color: var(--ap-teal-400);
  background: rgba(255, 255, 255, .09);
}

.ap-field input.invalid {
  border-color: var(--ap-danger);
}

.ap-ferr {
  font-size: 0.75rem;
  color: #FF9A9A;
}

.ap-ferr:empty {
  display: none;
}

.ap-radio-row {
  display: flex;
  gap: 18px;
  padding-top: 6px;
}

.ap-radio-row label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  cursor: pointer;
  color: rgba(255, 255, 255, .85);
}

.ap-radio-row input {
  accent-color: var(--ap-teal-400);
  width: 18px;
  height: 18px;
  margin: 0;
}

.ap-consent {
  grid-column: 1 / -1;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, .7);
  cursor: pointer;
}

.ap-footer .ap-consent a {
  color: var(--ap-teal-300);
  text-decoration: underline;
}

.ap-consent.invalid {
  color: var(--ap-danger);
}

.ap-consent input {
  margin: 3px 0 0;
  accent-color: var(--ap-teal-400);
  width: 17px;
  height: 17px;
}

.ap-form-note {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, .5);
}

.ap-form .ap-btn {
  grid-column: 1 / -1;
  justify-content: center;
  padding: 17px 30px;
  font-size: 1rem;
}

.ap-hp {
  position: absolute !important;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.ap-form-err {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.875rem;
  color: #FF9A9A;
}

.ap-form-err a {
  color: #fff;
  text-decoration: underline;
}

.ap-form-err[hidden] {
  display: none;
}

.ap-form-ok {
  grid-column: 1 / -1;
  display: none;
  align-items: center;
  gap: 10px;
  background: rgba(43, 182, 115, .16);
  border: 1px solid rgba(43, 182, 115, .45);
  color: #b8f0d5;
  padding: 14px 18px;
  border-radius: 10px;
  font-weight: 600;
}

.ap-form-ok svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.ap-form-ok.show {
  display: flex;
}

.ap-foot-links {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  justify-content: center;
  padding-block: 32px;
  margin-top: 48px;
  border-top: 1px solid rgba(255, 255, 255, .1);
}

.ap-footer .ap-foot-links a {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, .6);
  transition: color 200ms var(--ap-ease);
}

.ap-footer .ap-foot-links a:hover {
  color: #fff;
}

.ap-foot-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 32px;
  border-top: 1px solid rgba(255, 255, 255, .1);
  flex-wrap: wrap;
}

.ap-foot-brand img {
  height: 30px;
  width: auto;
  display: block;
}

.ap-foot-copy {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, .55);
  text-align: center;
  flex: 1 1 auto;
}

.ap-foot-social {
  display: flex;
  gap: 10px;
}

.ap-footer .ap-foot-social a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .75);
  transition: all 200ms var(--ap-ease);
}

.ap-footer .ap-foot-social a:hover {
  background: #1FAE54;
  border-color: #1FAE54;
  color: #fff;
  transform: translateY(-2px);
}

.ap-foot-social svg {
  width: 18px;
  height: 18px;
}

.ap-nowrap {
  white-space: nowrap;
}

/* ==========================================================================
   BOTÕES FLUTUANTES · WhatsApp à direita, voltar ao topo empilhado acima
   ========================================================================== */
.ap-wa-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #1FAE54;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 10px 30px rgba(31, 174, 84, .45);
  z-index: 90;
  transition: transform 200ms var(--ap-ease);
}

.ap-wa-float:hover {
  color: #fff;
  transform: scale(1.08);
}

.ap-wa-float svg {
  width: 30px;
  height: 30px;
}

.ap-to-top {
  position: fixed;
  bottom: 92px;
  right: 28px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--ap-purple-600);
  color: #fff;
  border: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 32px rgba(94, 43, 168, 0.28);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 200ms var(--ap-ease);
  z-index: 90;
}

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

.ap-to-top:hover {
  background: var(--ap-purple-700);
  transform: translateY(-3px);
}

.ap-to-top svg {
  width: 22px;
  height: 22px;
}

/* ==========================================================================
   RESPONSIVO
   ========================================================================== */
/* telas médias: itens do menu mais próximos */
@media (max-width: 1240px) {
  .ap-header .ap-nav-link {
    padding: 9px 12px;
  }

  .ap-header-inner {
    gap: 16px;
  }
}

/* a partir daqui o menu vira o botão de menu (☰) */
@media (max-width: 1100px) {
  .ap-nav {
    display: none;
  }

  .ap-menu-toggle {
    display: grid;
    place-items: center;
  }
}

@media (max-width: 1000px) {
  .ap-header-cta .ap-full {
    display: none;
  }

  .ap-header-cta .ap-btn {
    padding: 14px;
  }

  .ap-footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .ap-form {
    grid-template-columns: 1fr;
  }

  .ap-foot-bottom {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {

  .ap-header *,
  .ap-mobile-menu,
  .ap-wa-float,
  .ap-to-top {
    transition: none !important;
  }
}
