/* ══ ESTILOS GERAIS - V1.0 ══ */
/* Sistema Design System Coast */

:root {
  /* Fallbacks de variáveis - Serão sobrescritas pelo config.js via JS */
  --bg-base: #040A14;
  --bg-surface: #070F1C;
  --bg-elevated: rgba(255,255,255,0.04);
  --accent: #1E6FFF;
  --accent-dim: rgba(30,111,255,0.15);
  --accent-glow: rgba(30,111,255,0.30);
  --text-high: #F0F4FF;
  --text-mid: #8A9BC0;
  --text-low: #3D4F6E;
  --border-subtle: rgba(255,255,255,0.06);
  --border-accent: rgba(30,111,255,0.20);
  --gradient-brand: linear-gradient(135deg, #1E6FFF, #0A3A8C);
  
  /* Tipografia */
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;

  /* Espaçamento */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 40px;
  --space-xl: 64px;
  --space-2xl: 100px;
  --space-3xl: 160px;

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;
  --radius-pill: 999px;

  /* Transições */
  --ease-out: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 180ms;
  --duration-base: 300ms;
  --duration-slow: 500ms;
}

/* ══ RESET & BASE ══ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background-color: var(--bg-base);
  color: var(--text-mid);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Base de Noise Overlay via Pseudo-elemento no Body */
body::after {
  content: "";
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  pointer-events: none;
  z-index: 9998;
  opacity: 0.03;
  background-image: var(--gradient-noise);
}

h1, h2, h3, h4, .font-display { font-family: var(--font-display); color: var(--text-high); letter-spacing: -0.03em; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--space-md); }
.section-padding { padding: clamp(100px, 12vw, 160px) 0; }

/* ══ CUSTOM CURSOR ══ */
#cursor-dot, #cursor-ring {
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 10000;
  transform: translate(-50%, -50%); border-radius: 50%;
}
#cursor-dot { width: 6px; height: 6px; background: var(--accent); transition: transform var(--duration-fast) var(--ease-out); }
#cursor-ring {
  width: 32px; height: 32px; border: 1.5px solid var(--accent-glow);
  transition: width var(--duration-fast) var(--ease-out), height var(--duration-fast) var(--ease-out), background var(--duration-fast);
}
body.is-hovering #cursor-ring { width: 48px; height: 48px; background: var(--accent-dim); border-color: transparent; }
@media (pointer: coarse) { #cursor-dot, #cursor-ring { display: none !important; } }

/* ══ PRELOADER ══ */
#preloader {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: var(--bg-base); z-index: 9999; display: flex; align-items: center; justify-content: center;
  transition: opacity 0.6s var(--ease-out), visibility 0.6s;
}
.preloader-content { display: flex; flex-direction: column; align-items: center; gap: var(--space-md); }
.preloader-logo { width: 120px; animation: pulseLogo 2s infinite ease-in-out; }
.preloader-progress { width: 200px; height: 2px; background: var(--border-subtle); border-radius: 2px; overflow: hidden; }
.preloader-bar { height: 100%; background: var(--accent); width: 0%; transition: width 0.1s linear; }
@keyframes pulseLogo { 0%, 100% { transform: scale(0.95); opacity: 0.8; } 50% { transform: scale(1.05); opacity: 1; } }

/* ══ BOTOES ══ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; font-weight: 600; font-size: 0.95rem; border-radius: var(--radius-pill);
  transition: all var(--duration-base) var(--ease-out); cursor: pointer; border: none; font-family: var(--font-body);
}
.btn-primary {
  background: var(--gradient-brand); color: #fff;
  box-shadow: 0 4px 28px var(--accent-glow);
}
.btn-primary:hover { box-shadow: 0 8px 40px var(--accent-glow); transform: translateY(-2px); }
.btn-secondary {
  background: transparent; color: var(--text-high); border: 1px solid var(--border-subtle);
}
.btn-secondary:hover { border-color: var(--border-accent); background: var(--accent-dim); }
.btn-large { padding: 16px 36px; font-size: 1.05rem; }

/* ══ HEADER ══ */
header {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 100;
  padding: var(--space-sm) 0; transition: all var(--duration-base) var(--ease-out);
}
header.scrolled {
  background: color-mix(in srgb, var(--bg-base) 85%, transparent);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border-subtle); padding: 12px 0;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; }
