/**
 * Observatory SSH Panel CSS - ITERATION A-340
 * CLEAN GREEN TERMINAL - Demo Friendly
 * 
 * Readable terminal with green theme (no CRT blur/scanlines)
 */

/* ═══════════════════════════════════════════════════════════════════════════
   SSH PANEL - CLEAN TERMINAL THEME
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-panel-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #0a0f0a;
    font-family: 'Consolas', 'Monaco', 'Lucida Console', 'Liberation Mono', monospace;
    font-size: 13px;
    position: relative;
    overflow: hidden;
}

/* ═══════════════════════════════════════════════════════════════════════════
   HEADER BAR
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-panel-header-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 10px;
    background: linear-gradient(180deg, #0f1a0f 0%, #0a120a 100%);
    border-bottom: 1px solid #1a3a1a;
    flex-shrink: 0;
    z-index: 10;
}

.ssh-connection-status {
    display: flex;
    align-items: center;
    gap: 6px;
}

.ssh-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #333;
    transition: all 0.3s ease;
}

.ssh-status-dot.connected {
    background: #00ff00;
    box-shadow: 0 0 6px #00ff00;
}

.ssh-status-dot.disconnected {
    background: #ff4444;
    box-shadow: 0 0 6px #ff4444;
}

.ssh-status-text {
    font-size: 11px;
    font-weight: 600;
    color: #00cc00;
    letter-spacing: 0.5px;
}

.ssh-status-dot.disconnected + .ssh-status-text {
    color: #ff4444;
}

.ssh-host-display {
    flex: 1;
    text-align: center;
}

.ssh-host {
    color: #00ff00;
    font-size: 12px;
    font-weight: bold;
}

.ssh-host-empty {
    color: #446644;
    font-size: 11px;
    font-style: italic;
}

.ssh-panel-controls {
    display: flex;
    gap: 4px;
}

.ssh-ctrl-btn {
    background: #1a2a1a;
    border: 1px solid #2a4a2a;
    color: #00cc00;
    padding: 2px 8px;
    font-size: 10px;
    font-family: inherit;
    cursor: pointer;
    border-radius: 3px;
    transition: all 0.2s ease;
}

.ssh-ctrl-btn:hover {
    background: #2a3a2a;
    border-color: #00ff00;
}

.ssh-ctrl-btn.active {
    background: #00aa00;
    color: #000;
    border-color: #00ff00;
}

/* ═══════════════════════════════════════════════════════════════════════════
   OUTPUT AREA - CLEAN AND READABLE
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-output-area {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 10px;
    background: #0a0f0a;
    scroll-behavior: smooth;
}

/* Clean scrollbar */
.ssh-output-area::-webkit-scrollbar {
    width: 8px;
}

.ssh-output-area::-webkit-scrollbar-track {
    background: #0a0f0a;
}

.ssh-output-area::-webkit-scrollbar-thumb {
    background: #1a3a1a;
    border-radius: 4px;
}

.ssh-output-area::-webkit-scrollbar-thumb:hover {
    background: #2a5a2a;
}

/* ═══════════════════════════════════════════════════════════════════════════
   COMMAND ENTRIES
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-cmd-entry {
    margin-bottom: 10px;
    padding: 8px 10px;
    background: rgba(0, 50, 0, 0.3);
    border-left: 3px solid #00aa00;
    border-radius: 0 4px 4px 0;
}

.ssh-cmd-entry.error {
    border-left-color: #ff4444;
    background: rgba(50, 0, 0, 0.3);
}

.ssh-entry {
    margin-bottom: 8px;
    padding: 6px 8px;
    background: rgba(0, 50, 0, 0.3);
    border-left: 3px solid #00aa00;
    border-radius: 0 4px 4px 0;
}

.ssh-entry.error {
    border-left-color: #ff4444;
    background: rgba(50, 0, 0, 0.3);
}

.ssh-entry.system {
    border-left-color: #4488ff;
    background: rgba(0, 30, 60, 0.3);
}

.ssh-entry.file {
    border-left-color: #ffaa00;
    background: rgba(50, 40, 0, 0.3);
}

/* Command line */
.ssh-cmd-line {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 4px;
}

.ssh-prompt {
    color: #00cc00;
    font-weight: bold;
    flex-shrink: 0;
}

.ssh-cmd-text {
    color: #ffffff;
    word-break: break-all;
    flex: 1;
}

.ssh-command {
    color: #ffffff;
    word-break: break-word;
    flex: 1;
    font-weight: 500;
}

