/* parallengine.com - Isometric Engine Dashboard */
/* Colors: #f85149, #2a6157, #58d1c9, #8b949e, #f0883e, #0d1117, #39ff14, #3d8b7a */
/* Font: JetBrains Mono (monospace only) */

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

html, body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

body {
    font-family: 'JetBrains Mono', monospace;
    background: #0d1117;
    color: #8b949e;
    display: grid;
    grid-template-rows: 40px 1fr 120px;
}

/* Status Bar */
.status-bar {
    background: #0d1117;
    border-bottom: 1px solid #2a6157;
    display: flex;
    align-items: center;
    padding: 0 20px;
    gap: 30px;
    font-size: 13px;
}

.status-label {
    font-weight: 700;
    font-size: 14px;
    color: #58d1c9;
    letter-spacing: 0.1em;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #39ff14;
}

.blink-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #39ff14;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.2; }
}

.status-metrics {
    color: #8b949e;
    font-size: 12px;
}

.status-metrics span {
    color: #f0883e;
}

/* Engine Diagram */
.engine-diagram {
    position: relative;
    overflow: hidden;
    background:
        repeating-linear-gradient(0deg, transparent, transparent 49px, rgba(42,97,87,0.1) 49px, rgba(42,97,87,0.1) 50px),
        repeating-linear-gradient(90deg, transparent, transparent 49px, rgba(42,97,87,0.1) 49px, rgba(42,97,87,0.1) 50px);
}

.iso-grid {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 900px;
    height: 550px;
}

/* Isometric Blocks */
.iso-block {
    position: absolute;
    width: 140px;
    height: 90px;
    transform-style: preserve-3d;
    cursor: pointer;
    transition: filter 0.3s ease;
}

.iso-block:hover {
    filter: brightness(1.3);
}

.iso-face {
    position: absolute;
}

.iso-top {
    width: 140px;
    height: 50px;
    top: 0;
    left: 0;
    transform: skewX(-30deg);
}

.iso-left {
    width: 100px;
    height: 90px;
    bottom: 0;
    left: -30px;
    transform: skewY(-30deg);
}

.iso-right {
    width: 100px;
    height: 90px;
    bottom: 0;
    right: -30px;
    transform: skewY(30deg);
}

/* Thread Pool - Green */
.block-threadpool { top: 80px; left: 50px; }
.block-threadpool .iso-top { background: #3d8b7a; }
.block-threadpool .iso-left { background: #2a6157; }
.block-threadpool .iso-right { background: #1d4a41; }

/* Task Queue - Cyan */
.block-taskqueue { top: 80px; left: 300px; }
.block-taskqueue .iso-top { background: #58d1c9; }
.block-taskqueue .iso-left { background: #3d9e97; }
.block-taskqueue .iso-right { background: #2a7872; }

/* Scheduler - Orange */
.block-scheduler { top: 200px; left: 500px; }
.block-scheduler .iso-top { background: #f0883e; }
.block-scheduler .iso-left { background: #c06b2e; }
.block-scheduler .iso-right { background: #905020; }

/* Output Buffer - Red */
.block-output { top: 200px; left: 700px; }
.block-output .iso-top { background: #f85149; }
.block-output .iso-left { background: #c43e38; }
.block-output .iso-right { background: #922d28; }

/* Memory - Purple-grey */
.block-memory { top: 350px; left: 500px; }
.block-memory .iso-top { background: #8b949e; }
.block-memory .iso-left { background: #6b737d; }
.block-memory .iso-right { background: #4b535d; }

.block-label {
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 11px;
    font-weight: 700;
    color: #0d1117;
    letter-spacing: 0.05em;
    z-index: 5;
    pointer-events: none;
}

.block-counter {
    position: absolute;
    bottom: 15px;
    left: 10px;
    font-size: 16px;
    font-weight: 700;
    color: #0d1117;
    z-index: 5;
    pointer-events: none;
}

/* Pipeline SVG */
.pipeline-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.pipeline {
    stroke: #2a6157;
    stroke-width: 2;
    stroke-dasharray: 8 4;
    animation: dashFlow 1s linear infinite;
}

@keyframes dashFlow {
    from { stroke-dashoffset: 0; }
    to { stroke-dashoffset: -12; }
}

.data-packet {
    filter: drop-shadow(0 0 4px currentColor);
}

/* HUD Overlay */
.hud-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.hud-corner {
    position: absolute;
    font-size: 11px;
    color: #3d8b7a;
    letter-spacing: 0.08em;
    opacity: 0.6;
}

.hud-tl { top: 15px; left: 20px; }
.hud-tr { top: 15px; right: 20px; }
.hud-bl { bottom: 15px; left: 20px; }
.hud-br { bottom: 15px; right: 20px; }

/* Log Panel */
.log-panel {
    background: #0d1117;
    border-top: 1px solid #2a6157;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 20px;
    border-bottom: 1px solid rgba(42,97,87,0.3);
}

.log-title {
    font-size: 12px;
    color: #58d1c9;
    font-weight: 700;
}

.log-scroll-indicator {
    font-size: 10px;
    color: #39ff14;
    animation: blink 1.5s step-end infinite;
}

.log-entries {
    flex: 1;
    overflow-y: auto;
    padding: 8px 20px;
    font-size: 12px;
    line-height: 1.6;
}

.log-entry {
    color: #8b949e;
    white-space: nowrap;
}

.log-success {
    color: #39ff14;
}

.log-warning {
    color: #f0883e;
}

.log-error {
    color: #f85149;
}

/* Block active state */
.iso-block.active .iso-top {
    filter: brightness(1.5);
}

.iso-block.active .block-label {
    color: #39ff14;
}

/* Responsive */
@media (max-width: 900px) {
    .iso-grid {
        transform: translate(-50%, -50%) scale(0.65);
    }

    .status-metrics {
        display: none;
    }
}
