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

:root {
  --bg-main: #070B12;
  --bg-surface: #0D131D;
  --bg-surface-elevated: #131B29;
  --border-color: #1B2636;
  --border-hover: #29384F;
  --accent: #2F80FF;
  --accent-glow: rgba(47, 128, 255, 0.35);
  --text-main: #F2F5F8;
  --text-muted: #7D8999;
  --text-dim: #4B5565;
  --status-green: #34D399;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-y: scroll;
  scrollbar-gutter: stable;
  background-color: var(--bg-main);
  color: var(--text-main);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  margin: 0;
  padding: 0;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography Utility Classes */
.font-headline {
  font-family: 'Space Grotesk', sans-serif;
}

.font-mono-code {
  font-family: 'JetBrains Mono', monospace;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum", "zero";
}

/* Glass & Glow Accents */
.glass-panel {
  background-color: rgba(13, 19, 29, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
}

.glow-blue {
  box-shadow: 0 0 24px rgba(47, 128, 255, 0.25);
}

.glow-blue-lg {
  box-shadow: 0 0 32px rgba(47, 128, 255, 0.35);
}

.glow-pin {
  box-shadow: 0 0 12px rgba(47, 128, 255, 0.85);
}

/* Layer M Master Timecode Styling */
.layer-m-card {
  background: #0E131D;
  border: 1px solid #1B2636;
  border-radius: 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.layer-m-card:hover {
  border-color: #2D3D54;
  box-shadow: 0 12px 32px -8px rgba(0, 0, 0, 0.75);
}

.layer-m-inner {
  background: #06090F;
  border: 1px solid #17212F;
  border-radius: 8px;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.6);
}

.layer-m-header-text {
  color: #00dbe9;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

/* Smooth 4-Beat Cyan LED Segments */
.layer-m-segment {
  width: 16px;
  height: 4px;
  border-radius: 2px;
  background: #202D37;
  opacity: 0.55;
  transition: background-color 0.08s ease-out, box-shadow 0.12s ease-out, opacity 0.12s ease-out;
}

.layer-m-segment.active {
  background: #00dbe9;
  box-shadow: 0 0 10px rgba(0, 219, 233, 0.95), 0 0 2px #ffffff;
  opacity: 1;
}

/* Control Toggle Button */
.layer-m-btn-ctrl {
  background: #080C14;
  border: 1px solid #202B3B;
  color: #8D9CB0;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.layer-m-btn-ctrl:hover {
  background: #121A28;
  border-color: #384A64;
  color: #ffffff;
}

.layer-m-btn-ctrl:active {
  transform: scale(0.96);
}

/* Smooth Track Title Crossfade */
.track-crossfade {
  transition: opacity 0.12s ease, transform 0.12s ease;
}

/* Pulse Animation for Connected Status */
@keyframes pulse-dot {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
    box-shadow: 0 0 6px rgba(52, 211, 153, 0.8);
  }
  50% {
    transform: scale(1.15);
    opacity: 0.75;
    box-shadow: 0 0 12px rgba(52, 211, 153, 1);
  }
}

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

/* Interactive Timeline Scrubber */
.timeline-track {
  cursor: pointer;
  position: relative;
  transition: background-color 0.2s ease;
}

.timeline-track:hover {
  background-color: #0A0F18;
}

.timeline-handle {
  transition: transform 0.08s ease, box-shadow 0.15s ease;
  user-select: none;
}

.timeline-handle:hover,
.timeline-handle:active {
  transform: translate(-50%, -50%) scale(1.2);
  box-shadow: 0 0 16px rgba(47, 128, 255, 1);
}

/* Card Transitions */
.card-syad {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.card-syad:hover {
  border-color: var(--border-hover);
  box-shadow: 0 12px 28px -8px rgba(0, 0, 0, 0.6);
}

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

::-webkit-scrollbar-track {
  background: #070B12;
}

::-webkit-scrollbar-thumb {
  background: #1B2636;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #2D3D54;
}
