/* ============================================
   nlbd.dev - Skeuomorphic City Cockpit
   ============================================ */
:root {
    --signal-red: #FF2D55;
    --forest-dark: #1B3A2F;
    --phosphor-silver: #C8CCD4;
    --ember-orange: #FF6B2C;
    --substrate-black: #0C0E14;
    --panel-grey: #2A2D35;
    --deep-navy: #0F1923;
    --carbon-dark: #14171F;
    --phosphor-green: #2AFFC2;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
    background: var(--substrate-black);
    color: var(--phosphor-silver);
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 400;
    font-size: 0.875rem;
    line-height: 1.6;
    letter-spacing: 0.06em;
    overflow-x: hidden;
}

/* ==============================
   MODULE BASICS
   ============================== */
.module {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: clamp(2rem, 5vw, 4rem);
    position: relative;
    border-bottom: 1px solid rgba(42, 255, 194, 0.06);
}

/* ==============================
   BEZEL
   ============================== */
.bezel {
    background: var(--carbon-dark);
    border: 2px solid var(--panel-grey);
    box-shadow: 4px 4px 16px rgba(0, 0, 0, 0.6), inset 1px 1px 2px rgba(200, 204, 212, 0.05);
    padding: clamp(1.5rem, 3vw, 2.5rem);
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.bezel.visible {
    opacity: 1;
    transform: translateY(0);
}
.bezel--circular {
    border-radius: 50%;
    width: clamp(280px, 50vw, 420px);
    height: clamp(280px, 50vw, 420px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transform: none;
}
.bezel--rect {
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
}
.bezel--wide {
    max-width: 700px;
}
.bezel-label {
    display: block;
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 600;
    font-size: 0.6rem;
    letter-spacing: 0.2em;
    color: var(--phosphor-green);
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(42, 255, 194, 0.1);
}

/* ==============================
   MODULE 1: RADAR
   ============================== */
.radar-scope {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--substrate-black);
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.5);
}
.radar-grid {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(0deg, rgba(42, 255, 194, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(42, 255, 194, 0.03) 1px, transparent 1px);
    background-size: 20% 20%;
}
.radar-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(42, 255, 194, 0.08);
    left: 50%; top: 50%;
    transform: translate(-50%, -50%);
}
.radar-ring--1 { width: 30%; height: 30%; }
.radar-ring--2 { width: 60%; height: 60%; }
.radar-ring--3 { width: 90%; height: 90%; }
.radar-sweep {
    position: absolute;
    top: 50%; left: 50%;
    width: 50%;
    height: 2px;
    background: linear-gradient(90deg, var(--phosphor-green), transparent);
    transform-origin: left center;
    animation: radarSweep 4s linear infinite;
    opacity: 0.5;
}
@keyframes radarSweep {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
.radar-center {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 5;
}
.radar-title {
    display: block;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: clamp(1.8rem, 4vw, 3rem);
    color: var(--phosphor-green);
    letter-spacing: 0.1em;
    text-shadow: 0 0 20px rgba(42, 255, 194, 0.3);
}
.radar-sub {
    display: block;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    color: var(--phosphor-silver);
    opacity: 0.5;
}
.module-status {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}
.status-item {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 600;
    font-size: 0.55rem;
    letter-spacing: 0.15em;
    color: var(--phosphor-silver);
    text-transform: uppercase;
    opacity: 0.4;
}
.status-item--accent {
    color: var(--phosphor-green);
    opacity: 0.7;
}

/* ==============================
   MODULE 2: SPECTROMETER
   ============================== */
.spectro-bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 200px;
    margin-bottom: 1.5rem;
}
.bar {
    flex: 1;
    height: var(--height);
    background: linear-gradient(180deg, var(--phosphor-green), rgba(42, 255, 194, 0.2));
    border-radius: 2px 2px 0 0;
    transition: height 1s ease;
    box-shadow: 0 0 6px rgba(42, 255, 194, 0.15);
}
.spectro-data {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.3rem 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(42, 255, 194, 0.08);
}
.data-label {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 600;
    font-size: 0.55rem;
    letter-spacing: 0.15em;
    color: var(--phosphor-silver);
    text-transform: uppercase;
    opacity: 0.5;
}
.data-value {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    color: var(--phosphor-green);
}

/* ==============================
   MODULE 3: OSCILLOSCOPE
   ============================== */
.oscillo-canvas {
    width: 100%;
    height: 180px;
    display: block;
    margin-bottom: 1rem;
}
.oscillo-readout {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(42, 255, 194, 0.08);
}
.readout-item {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.55rem;
    letter-spacing: 0.12em;
    color: var(--phosphor-silver);
    text-transform: uppercase;
    opacity: 0.5;
}

/* ==============================
   MODULE 4: GAUGE CLUSTER
   ============================== */
.gauge-cluster {
    display: flex;
    gap: clamp(1.5rem, 4vw, 3rem);
    flex-wrap: wrap;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.gauge-cluster.visible {
    opacity: 1;
    transform: translateY(0);
}
.gauge-unit {
    text-align: center;
}
.gauge-face {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--substrate-black);
    border: 2px solid var(--panel-grey);
    box-shadow: 4px 4px 12px rgba(0, 0, 0, 0.5), inset 0 0 15px rgba(0, 0, 0, 0.4);
    position: relative;
    margin: 0 auto 0.75rem;
    overflow: hidden;
}
.gauge-needle {
    position: absolute;
    bottom: 50%;
    left: 50%;
    width: 2px;
    height: 35px;
    margin-left: -1px;
    background: var(--signal-red);
    transform-origin: bottom center;
    transform: rotate(-40deg);
    transition: transform 1.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 0 4px rgba(255, 45, 85, 0.3);
}
.gauge-label {
    display: block;
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 600;
    font-size: 0.5rem;
    letter-spacing: 0.2em;
    color: var(--phosphor-silver);
    text-transform: uppercase;
    opacity: 0.5;
    margin-bottom: 0.2rem;
}
.gauge-value {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.8rem;
    color: var(--phosphor-green);
}

/* ==============================
   MODULE 5: TERMINAL
   ============================== */
.terminal-output {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.term-line {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    color: var(--phosphor-green);
    opacity: 0.7;
    line-height: 1.5;
}
.term-accent {
    color: var(--phosphor-green);
    text-shadow: 0 0 8px rgba(42, 255, 194, 0.4);
    font-weight: 600;
}

/* ==============================
   RESPONSIVE
   ============================== */
@media (max-width: 768px) {
    .gauge-face {
        width: 80px;
        height: 80px;
    }
    .gauge-needle {
        height: 28px;
    }
    .spectro-bars {
        height: 140px;
    }
}
