/* System Console Styles */
#system-console {
    position: fixed;
    bottom: -100%;
    left: 0;
    width: 100%;
    height: 400px;
    background: rgba(15, 17, 26, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 10000;
    transition: bottom 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    display: flex;
    flex-direction: column;
    color: #e2e8f0;
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
}

#system-console.open {
    bottom: 0;
}

#system-console.fullscreen {
    height: 100vh;
}

.console-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    user-select: none;
}

.console-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-blue, #3b82f6);
}

.console-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.console-level-filters {
    display: flex;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
    padding: 2px;
    margin-right: 15px;
}

.console-filter-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    padding: 4px 10px;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.console-filter-btn:hover {
    color: #f1f5f9;
}

.console-filter-btn.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.console-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.console-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.console-btn.paused {
    color: var(--accent-orange, #f59e0b);
    background: rgba(245, 158, 11, 0.1);
}

#system-console-output {
    flex: 1;
    overflow-y: auto;
    padding: 15px 20px;
    font-size: 0.85rem;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Custom Scrollbar for Console */
#system-console-output::-webkit-scrollbar {
    width: 8px;
}

#system-console-output::-webkit-scrollbar-track {
    background: transparent;
}

#system-console-output::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

#system-console-output::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

.console-msg {
    display: flex;
    gap: 12px;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.1s;
    animation: consoleSlideIn 0.2s ease-out;
}

@keyframes consoleSlideIn {
    from { opacity: 0; transform: translateX(-5px); }
    to { opacity: 1; transform: translateX(0); }
}

.console-msg:hover {
    background: rgba(255, 255, 255, 0.03);
}

.console-msg-ts {
    color: #64748b;
    font-size: 0.75rem;
    white-space: nowrap;
    min-width: 75px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.console-msg-content {
    white-space: pre-wrap;
    word-break: break-all;
    flex: 1;
}

.console-msg-count {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 10px;
    margin-left: 8px;
}

.console-info .console-msg-content { color: #e2e8f0; }
.console-warn { background: rgba(245, 158, 11, 0.05); }
.console-warn .console-msg-content { color: #fbbf24; }
.console-error { background: rgba(239, 68, 68, 0.05); }
.console-error .console-msg-content { color: #f87171; }

.console-entry-copy {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.console-msg:hover .console-entry-copy {
    opacity: 1;
}

.console-entry-copy:hover {
    color: #fff;
}
