@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
  color-scheme: light dark;
  
  /* Cores Light Mode (padrão) */
  --bg-main: #f8fafc;
  --bg-surface: #ffffff;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --border-color: #e2e8f0;
  
  --primary: #8b5cf6;
  --primary-hover: #7c3aed;
  --primary-focus: rgba(139, 92, 246, 0.3);
  
  --header-bg: rgba(255, 255, 255, 0.7);
  --header-border: rgba(0, 0, 0, 0.05);

  --wpp-color: #25d366;
  
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-wpp: 0 4px 14px rgba(37, 211, 102, 0.4);
}

/* Força modo escuro pela classe */
html[data-theme="dark"] {
  --bg-main: #0f172a;
  --bg-surface: #1e293b;
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --border-color: #334155;
  
  --primary: #a78bfa;
  --primary-hover: #8b5cf6;
  --primary-focus: rgba(167, 139, 250, 0.3);
  
  --header-bg: rgba(15, 23, 42, 0.7);
  --header-border: rgba(255, 255, 255, 0.05);
  
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.4);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.5);
  color-scheme: dark;
}

/* Aplica modo escuro pelo sistema, a menos que o claro seja forçado */
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --bg-main: #0f172a;
    --bg-surface: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --border-color: #334155;
    
    --primary: #a78bfa;
    --primary-hover: #8b5cf6;
    --primary-focus: rgba(167, 139, 250, 0.3);
    
    --header-bg: rgba(15, 23, 42, 0.7);
    --header-border: rgba(255, 255, 255, 0.05);
    
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.5);
    color-scheme: dark;
  }
}

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

html {
  font-family: 'Inter', sans-serif;
  scroll-behavior: smooth;
}

@font-face {
  font-family: 'Doggies Silhouette';
  src: url('./fonts/doggies-silhouette-font-regular.ttf') format('truetype');
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

/* Tipografia */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.2;
}

p {
  color: var(--text-secondary);
}

a {
  text-decoration: none;
  color: var(--text-primary);
  transition: color 0.2s;
}

/* Cabecalho */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--header-border);
  z-index: 1000;
  display: flex;
  justify-content: center;
  transition: background-color 0.3s ease;
}

#cabecalho {
  width: 100%;
  max-width: 1200px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 2rem;
}

#cabecalho > a {
  font-family: 'Doggies Silhouette', cursive;
  font-size: 2.5rem; /* Aumentado */
  font-weight: normal;
  color: var(--primary);
  letter-spacing: normal;
}

nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.lnkOpcsMenu {
  font-weight: 500;
  font-size: 1rem;
  padding: 0.5rem;
}

.lnkOpcsMenu:hover {
  color: var(--primary);
}

.btnTheme {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s, background-color 0.2s, border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--shadow-sm);
}

.btnTheme:hover {
  transform: scale(1.05);
  border-color: var(--primary);
}

.btnTheme:active {
  transform: scale(0.95);
}

.btnMenu {
  display: none;
}

/* Seção Início */
#inicio {
  margin-top: 60px; /* espaco do header */
  padding: 2rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.cjntImg {
  position: relative;
  width: 100%;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 21/9;
}

.controleDeslizante {
  display: flex;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.controleDeslizante::-webkit-scrollbar {
  display: none;
}

.controleDeslizante img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  scroll-snap-align: start;
}

.navDeslizante {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.75rem;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  backdrop-filter: blur(4px);
}

.navDeslizante a {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  transition: background-color 0.3s, transform 0.2s;
}

.navDeslizante a:hover {
  background-color: #fff;
  transform: scale(1.2);
}

/* Seção Sobre */
#sobre {
  padding: 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.sobreApresentacao {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 4rem;
}

.sobreImagens {
  position: relative;
  height: 500px;
}

.sobreImg {
  border-radius: 24px;
  object-fit: cover;
  box-shadow: var(--shadow-lg);
  position: absolute;
}

.sobreImgPrincipal {
  width: 80%;
  height: 400px;
  top: 0;
  left: 0;
  z-index: 1;
}

.sobreImgSecundaria {
  width: 60%;
  height: 300px;
  bottom: 0;
  right: 0;
  z-index: 2;
  border: 8px solid var(--bg-main);
}

