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

body {
    font-family: 'VT323', 'Courier New', monospace;
    background: #0a0a0a;
    color: #00ff41;
    overflow-x: hidden;
}

/* CRT Scanline Effect */
.crt-overlay {
    pointer-events: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.08) 2px,
        rgba(0, 0, 0, 0.08) 4px
    );
}

/* Blinking LED */
@keyframes pulse-led {
    0%, 100% { opacity: 1; box-shadow: 0 0 8px #00ff41, 0 0 16px #00ff41; }
    50% { opacity: 0.5; box-shadow: 0 0 4px #00ff41; }
}

.led-online {
    animation: pulse-led 1.5s ease-in-out infinite;
}

/* Register flash animation */
@keyframes register-flash {
    0% { background-color: rgba(0, 255, 65, 0.4); }
    100% { background-color: transparent; }
}

.register-flash {
    animation: register-flash 0.5s ease-out;
}

/* Button styles */
.retro-btn {
    font-family: 'VT323', monospace;
    background: #1a1a2e;
    color: #00ff41;
    border: 2px solid #00ff41;
    padding: 4px 12px;
    font-size: 16px;
    cursor: pointer;
    position: relative;
    box-shadow: 
        inset -2px -2px 0 rgba(0, 0, 0, 0.5),
        inset 2px 2px 0 rgba(0, 255, 65, 0.2),
        0 2px 0 #000;
    transition: all 0.1s;
}

.retro-btn:hover {
    background: #0f3d0f;
    box-shadow: 
        inset -1px -1px 0 rgba(0, 0, 0, 0.5),
        inset 1px 1px 0 rgba(0, 255, 65, 0.2),
        0 1px 0 #000;
    transform: translateY(1px);
}

.retro-btn:active {
    transform: translateY(2px);
    box-shadow: none;
}

.retro-btn.amber {
    color: #ffb000;
    border-color: #ffb000;
}

.retro-btn.amber:hover {
    background: #3d2e0f;
}

/* Panel borders */
.panel-border {
    border: 1px dashed #00ff41;
}

/* Code editor */
.code-editor {
    font-family: 'VT323', monospace;
    font-size: 18px;
    background: #0a0a0a;
    color: #00ff41;
    border: none;
    outline: none;
    resize: none;
    width: 100%;
    height: 100%;
    line-height: 1.4;
    tab-size: 8;
}

.code-editor::placeholder {
    color: #004d13;
}

/* Memory cell hover */
.mem-cell:hover {
    background: rgba(0, 255, 65, 0.2);
    cursor: pointer;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
    background: #00ff41;
    border: 1px solid #0a0a0a;
}

/* Tab active */
.tab-active {
    background: #0a0a0a;
    border-bottom-color: #0a0a0a;
}

/* Turbo button */
@keyframes turbo-glow {
    0%, 100% { box-shadow: 0 0 10px #ff0000, 0 0 20px #ff0000; }
    50% { box-shadow: 0 0 20px #ff0000, 0 0 40px #ff0000, 0 0 60px #ff4400; }
}

.turbo-active {
    animation: turbo-glow 0.5s ease-in-out infinite;
    background: #ff0000 !important;
    color: #fff !important;
}

/* Boot sequence typing */
@keyframes blink-cursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.cursor-blink::after {
    content: '█';
    animation: blink-cursor 0.7s step-end infinite;
}