/* YousefLab CyberChef-style Styling */
:root {
    --primary: rgba(255, 251, 251, 0.1);
    --secondary: rgba(107, 106, 106, 0.22);
    --accent: #6c6c6c;
    --background: #1a1a1a;
    --text: #e0e0e0;
    --button-hover: #62b1ff;
    --border: #555;
    --neon-glow: 0 0 10px rgba(98, 177, 255, 0.5);
    --widget-shadow: 0 4px 24px 0 rgba(0,0,0,0.18);
}

body {
    font-family: 'Press Start 2P', 'Courier New', monospace;
    background-color: var(--background);
    color: var(--text);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
}

/* Arcade Header */
.arcade-header {
    text-align: center;
    padding: 20px;
    margin-bottom: 30px;
    text-shadow: var(--neon-glow);
}

.arcade-title {
    font-size: 2em;
    margin-bottom: 10px;
    color: var(--text);
}

.arcade-subtitle {
    color: var(--accent);
    font-size: 0.8em;
}

/* Lab Container */
.lab-container {
    width: 100vw;
    height: 100vh;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
}

.lab-main {
    display: grid;
    grid-template-columns: 1.2fr 0.9fr;
    gap: 0;
    height: 100vh;
    width: 100vw;
    box-sizing: border-box;
}

/* Input/Output Section */
.lab-io {
    display: flex;
    flex-direction: column;
    gap: 18px;
    height: 100vh;
    padding: 32px 8px 32px 60px;
    box-sizing: border-box;
}

.lab-pane {
    background: var(--secondary);
    border-radius: 14px;
    border: 1.5px solid var(--border);
    overflow: hidden;
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    box-shadow: var(--widget-shadow);
    margin-bottom: 0;
    min-height: 0;
    max-width: 98%;
}

.pane-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 18px;
    background: var(--primary);
    border-bottom: 1.5px solid var(--border);
}

.pane-header h2 {
    margin: 0;
    font-size: 0.9em;
    color: var(--text);
}

.pane-controls {
    display: flex;
    gap: 7px;
}

/* Textareas */
textarea {
    width: 100%;
    height: 100%;
    min-height: 180px;
    background: var(--background);
    color: var(--text);
    border: none;
    padding: 14px 12px 14px 12px;
    font-family: 'Courier New', monospace;
    font-size: 1.08em;
    resize: none;
    outline: none;
    box-sizing: border-box;
    flex: 1 1 0;
    border-radius: 0 0 14px 14px;
}

textarea:focus {
    box-shadow: var(--neon-glow);
}

/* Operations Section */
.lab-operations {
    background: var(--secondary);
    border-radius: 14px 0 0 14px;
    border: 1.5px solid var(--border);
    padding: 32px 32px 32px 18px;
    overflow-y: auto;
    height: 100vh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-shadow: var(--widget-shadow);
    min-width: 320px;
    max-width: 480px;
}

.operations-header {
    margin-bottom: 18px;
}

.operations-search input {
    width: 90%;
    background: var(--background);
    color: var(--text);
    border: 1.5px solid var(--border);
    padding: 12px 16px;
    border-radius: 7px;
    font-family: inherit;
    font-size: 0.9em;
}

.operations-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    width: 100%;
}

@media (min-width: 900px) {
    .operations-grid {
        grid-template-columns: 1fr 1fr;
    }
}
@media (min-width: 1400px) {
    .operations-grid {
        grid-template-columns: 1fr 1fr 1fr;
    }
}

/* Operation Buttons */
.operation-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 15px;
    background: var(--primary);
    border: 1.5px solid var(--border);
    color: var(--text);
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 8px;
    font-family: inherit;
    font-weight: 500;
}

.operation-btn:hover {
    background: var(--button-hover);
    transform: translateY(-2px) scale(1.03);
    box-shadow: var(--neon-glow);
}

.operation-btn i {
    font-size: 1.2em;
}

/* Arcade Buttons */
.arcade-btn {
    background: var(--primary);
    border: 1.5px solid var(--border);
    color: var(--text);
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9em;
}

.arcade-btn:hover {
    background: var(--button-hover);
    box-shadow: var(--neon-glow);
}

/* Back Button */
.back-btn {
    position: fixed !important;
    top: 12px !important;
    right: 12px !important;
    left: auto !important;
    width: 20px;
    height: 20px;
    background: var(--primary);
    color: var(--text);
    border-radius: 50%;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 0.8em;
    border: 1.5px solid var(--border);
    z-index: 9999 !important;
    box-shadow: var(--widget-shadow);
    font-family: inherit;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    pointer-events: all;
}

.back-btn:hover {
    background: var(--button-hover);
    box-shadow: var(--neon-glow);
}

.back-btn::after {
    content: attr(title);
    position: absolute;
    right: 120%;
    top: 50%;
    transform: translateY(-50%);
    background: #222;
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8em;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    white-space: nowrap;
}

.back-btn:hover::after {
    opacity: 1;
}

/* Mobile Responsiveness */
@media (max-width: 1200px) {
    .lab-main {
        grid-template-columns: 1fr;
        height: auto;
    }
    .lab-io {
        padding: 12px;
    }
    .lab-operations {
        max-width: 100vw;
    }
}

@media (max-width: 768px) {
    .operations-grid {
        grid-template-columns: 1fr;
    }
    textarea {
        min-height: 120px;
        font-size: 0.9em;
    }
    .lab-io, .lab-operations {
        padding: 7px;
    }
    .back-btn {
        top: 6px !important;
        right: 6px !important;
        left: auto !important;
        width: 16px;
        height: 16px;
        font-size: 0.65em;
    }
} 