:root{font-family:system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;display:flex;place-items:center;min-width:320px;min-height:100vh}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:#1a1a1a;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}@media (prefers-color-scheme: light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.question-list{max-width:600px;margin:0 auto}.question-loading,.question-empty{text-align:center;padding:2rem;font-size:1.1rem}.question-header{display:flex;gap:.5rem;margin-bottom:1rem}.topic-badge,.difficulty-badge{padding:.25rem .75rem;border-radius:12px;font-size:.85rem;font-weight:500}.topic-badge{background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff)}.difficulty-badge{background:#f0f0f0;color:#333}.question-text{font-size:1.1rem;line-height:1.6;margin-bottom:1rem}.code-example{background:#f5f5f5;padding:1rem;border-radius:8px;overflow-x:auto;margin-bottom:1rem}.code-example code{font-family:Courier New,monospace;font-size:.9rem}.options{display:flex;flex-direction:column;gap:.75rem;margin-bottom:1rem}.option-button{display:flex;align-items:center;gap:.75rem;padding:1rem;border:2px solid #e0e0e0;border-radius:8px;background:#fff;cursor:pointer;transition:all .2s;text-align:left}.option-button:hover:not(:disabled){border-color:var(--tg-theme-button-color, #2481cc);background:#f8f9fa}.option-button:disabled{cursor:default}.option-button.correct{border-color:#28a745;background:#d4edda}.option-button.incorrect{border-color:#dc3545;background:#f8d7da}.option-letter{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:50%;background:var(--tg-theme-button-color, #2481cc);color:#fff;font-weight:700;flex-shrink:0}.option-button.correct .option-letter{background:#28a745}.option-button.incorrect .option-letter{background:#dc3545}.option-text{flex:1}.explanation{background:#f8f9fa;border-left:4px solid var(--tg-theme-button-color, #2481cc);padding:1rem;border-radius:4px;margin-bottom:1rem}.explanation h3{margin-bottom:.5rem}.explanation a{color:var(--tg-theme-link-color, #2481cc);text-decoration:none;margin-top:.5rem;display:inline-block}.next-button{width:100%;background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff);border:none;border-radius:8px;padding:1rem;font-size:1.1rem;cursor:pointer}.documentation{max-width:600px;margin:0 auto}.docs-loading{text-align:center;padding:2rem;font-size:1.1rem}.topics-list h2{margin-bottom:1rem}.topic-card{width:100%;background:#fff;border:1px solid #e0e0e0;border-radius:12px;padding:1.5rem;margin-bottom:1rem;cursor:pointer;transition:all .2s;text-align:left}.topic-card:hover{border-color:var(--tg-theme-button-color, #2481cc);box-shadow:0 2px 8px #0000001a}.topic-card h3{color:var(--tg-theme-text-color, #000);margin-bottom:.5rem}.topic-card p{color:var(--tg-theme-hint-color, #999);font-size:.9rem}.topic-detail h2{margin-bottom:1.5rem}.documentation-content{background:#f8f9fa;border-radius:8px;padding:1.5rem;margin-bottom:1.5rem;line-height:1.6}.no-docs{text-align:center;color:var(--tg-theme-hint-color, #999);padding:2rem}.action-buttons{display:flex;gap:.75rem}.primary-button,.secondary-button{flex:1;padding:1rem;border:none;border-radius:8px;font-size:1rem;cursor:pointer;transition:opacity .2s}.primary-button{background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff)}.secondary-button{background:#f0f0f0;color:#333}.primary-button:active,.secondary-button:active{opacity:.8}.code-challenge{max-width:800px;margin:0 auto}.code-challenge-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem;gap:1rem;flex-wrap:wrap}.code-challenge-header h2{margin:0}.execution-mode-toggle{display:flex;gap:.5rem;background:var(--tg-theme-secondary-bg-color, #f0f0f0);padding:.25rem;border-radius:8px}.mode-button{padding:.5rem 1rem;border:none;border-radius:6px;background:transparent;color:var(--tg-theme-text-color, #000);cursor:pointer;font-size:.9rem;transition:all .2s;white-space:nowrap}.mode-button:hover{background:#0000000d}.mode-button.active{background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff);font-weight:500}.pyodide-status{padding:.75rem;border-radius:8px;margin-bottom:1rem;font-size:.9rem}.pyodide-status.loading{background:#fff3cd;border:1px solid #ffc107;color:#856404}.pyodide-status.error{background:#f8d7da;border:1px solid #f5c6cb;color:#721c24}.pyodide-status.ready{background:#d4edda;border:1px solid #c3e6cb;color:#155724}.editor-container{border:1px solid var(--tg-theme-hint-color, #ccc);border-radius:8px;overflow:hidden;margin-bottom:1rem}.run-button{width:100%;background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff);border:none;border-radius:8px;padding:1rem;font-size:1.1rem;cursor:pointer;transition:opacity .2s;margin-bottom:1rem}.run-button:disabled{opacity:.6;cursor:not-allowed}.result{border-radius:8px;padding:1rem;margin-top:1rem}.result.success{background:#d4edda;border:1px solid #c3e6cb;color:#155724}.result.error{background:#f8d7da;border:1px solid #f5c6cb;color:#721c24}.result h3{margin-bottom:.5rem}.result pre{background:#0000000d;padding:.5rem;border-radius:4px;overflow-x:auto;font-size:.9rem}.python-task{padding:20px;max-width:100%}.python-task.loading{display:flex;justify-content:center;align-items:center;min-height:400px}.loading-spinner{font-size:1.2em;color:#666}.no-task{text-align:center;padding:40px 20px;color:#666}.task-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.task-header h2{margin:0;font-size:1.5em;color:#2481cc}.difficulty-badge{padding:5px 15px;border-radius:15px;font-size:.85em;font-weight:600;text-transform:capitalize}.difficulty-badge.beginner{background-color:#4caf50;color:#fff}.difficulty-badge.intermediate{background-color:#ff9800;color:#fff}.difficulty-badge.advanced{background-color:#f44336;color:#fff}.task-description{background-color:#f5f5f5;padding:15px;border-radius:8px;margin-bottom:15px}.task-description h3{margin-top:0;margin-bottom:10px;font-size:1.1em;color:#333}.task-description p{margin:0;line-height:1.6;color:#555}.task-hint{margin-bottom:15px}.hint-toggle{background-color:#fff3cd;color:#856404;border:1px solid #ffeaa7;padding:8px 15px;border-radius:5px;cursor:pointer;font-size:.95em;width:100%;text-align:left}.hint-toggle:hover{background-color:#ffeaa7}.hint-content{margin-top:10px;padding:15px;background-color:#fff;border:1px solid #ffeaa7;border-radius:5px;color:#555;line-height:1.6}.task-datasets{margin-bottom:15px;background-color:#e3f2fd;padding:15px;border-radius:8px;border:1px solid #90caf9}.task-datasets h3{margin-top:0;margin-bottom:15px;font-size:1.1em;color:#1976d2}.dataset-info{background-color:#fff;padding:12px;border-radius:5px;margin-bottom:10px}.dataset-info:last-child{margin-bottom:0}.dataset-info h4{margin-top:0;margin-bottom:8px;font-size:1em;color:#333}.dataset-info p{margin:5px 0;color:#555;font-size:.9em}.dataset-preview{margin:10px 0}.dataset-preview strong{color:#333;font-size:.9em}.dataset-data{background-color:#f5f5f5;padding:10px;border-radius:4px;overflow-x:auto;font-size:.85em;margin-top:5px;border:1px solid #ddd}.dataset-note{background-color:#fff3cd;padding:8px 12px;border-radius:4px;margin-top:10px;margin-bottom:0;font-size:.85em;border:1px solid #ffeaa7}.dataset-note code{background-color:#fff;padding:2px 6px;border-radius:3px;font-family:Courier New,monospace;color:#d63384;font-weight:600}.pyodide-status{padding:12px 15px;border-radius:8px;margin-bottom:15px;font-size:.95em;border:2px solid}.pyodide-status.loading{background-color:#fff3cd;border-color:#ffc107;color:#856404}.pyodide-status.error{background-color:#f8d7da;border-color:#f44336;color:#721c24}.pyodide-status.ready{background-color:#d4edda;border-color:#4caf50;color:#155724}.editor-section{margin-bottom:15px}.editor-section h3{margin-bottom:10px;font-size:1.1em;color:#333}.mobile-code-editor{width:100%;min-height:350px;padding:15px;font-family:Courier New,Monaco,Menlo,monospace;font-size:14px;line-height:1.6;background-color:#1e1e1e;color:#d4d4d4;border:1px solid #3c3c3c;border-radius:8px;resize:vertical;box-sizing:border-box;tab-size:4;-moz-tab-size:4;outline:none}.mobile-code-editor:focus{border-color:#007acc;box-shadow:0 0 0 2px #007acc33}.mobile-code-editor::placeholder{color:#858585}.task-actions{display:flex;gap:10px;margin-bottom:20px}.submit-button,.skip-button{flex:1;padding:12px 20px;border:none;border-radius:8px;font-size:1em;font-weight:600;cursor:pointer;transition:all .3s}.submit-button{background-color:#4caf50;color:#fff}.submit-button:hover:not(:disabled){background-color:#45a049}.submit-button:disabled{background-color:#ccc;cursor:not-allowed}.skip-button{background-color:#f0f0f0;color:#333}.skip-button:hover:not(:disabled){background-color:#e0e0e0}.result{border-radius:8px;padding:20px;margin-top:20px}.result.success{background-color:#d4edda;border:1px solid #c3e6cb}.result.error{background-color:#f8d7da;border:1px solid #f5c6cb}.result h3{margin-top:0;margin-bottom:15px;color:#333}.test-results{margin-bottom:20px}.test-results h4{margin-bottom:10px;color:#333}.test-case{background-color:#fff;border-radius:5px;padding:12px;margin-bottom:10px;border:2px solid #ddd}.test-case.passed{border-color:#4caf50}.test-case.failed{border-color:#f44336}.test-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.test-number{font-weight:600;color:#333}.test-status{font-size:1.2em}.test-details{margin-top:10px;padding-top:10px;border-top:1px solid #ddd}.test-details p{margin:5px 0;font-size:.9em;color:#555}.error-message{color:#f44336;font-weight:500}.explanation{background-color:#fff;padding:15px;border-radius:5px;margin-bottom:15px}.explanation h4{margin-top:0;margin-bottom:10px;color:#333}.explanation p{margin:0;line-height:1.6;color:#555}.documentation{text-align:center}.doc-link{display:inline-block;padding:10px 20px;background-color:#2481cc;color:#fff;text-decoration:none;border-radius:5px;font-weight:500;transition:background-color .3s}.doc-link:hover{background-color:#1a5fa0}*{margin:0;padding:0;box-sizing:border-box}.app{min-height:100vh;background:var(--tg-theme-bg-color, #ffffff);color:var(--tg-theme-text-color, #000000)}.app-header{background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff);padding:1rem;text-align:center}.app-header h1{font-size:1.5rem;margin-bottom:.5rem}.user-info{font-size:.9rem;opacity:.9}.app-content{padding:1rem}.menu{display:flex;flex-direction:column;gap:1rem;max-width:500px;margin:2rem auto}.menu-button{background:var(--tg-theme-button-color, #2481cc);color:var(--tg-theme-button-text-color, #ffffff);border:none;border-radius:12px;padding:1.5rem;font-size:1.1rem;cursor:pointer;transition:transform .2s,opacity .2s}.menu-button:active{transform:scale(.98);opacity:.8}
