/* ==========================================================================
   AI SCHOOL LESSON 9TH GRADE - MODERN CYBER-ACADEMIC THEME
   Tailored for High Performance, Weak School PCs & School Projectors
   ========================================================================== */

:root {
    --bg-main: #090d16;
    --bg-card: rgba(17, 24, 39, 0.85);
    --bg-card-solid: #111827;
    --bg-card-hover: rgba(30, 41, 59, 0.9);
    --border-color: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(0, 240, 255, 0.3);
    
    --primary: #00f0ff;
    --primary-glow: 0 0 15px rgba(0, 240, 255, 0.5);
    --secondary: #8b5cf6;
    --accent: #ec4899;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;

    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-dim: #64748b;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
}

/* Reset & Basics */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================================================
   HEADER & NAVBAR
   ========================================================================== */
.main-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(9, 13, 22, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 12px 0;
}

.nav-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    font-size: 28px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-title {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo-title span {
    color: var(--primary);
}

.grade-badge {
    background: rgba(0, 240, 255, 0.12);
    color: var(--primary);
    border: 1px solid rgba(0, 240, 255, 0.3);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    text-transform: uppercase;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* 45-min Timer Widget */
.lesson-timer-widget {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid var(--border-color);
    padding: 5px 12px;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
}

.timer-digits {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--primary);
}

.timer-warning {
    color: var(--warning) !important;
    animation: pulse 1s infinite;
}

.btn-timer-ctrl {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.8rem;
    padding: 2px 6px;
    border-radius: 4px;
    transition: all 0.2s;
}

.btn-timer-ctrl:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.1);
}

/* Control Buttons */
.btn-ctrl {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-ctrl:hover {
    color: var(--text-main);
    border-color: var(--primary);
}

.active-toggle {
    background: rgba(0, 240, 255, 0.15) !important;
    color: var(--primary) !important;
    border-color: var(--primary) !important;
}

.active-eco {
    background: rgba(16, 185, 129, 0.15) !important;
    color: var(--success) !important;
    border-color: var(--success) !important;
}

.btn-teacher {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(0, 240, 255, 0.2));
    border-color: var(--secondary);
    color: #e2e8f0;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    position: relative;
    padding: 60px 0 40px;
    text-align: center;
    overflow: hidden;
}

#hero-bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.55;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 860px;
    margin: 0 auto;
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 240, 255, 0.08);
    border: 1px solid rgba(0, 240, 255, 0.3);
    padding: 6px 16px;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 20px;
}

.hero-title {
    font-size: 2.7rem;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -1px;
    margin-bottom: 18px;
}

.hero-gradient-text {
    background: linear-gradient(135deg, #ffffff 20%, var(--primary) 70%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 30px;
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #00b4d8);
    color: #030712;
    font-weight: 700;
    font-size: 1rem;
    padding: 14px 28px;
    border-radius: var(--radius-full);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 20px rgba(0, 240, 255, 0.4);
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 240, 255, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    font-weight: 600;
    font-size: 1rem;
    padding: 14px 24px;
    border-radius: var(--radius-full);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--secondary);
}

/* ==========================================================================
   CURRICULUM SYLLABUS CARDS (LESSONS 1 TO 5)
   ========================================================================== */
.curriculum-section {
    padding: 30px 0 50px;
}

.section-title-wrap {
    text-align: center;
    margin-bottom: 35px;
}

.section-subtitle {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 6px;
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
}

.curriculum-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px;
}

.lesson-card-nav {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.lesson-card-nav:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.25);
    background: var(--bg-card-hover);
}

.active-lesson {
    border-color: var(--primary) !important;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
    background: rgba(0, 240, 255, 0.05);
}

.locked-lesson {
    opacity: 0.85;
}

.lesson-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.lesson-icon {
    font-size: 1.8rem;
}

.lesson-num-badge {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
}

.lesson-nav-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 14px;
    line-height: 1.35;
}

.lesson-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
}

.badge-active {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 700;
}

.badge-locked {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 600;
}

.duration-tag {
    color: var(--text-dim);
}

/* ==========================================================================
   LESSON 1 MASTER CONTAINER & MODULES
   ========================================================================== */
.lesson-container {
    background: var(--bg-card-solid);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px;
    margin-bottom: 60px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.lesson-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 25px;
    margin-bottom: 35px;
    flex-wrap: wrap;
    gap: 15px;
}

