/* --- Variáveis e Reset Globais --- */
:root {
  --bg-color: #fafafa;
  --text-main: #1a1a1a;
  --text-muted: #4a4a4a;
  --accent-green: #6bba92;
  --card-bg: #eaefea;
  --font-main:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
}

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  animation: fadeInPage 0.6s ease-out forwards;
}

@keyframes fadeInPage {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Header Responsivo --- */
header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 4rem;
  background-color: var(--bg-color);
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.3rem;
  font-size: 1.1rem;
}

.logo-icon {
  width: 32px;
  height: 14px;
  background: linear-gradient(90deg, #297461 0%, #6bba92 100%);
  border-radius: 20px;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 3rem;
}

nav a {
  text-decoration: none;
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 600;
  position: relative;
  padding-bottom: 4px;
}

nav a.active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--accent-green);
}

.cta-btn {
  background-color: var(--accent-green);
  color: white;
  border: none;
  padding: 0.8rem 1.8rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.cta-btn:hover {
  background-color: #5aa47f;
}

/* --- Layout Principal --- */
main {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  padding: 4rem;
  max-width: 1440px;
  margin: 0 auto;
  align-items: center;
  min-height: 70vh;
}

.text-content h1 {
  font-size: clamp(2.5rem, 6vw, 5.5rem);
  line-height: 1.05;
  margin-bottom: 2.5rem;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.text-content p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 1.8rem;
  max-width: 90%;
}

/* --- Stats --- */
.stats-container {
  display: flex;
  gap: 5rem;
  margin-top: 3rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--accent-green);
  line-height: 1;
}

.stat-label {
  font-size: 1rem;
  font-weight: 600;
}

/* --- Illustration (Correção de Bug) --- */
.illustration-container {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-bottom: 2rem; /* Margem de segurança */
}

.illustration-container svg {
  width: 100%;
  max-width: 450px;
  height: auto; /* Substitui o 100% e força o navegador a não sobrepor os elementos */
  display: block;
}

/* --- Partners Carousel --- */
.partners-carousel {
  width: 100%;
  padding: 4rem 0 6rem 0;
  overflow: hidden;
  position: relative;
}

.carousel-title {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 4rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

.carousel-track-container {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    black 15%,
    black 85%,
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    black 15%,
    black 85%,
    transparent
  );
}

.carousel-track {
  display: flex;
  width: max-content;
  animation: scroll 40s linear infinite;
}

.carousel-slide {
  display: flex;
  align-items: center;
  gap: 8rem;
  padding-right: 8rem;
}

.partner-img {
  height: 50px;
  width: auto;
  max-width: 200px;
  object-fit: contain;
  filter: grayscale(100%) opacity(0.6);
  transition: all 0.3s ease;
  cursor: pointer;
}

/* Restaura o efeito de "acender" a cor no Hover */
.partner-img:hover {
  filter: grayscale(0%) opacity(1);
  transform: scale(1.05);
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* --- Floating Chat --- */
.chat-widget {
  position: fixed;
  bottom: 2.5rem;
  right: 2.5rem;
  width: 60px;
  height: 60px;
  background-color: var(--accent-green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1001;
  box-shadow: 0 4px 15px rgba(107, 186, 146, 0.4);
  transition: transform 0.3s ease;
}

.chat-widget:hover {
  transform: scale(1.05);
}

/* --- Animações de Scroll --- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.8s ease-out,
    transform 0.8s ease-out;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* =========================================
   MEDIA QUERIES - RESPONSIVIDADE TOTAL
   ========================================= */

@media (max-width: 1024px) {
  header {
    padding: 1.5rem 2rem;
  }
  main {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 3rem 2rem;
  }
  .text-content p {
    margin: 0 auto 1.5rem auto;
  }
  .stats-container {
    justify-content: center;
    gap: 3rem;
  }
  .illustration-container {
    margin-top: 3rem;
  }
}

@media (max-width: 768px) {
  header {
    flex-direction: column;
    gap: 1.5rem;
    padding: 1.5rem 1rem;
  }
  nav ul {
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
  }
  .text-content h1 {
    font-size: 3rem;
  }
  .stats-container {
    flex-direction: column;
    gap: 2rem;
    align-items: center;
  }
  .carousel-slide {
    gap: 4rem;
    padding-right: 4rem;
  }
  .partner-img {
    height: 35px;
  }
  .partners-carousel {
    padding-top: 2rem; /* Reduz espaço vazio entre ilustração e carrossel */
  }
}

@media (max-width: 480px) {
  .text-content h1 {
    font-size: 2.5rem;
  }
  .cta-btn {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
  .chat-widget {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 55px;
    height: 55px;
  }
}