.ssh-timestamp {
    color: #446644;
    font-size: 11px;
    flex-shrink: 0;
}

.ssh-pending {
    color: #ffaa00;
    font-size: 12px;
    padding-left: 20px;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.ssh-result-meta {
    margin-top: 6px;
    padding-left: 20px;
}

/* Output section */
.ssh-output {
    margin-top: 4px;
    padding-left: 20px;
}

.ssh-stdout {
    color: #00dd00;
    white-space: pre-wrap;
    word-break: break-all;
    font-size: 12px;
    line-height: 1.4;
    max-height: 200px;
    overflow-y: auto;
}

.ssh-stderr {
    color: #ffaa00;
    white-space: pre-wrap;
    word-break: break-all;
    font-size: 12px;
    line-height: 1.4;
}

.ssh-entry.error .ssh-stderr {
    color: #ff6666;
}

/* Exit code display */
.ssh-exit-code {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
    margin-top: 4px;
}

.ssh-exit-code.success {
    background: #004400;
    color: #00ff00;
    border: 1px solid #00aa00;
}

.ssh-exit-code.error {
    background: #440000;
    color: #ff4444;
    border: 1px solid #aa0000;
}

.ssh-duration {
    color: #668866;
    font-size: 11px;
    margin-left: 8px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SYSTEM MESSAGES
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-system-msg {
    color: #4488ff;
    font-size: 12px;
    padding: 4px 8px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FILE OPERATIONS
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-file-entry {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: rgba(50, 40, 0, 0.3);
    border-left: 3px solid #ffaa00;
    border-radius: 0 4px 4px 0;
    margin-bottom: 6px;
}

.ssh-file-op {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffcc00;
}

.ssh-file-icon {
    font-size: 14px;
}

.ssh-file-path {
    color: #ffcc00;
    font-size: 12px;
}

.ssh-file-status {
    color: #668866;
    font-size: 11px;
}

.ssh-file-status.complete {
    color: #00cc00;
}

.ssh-file-size {
    color: #668866;
    font-size: 11px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SYSTEM MESSAGES
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-system-entry {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    background: rgba(0, 30, 60, 0.3);
    border-left: 3px solid #4488ff;
    border-radius: 0 4px 4px 0;
    margin-bottom: 6px;
}

.ssh-system-msg {
    color: #4488ff;
    font-size: 12px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   WELCOME SCREEN
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-welcome {
    color: #00aa00;
    padding: 20px;
    text-align: center;
}

.ssh-welcome-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 10px;
    color: #00ff00;
}

.ssh-welcome-subtitle {
    color: #448844;
    font-size: 12px;
}

.ssh-ascii-art {
    color: #005500;
    font-size: 10px;
    line-height: 1.2;
    margin: 15px 0;
}

.ssh-ascii {
    color: #00aa00;
    font-size: 11px;
    line-height: 1.3;
    white-space: pre;
    font-family: 'Consolas', 'Monaco', monospace;
}

.ssh-ready-msg {
    color: #00ff00;
    font-size: 14px;
    font-weight: bold;
    margin-top: 15px;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.3; }
}

.ssh-terminal-output {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 10px;
    background: #0a0f0a;
    scroll-behavior: smooth;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FOOTER STATS
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-stats-footer {
    display: flex;
    gap: 16px;
    padding: 4px 10px;
    background: #0a120a;
    border-top: 1px solid #1a3a1a;
    font-size: 11px;
    flex-shrink: 0;
}

.ssh-stat {
    color: #668866;
}

.ssh-stat .stat-num {
    color: #00cc00;
    font-weight: bold;
}

.ssh-stat.success .stat-num {
    color: #00ff00;
}

.ssh-stat.error .stat-num {
    color: #ff4444;
}

/* ═══════════════════════════════════════════════════════════════════════════
   ERROR MESSAGES
   ═══════════════════════════════════════════════════════════════════════════ */

.ssh-error-entry {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: rgba(50, 0, 0, 0.3);
    border-left: 3px solid #ff4444;
    border-radius: 0 4px 4px 0;
    margin-bottom: 6px;
}

.ssh-error-icon {
    color: #ff4444;
    font-size: 14px;
}

.ssh-error-msg {
    color: #ff6666;
    font-size: 12px;
}

.ssh-error-text {
    color: #ff6666;
    font-size: 12px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 600px) {
    .ssh-panel-wrapper {
        font-size: 12px;
    }
    
    .ssh-host-display {
        display: none;
    }
    
    .ssh-stats-footer {
        flex-wrap: wrap;
        gap: 8px;
    }
}