.lesson-banner h2 {
    font-size: 1.8rem;
    font-weight: 800;
}

.lesson-banner p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.module-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 28px;
    margin-bottom: 35px;
}

.module-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.module-num {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #030712;
    font-weight: 900;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.module-title {
    font-size: 1.4rem;
    font-weight: 700;
}

/* ==========================================================================
   MODULE 1: MYTHBUSTER GAME & CODE VS ML COMPARISON
   ========================================================================== */
.comparison-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.comp-box {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
}

.comp-box h4 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.comp-box pre {
    background: #030712;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: #38bdf8;
    overflow-x: auto;
    margin-bottom: 10px;
    line-height: 1.5;
}

.comp-box p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Myth Card */
.myth-container {
    background: rgba(15, 23, 42, 0.9);
    border: 1px dashed rgba(0, 240, 255, 0.4);
    border-radius: var(--radius-md);
    padding: 25px;
    text-align: center;
}

.myth-counter {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.myth-statement {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 25px;
    color: #f1f5f9;
}

.myth-btn-group {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.btn-myth-truth {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid var(--success);
    color: var(--success);
    font-weight: 700;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s;
}

.btn-myth-truth:hover {
    background: var(--success);
    color: #030712;
}

.btn-myth-fake {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid var(--danger);
    color: var(--danger);
    font-weight: 700;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s;
}

.btn-myth-fake:hover {
    background: var(--danger);
    color: #ffffff;
}

.myth-result-box {
    margin-top: 20px;
    padding: 16px;
    border-radius: var(--radius-sm);
    animation: fadeIn 0.3s ease;
}

.correct-verdict {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid var(--success);
}

.wrong-verdict {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid var(--danger);
}

.verdict-title {
    font-size: 1.1rem;
    font-weight: 800;
    margin-bottom: 6px;
}

.verdict-exp {
    font-size: 0.95rem;
    color: #e2e8f0;
}

/* ==========================================================================
   MODULE 2: NEURON LAB
   ========================================================================== */
.lab-split-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    align-items: center;
}

.neuron-visualizer-box {
    background: #050811;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: center;
}

.neuron-svg-wrap {
    width: 100%;
    max-width: 440px;
    margin: 0 auto 15px;
}

.neuron-nucleus-circle {
    transition: all 0.3s;
}

.neuron-nucleus-circle.active {
    fill: var(--primary) !important;
    filter: drop-shadow(0 0 15px var(--primary));
}

.neuron-controls-panel {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
}

.control-group-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 12px;
}

.preset-buttons-row {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.btn-preset {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-preset:hover {
    color: var(--text-main);
    border-color: var(--secondary);
    background: rgba(139, 92, 246, 0.15);
}

.neuron-input-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
    background: rgba(255, 255, 255, 0.02);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.neuron-slider-group {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 170px;
}

.neuron-slider-group input[type="range"] {
    flex: 1;
    accent-color: var(--primary);
}

.val-badge {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 700;
    min-width: 38px;
    text-align: right;
    color: var(--primary);
}

.neuron-decision-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-full);
    font-weight: 800;
    font-size: 0.95rem;
    margin-top: 10px;
}

.decision-yes {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
    border: 1px solid var(--success);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.3);
}

.decision-no {
    background: rgba(239, 68, 68, 0.2);
    color: var(--danger);
    border: 1px solid var(--danger);
}

.neuron-math-box {
    margin-top: 15px;
    background: #030712;
    padding: 12px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
}

.neon-num {
    color: var(--primary);
}

/* ==========================================================================
   MODULE 3: CLASSIFIER LAB (CANVAS)
   ========================================================================== */
.canvas-wrapper {
    position: relative;
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 340px;
}

#classifier-canvas {
    width: 100%;
    height: 100%;
    cursor: crosshair;
}

.canvas-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-top: 14px;
    flex-wrap: wrap;
}

.canvas-stats-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
    margin-top: 14px;
    text-align: center;
}

.stat-item-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
}

.stat-item-value {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
}

.btn-pause-active {
    background: var(--warning) !important;
    color: #030712 !important;
}

/* ==========================================================================
   MODULE 4: LLM TOKEN LAB
   ========================================================================== */
