/* =========================================
   Tokens
   ========================================= */
:root {
  --cream: #fff7ea;
  --white: #fbfcfa;
  --purple: #7a57cd;
  --purple-dark: #5f3fb0;
  --sage: #8e9c66;
  --sage-light: #a3af84;
  --ink: #0d1216;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;

  --max-width: 1080px;
  --radius: 16px;
}

/* =========================================
   Reset
   ========================================= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
}

/* =========================================
   Header / Nav
   ========================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 247, 234, 0.4);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(13, 18, 22, 0.06);
}

.navbar {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--purple-dark);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  font-weight: 600;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--purple);
}

.nav-cta {
  background: var(--purple);
  color: var(--white) !important;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
}

.nav-cta:hover {
  background: var(--purple-dark);
  color: var(--white) !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

/* =========================================
   Hero
   ========================================= */
.hero {
  padding: 4rem 1.5rem;
}

.hero-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: center;
}

.hero-content {
  text-align: left;
}

/* Envolve a foto e ancora o ring, que precisa ficar fora do overflow da .hero-media */
.hero-visual {
  position: relative;
}

/* Ring com a mesma silhueta da foto. A oscilação usa transform: scale, que
   interpola em subpixel — outline-offset arredonda para px inteiro e trava em degraus */
.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 4px solid var(--sage-light);
  border-radius: 999px;
  pointer-events: none;
  will-change: transform, opacity;
  animation: ring-ripple 5s linear infinite;
}

/* Onda: nasce colada na foto, se afasta perdendo opacidade até sumir.
   O trecho invisível no fim é a pausa antes da próxima onda */
@keyframes ring-ripple {
  0% {
    transform: scale(1.015);
    opacity: 0;
  }
  10% {
    opacity: 0.85;
  }
  60% {
    transform: scale(1.16);
    opacity: 0;
  }
  100% {
    transform: scale(1.16);
    opacity: 0;
  }
}

/* Versão mobile da onda: linha reta que nasce colada na borda inferior do hero
   e desce para fora dele. Curso curto, em px, para não invadir a seção seguinte */
@keyframes ring-ripple-bottom {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  20% {
    opacity: 0.75;
  }
  100% {
    transform: translateY(44px);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-visual::before,
  .hero-visual::after {
    animation: none;
  }
}

/* Formato pill em pé: raio maior que a metade da largura arredonda topo e base
   em semicírculos, e a proporção 3/4 da img mantém o pill vertical */
.hero-media {
  overflow: hidden;
  border-radius: 999px;
  height: full;
}

.hero-media img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  transform: scale(2) translateY(-50px);
  transform-origin: top center;
  box-shadow: 0 24px 48px rgba(13, 18, 22, 0.12);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--sage);
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  color: var(--purple-dark);
  margin-bottom: 1.25rem;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: rgba(13, 18, 22, 0.75);
  margin-bottom: 2rem;
}

/* =========================================
   Buttons
   ========================================= */
.btn {
  display: inline-block;
  padding: 0.85rem 1.9rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--purple);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--purple-dark);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--ink);
}

.btn-whatsapp {
  background: #25d366;
  color: var(--white);
}

.btn-whatsapp:hover {
  background: #1ebe57;
}

.btn-instagram {
  background: linear-gradient(45deg, #f9ce34, #ee2a7b, #6228d7);
  color: var(--white);
}

.btn-instagram:hover {
  opacity: 0.9;
}

/* =========================================
   Sections
   ========================================= */
.section {
  padding: 5rem 1.5rem;
}

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.section h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  color: var(--purple-dark);
  margin-bottom: 1.5rem;
}

.section p {
  max-width: 68ch;
}

.section p + p {
  margin-top: 1rem;
}

.section-alt {
  background: var(--white);
}

/* Split (text + image) layout, used in Sobre / Processo / Público */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.split.reverse {
  grid-template-columns: 0.9fr 1.1fr;
}

.split-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: 0 20px 40px rgba(13, 18, 22, 0.1);
}

/* Photo gallery, used in Contato */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}

.gallery img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--radius);
}

