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

body {
    font-family: Arial, sans-serif;
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: #ecf0f1;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    align-items: start;
}

.crt-monitor {
    background: linear-gradient(145deg, #f5f5dc, #e8e8d0);
    padding: 40px 30px 60px 30px;
    border-radius: 20px;
    box-shadow: 
        0 20px 40px rgba(0,0,0,0.3),
        inset 0 2px 4px rgba(255,255,255,0.5),
        inset 0 -2px 4px rgba(0,0,0,0.1);
    position: relative;
}

.crt-monitor::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 20px;
    background: linear-gradient(145deg, #d0d0d0, #c0c0c0);
    border-radius: 10px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.monitor-housing {
    display: flex;
    gap: 20px;
    align-items: center;
}

.screen-bezel {
    flex: 1;
    background: #2c2c2c;
    padding: 20px;
    border-radius: 15px;
    position: relative;
    box-shadow: 
        inset 0 4px 8px rgba(0,0,0,0.5),
        0 2px 4px rgba(255,255,255,0.1);
}

#crt-screen {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    background: #000;
    filter: contrast(1.1) brightness(0.9);
    box-shadow: 
        0 0 20px rgba(0,255,100,0.1),
        inset 0 0 40px rgba(0,0,0,0.3);
}

.screen-glare {
    position: absolute;
    top: 25px;
    left: 25px;
    right: 25px;
    height: 30%;
    background: linear-gradient(135deg, 
        rgba(255,255,255,0.1) 0%,
        rgba(255,255,255,0.05) 50%,
        transparent 100%);
    border-radius: 8px 8px 0 0;
    pointer-events: none;
}

.monitor-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    padding: 20px 0;
}

.power-led {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #333;
    border: 2px solid #666;
    transition: all 0.3s ease;
}

.power-led.on {
    background: #00ff00;
    box-shadow: 0 0 10px #00ff00;
}

.control-knobs {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.knob-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.knob-group label {
    font-size: 10px;
    font-weight: bold;
    color: #333;
    letter-spacing: 0.5px;
}

.knob {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(145deg, #e0e0e0, #c0c0c0);
    border: 2px solid #999;
    cursor: pointer;
    position: relative;
    transition: transform 0.1s ease;
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        inset 0 1px 2px rgba(255,255,255,0.5);
}

.knob:hover {
    background: linear-gradient(145deg, #f0f0f0, #d0d0d0);
}

.knob::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 8px;
    background: #666;
    border-radius: 2px;
}

.power-knob.on {
    background: linear-gradient(145deg, #90ee90, #70cc70);
}

.degauss-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(145deg, #ff6b6b, #ff5252);
    border: 2px solid #cc4444;
    color: white;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.1s ease;
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        inset 0 1px 2px rgba(255,255,255,0.3);
}

.degauss-btn:hover {
    background: linear-gradient(145deg, #ff7b7b, #ff6262);
    transform: scale(1.05);
}

.degauss-btn:active {
    transform: scale(0.95);
}

.content-controls {
    background: rgba(255,255,255,0.1);
    padding: 20px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.mode-selector {
    margin-bottom: 20px;
}

.mode-selector h3 {
    margin-bottom: 10px;
    color: #ecf0f1;
}

.mode-btn {
    background: linear-gradient(145deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 8px 12px;
    margin: 2px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.mode-btn:hover {
    background: linear-gradient(145deg, #5dade2, #3498db);
    transform: translateY(-1px);
}

.mode-btn.active {
    background: linear-gradient(145deg, #e74c3c, #c0392b);
    box-shadow: 0 2px 8px rgba(231,76,60,0.3);
}

.text-input-area {
    display: block;
}

.text-input-area h3 {
    margin-bottom: 10px;
    color: #ecf0f1;
}

#terminal-input {
    width: 100%;
    padding: 8px;
    border: 1px solid #555;
    border-radius: 4px;
    background: #2c3e50;
    color: #ecf0f1;
    font-family: 'Courier New', monospace;
    margin-bottom: 10px;
}

#clear-screen {
    background: linear-gradient(145deg, #e67e22, #d35400);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

#clear-screen:hover {
    background: linear-gradient(145deg, #f39c12, #e67e22);
    transform: translateY(-1px);
}

.info-panel {
    grid-column: 1 / -1;
    background: rgba(255,255,255,0.1);
    padding: 20px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    margin-top: 20px;
}

.info-panel h3 {
    margin-bottom: 10px;
    color: #e74c3c;
}

.info-panel p {
    margin-bottom: 10px;
    line-height: 1.6;
}

.footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: #bdc3c7;
    font-size: 14px;
}

.footer a {
    color: #3498db;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .monitor-housing {
        flex-direction: column;
        gap: 15px;
    }
    
    .control-knobs {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .crt-monitor {
        padding: 20px;
    }
}

/* Vintage aging effects */
.crt-monitor {
    position: relative;
}

.crt-monitor::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(255,200,100,0.02) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255,220,150,0.03) 0%, transparent 50%);
    border-radius: 20px;
    pointer-events: none;
}