.llm-token-box {
    background: #050811;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    min-height: 120px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.token-pill {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-family: var(--font-mono);
    font-size: 0.95rem;
    font-weight: 600;
    border: 1px solid transparent;
}

.prompt-token {
    background: rgba(255, 255, 255, 0.05);
}

.generated-token {
    background: rgba(0, 240, 255, 0.15);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
}

.animate-pop {
    animation: popIn 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.prob-row {
    margin-bottom: 10px;
}

.prob-token-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 4px;
}

.top-candidate .token-name {
    color: var(--primary);
    font-weight: 700;
}

.prob-bar-track {
    background: rgba(255, 255, 255, 0.06);
    height: 8px;
    border-radius: var(--radius-full);
    overflow: hidden;
}

.prob-bar-fill {
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    height: 100%;
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
}

/* ==========================================================================
   MODULE 5: COMPUTER VISION 8x8 GRID
   ========================================================================== */
.vision-grid-container {
    display: flex;
    gap: 25px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

#vision-pixel-grid {
    display: grid;
    grid-template-columns: repeat(8, 36px);
    grid-template-rows: repeat(8, 36px);
    gap: 3px;
    background: #030712;
    padding: 8px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.pixel-cell {
    background: #111827;
    border-radius: 3px;
    cursor: pointer;
    transition: background 0.15s;
}

.pixel-cell:hover {
    background: #1e293b;
}

.pixel-active {
    background: var(--primary) !important;
    box-shadow: 0 0 8px var(--primary);
}

#vision-matrix-display {
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 10px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    line-height: 1.3;
}

.matrix-row {
    display: flex;
    gap: 6px;
}

.matrix-val {
    color: var(--text-dim);
    width: 22px;
    text-align: center;
}

.matrix-val.m-active {
    color: var(--primary);
    font-weight: 700;
}

/* ==========================================================================
   MODULE 6: 12-GRADE QUIZ & CERTIFICATE
   ========================================================================== */
.quiz-box {
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 30px;
}

.quiz-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.quiz-progress-track {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    margin-bottom: 25px;
    overflow: hidden;
}

.quiz-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    width: 8%;
    transition: width 0.3s ease;
}

.quiz-question-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.4;
}

.quiz-options-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 25px;
}

.quiz-option-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quiz-option-card:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.2);
}

.opt-letter {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.opt-selected {
    background: rgba(0, 240, 255, 0.12) !important;
    border-color: var(--primary) !important;
}

.opt-selected .opt-letter {
    background: var(--primary);
    color: #030712;
}

.opt-correct {
    background: rgba(16, 185, 129, 0.2) !important;
    border-color: var(--success) !important;
}

.opt-correct .opt-letter {
    background: var(--success);
    color: #030712;
}

.opt-wrong {
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: var(--danger) !important;
}

.opt-wrong .opt-letter {
    background: var(--danger);
    color: #ffffff;
}

.quiz-explanation {
    background: #030712;
    border-left: 3px solid var(--primary);
    padding: 14px;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.quiz-footer-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Certificate Display Block */
.results-card {
    display: none;
    background: #050811;
    border: 1px solid var(--primary);
    border-radius: var(--radius-lg);
    padding: 35px;
    margin-top: 30px;
    text-align: center;
    box-shadow: 0 0 35px rgba(0, 240, 255, 0.2);
}

.results-score-badge {
    font-size: 3rem;
    font-weight: 900;
    color: var(--primary);
    margin: 10px 0;
}

/* Aliases for quiz options compatibility */
.quiz-opt-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.quiz-opt-item:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.2);
}
.selected-opt {
    background: rgba(0, 240, 255, 0.12) !important;
    border-color: var(--primary) !important;
}
.correct-opt {
    background: rgba(16, 185, 129, 0.2) !important;
    border-color: var(--success) !important;
}
.wrong-opt {
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: var(--danger) !important;
}
.opt-indicator {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    flex-shrink: 0;
}
.quiz-explanation-box {
    background: #030712;
    border-left: 3px solid var(--primary);
    padding: 14px;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
}

#certificate-canvas,
#certificate2-canvas,
#certificate3-canvas,
#certificate4-canvas,
#certificate5-canvas {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
    margin: 20px 0;
    border: 1px solid var(--border-color);
}

.cert-input-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    max-width: 480px;
    margin: 0 auto 20px;
}

