/* =========================================================================
   BIT INFORMÁTICA — styles.css
   Camada de estilos customizados que complementa o TailwindCSS.
   Paleta e tokens seguem a identidade visual da marca (preto, cinza, vermelho).
   ========================================================================= */

:root {
  /* --- Cores de marca --- */
  --bit-black: #0D0D0D;
  --bit-charcoal: #1B1B1B;
  --bit-charcoal-2: #232323;
  --bit-red: #D40000;
  --bit-red-dim: #A30000;
  --bit-red-glow: rgba(212, 0, 0, 0.35);
  --bit-light: #F5F5F5;
  --bit-white: #FFFFFF;
  --bit-line: rgba(245, 245, 245, 0.08);
  --bit-line-strong: rgba(245, 245, 245, 0.16);

  /* --- Tipografia --- */
  --font-display: 'Barlow Condensed', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* --- Timing --- */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* =========================================================================
   BASE
   ========================================================================= */

html {
  scroll-behavior: smooth;
}

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

body {
  background-color: var(--bit-black);
  color: var(--bit-light);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5,
.font-display {
  font-family: var(--font-display);
  letter-spacing: 0.01em;
}

.font-mono {
  font-family: var(--font-mono);
}

::selection {
  background: var(--bit-red);
  color: var(--bit-white);
}

/* Focus visível para acessibilidade em toda navegação por teclado */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--bit-red);
  outline-offset: 3px;
  border-radius: 2px;
}

/* Scrollbar discreta */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bit-black); }
::-webkit-scrollbar-thumb { background: var(--bit-charcoal-2); border-radius: 6px; border: 2px solid var(--bit-black); }
::-webkit-scrollbar-thumb:hover { background: var(--bit-red-dim); }

/* =========================================================================
   UTILITÁRIOS DE MARCA
   ========================================================================= */

.text-brand-red { color: var(--bit-red); }
.bg-brand-black { background-color: var(--bit-black); }
.bg-brand-charcoal { background-color: var(--bit-charcoal); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--bit-red);
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.eyebrow::before {
  content: '';
  width: 22px;
  height: 1px;
  background: var(--bit-red);
  display: inline-block;
}

.hairline {
  border-color: var(--bit-line);
}

.section-pad {
  padding-top: clamp(4rem, 8vw, 7rem);
  padding-bottom: clamp(4rem, 8vw, 7rem);
}

/* =========================================================================
   BOTÕES
   ========================================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.95rem 1.8rem;
  border-radius: 2px;
  transition: transform 0.35s var(--ease-out), background-color 0.35s var(--ease-out), color 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), border-color .35s var(--ease-out);
  white-space: nowrap;
}

.btn-primary {
  background: var(--bit-red);
  color: var(--bit-white);
  border: 1px solid var(--bit-red);
}

.btn-primary:hover {
  background: var(--bit-white);
  color: var(--bit-black);
  border-color: var(--bit-white);
  box-shadow: 0 0 0 1px var(--bit-white);
}

.btn-ghost {
  background: transparent;
  color: var(--bit-light);
  border: 1px solid var(--bit-line-strong);
}

.btn-ghost:hover {
  border-color: var(--bit-red);
  color: var(--bit-white);
}

.btn:active { transform: scale(0.97); }

/* =========================================================================
   HONEYPOT (ANTI-SPAM)
   Campo mantido no DOM e acessível a "bots" simples, mas invisível e
   inalcançável para pessoas reais (não usa display:none, que alguns bots
   já sabem detectar e ignorar).
   ========================================================================= */

.hp-field {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  left: -9999px;
  display:none;
}

/* =========================================================================
   BOTÃO FLUTUANTE — WHATSAPP
   Identidade visual oficial do WhatsApp (verde #25D366 / hover #128C7E).
   ========================================================================= */

.whatsapp-float {
  background-color: #25D366;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 0 0 rgba(37, 211, 102, 0.55);
  transition: background-color 0.3s var(--ease-out), transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
  animation: whatsapp-pulse 2.6s ease-in-out infinite;
}

.whatsapp-float:hover,
.whatsapp-float:focus-visible {
  background-color: #128C7E;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.4), 0 0 0 0 rgba(18, 140, 126, 0.5);
  animation-play-state: paused;
}

@keyframes whatsapp-pulse {
  0%, 100% { box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 0 0 rgba(37, 211, 102, 0.45); }
  50% { box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 0 8px rgba(37, 211, 102, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .whatsapp-float { animation: none; }
}

/* =========================================================================
   NAVEGAÇÃO
   ========================================================================= */

.site-header {
  backdrop-filter: blur(14px);
  background: rgba(13, 13, 13, 0.82);
  border-bottom: 1px solid var(--bit-line);
}

.nav-link {
  position: relative;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bit-light);
  opacity: 0.75;
  transition: opacity 0.25s var(--ease-out);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0%;
  height: 1px;
  background: var(--bit-red);
  transition: width 0.3s var(--ease-out);
}

.nav-link:hover,
.nav-link[aria-current="page"] {
  opacity: 1;
}

.nav-link:hover::after,
.nav-link[aria-current="page"]::after {
  width: 100%;
}

/* =========================================================================
   ASSINATURA VISUAL — "SCANLINE DE DIAGNÓSTICO"
   Um feixe fino que varre cards e painéis no hover, remetendo ao ato de
   diagnosticar hardware — o cerne do serviço da BIT.
   ========================================================================= */

.scan-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.scan-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 0%, var(--bit-red-glow) 50%, transparent 100%);
  transform: translateY(-140%);
  opacity: 0;
  transition: transform 0.9s var(--ease-out), opacity 0.4s ease;
}

