:root {
    --bg-color: #000000;
    --window-bg: #0a0a0a;
    /* Zinc-950 roughly */
    --border-color: #27272a;
    --accent-blue: #3b82f6;
    /* Electric Blue */
    --accent-glow: rgba(59, 130, 246, 0.35);
    --text-primary: #e4e4e7;
    --text-muted: #a1a1aa;
    --font-mono: 'JetBrains Mono', monospace;
    --font-sans: 'Inter', sans-serif;
}

/* Themes */
body.theme-green {
    --accent-blue: #22c55e;
    --accent-glow: rgba(34, 197, 94, 0.35);
    /* selection color */
}

body.theme-red {
    --accent-blue: #ef4444;
    --accent-glow: rgba(239, 68, 68, 0.35);
}

body.theme-retro {
    --accent-blue: #f59e0b;
    --accent-glow: rgba(245, 158, 11, 0.35);
    background-color: #1a1500;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-sans);
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* Background Glow */
.glow-effect {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow) 0%, rgba(0, 0, 0, 0) 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    pointer-events: none;
    opacity: 0.8;
}

.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(to bottom,
            transparent 0px,
            transparent 2px,
            rgba(0, 0, 0, 0.2) 3px);
    pointer-events: none;
    z-index: 100;
    opacity: 0.3;
}

.container {
    width: 100%;
    max-width: 900px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Terminal Window */
.terminal-window {
    background: var(--window-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 500px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.terminal-window:hover {
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(59, 130, 246, 0.1);
}

/* Title Bar */
.title-bar {
    background: #18181b;
    /* Slightly lighter than body */
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.buttons {
    display: flex;
    gap: 8px;
}

.btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.close {
    background: #ef4444;
}

.minimize {
    background: #eab308;
}

.maximize {
    background: #22c55e;
}

.title-text {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.icon-right {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Terminal Body */
.terminal-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Scrollbar */
.terminal-body::-webkit-scrollbar {
    width: 8px;
}

.terminal-body::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

/* Commands & Text */
.output {
    white-space: pre-wrap;
    margin-bottom: 10px;
}

.cmd-history-line {
    color: var(--text-muted);
    margin-bottom: 4px;
}

.cmd-response {
    margin-bottom: 16px;
    color: var(--text-primary);
}

.highlight-blue {
    color: #60a5fa;
}

.highlight-purple {
    color: #c084fc;
}

.highlight-green {
    color: #4ade80;
}

.highlight-warn {
    color: #facc15;
}

.highlight-muted {
    color: #a1a1aa;
}

.input-line {
    display: flex;
    align-items: center;
}

.prompt {
    color: var(--accent-blue);
    margin-right: 12px;
    font-weight: 700;
}

#command-input {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 0.95rem;
    flex: 1;
    outline: none;
    caret-color: transparent;
}

.cursor-block {
    width: 8px;
    height: 1.2em;
    background: var(--text-primary);
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

/* Status Bar */
.status-bar {
    background: #18181b;
    padding: 8px 16px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 20px;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.status-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.dot.green {
    background: #22c55e;
    box-shadow: 0 0 8px #22c55e;
}

.dot.blue {
    background: #3b82f6;
}

.rights {
    margin-left: auto;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    .terminal-window {
        height: 400px;
    }
}