.input-cyber {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    color: #ffffff;
    font-size: 0.95rem;
    width: 100%;
}

.input-cyber:focus {
    outline: none;
    border-color: var(--primary);
}

/* ==========================================================================
   MODALS (LOCKED LESSON & TEACHER GUIDE)
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(3, 7, 18, 0.85);
    backdrop-filter: blur(8px);
    z-index: 999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.show {
    display: flex;
    animation: fadeIn 0.2s ease;
}

.modal-content {
    background: var(--bg-card-solid);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    max-width: 650px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 30px;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.modal-close-btn {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    line-height: 1;
}

.modal-close-btn:hover {
    color: var(--text-main);
}

.modal-topics-list {
    list-style: none;
    margin: 20px 0;
}

.modal-topics-list li {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
}

/* ==========================================================================
   LESSON 2 STYLING: AUTOPILOT, CNN, FACE ID & ADVERSARIAL ATTACKS
   ========================================================================== */

/* Lesson Switcher Tab Bar */
.lesson-switch-bar {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.lesson-switch-tab {
    background: rgba(17, 24, 39, 0.85);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 10px 22px;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.lesson-switch-tab:hover {
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--text-main);
    transform: translateY(-2px);
}

.lesson-switch-tab.active-tab {
    background: linear-gradient(135deg, rgba(0, 240, 255, 0.2), rgba(236, 72, 153, 0.2)) !important;
    border-color: var(--primary) !important;
    color: #ffffff !important;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.3);
}

/* Autopilot Lab */
.autopilot-canvas-wrap {
    position: relative;
    background: #030712;
    border: 2px solid rgba(0, 240, 255, 0.3);
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 380px;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.8);
}

#autopilot-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.autopilot-hud {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    z-index: 5;
    flex-wrap: wrap;
    gap: 8px;
}

