@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@500;600;700;800&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap');

:root {
  --bg-color: #121414;
  --bg-deep: #0c0f0f;
  --surface: #121414;
  --surface-dim: #101212;
  --surface-container: #1e2020;
  --surface-container-low: #1a1c1c;
  --surface-container-high: #282a2b;
  --technical-gray: #1A1A1A;
  --industrial-red: #D9052A;
  --industrial-red-hover: #b80423;
  --border-gray: #333333;
  --border-light: #444748;
  --text-primary: #e2e2e2;
  --text-secondary: #c4c7c7;
  --text-muted: #8e9192;
  --success-green: #2ECC71;
  --font-headline: 'Hanken Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --max-w-container: 1440px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #0d0d0d;
}
::-webkit-scrollbar-thumb {
  background: #2a2a2a;
  border-radius: 2px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--industrial-red);
}

::selection {
  background: rgba(217, 5, 42, 0.4);
  color: #ffffff;
}

/* Material Symbols Helper */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
  line-height: 1;
}

/* Typography Utility Classes */
.font-headline-xl {
  font-family: var(--font-headline);
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.font-headline-lg {
  font-family: var(--font-headline);
  font-size: clamp(24px, 3.5vw, 36px);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.font-headline-md {
  font-family: var(--font-headline);
  font-size: clamp(20px, 2.5vw, 26px);
  font-weight: 600;
  line-height: 1.3;
}

.font-label-caps {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  line-height: 16px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.font-label-md {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  line-height: 18px;
}

.font-body-lg {
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 28px;
  color: var(--text-secondary);
}

.font-body-md {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 24px;
}

.font-body-sm {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 20px;
  color: var(--text-secondary);
}

/* Top Navigation */
.header-glass {
  background: rgba(18, 20, 20, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-gray);
  transition: all 0.3s ease;
}

.header-scrolled {
  background: rgba(14, 16, 16, 0.96);
  border-bottom: 1px solid rgba(217, 5, 42, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
  position: relative;
  padding: 6px 0;
}

.nav-link:hover {
  color: #ffffff;
}

.nav-link.active {
  color: var(--industrial-red);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--industrial-red);
}

/* Buttons */
.btn-red {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: var(--industrial-red);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 12px 28px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-red:hover {
  background-color: var(--industrial-red-hover);
  box-shadow: 0 0 20px rgba(217, 5, 42, 0.4);
  transform: translateY(-1px);
}

.btn-red:active {
  transform: translateY(1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: transparent;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 12px 28px;
  border: 1px solid var(--border-light);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-outline:hover {
  border-color: #ffffff;
  background-color: rgba(255, 255, 255, 0.05);
}

/* Animations */
@keyframes ken-burns {
  0% { transform: scale(1); }
  100% { transform: scale(1.1); }
}

.animate-ken-burns {
  animation: ken-burns 12s ease-out infinite alternate;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.96); }
}

.status-dot-pulse {
  animation: pulse-glow 2s infinite ease-in-out;
}

/* Carousel */
.carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), visibility 1.2s;
  z-index: 1;
}

.carousel-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 10;
}

.carousel-dot {
  width: 36px;
  height: 3px;
  background-color: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.carousel-dot.active {
  background-color: var(--industrial-red);
}

/* Bento Grid */
.bento-card {
  background-color: var(--technical-gray);
  border: 1px solid var(--border-gray);
  position: relative;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.bento-card:hover {
  border-color: var(--industrial-red);
  transform: translateY(-4px);
  box-shadow: 0 14px 34px -10px rgba(217, 5, 42, 0.2);
}

/* Angle Clip */
.angle-clip {
  clip-path: polygon(0 0, 100% 0, 100% 88%, 95% 100%, 0 100%);
}

/* Technical Hairline Borders */
.hairline-b {
  border-bottom: 1px solid var(--border-gray);
}
.hairline-t {
  border-top: 1px solid var(--border-gray);
}
.hairline-l {
  border-left: 1px solid var(--border-gray);
}
.hairline-r {
  border-right: 1px solid var(--border-gray);
}

/* Scroll Reveal */
.reveal-item {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Form Elements */
.input-technical {
  width: 100%;
  background-color: #0c0f0f;
  border: 1px solid var(--border-gray);
  color: #ffffff;
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 15px;
  transition: all 0.2s ease;
  outline: none;
}

.input-technical:focus {
  border-color: var(--industrial-red);
  box-shadow: 0 0 0 1px var(--industrial-red);
  background-color: #121414;
}

.input-technical::placeholder {
  color: var(--text-muted);
}

/* Scanline Overlay for High-Tech feel */
.scanline-overlay {
  background: linear-gradient(to bottom, transparent 50%, rgba(217, 5, 42, 0.02) 51%);
  background-size: 100% 4px;
  pointer-events: none;
}

/* Mobile Nav Drawer */
#mobile-menu {
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
  transform: translateX(100%);
}

#mobile-menu.open {
  transform: translateX(0);
}

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