/* ================================== */
/* 1. CONFIGURAÇÕES GLOBAIS E VARIÁVEIS */
/* ================================== */
:root {
  --primary-color: #8febd9;
  --secondary-color: #d7f2d8;
  --accent-color: #006666;
  --text-color: #663399;
  --white-color: #ffffff;
  --dark-text: #006666;
  --footer-bg: #006666;
  --star-color: #fbbc05;
  --border-color: #e0e0e0;
  --font-family-poppins: "Poppins", sans-serif;
  --font-family-montserrat: "Montserrat", sans-serif;
  --transition-fast: all 0.3s ease-in-out;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-poppins);
  background-color: var(--secondary-color);
  color: var(--text-color);
  line-height: 1.7;
  transition: var(--transition-fast);
}

body.menu-open {
  overflow: hidden;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast); /* Transição suave para todos os links */
}

.container,
.container-economia,
.container-investimentos,
.footer-container {
  max-width: 1100px;
  width: 90%;
  margin: 0 auto;
}

section {
  padding: clamp(60px, 8vw, 100px) 0;
}

.section-title {
  font-size: clamp(2rem, 5vw, 2.75rem);
  color: var(--dark-text);
  text-align: center;
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.section-subtitle {
  max-width: 800px;
  margin: 0 auto 3rem auto;
  text-align: center;
  font-size: clamp(1.1rem, 3vw, 1.25rem);
  color: var(--dark-text);
  line-height: 1.8;
}

/* ======================= */
/* 2. ANIMAÇÕES DE SCROLL */
/* ======================= */
.animate-on-scroll {
  opacity: 0;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll[data-animation="fade-in-up"] {
  transform: translateY(50px);
}
.animate-on-scroll[data-animation="fade-in-left"] {
  transform: translateX(-50px);
}
.animate-on-scroll[data-animation="fade-in-right"] {
  transform: translateX(50px);
}
.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* ================================== */
/* 3. HEADER & MENU HAMBURGUER */
/* ================================== */
.header {
  position: fixed;
  width: 90%;
  max-width: 1100px;
  left: 50%;
  transform: translateX(-50%);
  top: 20px;
  z-index: 1000;
  background-color: #0bd3c4;
  padding: 5px 0;
  border-radius: 50px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  transition: var(--transition-fast);
}
.header.scrolled {
  background-color: rgba(215, 242, 216, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  top: 10px;
}
.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 25px;
}
.logo img {
  height: 30px;
  transition: var(--transition-fast);
}
.logo:hover img {
  transform: scale(1.08);
}
.menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 85%;
  max-width: 320px;
  height: 100vh;
  background: var(--white-color);
  flex-direction: column;
  padding: 8rem 2rem 2rem 2rem;
  transition: right 0.4s ease-in-out;
  z-index: 1001;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  display: flex;
}
.menu.active {
  right: 0;
}
.menu ul {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  list-style: none;
  padding-left: 0;
}
.menu a {
  font-size: 1.2rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
}
.menu a:hover {
  background-color: rgba(143, 235, 217, 0.3);
  color: var(--accent-color);
}
.header-right {
  display: flex;
  align-items: center;
  gap: 15px;
}
.btn-contato {
  background-color: var(--accent-color);
  color: var(--white-color);
  padding: 8px 24px;
  border-radius: 25px;
  font-weight: 500;
  transition: var(--transition-fast);
  white-space: nowrap;
}
.btn-contato:hover {
  background-color: var(--text-color);
  transform: scale(1.05);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}
.hamburger {
  display: flex;
  width: 30px;
  height: 21px;
  flex-direction: column;
  justify-content: space-between;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 1002;
}
.hamburger span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: var(--text-color);
  border-radius: 3px;
  transition: var(--transition-fast);
  transform-origin: center;
}
.hamburger.active span {
  background-color: var(--dark-text);
}
.hamburger.active span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}
.hamburger.active span:nth-child(2) {
  opacity: 0;
}
.hamburger.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s;
}
.menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ================================== */
/* 4. HERO SECTION */
/* ================================== */
.hero {
  background-color: var(--primary-color);
  padding: 110px 0 60px;
  overflow: hidden;
  border-bottom-left-radius: 60px;
  border-bottom-right-radius: 60px;
  min-height: 60vh;
  margin-top: -70px;
}
.hero .hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2rem;
}
.hero-text {
  max-width: 550px;
}
.hero-text h1 {
  font-size: clamp(2.8rem, 8vw, 4.5rem);
  color: var(--text-color);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  line-height: 1.2;
}
.hero-text h1 img {
  height: clamp(2.8rem, 8vw, 4.5rem);
  animation: float 4s ease-in-out infinite;
}
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-15px);
  }
}
.divider {
  width: 200px;
  height: 9px;
  background: linear-gradient(90deg, var(--accent-color), var(--text-color));
  border-radius: 100px;
  margin: 1.5rem auto;
}
.hero-text p {
  font-size: clamp(1.2rem, 4vw, 1.5rem);
}
.hero-text .highlight {
  color: var(--white-color);
  font-weight: 600;
  background-color: var(--text-color);
  border-radius: 8px;
  padding: 0.2rem 0.6rem;
}
.hero-image {
  width: 100%;
  max-width: 1050px;
}
.hero-image img {
  width: 100%;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
  margin: -149px;
  height: 100%;
}

