:root {
  --bg: #020617;
  --bg-soft: #020617;
  --navy: #0f172a;
  --gold: #facc15;
  --gold-soft: rgba(250, 204, 21, 0.24);
  --accent: #38bdf8;
  --muted: #94a3b8;
  --text: #e5e7eb;
  --danger: #ef4444;
  --success: #22c55e;
  --radius-lg: 1.8rem;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(circle at 0% 0%, rgba(56,189,248,0.16), transparent 55%),
              radial-gradient(circle at 100% 100%, rgba(250,204,21,0.18), transparent 55%),
              linear-gradient(135deg, #020617 0%, #020617 40%, #020617 100%);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  position: relative;
  -webkit-overflow-scrolling: touch;
}

.bg-aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 20% 0%, rgba(56,189,248,0.14), transparent 55%),
    radial-gradient(circle at 80% 100%, rgba(250,204,21,0.14), transparent 55%);
  mix-blend-mode: screen;
  animation: auroraMove 18s ease-in-out infinite alternate;
}

@keyframes auroraMove {
  0% { transform: translate3d(0,0,0) scale(1); }
  50% { transform: translate3d(24px,-18px,0) scale(1.05); }
  100% { transform: translate3d(-18px,18px,0) scale(1.02); }
}

.page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem 1.4rem 5rem;
  padding-top: calc(env(safe-area-inset-top, 0) + 5.5rem); /* espaço para header sticky */
}

/* HEADER */

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
  background: radial-gradient(circle at 0% 0%, rgba(248,250,252,0.06), transparent 55%),
              radial-gradient(circle at 100% 100%, rgba(251,191,36,0.10), transparent 55%),
              linear-gradient(145deg, rgba(15,23,42,0.96), rgba(15,23,42,0.98));
  border: 1px solid rgba(148,163,184,0.32);
  box-shadow: 0 18px 50px rgba(0,0,0,0.9);
  margin-bottom: 2rem;
  position: fixed;
  top: env(safe-area-inset-top, 0.9rem);
  left: 50%;
  transform: translateX(-50%);
  max-width: 1180px;
  width: calc(100% - 2.8rem);
  z-index: 9999;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  /* fade suave na entrada */
  opacity: 0;
  animation: headerFadeIn 0.7s ease-out 0.15s forwards;
}

@keyframes headerFadeIn {
  to {
    opacity: 1;
  }
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-circle {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: radial-gradient(circle at 50% 50%, #0f172a, #020617 55%, #000 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  font-weight: 900;
  letter-spacing: 0.04em;
  box-shadow:
    0 0 20px rgba(250,204,21,0.8),
    0 8px 24px rgba(0,0,0,0.9);
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease;

  /* brilho pulsante contínuo */
  animation: logoPulse 3s ease-in-out infinite;
}

@keyframes logoPulse {
  0% {
    box-shadow:
      0 0 16px rgba(250,204,21,0.45),
      0 8px 24px rgba(0,0,0,0.95);
    transform: translateY(0) scale(1);
  }
  50% {
    box-shadow:
      0 0 26px rgba(250,204,21,0.9),
      0 10px 28px rgba(0,0,0,0.95);
    transform: translateY(-1px) scale(1.03);
  }
  100% {
    box-shadow:
      0 0 16px rgba(250,204,21,0.45),
      0 8px 24px rgba(0,0,0,0.95);
    transform: translateY(0) scale(1);
  }
}

.logo-circle:hover {
  transform: translateY(-1px) scale(1.05);
  box-shadow:
    0 0 30px rgba(250,204,21,0.95),
    0 12px 30px rgba(0,0,0,1);
}

.logo-circle img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  display: block;
}

.logo-name {
  height: 22px;
  max-width: 150px;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(0,0,0,0.9));
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.brand-tagline {
  font-size: 0.78rem;
  color: var(--muted);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.tag-pill {
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.4);
  color: var(--muted);
  background: rgba(15,23,42,0.9);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.tag-pill svg {
  width: 14px;
  height: 14px;
  stroke: var(--gold);
  flex-shrink: 0;
}

.btn-header-ghost {
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.4);
  background: rgba(15,23,42,0.9);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  transition: 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.btn-header-ghost svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.btn-header-ghost:hover {
  background: rgba(148,163,184,0.15);
  transform: translateY(-1px);
}

.btn-header-login {
  padding: 0.55rem 1.3rem;
  border-radius: 999px;
  border: 1px solid rgba(250,204,21,0.5);
  background: rgba(15,23,42,0.95);
  color: var(--gold);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: 0.18s ease;
  position: relative;
  overflow: hidden;
}

.btn-header-login:hover {
  background: rgba(250,204,21,0.14);
  transform: translateY(-1px);
}

/* micro-loading visual no botão (aparece em hover) */
.btn-header-login::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  width: 12px;
  height: 12px;
  margin-top: -6px;
  border-radius: 999px;
  border: 2px solid rgba(250,204,21,0.6);
  border-top-color: transparent;
  opacity: 0;
  transform: scale(0.5);
  pointer-events: none;
}

.btn-header-login:hover::after {
  opacity: 1;
  transform: scale(1);
  animation: headerSpinner 0.7s linear infinite;
}

@keyframes headerSpinner {
  to { transform: scale(1) rotate(360deg); }
}

/* HERO */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.95fr);
  gap: 1.8rem;
  align-items: center;
  margin-top: 1.8rem;
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: minmax(0,1fr);
  }
}