.header-logo { height: 36px; object-fit: contain; }
.desktop-nav { display: flex; gap: var(--space-lg); }
.desktop-nav a { font-size: 0.875rem; font-weight: 500; transition: color var(--duration-fast); }
.desktop-nav a:hover { color: var(--text-high); }
.btn-nav { padding: 8px 20px; font-size: 0.875rem; }

/* Burger Mobile */
#burger {
  display: none; background: transparent; border: none; cursor: pointer; width: 30px; height: 20px;
  position: relative; z-index: 102;
}
#burger span {
  display: block; width: 100%; height: 2px; background: var(--text-high); position: absolute; left: 0;
  transition: all var(--duration-base) var(--ease-out);
}
#burger span:nth-child(1) { top: 0; }
#burger span:nth-child(2) { top: 9px; }
#burger span:nth-child(3) { top: 18px; }
#burger.active span:nth-child(1) { transform: rotate(45deg); top: 9px; }
#burger.active span:nth-child(2) { opacity: 0; }
#burger.active span:nth-child(3) { transform: rotate(-45deg); top: 9px; }

.mobile-nav-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
  background: var(--bg-base); z-index: 101; display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: all var(--duration-base) var(--ease-out);
}
.mobile-nav-overlay.active { opacity: 1; visibility: visible; }
.mobile-nav-content { display: flex; flex-direction: column; align-items: center; gap: var(--space-md); }
.mobile-link { font-family: var(--font-display); font-size: 2rem; color: var(--text-high); }

/* ══ HERO SECTION ══ */
#hero {
  position: relative; min-height: 100svh; display: grid; place-items: center; overflow: hidden;
  background: var(--gradient-hero-bg);
}
#topo-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; opacity: 0.3; }
.hero-grid-bg {
  position: absolute; inset: 0; z-index: 1;
  background-image: linear-gradient(var(--border-subtle) 1px, transparent 1px), linear-gradient(90deg, var(--border-subtle) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 0%, transparent 70%);
}
.hero-orb {
  position: absolute; border-radius: 50%; filter: blur(100px); pointer-events: none; z-index: 1; opacity: 0.5;
  background: var(--accent);
}
.orb-1 { width: 400px; height: 400px; top: -100px; left: -100px; animation: float 10s ease-in-out infinite alternate; }
.orb-2 { width: 300px; height: 300px; bottom: 10%; right: -50px; animation: float 12s ease-in-out infinite alternate-reverse; }

.hero-content {
  position: relative; z-index: 10; text-align: center; display: flex; flex-direction: column; align-items: center;
  margin-top: 80px;
}
.eyebrow-badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px;
  background: var(--accent-dim); border: 1px solid var(--border-accent); border-radius: var(--radius-pill);
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-high); margin-bottom: var(--space-md);
}
.dot-pulse {
  width: 6px; height: 6px; background: var(--accent); border-radius: 50%;
  box-shadow: 0 0 0 0 var(--accent-glow); animation: pulseDot 2s infinite;
}
.hero-title {
  font-size: clamp(2.8rem, 6vw, 5.5rem); line-height: 1.05; margin-bottom: var(--space-md);
}
.hero-title em { font-style: italic; color: var(--accent); font-weight: 800; background: var(--gradient-brand); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-sub {
  font-size: clamp(1rem, 1.5vw, 1.25rem); max-width: 52ch; margin-bottom: var(--space-lg);
}
.hero-actions { display: flex; gap: var(--space-sm); margin-bottom: var(--space-md); }
.social-proof { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; color: var(--text-low); }

.scroll-indicator { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); z-index: 10; }
.mouse { width: 24px; height: 36px; border: 2px solid var(--text-low); border-radius: 12px; position: relative; }
.mouse::before {
  content: ''; position: absolute; top: 6px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; background: var(--text-low); border-radius: 50%; animation: scrollWheel 2s infinite;
}