.sobreTexto h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.sobreTexto p {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.sobreDestaque {
  margin-top: 2rem;
  padding: 2rem;
  background: var(--bg-surface);
  border-left: 4px solid var(--primary);
  border-radius: 0 16px 16px 0;
  box-shadow: var(--shadow-sm);
}

.sobreDestaque h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.sobreIndicadores {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.indicador {
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: 20px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
}

.indicador:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.indicador strong {
  display: block;
  font-size: 2rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-weight: 800;
}

/* Seção Serviços */
#servicos {
  padding: 6rem 2rem;
  background: var(--bg-surface);
}

.servicosCabecalho {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 4rem auto;
}

.servicosCabecalho h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.gradeServicos {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}

.cardServico {
  background: var(--bg-main);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
}

.cardServico:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.cardServico img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.cardServico h3 {
  font-size: 1.25rem;
  margin: 1.5rem 1.5rem 0.5rem 1.5rem;
}

.cardServico p {
  margin: 0 1.5rem 1.5rem 1.5rem;
  font-size: 0.95rem;
}

/* Seção Contato */
#contato {
  padding: 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contatoTexto h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.contatoTexto h3 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.contatoTexto address {
  font-style: normal;
  margin-top: 2rem;
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
}

form {
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 1.5rem;
}

form > p {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Nome */
form > p:nth-child(1) { grid-column: 1; }
/* Email */
form > p:nth-child(2) { grid-column: 2; }
/* Telefone */
form > p:nth-child(3) { grid-column: 1 / -1; }
/* Fieldset */
form > fieldset { grid-column: 1 / -1; }
/* Mensagem */
form > p:nth-child(5) { grid-column: 1 / -1; }
/* Botão */
form > button { grid-column: 1 / -1; justify-self: center; width: 100%; max-width: 300px; }

form label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
}

form input[type="text"],
form input[type="email"],
form input[type="tel"],
form textarea {
  width: 100%;
  padding: 1rem;
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  transition: all 0.2s;
}

form input:focus,
form textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-focus);
}

fieldset {
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
}

fieldset legend {
  font-weight: 600;
  padding: 0 0.5rem;
  color: var(--text-primary);
  text-align: center;
  margin: 0 auto;
}

fieldset ul {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 0.5rem;
}

fieldset li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* Botões */
button[type="submit"] {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 1rem;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background-color 0.2s;
  box-shadow: var(--shadow-sm);
  margin-top: 1rem;
}

button[type="submit"]:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

button[type="submit"]:active {
  transform: translateY(0);
}

/* Rodapé */
footer {
  padding-bottom: 2rem;
}

.btnRodape {
  position: fixed;
  bottom: 4rem;
  left: 2rem;
  right: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  pointer-events: none; /* Permite clicar nos elementos atrás do espaço vazio */
}

.btnRodape > * {
  pointer-events: auto; /* Restaura o clique apenas para os botões reais */
}

.btn {
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s;
}

.btnAgendamento {
  background: var(--primary);
  color: #fff;
  padding: 1rem 2rem;
  border-radius: 9999px; /* Pílula */
  box-shadow: var(--shadow-lg);
}

.btnAgendamento:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 20px -5px rgba(139, 92, 246, 0.4);
}

.btnAgendamento:active {
  transform: translateY(0);
}

.btnWpp {
  background: var(--wpp-color);
  color: #fff;
  width: 60px;
  height: 60px;
  border-radius: 50%; /* Circular */
  box-shadow: var(--shadow-wpp);
  animation: pulse 2s infinite;
}

.btnWpp:hover {
  transform: translateY(-4px) scale(1.05);
  animation-play-state: paused;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6); }
  70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Responsivo */