.hud-badge {
    background: rgba(3, 7, 18, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 5px 14px;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 800;
    font-family: var(--font-mono);
}

.autopilot-normal {
    color: var(--success);
    border-color: var(--success);
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

.brake-active {
    background: rgba(239, 68, 68, 0.9) !important;
    color: #ffffff !important;
    border-color: #ffffff !important;
    box-shadow: 0 0 25px rgba(239, 68, 68, 0.8);
    animation: pulse 0.5s infinite;
}

.active-mode {
    background: var(--primary) !important;
    color: #030712 !important;
    border-color: var(--primary) !important;
    font-weight: 800;
}

.active-attack {
    background: var(--danger) !important;
    color: #ffffff !important;
    border-color: var(--danger) !important;
}

/* CNN Kernel Grids */
.cnn-interactive-wrap {
    display: flex;
    gap: 25px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin: 20px 0;
}

.cnn-grid-6x6, .cnn-feature-map-4x4 {
    display: grid;
    gap: 3px;
    background: #030712;
    padding: 8px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.cnn-grid-6x6 {
    grid-template-columns: repeat(6, 42px);
    grid-template-rows: repeat(6, 42px);
}

.cnn-feature-map-4x4 {
    grid-template-columns: repeat(4, 46px);
    grid-template-rows: repeat(4, 46px);
}

.cnn-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-family: var(--font-mono);
    font-weight: 700;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.cnn-lens-active {
    border: 2px solid var(--primary) !important;
    box-shadow: 0 0 10px var(--primary);
    transform: scale(1.05);
    z-index: 2;
}

.cnn-target-cell {
    border: 2px solid #ec4899 !important;
    box-shadow: 0 0 12px #ec4899;
    transform: scale(1.08);
}

.cnn-kernel-box {
    background: #050811;
    border: 1px solid rgba(0, 240, 255, 0.3);
    border-radius: var(--radius-md);
    padding: 14px;
    text-align: center;
}

#cnn-kernel-grid {
    display: grid;
    grid-template-columns: repeat(3, 40px);
    grid-template-rows: repeat(3, 40px);
    gap: 4px;
    margin: 10px auto;
}

.cnn-k-cell {
    background: rgba(0, 240, 255, 0.1);
    color: var(--primary);
    border: 1px solid rgba(0, 240, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 800;
    font-family: var(--font-mono);
    border-radius: 4px;
}

.active-kernel {
    background: var(--primary) !important;
    color: #030712 !important;
    border-color: var(--primary) !important;
}

.active-hierarchy {
    background: linear-gradient(135deg, var(--secondary), var(--accent)) !important;
    color: #ffffff !important;
    border-color: var(--accent) !important;
}

.pulse-glow {
    animation: glowPulse 0.7s ease;
}

@keyframes glowPulse {
    0% { filter: drop-shadow(0 0 0px var(--primary)); }
    50% { filter: drop-shadow(0 0 25px var(--accent)); }
    100% { filter: drop-shadow(0 0 0px var(--primary)); }
}

/* Face ID & Adversarial */
.face-mesh-wrap {
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    padding: 15px;
}

#face-mesh-canvas, #adversarial-canvas {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.adv-prob-bar {
    height: 10px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-top: 4px;
}

.adv-fill-panda {
    background: linear-gradient(90deg, #10b981, #059669);
    height: 100%;
    border-radius: var(--radius-full);
    transition: width 0.2s ease;
}

.adv-fill-gibbon {
    background: linear-gradient(90deg, #f43f5e, #e11d48);
    height: 100%;
    border-radius: var(--radius-full);
    transition: width 0.2s ease;
}

/* ==========================================================================
   LESSON 3 STYLING: ATTENTION LAB, DIFFUSION CANVAS & PROMPT BATTLE ARENA
   ========================================================================== */

/* Attention Lab */
.attention-arcs-box {
    position: relative;
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px 15px 10px;
    margin: 15px 0;
    overflow-x: auto;
}

#attention-arcs-svg {
    display: block;
    margin: 0 auto;
    overflow: visible;
}

.attention-tokens-wrap {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.attention-token {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 6px 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.attention-token:hover {
    background: rgba(0, 240, 255, 0.15);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.attention-token.active-token {
    background: rgba(0, 240, 255, 0.25) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.4);
    transform: scale(1.08);
}

.token-word {
    font-weight: 700;
    font-size: 0.95rem;
    color: #ffffff;
}

.token-idx {
    font-size: 0.65rem;
    color: var(--text-dim);
    font-family: var(--font-mono);
}

/* Attention Heatmap */
#attention-heatmap-matrix {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 15px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    overflow-x: auto;
}

.heatmap-header-row, .heatmap-data-row {
    display: flex;
    gap: 4px;
    align-items: center;
}

.hm-header-token, .hm-row-label {
    width: 100px;
    color: var(--text-muted);
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hm-col-label {
    width: 48px;
    text-align: center;
    color: var(--text-dim);
}

.hm-cell {
    width: 48px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    font-weight: 700;
    color: #030712;
    transition: all 0.2s;
}

.hm-highest {
    outline: 2px solid #ec4899;
    box-shadow: 0 0 8px #ec4899;
    color: #ffffff !important;
}

/* Diffusion Lab */
.diffusion-box {
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
}

#diffusion-canvas {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.8);
    display: block;
    margin: 0 auto;
}

/* Prompt Battle Arena */
.battle-arena-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 20px;
    margin: 20px 0;
}

.battle-box {
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
}

.lazy-prompt-card {
    border-color: rgba(239, 68, 68, 0.3);
}

.pro-prompt-card {
    border-color: rgba(16, 185, 129, 0.4);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.1);
}

.pro-tag-role { color: #38bdf8; font-weight: 700; }
.pro-tag-task { color: #facc15; font-weight: 700; }
.pro-tag-format { color: #ec4899; font-weight: 700; }

.battle-output-preview {
    background: #030712;
    border-radius: var(--radius-sm);
    padding: 14px;
    font-size: 0.88rem;
    line-height: 1.5;
    margin-top: 12px;
    max-height: 240px;
    overflow-y: auto;
    border-left: 3px solid var(--border-color);
}

.detective-quote-box {
    background: #030712;
    border-left: 4px solid var(--primary);
    padding: 18px 22px;
    border-radius: var(--radius-sm);
    font-size: 1.15rem;
    font-weight: 600;
    margin: 20px 0;
    color: #f8fafc;
    line-height: 1.5;
}

/* ==========================================================================
   ANIMATIONS & KEYFRAMES
   ========================================================================= */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.97); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes popIn {
    0% { transform: scale(0.6); opacity: 0; }
    80% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ==========================================================================
   LESSON 4: GAN LAB, VOICE CLONING, SPOTTER & SCAM SIMULATOR
   ========================================================================= */

/* GAN Battle Arena */
.gan-arena-wrap {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 20px;
    align-items: start;
    background: #050811;
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: var(--radius-md);
    padding: 20px;
}

.gan-canvas-box {
    text-align: center;
    background: #030712;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 12px;
}

#gan-gen-canvas {
    width: 220px;
    height: 220px;
    border-radius: 6px;
    background: #000;
    box-shadow: 0 4px 15px rgba(0, 240, 255, 0.15);
}

#gan-loss-canvas {
    width: 100%;
    height: 190px;
    border-radius: 6px;
    background: #090d16;
}

.gan-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 10px;
    margin: 15px 0;
}

.gan-stat-chip {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 10px;
    text-align: center;
}

.gan-stat-val {
    font-size: 1.25rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: #10b981;
}

.gan-stat-lbl {
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 3px;
}

/* Voice Cloning Spectrogram Lab */
.voice-lab-wrap {
    background: #050811;
    border: 1px solid rgba(0, 240, 255, 0.25);
    border-radius: var(--radius-md);
    padding: 20px;
}

#voice-spectrogram-canvas {
    width: 100%;
    height: 180px;
    border-radius: 6px;
    background: #090d16;
    display: block;
    margin: 15px 0;
}

.voice-mode-btn {
    padding: 9px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.voice-mode-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.active-mode-btn {
    background: rgba(16, 185, 129, 0.2) !important;
    border-color: #10b981 !important;
    color: #34d399 !important;
}

/* Deepfake Spotter Challenge */
.df-spotter-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 20px;
    align-items: start;
}

.df-image-box {
    background: #050811;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px;
    text-align: center;
}

.artifact-check-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    margin-bottom: 10px;
    transition: var(--transition);
}