/* ══ STATS BAND ══ */
#stats { background: var(--bg-surface); border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); padding: var(--space-xl) 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); max-width: 1200px; margin: 0 auto; }
.stat-item { text-align: center; border-right: 1px solid var(--border-subtle); }
.stat-item:last-child { border-right: none; }
.stat-value { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; background: var(--gradient-brand); -webkit-background-clip: text; -webkit-text-fill-color: transparent; line-height: 1; margin-bottom: 4px; }
.stat-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-low); font-weight: 600; }

/* ══ SECTION HEADERS ══ */
.section-header { text-align: center; margin-bottom: var(--space-xl); }
.section-eyebrow { font-size: 0.875rem; color: var(--accent); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 8px; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.2; }

/* ══ ABOUT (Profissional) ══ */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-xl); align-items: center; }
.about-image-wrapper { position: relative; border-radius: var(--radius-xl); overflow: hidden; }
.about-image-wrapper::after { content:''; position: absolute; inset: 0; border: 1px solid var(--border-accent); border-radius: inherit; pointer-events: none;}
.about-img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: var(--radius-xl); filter: contrast(1.05); }
.about-text .section-title { margin-bottom: var(--space-md); }
.about-text .section-desc { font-size: 1.1rem; margin-bottom: var(--space-lg); }
.crp-badge { display: inline-block; padding: 8px 16px; background: var(--bg-surface); border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); font-size: 0.85rem; font-weight: 600; }

/* ══ SERVICES CARDS (Glassmorphism + Spotlight) ══ */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--space-md); }
.sr-card {
  position: relative; background: var(--bg-elevated); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); padding: var(--space-lg); overflow: hidden;
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transition: transform var(--duration-base) var(--ease-out), border-color var(--duration-base);
  display: flex; flex-direction: column;
}
.sr-card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 1px;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
  opacity: 0; transition: opacity var(--duration-base);
}
.sr-card::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), var(--accent-dim), transparent 40%);
  opacity: 0; transition: opacity var(--duration-base);
}
.sr-card:hover { transform: translateY(-8px); border-color: var(--border-accent); }
.sr-card:hover::before, .sr-card:hover::after { opacity: 1; }

.card-img-wrapper { margin-bottom: var(--space-md); border-radius: var(--radius-md); overflow: hidden; height: 180px;}
.card-img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--duration-slow); }
.sr-card:hover .card-img { transform: scale(1.05); }

.card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; position: relative; z-index: 2; }
.card-icon { font-size: 1.5rem; }
.card-tag { font-size: 0.7rem; padding: 4px 10px; background: var(--accent-dim); border: 1px solid var(--border-accent); border-radius: var(--radius-pill); text-transform: uppercase; font-weight: 700; color: var(--text-high); }
.card-title { font-size: 1.25rem; margin-bottom: 8px; position: relative; z-index: 2; }
.card-desc { font-size: 0.95rem; position: relative; z-index: 2; }

/* ══ TESTIMONIALS ══ */
.testimonials-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: var(--space-md); }
.testimonial-card {
  position: relative; padding: var(--space-lg); background: var(--bg-surface); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.quote-icon { position: absolute; top: 20px; right: 20px; font-size: 4rem; color: var(--accent); opacity: 0.1; font-family: serif; line-height: 1; }
.stars { color: #F59E0B; margin-bottom: 16px; font-size: 1.2rem; }
.quote-text { font-size: 1.1rem; font-style: italic; color: var(--text-high); margin-bottom: var(--space-md); }
.author-info { display: flex; align-items: center; gap: 16px; }
.author-avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border-accent); }
.author-name { font-weight: 700; color: var(--text-high); display: block; }
.author-role { font-size: 0.85rem; color: var(--text-low); }

