:root {
  --bg-midnight: #080809;
  --surface-glass: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --accent-gold: #D4AF37;
  --text-main: #FAFAF9;
  --text-muted: #A1A1AA;
  --border-light: rgba(255, 255, 255, 0.09);
  --border-accent: rgba(212, 175, 55, 0.34);
}

* {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Skip link ─────────────────────────────────────────────── */
.skip-link {
  position: fixed;
  top: -100%;
  left: 1rem;
  z-index: 9999;
  padding: 0.65rem 1.25rem;
  background: var(--accent-gold);
  color: #080809;
  font-weight: 800;
  font-size: 0.875rem;
  border-radius: 0 0 0.75rem 0.75rem;
  text-decoration: none;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: 0;
}

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-midnight);
  color: var(--text-main);
  background-image:
    radial-gradient(circle at 50% 0%, rgba(212, 175, 55, 0.08), transparent 36rem),
    radial-gradient(circle at 12% 18%, rgba(34, 197, 94, 0.05), transparent 24rem),
    linear-gradient(180deg, #080809 0%, #0b0b0d 45%, #070708 100%);
  background-attachment: fixed;
}

section[id] {
  scroll-margin-top: 5.5rem;
}

main,
section,
header,
footer {
  max-width: 100%;
  overflow-x: clip;
}

.glass-nav {
  background: rgba(8, 8, 9, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
}

.bento-card {
  background: var(--surface-glass);
  border: 1px solid var(--border-light);
  border-radius: 1.25rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.35s ease, background 0.35s ease;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  min-width: 0;
}

.bento-card:hover {
  background: var(--surface-hover);
  transform: translateY(-3px);
  border-color: var(--border-accent);
  box-shadow: 0 22px 50px -16px rgba(0, 0, 0, 0.9), 0 0 28px -12px rgba(212, 175, 55, 0.22);
}

.card-icon {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-light);
  border-radius: 1rem;
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  transition: all 0.35s ease;
}

.bento-card:hover .card-icon {
  background: var(--accent-gold);
  color: var(--bg-midnight);
  border-color: var(--accent-gold);
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.32);
}

.premium-btn,
.premium-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-main);
  border: 1px solid var(--border-light);
  border-radius: 999px;
  padding: 0.78rem 1.5rem;
  transition: all 0.2s ease;
  background: transparent;
  width: max-content;
  max-width: 100%;
  margin-top: 1.5rem;
  cursor: pointer;
  text-decoration: none;
}

.premium-btn:hover,
.premium-link:hover {
  transform: translateY(-2px);
}

.premium-btn.primary,
.premium-link.primary {
  background: var(--accent-gold);
  color: var(--bg-midnight);
  border-color: var(--accent-gold);
}

.premium-btn.primary:hover,
.premium-link.primary:hover {
  background: #c39e2e;
  border-color: #c39e2e;
}

.premium-btn.light,
.premium-link.light {
  background: var(--text-main);
  color: var(--bg-midnight);
  border-color: var(--text-main);
}

.premium-btn.light:hover,
.premium-link.light:hover {
  background: var(--accent-gold);
  color: var(--bg-midnight);
  border-color: var(--accent-gold);
}

.tab-btn {
  background: var(--surface-glass);
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  padding: 0.75rem 1.45rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  transition: all 0.25s ease;
  cursor: pointer;
  flex: 0 0 auto;
}

.tab-btn:hover {
  background: var(--surface-hover);
  color: var(--text-main);
}

.tab-btn.active {
  background: rgba(212, 175, 55, 0.12);
  border-color: var(--border-accent);
  color: var(--accent-gold);
}