.artifact-check-item.item-found {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.08);
}

.art-icon {
    font-size: 1.2rem;
}

/* Phishing & Scam Simulator */
.scam-sim-card {
    background: #090e1a;
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 20px;
}

.scam-quote-box {
    background: rgba(239, 68, 68, 0.06);
    border-left: 4px solid #ef4444;
    padding: 14px 18px;
    border-radius: 4px;
    font-style: italic;
    color: #fecaca;
    margin: 15px 0;
    line-height: 1.5;
}

.scam-opt-btn {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 100%;
    text-align: left;
    padding: 14px 18px;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: #e2e8f0;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
    font-family: var(--font-main);
}

.scam-opt-btn:hover {
    background: rgba(0, 240, 255, 0.08);
    border-color: var(--primary);
    transform: translateX(4px);
}

.scam-opt-num {
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 800;
    flex-shrink: 0;
}

/* Ethics Dilemmas */
.dilemma-card {
    background: #090e1a;
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: var(--radius-md);
    padding: 20px;
}

.dilemma-vote-btn {
    width: 100%;
    text-align: left;
    padding: 14px 18px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: #f8fafc;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font-main);
}

.dilemma-vote-btn:hover {
    background: rgba(168, 85, 247, 0.1);
    border-color: #a855f7;
}

.dilemma-stat-bar {
    position: relative;
    height: 22px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 4px;
    margin-top: 10px;
    overflow: hidden;
    align-items: center;
}

.stat-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981, #00f0ff);
    transition: width 0.8s ease;
}

.stat-text {
    position: absolute;
    right: 10px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #ffffff;
}

/* ==========================================================================
   LESSON 5: FITTING LAB, TEACHABLE STUDIO, CAREER & STARTUP LAB
   ========================================================================= */

/* Overfitting vs Underfitting Lab */
.fitting-lab-wrap {
    background: #050811;
    border: 1px solid rgba(234, 179, 8, 0.25);
    border-radius: var(--radius-md);
    padding: 20px;
}

#fitting-canvas {
    width: 100%;
    height: 220px;
    border-radius: 6px;
    background: #080d1a;
    display: block;
    margin: 15px 0;
}

/* Teachable Machine Simulator */
.tm-studio-wrap {
    background: #050811;
    border: 1px solid rgba(0, 240, 255, 0.25);
    border-radius: var(--radius-md);
    padding: 20px;
}

.tm-classes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 15px 0;
}

.tm-class-box {
    background: #090e1a;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 14px;
    text-align: center;
}