.scan-card:hover::before,
.scan-card:focus-within::before {
  transform: translateY(140%);
  opacity: 1;
}

.scan-card::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 2px;
  width: 100%;
  background: var(--bit-red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease-out);
  z-index: 3;
}

.scan-card:hover::after,
.scan-card:focus-within::after {
  transform: scaleX(1);
}

/* Indicador tipo LED de status (usado em cards de serviço/loja) */
.led {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--bit-red);
  box-shadow: 0 0 8px 1px var(--bit-red-glow);
  display: inline-block;
  flex-shrink: 0;
}

.led-pulse {
  animation: led-pulse 2.4s ease-in-out infinite;
}

@keyframes led-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px 1px var(--bit-red-glow); }
  50% { opacity: 0.45; box-shadow: 0 0 3px 0 var(--bit-red-glow); }
}

/* =========================================================================
   PAINEL / CARD BASE
   ========================================================================= */

.panel {
  background: var(--bit-charcoal);
  border: 1px solid var(--bit-line);
}

.panel-hover {
  transition: border-color 0.35s var(--ease-out), transform 0.35s var(--ease-out), background-color .35s var(--ease-out);
}

.panel-hover:hover {
  border-color: var(--bit-line-strong);
  transform: translateY(-4px);
  background: var(--bit-charcoal-2);
}

/* Numeração técnica tipo "spec sheet" */
.spec-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: rgba(245, 245, 245, 0.35);
  letter-spacing: 0.08em;
}

/* =========================================================================
   HERO
   ========================================================================= */

.hero-grid-bg {
  background-image:
    linear-gradient(rgba(245, 245, 245, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245, 245, 245, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 60% at 60% 30%, black 40%, transparent 90%);
}

.hero-glow {
  background: radial-gradient(600px circle at 75% 20%, var(--bit-red-glow), transparent 60%);
  filter: blur(10px);
}

.text-outline {
  -webkit-text-stroke: 1px rgba(245, 245, 245, 0.25);
  color: transparent;
}

/* Contador de anos em destaque no hero */
.stat-block { border-left: 2px solid var(--bit-red); }

/* =========================================================================
   MARQUEE DE MARCAS
   ========================================================================= */

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

.brand-track:hover { animation-play-state: paused; }

@keyframes brand-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .brand-track { animation: none; }
}

/* =========================================================================
   ACCORDION (FAQ)
   ========================================================================= */

.accordion-item { border-bottom: 1px solid var(--bit-line); }

.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  text-align: left;
  padding: 1.4rem 0;
  cursor: pointer;
  background: transparent;
}

.accordion-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  position: relative;
}

.accordion-icon::before,
.accordion-icon::after {
  content: '';
  position: absolute;
  background: var(--bit-red);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}

.accordion-icon::before { width: 14px; height: 2px; }
.accordion-icon::after { width: 2px; height: 14px; transition: transform 0.3s var(--ease-out), opacity .3s; }

.accordion-trigger[aria-expanded="true"] .accordion-icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
  opacity: 0;
}

.accordion-panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s var(--ease-out);
}

.accordion-panel > div { overflow: hidden; }

.accordion-item.is-open .accordion-panel {
  grid-template-rows: 1fr;
}

/* =========================================================================
   FORMULÁRIO
   ========================================================================= */

.field {
  width: 100%;
  background: var(--bit-charcoal);
  border: 1px solid var(--bit-line-strong);
  color: var(--bit-white);
  padding: 0.9rem 1rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  border-radius: 2px;
  transition: border-color 0.25s var(--ease-out), background-color .25s;
}

.field::placeholder { color: rgba(245, 245, 245, 0.35); }

.field:focus {
  border-color: var(--bit-red);
  background: var(--bit-charcoal-2);
  outline: none;
}

.field-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(245, 245, 245, 0.55);
  margin-bottom: 0.5rem;
  display: block;
}

/* =========================================================================
   BADGE DE CATEGORIA (LOJA)
   ========================================================================= */

.tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--bit-line-strong);
  color: rgba(245, 245, 245, 0.75);
  border-radius: 2px;
  transition: border-color .3s var(--ease-out), color .3s var(--ease-out), background-color .3s var(--ease-out);
}

.tag:hover {
  border-color: var(--bit-red);
  color: var(--bit-white);
  background: rgba(212, 0, 0, 0.08);
}

/* =========================================================================
   REVEAL ON SCROLL
   ========================================================================= */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

/* =========================================================================
   SKIP LINK
   ========================================================================= */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--bit-red);
  color: var(--bit-white);
  padding: 1rem 1.5rem;
  z-index: 100;
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* =========================================================================
   BACK TO TOP
   ========================================================================= */

#backToTop {
  transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}

#backToTop.hidden-btn {
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
}

/* =========================================================================
   RESPONSIVO — ajustes finos
   ========================================================================= */

@media (max-width: 640px) {
  .hero-grid-bg { background-size: 30px 30px; }
}