/* ================================== */
/* 5. SEÇÕES DE CONTEÚDO */
/* ================================== */
.sobre {
  text-align: center;
  background-color: #fff;
  margin-top: -50px;
}
.libelula-sobre {
  width: 70px;
  margin: 20px auto;
  animation: float 3s ease-in-out infinite alternate;
}
.sobre p {
  max-width: 800px;
  margin: 0 auto;
  color: var(--dark-text);
  font-size: large;
}
.analise {
  background-color: var(--secondary-color);
}
.analise-imagem-fundo {
  padding: 3rem 1.5rem;
  background: url("imagens/clinica.png") center/cover no-repeat;
  border-radius: 24px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}
.analise-cards {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}
.analise .card {
  background-color: var(--accent-color);
  color: var(--white-color);
  border-radius: 20px;
  padding: 2rem 1.5rem;
  width: 100%;
  max-width: 350px;
  text-align: center;
  font-size: 1.2rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  transition: var(--transition-fast);
  min-height: 170px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.analise .card:hover {
  transform: translateY(-10px) scale(1.02);
}
.economia {
  background-color: var(--primary-color);
  text-align: center;
}
.container-economia {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2rem;
  font-family: "Montserrat", sans-serif;
}
.texto-economia h3 {
  font-size: clamp(2rem, 6vw, 2.8rem);
  color: var(--text-color);
  line-height: 1.3;
  max-width: 800px;
  text-align: left;
}
.imagem-economia img {
  max-width: 500px;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.15));
  margin-top: 2rem;
}
.investimentos {
  background-color: var(--text-color);
  color: var(--white-color);
}
.investimentos .texto-investimentos h2 {
  font-size: clamp(2.5rem, 7vw, 3.5rem);
  color: var(--secondary-color);
  text-align: left;
  margin-bottom: 1.5rem;
  font-weight: 700;
}
.investimentos .texto-investimentos p {
  font-size: 1.25rem;
  line-height: 1.6;
}
.cards-investimentos {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin-top: 2rem;
}
.card-investimento {
  background-color: var(--secondary-color);
  padding: 2.5rem;
  border-radius: 20px;
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  transition: var(--transition-fast);
  color: var(--dark-text);
}
.card-investimento:hover {
  transform: translateY(-10px);
}
.icone-investimento {
  text-align: center;
  margin-bottom: 1rem;
}
.icone-investimento img {
  width: 60px;
  margin: 0 auto;
}
.card-investimento h3 {
  text-align: center;
  font-size: 1.6rem;
}
.card-investimento h3 span {
  display: block;
}
.card-investimento ul {
  list-style: none;
  text-align: left;
  margin: 1.5rem 0;
  padding: 0;
  flex-grow: 1;
}
.card-investimento ul li {
  margin-bottom: 1rem;
  position: relative;
  padding-left: 25px;
  font-size: 1.1rem;
}
.card-investimento ul li::before {
  content: "✓";
  color: var(--text-color);
  position: absolute;
  left: 0;
  font-weight: bold;
}
.btn-investimento {
  background-color: var(--text-color);
  color: var(--white-color);
  padding: 12px 25px;
  border-radius: 8px;
  font-weight: 600;
  transition: var(--transition-fast);
  margin-top: auto;
  align-self: center;
  text-align: center;
}
.btn-investimento:hover {
  background-color: var(--accent-color);
}

