:root {
  --bg-100: #f6f9fc;
  --primary: #0b63b7; /* slightly brighter */
  --primary-600: #084a86;
  --accent: #1e73be;
  --success: #16a34a;
  --muted: #6b7280;
  --card: #ffffff;
  --rounded: 14px;
  --shadow-1: 0 10px 30px rgba(11,78,153,0.08);
  --shadow-2: 0 4px 16px rgba(2,6,23,0.06);
}

/* Base */
* { box-sizing: border-box; }
html { width: 100%; height: 100%; margin: 0; padding: 0;}
body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
  background: linear-gradient(180deg, #f7fbff 0%, #eef4fb 100%);
  color: #0f1724;
  font-size: 15px;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}

/* Utility containers */
.container { 
  width: 100%; 
  padding: 20px;
  box-sizing: border-box;
  overflow-x: hidden;
}

@media (max-width: 768px) { 
  .container { 
    padding: 16px; 
  } 
}

@media (max-width: 480px) { 
  .container { 
    padding: 12px; 
  } 
}

/* Buttons */
button { font-family: inherit; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; border: none; border-radius: 12px; padding: 10px 18px; transition: transform .12s ease, box-shadow .12s ease, background .12s ease; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: white; box-shadow: var(--shadow-1); }
.btn-primary:hover { background: var(--primary-600); }
.btn-ghost { background: transparent; color: var(--primary); border: 1px solid rgba(11,78,153,0.08); }
.btn-success { background: var(--success); color: white; }
.btn:focus { outline: none; box-shadow: 0 0 0 4px rgba(11,99,183,0.12); }