/* ══ CTA BAND + MAPA ══ */
.cta-box {
  position: relative; background: var(--bg-surface); border: 1px solid var(--border-accent);
  border-radius: var(--radius-xl); overflow: hidden; display: flex;
}
.cta-orb { position: absolute; width: 300px; height: 300px; background: var(--accent); filter: blur(100px); opacity: 0.15; top: -100px; left: -100px; pointer-events: none;}
.cta-content { padding: var(--space-xl); flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; z-index: 2;}
.cta-title { font-size: clamp(2rem, 3vw, 2.5rem); margin-bottom: var(--space-lg); max-width: 15ch; }
.cta-map { width: 50%; min-height: 400px; filter: grayscale(1) invert(0.9) hue-rotate(180deg) opacity(0.8); }

/* ══ FOOTER ══ */
footer { background: var(--bg-surface); border-top: 1px solid var(--border-subtle); padding: var(--space-xl) 0 var(--space-lg) 0; }
.footer-top { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: var(--space-xl); }
.footer-brand { max-width: 300px; }
.footer-logo { height: 40px; margin-bottom: var(--space-md); object-fit: contain; }
.footer-social { display: flex; gap: 16px; }
.social-link { display: flex; align-items: center; gap: 8px; font-size: 0.95rem; font-weight: 500; transition: color var(--duration-fast); }
.social-link:hover { color: var(--text-high); }
.footer-divider { height: 1px; background: var(--border-subtle); margin-bottom: var(--space-md); }
.footer-bottom { display: flex; justify-content: space-between; font-size: 0.85rem; color: var(--text-low); }

/* ══ WHATSAPP FAB ══ */
#whatsapp-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 200; display: flex; align-items: center; gap: 12px;
  background: #25D366; color: white; padding: 14px 20px; border-radius: var(--radius-pill);
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4); text-decoration: none;
  transition: all var(--duration-base) var(--ease-spring); max-width: 240px; overflow: hidden;
}
.fab-content { display: flex; align-items: center; gap: 12px; position: relative; z-index: 2; }
.fab-text { font-weight: 700; white-space: nowrap; transition: opacity 0.3s; }
.fab-pulse-ring {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 100%; height: 100%; border-radius: var(--radius-pill); border: 2px solid #25D366;
  animation: pulseFab 2s infinite; z-index: 1; pointer-events: none;
}
#whatsapp-fab:hover { transform: translateY(-4px) scale(1.05); }
#whatsapp-fab.collapsed { max-width: 56px; padding: 14px; }
#whatsapp-fab.collapsed .fab-text { opacity: 0; width: 0; }

/* ══ ANIMAÇÕES & KEYFRAMES ══ */
@keyframes pulseDot { 0% { box-shadow: 0 0 0 0 var(--accent-glow); } 70% { box-shadow: 0 0 0 10px rgba(0,0,0,0); } 100% { box-shadow: 0 0 0 0 rgba(0,0,0,0); } }
@keyframes float { 0% { transform: translate(0, 0); } 100% { transform: translate(30px, 50px); } }
@keyframes scrollWheel { 0% { top: 6px; opacity: 1; } 100% { top: 20px; opacity: 0; } }
@keyframes pulseFab { 0% { width: 100%; height: 100%; opacity: 0.6; } 100% { width: 150%; height: 150%; opacity: 0; } }

/* Scroll Reveal */
.sr { opacity: 0; transform: translateY(24px); transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out); }
.sr.visible { opacity: 1; transform: translateY(0); }

/* ══ RESPONSIVO ══ */
@media (max-width: 1024px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-image-wrapper { max-width: 500px; margin: 0 auto; }
  .cta-box { flex-direction: column; }
  .cta-map { width: 100%; min-height: 300px; }
}
@media (max-width: 768px) {
  .desktop-nav, .header-inner .btn-nav { display: none; }
  #burger { display: block; }
  .hero-actions { flex-direction: column; width: 100%; }
  .hero-actions .btn { width: 100%; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: var(--space-md); }
  .stat-item { border-right: none; border-bottom: 1px solid var(--border-subtle); padding-bottom: var(--space-md); }
  .stat-item:nth-child(3), .stat-item:nth-child(4) { border-bottom: none; padding-bottom: 0; }
  .footer-top { flex-direction: column; align-items: flex-start; gap: var(--space-lg); }
  .footer-bottom { flex-direction: column; gap: var(--space-sm); text-align: center; }
}