/* ============================================
   GLOBAL - Camilla Barretto Site
   ============================================ */

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

:root {
  --bg: #f7f3ed;
  --white: #ffffff;
  --text: #2d2d2d;
  --text-muted: #6b7280;
  --primary: #7a9e8e;
  --primary-light: #eef5f0;
  --accent: #c9a96e;
  --accent-light: #fdf6e3;
  --corp-primary: #1a2744;
  --corp-secondary: #2c4a7c;
  --corp-light: #eef2f7;
  --border: #e8e4de;
  --radius: 10px;
  --shadow: 0 2px 12px rgba(0,0,0,0.06);
  --max-width: 1100px;
  --home-bg: #f5efe6;
  --home-hero-bg: #faf6f0;
}

body {
  font-family: 'Montserrat', -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* Nav */
.nav {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

/* Home-specific styles */
body.page-home { background: var(--home-bg); }
body.page-home .nav { background: var(--home-hero-bg); border-bottom-color: transparent; }
body.page-home .section--alt { background: var(--home-hero-bg); }
body.page-home .card { background: var(--home-hero-bg); border-color: var(--border); }
body.page-home .hero__text h1 { color: #3d3d3d; }
body.page-home .btn--primary { background: var(--primary); }
body.page-home .btn--primary:hover { background: #5f8573; }
body.page-home .footer { background: #4a6b5a; }
.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav__logo { font-weight: 700; font-size: 1.1rem; color: var(--primary); }
.nav__links { display: flex; gap: 28px; }
.nav__links a {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}
.nav__links a:hover, .nav__links a.active { color: var(--primary); }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 80px 0;
}
.hero__text h1 { font-size: 2.2rem; font-weight: 700; line-height: 1.2; margin-bottom: 16px; }
.hero__text p { font-size: 1rem; color: var(--text-muted); margin-bottom: 24px; }
.hero__img img { border-radius: var(--radius); box-shadow: var(--shadow); }

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  font-family: inherit;
}
.btn--primary { background: var(--primary); color: white; }
.btn--primary:hover { background: #14472e; }
.btn--corp { background: var(--corp-primary); color: white; }
.btn--corp:hover { background: #0f1c33; }
.btn--outline { border: 2px solid var(--primary); color: var(--primary); background: none; }
.btn--outline:hover { background: var(--primary); color: white; }
.btn--whatsapp { background: #25d366; color: white; }
.btn--whatsapp:hover { background: #20bd5a; }

/* Section */
.section { padding: 64px 0; }
.section--alt { background: var(--white); }
.section__title { font-size: 1.6rem; font-weight: 700; text-align: center; margin-bottom: 12px; }
.section__subtitle { text-align: center; color: var(--text-muted); max-width: 600px; margin: 0 auto 40px; font-size: 0.95rem; }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.cards--2col { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card__icon { font-size: 2.5rem; margin-bottom: 16px; }
.card__title { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.card__desc { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

/* Footer */
.footer {
  background: var(--text);
  color: rgba(255,255,255,0.8);
  padding: 40px 0;
  text-align: center;
  font-size: 0.82rem;
}
.footer a { color: rgba(255,255,255,0.9); }
.footer a:hover { color: white; }
.footer__links { display: flex; justify-content: center; gap: 24px; margin-bottom: 12px; }

/* WhatsApp Float */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #25d366;
  color: white;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  box-shadow: 0 4px 12px rgba(37,211,102,0.4);
  z-index: 999;
  transition: transform 0.2s;
}
.whatsapp-float:hover { transform: scale(1.1); }

/* Responsive */
.grid-about {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 40px;
  align-items: center;
}
.grid-about img {
  width: 100%;
  border-radius: var(--radius);
}

@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding: 40px 0; gap: 24px; }
  .hero__img { order: -1; }
  .hero__text h1 { font-size: 1.6rem; }
  .nav .container { flex-wrap: wrap; row-gap: 8px; justify-content: center; }
  .nav__logo { width: 100%; text-align: center; }
  .nav__links { width: 100%; justify-content: center; gap: 12px; }
  .nav__links a { font-size: 0.75rem; }
  .section { padding: 40px 0; }
  .section__title { font-size: 1.3rem; }
  .grid-about { grid-template-columns: 1fr !important; text-align: center; gap: 24px; }
  .grid-about img { max-width: 200px; margin: 0 auto; }
  .cards { grid-template-columns: 1fr !important; }
  .cards--2col { grid-template-columns: 1fr !important; }
  .footer__links { flex-wrap: wrap; gap: 12px; }
  .btn { padding: 10px 20px; font-size: 0.85rem; }
  .btn + .btn { margin-left: 0 !important; margin-top: 12px; display: block; }

  /* Fix inline grids */
  [style*="grid-template-columns: 300px"] ,
  [style*="grid-template-columns: 280px"],
  [style*="grid-template-columns:300px"],
  [style*="grid-template-columns:280px"],
  [style*="grid-template-columns:1fr 300px"],
  [style*="grid-template-columns: 1fr 300px"],
  [style*="grid-template-columns:1fr 1fr"],
  [style*="grid-template-columns: 1fr 1fr"] {
    grid-template-columns: 1fr !important;
    text-align: center;
  }

  /* Stats grid */
  .stats { grid-template-columns: 1fr !important; gap: 16px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .hero__text h1 { font-size: 1.4rem; }
  .nav__logo { font-size: 0.95rem; }
  .card { padding: 24px 16px; }
  .whatsapp-float { width: 48px; height: 48px; bottom: 16px; right: 16px; }
}


/* Top Banner Slideshow */
.top-banner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  height: 300px;
  overflow: hidden;
  position: relative;
  border-radius: var(--radius);
}
.top-banner .slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
}

/* Ajuste específico do banner da Consultoria — altura maior e desce o
   foco da imagem para mostrar melhor a Camilla escrevendo no quadro. */
.top-banner--consultoria {
  height: 420px;
}
.top-banner--consultoria .slide {
  object-position: center top;
}
.top-banner .slide.active {
  opacity: 1;
}

@media (max-width: 768px) {
  .top-banner { height: 200px; }
  .top-banner--consultoria { height: 280px; }
}

/* Slideshow - Hero Image Rotation */
.slideshow {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.slideshow .slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}
.slideshow .slide.active {
  position: relative;
  opacity: 1;
}

/* Setas de navegação (prev/next) — adicionadas via js/gallery.js */
.gallery-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.75);
  color: var(--text);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background 0.2s, transform 0.2s;
}
.gallery-arrow:hover { background: rgba(255, 255, 255, 0.95); transform: translateY(-50%) scale(1.08); }
.gallery-arrow--prev { left: 14px; }
.gallery-arrow--next { right: 14px; }

/* Pontinhos indicadores de slide */
.gallery-dots {
  position: absolute;
  bottom: 12px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 6px;
  z-index: 10;
}
.gallery-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}
.gallery-dot.active { background: rgba(255, 255, 255, 0.95); transform: scale(1.2); }

@media (max-width: 480px) {
  .gallery-arrow { width: 30px; height: 30px; font-size: 0.85rem; }
}


/* ============================================
   EFEITOS E ANIMAÇÕES
   ============================================ */

/* Fade-in ao scroll (elementos com class .reveal) */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delay para cards */
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Slideshow com zoom sutil (ken burns) */
.slideshow .slide {
  transform: scale(1);
  transition: opacity 1.2s ease-in-out, transform 6s ease-in-out;
}
.slideshow .slide.active {
  transform: scale(1.05);
}

/* Card hover aprimorado */
.card {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.1);
  border-color: var(--primary);
}

/* Hero text entrada */
.hero__text {
  animation: heroFadeIn 1s ease-out;
}
@keyframes heroFadeIn {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* Hero image entrada */
.hero__img {
  animation: heroImgIn 1.2s ease-out 0.3s both;
}
@keyframes heroImgIn {
  from { opacity: 0; transform: translateX(20px) scale(0.95); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}

/* Botão pulse sutil no WhatsApp float */
.whatsapp-float {
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 4px 12px rgba(37,211,102,0.4); }
  50% { box-shadow: 0 4px 24px rgba(37,211,102,0.7); }
}

/* Nav fade on load */
.nav {
  animation: navSlideDown 0.5s ease-out;
}
@keyframes navSlideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Stats counter animation */
.stat__num {
  transition: transform 0.3s ease;
}
.stat:hover .stat__num {
  transform: scale(1.15);
}

/* Section title underline effect */
.section__title {
  position: relative;
  display: inline-block;
}
.section__title::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

/* Smooth scroll */
html { scroll-behavior: smooth; }