.tm-class-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 8px;
}

.tm-conf-row {
    margin-bottom: 12px;
}

.tm-conf-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.tm-conf-track {
    height: 16px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 4px;
    overflow: hidden;
}

.tm-conf-fill {
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #10b981);
    transition: width 0.4s ease;
}

.tm-test-btn {
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-muted);
    font-size: 1.1rem;
    cursor: pointer;
    transition: var(--transition);
}

.tm-test-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.active-test-btn {
    background: rgba(0, 240, 255, 0.2) !important;
    border-color: var(--primary) !important;
    color: var(--primary) !important;
    transform: scale(1.05);
}

/* Career Matcher */
.career-quiz-card {
    background: #090e1a;
    border: 1px solid rgba(168, 85, 247, 0.25);
    border-radius: var(--radius-md);
    padding: 20px;
}

.career-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.career-q-btn {
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.03);
    color: #e2e8f0;
    cursor: pointer;
    text-align: left;
    font-size: 0.9rem;
    font-family: var(--font-main);
    transition: var(--transition);
}

.career-q-btn:hover {
    background: rgba(168, 85, 247, 0.1);
    border-color: var(--secondary);
}

.active-career-btn {
    background: rgba(168, 85, 247, 0.25) !important;
    border-color: var(--secondary) !important;
    color: #ffffff !important;
}

.career-result-box {
    background: #050811;
    border: 1px solid rgba(16, 185, 129, 0.4);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 20px;
    animation: fadeIn 0.5s ease;
}

/* ==========================================================================
   LESSON 6: AI ARCADE & CREATIVE PLAYGROUND
   ========================================================================== */
.arcade-badge {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    color: #ffffff;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.4);
}

.arcade-card {
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(56, 189, 248, 0.2);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.arcade-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #f59e0b, #ec4899, #38bdf8);
}

.seq-cell:hover {
    filter: brightness(1.3);
    transform: scale(1.05);
}

.seq-cell.active {
    box-shadow: 0 0 10px currentColor;
}

#doodle-canvas {
    background: #0f172a;
    border: 2px solid rgba(56, 189, 248, 0.3);
    border-radius: var(--radius-md);
    cursor: crosshair;
    touch-action: none;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.6);
}

#arena-canvas {
    background: #0a0f1d;
    border: 2px solid rgba(56, 189, 248, 0.25);
    border-radius: var(--radius-md);
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

#meme-canvas {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
    display: block;
    margin: 0 auto;
}

#diploma-canvas {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.8);
    display: block;
    margin: 0 auto;
}

.arcade-control-btn {
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #f8fafc;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.arcade-control-btn:hover {
    background: rgba(56, 189, 248, 0.2);
    border-color: #38bdf8;
    color: #ffffff;
}

.arcade-control-btn.active {
    background: #0284c7;
    border-color: #38bdf8;
    color: #ffffff;
}

/* --- TURING ARENA --- */
.turing-cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 16px;
}
.turing-card {
    background: rgba(2, 6, 23, 0.7);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.turing-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.turing-card-badge {
    font-size: 0.75rem;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
}
.turing-card-name {
    font-weight: 700;
    color: #f8fafc;
}
.turing-card-body {
    font-size: 0.92rem;
    line-height: 1.55;
    color: #cbd5e1;
    margin-bottom: 16px;
    min-height: 100px;
}
.turing-code-body pre {
    background: #020617;
    padding: 10px;
    border-radius: 6px;
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: #38bdf8;
    border: 1px solid rgba(255,255,255,0.06);
}
.turing-choice-actions {
    display: flex;
    gap: 8px;
}
.turing-choice-btn {
    flex: 1;
    padding: 9px 12px;
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid rgba(255,255,255,0.15);
}
.turing-choice-btn.btn-human {
    background: rgba(16, 185, 129, 0.15);
    color: #4ade80;
    border-color: #10b981;
}
.turing-choice-btn.btn-human:hover {
    background: #10b981;
    color: #020617;
}
.turing-choice-btn.btn-ai {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border-color: #ef4444;
}
.turing-choice-btn.btn-ai:hover {
    background: #ef4444;
    color: #ffffff;
}
.turing-verdict-box {
    padding: 14px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 14px;
    animation: fadeIn 0.3s ease;
}
.verdict-win {
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid #10b981;
    color: #34d399;
}
.verdict-lose {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid #ef4444;
    color: #f87171;
}

/* --- Q-LEARNING RACER --- */
#racer-canvas {
    background: #090d16;
    border: 2px solid rgba(56, 189, 248, 0.3);
    border-radius: var(--radius-md);
    display: block;
    width: 100%;
    box-shadow: 0 8px 30px rgba(0,0,0,0.6);
}

