/* =====================================================================
   SCAI.SI — CLEAN FUTURISTIC SCROLL-ANIMATED STYLING
   Typography: Plus Jakarta Sans (Headings) + Inter (Body) + JetBrains Mono (Specs)
   Non-intrusive scroll animations designed for optimal reading comfort
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800;900&display=swap');

:root {
  --font-display: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

html {
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  background-color: #030611;
  color: #F1F5F9;
}

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

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

/* =====================================================================
   TOP REAL-TIME SCROLL PROGRESS BAR
   ===================================================================== */
#scrollProgressBar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, #A855F7, #06B6D4, #EC4899);
  z-index: 100;
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.8), 0 0 16px rgba(168, 85, 247, 0.5);
  transition: width 0.08s linear;
}

/* =====================================================================
   SMOOTH, NON-DISTURBING SCROLL REVEAL ANIMATIONS
   Gentle fade and subtle translation so content never shakes or obscures
   ===================================================================== */
.scroll-reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s ease-out, transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

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

/* Stagger utilities */
.delay-100 { transition-delay: 0.08s; }
.delay-200 { transition-delay: 0.16s; }
.delay-300 { transition-delay: 0.24s; }

/* Subtle scanning laser line on top border only (never covers text) */
.scan-border {
  position: relative;
}

.scan-border::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #06B6D4, #A855F7, transparent);
  opacity: 0;
  pointer-events: none;
}

.scan-border.is-revealed::before {
  opacity: 1;
  animation: scanLaserBorder 1.6s ease-in-out forwards;
}

@keyframes scanLaserBorder {
  0% { left: -100%; opacity: 0; }
  30% { opacity: 0.8; }
  70% { opacity: 0.8; }
  100% { left: 100%; opacity: 0; }
}

/* =====================================================================
   BACKGROUND AMBIENT GRID & PARALLAX
   ===================================================================== */
.bg-cyber-grid {
  background-image: 
    linear-gradient(to right, rgba(30, 44, 91, 0.15) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(30, 44, 91, 0.15) 1px, transparent 1px);
  background-size: 40px 40px;
}

.parallax-layer {
  transition: transform 0.15s ease-out;
  will-change: transform;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #030611;
}

::-webkit-scrollbar-thumb {
  background: #1E2C5B;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #06B6D4;
}