.hero-title {
  font-size: 2.7rem;
  font-weight: 800;
  color: #f9fafb;
  letter-spacing: 0.02em;
  line-height: 1.15;
}

.hero-title span {
  color: var(--gold);
  text-shadow: 0 0 26px rgba(250,204,21,0.5);
}

.hero-subtitle {
  margin-top: 1rem;
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 520px;
  line-height: 1.6;
}

.hero-subtitle-strong {
  margin-top: 0.5rem;
  font-size: 0.94rem;
  color: #e5e7eb;
  max-width: 540px;
  line-height: 1.5;
}

.hero-subtitle-strong span {
  color: var(--gold);
  font-weight: 600;
}

.hero-highlights {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  font-size: 0.78rem;
}

.hero-highlights span {
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.5);
  background: rgba(15,23,42,0.9);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.hero-highlights svg {
  width: 15px;
  height: 15px;
  stroke: var(--gold);
}

.hero-cta {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
}

.btn-primary {
  padding: 0.95rem 2.2rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  background: linear-gradient(90deg, #fbbf24, #facc15, #f97316);
  color: #111827;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow:
    0 14px 34px rgba(0,0,0,0.85),
    0 0 30px rgba(250,204,21,0.7);
  transition: 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.btn-primary svg {
  width: 18px;
  height: 18px;
  stroke: #111827;
  flex-shrink: 0;
}

.btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.03);
}

.btn-outline {
  padding: 0.9rem 1.8rem;
  border-radius: 999px;
  border: 1px solid rgba(250,204,21,0.5);
  background: rgba(15,23,42,0.9);
  color: var(--gold);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.btn-outline svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  stroke: var(--gold);
}

.btn-outline:hover {
  background: rgba(250,204,21,0.18);
  transform: translateY(-2px);
}

.hero-trust {
  margin-top: 0.8rem;
  font-size: 0.78rem;
  color: var(--muted);
}

/* HERO DEMO */

.hero-demo {
  position: relative;
  padding: 1.3rem;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 0% 0%, rgba(248,250,252,0.06), transparent 55%),
    radial-gradient(circle at 100% 100%, rgba(251,191,36,0.12), transparent 55%),
    linear-gradient(145deg, rgba(15,23,42,0.98), rgba(15,23,42,0.96));
  border: 1px solid rgba(148,163,184,0.45);
  box-shadow:
    0 24px 70px rgba(0,0,0,0.95),
    0 0 30px rgba(15,23,42,0.9);
  overflow: hidden;
}

