@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Fira+Code:wght@500;600;700&display=swap');

:root {
  /* High-Contrast Light Theme Colors */
  --bg-main: #f0f4f9;
  --bg-card: #ffffff;
  --bg-sidebar: #ffffff;
  --bg-glass: rgba(99, 102, 241, 0.05);
  --border-glass: rgba(99, 102, 241, 0.18);
  --border-glass-glow: rgba(99, 102, 241, 0.4);
  
  --primary: #4f46e5; /* Deep Indigo for clear text contrast */
  --primary-glow: rgba(79, 70, 229, 0.2);
  --secondary: #059669; /* Emerald Green */
  --secondary-glow: rgba(5, 150, 105, 0.2);
  --accent: #e11d48; /* Vibrant Rose */
  --accent-glow: rgba(225, 29, 72, 0.2);
  
  --text-main: #0f172a; /* Deep Slate (nearly black) for maximum contrast */
  --text-muted: #334155; /* Medium Dark Slate for secondary text */
  --text-glow: #312e81; /* Deep Indigo Navy */
  
  --sidebar-width: 380px; /* Wider sidebar for larger text readability */
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
  height: 100vh;
  display: flex;
}

/* Scrollbar customization */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* Layout */
.app-container {
  display: flex;
  width: 100%;
  height: 100vh;
}

/* Sidebar Navigation */
.sidebar {
  width: var(--sidebar-width);
  background: var(--bg-sidebar);
  border-right: 2px solid var(--border-glass);
  display: flex;
  flex-direction: column;
  height: 100%;
  flex-shrink: 0;
  box-shadow: 4px 0 20px rgba(0, 0, 0, 0.05);
  z-index: 10;
}

.sidebar-header {
  padding: 28px 24px;
  border-bottom: 2px solid var(--border-glass);
}

.sidebar-logo {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-logo span {
  font-size: 32px;
}

.progress-section {
  padding: 20px 24px;
  border-bottom: 2px solid var(--border-glass);
  background: rgba(99, 102, 241, 0.04);
}

.progress-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-muted);
}

.progress-bar-container {
  width: 100%;
  height: 10px;
  background: #e2e8f0;
  border-radius: 9999px;
  overflow: hidden;
}

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

.modules-list {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px 16px;
}

.module-group {
  margin-bottom: 28px;
}

.module-title {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  color: #4338ca; /* Clear indigo blue for module groupings */
  margin-bottom: 12px;
  padding-left: 8px;
  letter-spacing: 0.06em;
  border-left: 3px solid var(--primary);
}

.meeting-item {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 8px;
  border: 2px solid transparent;
  background: rgba(0, 0, 0, 0.01);
}

.meeting-item:hover {
  background: rgba(99, 102, 241, 0.05);
  border-color: rgba(99, 102, 241, 0.1);
}

.meeting-item.active {
  background: rgba(99, 102, 241, 0.1);
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.08);
}

.meeting-checkbox {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid var(--text-muted);
  margin-right: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: white;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.meeting-item.completed .meeting-checkbox {
  background-color: var(--secondary);
  border-color: var(--secondary);
}

.meeting-item.completed .meeting-checkbox::after {
  content: "✓";
}

.meeting-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.meeting-number {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
}

.meeting-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.4;
}

.meeting-item.active .meeting-title {
  color: var(--primary);
}

/* Main Workspace */
.main-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: relative;
}

/* Navbar / Controls Header */
.top-header {
  min-height: 90px;
  height: auto;
  border-bottom: 2px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 12px 20px;
  gap: 16px;
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1 1 280px;
  min-width: 0;
}

.header-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  flex: 1 1 280px;
  min-width: 0;
  flex-wrap: wrap;
}

.meeting-indicator p {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
}

.meeting-indicator h3 {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
}

.slide-tabs {
  display: flex;
  background: #f1f5f9;
  padding: 6px;
  border-radius: 10px;
  border: 1px solid #cbd5e1;
}

.slide-tab {
  padding: 10px 20px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.slide-tab.active {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

/* Slide Presentation Area */
.slide-viewer {
  flex-grow: 1;
  padding: 30px 40px; /* Spacing top/bottom and left/right */
  display: flex;
  align-items: flex-start; /* Align to top to prevent overlapping under header on small screens */
  justify-content: center;
  overflow-y: auto;
}

.slide-card {
  width: 100%;
  max-width: 1100px; /* Expanded for classroom visibility */
  min-height: 580px; /* Taller slides */
  background: var(--bg-card);
  border: 2px solid var(--border-glass);
  border-radius: 20px;
  padding: 56px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* Changed to flex-start to prevent title push-up */
  overflow-y: auto; /* Allow scrolling for long content on smaller screens */
  transition: all 0.3s ease;
  animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Cover Slide */
.slide-cover-layout {
  text-align: center;
  margin: auto 0; /* Centering cover slide vertically inside flex-start container */
}

.slide-cover-layout .subtitle {
  font-size: 16px;
  font-weight: 800;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 16px;
}

.slide-cover-layout h2 {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 32px;
  color: var(--primary);
}

.learning-objectives-card {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  padding: 32px;
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
}

.learning-objectives-card h4 {
  font-size: 20px;
  color: var(--text-main);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.learning-objectives-card ul {
  list-style-type: none;
}

.learning-objectives-card li {
  font-size: 22px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding-left: 28px;
  position: relative;
  line-height: 1.5;
}

.learning-objectives-card li::before {
  content: "🎯";
  position: absolute;
  left: 0;
  top: 2px;
  font-size: 16px;
}

/* Concept & Application Slides */
.slide-header {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 28px;
  border-bottom: 3px solid var(--border-glass);
  padding-bottom: 14px;
  color: var(--primary);
}

.slide-body-text {
  font-size: 26px; /* Increased from 22px for even larger default size */
  line-height: 1.8;
  color: #1e293b;
}

.slide-body-text b {
  color: #1e3a8a;
  font-weight: 800;
}

.slide-body-text code {
  background: rgba(99, 102, 241, 0.1);
  padding: 3px 8px;
  border-radius: 6px;
  font-family: 'Fira Code', monospace;
  font-size: 20px;
  color: #1e1b4b;
  font-weight: 600;
}

.slide-body-text pre {
  background: #1e293b; /* Keep dark background for code syntax legibility */
  border: 1px solid #475569;
  padding: 20px;
  border-radius: 12px;
  margin-top: 20px;
  overflow-x: auto;
}

.slide-body-text pre code {
  background: transparent;
  padding: 0;
  color: #f8fafc;
  font-size: 20px;
}

/* Bottom Controls */
.slide-footer-controls {
  height: 90px;
  border-top: 2px solid var(--border-glass);
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #ffffff;
}

.nav-buttons {
  display: flex;
  gap: 16px;
}

.btn-primary, .btn-secondary, .btn-cmd {
  font-family: inherit;
  font-weight: 700;
  font-size: 16px; /* Bigger buttons */
  padding: 12px 24px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 14px var(--primary-glow);
}

.btn-primary:hover {
  background: #3730a3;
  transform: translateY(-1px);
}

.btn-secondary {
  background: #ffffff;
  color: var(--text-main);
  border: 2px solid #cbd5e1;
}

.btn-secondary:hover {
  background: #f1f5f9;
  transform: translateY(-1px);
}

.meeting-completion-area {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn-complete-meeting {
  background: var(--secondary);
  color: white;
  box-shadow: 0 4px 14px var(--secondary-glow);
}

.btn-complete-meeting:hover {
  background: #047857;
}

/* Dynamic Activity Section Wrapper */
.activity-slide-container {
  width: 100%;
}

.activity-slide-container .instruction-box {
  background: rgba(99, 102, 241, 0.05);
  border-left: 6px solid var(--primary);
  padding: 20px;
  border-radius: 0 10px 10px 0;
  margin-bottom: 28px;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-glow);
  font-weight: 600;
}

/* ==========================================================================
   INTERACTIVE MODULE ACTIVITIES STYLE - LIGHT THEME HIGHER CONTRAST
   ========================================================================== */

/* P1: Robot Flowchart Pathfinder */
.game-grid-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
}

.game-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 1fr);
  gap: 10px;
  width: 400px;
  height: 400px;
  margin: 0 auto;
}

.grid-cell {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.03);
}