/* ================================== */
/* 6. CARROSSEL (REFEITO) */
/* ================================== */
.estudo-caso {
  background-color: #663399;
}
.estudo-caso .section-title,
.estudo-caso .section-subtitle {
  color: #d7f2d8;
}
.carrossel-container {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.carrossel {
  width: 100%;
  max-width: 320px;
  overflow: hidden;
}
.carrossel-inner {
  display: flex;
}
.review-card {
  flex: 0 0 100%;
  background: #d7f2d8;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 240px;
}
.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.review-author {
  font-weight: 600;
  color: var(--dark-text);
  font-size: 1.1rem;
}
.review-stars {
  display: flex;
  gap: 2px;
}
.star {
  width: 16px;
  height: 16px;
  background-color: #ccc;
  -webkit-mask-image: url("data:image/svg+xml,...");
  mask-image: url("data:image/svg+xml,...");
  -webkit-mask-size: contain;
  mask-size: contain;
}
.star.filled {
  background-color: var(--star-color);
}
.review-text {
  font-style: italic;
  color: #663399;
  line-height: 1.5;
  flex-grow: 1;
  font-size: 1rem;
}
.review-source {
  font-size: 0.9rem;
  color: #663399;
  margin-top: auto;
}
.seta {
  background-color: var(--white-color);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  z-index: 10;
  margin: -10px
}
.seta:hover {
  background-color: #f0f0f0;
  transform: scale(1.1);
}
.seta img {
  width: 22px;
}

/* ================================== */
/* 7. FAQ, FOOTER & WHATSAPP */
/* ================================== */
.faq-section {
  background-color: var(--secondary-color);
}
.faq-section h2 {
  color: var(--dark-text);
}
.faq-container {
  max-width: 800px;
  margin: 2rem auto 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.faq-item {
  background: var(--white-color);
  border-radius: 12px;
  overflow: hidden;
  transition: var(--transition-fast);
}
.faq-question {
  width: 100%;
  padding: 1.5rem;
  text-align: left;
  background: transparent;
  border: none;
  color: var(--text-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 1.1rem;
  font-weight: 600;
  font-family: var(--font-family-poppins);
}
.faq-toggle {
  transition: transform 0.3s ease;
  width: 16px;
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-in-out;
}
.faq-answer p {
  padding: 0 1.5rem 1.5rem 1.5rem;
  color: var(--dark-text);
  line-height: 1.7;
}
.faq-item.active .faq-toggle {
  transform: rotate(180deg);
}
.faq-item.active .faq-question {
  color: var(--accent-color);
}
.faq-item.active .faq-answer {
  border-top: 1px solid var(--border-color);
}
.whatsapp-float {
  position: fixed;
  width: 55px;
  height: 55px;
  bottom: 20px;
  right: 20px;
  background-color: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  z-index: 999;
  transition: var(--transition-fast);
}
.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}
.whatsapp-icon {
  width: 30px;
  height: 30px;
}
.footer {
  background: var(--footer-bg);
  color: var(--white-color);
  padding: 6rem 0 2rem 0;
  border-top-left-radius: 50px;
  border-top-right-radius: 50px;
}
.footer-container {
  display: flex;
  flex-direction: column;
  text-align: center;
  gap: 2.5rem;
}
.footer-logo img {
  width: 150px;
  margin: 0 auto;
  transition: var(--transition-fast);
}
.footer-logo:hover img {
  transform: scale(1.05);
  opacity: 0.9;
}
.footer-info p,
.footer-social p {
  margin-bottom: 0.5rem;
}
.footer-info a:hover {
  color: var(--primary-color);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.social-icons {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
}
.social-icons img {
  width: 30px;
  transition: var(--transition-fast);
}
.social-icons a:hover img {
  transform: scale(1.2) rotate(-5deg);
}
.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.9rem;
}
.footer-bottom a:hover {
  color: var(--primary-color);
}

/* ============================================== */
/* 8. MEDIA QUERIES */
/* ============================================== */

@media (min-width: 768px) {
  .hamburger,
  .menu-overlay {
    display: none;
  }
  .menu {
    position: static;
    display: flex;
    flex-direction: row;
    width: auto;
    height: auto;
    background: transparent;
    right: auto;
    box-shadow: none;
    padding: 0;
  }
  .menu ul {
    flex-direction: row;
    gap: clamp(0.5rem, 2vw, 1.5rem);
    align-items: center;
  }
  .menu a {
    font-size: 0.95rem;
    padding: 5px;
    font-weight: 500;
    white-space: nowrap;
    position: relative;
    color: var(--dark-text);
  }
  .menu a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent-color);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s cubic-bezier(0.19, 1, 0.22, 1);
  }
  .menu a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
  }
  .analise-cards,
  .cards-investimentos {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
  }
  .analise .card {
    width: calc(50% - 2rem);
  }
  .card-investimento {
    width: calc(50% - 2rem);
    max-width: 340px;
  }
  .economia {
    padding-bottom: 0;
  }
  .container-economia {
    position: relative;
    min-height: 400px;
  }
  .texto-economia {
    text-align: left;
    width: 60%;
  }
  .imagem-economia {
    position: absolute;
    right: 0;
    bottom: -25px;
    width: 45%;
    max-width: 450px;
  }
  .footer-container {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
  .footer-logo img,
  .social-icons {
    margin: 0;
    justify-content: flex-start;
  }
}
@media (max-width: 890px) {
  .imagem-economia {
    display: none;
  }
}