.tab-pane {
  display: none;
  animation: smoothReveal 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.tab-pane.active {
  display: grid;
}

.scrollbar-none {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.scrollbar-none::-webkit-scrollbar {
  display: none;
}

.text-gradient-gold {
  background: linear-gradient(135deg, #fff 0%, #f3df98 42%, #D4AF37 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.proof-pill {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
  border-radius: 999px;
  padding: 0.55rem 0.85rem;
  color: #d4d4d8;
  font-size: 0.82rem;
  font-weight: 700;
}

.mobile-whatsapp {
  display: none;
}

.hero-kicker {
  max-width: 100%;
}

.tech-showcase {
  --light-bg: #ffffff;
  --light-card: rgba(255, 255, 255, 0.78);
  --light-card-strong: #ffffff;
  --light-text: #0f172a;
  --light-muted: #475569;
  --light-line: rgba(15, 23, 42, 0.11);
  color: var(--light-text);
  background-color: #fcfcfd;
  background-image:
    linear-gradient(115deg, transparent 35%, rgba(212, 175, 55, 0.08) 48%, rgba(212, 175, 55, 0.15) 50%, rgba(212, 175, 55, 0.08) 52%, transparent 65%),
    radial-gradient(circle at 50% 30%, #ffffff 15%, rgba(255, 255, 255, 0) 85%),
    radial-gradient(circle, rgba(15, 23, 42, 0.12) 1px, transparent 1.5px),
    linear-gradient(rgba(15, 23, 42, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, 0.05) 1px, transparent 1px);
  background-size: 200% 100%, 100% 100%, 45px 45px, 45px 45px, 45px 45px;
  background-position: 150% 0, 0 0, 0 0, 0 0, 0 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  overflow: hidden;
  isolation: isolate;
  animation: bgShimmer 8s ease-in-out infinite;
}

.tech-showcase::before {
  display: none;
}

@keyframes bgShimmer {
  0%, 20% {
    background-position: 150% 0, 0 0, 0 0, 0 0, 0 0;
  }
  80%, 100% {
    background-position: -50% 0, 0 0, 0 0, 0 0, 0 0;
  }
}

.tech-showcase .text-white,
.tech-showcase h2,
.tech-showcase h3 {
  color: var(--light-text) !important;
}

.tech-showcase .text-\[var\(--text-muted\)\],
.tech-showcase p {
  color: var(--light-muted) !important;
}

.tech-showcase .tab-track {
  width: max-content;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding: 0.45rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 24px 70px -48px rgba(15, 23, 42, 0.35);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.tech-showcase .tab-btn {
  background: transparent;
  border-color: transparent;
  color: #475569;
}

.tech-showcase .tab-btn:hover {
  background: rgba(15, 23, 42, 0.055);
  color: #0f172a;
}

.tech-showcase .tab-btn.active {
  background: #0f172a;
  color: #fff;
  border-color: #0f172a;
  box-shadow: 0 18px 35px -22px rgba(15, 23, 42, 0.9);
}

/* Catálogo em grid filtrável (o carrossel infinito foi substituído na Fase 2) */
.tech-showcase .tab-pane.active {
  display: grid;
}

.showcase-viewport {
  position: relative;
  min-height: 0;
}

.showcase-rail {
  padding: 0.75rem 0 1rem;
  margin: 0;
}

.showcase-rail>* {
  min-width: 0;
}

.tech-showcase article[data-offer] {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.68)),
    var(--light-card);
  border: 1px solid var(--light-line);
  border-radius: 1.35rem;
  box-shadow: 0 28px 74px -48px rgba(15, 23, 42, 0.42);
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(0);
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.5s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.4s ease, background 0.4s ease;
  will-change: transform;
}

.tech-showcase article[data-offer] h3 {
  font-size: clamp(1.45rem, 2vw, 2.15rem) !important;
}

.tech-showcase article[data-offer] h4,
.tech-showcase article[data-offer] .text-2xl,
.tech-showcase article[data-offer] .text-3xl,
.tech-showcase article[data-offer] .md\:text-4xl {
  font-size: clamp(1.75rem, 3.1vw, 3.35rem) !important;
  line-height: 1.05 !important;
  max-width: 44rem;
}

.tech-showcase article[data-offer] p {
  max-width: 48rem;
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.75;
}

.tech-showcase article[data-offer]::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 50%), rgba(212, 175, 55, 0.08), transparent 22rem);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.tech-showcase article[data-offer]:hover {
  border-color: rgba(212, 175, 55, 0.20);
  box-shadow: 0 20px 50px -28px rgba(15, 23, 42, 0.28), 0 0 0 1px rgba(212, 175, 55, 0.05);
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(-2px);
}

.tech-showcase article[data-offer]:hover::after {
  opacity: 1;
}

.tech-showcase .bento-card:hover {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.76)),
    var(--light-card-strong);
}

.tech-showcase .card-icon {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.055);
  border-color: rgba(15, 23, 42, 0.1);
}