.cell-robot {
  background: rgba(99, 102, 241, 0.15);
  border-color: var(--primary);
  box-shadow: 0 0 10px var(--primary-glow);
}

.cell-goal {
  background: rgba(16, 185, 129, 0.15);
  border-color: var(--secondary);
}

.cell-obstacle {
  background: rgba(244, 63, 94, 0.15);
  border-color: var(--accent);
}

.command-palette {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.btn-cmd {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  color: var(--text-main);
  text-align: left;
  padding: 10px 14px;
  font-size: 15px;
  width: 100%;
}

.btn-cmd:hover {
  background: rgba(99, 102, 241, 0.05);
  border-color: var(--primary);
}

.flowchart-box {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  padding: 20px;
  max-height: 220px;
  overflow-y: auto;
  text-align: center;
}

.flow-node {
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 6px 0;
  width: 220px;
  margin: 0 auto;
}

.flow-node.terminator {
  background: #e2e8f0;
  color: #334155;
  border: 2px solid #cbd5e1;
}

.flow-node.process {
  background: #e0e7ff;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.flow-arrow {
  font-size: 14px;
  margin: 4px 0;
}

.btn-remove-node {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 12px;
  font-weight: bold;
}

.game-feedback {
  margin-top: 20px;
  padding: 16px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  min-height: 52px;
}

.game-feedback.success {
  background: #d1fae5;
  border: 2px solid var(--secondary);
  color: #065f46;
}

.game-feedback.error {
  background: #ffe4e6;
  border: 2px solid var(--accent);
  color: #9f1239;
}

.game-feedback.info {
  background: #e0e7ff;
  border: 2px solid var(--primary);
  color: #3730a3;
}

/* P2: Blockly visual code translator */
.translator-layout {
  display: grid;
  grid-template-columns: 280px 1fr 1fr;
  gap: 24px;
}

.palette-panel, .workspace-panel, .code-output-panel {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  height: 480px; /* Expanded height */
}

.palette-panel h4, .workspace-panel h4, .code-output-panel h4 {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--primary);
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 10px;
}

.palette-blocks {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.visual-block {
  background: #ffffff;
  border: 2px solid var(--primary);
  color: var(--primary);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.visual-block.in-workspace {
  background: #e6f4ea;
  border-color: var(--secondary);
  color: var(--secondary);
  margin-bottom: 10px;
}

.block-drag-handle {
  color: #94a3b8;
  margin-right: 8px;
}

.btn-add-block, .btn-remove-block {
  background: transparent;
  border: none;
  cursor: pointer;
  font-weight: bold;
  font-size: 16px;
}

.workspace-dropzone {
  flex-grow: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 10px;
}

.empty-placeholder {
  color: #64748b;
  font-size: 14px;
  text-align: center;
  margin-top: 60px;
  font-style: italic;
}

.python-code-box, .console-box {
  background: #0f172a; /* Keep dark for developer console realism, but larger fonts */
  border: 1px solid #475569;
  border-radius: 8px;
  padding: 12px;
  flex-grow: 1;
  margin-bottom: 12px;
  overflow: auto;
}

.python-code-box h4, .console-box h4 {
  color: #94a3b8;
  border: none;
  font-size: 12px;
  margin-bottom: 6px;
  padding: 0;
}

.python-code-box pre, .console-box pre {
  font-family: 'Fira Code', monospace;
  font-size: 15px; /* Larger print */
}

#python-output {
  color: #38bdf8;
}

#console-output {
  color: #34d399;
}

/* P3: RAM Memory Simulator */
.ram-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 32px;
}

.ram-form {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
}

.ram-form h4 {
  font-size: 18px;
  margin-bottom: 16px;
  color: var(--primary);
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 6px;
  font-weight: 700;
}

.form-group input, .form-group select {
  width: 100%;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 8px;
  color: var(--text-main);
  padding: 10px 14px;
  font-family: inherit;
  font-size: 16px;
}

.form-group input:focus, .form-group select:focus {
  border-color: var(--primary);
  outline: none;
}

.ram-slots-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.ram-slot {
  border-radius: 12px;
  padding: 16px;
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 120px;
  border: 2px solid;
}

.ram-slot.empty {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.ram-slot.occupied {
  background: #eef2ff;
  border-color: var(--primary);
  box-shadow: 0 4px 10px rgba(99,102,241,0.06);
}

.slot-header {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 6px;
}

.slot-empty-label {
  margin: auto;
  font-size: 13px;
  color: #94a3b8;
  font-weight: 800;
}

.slot-var-name {
  font-size: 18px;
  font-weight: 800;
  color: #1e1b4b;
}

.slot-var-type {
  font-size: 11px;
  font-weight: 800;
  background: #475569;
  color: white;
  padding: 2px 6px;
  border-radius: 4px;
  width: max-content;
  margin-bottom: 6px;
}

.slot-var-val, .slot-binary {
  font-size: 14px;
  font-weight: 600;
  color: #475569;
}

.slot-binary code {
  color: var(--primary);
  font-family: 'Fira Code', monospace;
  font-weight: bold;
}

.btn-delete-slot {
  position: absolute;
  right: 14px;
  top: 14px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 16px;
}

.form-feedback {
  margin-top: 12px;
  font-size: 14px;
  font-weight: 700;
}

.form-feedback.error { color: var(--accent); }
.form-feedback.success { color: var(--secondary); }

/* P4: Dungeon Escape Conditions */
.game-stage {
  display: flex;
  justify-content: space-between;
  background: #f1f5f9;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 28px;
}

.stage-cell {
  width: 160px;
  height: 100px;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  background: #ffffff;
  transition: all 0.3s ease;
}

.stage-cell.active {
  background: #e0e7ff;
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(99,102,241,0.2);
}

.dungeon-logic-flow {
  background: #ffffff;
  padding: 20px;
  border-radius: 12px;
  border: 2px solid #cbd5e1;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dungeon-statement {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Fira Code', monospace;
  font-size: 18px;
  font-weight: 700;
}

.dungeon-statement select, .dungeon-action select {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 6px;
  color: var(--text-main);
  padding: 6px 12px;
  font-family: inherit;
  font-size: 16px;
}

.dungeon-action {
  padding-left: 28px;
  font-family: 'Fira Code', monospace;
  font-size: 18px;
  font-weight: 700;
}

/* P5: Recommendation Dashboard */
.rec-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 32px;
}

.rec-controls {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
}

.ai-rule-box {
  background: #e0e7ff;
  border-left: 6px solid var(--primary);
  padding: 16px;
  border-radius: 0 8px 8px 0;
  margin-top: 24px;
}

.ai-rule-box h5 {
  font-size: 14px;
  color: var(--primary);
  margin-bottom: 6px;
}

.ai-rule-box p {
  font-size: 13px;
  font-weight: 600;
  color: #1e1b4b;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.video-card {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

.video-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: 0 8px 16px rgba(99,102,241,0.08);
}