/* ⭐ REGRAS DO CARROSSEL PARA DESKTOP ⭐ */
@media (min-width: 1024px) {
  .hero {
    min-height: 85vh;
    display: flex;
    align-items: center;
    padding-bottom: 0;
    position: relative;
  }
  .hero .hero-content {
    position: relative;
    flex-direction: row;
    text-align: left;
    height: 100%;
  }
  .hero-text {
    flex-basis: 50%;
    z-index: 2;
    max-width: 500px;
  }
  .hero-text h1,
  .divider {
    margin-left: 0;
    justify-content: flex-start;
  }
  .hero-image {
    position: absolute;
    bottom: 0;
    right: -5%;
    width: 60%;
    max-width: 800px;
    z-index: 1;
  }
  .analise .card,
  .card-investimento {
    width: calc(33.33% - 2rem);
  }

  /* Layout do Carrossel Desktop */
  .carrossel-container {
    /* Adiciona espaço nas laterais para as setas não ficarem coladas */
    padding: 0 2rem;
  }
  .carrossel {
    max-width: 100%;
    overflow: hidden;
  }
  .carrossel-inner {
    display: flex;
    justify-content: flex-start;
    gap: 1.5rem;
  }
  .review-card {
    flex: 0 0 330px;
    opacity: 0.5;
    transform: scale(0.85);
    transition: transform 0.4s ease, opacity 0.4s ease;
  }
  .review-card.active-slide {
    opacity: 1;
    transform: scale(1);
  }
}

@media (max-width: 910px) {
  .btn-contato {
    display: none;
  }
}
@media (max-width: 1024px) {
  .hero-image img {
    height: 300px;
    margin-bottom: -50px;
    margin-top: -10px;
    display: none;
    height: 300px;
  }
}
@media (max-width: 910px) {
  .btn-contato {
    display: none;
  }
}