.section-center {
  text-align: center;
}

.section-center .section-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lead {
  font-size: 1.2rem;
  font-weight: 600;
}

/* Fundo no tom do ripple, com texto preto para manter o contraste */
.section-contact {
  background: var(--sage-light);
  color: var(--ink);
}

.section-contact h2 {
  color: var(--ink);
}

/* Número logo abaixo do título, no display do resto da página */
.section-contact .contact-phone {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.section-contact .contact-phone a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid rgba(13, 18, 22, 0.35);
}

.section-contact .contact-phone a:hover {
  border-bottom-color: var(--ink);
}

.section-contact .lead {
  color: rgba(13, 18, 22, 0.85);
  margin-bottom: 2rem;
}

/* =========================================
   Grid / Cards
   ========================================= */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.card {
  background: var(--cream);
  border-radius: var(--radius);
  padding: 1.75rem;
}

.card h3 {
  font-size: 1.1rem;
  color: var(--purple-dark);
  margin-bottom: 1rem;
}

.tag-list li {
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(13, 18, 22, 0.08);
  font-size: 0.95rem;
}

.tag-list li:last-child {
  border-bottom: none;
}

/* =========================================
   Timeline
   ========================================= */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.timeline li {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

.timeline-index {
  position: relative;
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--sage);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
}

/* Ripple no círculo do passo, mesma linguagem do ring do hero: duas ondas
   defasadas meio ciclo saindo da borda do círculo */
.timeline-index::before,
.timeline-index::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 2px solid var(--sage-light);
  border-radius: 50%;
  pointer-events: none;
  will-change: transform, opacity;
  animation: index-ripple 4s linear infinite;
}

.timeline-index::before {
  animation-delay: var(--ripple-delay, 0s);
}

.timeline-index::after {
  animation-delay: calc(var(--ripple-delay, 0s));
}

/* Delay crescente por passo: as ondas descem a timeline em cascata.
   Valores negativos para todas já entrarem em curso no load */
.timeline li:nth-child(2) {
  --ripple-delay: 0.3s;
}

.timeline li:nth-child(3) {
  --ripple-delay: 0.6s;
}

.timeline li:nth-child(4) {
  --ripple-delay: 0.9s;
}

.timeline li:nth-child(5) {
  --ripple-delay: 1.2s;
}

.timeline li:nth-child(6) {
  --ripple-delay: 1.5s;
}

/* Onda do passo: nasce colada no círculo, se afasta perdendo opacidade.
   O trecho invisível no fim é a pausa antes da próxima */