.video-thumbnail {
  height: 120px;
  background: linear-gradient(135deg, #e0e7ff, #c7d2fe);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
}

.video-info {
  padding: 16px;
}

.video-title {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--text-main);
  line-height: 1.4;
}

.video-creator {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.video-stats {
  font-size: 12px;
  font-weight: 700;
  color: var(--secondary);
}

/* P6: AI Fruit Classifier */
.classifier-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.dataset-section, .testing-section {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  min-height: 480px;
}

.dataset-list {
  flex-grow: 1;
  overflow-y: auto;
  max-height: 200px;
  margin-bottom: 16px;
}

.dataset-item {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.dataset-item button {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 14px;
}

.dataset-add-form {
  background: #f1f5f9;
  padding: 16px;
  border-radius: 12px;
  border: 2px solid #cbd5e1;
}

.dataset-add-form h5 {
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 10px;
  color: var(--text-muted);
}

.form-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.form-row select, .form-row input[type="range"] {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  color: var(--text-main);
  padding: 6px;
  font-size: 14px;
  font-weight: 600;
}

.form-row span {
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.classifier-result-box {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  padding: 20px;
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-muted);
}

.ai-training-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e2e8f0;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s infinite linear;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.pred-label {
  font-size: 32px;
  font-weight: 800;
  margin: 12px 0;
  color: var(--primary);
}

.confidence-bar {
  width: 100%;
  height: 12px;
  background: #cbd5e1;
  border-radius: 9999px;
  overflow: hidden;
  margin-bottom: 10px;
}

.confidence-fill {
  height: 100%;
  background: var(--primary);
}

/* P7: Ethical AI Dilemma */
.dilemma-card {
  max-width: 700px;
  margin: 0 auto;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.05);
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from { transform: translateX(20px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

.card-step {
  font-size: 13px;
  font-weight: 800;
  color: var(--primary);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.card-title {
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--primary);
}

.card-desc {
  font-size: 18px;
  line-height: 1.6;
  color: #334155;
  margin-bottom: 30px;
}

.options-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn-eth-option {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  color: var(--text-main);
  padding: 16px 20px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
}

.btn-eth-option:hover {
  background: #e0e7ff;
  border-color: var(--primary);
  transform: translateX(4px);
}

.ethics-radar-panel {
  margin-top: 24px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  text-align: center;
}

.feedback-state {
  text-align: center;
}

.ethical-feedback-text {
  font-size: 18px;
  line-height: 1.7;
  color: #0f172a;
  margin-bottom: 24px;
}

.score-changes {
  font-size: 16px;
  font-weight: 800;
  color: var(--secondary);
}

.activity-ethical-finished {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
  padding: 40px;
}

.ethics-scores-container {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  padding: 24px;
  border-radius: 16px;
  margin: 24px 0;
  text-align: left;
}

.score-bar-group {
  margin-bottom: 16px;
}

.score-bar-group label {
  font-size: 14px;
  font-weight: 700;
  display: block;
  margin-bottom: 6px;
}

.progress-bar {
  height: 10px;
  background: #cbd5e1;
  border-radius: 9999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--primary);
}

.ethics-summary-text {
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 30px;
}

/* P8: Prompt Sandbox */
.prompt-sandbox-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.prompt-input-panel, .prompt-analysis-panel {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.prompt-input-panel textarea {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 10px;
  color: var(--text-main);
  padding: 16px;
  font-family: inherit;
  font-size: 16px;
  resize: none;
  flex-grow: 1;
  margin-bottom: 20px;
}

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

.sandbox-actions {
  display: flex;
  gap: 12px;
}

.score-display {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.score-num {
  font-size: 32px;
  font-weight: 800;
  color: var(--primary);
}

.score-bar {
  flex-grow: 1;
  height: 10px;
  background: #cbd5e1;
  border-radius: 9999px;
  overflow: hidden;
}

.score-fill {
  height: 100%;
  background: var(--primary);
  transition: width 0.3s ease;
}

.prompt-checklist {
  list-style-type: none;
  margin-bottom: 20px;
}

.prompt-checklist li {
  font-size: 15px;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.prompt-checklist li.success {
  color: var(--secondary);
}

.simulated-ai-response {
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  border-radius: 10px;
  padding: 16px;
  flex-grow: 1;
}

.simulated-ai-response h5 {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.ai-response-box {
  font-size: 15px;
  line-height: 1.6;
  color: #1e293b;
  max-height: 180px;
  overflow-y: auto;
}

/* P9: HTML Live Code Editor */
.editor-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.code-editor-box, .code-preview-box {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  height: 460px;
}

.code-editor-box textarea {
  width: 100%;
  flex-grow: 1;
  background: #0f172a;
  border: 1px solid #475569;
  border-radius: 8px;
  color: #38bdf8;
  font-family: 'Fira Code', monospace;
  font-size: 16px; /* Legible raw code */
  padding: 16px;
  resize: none;
}

.code-editor-box textarea:focus {
  border-color: var(--primary);
  outline: none;
}

.html-preview-frame {
  flex-grow: 1;
  background: white;
  color: #0f172a;
  border-radius: 8px;
  padding: 20px;
  overflow-y: auto;
  border: 2px solid #cbd5e1;
}

.html-preview-frame h1 { font-size: 32px; margin-bottom: 12px; }
.html-preview-frame h3 { font-size: 20px; margin: 16px 0 10px 0; }
.html-preview-frame p { font-size: 18px; margin-bottom: 12px; }
.html-preview-frame ul { margin-left: 28px; font-size: 18px; }

/* P10: Visual CSS Stylist */
.stylist-layout {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 32px;
}

.stylist-controls {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
}

.css-code-panel {
  background: #0f172a;
  border: 1px solid #475569;
  padding: 16px;
  border-radius: 10px;
  margin-top: 20px;
}

.css-code-panel h5 {
  font-size: 12px;
  color: #94a3b8;
  margin-bottom: 6px;
}

.css-code-panel code {
  font-family: 'Fira Code', monospace;
  font-size: 15px;
  color: #f43f5e;
  font-weight: 600;
}

.stylist-preview {
  display: flex;
  align-items: center;
  justify-content: center;
}

.styled-card-container {
  padding: 24px;
  border: 2px dashed #cbd5e1;
  border-radius: 20px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.profile-card {
  padding: 32px;
  width: 320px;
  transition: all 0.2s ease;
  box-shadow: 0 10px 20px rgba(0,0,0,0.05);
  background: white;
  border: 1px solid #e2e8f0;
}

.card-avatar {
  font-size: 52px;
  margin-bottom: 16px;
}

.profile-card h3 {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 6px;
}

.profile-card .card-desc {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.profile-card .card-text {
  font-size: 15px;
  line-height: 1.6;
}

/* P11: Navbar Builder */
.activity-navbar-builder {
  display: flex;
  justify-content: center;
}

.navbar-builder-container {
  width: 100%;
  max-width: 800px;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  overflow: hidden;
}

.builder-nav {
  background: #e2e8f0;
  border-bottom: 2px solid #cbd5e1;
  padding: 20px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
}

.nav-links-slots {
  display: flex;
  gap: 12px;
}

.nav-link-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.nav-link-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.builder-page-content {
  padding: 40px;
  min-height: 240px;
  background: #f8fafc;
  text-align: center;
}

.builder-page-content h2 {
  font-size: 22px;
  margin-bottom: 16px;
}

.builder-page-content p {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 580px;
  margin: 0 auto 20px auto;
}

.page-media {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  padding: 30px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: bold;
  color: var(--text-muted);
}

.builder-contact-form {
  max-width: 400px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.builder-contact-form input, .builder-contact-form textarea {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 6px;
  padding: 10px;
  font-family: inherit;
  font-size: 15px;
  color: var(--text-main);
}

.builder-feedback-box {
  background: rgba(99,102,241,0.06);
  padding: 16px;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  border-top: 2px solid #cbd5e1;
  color: var(--primary);
}

/* P12: Portfolio Web Generator */
.wizard-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 32px;
}

.wizard-form {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
}

.wizard-preview {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  height: 460px;
}

.preview-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.tab-btn {
  background: transparent;
  border: 2px solid #cbd5e1;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
}

.tab-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.preview-output-container {
  flex-grow: 1;
  border: 2px solid #cbd5e1;
  border-radius: 10px;
  overflow: hidden;
}

.wiz-visual-output {
  padding: 30px;
  height: 100%;
  overflow-y: auto;
  border-radius: 8px;
}

.theme-cyber {
  background: #0f172a;
  color: white;
}
.theme-cyber .viz-header h2 { color: #38bdf8; font-size: 26px; }
.theme-cyber .skill-tag { background: #1e293b; border: 1px solid #38bdf8; padding: 4px 10px; border-radius: 6px; font-size: 14px; }

.theme-light {
  background: #f8fafc;
  color: #0f172a;
  border: 1px solid #e2e8f0;
}
.theme-light .viz-header h2 { color: #1e3a8a; font-size: 26px; }
.theme-light .skill-tag { background: #e2e8f0; color: #1e293b; padding: 4px 10px; border-radius: 6px; font-size: 14px; }

.theme-emerald {
  background: #064e3b;
  color: white;
}
.theme-emerald .viz-header h2 { color: #34d399; font-size: 26px; }
.theme-emerald .skill-tag { background: #022c22; border: 1px solid #34d399; padding: 4px 10px; border-radius: 6px; font-size: 14px; }

.viz-skills-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.wiz-code-output {
  height: 100%;
}

.wiz-code-output textarea {
  width: 100%;
  height: 100%;
  background: #0f172a;
  border: none;
  color: #34d399;
  font-family: 'Fira Code', monospace;
  font-size: 14px;
  padding: 16px;
  resize: none;
}

/* P13: Client-Server Game */
.server-game-board {
  display: grid;
  grid-template-columns: 220px 1fr 220px;
  gap: 24px;
  align-items: center;
}

.actor {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 20px;
  text-align: center;
  height: 280px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.actor-icon {
  font-size: 52px;
}

.request-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-req-send {
  background: #e0e7ff;
  border: 2px solid var(--primary);
  color: var(--primary);
  font-size: 14px;
  font-weight: 700;
  padding: 8px;
  border-radius: 6px;
  cursor: pointer;
}

.btn-req-send:hover {
  background: var(--primary);
  color: white;
}

.network-cable-lane {
  position: relative;
  height: 80px;
}

.cable-line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 6px;
  background: #cbd5e1;
  transform: translateY(-50%);
}

.network-packet {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  background: var(--primary);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: bold;
}

.server-status-display {
  background: #cbd5e1;
  padding: 8px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.server-storage-visualization h6 {
  font-size: 13px;
  margin-bottom: 8px;
}

.storage-files {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: bold;
  text-align: left;
  background: #f1f5f9;
  padding: 8px;
  border-radius: 6px;
}

.game-feedback-box {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  padding: 16px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  text-align: center;
}

/* P14: DNS Tracer */
.dns-servers-flow {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 30px;
  margin: 24px 0;
}

.dns-node {
  width: 130px;
  padding: 16px 8px;
  border-radius: 12px;
  text-align: center;
  background: #f8fafc;
  border: 2px solid #cbd5e1;
  transition: all 0.3s ease;
}

.dns-node.active {
  background: #e0e7ff;
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(99,102,241,0.25);
}

.node-icon { font-size: 32px; margin-bottom: 6px; }
.dns-node h6 { font-size: 12px; font-weight: 800; margin-bottom: 4px; }
.node-ip { font-size: 10px; font-weight: 700; color: var(--text-muted); font-family: monospace; }

.dns-flow-lines {
  flex-grow: 1;
  position: relative;
  height: 20px;
}

.dns-path {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 3px;
  background: #cbd5e1;
  transform: translateY(-50%);
}

.dns-trace-logs {
  background: #0f172a;
  border: 1px solid #475569;
  border-radius: 10px;
  padding: 16px;
  height: 160px;
  overflow-y: auto;
  font-family: 'Fira Code', monospace;
  font-size: 14px;
}

.log-entry { margin-bottom: 6px; color: #94a3b8; }
.log-entry.success { color: #34d399; font-weight: bold; }

/* P15: Git Command Terminal */
.terminal-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 24px;
}

.terminal-guide {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 20px;
}

.deployment-steps-list {
  list-style: none;
  margin-top: 16px;
}

.deployment-steps-list li {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 16px;
  padding-left: 12px;
  border-left: 3px solid #cbd5e1;
}

.deployment-steps-list li.active {
  color: var(--primary);
  border-color: var(--primary);
  font-weight: 800;
}

.deployment-steps-list li.completed {
  color: var(--secondary);
  border-color: var(--secondary);
}

.terminal-console {
  background: #0f172a;
  border: 2px solid #475569;
  border-radius: 12px;
  overflow: hidden;
  height: 380px;
  display: flex;
  flex-direction: column;
}

.console-header {
  background: #1e293b;
  padding: 8px 16px;
  font-size: 13px;
  color: #94a3b8;
  font-weight: bold;
}

.console-body {
  flex-grow: 1;
  padding: 20px;
  overflow-y: auto;
  font-family: 'Fira Code', monospace;
  font-size: 15px; /* Larger terminal print for projector */
  line-height: 1.6;
  color: #e2e8f0;
}

.console-line.error { color: #f43f5e; font-weight: bold; }
.console-line.success { color: #34d399; font-weight: bold; }

.console-input-row {
  display: flex;
  align-items: center;
  background: #000;
  border-top: 1px solid #475569;
  padding: 10px 16px;
  font-family: 'Fira Code', monospace;
}

.console-input-row span {
  color: var(--secondary);
  font-weight: bold;
  margin-right: 10px;
  font-size: 16px;
}

.console-input-row input {
  flex-grow: 1;
  background: transparent;
  border: none;
  color: white;
  font-family: inherit;
  font-size: 15px;
}

.console-input-row input:focus {
  outline: none;
}

/* P16: Peer Review */
.review-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 24px;
}

.review-form {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 20px;
}

.review-dashboard {
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.reviews-table-container {
  overflow-x: auto;
  max-height: 200px;
  margin-bottom: 16px;
}

.review-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  font-weight: 600;
}

.review-table th, .review-table td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 2px solid #cbd5e1;
}

.review-table th {
  color: var(--text-muted);
}

.radar-chart-mock {
  text-align: center;
}

.performance-svg {
  height: 180px; /* Bigger radar chart */
}

/* ==========================================================================
   SIDEBAR TOGGLE & FULLSCREEN PRESENTATION CLASSES
   ========================================================================== */

/* 1. Toggle Sidebar Mode */
.sidebar-hidden .sidebar {
  display: none !important;
}

/* 2. Fullscreen Presentation Mode */
.fullscreen-active .sidebar {
  display: none !important;
}

.fullscreen-active .top-header {
  height: 70px;
  padding: 0 24px;
}

.fullscreen-active .meeting-indicator p {
  font-size: 12px;
}

.fullscreen-active .meeting-indicator h3 {
  font-size: 18px;
}

.fullscreen-active .slide-tabs {
  padding: 4px;
}

.fullscreen-active .slide-tab {
  padding: 6px 14px;
  font-size: 14px;
}

.fullscreen-active .slide-viewer {
  padding: 16px;
  background: #f1f5f9;
}

.fullscreen-active .slide-card {
  max-width: 98vw !important;
  width: 98vw !important;
  min-height: 82vh !important;
  height: 82vh !important;
  padding: 48px !important;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  justify-content: flex-start;
  overflow-y: auto;
}

/* Maximize Fullscreen Typography sizes for projector */
.fullscreen-active .slide-cover-layout h2 {
  font-size: 56px !important;
  margin-bottom: 36px !important;
}

.fullscreen-active .slide-cover-layout .subtitle {
  font-size: 20px !important;
  margin-bottom: 20px !important;
}

.fullscreen-active .learning-objectives-card {
  max-width: 960px !important;
  padding: 40px !important;
}

.fullscreen-active .learning-objectives-card h4 {
  font-size: 26px !important;
  margin-bottom: 24px !important;
}

.fullscreen-active .learning-objectives-card li {
  font-size: 24px !important;
  margin-bottom: 16px !important;
  padding-left: 36px !important;
}

.fullscreen-active .learning-objectives-card li::before {
  font-size: 20px !important;
}

.fullscreen-active .slide-header {
  font-size: 44px !important;
  margin-bottom: 32px !important;
  padding-bottom: 16px !important;
}

.fullscreen-active .slide-body-text {
  font-size: 30px !important; /* Extremely clear from the very back */
  line-height: 1.8 !important;
}

.fullscreen-active .slide-body-text code {
  font-size: 24px !important;
  padding: 4px 10px !important;
}

.fullscreen-active .slide-body-text pre {
  padding: 24px !important;
  margin-top: 24px !important;
}

.fullscreen-active .slide-body-text pre code {
  font-size: 24px !important;
}

.fullscreen-active .activity-slide-container .instruction-box {
  font-size: 22px !important;
  padding: 24px !important;
  margin-bottom: 32px !important;
}

/* Fullscreen scaling for specific activities */
.fullscreen-active .game-grid {
  width: 460px !important;
  height: 460px !important;
}

.fullscreen-active .grid-cell {
  font-size: 40px !important;
}

.fullscreen-active .btn-cmd {
  font-size: 18px !important;
  padding: 12px 18px !important;
}

.fullscreen-active .flow-node {
  font-size: 16px !important;
  padding: 10px 20px !important;
  width: 260px !important;
}

.fullscreen-active .palette-panel,
.fullscreen-active .workspace-panel,
.fullscreen-active .code-output-panel {
  height: 520px !important;
}

.fullscreen-active .visual-block {
  font-size: 16px !important;
  padding: 12px 18px !important;
}

.fullscreen-active .python-code-box pre,
.fullscreen-active .console-box pre {
  font-size: 18px !important;
}

.fullscreen-active .form-group label {
  font-size: 16px !important;
}

.fullscreen-active .form-group input,
.fullscreen-active .form-group select {
  font-size: 18px !important;
  padding: 12px 16px !important;
}

.fullscreen-active .ram-slot {
  min-height: 140px !important;
}

.fullscreen-active .slot-var-name {
  font-size: 22px !important;
}

.fullscreen-active .slot-var-val,
.fullscreen-active .slot-binary {
  font-size: 16px !important;
}

.fullscreen-active .stage-cell {
  width: 200px !important;
  height: 120px !important;
  font-size: 18px !important;
}

.fullscreen-active .dungeon-statement,
.fullscreen-active .dungeon-action {
  font-size: 20px !important;
}

.fullscreen-active .dungeon-statement select,
.fullscreen-active .dungeon-action select {
  font-size: 18px !important;
}

.fullscreen-active .video-thumbnail {
  height: 140px !important;
  font-size: 48px !important;
}

.fullscreen-active .video-title {
  font-size: 18px !important;
}

.fullscreen-active .video-creator,
.fullscreen-active .video-stats {
  font-size: 14px !important;
}

.fullscreen-active .dilemma-card {
  max-width: 850px !important;
  padding: 48px !important;
}

.fullscreen-active .card-title {
  font-size: 28px !important;
}

.fullscreen-active .card-desc {
  font-size: 20px !important;
}

.fullscreen-active .btn-eth-option {
  font-size: 18px !important;
  padding: 18px 24px !important;
}

.fullscreen-active .prompt-input-panel textarea {
  font-size: 18px !important;
  padding: 20px !important;
}

.fullscreen-active .prompt-checklist li {
  font-size: 18px !important;
}

.fullscreen-active .ai-response-box {
  font-size: 18px !important;
  max-height: 220px !important;
}

.fullscreen-active .code-editor-box,
.fullscreen-active .code-preview-box {
  height: 520px !important;
}

.fullscreen-active .code-editor-box textarea {
  font-size: 18px !important;
}

.fullscreen-active .html-preview-frame h1 { font-size: 38px !important; }
.fullscreen-active .html-preview-frame h3 { font-size: 24px !important; }
.fullscreen-active .html-preview-frame p,
.fullscreen-active .html-preview-frame ul { font-size: 22px !important; }

.fullscreen-active .profile-card {
  width: 380px !important;
  padding: 40px !important;
}

.fullscreen-active .card-avatar {
  font-size: 64px !important;
}

.fullscreen-active .profile-card h3 {
  font-size: 26px !important;
}

.fullscreen-active .profile-card .card-text {
  font-size: 18px !important;
}

.fullscreen-active .builder-page-content {
  min-height: 300px !important;
}

.fullscreen-active .builder-page-content h2 {
  font-size: 26px !important;
}

.fullscreen-active .builder-page-content p {
  font-size: 18px !important;
}

.fullscreen-active .actor {
  height: 320px !important;
}

.fullscreen-active .actor-icon {
  font-size: 64px !important;
}

.fullscreen-active .btn-req-send {
  font-size: 16px !important;
  padding: 10px !important;
}

.fullscreen-active .dns-node {
  width: 150px !important;
  padding: 20px 10px !important;
}

.fullscreen-active .dns-node h6 {
  font-size: 14px !important;
}

.fullscreen-active .node-ip {
  font-size: 11px !important;
}

.fullscreen-active .dns-trace-logs {
  height: 200px !important;
  font-size: 16px !important;
}

.fullscreen-active .terminal-console {
  height: 480px !important;
}

.fullscreen-active .console-body {
  font-size: 18px !important;
}

.fullscreen-active .console-input-row input {
  font-size: 18px !important;
}

.fullscreen-active .review-table {
  font-size: 16px !important;
}

.fullscreen-active .performance-svg {
  height: 240px !important;
}

/* --- Class Filter Styling --- */
.class-filter-container {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.class-filter-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 4px;
}

.custom-select-wrapper {
  position: relative;
  width: 100%;
}

.class-select-dropdown {
  width: 100%;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  background-color: var(--bg-main);
  border: 2px solid var(--border-glass);
  border-radius: 10px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.class-select-dropdown:hover {
  border-color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: 0 4px 12px var(--primary-glow);
}

.class-select-dropdown:focus {
  outline: none;
  border-color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Custom indicator chevron for dropdown */
.custom-select-wrapper::after {
  content: "▼";
  font-size: 9px;
  color: var(--text-muted);
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  transition: transform 0.2s ease;
}

.custom-select-wrapper:focus-within::after {
  transform: translateY(-50%) rotate(180deg);
  color: var(--primary);
}

/* --- Authentication & Teacher Control Styles --- */

/* User badge styling */
.user-badge {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 9999px;
  background-color: var(--secondary);
  color: white;
  letter-spacing: 0.05em;
}

.user-badge.role-guru {
  background-color: var(--primary);
}

/* Logout Button */
.btn-logout-small {
  background: transparent;
  border: 1.5px solid var(--border-glass);
  color: var(--accent);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-logout-small:hover {
  background: var(--accent-glow);
  border-color: var(--accent);
}

/* Modal Overlay base */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  animation: fadeIn 0.3s ease-out forwards;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Modal Card */
.modal-card {
  background: var(--bg-card);
  border: 2px solid var(--border-glass);
  border-radius: 24px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  max-width: 100%;
  animation: slideUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes slideUp {
  from { transform: translateY(30px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Login Card size */
.login-card {
  width: 420px;
  padding: 40px;
}

.login-header {
  text-align: center;
  margin-bottom: 28px;
}

.login-header h2 {
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}

.login-header p {
  font-size: 14px;
  color: var(--text-muted);
}

.form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}

.form-group label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  background-color: var(--bg-main);
  border: 2px solid var(--border-glass);
  border-radius: 12px;
  color: var(--text-main);
  font-family: inherit;
  transition: all 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.login-error {
  background-color: rgba(225, 29, 72, 0.1);
  border: 1.5px solid var(--accent);
  color: var(--accent);
  padding: 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.btn-block {
  width: 100%;
}

/* Teacher Card size */
.teacher-card {
  width: 100vw;
  height: 100vh;
  max-height: 100vh;
  border-radius: 0;
  border: none;
}

.modal-header {
  padding: 24px 32px;
  border-bottom: 2px solid var(--border-glass);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--primary);
}

.btn-close-modal {
  background: transparent;
  border: none;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s ease;
}

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

.modal-body {
  padding: 32px;
  overflow-y: auto;
  flex-grow: 1;
}

.teacher-settings-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 32px;
}

.settings-left, .settings-right {
  display: flex;
  flex-direction: column;
}

.settings-left h3, .settings-right h3 {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
  border-bottom: 1.5px solid var(--border-glass);
  padding-bottom: 8px;
}

.meetings-dates-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 65vh;
  overflow-y: auto;
  padding-right: 10px;
}

.date-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-main);
  padding: 10px 16px;
  border-radius: 12px;
  border: 1.5px solid transparent;
  transition: all 0.2s ease;
}

.date-row:hover {
  border-color: var(--border-glass-glow);
  background-color: var(--bg-card);
}

.date-row span {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
}

.date-row input[type="date"] {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1.5px solid var(--border-glass);
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  color: var(--text-main);
  background-color: var(--bg-card);
  outline: none;
  transition: all 0.2s ease;
}

.date-row input[type="date"]:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.modal-footer {
  padding: 20px 32px;
  border-top: 2px solid var(--border-glass);
  display: flex;
  justify-content: flex-end;
  background-color: var(--bg-main);
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
}

/* Sidebar locked meetings style */
.meeting-item.locked {
  opacity: 0.65;
  cursor: not-allowed;
}

.meeting-item.locked .meeting-checkbox {
  background-color: #cbd5e1 !important;
  border-color: #94a3b8 !important;
}

.meeting-item.locked .meeting-checkbox::after {
  content: "🔒" !important;
  font-size: 11px;
}

.meeting-item.locked .meeting-title {
  color: #64748b !important;
}

.locked-badge {
  font-size: 10px;
  font-weight: 700;
  background-color: #f1f5f9;
  color: #64748b;
  padding: 1px 6px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  width: fit-content;
}

/* Lock slide notification screen */
.locked-slide-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 100%;
  min-height: 400px;
  padding: 40px;
}

.locked-slide-icon {
  font-size: 80px;
  margin-bottom: 24px;
  animation: lockBounce 2s infinite ease-in-out;
}

@keyframes lockBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.locked-slide-container h2 {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}

.locked-slide-container p {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 500px;
  margin-bottom: 24px;
  line-height: 1.6;
}

.locked-slide-date-box {
  background-color: rgba(99, 102, 241, 0.05);
  border: 2px dashed var(--primary);
  border-radius: 16px;
  padding: 16px 28px;
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
}

/* Modal Tab buttons */
.modal-tab-btn:hover {
  color: var(--primary) !important;
  opacity: 0.9;
}

.modal-tab-btn.active {
  color: var(--primary) !important;
  border-bottom: 3px solid var(--primary) !important;
}

/* Student Table Styles */
.student-table th, .student-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border-glass);
}

.student-table tbody tr {
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.student-table tbody tr:hover {
  background-color: rgba(99, 102, 241, 0.04);
}

.student-table td button {
  padding: 4px 8px;
  font-size: 11px;
  font-weight: bold;
  border-radius: 6px;
  cursor: pointer;
}

/* Detail Box Grid */
.student-detail-card {
  box-shadow: 0 20px 40px rgba(0,0,0,0.3) !important;
}

.detail-box {
  background-color: var(--bg-main);
  border: 1.5px solid var(--border-glass);
  border-radius: 12px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.detail-box.completed {
  border-color: rgba(16, 185, 129, 0.25);
  background-color: rgba(16, 185, 129, 0.02);
}

.detail-box-meet {
  font-weight: 800;
  font-size: 14px;
  color: var(--text-main);
}

.detail-status-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  align-items: center;
}

.status-badge {
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: bold;
  font-size: 10px;
}

.status-badge.yes {
  background-color: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.status-badge.no {
  background-color: rgba(225, 29, 72, 0.1);
  color: var(--accent);
}


/* ==========================================================================
   RESPONSIVE MOBILE STYLES (max-width: 768px)
   ========================================================================== */

@media (max-width: 1024px) {
  /* --- Sidebar: slide over content on mobile --- */
  .sidebar {
    position: fixed;
    left: -100%;
    top: 0;
    width: 85vw;
    max-width: 340px;
    height: 100vh;
    z-index: 1000;
    transition: left 0.3s ease;
    box-shadow: 4px 0 30px rgba(0,0,0,0.2);
  }

  .sidebar.mobile-open {
    left: 0;
  }

  /* Backdrop overlay for sidebar */
  .sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 999;
  }

  .sidebar-backdrop.visible {
    display: block;
  }

  /* Main content fills full width */
  .app-container {
    flex-direction: column;
  }

  .main-content {
    width: 100%;
    height: 100vh;
  }

  /* --- Top Header: compact & single line on mobile --- */
  .top-header {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    height: 64px !important;
    min-height: 64px !important;
    padding: 0 12px !important;
    gap: 8px !important;
    box-sizing: border-box;
  }

  .header-left {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px !important;
    flex-grow: 1;
    min-width: 0;
  }

  #btn-toggle-sidebar,
  #btn-toggle-theme,
  #btn-teacher-panel,
  #btn-header-logout {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 40px !important;
    height: 40px !important;
    padding: 0 !important;
    font-size: 16px !important;
    border-radius: 10px !important;
    color: var(--text-main);
    box-sizing: border-box;
    flex-shrink: 0;
  }

  .menu-text-desktop {
    display: none !important;
  }

  .meeting-indicator {
    flex-grow: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    margin-left: 4px;
  }

  .meeting-indicator p {
    font-size: 10px;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .meeting-indicator h3 {
    font-size: 12px;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header-right {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-end !important;
    width: auto !important;
    gap: 6px !important;
    flex-shrink: 0;
  }

  /* Slide tabs: full-width segmented style on mobile */
  .slide-tabs {
    width: 100% !important;
    max-width: 100% !important;
    display: flex !important;
    padding: 4px !important;
    gap: 4px !important;
    box-sizing: border-box !important;
  }

  .slide-tab {
    flex: 1 1 0% !important;
    min-width: 0 !important;
    text-align: center !important;
    padding: 6px 2px !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    border-radius: 6px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  #btn-fullscreen {
    display: none !important;
  }

  #btn-teacher-panel {
    width: 100%;
    justify-content: center;
    padding: 8px 16px !important;
    font-size: 12px !important;
    margin-top: 2px;
  }

  /* Sub tabs for student progress/quiz split */
  .sub-tabs-container {
    width: 100%;
    display: flex;
    gap: 4px !important;
    margin-bottom: 12px !important;
  }

  .sub-tab-btn {
    flex: 1;
    text-align: center;
    padding: 8px 4px !important;
    font-size: 11px !important;
  }

  /* --- Slide Viewer: full width, minimal padding --- */
  .slide-viewer {
    padding: 10px;
  }

  .slide-card {
    padding: 20px 16px;
    min-height: auto;
    border-radius: 14px;
  }

  /* Slide typography scale down */
  .slide-header {
    font-size: 20px;
    margin-bottom: 16px;
  }

  .slide-body-text {
    font-size: 16px;
    line-height: 1.6;
  }

  .slide-body-text code {
    font-size: 13px;
  }

  .slide-body-text pre code {
    font-size: 12px;
  }

  .slide-cover-layout h2 {
    font-size: 26px;
    margin-bottom: 16px;
  }

  .slide-cover-layout .subtitle {
    font-size: 12px;
  }

  .learning-objectives-card {
    padding: 16px;
  }

  .learning-objectives-card li {
    font-size: 15px;
  }

  /* --- Footer controls: full width & stacked for mobile --- */
  .slide-footer-controls {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 12px 14px;
    height: auto;
  }

  .slide-footer-controls button {
    width: 100% !important;
  }

  .nav-buttons {
    display: flex;
    width: 100%;
    gap: 10px;
  }

  .nav-buttons button {
    flex: 1;
    justify-content: center;
    padding: 10px 16px !important;
    font-size: 13px !important;
  }

  .meeting-completion-area {
    width: 100%;
    display: flex;
    gap: 10px !important;
  }

  .meeting-completion-area button {
    width: 100%;
    justify-content: center;
    padding: 10px 16px !important;
    font-size: 13px !important;
  }

  /* --- Login Modal: full width --- */
  .login-card {
    width: 92vw;
    padding: 28px 20px;
    border-radius: 20px;
  }

  .login-header h2 {
    font-size: 22px;
  }

  /* --- Teacher Panel: fixed header & scrollable body on mobile --- */
  .teacher-card {
    width: 100vw !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }

  .modal-header {
    padding: 14px 16px !important;
    flex-shrink: 0 !important;
  }

  .modal-header h2 {
    font-size: 16px !important;
  }

  .modal-tabs {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    width: 100% !important;
    gap: 8px !important;
    padding: 8px 12px !important;
    border-bottom: 2px solid var(--border-glass) !important;
    background-color: var(--bg-card) !important;
    flex-shrink: 0 !important;
  }

  .modal-tab-btn {
    flex: 0 0 auto !important;
    white-space: nowrap !important;
    padding: 8px 12px !important;
    font-size: 11px !important;
    border-radius: 8px !important;
    border-bottom: none !important;
    background: none !important;
    color: var(--text-muted) !important;
  }

  .modal-tab-btn.active {
    color: var(--primary) !important;
    border-bottom: 3px solid var(--primary) !important;
  }

  .modal-body {
    flex-grow: 1 !important;
    overflow-y: auto !important;
    padding: 16px 12px !important;
    -webkit-overflow-scrolling: touch;
  }

  /* Teacher settings: single column */
  .teacher-settings-grid {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }

  .meetings-dates-list {
    max-height: 45vh;
  }

  .date-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
  }

  .date-row span {
    font-size: 12px;
  }

  .date-row input[type="date"] {
    width: 100%;
    font-size: 12px;
  }

  /* Student master: single column */
  .student-master-grid {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }

  .table-container {
    max-height: 50vh !important;
  }

  .student-table {
    font-size: 11px !important;
  }

  .student-table th,
  .student-table td {
    padding: 8px 6px !important;
  }

  /* Student Detail Modal */
  .student-detail-card {
    width: 95vw !important;
    max-height: 90dvh !important;
    border-radius: 16px !important;
  }

  #student-detail-grid {
    grid-template-columns: 1fr !important;
  }

  /* --- Activity grids: single column --- */
  .game-grid-container {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }

  .game-grid {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    max-width: 320px;
    margin: 0 auto;
  }

  .translator-layout {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }

  .palette-panel,
  .workspace-panel,
  .code-output-panel {
    height: 280px;
  }

  /* Sidebar header compact */
  .sidebar-header {
    padding: 16px 16px;
  }

  .sidebar-logo {
    font-size: 18px;
  }

  .sidebar-logo span {
    font-size: 22px;
  }

  .btn-logout-small {
    font-size: 11px;
    padding: 4px 8px;
  }

  .progress-section {
    padding: 12px 16px;
  }

  .modules-list {
    padding: 12px 10px;
  }

  .meeting-item {
    padding: 10px 12px;
  }

  .meeting-title {
    font-size: 14px;
  }
}

/* Extra-small phones */
@media (max-width: 400px) {
  .slide-tab {
    padding: 5px 6px;
    font-size: 10px;
  }

  .slide-card {
    padding: 14px 10px;
  }

  .slide-header {
    font-size: 17px;
  }

  .slide-body-text {
    font-size: 14px;
  }

  .nav-buttons button,
  .meeting-completion-area button {
    padding: 7px 10px;
    font-size: 12px;
  }
}

/* ==========================================================================
   COMPUTER LAB SEATING CHART STYLES (DENAH KURSI)
   ========================================================================== */
.seating-grid-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  padding: 10px;
}

.com-unit {
  background: var(--bg-card);
  border: 1.5px solid var(--border-glass);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.com-unit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06);
  border-color: rgba(99, 102, 241, 0.3);
}

.com-header {
  background: var(--bg-main);
  padding: 8px 12px;
  text-align: center;
  font-weight: 800;
  font-size: 13px;
  border-bottom: 1.5px solid var(--border-glass);
  color: var(--primary);
  letter-spacing: 0.5px;
}

.com-seats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 10px;
  gap: 10px;
}

.com-seat {
  background: rgba(0, 0, 0, 0.02);
  border: 1.5px dashed var(--border-glass);
  border-radius: 8px;
  padding: 12px 6px;
  min-height: 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-muted);
}

.com-seat:hover {
  background: rgba(99, 102, 241, 0.05);
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(1.02);
}

.com-seat.occupied {
  background: rgba(16, 185, 129, 0.08);
  border: 1.5px solid #10b981;
  color: #065f46;
}

.com-seat.occupied:hover {
  background: rgba(225, 29, 72, 0.06);
  border-color: var(--accent);
  color: var(--accent);
}

.seat-label {
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  opacity: 0.8;
}

.seat-student-name {
  font-size: 12px;
  font-weight: 700;
  word-break: break-word;
  line-height: 1.2;
}

/* Responsiveness for Seating Chart - Enforce 4x5 grid layout on all devices */
@media (max-width: 992px) {
  .seating-grid-container {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 8px !important;
    padding: 4px !important;
  }
  
  .com-header {
    font-size: 10px !important;
    padding: 3px !important;
  }
  
  .com-seat {
    padding: 4px 2px !important;
    min-height: 40px !important;
  }
  
  .seat-label {
    font-size: 8px !important;
  }
  
  .seat-student-name {
    font-size: 9px !important;
  }
}

@media (max-width: 576px) {
  .seating-grid-container {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 5px !important;
    padding: 2px !important;
  }
  
  .com-header {
    font-size: 9px !important;
    padding: 2px !important;
  }
  
  .com-seat {
    padding: 3px 1px !important;
    min-height: 36px !important;
  }
  
  .seat-label {
    display: none !important; /* Sembunyikan label Kiri/Kanan agar muat di HP */
  }
  
  .seat-student-name {
    font-size: 8px !important;
  }
}

/* ==========================================================================
   MODERN DARK MODE & SLIDE TRANSITIONS & DASHBOARD ANALYTICS
   ========================================================================== */

/* 1. Dark Mode Variables Override */
[data-theme="dark"] {
  --bg-main: #0b0f19;
  --bg-card: #151c2e;
  --bg-sidebar: #0f1524;
  --bg-glass: rgba(99, 102, 241, 0.08);
  --border-glass: rgba(99, 102, 241, 0.25);
  --border-glass-glow: rgba(99, 102, 241, 0.5);

  --primary: #6366f1;
  --primary-glow: rgba(99, 102, 241, 0.3);
  --secondary: #10b981;
  --secondary-glow: rgba(16, 185, 129, 0.3);
  --accent: #f43f5e;
  --accent-glow: rgba(244, 63, 94, 0.3);

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-glow: #e2e8f0;
}

/* 2. Specific Overrides for Dark Mode Elements */
[data-theme="dark"] .top-header,
[data-theme="dark"] .modal-tabs {
  background-color: var(--bg-sidebar) !important;
}

[data-theme="dark"] .slide-tabs {
  background-color: #1e293b;
  border-color: #334155;
}

[data-theme="dark"] .slide-tab {
  color: var(--text-muted);
}

[data-theme="dark"] .slide-tab.active {
  background-color: var(--primary);
  color: white;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: #334155;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

[data-theme="dark"] input, 
[data-theme="dark"] select, 
[data-theme="dark"] textarea {
  background-color: #1e293b !important;
  color: var(--text-main) !important;
  border-color: var(--border-glass) !important;
}

[data-theme="dark"] select option {
  background-color: #1e293b;
  color: var(--text-main);
}

[data-theme="dark"] .meeting-item:hover,
[data-theme="dark"] .student-table tbody tr:hover {
  background-color: rgba(99, 102, 241, 0.08);
}

[data-theme="dark"] .meeting-item.active {
  background-color: rgba(99, 102, 241, 0.15);
}

[data-theme="dark"] .meeting-item.locked .meeting-checkbox {
  background-color: #334155 !important;
  border-color: #475569 !important;
}

[data-theme="dark"] .locked-badge {
  background-color: #1e293b;
  color: #94a3b8;
  border-color: #334155;
}

[data-theme="dark"] .locked-slide-date-box {
  background-color: rgba(99, 102, 241, 0.1);
}

[data-theme="dark"] .detail-box {
  background-color: #0f1524;
}

[data-theme="dark"] .detail-box.completed {
  background-color: rgba(16, 185, 129, 0.04);
}

[data-theme="dark"] .com-unit {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .com-header {
  background-color: #0b0f19;
}

[data-theme="dark"] .com-seat {
  background-color: rgba(255, 255, 255, 0.02);
}

[data-theme="dark"] .com-seat:hover {
  background-color: rgba(99, 102, 241, 0.12);
}

[data-theme="dark"] .com-seat.occupied {
  background-color: rgba(16, 185, 129, 0.15);
  color: #a7f3d0;
}

[data-theme="dark"] .modal-card {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

/* 3. Slide Transitions: Child elements entry animation */
.slide-card > * {
  animation: slideFadeIn 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 4. Analytics SVG and Layout Styles */
.analytics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.analytics-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.analytics-card:hover {
  transform: translateY(-2px);
}

[data-theme="dark"] .analytics-card,
[data-theme="dark"] .analytics-chart-card {
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25) !important;
}

.chart-scroll-container::-webkit-scrollbar {
  height: 8px;
}

.chart-scroll-container::-webkit-scrollbar-thumb {
  background: #cbd5e1;
}

[data-theme="dark"] .chart-scroll-container::-webkit-scrollbar-thumb {
  background: #475569;
}


/* ==========================================================================
   NEW CONTINUOUS SCROLL LEARNING WEBSITE LAYOUT
   ========================================================================== */

.learning-page-container {
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 8px 0;
}

.learning-section-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border-glass);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-sizing: border-box;
  text-align: left;
}

.learning-section-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 800;
  border-radius: 8px;
  background-color: var(--primary-glow);
  color: var(--primary);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.learning-text-content {
  margin-top: 16px;
  line-height: 1.75;
  font-size: 15px;
  color: var(--text-main);
  word-break: break-word;
}

.learning-text-content b {
  color: var(--primary);
  font-weight: 700;
}

[data-theme="dark"] .learning-text-content b {
  color: #818cf8; /* Lighter indigo for readability */
}

.learning-text-content code {
  background: rgba(99, 102, 241, 0.1);
  padding: 2px 6px;
  border-radius: 6px;
  font-family: 'Fira Code', monospace;
  font-size: 13.5px;
  color: var(--primary);
  font-weight: 600;
  word-break: break-word;
  white-space: pre-wrap;
  max-width: 100%;
}

[data-theme="dark"] .learning-text-content code {
  background: rgba(129, 140, 248, 0.15);
  color: #818cf8;
}

/* Locked Quiz Overlay Styling */
.quiz-lock-overlay {
  background: rgba(15, 23, 42, 0.03);
  border: 2px dashed var(--border-glass);
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

[data-theme="dark"] .quiz-lock-overlay {
  background: rgba(255, 255, 255, 0.02);
}

/* Scrollable Container Overrides */
.slide-viewer {
  flex-grow: 1;
  overflow-y: auto !important;
  padding: 24px 20px;
  -webkit-overflow-scrolling: touch;
}

/* Universal Responsive Rules */
img, video, iframe {
  max-width: 100% !important;
  height: auto !important;
}

pre, code {
  max-width: 100% !important;
  box-sizing: border-box !important;
  word-break: break-word !important;
  white-space: pre-wrap !important;
}

pre {
  overflow-x: auto !important;
}

table {
  max-width: 100% !important;
  word-break: break-word !important;
}

/* HP/Mobile Overrides for continuous scroll layout */
@media (max-width: 768px) {
  .learning-page-container {
    padding: 0;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .learning-section-card {
    padding: 16px 14px;
    border-radius: 12px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .learning-text-content {
    font-size: 14px;
    line-height: 1.65;
    word-break: break-word;
  }
  
  .slide-viewer {
    padding: 12px 8px !important;
    overflow-x: hidden !important;
  }

  .activity-slide-container {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .quiz-section-card {
    padding: 16px 12px !important;
    box-sizing: border-box !important;
  }

  .quiz-lock-overlay {
    padding: 20px 14px !important;
  }
}

@media (max-width: 480px) {
  .section-badge {
    font-size: 10px;
    padding: 4px 8px;
  }

  .learning-section-card h3 {
    font-size: 16px !important;
  }

  .activity-question {
    font-size: 15px !important;
    margin-bottom: 14px !important;
  }

  .game-grid {
    width: 100% !important;
    max-width: 280px !important;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
  }

  .grid-cell {
    font-size: 24px !important;
  }

  .instruction-box {
    padding: 10px !important;
    font-size: 13px !important;
  }
}