.tech-showcase .premium-btn,
.tech-showcase .premium-link {
  color: #0f172a;
  border-color: rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.tech-showcase .premium-btn:hover,
.tech-showcase .premium-link:hover,
.tech-showcase .premium-btn.primary,
.tech-showcase .premium-link.primary {
  color: #080809;
  background: var(--accent-gold);
  border-color: var(--accent-gold);
}

@keyframes smoothReveal {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.99);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 767px) {
  body {
    background-attachment: scroll;
  }

  .mobile-whatsapp {
    display: inline-flex;
    padding: 0.65rem 0.9rem;
    font-size: 0.78rem;
    max-width: 8rem;
    white-space: nowrap;
    overflow: hidden;
  }

  .hero-title {
    font-size: 2.35rem !important;
    line-height: 1.04 !important;
    max-width: calc(100vw - 2rem) !important;
  }

  .hero-kicker {
    width: calc(100vw - 2rem);
    justify-content: center;
    align-items: center;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .hero-kicker span:last-child {
    white-space: normal;
    line-height: 1.35;
    overflow-wrap: anywhere;
  }

  section h2,
  section h3,
  section p {
    max-width: calc(100vw - 2rem);
    overflow-wrap: anywhere;
  }

  section h2 {
    font-size: 1.85rem !important;
    line-height: 1.12 !important;
  }

  .proof-pill {
    max-width: calc(100vw - 2rem);
    white-space: normal;
    text-align: center;
  }

  .bento-card {
    padding: 1.35rem;
    border-radius: 1rem;
  }

  .premium-btn,
  .premium-link {
    width: 100%;
    min-height: 3rem;
  }

  .tab-track {
    margin-left: 0;
    margin-right: 0;
  }
}

/* Focus-visible nos painéis de aba (tabindex="0") */
.tab-pane:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 4px;
  border-radius: 0.5rem;
}

/* ============================================================
   NICHE FILTER CHIPS
   ============================================================ */

.niche-filter-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  min-height: 2rem;
}

.niche-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.niche-chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
  white-space: nowrap;
  line-height: 1;
}

.niche-chip:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.2);
}

.niche-chip.active {
  background: var(--accent-gold);
  color: #08090b;
  border-color: var(--accent-gold);
  box-shadow: 0 6px 18px -8px rgba(212, 175, 55, 0.6);
}

/* Variante clara: os chips são injetados dentro da seção .tech-showcase (fundo claro) */
.tech-showcase .niche-chip {
  background: rgba(15, 23, 42, 0.05);
  border-color: rgba(15, 23, 42, 0.16);
  color: #475569;
}

.tech-showcase .niche-chip:hover {
  background: rgba(15, 23, 42, 0.1);
  border-color: rgba(15, 23, 42, 0.28);
  color: #0f172a;
}

.tech-showcase .niche-chip.active {
  background: #0f172a;
  border-color: #0f172a;
  color: #fff;
  box-shadow: 0 10px 24px -14px rgba(15, 23, 42, 0.8);
}


/* ============================================================
   FILTERED-OUT CARD (niche filter)
   ============================================================ */

.card-hidden {
  display: none !important;
}

/* ============================================================
   DEMO MODAL LOADER
   ============================================================ */

.demo-loader {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  transition: opacity 0.25s ease;
}

.demo-loader.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.demo-spinner {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  border: 3px solid rgba(15, 23, 42, 0.12);
  border-top-color: var(--accent-gold);
  animation: demo-spin 0.8s linear infinite;
}

@keyframes demo-spin {
  to { transform: rotate(360deg); }
}

/* ============================================================
   TECH HERO (malha tecnológica adaptada ao tema escuro)
   ============================================================ */
.tech-hero {
  position: relative;
}

.tech-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.045) 1px, transparent 1.5px),
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 45px 45px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, black 20%, transparent 80%);
  mask-image: radial-gradient(circle at 50% 50%, black 20%, transparent 80%);
}

/* Hover simplificado para os botões do Hero (sem brilho, elevação ou iluminação dourada) */
.tech-hero .premium-btn:hover,
.tech-hero .premium-link:hover {
  transform: none;
}

.tech-hero .premium-btn.primary:hover,
.tech-hero .premium-link.primary:hover {
  background: #c39e2e;
  border-color: #c39e2e;
  box-shadow: none;
}

.tech-hero .premium-btn.light:hover,
.tech-hero .premium-link.light:hover {
  background: #e2e8f0;
  border-color: #e2e8f0;
  color: var(--bg-midnight);
  box-shadow: none;
}

/* ============================================================
   MOVIMENTO REDUZIDO (acessibilidade)
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto !important;
  }

  .tech-showcase article[data-offer] {
    transform: none !important;
  }
}
