/* ============================================================
   TTS Digital — Shared site styles
   Dark, cinematic, industrial. Used with Tailwind CDN.
============================================================ */

:root {
  --bg: #0a0a0a;
  --red: #e11d2a;
  --red-soft: #ff3b46;
}

* { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

html { scroll-behavior: smooth; }
body {
  background-color: var(--bg);
  font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
}

::selection { background: var(--red); color: #fff; }

::-webkit-scrollbar { width: 9px; }
::-webkit-scrollbar-track { background: #0a0a0a; }
::-webkit-scrollbar-thumb { background: #1f1f1f; border-radius: 9px; }
::-webkit-scrollbar-thumb:hover { background: #2c2c2c; }

/* Faint technical grid background */
.tech-grid {
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 64px 64px;
}

/* Cinematic vignette */
.vignette::after {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(0,0,0,0) 38%, rgba(0,0,0,0.85) 100%);
}

/* Machine glow / drop shadow */
.machine-glow {
  filter: drop-shadow(0 40px 80px rgba(0,0,0,0.9))
          drop-shadow(0 0 60px rgba(225,29,42,0.18));
}

/* Red radial glow blob */
.glow-red {
  background: radial-gradient(circle, rgba(225,29,42,0.30) 0%, rgba(225,29,42,0) 70%);
}

/* Pulsing glow */
@keyframes glowPulse { 0%,100% { opacity: .5; } 50% { opacity: .9; } }
.glow-pulse { animation: glowPulse 5.5s ease-in-out infinite; }

/* Eyebrow label */
.eyebrow {
  font-size: 11px; font-weight: 600; letter-spacing: 0.45em;
  text-transform: uppercase; color: var(--red);
}

/* Big display headline */
.display {
  font-weight: 800; letter-spacing: -0.02em; line-height: 0.95;
}

/* Reveal-on-scroll: initial hidden state (JS removes via GSAP) */
.reveal { opacity: 0; }

/* Prevent flash of stacked machines/specs before GSAP initializes */
.showcase-pin .scene-machine,
.showcase-pin .spec { opacity: 0; }

/* Accessibility: if user prefers reduced motion, show everything */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1 !important; }
}

/* Link underline animation */
.link-underline { position: relative; }
.link-underline::after {
  content: ""; position: absolute; left: 0; bottom: -3px; height: 1px; width: 0;
  background: var(--red); transition: width .35s ease;
}
.link-underline:hover::after { width: 100%; }

/* Buttons */
.btn-red {
  display: inline-flex; align-items: center; gap: .6rem;
  background: var(--red); color: #fff;
  padding: .95rem 2rem; border-radius: 999px;
  font-size: .8rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase;
  transition: background .25s ease, transform .25s ease;
}
.btn-red:hover { background: var(--red-soft); transform: translateY(-2px); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: .6rem;
  border: 1px solid rgba(255,255,255,0.18); color: #fff;
  padding: .95rem 2rem; border-radius: 999px;
  font-size: .8rem; font-weight: 600; letter-spacing: .15em; text-transform: uppercase;
  transition: border-color .25s ease, background .25s ease;
}
.btn-ghost:hover { border-color: var(--red); background: rgba(225,29,42,0.08); }

/* Spec chip */
.spec-chip {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  color: #d4d4d4; border: 1px solid rgba(255,255,255,0.12);
  padding: .45rem .85rem; border-radius: 999px; background: rgba(255,255,255,0.02);
}

/* Card hover */
.machine-card {
  transition: transform .4s cubic-bezier(.2,.7,.2,1), border-color .4s ease;
}
.machine-card:hover { transform: translateY(-6px); border-color: rgba(225,29,42,0.5); }

/* Marquee */
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.marquee-track { display: inline-flex; white-space: nowrap; animation: marquee 28s linear infinite; }

/* Hide scrollbar utility for horizontal areas */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ---------- Floating WhatsApp button ---------- */
.wa-fab {
  position: fixed; right: 22px; bottom: 22px; z-index: 60;
  width: 58px; height: 58px; border-radius: 999px;
  background: #25D366; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 12px 34px rgba(37,211,102,0.38);
  transition: transform .25s ease, box-shadow .25s ease;
  animation: waPulse 2.8s infinite;
}
.wa-fab:hover { transform: translateY(-3px) scale(1.05); box-shadow: 0 16px 40px rgba(37,211,102,0.5); }
.wa-fab svg { width: 31px; height: 31px; fill: #fff; }
.wa-fab::before {
  content: attr(data-label);
  position: absolute; right: 70px;
  background: #0a0a0a; color: #fff; border: 1px solid rgba(255,255,255,0.12);
  padding: .5rem .85rem; border-radius: 999px;
  font-size: .72rem; letter-spacing: .08em; white-space: nowrap;
  opacity: 0; transform: translateX(8px); transition: all .25s ease; pointer-events: none;
}
.wa-fab:hover::before { opacity: 1; transform: translateX(0); }
@keyframes waPulse {
  0%   { box-shadow: 0 12px 34px rgba(37,211,102,0.38), 0 0 0 0 rgba(37,211,102,0.5); }
  70%  { box-shadow: 0 12px 34px rgba(37,211,102,0.38), 0 0 0 16px rgba(37,211,102,0); }
  100% { box-shadow: 0 12px 34px rgba(37,211,102,0.38), 0 0 0 0 rgba(37,211,102,0); }
}
@media (max-width: 640px) {
  .wa-fab { right: 16px; bottom: 16px; width: 54px; height: 54px; }
  .wa-fab::before { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .wa-fab { animation: none; }
}