/* Inputs */
input,textarea,select { font: inherit; padding: 12px 14px; border-radius: 10px; border: 1px solid #e6eef6; background: #ffffff; width: 100%; }
input:focus,textarea:focus { outline: none; box-shadow: 0 6px 18px rgba(30,115,190,0.08); border-color: var(--accent); }

/* Login */
.login-wrapper { width: 100%; min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-body { width: 100%; min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card { width: 100%; max-width: 460px; background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.96)); border-radius: 18px; box-shadow: var(--shadow-1); padding: 40px; }

@media (max-width: 768px) {
  .login-wrapper, .login-body { padding: 16px; }
  .login-card { padding: 32px; }
}

@media (max-width: 480px) {
  .login-wrapper, .login-body { padding: 12px; }
  .login-card { padding: 24px; border-radius: 12px; }
}
.brand-container { display:flex; align-items:center; gap:18px; margin-bottom: 24px; }
.logo { width: 84px; height: auto; border-radius: 10px; object-fit:cover; }
.brand-text h1 { margin:0; font-size:24px; color:var(--primary); }
.brand-text p { margin: 0; font-size:12px; color:var(--muted); letter-spacing:0.6px; text-transform:uppercase; }

.form-group { margin-bottom:16px; }
.form-group label { display:block; font-size:13px; margin-bottom:8px; color:#26303a; font-weight:700; }

.action-buttons { display:flex; flex-direction:column; gap:12px; margin-top:10px; }
.primary-btn { width:100%; }
.secondary-btn { width:100%; }

.divider { margin-top: 20px; text-align:center; font-size:12px; color:var(--muted); }

/* QUIZ LAYOUT */
.assessment-layout { width: 100%; display: grid; grid-template-columns: 1fr 320px; gap: 28px; padding: 28px; min-height: 100vh; }

@media (max-width: 1024px) {
  .assessment-layout { grid-template-columns: 1fr; gap: 20px; padding: 20px; }
}

@media (max-width: 768px) {
  .assessment-layout { grid-template-columns: 1fr; gap: 16px; padding: 16px; }
}

@media (max-width: 480px) {
  .assessment-layout { grid-template-columns: 1fr; gap: 12px; padding: 8px; }
}
.question-module { background:var(--card); border-radius: 18px; padding: 30px; box-shadow: var(--shadow-2); }
.question-text h2 { margin: 0 0 12px 0; font-size:20px; line-height:1.4; }

.options-grid { display:grid; grid-template-columns: 1fr; gap:14px; margin-top:18px; }
.option-item { border:1px solid #e8eef7; padding:16px 18px; border-radius:14px; cursor:pointer; transition: all .14s ease; display:flex; align-items:center; gap:12px; }
.option-item:hover { background:#f7fbff; transform: translateY(-2px); }
.option-item.selected { background: var(--primary); color:white; border-color: var(--primary); box-shadow: 0 8px 20px rgba(11,99,183,0.08); }
.option-item .opt-text { font-size:16px; }
.option-item input { margin-right:12px; transform:scale(1.08); }

.control-bar { display:flex; justify-content:space-between; gap:12px; margin-top:26px; }
.nav-section { display:flex; gap:12px; }

/* Sidebar / palette */
.sidebar { background:var(--card); border-radius: 14px; padding:18px; box-shadow: var(--shadow-2); }
.palette-grid { display:grid; grid-template-columns: repeat(5, 1fr); gap:10px; margin-top:12px; }
.palette-item { padding: 12px; border-radius: 8px; text-align: center; background: #f6fbff; cursor: pointer; font-weight: 700; color: var(--primary); box-shadow: inset 0 -2px 0 rgba(11,99,183,0.02); font-size: 14px; }

@media (max-width: 480px) {
  .palette-item { padding: 10px; font-size: 12px; }
}
.palette-item.done { background:var(--primary); color:white; box-shadow:none; }
.palette-item.active { outline: 2px solid rgba(11,99,183,0.12); transform: translateY(-3px); }

/* Progress */
.progress-track { height:10px; background:#eef7ff; border-radius:999px; overflow:hidden; }
.progress-fill { height:100%; width:0%; background:linear-gradient(90deg,var(--primary),var(--accent)); transition:width .28s ease; }

/* Review */
.review-grid { display:flex; flex-direction:column; gap:12px; }
.review-card { background:var(--card); border-radius:12px; padding:14px; display:flex; gap:12px; align-items:center; border:1px solid #f0f6ff; }

/* Datatable and page-specific responsive */
@media (max-width: 920px) { 
  .palette-grid { grid-template-columns: repeat(6, 1fr); }
}

@media (max-width: 768px) {
  .brand-text h1 { font-size: 20px; }
  .brand-text p { font-size: 11px; }
}

@media (max-width: 480px) { 
  .brand-text h1 { font-size: 18px; }
  .brand-text p { font-size: 10px; }
  .logo { width: 64px; }
  .palette-grid { grid-template-columns: repeat(4, 1fr); }
}

/* Misc small niceties */
.secure-badge { font-size:12px; color:var(--muted); display:inline-flex; gap:8px; align-items:center; justify-content:center; font-weight:700; }

/* keep some legacy names working */
.timer { font-weight:700; color:#c53030; }

/* End of consolidated styles */
.secondary-btn {
  background: #e2e8f0;
  border: none;
  padding: 10px 18px;
  border-radius: 6px;
  cursor: pointer;
}

.submit-btn {
  margin-left: auto;
  background: #16a34a;
  color: white;
  padding: 10px 18px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

/* ===== SIDE PANEL ===== */
.question-palette {
  flex: 1;
  background: white;
  padding: 20px;
  border-radius: 10px;
  height: fit-content;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

#sidePanel {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 15px;
}

.palette-btn {
  padding: 8px;
  border-radius: 5px;
  text-align: center;
  font-size: 13px;
  cursor: pointer;
  background: #e2e8f0;
}

.palette-btn.attempted {
  background: #16a34a;
  color: white;
}

.palette-btn.current {
  background: #2563eb;
  color: white;
}

/* ===== LEGEND ===== */
.legend p {
  font-size: 13px;
  margin: 5px 0;
}

.box {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 3px;
  margin-right: 6px;
}

.box.attempted { background: #16a34a; }
.box.not-attempted { background: #e2e8f0; }
.box.current { background: #2563eb; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .quiz-layout {
    flex-direction: column;
  }
}
:root {
  --primary-blue: #0b4e99;
  --light-blue: #1e73be;
  --bg-gradient: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  --card-bg: rgba(255, 255, 255, 0.95);
  --text-dark: #2c3e50;
  --text-gray: #7f8c8d;
  --border-radius: 12px;
  --shadow: 0 10px 25px rgba(11, 78, 153, 0.1);
}

* {
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
}

body.login-body {
  margin: 0;
  padding: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-gradient);
}

/* .login-wrapper correct styles are defined earlier — broken duplicate removed */

.login-card {
  background: var(--card-bg);
  padding: 40px;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.3);
  text-align: center;
}

/* Brand Styling */
.brand-container {
  margin-bottom: 30px;
}

.logo {
  width: 100px;
  height: auto;
  margin-bottom: 15px;
}

.brand-text h1 {
  margin: 0;
  color: var(--primary-blue);
  font-size: 28px;
  letter-spacing: -0.5px;
}

.brand-text p {
  margin: 5px 0 0;
  color: var(--text-gray);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Form Styling */
.form-group {
  text-align: left;
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 6px;
  margin-left: 4px;
}

input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #dcdde1;
  border-radius: 8px;
  font-size: 15px;
  transition: all 0.3s ease;
  background: #fcfcfc;
}

input:focus {
  outline: none;
  border-color: var(--light-blue);
  box-shadow: 0 0 0 4px rgba(30, 115, 190, 0.1);
}

/* Buttons */
.action-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 25px;
}

button {
  width: 100%;
  padding: 14px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, background 0.3s;
  border: none;
}

.primary-btn {
  background: var(--primary-blue);
  color: white;
}

.primary-btn:hover {
  background: #083d7a;
  transform: translateY(-1px);
}

.secondary-btn {
  background: transparent;
  color: var(--primary-blue);
  border: 1px solid var(--primary-blue);
}

.secondary-btn:hover {
  background: rgba(11, 78, 153, 0.05);
}

/* Footer Section */
.divider {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.secure-badge {
  font-size: 11px;
  color: #95a5a6;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-transform: uppercase;
  font-weight: 700;
}
:root {
  --med-blue: #0b4e99;
  --med-light: #eef4fb;
  --med-accent: #1e73be;
  --success: #27ae60;
  --text-main: #1a2a3a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --white: #ffffff;
}

* { box-sizing: border-box; font-family: 'Inter', sans-serif; }

body.assessment-body {
  margin: 0;
  background-color: #f8fafc;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  height: 100vh;
}

/* Header Styling */
.medminds-header {
  background: var(--white);
  border-bottom: 2px solid var(--med-light);
  padding: 12px 40px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
}

.brand-block { display: flex; align-items: center; gap: 15px; }
.nav-logo { height: 50px; width: auto; }
.brand-text h1 { font-size: 20px; margin: 0; color: var(--med-blue); }
.brand-text p { font-size: 12px; margin: 0; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }

.badge {
  background: var(--med-light);
  color: var(--med-accent);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 4px;
  vertical-align: middle;
}

.timer-card {
  background: #fff5f5;
  border: 1px solid #feb2b2;
  padding: 8px 20px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.timer-digits { font-family: monospace; font-weight: 700; font-size: 1.2rem; color: #c53030; }

/* Layout */
.assessment-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 25px;
  padding: 25px 40px;
  max-width: 1400px;
  margin: 0 auto;
  flex: 1;
}

/* Main Content Area */
.status-strip { margin-bottom: 20px; }
.progress-info { margin-bottom: 8px; }
.q-count { font-weight: 700; color: var(--med-blue); font-size: 18px; }
.q-total { color: var(--text-muted); font-size: 14px; }

.progress-track {
  height: 6px;
  background: var(--border-color);
  border-radius: 10px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--med-blue);
  transition: width 0.4s ease;
}

.question-module {
  background: var(--white);
  padding: 40px;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
  min-height: 400px;
}

.question-text h2 {
  font-size: 22px;
  line-height: 1.5;
  margin-top: 0;
  font-weight: 500;
}

/* Options */
.options-grid {
  display: grid;
  gap: 12px;
  margin-top: 30px;
}

.option-item {
  padding: 16px 20px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.option-item:hover {
  background: var(--med-light);
  border-color: var(--med-accent);
}

.option-item.selected {
  background: var(--med-blue);
  color: white;
  border-color: var(--med-blue);
}

/* Buttons */
.control-bar {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
}

button {
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: opacity 0.2s;
}

.btn-primary { background: var(--med-blue); color: white; }
.btn-outline { background: var(--white); border: 2px solid var(--med-blue); color: var(--med-blue); }
.btn-finish { background: var(--success); color: white; }

/* Palette */
.sidebar {
  background: var(--white);
  padding: 24px;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  height: fit-content;
}

.palette-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin: 20px 0;
}

.palette-item {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  background: var(--med-light);
  border: 1px solid var(--border-color);
  cursor: pointer;
}

.palette-item.active { border: 2px solid var(--med-blue); background: var(--white); color: var(--med-blue); }
.palette-item.done { background: var(--med-blue); color: white; border: none; }

.legend-box { margin-top: 25px; border-top: 1px solid var(--border-color); pt: 20px; }
.legend-item { font-size: 12px; display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: var(--text-muted); }
.dot { width: 10px; height: 10px; border-radius: 50%; }
.status-done { background: var(--med-blue); }
.status-skip { background: #f59e0b; }
.status-empty { background: var(--med-light); }
/* --- ADVANCED UI ADDITIONS --- */
  height: 100%;
  background: var(--white);
  box-shadow: -5px 0 15px rgba(0,0,0,0.1);
  z-index: 1000;
  transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.sidebar-drawer.active {
  right: 0;
}

.drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(11, 78, 153, 0.4);
  backdrop-filter: blur(4px);
  display: none;
  z-index: 999;
}

.drawer-overlay.active {
  display: block;
}

/* Glassmorphism Question Card */
.question-module {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 24px;
  padding: 30px;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
  .assessment-layout {
    grid-template-columns: 1fr; /* Hide sidebar from grid */
    padding: 15px;
  }

  .medminds-header {
    padding: 10px 15px;
  }

  .nav-logo { height: 40px; }
  
  .brand-text h1 { font-size: 16px; }
  .brand-text p { display: none; } /* Hide tagline on small screens */

  .control-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    padding: 15px;
    box-shadow: 0 -5px 15px rgba(0,0,0,0.05);
    margin-top: 0;
    z-index: 900;
    display: flex;
    justify-content: space-around;
  }
  
  .assessment-main {
    margin-bottom: 80px; /* Space for fixed bottom bar */
  }

  .question-module {
    padding: 20px;
    border-radius: 16px;
  }
}
/* Review Page Specifics */
.review-body {
  background-color: #f0f4f8;
}

.review-layout {
  max-width: 1000px;
  margin: 0 auto;
  padding: 40px 20px;
}

.summary-ribbon {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  padding: 20px;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
  border-bottom: 4px solid var(--med-blue);
}

.stat-label { font-size: 12px; color: var(--text-muted); text-transform: uppercase; font-weight: 700; }
.stat-value { display: block; font-size: 24px; font-weight: 800; color: var(--med-blue); }

/* Review Cards */
.review-grid {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.review-card {
  background: white;
  padding: 20px;
  border-radius: 12px;
  display: grid;
  grid-template-columns: 60px 1fr auto;
  align-items: center;
  border: 1px solid var(--border-color);
  transition: transform 0.2s;
}

.review-card:hover {
  transform: scale(1.01);
  border-color: var(--med-accent);
}

.q-num-circle {
  width: 40px;
  height: 40px;
  background: var(--med-light);
  color: var(--med-blue);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.q-preview-text {
  font-weight: 500;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding-right: 20px;
}

.user-answer-badge {
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
}

.status-filled { background: #e6fffa; color: #2c7a7b; border: 1px solid #b2f5ea; }
.status-empty { background: #fff5f5; color: #c53030; border: 1px solid #feb2b2; }

.shadow-pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(11, 78, 153, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(11, 78, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(11, 78, 153, 0); }
}

@media (max-width: 600px) {
  .review-card {
    grid-template-columns: 1fr auto;
    gap: 10px;
  }
  .q-num-circle { display: none; }
  .summary-ribbon { grid-template-columns: 1fr; }
}

/* Animations and motion system */
.fade-in { animation: fadeInUp .44s cubic-bezier(.2,.9,.3,1) both; }
.stagger > * { opacity: 0; transform: translateY(6px); animation: fadeInUp .44s cubic-bezier(.2,.9,.3,1) both; }
.stagger > *:nth-child(1) { animation-delay: 0s; }
.stagger > *:nth-child(2) { animation-delay: 0.06s; }
.stagger > *:nth-child(3) { animation-delay: 0.12s; }
.stagger > *:nth-child(4) { animation-delay: 0.18s; }
.stagger > *:nth-child(5) { animation-delay: 0.24s; }

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* subtle micro-interactions */
.palette-item { transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
.palette-item:hover { transform: translateY(-4px); box-shadow: 0 8px 20px rgba(11,99,183,0.06); }
.review-card { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.btn-primary { transition: transform .12s ease, box-shadow .12s ease; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(11,99,183,0.12); }

/* ===== PREMIUM MEDICAL CAT QUIZ DESIGN ===== */
.quiz-body {
  background: linear-gradient(180deg, #f7fbff 0%, #eef4fb 100%);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Premium Quiz Header */
.quiz-header-premium {
  background: linear-gradient(135deg, #0b63b7 0%, #2b8ef7 100%);
  color: white;
  padding: 24px 32px;
  box-shadow: 0 10px 30px rgba(11, 99, 183, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-premium-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 240px 1fr 220px;
  gap: 32px;
  align-items: center;
}

.header-left {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.app-title {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.app-subtitle {
  margin: 0;
  font-size: 13px;
  opacity: 0.85;
  font-weight: 500;
}

.header-center {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.progress-bar-wrapper {
  width: 100%;
  max-width: 400px;
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  overflow: hidden;
  margin: 0 auto;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #ffd700, #ffed4e);
  border-radius: 999px;
  transition: width 0.3s cubic-bezier(0.2, 0.9, 0.3, 1);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
}

.progress-text {
  font-size: 13px;
  font-weight: 600;
  opacity: 0.9;
}

.header-right {
  display: flex;
  justify-content: flex-end;
}

.timer-widget {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.15);
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

.timer-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.timer-display {
  font-size: 16px;
  font-weight: 700;
  min-width: 60px;
}

/* Main Quiz Container */
.quiz-main-container {
  flex: 1;
  display: flex;
  justify-content: center;
  padding: 20px 0;
  overflow-x: hidden;
  overflow-y: auto;
}

.quiz-content-wrapper {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  padding: 0 16px;
  max-width: 100%;
}

@media (max-width: 1024px) {
  .quiz-content-wrapper {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0 12px;
  }
}

@media (max-width: 768px) {
  .quiz-content-wrapper {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 0 12px;
  }
}

@media (max-width: 480px) {
  .quiz-content-wrapper {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 0 8px;
  }
  .quiz-sidebar {
    display: none;
  }
}

/* Question Section - Left Column */
.quiz-question-section {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.question-badge-wrapper {
  display: flex;
  align-items: center;
  gap: 14px;
}

.question-badge {
  display: inline-block;
  background: var(--primary);
  color: white;
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 16px;
  min-width: 60px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.15);
}

.question-counter {
  font-size: 14px;
  color: var(--muted);
  font-weight: 600;
}

.question-display-area {
  background: white;
  padding: 28px;
  border-radius: 14px;
  box-shadow: var(--shadow-1);
  border-left: 4px solid var(--primary);
}

.question-text {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.6;
  color: #0f1724;
}

/* Options Section */
.options-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.options-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.option-item {
  background: white;
  border: 1px solid #e8eef7;
  border-radius: 12px;
  padding: 14px 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: all 0.14s ease;
  box-shadow: 0 2px 8px rgba(2, 6, 23, 0.02);
}

.option-item:hover {
  background: #f7fbff;
  border-color: rgba(43, 142, 247, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.08);
}

.option-item.selected {
  background: linear-gradient(135deg, #e3f2ff 0%, #f0f8ff 100%);
  border-color: var(--primary);
  box-shadow: 0 8px 24px rgba(11, 99, 183, 0.12);
}

.option-item input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--primary);
  cursor: pointer;
}

.opt-text {
  flex: 1;
  font-size: 15px;
  line-height: 1.4;
  color: #0f1724;
  font-weight: 500;
}

/* Action Bar */
.quiz-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
}

.nav-button-group {
  display: flex;
  gap: 12px;
}

.btn-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: white;
  border: 1px solid #e8eef7;
  border-radius: 10px;
  padding: 10px 18px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  transition: all 0.12s ease;
  min-width: 110px;
}

.btn-nav:hover {
  background: #f7fbff;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.08);
}

.btn-nav:active {
  transform: translateY(0);
}

.btn-icon {
  font-size: 16px;
  display: inline-flex;
}

.btn-submit {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px 24px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  transition: all 0.12s ease;
  box-shadow: 0 6px 20px rgba(11, 99, 183, 0.15);
  margin-left: auto;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(11, 99, 183, 0.2);
}

.btn-submit:active {
  transform: translateY(0);
}

/* Explanation Section */
.explanation-section {
  background: white;
  border-radius: 12px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(2, 6, 23, 0.02);
  border: 1px solid #e8eef7;
  border-left: 4px solid var(--success);
}

.explanation-header {
  margin: 0 0 10px 0;
}

.explanation-header h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--success);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.explanation-content {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: #374151;
}

/* Sidebar - Right Column */
.quiz-sidebar {
  display: flex;
  flex-direction: column;
  gap: 18px;
  height: fit-content;
  position: sticky;
  top: 130px;
}

.sidebar-header {
  background: white;
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: var(--shadow-2);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sidebar-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #0f1724;
}

.sidebar-counter {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
}

.question-palette {
  background: white;
  border-radius: 12px;
  padding: 16px;
  box-shadow: var(--shadow-2);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  width: 100%;
}

.question-palette > div {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  background: #eef6ff;
  color: var(--primary);
  border: 2px solid transparent;
  transition: all 0.12s ease;
  user-select: none;
}

.question-palette > div:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.2);
}

.question-palette > div.done {
  background: var(--primary);
  color: white;
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.15);
}

.question-palette > div.active {
  background: var(--success);
  color: white;
  border-color: var(--success);
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.15);
  transform: scale(1.12);
}

.sidebar-legend {
  background: white;
  border-radius: 12px;
  padding: 14px;
  box-shadow: var(--shadow-2);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 600;
  color: #6b7280;
}

.legend-indicator {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  flex-shrink: 0;
}

.legend-attempted {
  background: var(--primary);
}

.legend-current {
  background: var(--success);
}

.legend-unanswered {
  background: #eef6ff;
  border: 1px solid #d1e0f1;
}

.legend-label {
  flex: 1;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .header-premium-inner {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .header-left,
  .header-right {
    text-align: center;
  }

  .quiz-content-wrapper {
    grid-template-columns: 1fr;
  }

  .quiz-sidebar {
    position: relative;
    top: auto;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    grid-template-rows: auto;
  }

  .sidebar-header {
    grid-column: 1 / -1;
  }

  .question-palette {
    grid-column: 1 / -1;
  }

  .sidebar-legend {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

  .legend-item {
    flex-direction: column;
    text-align: center;
    gap: 8px;
  }
}

@media (max-width: 768px) {
  .quiz-body {
    padding: 0;
  }

  .quiz-header-premium {
    padding: 16px;
  }

  .header-premium-inner {
    gap: 12px;
  }

  .app-title {
    font-size: 18px;
  }

  .quiz-main-container {
    padding: 16px 12px;
  }

  .question-display-area {
    padding: 16px;
  }

  .question-text {
    font-size: 16px;
  }

  .question-badge-wrapper {
    gap: 10px;
  }

  .quiz-action-bar {
    flex-direction: column;
  }

  .nav-button-group {
    width: 100%;
    flex-direction: column;
  }

  .btn-nav {
    width: 100%;
  }

  .btn-submit {
    width: 100%;
    margin-left: 0;
  }

  .question-palette {
    grid-template-columns: repeat(5, 1fr);
  }

  .timer-widget {
    padding: 8px 12px;
  }

  .timer-display {
    font-size: 14px;
    min-width: 50px;
  }

  .app-subtitle {
    display: none;
  }
}

/* Animations and motion system */
.fade-in { animation: fadeInUp .44s cubic-bezier(.2,.9,.3,1) both; }
.stagger > * { opacity: 0; transform: translateY(6px); animation: fadeInUp .44s cubic-bezier(.2,.9,.3,1) both; }
.stagger > *:nth-child(1) { animation-delay: 0s; }
.stagger > *:nth-child(2) { animation-delay: 0.06s; }
.stagger > *:nth-child(3) { animation-delay: 0.12s; }
.stagger > *:nth-child(4) { animation-delay: 0.18s; }
.stagger > *:nth-child(5) { animation-delay: 0.24s; }

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== ADMIN DASHBOARD STYLES ===== */
.admin-body {
  background: linear-gradient(180deg, #f7fbff 0%, #eef4fb 100%);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Admin Header */
.admin-header {
  background: linear-gradient(135deg, #0b63b7 0%, #2b8ef7 100%);
  color: white;
  padding: 20px 32px;
  box-shadow: 0 10px 30px rgba(11, 99, 183, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-header-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-brand h1 {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.admin-subtitle {
  margin: 4px 0 0 0;
  font-size: 13px;
  opacity: 0.85;
  font-weight: 500;
}

.admin-user-info {
  display: flex;
  align-items: center;
  gap: 16px;
}

.admin-email-display {
  font-size: 14px;
  opacity: 0.9;
  font-weight: 600;
}

.btn-logout {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.12s ease;
  backdrop-filter: blur(10px);
}

.btn-logout:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.btn-logout-header {
  background: rgba(255, 107, 107, 0.95);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}

.btn-logout-header:hover {
  background: rgba(255, 107, 107, 1);
  transform: translateY(-2px);
}

/* Admin Navigation Tabs */
.admin-tabs {
  background: white;
  border-bottom: 2px solid #e8eef7;
  padding-left: 32px;
  display: flex;
  gap: 2px;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

.admin-tab-btn {
  background: none;
  border: none;
  padding: 16px 20px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  border-bottom: 3px solid transparent;
  transition: all 0.12s ease;
}

.admin-tab-btn:hover {
  color: var(--primary);
  background: rgba(11, 99, 183, 0.04);
}

.admin-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* Show hamburger menu on mobile */
@media (max-width: 1024px) {
  .admin-menu-toggle {
    display: flex;
  }
  
  .admin-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }
  
  .admin-tabs::-webkit-scrollbar {
    display: none;
  }
}

@media (max-width: 768px) {
  .admin-menu-toggle {
    display: flex;
  }

  .admin-drawer {
    width: 260px;
    right: -260px;
  }
}

@media (max-width: 480px) {
  .admin-menu-toggle {
    display: flex;
    padding: 10px 12px;
  }

  .admin-tabs {
    padding-left: 0;
    justify-content: flex-start;
  }

  .admin-tab-btn {
    padding: 12px 16px;
    font-size: 12px;
    white-space: nowrap;
  }

  .admin-drawer {
    width: 100%;
    right: -100%;
  }
}
.admin-main {
  flex: 1;
  width: 100%;
  padding: 24px 16px;
  overflow-x: hidden;
}

@media (max-width: 768px) {
  .admin-main {
    padding: 16px 12px;
  }
}

@media (max-width: 480px) {
  .admin-main {
    padding: 12px 8px;
  }
}

.admin-tab-content {
  display: none;
  animation: fadeInUp 0.3s ease;
}

.admin-tab-content.active {
  display: block;
}

/* Dashboard Stats */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.stat-box {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
  border-left: 4px solid var(--primary);
}

.stat-label {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 12px;
}

.stat-number {
  font-size: 32px;
  font-weight: 800;
  color: var(--primary);
}

/* Recent Attempts */
.admin-recent {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
}

.admin-recent h2 {
  margin: 0 0 20px 0;
  font-size: 18px;
  color: #0f1724;
}

.recent-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.recent-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #f7fbff;
  border-radius: 10px;
  border-left: 3px solid var(--primary);
}

.recent-content {
  flex: 1;
}

.recent-user {
  font-size: 14px;
  font-weight: 600;
  color: #0f1724;
  margin-bottom: 4px;
}

.recent-meta {
  font-size: 12px;
  color: var(--muted);
}

.recent-score {
  font-size: 15px;
  font-weight: 700;
}

/* Questions Management */
.admin-questions-section {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #e8eef7;
}

.section-header h2 {
  margin: 0;
  font-size: 18px;
  color: #0f1724;
}

/* Add Question Form */
.btn-add-question {
  background: var(--primary);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.12s ease;
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.15);
}

.btn-add-question:hover {
  background: var(--primary-600);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.2);
}

.header-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* CSV Upload Styles */
.csv-upload-section {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
  border: 2px dashed #0b63b7;
}

.csv-upload-section h3 {
  margin: 0 0 8px 0;
  color: var(--primary);
  font-size: 16px;
}

.csv-description {
  margin: 0 0 16px 0;
  font-size: 13px;
  color: #374151;
  line-height: 1.5;
}

.csv-description a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
}

.csv-description a:hover {
  text-decoration: underline;
}

.csv-upload-area {
  border: 2px dashed var(--primary);
  border-radius: 10px;
  padding: 32px;
  background: white;
  cursor: pointer;
  text-align: center;
  transition: all 0.12s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.csv-upload-area:hover {
  background: #f7fbff;
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.08);
}

.csv-upload-area svg {
  color: var(--primary);
  opacity: 0.7;
}

.upload-text {
  font-size: 14px;
  font-weight: 600;
  color: #0f1724;
}

.upload-hint {
  font-size: 12px;
  color: var(--muted);
}

/* Add Question Form */
.add-question-form {
  background: #f7fbff;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 24px;
  border: 2px solid #e3f2ff;
}

.add-question-form h3 {
  margin: 0 0 16px 0;
  color: var(--primary);
  font-size: 16px;
}

.form-group {
  margin-bottom: 16px;
}


.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #0f1724;
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #e8eef7;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  transition: all 0.12s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(11, 99, 183, 0.1);
  background: white;
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 16px;
}

.btn-cancel,
.btn-save {
  padding: 10px 18px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.12s ease;
}

.btn-cancel {
  background: #e8eef7;
  color: var(--primary);
}

.btn-cancel:hover {
  background: #d1e0f1;
}

.btn-save {
  background: var(--success);
  color: white;
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.15);
}

.btn-save:hover {
  background: #15803d;
  transform: translateY(-2px);
}

/* Questions List */
.questions-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.question-card {
  background: white;
  border: 1px solid #e8eef7;
  border-radius: 12px;
  padding: 16px;
  transition: all 0.12s ease;
  border-left: 4px solid var(--primary);
}

.question-card:hover {
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.08);
}

.question-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.question-number {
  background: var(--primary);
  color: white;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}

.question-id {
  font-size: 12px;
  color: var(--muted);
}

.question-text {
  font-size: 15px;
  font-weight: 600;
  color: #0f1724;
  margin-bottom: 12px;
  line-height: 1.5;
}

.question-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
  background: #f7fbff;
  padding: 12px;
  border-radius: 8px;
}

.option {
  font-size: 13px;
  color: #374151;
  line-height: 1.4;
}

.question-answer {
  font-size: 13px;
  color: var(--success);
  font-weight: 600;
  margin-bottom: 8px;
}

.question-explanation {
  font-size: 13px;
  color: var(--muted);
  background: rgba(11, 99, 183, 0.04);
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 12px;
  border-left: 3px solid var(--primary);
}

.question-actions {
  display: flex;
  gap: 10px;
}

.btn-edit,
.btn-delete {
  flex: 1;
  padding: 8px 12px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  transition: all 0.12s ease;
}

.btn-edit {
  background: #e3f2ff;
  color: var(--primary);
}

.btn-edit:hover {
  background: #bbdefb;
}

.btn-delete {
  background: #fee2e2;
  color: #dc2626;
}

.btn-delete:hover {
  background: #fecaca;
}

/* Attempts Table */
.admin-attempts-section {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
}

.admin-attempts-section h2 {
  margin: 0 0 20px 0;
  font-size: 18px;
  color: #0f1724;
}

.attempts-table {
  width: 100%;
  overflow-x: auto;
}

.attempts-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.attempts-data-table thead {
  background: #f7fbff;
  border-bottom: 2px solid #e8eef7;
}

.attempts-data-table th {
  padding: 12px;
  text-align: left;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.5px;
}

.attempts-data-table td {
  padding: 12px;
  border-bottom: 1px solid #e8eef7;
  color: #374151;
}

.attempts-data-table tbody tr:hover {
  background: #f7fbff;
}

/* Publish Status Buttons */
.publish-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-published {
  background: #d1fae5;
  color: #065f46;
}

.btn-published:hover {
  background: #a7f3d0;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.btn-not-published {
  background: #fee2e2;
  color: #991b1b;
}

.btn-not-published:hover {
  background: #fca5a5;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
}

/* Users Management */
.admin-users-section {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
}

.admin-users-section h2 {
  margin: 0 0 20px 0;
  font-size: 18px;
  color: #0f1724;
}

.btn-add-user {
  background: var(--primary);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.12s ease;
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.15);
}

.btn-add-user:hover {
  background: var(--primary-600);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.2);
}

.add-user-form {
  background: #f7fbff;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 24px;
  border: 2px solid #e3f2ff;
}

.add-user-form h3 {
  margin: 0 0 16px 0;
  color: var(--primary);
  font-size: 16px;
}

.users-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.user-card {
  background: white;
  border: 1px solid #e8eef7;
  border-radius: 12px;
  padding: 16px;
  transition: all 0.12s ease;
  border-left: 4px solid var(--primary);
}

.user-card:hover {
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.08);
}

.user-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e8eef7;
}

.user-info {
  flex: 1;
}

.user-name {
  font-size: 15px;
  font-weight: 700;
  color: #0f1724;
  margin-bottom: 4px;
}

.user-email {
  font-size: 13px;
  color: var(--primary);
  font-weight: 500;
}

.user-id {
  font-size: 12px;
  color: var(--muted);
  text-align: right;
}

.user-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.detail-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.detail-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.detail-value {
  font-size: 13px;
  color: #374151;
  font-weight: 500;
}

.user-actions {
  display: flex;
  gap: 10px;
}

.user-actions .btn-delete {
  flex: 1;
  padding: 8px 12px;
  background: #fee2e2;
  color: #dc2626;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  transition: all 0.12s ease;
}

.user-actions .btn-delete:hover {
  background: #fecaca;
  transform: translateY(-2px);
}

/* No Data Message */
.no-data {
  text-align: center;
  padding: 24px;
  color: var(--muted);
  font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
  .admin-header-inner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .admin-tabs {
    padding-left: 0;
    overflow-x: auto;
  }

  .admin-main {
    padding: 16px;
  }

  .admin-stats {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .question-options {
    grid-template-columns: 1fr;
  }

  section {
    margin-bottom: 20px;
  }
}

/* ===== RESULT PAGE STYLES ===== */
.result-body {
  background: linear-gradient(180deg, #f7fbff 0%, #eef4fb 100%);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.result-layout {
  flex: 1;
  width: 100%;
  padding: 24px 16px;
  overflow-x: hidden;
}

@media (max-width: 768px) {
  .result-layout {
    padding: 16px 12px;
  }
}

@media (max-width: 480px) {
  .result-layout {
    padding: 12px 8px;
  }
}

/* Score Card */
.result-score-card {
  background: white;
  border-radius: 14px;
  padding: 40px;
  box-shadow: var(--shadow-1);
  margin-bottom: 32px;
  text-align: center;
  border-top: 4px solid var(--primary);
}

.result-score-card h2 {
  margin: 0 0 24px 0;
  font-size: 20px;
  color: #0f1724;
}

.score-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.score-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.score-percentage {
  font-size: 64px;
  font-weight: 900;
  line-height: 1;
  color: var(--primary);
}

.score-details {
  font-size: 18px;
  font-weight: 600;
  color: #374151;
}

.score-message {
  font-size: 15px;
  color: var(--muted);
  font-weight: 600;
}

/* Answer Key Section */
.answer-key-section {
  margin-bottom: 32px;
}

.answer-key-section h2 {
  font-size: 20px;
  font-weight: 700;
  color: #0f1724;
  margin: 0 0 20px 0;
}

.answer-key-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.answer-key-card {
  background: white;
  border-radius: 12px;
  padding: 20px;
  box-shadow: var(--shadow-2);
  border-left: 4px solid var(--primary);
  transition: all 0.12s ease;
}

.answer-key-card:hover {
  box-shadow: 0 8px 24px rgba(11, 99, 183, 0.12);
}

.key-question-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e8eef7;
}

.key-number {
  background: var(--primary);
  color: white;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}

.key-status {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 16px;
  font-weight: 700;
}

.key-status.key-correct {
  background: #d1fae5;
  color: var(--success);
  border: 2px solid var(--success);
}

.key-status.key-incorrect {
  background: #fee2e2;
  color: #dc2626;
  border: 2px solid #dc2626;
}

.key-status.key-unanswered {
  background: #f3f4f6;
  color: var(--muted);
  border: 2px solid #d1d5db;
}

.key-question-text {
  font-size: 15px;
  font-weight: 600;
  color: #0f1724;
  line-height: 1.6;
  margin-bottom: 16px;
}

.key-answers-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
  background: #f7fbff;
  padding: 12px;
  border-radius: 8px;
}

.key-answer-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.key-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  min-width: 120px;
}

.key-value {
  font-size: 14px;
  font-weight: 600;
  color: #0f1724;
  flex: 1;
}

.user-answer .key-label {
  color: #0b63b7;
}

.correct-answer .key-label {
  color: var(--success);
}

.key-explanation {
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.08) 0%, rgba(22, 163, 74, 0.04) 100%);
  border-left: 3px solid var(--success);
  padding: 12px;
  border-radius: 8px;
}

.explanation-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--success);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 6px;
}

.explanation-text {
  font-size: 13px;
  color: #374151;
  line-height: 1.6;
}

/* Result Actions */
.result-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid #e8eef7;
}

.result-actions .btn {
  min-width: 160px;
}

/* Responsive */
@media (max-width: 768px) {
  .result-layout {
    padding: 16px;
  }

  .result-score-card {
    padding: 24px;
  }

  .score-percentage {
    font-size: 48px;
  }

  .answer-key-card {
    padding: 16px;
  }

  .key-answers-section {
    flex-direction: column;
  }

  .result-actions {
    flex-direction: column;
  }

  .result-actions .btn {
    width: 100%;
    min-width: unset;
  }
}

/* ===== LEADERBOARD PAGE STYLES ===== */
.leaderboard-body {
  background: linear-gradient(180deg, #f7fbff 0%, #eef4fb 100%);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.leaderboard-layout {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px;
  width: 100%;
}

/* Leadership Stats */
.leadership-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.stat-card {
  background: white;
  border-radius: 14px;
  padding: 20px;
  box-shadow: var(--shadow-2);
  border-top: 4px solid var(--primary);
  display: flex;
  align-items: center;
  gap: 16px;
}

.stat-icon {
  font-size: 32px;
  flex-shrink: 0;
}

.stat-info {
  flex: 1;
}

.stat-label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 6px;
}

.stat-number {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary);
}

/* Leaderboard Section */
.leaderboard-section {
  background: white;
  border-radius: 14px;
  padding: 24px;
  box-shadow: var(--shadow-2);
  margin-bottom: 24px;
}

.section-title {
  text-align: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #e8eef7;
}

.section-title h2 {
  margin: 0;
  font-size: 22px;
  color: #0f1724;
}

.section-subtitle {
  margin: 8px 0 0 0;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}

.leaderboard-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.leaderboard-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.leaderboard-data-table thead {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  border-bottom: 2px solid #0b63b7;
}

.leaderboard-data-table th {
  padding: 16px;
  text-align: left;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.5px;
}

.leaderboard-data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #e8eef7;
  color: #374151;
}