/* --- NEURAL MINIMAX BOARD --- */
#minimax-board-grid {
    display: grid;
    grid-template-columns: repeat(3, 85px);
    grid-template-rows: repeat(3, 85px);
    gap: 8px;
    margin: 0 auto;
    width: max-content;
}
.minimax-cell {
    width: 85px;
    height: 85px;
    background: rgba(15, 23, 42, 0.85);
    border: 2px solid rgba(56, 189, 248, 0.3);
    border-radius: 8px;
    font-size: 2.2rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}
.minimax-cell:hover:not(.cell-x):not(.cell-o) {
    background: rgba(56, 189, 248, 0.15);
    border-color: #38bdf8;
    transform: scale(1.03);
}

/* --- JAILBREAK ARENA --- */
#jailbreak-chat-history {
    height: 250px;
    overflow-y: auto;
    background: #020617;
    border: 1px solid rgba(56, 189, 248, 0.2);
    border-radius: var(--radius-sm);
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
    font-family: var(--font-mono);
}
.jb-msg {
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    line-height: 1.45;
}
.jb-msg-user {
    background: rgba(2, 132, 199, 0.2);
    border: 1px solid rgba(56, 189, 248, 0.3);
    align-self: flex-end;
    color: #e2e8f0;
    max-width: 85%;
}
.jb-msg-bot {
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    align-self: flex-start;
    color: #cbd5e1;
    max-width: 90%;
}
.jb-msg-bot.jb-success {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.15);
    color: #4ade80;
}
.jb-msg-bot.jb-denied {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
}
.jb-author {
    font-size: 0.72rem;
    font-weight: 700;
    display: block;
    margin-bottom: 3px;
    color: #94a3b8;
}

/* --- VOICE FX & SPECTROGRAM --- */
#voicefx-canvas {
    background: #050811;
    border: 1px solid rgba(56, 189, 248, 0.3);
    border-radius: var(--radius-md);
    width: 100%;
    height: 120px;
    display: block;
}

/* --- PIXEL ART --- */
.pixel-cell:hover {
    filter: brightness(1.3);
    outline: 1px solid rgba(255,255,255,0.4);
}
.pixel-color-swatch.active {
    transform: scale(1.15);
    box-shadow: 0 0 10px currentColor;
}

/* --- SPEEDRUN ARCADE --- */
.speedrun-flash-green {
    animation: flashGreen 0.3s ease;
}
.speedrun-flash-red {
    animation: flashRed 0.3s ease;
}
@keyframes flashGreen {
    0% { box-shadow: 0 0 0px #10b981; }
    50% { box-shadow: 0 0 25px #10b981; border-color: #10b981; }
    100% { box-shadow: 0 0 0px #10b981; }
}
@keyframes flashRed {
    0% { box-shadow: 0 0 0px #ef4444; }
    50% { box-shadow: 0 0 25px #ef4444; border-color: #ef4444; }
    100% { box-shadow: 0 0 0px #ef4444; }
}

/* ==========================================================================
   RESPONSIVE & PRINT MEDIA
   ========================================================================= */
@media (max-width: 900px) {
    .hero-title { font-size: 2rem; }
    .comparison-grid, .lab-split-layout, .battle-arena-grid, .gan-arena-wrap, .df-spotter-grid { grid-template-columns: 1fr; }
    .lesson-container { padding: 20px; }
}

@media print {
    body * {
        visibility: hidden;
    }
    #certificate-canvas, #certificate-canvas *,
    #certificate2-canvas, #certificate2-canvas *,
    #certificate3-canvas, #certificate3-canvas *,
    #certificate4-canvas, #certificate4-canvas *,
    #certificate5-canvas, #certificate5-canvas * {
        visibility: visible;
    }
    #certificate-canvas, #certificate2-canvas, #certificate3-canvas, #certificate4-canvas, #certificate5-canvas {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
    }
}
