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

:root {
  --font-display: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

html {
  font-family: var(--font-sans);
  scroll-behavior: smooth;
  overflow-x: hidden;
  max-width: 100vw;
}

body {
  overflow-x: hidden;
  max-width: 100vw;
}

.font-display {
  font-family: var(--font-display);
}

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

/* Hairline Wireframe Blueprint Grid */
.bg-blueprint-grid {
  background-size: 40px 40px;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
}

/* Solid high-contrast grid for light theme */
:not(.dark) .bg-blueprint-grid,
.light .bg-blueprint-grid {
  background-size: 40px 40px;
  background-image: 
    linear-gradient(to right, rgba(15, 23, 42, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.07) 1px, transparent 1px);
}

/* Corner Crosshairs - constrained to prevent container blowout */
.has-crosshairs {
  position: relative;
}

.has-crosshairs::before {
  content: '+';
  position: absolute;
  top: -4px;
  left: -4px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1;
  color: #f59e0b;
  opacity: 0.8;
  pointer-events: none;
}

.has-crosshairs::after {
  content: '+';
  position: absolute;
  bottom: -4px;
  right: -4px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1;
  color: #f59e0b;
  opacity: 0.8;
  pointer-events: none;
}

:not(.dark) .has-crosshairs::before,
:not(.dark) .has-crosshairs::after {
  color: #b45309;
  opacity: 0.9;
}

/* Radial Ambient Glows */
.amber-glow {
  background: radial-gradient(circle 650px at 50% 0%, rgba(245, 158, 11, 0.12), transparent 70%);
}

.dark .amber-glow {
  background: radial-gradient(circle 750px at 50% 0%, rgba(245, 158, 11, 0.16), transparent 75%);
}

/* SVG Flow Animations */
@keyframes flowDash {
  to {
    stroke-dashoffset: -48;
  }
}

@keyframes reverseFlowDash {
  to {
    stroke-dashoffset: 48;
  }
}

.pulse-path {
  stroke-dasharray: 6 12;
  animation: flowDash 2.2s linear infinite;
}

.pulse-path-reverse {
  stroke-dasharray: 6 12;
  animation: reverseFlowDash 2.2s linear infinite;
}

.pulse-path-fast {
  stroke-dasharray: 4 8;
  animation: flowDash 1.2s linear infinite;
}

@keyframes nodeGlow {
  0%, 100% {
    transform: scale(1);
    opacity: 0.85;
  }
  50% {
    transform: scale(1.15);
    opacity: 1;
  }
}

.animate-node-glow {
  transform-origin: center;
  animation: nodeGlow 3s ease-in-out infinite;
}

@keyframes floatIso {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-6px);
  }
}

.animate-float-iso {
  animation: floatIso 4s ease-in-out infinite;
}

@keyframes pulseRadar {
  0% {
    r: 12;
    opacity: 0.8;
  }
  100% {
    r: 34;
    opacity: 0;
  }
}

.animate-radar {
  animation: pulseRadar 2.5s cubic-bezier(0.2, 0.8, 0.4, 1) infinite;
}

/* Isometric SVG Styling - Dark & Light mode weight adaptation */
.iso-stroke {
  stroke: #262a38;
}

.iso-fill-top {
  fill: #191c28;
}

.iso-fill-left {
  fill: #13151f;
}

.iso-fill-right {
  fill: #0d0f17;
}

/* Confident, authoritative light theme weight */
:not(.dark) .iso-stroke,
.light .iso-stroke {
  stroke: #1e293b;
  stroke-width: 1.8px;
}

:not(.dark) .iso-fill-top,
.light .iso-fill-top {
  fill: #ffffff;
}

:not(.dark) .iso-fill-left,
.light .iso-fill-left {
  fill: #f1f5f9;
}

:not(.dark) .iso-fill-right,
.light .iso-fill-right {
  fill: #e2e8f0;
}

/* Isometric Diagram Labels & Badges - High Visibility Adaptation */
.iso-badge-bg {
  fill: #0c0e17;
  stroke-width: 1.5px;
}

:not(.dark) .iso-badge-bg,
.light .iso-badge-bg {
  fill: #ffffff;
  stroke-width: 1.8px;
  filter: drop-shadow(0 2px 5px rgba(15, 23, 42, 0.12));
}

.iso-text-default {
  fill: #f8fafc;
}
:not(.dark) .iso-text-default,
.light .iso-text-default {
  fill: #0f172a;
  font-weight: 800;
}

.iso-text-amber {
  fill: #fbbf24;
}
:not(.dark) .iso-text-amber,
.light .iso-text-amber {
  fill: #92400e;
  font-weight: 800;
}

.iso-text-emerald {
  fill: #34d399;
}
:not(.dark) .iso-text-emerald,
.light .iso-text-emerald {
  fill: #065f46;
  font-weight: 800;
}

.iso-text-rose {
  fill: #fb7185;
}
:not(.dark) .iso-text-rose,
.light .iso-text-rose {
  fill: #9f1239;
  font-weight: 800;
}

.iso-text-sky {
  fill: #38bdf8;
}
:not(.dark) .iso-text-sky,
.light .iso-text-sky {
  fill: #0369a1;
  font-weight: 800;
}

/* Subtle blinking server chassis LEDs */
@keyframes blinkLed {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}
.animate-led {
  animation: blinkLed 1.4s infinite ease-in-out;
}
.animate-led-delayed {
  animation: blinkLed 1.8s infinite ease-in-out 0.6s;
}

/* Console card transitions */
.console-card {
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.console-card:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.5);
  box-shadow: 0 16px 36px -10px rgba(245, 158, 11, 0.15);
}

/* Light mode card depth */
:not(.dark) .console-card,
.light .console-card {
  box-shadow: 0 4px 16px -2px rgba(15, 23, 42, 0.06);
}

:not(.dark) .console-card:hover,
.light .console-card:hover {
  box-shadow: 0 16px 32px -8px rgba(180, 83, 9, 0.15);
  border-color: #b45309;
}

/* Metric badge styling */
.metric-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
}

/* Service Offering Card */
.service-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.85rem;
  border-radius: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 7px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(245, 158, 11, 0.3);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(245, 158, 11, 0.55);
}