.hero-demo-tag {
  font-size: 0.74rem;
  color: var(--muted);
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hero-demo-tag span:last-child {
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.6);
  background: rgba(15,23,42,0.95);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.hero-demo-tag svg {
  width: 13px;
  height: 13px;
  stroke: var(--muted);
}

.hero-demo img {
  width: 100%;
  border-radius: 1.2rem;
  border: 1px solid rgba(15,23,42,0.9);
  box-shadow:
    0 18px 45px rgba(0,0,0,0.8),
    0 0 26px rgba(15,23,42,0.9);
  object-fit: cover;
  display: block;
}

.hero-demo-kpis {
  margin-top: 0.9rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 0.7rem;
  font-size: 0.78rem;
}

.hero-demo-kpi {
  padding: 0.5rem 0.6rem;
  border-radius: 0.9rem;
  background: rgba(15,23,42,0.9);
  border: 1px solid rgba(148,163,184,0.4);
}

.hero-demo-kpi-label {
  color: var(--muted);
}

.hero-demo-kpi-value {
  margin-top: 0.2rem;
  font-weight: 700;
}

.hero-demo-kpi-value.in { color: var(--success); }
.hero-demo-kpi-value.out { color: var(--danger); }
.hero-demo-kpi-value.neutral { color: var(--gold); }

/* SEÇÃO VANTAGENS / TRANSFORMAÇÃO */

.section {
  margin-top: 4rem;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 0.4rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-title svg {
  width: 18px;
  height: 18px;
  stroke: var(--gold);
}

.section-subtitle {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 620px;
}

.advantages-grid {
  margin-top: 2.2rem;
  display: grid;
  grid-template-columns: minmax(0,1.3fr) minmax(0,1fr);
  gap: 1.6rem;
}

@media (max-width: 900px) {
  .advantages-grid {
    grid-template-columns: minmax(0,1fr);
  }
}

.adv-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}

.adv-card {
  padding: 1rem;
  border-radius: 1.3rem;
  background: rgba(15,23,42,0.9);
  border: 1px solid rgba(148,163,184,0.4);
}

.adv-card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.adv-card-icon {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(15,23,42,0.9);
  border: 1px solid rgba(250,204,21,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
}

.adv-card-icon svg {
  width: 14px;
  height: 14px;
  stroke: var(--gold);
}

.adv-card h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.adv-card p {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

.before-after {
  padding: 1.1rem;
  border-radius: 1.3rem;
  background: radial-gradient(circle at 0% 0%, rgba(248,250,252,0.03), transparent 55%),
              radial-gradient(circle at 100% 100%, rgba(250,204,21,0.08), transparent 55%),
              linear-gradient(145deg, rgba(15,23,42,0.98), rgba(15,23,42,0.96));
  border: 1px solid rgba(148,163,184,0.5);
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 0.9rem;
  font-size: 0.88rem;
}

@media (max-width: 640px) {
  .before-after {
    grid-template-columns: minmax(0,1fr);
  }
}

.ba-col h4 {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
}

.ba-col ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.ba-col li {
  margin-bottom: 0.3rem;
}

.ba-col.before h4 { color: var(--muted); }
.ba-col.after h4 { color: var(--gold); }

/* TECNOLOGIA */

.tech-strip {
  margin-top: 4rem;
  padding: 2.6rem 1.6rem;
  border-radius: 1.7rem;
  background:
    radial-gradient(circle at 50% 0%, rgba(56,189,248,0.18), transparent 65%),
    linear-gradient(145deg, rgba(15,23,42,0.98), rgba(15,23,42,0.96));
  border: 1px solid rgba(148,163,184,0.55);
  box-shadow: 0 20px 60px rgba(0,0,0,0.9);
  text-align: center;
}

.tech-icons {
  margin-top: 1.3rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.8rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.tech-pill {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.55);
  background: rgba(15,23,42,0.96);
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.tech-pill svg {
  width: 15px;
  height: 15px;
  stroke: var(--gold);
}

/* CTA FINAL */

.final-cta {
  margin-top: 3.6rem;
  padding: 1.4rem 1.2rem;
  border-radius: 1.5rem;
  background: linear-gradient(135deg, rgba(15,23,42,0.98), rgba(15,23,42,0.92));
  border: 1px solid rgba(250,204,21,0.4);
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
  justify-content: space-between;
}

.final-cta-text {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 620px;
}

.final-cta-text span {
  color: var(--gold);
  font-weight: 600;
}

footer {
  margin-top: 2.6rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

/* MOBILE AJUSTES */

@media (max-width: 640px) {
  .page {
    padding-inline: 1rem;
    padding-top: calc(env(safe-area-inset-top, 0) + 6.5rem);
  }
  
  .header {
    border-radius: 1.4rem;
    padding: 0.8rem 1rem;
    width: calc(100% - 2rem);
    top: env(safe-area-inset-top, 0.5rem);
  }
  
  .hero {
    margin-top: 1rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 0.95rem;
  }
  
  .hero-cta {
    margin-top: 1.5rem;
    width: 100%;
  }
  
  .btn-primary,
  .btn-outline {
    width: 100%;
    justify-content: center;
    font-size: 0.95rem;
    padding: 0.85rem 1.5rem;
  }
  
  .hero-demo-kpis {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
  
  .hero-highlights {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }
  
  .hero-highlights span {
    white-space: normal;
    justify-content: center;
  }
  
  .section-title {
    font-size: 1.6rem;
  }
  
  .section-subtitle {
    font-size: 0.9rem;
  }
  
  .final-cta {
    flex-direction: column;
    text-align: center;
    gap: 1.2rem;
  }
  
  .final-cta .btn-primary {
    width: 100%;
  }
}

/* =====================================================================
   CORREÇÃO DO BUG NO MOBILE — LOGO SUMINDO NO iPHONE
   ===================================================================== */

/* Impede que a área da logo seja encolhida. */
.header-left {
  flex-shrink: 0 !important;
  min-width: 0;
}

/* Garante que a bolinha nunca desapareça ou seja comprimida */
.logo-circle {
  flex-shrink: 0 !important;
  min-width: 44px;
  min-height: 44px;
}

/* Garante que a logo-name também não suma */
.logo-name {
  flex-shrink: 0 !important;
  max-width: 140px;
}

/* Reorganização do header em telas muito pequenas */
@media (max-width: 580px) {
  .page {
    padding-top: calc(env(safe-area-inset-top, 0) + 8.5rem);
  }
  
  .header {
    flex-direction: column;
    align-items: center;
    padding: 1rem 1.2rem;
    gap: 12px;
    text-align: center;
  }

  .header-left {
    width: 100%;
    justify-content: center;
  }

  .header-right {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
  }

  .tag-pill,
  .btn-header-ghost {
    font-size: 0.75rem;
    padding: 0.3rem 0.6rem;
  }

  .logo-name {
    max-width: 120px;
  }

  .brand-tagline {
    font-size: 0.7rem;
  }

  .btn-header-login {
    flex-shrink: 0 !important;
    white-space: nowrap;
    font-size: 0.8rem;
    padding: 0.5rem 1.1rem;
  }
}

/* =================================================
   GRÁFICOS DEMONSTRATIVOS
   ================================================= */

.charts-demo-section {
  margin-top: 4rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  animation: fadeInUp 0.8s ease-out 0.3s backwards;
}

.chart-demo-card {
  background: radial-gradient(circle at 0% 0%, rgba(248,250,252,0.04), transparent 65%),
              radial-gradient(circle at 100% 100%, rgba(251,191,36,0.08), transparent 65%),
              linear-gradient(145deg, rgba(15,23,42,0.7), rgba(15,23,42,0.8));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 1rem;
  padding: 1.5rem;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4), 
              inset 0 1px 0 rgba(255,255,255,0.05);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.chart-demo-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(250,204,21,0.6) 30%, 
    rgba(56,189,248,0.6) 70%, 
    transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.chart-demo-card:hover::before {
  opacity: 1;
}

.chart-demo-card:hover {
  transform: translateY(-4px);
  border-color: rgba(148, 163, 184, 0.4);
  box-shadow: 0 12px 48px rgba(0,0,0,0.6), 
              inset 0 1px 0 rgba(255,255,255,0.08),
              0 0 0 1px rgba(250,204,21,0.2);
}

.chart-demo-card h3 {
  color: #e5e7eb;
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 1rem 0;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.chart-demo-card > div[id^="chart-"] {
  width: 100%;
  height: 240px;
  position: relative;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .charts-demo-section {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 2.5rem;
  }
  
  .chart-demo-card {
    padding: 1.2rem;
  }
  
  .chart-demo-card > div[id^="chart-"] {
    height: 220px;
  }
}

/* ============================================================
   DEMO (KPIs + GRÁFICOS) no padrão do dashboard
   ============================================================ */

.landing-dash-stack {
  margin-top: 3rem;
  display: grid;
  gap: 1.5rem;
}

/* No index o gráfico não precisa ser tão alto quanto no app */
.landing-dash-stack .dash-chart {
  height: 240px;
}

.landing-dash-stack #kpis .dash-card-header {
  margin-bottom: 12px;
}

@media (max-width: 640px) {
  .landing-dash-stack {
    margin-top: 2.4rem;
    gap: 1rem;
  }

  .landing-dash-stack .dash-chart {
    height: 220px;
  }
}