:root { color-scheme: dark; }
#container { height: 100%; overflow-y: auto; padding-bottom: 50px; }

/* Notebook container for program config modal */
.notebook-container { background: #1e1e1e; border-radius: 6px; border: 1px solid #333; max-height: 300px; overflow-y: scroll; position: relative; }
.notebook-blocks { padding: 0; display: block; }
.notebook-maximize-btn { position: absolute; top: 5px; left: 5px; z-index: 20; width: 24px; height: 24px; border: none; background: #3c3c3c; border-radius: 4px; cursor: pointer; font-size: 14px; color: #888; display: flex; align-items: center; justify-content: center; }
.notebook-raw-toggle { position: absolute; top: 5px; left: 35px; z-index: 20; height: 24px; border: none; background: #3c3c3c; border-radius: 4px; cursor: pointer; font-size: 11px; color: #888; padding: 0 8px; display: flex; align-items: center; justify-content: center; }
.notebook-raw-toggle:hover { background: #4c4c4c; color: #fff; }
.notebook-raw-toggle.active { background: #0078d4; color: #fff; }
.notebook-raw-view { display: none; background: #1a1a1a; padding: 10px; font-family: 'Courier New', monospace; font-size: 13px; color: #d4d4d4; white-space: pre-wrap; word-break: break-all; min-height: 100px; }
.notebook-raw-view.visible { display: block; }
.notebook-maximize-btn:hover { background: #0078d4; color: white; }
.notebook-container.maximized { position: fixed; top: 0; left: 0; right: 0; bottom: 0; max-height: none; border-radius: 0; z-index: 30000; overflow-y: scroll; }
.notebook-container.maximized .block .editor { height: calc(100vh - 60px); }
.notebook-container .block { border-bottom: 1px solid #333; display: flex; flex-shrink: 0; }
.notebook-container .block .editor { min-height: 40px; }
.drag-handle { width: 20px; background: #252526; cursor: grab; display: flex; align-items: center; justify-content: center; color: #555; opacity: 0; transition: opacity 0.2s; }
.block:hover .drag-handle { opacity: 1; }
.drag-handle:hover { color: #888; }
.drag-handle::before { content: '⋮⋮'; font-size: 12px; }
.block.dragging { opacity: 0.5; }
.block.drag-over { border-top: 2px solid #007acc; }
.block-content { flex: 1; min-width: 0; }
.toolbar { height: 40px; background: #252526; display: flex; align-items: center; justify-content: flex-end; padding: 0 10px; gap: 10px; }
.editor { height: 200px; }
#container .block { border-bottom: 1px solid #333; display: flex; }
#container .editor { height: 200px; }
select, button { background: #3c3c3c; color: #fff; border: 1px solid #555; padding: 5px 10px; border-radius: 4px; cursor: pointer; }
button:hover { background: #4c4c4c; }
.lang-select { position: relative; }
.lang-select-btn { display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: linear-gradient(180deg, #3c3c3c, #2d2d2d); border: 1px solid #555; border-radius: 8px; cursor: pointer; color: #fff; font-size: 14px; transition: all 0.15s; box-shadow: 0 2px 4px rgba(0,0,0,0.3); }
.lang-select-btn img, .lang-select-btn i { width: 20px; height: 20px; font-size: 20px; }
.lang-select-btn:hover { background: linear-gradient(180deg, #4a4a4a, #3a3a3a); border-color: #666; }
.lang-dropdown { display: none; position: absolute; top: calc(100% + 4px); right: 0; background: #2d2d2d; border: 1px solid #555; border-radius: 8px; z-index: 50; min-width: 120px; box-shadow: 0 4px 12px rgba(0,0,0,0.4); overflow: hidden; }
.lang-dropdown.open { display: block; }
.lang-option { display: flex; align-items: center; gap: 10px; padding: 10px 14px; cursor: pointer; transition: background 0.1s; }
.lang-option:hover { background: #3c3c3c; }
.lang-option img, .lang-option i { width: 18px; height: 18px; font-size: 18px; }
.delete-btn { color: #ff6b6b; font-size: 18px; padding: 6px 12px; background: transparent; border: none; border-radius: 6px; transition: all 0.15s; }
.delete-btn:hover { background: rgba(255,107,107,0.2); color: #ff4757; }
.drop-zone { height: 0; transition: height 0.2s; }
.drop-zone.active { height: 40px; border: 2px dashed #007acc; margin: 5px 0; }
.add-between { height: 0; position: relative; }
.add-between::before { content: ''; position: absolute; left: 0; right: 0; top: -10px; height: 20px; z-index: 5; }
.add-between button { position: absolute; left: 50%; top: -15px; transform: translateX(-50%); opacity: 0; font-size: 16px; width: 30px; height: 30px; border-radius: 50%; transition: opacity 0.15s; z-index: 10; pointer-events: none; }
.add-between:hover button { opacity: 1; pointer-events: auto; }
