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

:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  --bg-canvas: #FAFAFA;
  --surface-white: #FFFFFF;
  --surface-muted: #F4F4F5;
  --surface-dark: #09090B;
  
  --border-subtle: #E4E4E7;
  --border-dark: #27272A;
  
  --text-main: #09090B;
  --text-muted: #71717A;
  --text-inverse: #FAFAFA;
  
  --accent-blue: #0052FF;
  --accent-blue-hover: #0043D1;
  --status-emerald: #10B981;
  --status-emerald-bg: #ECFDF5;
  --status-amber: #F59E0B;
  --status-amber-bg: #FFFBEB;
  --status-rose: #F43F5E;
}

* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-canvas);
  color: var(--text-main);
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

/* Precision Swiss Grid & Borders */
.border-precision {
  border: 1px solid var(--border-subtle);
}

.border-precision-dark {
  border: 1px solid var(--border-dark);
}

/* Pulsing dot indicator */
.pulse-emerald {
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* 1. SCROLL REVEAL ANIMATIONS (60fps GPU-Accelerated) */
.reveal-init {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

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

/* Staggered delay helpers */
.delay-100 { transition-delay: 100ms; }
.delay-150 { transition-delay: 150ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }

/* 2. HERO ANIMATED GRID & AMBIENT GLOW */
.hero-animated-bg {
  position: relative;
  overflow: hidden;
}

.hero-grid-pattern {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(228, 228, 231, 0.45) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(228, 228, 231, 0.45) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 80%);
  pointer-events: none;
  z-index: 0;
}

.hero-ambient-glow {
  position: absolute;
  top: -10%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 350px;
  background: radial-gradient(circle, rgba(0, 82, 255, 0.08) 0%, rgba(16, 185, 129, 0.03) 45%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
  animation: ambientFloat 8s ease-in-out infinite alternate;
}

@keyframes ambientFloat {
  0% { transform: translateX(-50%) translateY(0) scale(1); }
  100% { transform: translateX(-48%) translateY(25px) scale(1.08); }
}

/* 3. DUAL-MODE TEXT GLOW (AUTOMATIC CYCLE + CURSOR TRACKING SPOTLIGHT) */
.interactive-glow-text,
.text-shimmer {
  display: inline;
  position: relative;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  cursor: default;
  transition: filter 0.25s ease;
  will-change: background-position, background;
}

/* Condition 2: Automated Continuous Beam Cycle (When cursor is away) */
.interactive-glow-text:not(.is-tracking),
.text-shimmer:not(.is-tracking) {
  background-image: linear-gradient(
    90deg, 
    #09090B 0%, 
    #09090B 15%,
    #0052FF 35%, 
    #3B82F6 48%,
    #60A5FA 50%,
    #3B82F6 52%,
    #0052FF 65%, 
    #09090B 85%,
    #09090B 100%
  );
  background-size: 250% 100%;
  animation: autoGlowCycle 4.5s linear infinite;
  filter: drop-shadow(0 0 10px rgba(0, 82, 255, 0.18));
}

@keyframes autoGlowCycle {
  0% { background-position: 120% center; }
  100% { background-position: -120% center; }
}

@keyframes textShimmerMove {
  0% { background-position: 120% center; }
  100% { background-position: -120% center; }
}

/* Condition 1: Cursor-Tracking Spotlight (When cursor is moving over/near text) */
.interactive-glow-text.is-tracking,
.text-shimmer.is-tracking {
  background-image: radial-gradient(
    200px circle at var(--glow-x, 50%) var(--glow-y, 50%),
    #60A5FA 0%,
    #0052FF 35%,
    #09090B 80%
  );
  animation: none !important;
  filter: drop-shadow(0 0 18px rgba(0, 82, 255, 0.35));
}

/* 4. BUTTON SHINE / SHIMMER EFFECT */
.btn-shimmer {
  position: relative;
  overflow: hidden;
}

.btn-shimmer::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -60%;
  width: 40%;
  height: 200%;
  background: linear-gradient(
    60deg,
    rgba(255, 255, 255, 0) 20%,
    rgba(255, 255, 255, 0.25) 50%,
    rgba(255, 255, 255, 0) 80%
  );
  transform: rotate(25deg);
  transition: all 0.6s ease;
  pointer-events: none;
}

.btn-shimmer:hover::after {
  left: 120%;
}

/* 5. INTERACTIVE CARDS & HOVER ELEVATION */
.card-interactive {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease;
  will-change: transform, box-shadow;
}

.card-interactive:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px -10px rgba(0, 82, 255, 0.10), 0 0 0 1px #0052FF;
}

/* 6. NAVBAR SCROLLED GLASSMORPHISM & ACTIVE INDICATOR */
.nav-scrolled {
  background-color: rgba(255, 255, 255, 0.92) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  box-shadow: 0 4px 20px -4px rgba(9, 9, 11, 0.05);
}

.nav-link {
  position: relative;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #71717A;
}

.nav-link:hover {
  color: #09090B;
  background-color: rgba(9, 9, 11, 0.04);
}

.nav-link.nav-active {
  color: #0052FF !important;
  background-color: rgba(0, 82, 255, 0.08) !important;
  font-weight: 700 !important;
}

.nav-link.nav-active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 20%;
  right: 20%;
  height: 2px;
  background-color: #0052FF;
  border-radius: 2px;
}

/* 7. FLOATING WHATSAPP BUTTON */
.wa-floating-btn {
  box-shadow: 0 8px 24px -4px rgba(16, 185, 129, 0.35);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease;
}

.wa-floating-btn:hover {
  transform: translateY(-4px) scale(1.04);
  box-shadow: 0 14px 32px -4px rgba(16, 185, 129, 0.45);
}

/* Custom scrollbar for technical logs */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #F4F4F5;
}
::-webkit-scrollbar-thumb {
  background: #D4D4D8;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #A1A1AA;
}

/* Modal backdrop */
.modal-overlay {
  background-color: rgba(9, 9, 11, 0.75);
  backdrop-filter: blur(4px);
}