@keyframes index-ripple {
  0% {
    transform: scale(1);
    opacity: 0;
  }
  15% {
    opacity: 0.7;
  }
  70% {
    transform: scale(1.9);
    opacity: 0;
  }
  100% {
    transform: scale(1.9);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .timeline-index::before,
  .timeline-index::after {
    animation: none;
    opacity: 0;
  }
}

.timeline h3 {
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.timeline p {
  font-size: 0.95rem;
  color: rgba(13, 18, 22, 0.7);
}

/* =========================================
   Avaliações Google
   ========================================= */
.reviews-summary {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: space-between;
  gap: 1.25rem;
}

.reviews-score {
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex-shrink: 1;
  min-width: 0;
  gap: 0.35rem;
}

/* Linha fina separando a nota do botão "Ver no Google" */
.reviews-divider {
  width: 1px;
  background: rgba(13, 18, 22, 0.15);
}

.reviews-score-number {
  display: block;
  text-align: center;
  font-family: var(--font-display);
  font-size: 3.6rem;
  font-weight: 600;
  line-height: 1;
}

.reviews-count {
  font-size: 0.9rem;
  color: rgba(13, 18, 22, 0.65);
}

.review-stars {
  display: flex;
  gap: 0.2rem;
}

/* Cada estrela é o contorno vazio com uma cópia cheia por cima, cortada em --fill */
.star {
  position: relative;
  display: block;
  width: 26px;
  height: 26px;
}

.star svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.star-base {
  fill: none;
  stroke: #f2a900;
  stroke-width: 1.5;
}

.star-fill {
  fill: #f2a900;
  /* Corta pela direita o quanto falta para a estrela ficar cheia */
  clip-path: inset(0 calc(100% - var(--fill)) 0 0);
}

/* .btn-outline foi pensado pra fundo escuro (hero); aqui a seção é clara,
   então sobrescreve cor e borda pro contraste funcionar */
.reviews-google-link {
  display: inline-flex;
  align-items: center;
  align-self: center;
  flex-shrink: 1;
  min-width: 0;
  gap: 0.6rem;
  color: var(--ink);
  border-color: var(--ink);
}

/* Texto quebra em vez de empurrar o botão pra fora ou forçar a linha a virar coluna */
.reviews-google-label {
  min-width: 0;
  text-align: center;
}

.reviews-google-link:hover {
  background: var(--ink);
  color: var(--white);
}

.google-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* =========================================
   Contact (botões flutuantes fixos)
   ========================================= */
.contact-actions {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 200;
}

.fab {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(13, 18, 22, 0.25);
  transition: transform 0.2s ease;
}

.fab:hover {
  transform: scale(1.08);
}

.fab svg {
  width: 28px;
  height: 28px;
  fill: var(--white);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* =========================================
   Footer
   ========================================= */
.site-footer {
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(13, 18, 22, 0.6);
  background: var(--white);
}

/* =========================================
   Mobile
   ========================================= */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--white);
    box-shadow: 0 12px 24px rgba(13, 18, 22, 0.08);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .nav-links.open {
    max-height: 400px;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    width: 100%;
    padding: 1rem 1.5rem;
  }

  .nav-cta {
    border-radius: 0;
    text-align: center;
  }

  .nav-toggle.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .nav-toggle.open span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .hero {
    padding: 4rem 1.25rem 3.5rem;
  }

  .section {
    padding: 3.5rem 1.25rem;
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-content {
    text-align: center;
    order: 2;
    position: relative;
    z-index: 1;
    color: var(--white);
  }

  .hero-content .eyebrow,
  .hero-content h1 {
    color: var(--white);
  }

  .hero-subtitle {
    color: rgba(251, 252, 250, 0.9);
  }

  /* Hero vira full-bleed: foto ocupa toda a section, por trás da navbar.
     Sem overflow: hidden aqui — quem recorta a foto ampliada é o .hero-media,
     e o hero precisa deixar as ondas passarem da borda inferior */
  .hero {
    position: relative;
    margin-top: -72px;
    padding-top: calc(72px + 4rem);
  }

  .hero-visual {
    position: absolute;
    inset: 0;
    z-index: 0;
  }

  /* Foto vira full-bleed: o ring em volta dela ficaria fora da tela, então as
     ondas viram linhas retas de ponta a ponta, nascendo na borda inferior do
     hero e descendo para fora dele */
  .hero-visual::before,
  .hero-visual::after {
    content: "";
    position: absolute;
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    height: 0;
    z-index: 1;
    border: 0;
    border-top: 3px solid var(--sage-light);
    border-radius: 0;
    pointer-events: none;
    will-change: transform, opacity;
    animation: ring-ripple-bottom 5s linear infinite;
  }

  /* Delay negativo: a segunda onda já entra em meio de curso no load */
  .hero-visual::before {
    animation-delay: -2.5s;
  }

  /* Sem animação a linha ficaria parada em cima da borda inferior, então some de vez */
  @media (prefers-reduced-motion: reduce) {
    .hero-visual::before,
    .hero-visual::after {
      display: none;
    }
  }

  .hero-media {
    position: absolute;
    inset: 0;
    border-radius: 0;
  }

  .hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(13, 18, 22, 0.15) 0%, rgba(13, 18, 22, 0.6) 100%);
  }

  .hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transform: scale(1.8);
    transform-origin: top center;
    box-shadow: none;
  }

  .split,
  .split.reverse {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .split-media {
    order: -1;
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .fab {
    width: 48px;
    height: 48px;
  }

  .fab svg {
    width: 24px;
    height: 24px;
  }
}