@media (max-width: 992px) {
  .sobreApresentacao,
  #contato {
    grid-template-columns: 1fr;
  }
  
  .gradeServicos {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .sobreIndicadores {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .sobreImagens {
    height: 400px;
  }
}

@media (max-width: 768px) {
  #cabecalho {
    padding: 0.6rem 1rem;
  }

  #cabecalho > a {
    font-size: 2rem;
  }
  
  .btnMenu {
    display: block;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s, box-shadow 0.2s;
    box-shadow: var(--shadow-sm);
  }

  .btnMenu:active {
    transform: scale(0.95);
    background: var(--border-color);
  }
  
  #cabecalho nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--bg-surface);
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    
    /* Efeito de abertura mais evidente */
    opacity: 0;
    visibility: hidden;
    transform-origin: top center;
    transform: translateY(-15px) scaleY(0.9);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  }
  
  #cabecalho nav.menuAberto {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scaleY(1);
  }
  
  #cabecalho nav ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  
  #cabecalho nav ul li {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .lnkOpcsMenu {
    display: block;
    width: 100%;
    padding: 1rem;
    background: var(--bg-main);
    border-radius: 8px;
    text-align: center;
    transition: background-color 0.2s;
  }
  
  .lnkOpcsMenu:hover, .lnkOpcsMenu:active {
    background: var(--primary-focus);
    color: var(--primary);
  }
  
  /* Ajusta botões flutuantes no celular: um de cada lado */
  .btnRodape {
    left: 1rem;
    right: 1rem;
    bottom: 2rem;
    justify-content: space-between;
  }
  
  .btnAgendamento {
    font-size: 0.95rem;
    padding: 0.7rem 1.2rem;
  }
  
  .btnWpp {
    width: 50px;
    height: 50px;
  }
  
  .btnWpp svg {
    width: 26px;
    height: 26px;
  }
  
  .gradeServicos,
  .sobreIndicadores {
    grid-template-columns: 1fr;
  }
  
  form {
    padding: 1.5rem;
    grid-template-columns: 1fr;
  }
  /* Reseta os grid-columns para ocupar 100% no celular */
  form > p:nth-child(1),
  form > p:nth-child(2) {
    grid-column: 1 / -1;
  }
  
  fieldset ul {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .cjntImg {
    aspect-ratio: auto;
    flex: 1;
    height: 100%;
    width: 100%;
  }
  
  /* Ajusta o seletor do carrossel para caber exatamente entre os botões desiguais */
  .navDeslizante {
    padding: 0.4rem 0.8rem;
    gap: 0.5rem;
    /* Desloca ligeiramente para a direita para compensar o botão Agendar que é mais largo */
    transform: translateX(calc(-50% + 15px));
    bottom: 2.2rem;
  }
  
  .navDeslizante a {
    width: 8px;
    height: 8px;
  }
  
  #inicio {
    padding: 1rem;
    margin-top: 50px;
    height: calc(100vh - 50px);
    display: flex;
    flex-direction: column;
  }
  

}

/* Correção de âncoras para não esconder o topo atrás do cabeçalho fixo */
#inicio, #sobre, #servicos, #contato {
  scroll-margin-top: 65px;
}

/* Ajustes para Notebooks (1366x768) para que o conteúdo caiba na tela sem cortar */
@media (max-width: 1366px), (max-height: 800px) {
  #sobre {
    padding: 2rem;
  }
  .sobreApresentacao {
    gap: 1.5rem;
    margin-bottom: 1rem;
  }
  .sobreImagens {
    height: 300px;
  }
  .sobreImgPrincipal {
    height: 250px;
  }
  .sobreImgSecundaria {
    height: 180px;
    border-width: 4px;
  }
  .sobreTexto h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
  }
  .sobreTexto p {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
  }
  .sobreDestaque {
    margin-top: 0.5rem;
    padding: 1rem;
  }
  .indicador {
    padding: 1rem;
  }
  .indicador strong {
    font-size: 1.2rem;
  }
  
  #servicos {
    padding: 2rem;
  }
  .servicosCabecalho {
    margin-bottom: 1.5rem;
  }
  .servicosCabecalho h2 {
    font-size: 2rem;
  }
  .cardServico img {
    height: 140px;
  }
  .cardServico h3 {
    margin: 1rem 1rem 0.5rem 1rem;
    font-size: 1.1rem;
  }
  .cardServico p {
    margin: 0 1rem 1rem 1rem;
    font-size: 0.85rem;
  }

  #contato {
    padding: 2rem;
    gap: 1.5rem;
  }
  .contatoTexto h2 {
    font-size: 2rem;
  }
  .contatoTexto address {
    padding: 1rem;
    margin-top: 1rem;
    font-size: 0.9rem;
  }
  form {
    padding: 1.5rem;
    gap: 0.8rem;
  }
  form p {
    gap: 0.2rem;
  }
  form input[type="text"],
  form input[type="email"],
  form input[type="tel"],
  form textarea {
    padding: 0.6rem;
    font-size: 0.9rem;
  }
  form textarea {
    min-height: 80px;
  }
  fieldset {
    padding: 0.8rem;
  }
  button[type="submit"] {
    padding: 0.6rem;
    margin-top: 0.5rem;
  }
}

/* Empurra o conteúdo para que cada seção ocupe pelo menos a tela inteira */
#sobre, #servicos {
  min-height: calc(100vh - 65px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
#contato {
  min-height: calc(100vh - 65px);
  align-items: center; /* Alinha o grid verticalmente ao centro */
}