.leaderboard-data-table tbody tr {
  transition: all 0.12s ease;
}

.leaderboard-data-table tbody tr:hover {
  background: #f7fbff;
  box-shadow: inset 4px 0 0 var(--primary);
}

.leaderboard-data-table tbody tr.current-user {
  background: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 100%);
  border-left: 4px solid var(--primary);
}

.leaderboard-data-table tbody tr.current-user td:first-child {
  font-weight: 700;
  color: var(--primary);
}

.rank-badge {
  display: inline-block;
  min-width: 32px;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
}

/* Leaderboard Actions */
.leaderboard-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.leaderboard-actions .btn {
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.12s ease;
  font-size: 14px;
}

.leaderboard-actions .btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  box-shadow: 0 6px 20px rgba(11, 99, 183, 0.15);
}

.leaderboard-actions .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(11, 99, 183, 0.2);
}

.leaderboard-actions .btn-ghost {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.leaderboard-actions .btn-ghost:hover {
  background: rgba(11, 99, 183, 0.05);
  transform: translateY(-2px);
}

/* No Data Message */
.no-data-message {
  text-align: center;
  padding: 40px 24px;
  color: var(--muted);
  font-size: 16px;
}

.no-data-message p {
  margin: 8px 0;
}

/* Responsive Design */
@media (max-width: 768px) {
  .leaderboard-layout {
    padding: 16px;
  }

  .leadership-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .stat-card {
    padding: 14px;
    flex-direction: column;
    text-align: center;
    gap: 8px;
  }

  .stat-icon {
    font-size: 28px;
  }

  .stat-number {
    font-size: 20px;
  }

  .leaderboard-section {
    padding: 16px;
  }

  .section-title h2 {
    font-size: 18px;
  }

  .leaderboard-data-table th,
  .leaderboard-data-table td {
    padding: 10px 8px;
    font-size: 12px;
  }

  .leaderboard-data-table th {
    font-size: 10px;
  }

  .rank-badge {
    font-size: 16px;
  }

  .leaderboard-actions {
    gap: 8px;
  }

  .leaderboard-actions .btn {
    padding: 10px 16px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .leadership-stats {
    grid-template-columns: 1fr;
  }

  .stat-card {
    flex-direction: row;
  }

  .leaderboard-data-table {
    font-size: 12px;
  }

  .leaderboard-data-table th,
  .leaderboard-data-table td {
    padding: 8px 6px;
  }

  .rank-badge {
    min-width: 24px;
  }
}

/* =============================================
   MODERN UI COMPONENTS & ENHANCED DESIGN
   ============================================ */

/* Modern Form Styling */
.form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  background: white;
  color: #1a1a1a;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #0b63b7;
  box-shadow: 0 0 0 3px rgba(11, 99, 183, 0.1);
  background: #f8fbff;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #999;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* Enhanced Button Styles */
.btn-primary {
  background: linear-gradient(135deg, #0b63b7 0%, #0a4a8f 100%);
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(11, 99, 183, 0.3);
}

.btn-secondary {
  background: #f5f5f5;
  color: #1a1a1a;
  padding: 12px 24px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: #ebebeb;
  border-color: #d0d0d0;
}

.btn-danger {
  background: #ff6b6b;
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-danger:hover {
  background: #ff5252;
  transform: translateY(-2px);
}

.btn-edit {
  background: #0b63b7;
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-edit:hover {
  background: #0a4a8f;
}

.btn-delete {
  background: #ff6b6b;
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-delete:hover {
  background: #ff5252;
}

.btn-cancel {
  background: #f5f5f5;
  color: #1a1a1a;
  padding: 12px 24px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-cancel:hover {
  background: #ebebeb;
}

.btn-save {
  background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-save:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.2);
}

/* Card Components */
.card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  border: 1px solid #f0f0f0;
  transition: all 0.3s ease;
}

.card:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.card-header {
  padding: 20px;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-title {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0;
}

.card-body {
  padding: 20px;
}

/* Section Headers */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #f0f0f0;
}

.section-title {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0;
}

.btn-add-user {
  background: linear-gradient(135deg, #0b63b7 0%, #0a4a8f 100%);
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-add-user:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(11, 99, 183, 0.2);
}

/* Question Card */
.question-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
  border-left: 4px solid #0b63b7;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.question-card:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.question-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f0f0f0;
}

.question-number {
  font-weight: 700;
  color: #0b63b7;
  font-size: 14px;
}

.question-id {
  font-size: 12px;
  color: #999;
}

.question-text {
  font-size: 16px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 12px 0;
}

.question-options {
  margin: 16px 0;
  padding: 12px;
  background: #f8fbff;
  border-radius: 8px;
}

.option {
  padding: 8px 0;
  font-size: 14px;
  color: #333;
  border-bottom: 1px solid #e8eef7;
}

.option:last-child {
  border-bottom: none;
}

.question-answer {
  font-size: 13px;
  color: #16a34a;
  font-weight: 600;
  margin: 12px 0;
  padding: 10px 12px;
  background: #f0fdf4;
  border-radius: 6px;
}

.question-explanation {
  font-size: 13px;
  color: #555;
  margin: 12px 0;
  padding: 10px 12px;
  background: #fef3c7;
  border-left: 3px solid #f59e0b;
  border-radius: 6px;
}

.question-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #f0f0f0;
}

/* Modal/Dialog */
.add-user-form {
  background: white;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border: 2px solid #e8eef7;
}

.add-user-form h3 {
  color: #0b63b7;
  margin: 0 0 20px 0;
  font-size: 18px;
}

.add-user-form form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* List & Table Styling */
.admin-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 20px;
}

.list-item {
  background: white;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #f0f0f0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.list-item:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

/* Table Styling */
.attempts-data-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.attempts-data-table thead {
  background: linear-gradient(135deg, #0b63b7 0%, #0a4a8f 100%);
  color: white;
}

.attempts-data-table th {
  padding: 16px;
  text-align: left;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: none;
}

.attempts-data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #f0f0f0;
  font-size: 14px;
  color: #1a1a1a;
}

.attempts-data-table tbody tr:hover {
  background: #f8fbff;
}

/* Badge/Status */
.badge {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.badge-success {
  background: #d1fae5;
  color: #065f46;
}

.badge-warning {
  background: #fef3c7;
  color: #92400e;
}

.badge-danger {
  background: #fee2e2;
  color: #991b1b;
}

/* No Data State */
.no-data {
  text-align: center;
  padding: 40px 20px;
  color: #999;
  font-size: 14px;
}

.no-data-icon {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.5;
}

/* Loading State */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #f0f0f0;
  border-top-color: #0b63b7;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Alert Messages */
.alert {
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-weight: 600;
  border-left: 4px solid;
}

.alert-success {
  background: #d1fae5;
  color: #065f46;
  border-color: #10b981;
}

.alert-error {
  background: #fee2e2;
  color: #991b1b;
  border-color: #ef4444;
}

.alert-warning {
  background: #fef3c7;
  color: #92400e;
  border-color: #f59e0b;
}

/* Responsive Design */
@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
  }

  .admin-list {
    grid-template-columns: 1fr;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .btn-add-user {
    width: 100%;
  }

  .attempts-data-table {
    font-size: 12px;
  }

  .attempts-data-table th,
  .attempts-data-table td {
    padding: 10px 8px;
  }
}

/* ===== COMPREHENSIVE RESPONSIVE DESIGN ===== */

/* Tablet (768px and below) */
@media (max-width: 768px) {
  html, body { width: 100%; height: 100%; }
  body { font-size: 14px; padding: 0; margin: 0; }
  .container { width: 100%; padding: 16px; margin: 0 auto; }
  
  /* Forms and Cards */
  .form-group { margin-bottom: 14px; }
  .card { padding: 16px; border-radius: 10px; }
  .btn { padding: 10px 16px; font-size: 13px; }
  
  /* Navigation */
  .navbar { padding: 0.5rem 0.75rem; }
  
  /* Tables */
  table { font-size: 12px; width: 100%; }
  table th, table td { padding: 8px; }
  
  /* Grids */
  .grid { grid-template-columns: 1fr !important; }
  [class*="grid-"] { grid-template-columns: 1fr !important; }
  
  /* Quiz Layout */
  .assessment-layout { grid-template-columns: 1fr; }
  .sidebar { margin-top: 20px; }
  .palette-grid { grid-template-columns: repeat(4, 1fr); gap: 8px; }
  .palette-item { padding: 8px; font-size: 11px; }
  
  /* Sections */
  .section-header { font-size: 16px; padding: 12px; }
  .section-title { font-size: 14px; }
  
  /* Admin Sections */
  .users-section, .questions-section, .quizzes-section { padding: 16px; }
}

/* Mobile (480px and below) */
@media (max-width: 480px) {
  html, body { width: 100%; height: 100%; overflow-x: hidden; }
  body { font-size: 13px; padding: 0; margin: 0; }
  .container { width: 100%; padding: 12px; margin: 0 auto; }
  
  /* Full Width Elements */
  .card, .form-group, .section-header { width: 100%; }
  
  /* Text Sizing */
  h1 { font-size: 20px; }
  h2 { font-size: 17px; }
  h3 { font-size: 15px; }
  
  /* Forms */
  input, textarea, select, .form-control { width: 100%; padding: 10px 12px; font-size: 13px; }
  .form-group { margin-bottom: 12px; }
  .form-group label { font-size: 12px; margin-bottom: 6px; }
  
  /* Buttons */
  .btn, button { width: 100%; padding: 12px 16px; font-size: 13px; margin: 6px 0; }
  .btn-primary, .btn-secondary, .btn-danger { width: 100%; }
  
  /* Flex Layouts */
  .action-buttons { flex-direction: column; gap: 8px; }
  .flex-row { flex-direction: column; }
  
  /* Navigation */
  .navbar { flex-direction: column; padding: 0; }
  .navbar-nav { width: 100%; flex-direction: column; }
  .nav-item { width: 100%; padding: 8px; }
  
  /* Tables - Make Scrollable */
  .table-container { overflow-x: auto; width: 100%; }
  table { font-size: 11px; width: 100%; }
  table th, table td { padding: 6px; font-size: 11px; }
  
  /* Grid to Stack */
  .grid, .grid-*, [class*="grid-"], [class*="col-"] { 
    grid-template-columns: 1fr !important;
    flex-direction: column !important;
    width: 100% !important;
  }
  
  /* Cards and Sections */
  .card { margin: 0 0 12px 0; padding: 12px; }
  .card-header { padding: 10px; font-size: 13px; }
  .card-title { font-size: 14px; }
  .card-body { padding: 10px; }
  
  /* Section Headers */
  .section-header { padding: 10px; margin-bottom: 12px; }
  .section-title { font-size: 13px; }
  
  /* Admin Panels */
  .users-section, .questions-section, .quizzes-section, .attempts-section { 
    padding: 12px; 
    margin-bottom: 12px;
  }
  
  /* Forms and Inputs */
  .question-card { flex-direction: column; width: 100%; }
  .form-container { padding: 12px; }
  
  /* Tabs */
  .tabs { gap: 0; border-bottom: 1px solid var(--border-color); overflow-x: auto; }
  .tab-btn { padding: 10px; font-size: 12px; flex: 1; text-align: center; }
  
  /* Login/Auth Pages */
  .login-card { padding: 20px; max-width: 100%; }
  .brand-container { flex-direction: column; text-align: center; }
  .logo { width: 56px; }
  .brand-text h1 { font-size: 18px; }
  .brand-text p { font-size: 10px; }
  
  /* Modals */
  .modal-content { width: 95%; max-width: 100%; margin: 10% auto; padding: 16px; }
  
  /* Lists */
  .list-item { padding: 10px; margin-bottom: 8px; }
  .palette-grid { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .palette-item { padding: 6px; font-size: 10px; }
  
  /* Margins and Padding */
  .gap-1 { gap: 4px !important; }
  .gap-2 { gap: 8px !important; }
  .gap-3 { gap: 12px !important; }
  
  /* Responsive Display */
  .hide-mobile { display: none !important; }
}

/* Extra Small (Below 360px) */
@media (max-width: 360px) {
  body { font-size: 12px; }
  h1 { font-size: 18px; }
  h2 { font-size: 15px; }
  .btn { padding: 10px 12px; }
  table th, table td { padding: 4px; font-size: 10px; }
}

/* Landscape Mode (Mobile) */
@media (max-height: 500px) and (orientation: landscape) {
  body { padding: 10px; }
  .login-card { max-height: 90vh; overflow-y: auto; padding: 20px; }
  .form-group { margin-bottom: 8px; }
  .btn { padding: 8px 12px; }
}

/* ============================================================
   CONTENT PROTECTION
   ============================================================ */

/* Block printing entirely */
@media print {
  body, html {
    display: none !important;
    visibility: hidden !important;
  }
}

/* Disable text selection site-wide */
* {
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
  user-select: none !important;
}

/* Re-enable selection only in form inputs */
input, textarea, [contenteditable="true"] {
  -webkit-user-select: text !important;
  -moz-user-select: text !important;
  user-select: text !important;
}

/* Disable image dragging */
img {
  -webkit-user-drag: none !important;
  user-drag: none !important;
  pointer-events: none;
}

/* Re-enable pointer events on images that need zoom/click */
.q-image-frame img,
.logo {
  pointer-events: auto !important;
}

/* Watermark always on top, can't be interacted with */
#mm-watermark {
  pointer-events: none !important;
  user-select: none !important;
}