@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url(https://fonts.gstatic.com/s/inter/v20/UcC73FwrK3iLTeHuS_nVMrMxCp50SjIa2JL7SUc.woff2) format('woff2');
    unicode-range: U +0460 -052F, U +1C80 -1C8A, U +20B4, U +2DE0 -2DFF, U + A640-A69F, U + FE2E-FE2F;
}

:root {
    --bg-color: #eceff4;
    --text-primary: #2e3440;
    --text-secondary: #4c566a;
    --accent-color: #5e81ac;
    --error-color: #bf616a;
    --success-color: #a3be8c;
    --card-bg: #fff;
    --border-color: #d8dee9;
    --font-main: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --transition-speed: .3s;
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-primary);
    transition: background-color var(--transition-speed), color var(--transition-speed);
    line-height: 1.5;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

/* Helper Classes */
button {
  border: none;
  font-family: inherit;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.typing-test-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: var(--bg-color);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  padding: 0;
}

.typing-test-container {
  background: var(--bg-color);
  border: none;
  width: 100%;
  height: 100%;
  border-radius: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Times New Roman', Times, serif;
}

.test-header {
  padding: 0.4rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #5e81ac;
  color: #ffffff;
  height: 50px;
  position: relative;
}

.header-left {
  flex: 1;
  display: flex;
  justify-content: flex-start;
  z-index: 2;
  min-width: 0;
}

.header-center {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1;
  min-width: 0;
  padding: 0 10px;
}

.header-right {
  flex: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 1.5rem;
  z-index: 2;
  min-width: 0;
}

.exam-display-badge {
  background: rgba(255, 255, 255, 0.12);
  padding: 0.2rem 0.7rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.test-metric {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}

.test-metric .label, .test-timer .label, .control-label {
  font-size: 0.6rem;
  color: rgba(255, 255, 255, 0.8);
  text-transform: uppercase;
  white-space: nowrap;
}

.test-metric .value, .test-timer .value {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
}

.test-timer {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 100px;
}

.test-timer .value {
  font-size: 1.3rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.test-timer .value.highlight {
  color: #ebcb8b;
}

.test-controls {
  display: flex;
  align-items: center;
}

.zoom-controls {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.4rem 1rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-zoom {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s;
  padding: 0;
  line-height: 1;
}

.btn-zoom:hover {
  background: #ffffff;
  color: #5e81ac;
}

.test-actions-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.user-display {
  font-size: 0.85rem;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.3rem 0.8rem;
  border-radius: 4px;
}

.btn-submit {
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
  background: #ffffff;
  color: #5e81ac;
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
}

.btn-submit:hover {
  background: #a3be8c;
  color: #ffffff;
  transform: translateY(-2px);
}

.test-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 1.5rem 2rem;
  gap: 1.5rem;
  background: var(--bg-color);
}

.text-display {
  flex: 1.5;
  padding: 1.5rem 1.5rem !important; 
  font-family: 'Times New Roman', Times, serif;
  line-height: 1.4; 
  letter-spacing: -0.2px;
  word-spacing: 0.5px;
  color: #000000;
  white-space: normal; 
  word-break: normal;
  text-align: justify !important;
  text-justify: auto !important;
  text-align-last: left;
  user-select: none;
  background: #ffffff; 
  overflow-y: auto;
  position: relative;
  border: 1px solid #5e81ac;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  display: block;
  width: 100%;
  box-sizing: border-box;
}

.typing-area {
  flex: 1;
  background: #98F059;
  display: flex;
  border: 1px solid #d08770;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  overflow: hidden;
  cursor: text;
}

.test-input {
  width: 100%;
  height: 100%;
  background: transparent;
  border: none;
  padding: 1.5rem 1.5rem !important; 
  font-family: 'Times New Roman', Times, serif;
  line-height: 1.4;
  letter-spacing: -0.2px;
  word-spacing: 0.5px;
  text-align: justify;
  color: #000000;
  resize: none;
  outline: none;
  box-sizing: border-box;
}

@media (min-width: 1401px) {
  .test-input {
    font-size: 22.1px !important;
  }
}

.text-display span {
  display: inline;
  font-family: 'Times New Roman', Times, serif;
  color: #1a1a1a;
  font-weight: 500;
  opacity: 1;
}

.char-plain {
  color: #1a1a1a !important;
}

.char-correct {
  color: #1a7f37 !important;
}

.char-incorrect {
  color: #cf222e !important;
}

.char-typed {
  color: #1a1a1a !important; 
}

.word-container {
  display: inline;
  white-space: nowrap; 
}

.char-space {
  display: inline;
  white-space: normal;
}

/* Removed char-current highlight as requested */

.word-error-red {
  color: #cf222e !important;
}

.word-error-yellow {
  color: #cf222e !important;
}

.word-success-green {
  color: #1a7f37 !important;
}

.active-word span {
  color: #5e81ac !important;
}

.active-word span.char-active-word {
  color: #5e81ac !important;
  background-color: transparent !important;
  border: none !important;
}

.active-word.has-mistake span {
  color: #cf222e !important;
}

.active-word span.word-error-red {
  color: #cf222e !important;
}

.active-word span.word-error-yellow {
  color: #cf222e !important;
}

.test-footer {
  padding: 0.3rem 1rem;
  background: #5e81ac;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  line-height: 1.2;
}

@media (max-width: 768px) {
  .test-header {
    flex-direction: column;
    height: auto;
    padding: 0.8rem;
    gap: 0.8rem;
  }

  .header-left, .header-center, .header-right {
    position: static;
    transform: none;
    flex: none;
    width: 100%;
    justify-content: center;
  }

  .header-right {
    flex-direction: column;
    gap: 0.8rem;
  }

  .test-actions-right {
    gap: 0.8rem;
    width: 100%;
    justify-content: space-around;
  }

  .test-main {
    padding: 1rem 1rem;
  }

  .text-display {
    padding: 1rem 0 !important;
  }

  .test-input {
    padding: 1rem 0 !important;
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .zoom-controls {
    padding: 0.2rem 0.5rem;
    gap: 0.4rem;
  }

  .btn-zoom {
    width: 24px;
    height: 24px;
    font-size: 0.9rem;
  }

  .test-metric .value, .test-timer .value {
    font-size: 1rem;
  }
}

/* Custom Scrollbar for Text Display inside Typing Test */
.text-display::-webkit-scrollbar {
  width: 14px;
  display: block !important;
}

.text-display::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 8px;
  border-left: 1px solid var(--border);
}

.text-display::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 8px;
  border: 3px solid #f1f5f9;
}

.text-display::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Scrollbar Buttons (Up and Down arrows) */
.text-display::-webkit-scrollbar-button:single-button {
  display: block;
  height: 14px;
  width: 14px;
  background-color: #e2e8f0;
  background-repeat: no-repeat;
  background-position: center;
  border-left: 1px solid var(--border);
}

.text-display::-webkit-scrollbar-button:single-button:vertical:decrement {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='8' height='8' fill='none' stroke='%23475569' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'><polyline points='18 15 12 9 6 15'></polyline></svg>");
  border-bottom: 1px solid var(--border);
}

.text-display::-webkit-scrollbar-button:single-button:vertical:increment {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='8' height='8' fill='none' stroke='%23475569' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>");
  border-top: 1px solid var(--border);
}
.results-page {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: var(--bg-color);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.results-header-bar {
  padding: 0.8rem 2rem;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo-small {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text-primary);
}

.logo-small span {
  color: var(--accent-color);
}

.header-actions {
  display: flex;
  gap: 1rem;
}

.results-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 3rem 2rem;
  width: 100%;
}

.performance-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 4rem;
}

.report-main-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.result-status-ring {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  border: 6px solid #eee;
  margin-bottom: 1.5rem;
  position: relative;
  background: #fff;
  box-shadow: 0 8px 20px rgba(0,0,0,0.05);
  transition: all 0.3s ease;
}

.result-status-ring.pass { 
  border-color: #2ea043; 
  background: rgba(46, 160, 67, 0.02);
  box-shadow: 0 0 15px rgba(46, 160, 67, 0.08);
}

.result-status-ring.fail { 
  border-color: #f85149; 
  background: rgba(248, 81, 73, 0.02);
  box-shadow: 0 0 15px rgba(248, 81, 73, 0.08);
}

.result-status-ring.pass .status-label { color: #2ea043; }
.result-status-ring.fail .status-label { color: #f85149; }

.status-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  font-weight: 900;
  letter-spacing: 1.5px;
  margin-bottom: 0;
}

.main-wpm {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1;
  color: var(--text-primary);
}

.main-wpm-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.hero-metrics {
  display: flex;
  gap: 4rem;
}

.hero-metric-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.h-val {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
}

.h-lab {
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.detailed-stats-section {
  background: var(--card-bg);
  padding: 1.2rem 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  margin-bottom: 2rem;
}

.detailed-stats-section h3, .comparison-section h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  font-size: 1rem;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stats-grid-detailed {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.stat-box {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.s-label {
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
}

.s-value {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-primary);
}

.s-value.error { color: #f85149; }
.s-value.warning { color: #d29922; }

.comparison-section {
  margin-bottom: 3rem;
}

.comp-legend {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.leg-item {
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.leg-item::before {
  content: '';
  width: 12px;
  height: 12px;
  border-radius: 2px;
}

.leg-item.correct::before { background: #dafbe1; border: 1px solid #2ea043; }
.leg-item.wrong::before { background: #ffebe9; border: 1px solid #cf222e; }
.leg-item.half-wrong::before { background: #fff3cd; border: 1px solid #d29922; }
.leg-item.typed::before { background: #fff3cd; border: 1px solid #d29922; }

.dual-passage-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 1rem;
  height: auto;
}

.passage-pane {
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  height: fit-content;
  min-height: 350px; /* Increased minimum height */
}

.pane-header {
  padding: 0.8rem 1.5rem;
  font-size: 0.9rem; /* Increased from 0.75rem */
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-secondary);
  background: var(--border-color);
  opacity: 0.9;
  text-align: center;
}

.pane-content {
  padding: 2rem; /* Increased from 1.5rem */
  font-family: 'Times New Roman', Times, serif;
  font-size: 1.25rem; /* Increased from 1.15rem */
  line-height: 1.6; /* Increased from 1.4 */
  background: var(--bg-color);
  white-space: pre-wrap;
  word-break: break-word;
}

.passage-pane.original .pane-content {
  color: var(--text-primary);
}

.comp-word {
  display: inline;
  padding: 0 0.05rem;
  border-radius: 2px;
}

.comp-word.correct {
  color: #2ea043;
  background: #dafbe1;
}

.comp-word.wrong {
  color: #cf222e;
  background: #ffebe9;
  text-decoration: line-through;
}

.comp-word.wrong-half {
  color: #d29922;
  background: #fff3cd;
  text-decoration: line-through;
}

.comp-word.wrong-word-ref {
  color: #cf222e;
  background: #ffebe9;
  font-weight: 600;
}

.comp-word.wrong-word-ref-half {
  color: #d29922;
  background: #fff3cd;
  font-weight: 600;
}

.comp-word.missed {
  color: #d29922;
  background: #fff3cd;
  text-decoration: underline dashed;
  font-weight: 600;
}

.comp-word.missed-indicator {
  color: #d29922;
  font-weight: 800;
  font-size: 0.7rem;
}

.comp-word.not-reached {
  color: var(--text-secondary);
  opacity: 0.3;
}

.exam-criteria-box {
  background: rgba(9, 105, 218, 0.03);
  padding: 1rem 1.5rem;
  border-radius: 10px;
  border: 1px solid rgba(9, 105, 218, 0.15);
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin: 2.5rem auto 0 auto;
  max-width: 600px;
}

.exam-criteria-box h4 {
  margin: 0 0 0.8rem 0;
  color: var(--accent-color);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-transform: uppercase;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.criteria-list {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.criteria-list p {
  margin: 0;
  line-height: 1.5;
}

.criteria-list strong {
  color: var(--text-primary);
}

/* Mobile Results Styling */
@media (max-width: 768px) {
  .results-content {
    padding: 1.5rem 1rem;
  }

  .hero-metrics {
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
  }

  .h-val {
    font-size: 1.2rem;
  }

  .stat-row {
    grid-template-columns: 1fr;
  }

  .dual-passage-container {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .passage-pane {
    min-height: 250px;
  }

  .pane-content {
    font-size: 1rem;
    padding: 1.2rem;
  }

  .header-actions {
    gap: 0.5rem;
  }

  .header-actions .btn {
    padding: 0.4rem 0.6rem;
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .report-main-title {
    font-size: 1.2rem;
  }

  .main-wpm {
    font-size: 2rem;
  }

  .result-status-ring {
    width: 120px;
    height: 120px;
  }
}

/* Print Styles */
@media print {
  @page {
    margin: 1cm;
    size: auto;
  }

  /* Hide non-essential UI elements */
  .navbar, 
  .footer, 
  .dashboard-header, 
  .stats-overview, 
  .history-section,
  .modal-header, 
  .modal-footer, 
  .header-actions,
  .btn-close,
  .logout-btn {
    display: none !important;
  }

  /* Reset layout constraints for printing */
  html, body {
    height: auto !important;
    overflow: visible !important;
    background: #fff !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* Ensure the dashboard container doesn't block the view */
  .dashboard-page {
    height: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
  }

  .dashboard-content {
    display: none !important;
  }

  /* Make the modal container act like a normal block */
  .modal-overlay {
    position: static !important;
    display: block !important;
    background: #fff !important;
    padding: 0 !important;
    margin: 0 !important;
    z-index: auto !important;
    overflow: visible !important;
  }

  .modal-content.report-modal {
    position: static !important;
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    box-shadow: none !important;
    overflow: visible !important;
    background: #fff !important;
  }

  .printable-report {
    display: block !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .print-branding {
    display: block !important;
  }

  /* Keep colors and backgrounds in print */
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .result-status-ring {
    border-width: 5px !important;
    print-color-adjust: exact;
  }
}
.auth-page {
  min-height: 100vh;
  background-color: var(--bg-color);
  display: flex;
}

.auth-split {
  display: flex;
  width: 100%;
}

/* Left Visual Side */
.auth-visual {
  flex: 1;
  background: linear-gradient(135deg, var(--bg-color) 0%, var(--card-bg) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem;
  position: relative;
  overflow: hidden;
  border-right: 1px solid var(--border-color);
}

.auth-visual::before {
  content: '';
  position: absolute;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, var(--accent-color) 0.05%, transparent 70%);
  opacity: 0.1;
  top: -50%;
  left: -50%;
  animation: rotate 20s linear infinite;
}

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

.visual-content {
  position: relative;
  z-index: 1;
  max-width: 500px;
  color: var(--text-primary);
}

.visual-logo {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 3rem;
  cursor: pointer;
  color: var(--text-primary);
}

.visual-logo span {
  color: var(--accent-color);
}

.visual-content h1 {
  font-size: 3rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  letter-spacing: -1.5px;
  color: var(--text-primary);
}

.visual-content p {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 3rem;
}

.quote-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 16px;
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.6;
}

.quote-author {
  display: block;
  margin-top: 1rem;
  font-style: normal;
  font-weight: 700;
  color: var(--accent-color);
  font-size: 0.9rem;
}

/* Right Form Side */
.auth-form-side {
  flex: 1;
  background-color: var(--bg-color);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.form-container {
  width: 100%;
  max-width: 420px;
}

.btn-back {
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 2.5rem;
  transition: color 0.2s;
}

.btn-back:hover {
  color: var(--text-primary);
}

.form-header {
  margin-bottom: 2.5rem;
}

.form-header h2 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.form-header p {
  color: var(--text-secondary);
}

.social-auth {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.google-btn {
  background: #fff !important;
  color: #000 !important;
  border: none !important;
}

.google-btn:hover {
  background: #f1f1f1 !important;
}

.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 0.8rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.9rem;
  transition: background 0.2s;
}

.btn-social:hover {
  background: #21262d;
}

.btn-social img {
  width: 20px;
  height: 20px;
}

.divider {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 700;
}

.divider::before, .divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

.divider span {
  padding: 0 1rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
  color: var(--text-primary);
}

.label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.forgot-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-color);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
  width: 100%;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 0.8rem 1rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
  outline: none;
}

.password-input {
  position: relative;
}

.toggle-password {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
}

.password-strength {
  margin-top: 0.8rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.strength-bar {
  flex: 1;
  height: 4px;
  background: var(--border-color);
  border-radius: 2px;
  position: relative;
  overflow: hidden;
}

.strength-bar::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  transition: width 0.3s, background 0.3s;
}

.strength-bar.level-1::after { width: 25%; background: #f85149; }
.strength-bar.level-2::after { width: 50%; background: #d29922; }
.strength-bar.level-3::after { width: 75%; background: #3fb950; }
.strength-bar.level-4::after { width: 100%; background: #238636; }

.password-strength span {
  font-size: 0.8rem;
  font-weight: 600;
  min-width: 80px;
}

.form-actions {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
}

.remember-me, .terms {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.remember-me label, .terms label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0;
}

.auth-submit {
  margin-bottom: 2rem;
}

.auth-footer {
  text-align: center;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.auth-footer span {
  color: var(--accent-color);
  font-weight: 700;
  cursor: pointer;
}

/* Responsive Auth */
@media (max-width: 1024px) {
  .auth-visual {
    display: none;
  }
}

@media (max-width: 480px) {
  .social-auth {
    grid-template-columns: 1fr;
  }
}
.dashboard-page {
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
}

.dashboard-content {
  padding: 4rem 2rem;
}

.dashboard-header {
  margin-bottom: 3rem;
}

.dashboard-header h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.dashboard-header p {
  color: var(--text-secondary);
}

/* Stats Cards */
.stats-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.stat-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 1.5rem;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
}

.card-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.card-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}

.card-trend {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.card-trend.positive {
  color: var(--success-color);
}

.card-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Analytics Section */
.analytics-section {
  margin-bottom: 4rem;
}

.analytics-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.analytics-header {
  margin-bottom: 2rem;
}

.analytics-header h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  font-weight: 700;
}

.analytics-header p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.chart-container {
  width: 100%;
  background: var(--bg-color);
  border-radius: 8px;
  padding: 1.5rem;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
}

.wpm-chart {
  width: 100%;
  height: auto;
  max-height: 300px;
}

.chart-point-group circle {
  transition: r 0.2s, stroke-width 0.2s;
  cursor: pointer;
}

.chart-point-group:hover circle {
  r: 7;
  stroke-width: 3;
}

.chart-placeholder {
  color: var(--text-secondary);
  font-style: italic;
  text-align: center;
  font-size: 0.95rem;
}

/* History Section */
.history-section {
  margin-bottom: 4rem;
}

.history-section h2 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
}

.history-table-container {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.history-table th {
  background: #21262d;
  padding: 1rem 1.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.history-table td {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.95rem;
}

.wpm-cell { font-weight: 700; color: var(--accent-color); }

.history-mode-box {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.h-mode-name {
  font-weight: 700;
  color: var(--text-primary);
}

.h-passage-name {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-style: italic;
  opacity: 0.8;
}

.acc-cell { color: var(--success-color); }

.status-tag {
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.status-tag.pass { background: rgba(63, 185, 80, 0.1); color: var(--success-color); }
.status-tag.fail { background: rgba(248, 81, 73, 0.1); color: var(--error-color); }

/* Promo Card */
.pro-features-promo {
  background: linear-gradient(135deg, rgba(88, 166, 255, 0.1) 0%, rgba(88, 166, 255, 0.02) 100%);
  border: 1px solid var(--accent-color);
  border-radius: 16px;
  padding: 3rem;
  text-align: center;
}

.promo-content h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.promo-content p {
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2rem;
}
.support-page {
  min-height: 100vh;
  background-color: var(--bg-color);
}

.support-hero {
  padding: 2.5rem 1rem 1.5rem;
  text-align: center;
}

.support-hero h1 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.4rem;
  color: var(--text-primary);
}

.support-hero p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto;
}

.support-content {
  padding: 0 1rem 4rem;
  max-width: 800px !important;
  margin: 0 auto;
}

.support-grid {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 1.5rem;
  align-items: start;
}

.support-info-cards {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.info-card {
  background: var(--card-bg);
  padding: 1rem;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  transition: all 0.2s;
}

.info-card:hover {
  border-color: var(--accent-color);
  background: rgba(94, 129, 172, 0.02);
}

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

.info-text h3 {
  font-size: 0.85rem;
  margin-bottom: 0.1rem;
  font-weight: 700;
}

.info-text p {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.3;
}

.email-card p {
  word-break: break-all;
  font-size: 0.7rem;
}

.contact-form-container {
  background: var(--card-bg);
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
}

.contact-form-container h2 {
  font-size: 1.1rem;
  margin-bottom: 1.2rem;
  font-weight: 700;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  display: block;
}

.form-group input, 
.form-group select, 
.form-group textarea {
  width: 100%;
  padding: 0.6rem 0.8rem;
  font-size: 0.9rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--bg-color);
  color: var(--text-primary);
}

.btn-large {
  width: 100%;
  padding: 0.7rem;
  font-size: 0.95rem;
  font-weight: 700;
}

@media (max-width: 768px) {
  .support-grid {
    grid-template-columns: 1fr;
  }
  .support-info-cards {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 1rem;
  }
  .info-card {
    min-width: 140px;
  }
}
.profile-page {
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
}

.profile-content {
  padding: 4rem 2rem;
}

.profile-header {
  margin-bottom: 3rem;
}

.profile-header h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.profile-header p {
  color: var(--text-secondary);
}

.settings-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
}

.settings-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 3rem;
  border-radius: 12px;
}

.form-section {
  margin-bottom: 3rem;
}

.form-section h3 {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: var(--accent-color);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.8rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.form-group input {
  width: 100%;
  background: #0d1117;
  border: 1px solid var(--border-color);
  padding: 0.8rem 1rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
}

.form-group input:focus {
  border-color: var(--accent-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
}

.form-actions {
  display: flex;
  gap: 1.5rem;
  padding-top: 1rem;
}

/* Notifications */
.notification {
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 2rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.notification.success {
  background: rgba(63, 185, 80, 0.1);
  color: var(--success-color);
  border: 1px solid var(--success-color);
}

.notification.error {
  background: rgba(248, 81, 73, 0.1);
  color: var(--error-color);
  border: 1px solid var(--error-color);
}

/* Sidebar */
.profile-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.sidebar-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 12px;
}

.sidebar-card h3 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.sidebar-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.status-details {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.status-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
}

.status-item .label {
  color: var(--text-secondary);
  font-weight: 500;
}

.status-item .value {
  font-weight: 600;
}

.pro-badge {
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: #000;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.75rem;
  letter-spacing: 0.5px;
}

.free-badge {
  background: #30363d;
  color: var(--text-secondary);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.75rem;
}

.expire-date {
  color: #f85149;
}

.membership-segments {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 1rem;
  padding-top: 1rem;
}

.segment-item {
  margin-bottom: 0.5rem;
}

.segment-item.highlight .value {
  color: #3fb950;
}

.extension-badge {
  display: inline-block;
  background: rgba(63, 185, 80, 0.15);
  color: #3fb950;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: 1rem;
  width: 100%;
  text-align: center;
}

.sidebar-card.danger {
  border-color: rgba(248, 81, 73, 0.3);
}

.danger-btn {
  color: var(--error-color);
  border-color: rgba(248, 81, 73, 0.3);
}

.danger-btn:hover {
  background: rgba(248, 81, 73, 0.1);
  border-color: var(--error-color);
}

/* Responsive */
@media (max-width: 1024px) {
  .settings-grid {
    grid-template-columns: 1fr;
  }
}
.admin-page {
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
}

.admin-content {
  padding: 4rem 2rem;
}

.admin-tabs {
  display: flex;
  gap: 1rem;
}

.tab-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s;
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--accent-color);
  border-bottom-color: var(--accent-color);
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 2rem;
}

.admin-header h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.admin-header p {
  color: var(--text-secondary);
}

.add-exam-form {
  margin-bottom: 4rem;
  animation: fadeIn 0.3s ease-out;
}

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

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.form-group select {
  width: 100%;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  padding: 0.8rem 1rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
}

.exams-list-section h2 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
}

.admin-list-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.admin-list-header-row h2 {
  margin-bottom: 0;
}

.admin-filter-box {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-color);
  padding: 0.6rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

.admin-filter-box label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.admin-date-input {
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--card-bg);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.9rem;
}

.exams-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.admin-exam-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.2s;
}

.admin-exam-card:hover {
  border-color: var(--accent-color);
}

.passage-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.admin-exam-card h3 {
  font-size: 1.3rem;
  margin: 0;
  flex: 1;
}

.date-badge {
  font-size: 0.75rem;
  color: var(--text-secondary);
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  white-space: nowrap;
}

.exam-tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.tag-lang.hi {
  background: rgba(210, 153, 34, 0.1);
  color: #d29922;
}

.tag-difficulty {
  font-weight: 800;
  color: #fff;
}

.tag-difficulty.easy {
  background: #2ea043;
}

.tag-difficulty.medium {
  background: #d29922;
}

.tag-difficulty.hard {
  background: #cf222e;
}

.exam-req {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.form-group textarea {
  width: 100%;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  padding: 1rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  resize: vertical;
}

.form-group textarea:focus {
  border-color: var(--accent-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
}

.full-width {
  grid-column: 1 / -1;
}

.field-hint {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

.exam-p-preview {
  font-size: 0.85rem;
  color: var(--text-secondary);
  background: var(--card-bg);
  padding: 0.8rem;
  border-radius: 6px;
  border: 1px dashed var(--border-color);
  margin-bottom: 1.5rem;
}

.exam-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
}

.danger-btn {
  color: var(--error-color);
  border-color: rgba(248, 81, 73, 0.3);
}

.danger-btn:hover {
  background: rgba(248, 81, 73, 0.1);
  border-color: var(--error-color);
}

.users-table-container {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.admin-users-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-users-table th {
  text-align: left;
  padding: 0.6rem 0.8rem;
  font-size: 0.7rem;
  text-transform: uppercase;
  color: var(--text-secondary);
  border-bottom: 2px solid var(--border-color);
  background: rgba(0, 0, 0, 0.02);
}

.user-list-row td {
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
  font-size: 0.8rem;
}

.user-list-row.active {
  background: rgba(88, 166, 255, 0.05);
}

.user-cell-info {
  display: flex;
  flex-direction: column;
}

.user-cell-info strong {
  color: var(--text-primary);
  font-size: 0.85rem;
}

.u-email {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.credential-cell code {
  background: rgba(0, 0, 0, 0.05);
  padding: 0.15rem 0.3rem;
  border-radius: 4px;
  color: var(--accent-color);
  font-family: monospace;
  font-size: 0.75rem;
}

.user-stats-badges.compact {
  display: flex;
  gap: 0.4rem;
}

.history-expanded-row {
  background: var(--bg-color);
}

.expanded-history-content {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-color);
}

.expanded-history-content h4 {
  margin-top: 0;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.user-record-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.user-record-header {
  padding: 1.2rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border-color);
}

.user-main-info {
  display: flex;
  flex-direction: column;
}

.user-main-info strong {
  font-size: 1.1rem;
  color: var(--text-primary);
}

.user-email-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.user-pwd-display {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.4rem;
}

.user-pwd-display code {
  background: rgba(0, 0, 0, 0.05);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  color: var(--accent-color);
  font-family: monospace;
}

.user-meta-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.8rem;
}

.user-date {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.user-stats-badges {
  display: flex;
  gap: 0.5rem;
}

.stat-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  text-transform: uppercase;
}

.stat-badge.pass {
  background: rgba(46, 160, 67, 0.1);
  color: #2ea043;
  border-color: rgba(46, 160, 67, 0.2);
}

.stat-badge.fail {
  background: rgba(248, 81, 73, 0.1);
  color: #f85149;
  border-color: rgba(248, 81, 73, 0.2);
}

.user-history-section {
  padding: 1.2rem 1.5rem;
}

.user-history-section h4 {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  margin-bottom: 1rem;
  letter-spacing: 0.5px;
}

.history-mini-table {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
}

.history-header {
  display: grid;
  grid-template-columns: 100px 1fr 80px 100px;
  padding: 0.6rem 1rem;
  background: var(--bg-color);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  border-bottom: 1px solid var(--border-color);
}

.history-row {
  display: grid;
  grid-template-columns: 100px 1fr 80px 100px;
  padding: 0.8rem 1rem;
  align-items: center;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border-color);
}

.history-row:last-child {
  border-bottom: none;
}

.h-date {
  color: var(--text-secondary);
  font-size: 0.8rem;
}

.h-exam-info {
  display: flex;
  flex-direction: column;
}

.h-mode {
  font-weight: 700;
  color: var(--text-primary);
}

.h-passage {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-style: italic;
}

.h-speed {
  font-weight: 800;
  color: var(--accent-color);
}

.h-status {
  font-size: 0.7rem;
  font-weight: 800;
  text-align: center;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  width: fit-content;
}

.h-status.passed {
  background: rgba(46, 160, 67, 0.1);
  color: #2ea043;
}

.h-status.failed {
  background: rgba(248, 81, 73, 0.1);
  color: #f85149;
}

.no-history {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-style: italic;
  padding: 1rem 0;
}

.queries-list-section {
  animation: fadeIn 0.3s ease-out;
}

.notification {
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 0.9rem;
  font-weight: 500;
}

.notification.success {
  background: rgba(46, 160, 67, 0.1);
  color: #2ea043;
  border: 1px solid rgba(46, 160, 67, 0.2);
}

.notification.error {
  background: rgba(248, 81, 73, 0.1);
  color: #f85149;
  border: 1px solid rgba(248, 81, 73, 0.2);
}

@media (max-width: 768px) {
  .admin-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }

  /* Responsive styling for admin database tables (convert to cards) */
  .admin-users-table thead {
    display: none;
  }

  .admin-users-table, 
  .admin-users-table tbody {
    display: block;
    width: 100%;
  }

  .admin-users-table tr.user-list-row {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 1.2rem;
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
  }

  .admin-users-table tr.user-list-row td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-size: 0.8rem;
    width: 100%;
    box-sizing: border-box;
    min-height: 40px;
  }

  .admin-users-table tr.user-list-row td:last-child {
    border-bottom: none;
  }

  /* Display label prefix on left */
  .admin-users-table tr.user-list-row td::before {
    content: attr(data-label);
    font-weight: 700;
    color: var(--text-secondary);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    text-align: left;
    margin-right: 1rem;
  }

  /* Hide label prefix on User Details and Actions (full-width style) */
  .admin-users-table tr.user-list-row td[data-label="User Details"]::before,
  .admin-users-table tr.user-list-row td[data-label="User Info"]::before,
  .admin-users-table tr.user-list-row td[data-label="Actions"]::before {
    display: none;
  }

  .admin-users-table tr.user-list-row td[data-label="User Details"],
  .admin-users-table tr.user-list-row td[data-label="User Info"] {
    display: block;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.6rem;
    margin-bottom: 0.4rem;
    text-align: left;
  }

  .admin-users-table tr.user-list-row td[data-label="Actions"] {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.4rem;
    padding-top: 0.6rem;
  }
}
.rules-page-container {
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
}

.rules-main {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2rem;
  padding: 2rem;
}

.rules-sidebar {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  height: fit-content;
  position: sticky;
  top: 100px;
}

.rules-sidebar h3 {
  margin-bottom: 1.2rem;
  font-size: 1.1rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.exam-menu-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.menu-item {
  text-align: left;
  padding: 0.8rem 1rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.95rem;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.menu-item.active {
  background: var(--accent-color);
  color: #fff;
}

.rules-detail-area {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2.5rem;
}

.detail-header {
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1.5rem;
}

.detail-header h1 {
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
}

.detail-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.rules-content h2 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  color: var(--accent-color);
}

.rules-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.rules-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
}

.rules-card h3 {
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-size: 1.2rem;
}

.rules-card ul {
  list-style: none;
  padding: 0;
}

.rules-card li {
  margin-bottom: 0.8rem;
  line-height: 1.5;
  color: var(--text-secondary);
  position: relative;
  padding-left: 1.2rem;
}

.rules-card li::before {
  content: "•";
  color: var(--accent-color);
  position: absolute;
  left: 0;
  font-weight: bold;
}

@media (max-width: 992px) {
  .rules-main {
    grid-template-columns: 1fr;
  }
  .rules-sidebar {
    position: static;
  }
  .rules-grid {
    grid-template-columns: 1fr;
  }
}
.legal-page {
  min-height: 100vh;
  background-color: var(--bg-color);
  color: var(--text-primary);
}

.legal-content {
  padding: 4rem 2rem;
  max-width: 800px !important;
  margin: 0 auto;
}

.legal-card {
  background: var(--card-bg);
  padding: 3rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.legal-header {
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 2rem;
  margin-bottom: 2rem;
}

.legal-header h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  color: var(--accent-color);
}

.last-updated {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.legal-section {
  margin-bottom: 2.5rem;
}

.legal-section h2 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-weight: 700;
}

.legal-section p {
  line-height: 1.7;
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.legal-footer {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

@media (max-width: 768px) {
  .legal-card {
    padding: 1.5rem;
  }
  .legal-header h1 {
    font-size: 1.8rem;
  }
}
.instruction-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2500;
  backdrop-filter: blur(8px);
}

.instruction-card {
  background: var(--bg-color);
  width: 90%;
  max-width: 600px;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.instruction-header {
  padding: 1.5rem;
  background: var(--accent-color);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.instruction-header h1 {
  font-size: 1.25rem;
  margin: 0;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.close-btn {
  background: transparent;
  border: none;
  color: white;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.close-btn:hover {
  opacity: 1;
}

.candidate-info {
  padding: 1.5rem;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
  display: grid;
  gap: 0.8rem;
}

.info-item {
  display: grid;
  grid-template-columns: 150px 1fr;
  align-items: center;
}

.info-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.info-value {
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 700;
}

.instruction-body {
  padding: 2rem;
  overflow-y: auto;
  max-height: 40vh;
}

.instruction-body h3 {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.instruction-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.instruction-list li {
  padding: 0.6rem 0;
  padding-left: 1.5rem;
  position: relative;
  font-size: 0.95rem;
  color: var(--text-primary);
  line-height: 1.5;
  border-bottom: 1px solid var(--border-color);
}

.instruction-list li:last-child {
  border-bottom: none;
}

.instruction-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-weight: 900;
}

.instruction-footer {
  padding: 1.5rem;
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  background: var(--card-bg);
}

.start-btn {
  padding: 0.8rem 2rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(9, 105, 218, 0.3);
}

.start-btn:hover {
  background: var(--success-color);
  transform: translateY(-2px);
}
.pricing-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 20px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  color: var(--text);
  animation: fadeIn 0.5s ease-out;
}

.pricing-header {
  text-align: center;
  margin-bottom: 80px;
  position: relative;
}

.back-btn {
  position: absolute;
  top: 0;
  left: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 700;
  transition: color 0.2s;
}

.back-btn:hover {
  color: var(--primary);
}

.pricing-title h1 {
  font-size: 3rem;
  font-weight: 900;
  margin-bottom: 15px;
  letter-spacing: -1.5px;
}

.pricing-title h1 span {
  color: var(--primary);
  background: linear-gradient(135deg, #6366f1, #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pricing-title p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-bottom: 80px;
}

.plan-card {
  background: linear-gradient(145deg, var(--bg-card), var(--bg-main));
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 30px 24px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  overflow: visible;
}

.plan-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary-light, #818cf8);
  box-shadow: 0 12px 30px rgba(0,0,0,0.1), 0 0 15px rgba(99, 102, 241, 0.1);
  background: var(--bg-card);
}

.plan-card.popular {
  background: rgba(94, 129, 172, 0.03);
  border: 2.5px solid #5e81ac;
  border-radius: 20px;
}

.plan-card.popular:hover {
  transform: translateY(-5px);
  border-color: #5e81ac;
  box-shadow: 0 12px 30px rgba(94, 129, 172, 0.25);
}

.popular-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: #5e81ac;
  color: white;
  padding: 5px 16px;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 1px;
  box-shadow: 0 4px 12px rgba(94, 129, 172, 0.4);
  white-space: nowrap;
  z-index: 10;
}

.plan-name {
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 15px;
  color: var(--text-title);
}

.plan-price-group {
  margin-bottom: 15px;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.plan-price-group .price {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--text-title);
  letter-spacing: -1.5px;
}

.plan-price-group .duration {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
}

.plan-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 25px;
  line-height: 1.5;
  min-height: 40px;
}

.plan-features {
  margin-bottom: 30px;
  flex: 1;
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.8rem;
  margin-bottom: 12px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}

.check-icon {
  color: #10b981;
  flex-shrink: 0;
  margin-top: 2px;
}

.plan-btn {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-primary {
  background: #5e81ac;
  color: white;
  border: none;
  transition: all 0.2s ease-in-out;
}

.btn-primary:hover {
  background: #4c6e96;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(94, 129, 172, 0.3);
}

.btn-ghost {
  background: transparent;
  color: #5e81ac;
  border: 1px solid #5e81ac;
  transition: all 0.2s ease-in-out;
}

.btn-ghost:hover {
  background: #5e81ac;
  color: white;
  border-color: #5e81ac;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(94, 129, 172, 0.3);
}

.faq-section {
  max-width: 900px;
  margin: 0 auto 100px auto;
}

.faq-section h2 {
  text-align: center;
  font-size: 2.2rem;
  font-weight: 900;
  margin-bottom: 50px;
}

.faq-section h2 span {
  color: var(--primary);
}

.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.faq-item h4 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-title);
  margin-bottom: 12px;
}

.faq-item p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.pricing-footer {
  text-align: center;
  border-top: 1px solid var(--border);
  padding-top: 40px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.legal-links {
  margin-top: 15px;
}

.footer-link {
  color: var(--primary);
  cursor: pointer;
  margin: 0 10px;
  text-decoration: underline;
  transition: color 0.2s, opacity 0.2s;
}

.footer-link:hover {
  opacity: 0.8;
  color: #a855f7;
}

.legal-links a {
  color: var(--primary);
  text-decoration: none;
  margin: 0 10px;
}

@media (max-width: 768px) {
  .pricing-title h1 {
    font-size: 2.2rem;
  }
  .faq-grid {
    grid-template-columns: 1fr;
  }
  .back-btn {
    position: relative;
    margin-bottom: 20px;
  }
}
.download-app-container {
  padding: 2rem 1rem;
  max-width: 1200px;
  margin: 0 auto;
  animation: fadeIn 0.5s ease-out;
}

.download-header {
  margin-bottom: 3rem;
  text-align: center;
  position: relative;
}

.download-header .back-btn {
  position: absolute;
  left: 0;
  top: 0;
  background: none;
  border: none;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  padding: 0.5rem 1rem;
  border-radius: 8px;
}

.download-header .back-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.download-title h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.download-title h1 span {
  color: var(--accent-color);
}

.download-title p {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.download-main {
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.hero-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  padding: 3rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  align-items: center;
}

.hero-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.app-icon-large {
  background: rgba(var(--accent-rgb), 0.05);
  padding: 0.5rem;
  border-radius: 20px;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  width: 100%;
  max-width: 320px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border-color);
}

.app-preview-img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.hero-content h2 {
  font-size: 2rem;
  margin: 0;
}

.version-info {
  color: var(--text-secondary);
  margin-top: -1rem;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1rem 2.5rem;
  font-size: 1.2rem;
  text-decoration: none;
}

.installer-type {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.hero-features h3 {
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
}

.features-list {
  display: grid;
  gap: 1rem;
}

.feature-pill {
  padding: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border: 1px solid var(--border-color);
  font-size: 1rem;
}

.feature-pill strong {
  color: var(--accent-color);
}

.requirements-section, .installation-guide {
  text-align: center;
}

.requirements-section h2, .installation-guide h2 {
  margin-bottom: 2.5rem;
  font-size: 2rem;
}

.requirements-section h2 span, .installation-guide h2 span {
  color: var(--accent-color);
}

.requirements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.requirement-item {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  text-align: left;
  transition: transform 0.2s, border-color 0.2s;
}

.requirement-item:hover {
  transform: translateY(-5px);
  border-color: var(--accent-color);
}

.req-header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.req-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--accent-color);
  border-radius: 10px;
}

.req-label {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
}

.req-value {
  font-weight: 500;
  color: var(--text-primary);
  font-size: 1rem;
  line-height: 1.4;
}

.guide-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.step {
  padding: 2rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  position: relative;
}

.step-num {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  background: var(--accent-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  box-shadow: 0 4px 10px rgba(var(--accent-rgb), 0.3);
}

.step p {
  margin-top: 1rem;
  line-height: 1.6;
}

.download-footer {
  margin-top: 5rem;
  text-align: center;
  color: var(--text-secondary);
  padding-bottom: 2rem;
}

.download-faq {
  text-align: center;
}

.download-faq h2 {
  margin-bottom: 2.5rem;
  font-size: 2rem;
}

.download-faq h2 span {
  color: var(--accent-color);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.faq-item {
  padding: 1.5rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  text-align: left;
  transition: transform 0.2s;
}

.faq-item:hover {
  transform: translateY(-5px);
}

.faq-item h4 {
  color: var(--text-primary);
  margin-bottom: 1rem;
  font-size: 1.1rem;
  border-bottom: 2px solid rgba(var(--accent-rgb), 0.1);
  padding-bottom: 0.5rem;
}

.faq-item p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 0.95rem;
}

.faq-item strong {
  color: var(--accent-color);
}

@media (max-width: 992px) {
  .hero-card {
    grid-template-columns: 1fr;
    padding: 2rem;
  }
}

@media (max-width: 600px) {
  .download-header {
    padding-top: 3rem;
  }
  .download-header .back-btn {
    left: 50%;
    transform: translateX(-50%);
  }
  .download-title h1 {
    font-size: 1.8rem;
  }
  .requirement-item {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Navbar Styles */
.navbar {
  height: 60px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background: var(--bg-color);
  backdrop-filter: blur(10px);
  z-index: 100;
}

.logo {
  display: flex;
  align-items: center;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #000;
  cursor: pointer;
  margin-right: 3rem;
}

.navbar-logo-img {
  width: 38px;
  height: 38px;
  margin-right: 12px;
  object-fit: contain;
}

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

.nav-links {
  display: flex;
  gap: 0.8rem;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
}

.nav-links a, .nav-link-clickable {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color 0.2s;
  cursor: pointer;
  white-space: nowrap;
}

.nav-link-clickable:hover {
  color: var(--accent-color);
}

.nav-link-clickable.active {
  color: var(--accent-color);
  font-weight: 700;
}

.nav-highlight {
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--accent-color) !important;
  padding: 0.4rem 0.6rem;
  border-radius: 8px;
  font-weight: 700 !important;
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  transition: all 0.3s ease;
}

.nav-highlight:hover {
  background: var(--accent-color);
  color: white !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(var(--accent-rgb), 0.2);
}

.nav-badge-new {
  background: #f85149;
  color: white !important;
  font-size: 0.55rem;
  font-weight: 900;
  padding: 1px 5px;
  border-radius: 4px;
  margin-left: 4px;
  vertical-align: middle;
  display: inline-block;
  animation: pulseBadge 2s infinite;
  box-shadow: 0 0 8px rgba(248, 81, 73, 0.4);
  text-transform: uppercase;
}

@keyframes pulseBadge {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(248, 81, 73, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 10px rgba(248, 81, 73, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(248, 81, 73, 0); }
}

.nav-content {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-left: 2rem;
}

.nav-auth-btns {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.user-profile-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.welcome-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.welcome-text strong {
  color: var(--accent-color);
}

.btn {
  padding: 0.6rem 1.25rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  background-color: var(--accent-color);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(9, 105, 218, 0.15);
}

.btn-primary:hover {
  background-color: #085cc1;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(9, 105, 218, 0.25);
}

.btn-outline {
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.btn-outline:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
  background-color: rgba(9, 105, 218, 0.02);
  transform: translateY(-1px);
}

.btn-large {
  padding: 0.75rem 1.75rem;
  font-size: 0.95rem;
}

/* Hero Section */
.hero {
  padding: 4rem 0 5rem;
  background: radial-gradient(circle at 10% 20%, rgba(88, 166, 255, 0.08) 0%, transparent 50%);
  position: relative;
  overflow: hidden;
}

.hero-content {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: center;
}

.hero-text h1 {
  font-size: 3.5rem;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: -1.5px;
}

.hero-text h1 span {
  color: var(--accent-color);
}

.hero-description-styled {
  font-size: 1.2rem;
  color: #475569;
  margin-bottom: 2.5rem;
  line-height: 1.7;
  max-width: 620px;
}

.supported-exams-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.exam-badge {
  background: white;
  color: #334155;
  padding: 0.5rem 1rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.exam-badge:hover {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(9, 105, 218, 0.2);
}

.hero-btns {
  display: flex;
  gap: 1.25rem;
}

.hero-stats {
  display: flex;
  gap: 3.5rem;
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid #f1f5f9;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
}

.stat-label {
  font-size: 0.85rem;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 0.4rem;
  font-weight: 600;
}

/* Dashboard Preview (Hero Visual) */
.hero-visual {
  flex: 1;
  display: flex;
  justify-content: flex-end;
  margin-top: -7rem;
}

.dashboard-preview {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12);
  overflow: hidden;
  width: 100%;
  max-width: 500px;
  transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
  transition: transform 0.3s;
}

.dashboard-preview:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.preview-header {
  background: #21262d;
  padding: 12px 18px;
  display: flex;
  gap: 8px;
}

.preview-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.preview-dot.red { background: #ff5f56; }
.preview-dot.yellow { background: #ffbd2e; }
.preview-dot.green { background: #27c93f; }

.preview-body {
  padding: 2.5rem;
}

.preview-metrics {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
}

.metric {
  display: flex;
  flex-direction: column;
}

.m-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
}

.m-value {
  font-size: 1.6rem;
  font-weight: 850;
  color: var(--accent-color);
}

.preview-text {
  font-size: 1.1rem;
  color: var(--text-primary);
  opacity: 0.8;
  font-family: 'Times New Roman', Times, serif;
  line-height: 1.6;
}

.preview-text .correct { 
  color: var(--success-color); 
  border-bottom: 2px solid var(--success-color); 
}

.preview-text .incorrect { 
  color: var(--error-color); 
  background: rgba(248, 81, 73, 0.15); 
  padding: 0 2px;
}

.preview-metrics {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
}

.metric {
  display: flex;
  flex-direction: column;
}

.m-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.m-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-color);
}

.preview-text {
  font-size: 1.2rem;
  color: var(--text-primary);
  opacity: 0.7;
  font-family: 'Times New Roman', Times, serif;
}

.preview-text .correct { color: var(--success-color); border-bottom: 2px solid var(--success-color); }
.preview-text .incorrect { color: var(--error-color); background: rgba(248, 81, 73, 0.2); }

/* Exams Section */
.exams-section {
  padding: 3rem 0;
}

.section-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  margin-bottom: 2rem !important;
}

.category-filters {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 0.6rem 1.5rem;
  border-radius: 30px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-weight: 600;
  cursor: pointer;
}

.filter-btn.active {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

.exam-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.exam-card {
    background: #fff !important;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    flex-direction: column;
    padding: 1.25rem;
    transition: all .25s;
    display: flex;
}

.exam-card:hover {
  border-color: var(--accent-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.exam-tag {
  display: inline-block;
  background: rgba(9, 105, 218, 0.1);
  color: var(--accent-color);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.8rem;
  text-transform: uppercase;
  width: fit-content;
}

.exam-tag-new {
  display: inline-block;
  background: #fdf2f2;
  color: #cf222e;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.8rem;
  text-transform: uppercase;
  width: fit-content;
  border: 1px solid #f851494d;
  animation: pulseNew 2s infinite;
}

.is-new-card {
  border-color: #f8514933 !important;
  background: linear-gradient(to bottom, #fffcfc, #fff) !important;
}

@keyframes pulseNew {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.exam-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.exam-details {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.exam-details span {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.exam-details strong {
  color: var(--text-primary);
}

.btn-start-exam {
  background-color: #5e81ac !important;
  border-color: #5e81ac !important;
  color: white !important;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 0.8rem;
  padding: 0.8rem;
  transition: all 0.2s ease;
}

.btn-start-exam:hover {
  background-color: #4c566a !important;
  border-color: #4c566a !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(94, 129, 172, 0.3);
}

/* Exam Landing Page */
.exam-landing-container {
  padding: 4rem 0;
  min-height: 80vh;
  background: var(--bg-color);
}

.exam-landing-header {
  margin-bottom: 3rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
  flex-wrap: wrap;
}

.exam-landing-title-section {
  flex: 1;
  min-width: 300px;
}

.btn-back-link {
  background: none;
  border: none;
  color: var(--accent-color);
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: transform 0.2s;
}

.btn-back-link:hover {
  transform: translateX(-5px);
}

.exam-landing-title-section h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.exam-landing-title-section h1 span {
  color: var(--accent-color);
  display: block;
}

.exam-description-lead {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  line-height: 1.6;
}

.exam-quick-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  min-width: 300px;
}

.stat-card {
  background: var(--card-bg);
  padding: 1.2rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.stat-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent-color);
}

.exam-content-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 2rem;
}

.section-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.section-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-header h3 {
  margin: 0;
  font-size: 1.25rem;
}

.filter-controls {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  flex-wrap: wrap;
}

.limit-editor {
  display: flex;
  align-items: center;
  background: rgba(94, 129, 172, 0.1);
  padding: 0.3rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  gap: 0.5rem;
}

.limit-editor .label {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--text-secondary);
}

.limit-editor input {
  width: 50px;
  background: transparent;
  border: none;
  font-weight: 800;
  color: var(--accent-color);
  outline: none;
  font-family: inherit;
}

.date-filter {
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--bg-color);
  color: var(--text-primary);
  font-family: inherit;
}

.btn-filter {
  padding: 0.4rem 1rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-secondary);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-filter.active {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

.passage-table-wrapper {
  max-height: 600px;
  overflow-y: auto;
}

.passage-title-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tag-legal {
  font-size: 0.6rem;
  background: #d29922;
  color: white;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-weight: 800;
  text-transform: uppercase;
}

.exam-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.rules-summary-card, .tips-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.rules-summary-card h4, .tips-card h4 {
  margin: 0 0 1rem 0;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.rule-details {
  margin: 1rem 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.rule-item {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.rule-item strong {
  color: var(--text-primary);
}

.tips-card ul {
  padding-left: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin: 0;
}

.tips-card li {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

@media (max-width: 992px) {
  .exam-content-grid {
    grid-template-columns: 1fr;
  }
  
  .exam-landing-header {
    flex-direction: column;
  }
  
  .exam-quick-stats {
    width: 100%;
  }
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(6px);
}

.modal-content {
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  width: 95%;
  max-width: 850px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.passage-selection-modal {
  padding: 0;
}

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

.modal-header-text {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.modal-header h2 {
  margin: 0;
  font-size: 1.5rem;
}

.btn-close {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
  font-size: 1.6rem;
  line-height: 1;
  padding: 0;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  z-index: 1010;
}

.btn-close:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--text-secondary);
  transform: translateY(-1px);
}

.btn-close:active {
  transform: translateY(0);
}

.passage-count-badge {
  font-size: 0.8rem;
  color: var(--accent-color);
  font-weight: 600;
  background: rgba(88, 166, 255, 0.1);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  width: fit-content;
}

.modal-controls {
  padding: 1.5rem 2rem;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
}

.modal-filters-row {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.filter-group label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.date-filter-select, .date-filter-picker {
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--bg-color);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.85rem;
}

.date-input-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.clear-date {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.clear-date:hover {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

.level-filters {
  display: flex;
  gap: 0.4rem;
}

.level-btn {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--bg-color);
  font-weight: 700;
  cursor: pointer;
}

.level-btn.active.easy { background: #2ea043; color: white; border-color: #2ea043; }
.level-btn.active.medium { background: #d29922; color: white; border-color: #d29922; }
.level-btn.active.hard { background: #f85149; color: white; border-color: #f85149; }

.passage-table-container {
  overflow-y: auto;
  padding: 1rem 2rem 2rem;
}

.passage-table {
  width: 100%;
  border-collapse: collapse;
}

.passage-table th {
  text-align: left;
  padding: 0.8rem 1rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-secondary);
  border-bottom: 2px solid var(--border-color);
}

.passage-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.passage-row {
  cursor: pointer;
  transition: background 0.2s;
}

.passage-row:hover {
  background: rgba(9, 105, 218, 0.05);
}

.passage-info-box {
  display: flex;
  flex-direction: column;
}

.p-title {
  font-weight: 700;
  color: var(--text-primary);
}

.p-preview {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* Leaderboard Section */
.passage-selection-table {
  width: 100%;
  border-collapse: collapse;
}

.passage-selection-table th {
  text-align: left;
  padding: 0.8rem 1rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-secondary);
  border-bottom: 2px solid var(--border-color);
}

.passage-selection-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.9rem;
}

.passage-row-v2 {
  cursor: pointer;
  transition: background 0.2s;
}

.passage-row-v2:hover {
  background: rgba(9, 105, 218, 0.05);
}

.p-date-cell {
  color: var(--text-secondary);
  font-family: monospace;
}

.passage-selection-table .btn-small {
  background-color: #5e81ac;
  border-color: #5e81ac;
  color: white;
  font-weight: 700;
  padding: 0.4rem 1rem;
}

.passage-selection-table .btn-small:hover {
  background-color: #4c566a;
  border-color: #4c566a;
}

.leaderboard-section {
  padding: 6rem 0;
}

.leaderboard-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  margin-top: 2rem;
}

.leaderboard-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.leaderboard-table th {
  background: var(--border-color);
  opacity: 0.8;
  padding: 1rem 1.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.leaderboard-table td {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--border-color);
  font-weight: 700;
  font-size: 0.8rem;
}

.rank-1 { background: #ffd700; color: #000; }
.rank-2 { background: #c0c0c0; color: #000; }

/* Footer Styles */
.footer {
  background: var(--card-bg);
  border-top: 1px solid var(--border-color);
  padding: 5rem 0 0 0;
  margin-top: auto;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 4rem;
  margin-bottom: 4rem;
}

.footer-brand p {
  color: var(--text-secondary);
  margin: 1.5rem 0;
  line-height: 1.6;
  max-width: 300px;
}

.footer-logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: #000;
}

.footer-logo span { color: var(--accent-color); }

.footer-group h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-group ul {
  list-style: none;
}

.footer-group ul li {
  margin-bottom: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s;
}

.footer-group ul li:hover {
  color: var(--accent-color);
}

.footer-group ul li a {
  text-decoration: none;
  color: inherit;
}

.social-icons {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-icon {
  width: 40px;
  height: 40px;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.social-icon:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  border-color: var(--accent-color);
}

.social-icon.telegram:hover {
  background: #0088cc;
  color: white;
  border-color: #0088cc;
}

.social-icon svg {
  width: 22px;
  height: 22px;
}

.footer-bottom {
  padding: 2rem 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.footer-bottom p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Mobile Burger Menu & Drawer */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  cursor: pointer;
  position: relative;
  z-index: 1100;
  padding: 0;
}

.burger-bar {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  position: absolute;
  left: 8px;
  top: 19px;
  transition: all 0.3s ease;
}

.burger-bar::before, .burger-bar::after {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  position: absolute;
  left: 0;
  transition: all 0.3s ease;
}

.burger-bar::before { top: -8px; }
.burger-bar::after { top: 8px; }

.burger-bar.open { background: transparent; }
.burger-bar.open::before { transform: rotate(45deg); top: 0; }
.burger-bar.open::after { transform: rotate(-45deg); top: 0; }

.mobile-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100%;
  z-index: 2000;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-drawer.open {
  right: 0;
  visibility: visible;
}

.drawer-content {
  position: absolute;
  right: 0;
  top: 0;
  width: 280px;
  height: 100%;
  background: var(--bg-color);
  box-shadow: -10px 0 30px rgba(0,0,0,0.1);
  z-index: 2;
  padding: 2rem;
  display: flex;
  flex-direction: column;
}

.drawer-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px);
  z-index: 1;
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.drawer-header h3 {
  font-size: 1.2rem;
  margin: 0;
  color: var(--accent-color);
}

.btn-close-drawer {
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.link-item {
  padding: 0.8rem 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  border-bottom: 1px solid rgba(0,0,0,0.03);
}

.link-item.small {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 400;
}

.link-item:active {
  color: var(--accent-color);
}

/* Tablet & Small Desktop Navbar Adjustments */
@media (max-width: 1350px) {
  .nav-links {
    gap: 1.5rem;
  }
}

@media (max-width: 1250px) {
  .nav-links {
    gap: 1.2rem;
  }
  .nav-link-clickable {
    font-size: 0.9rem;
  }
  .logo {
    font-size: 1.4rem;
  }
  .navbar-logo-img {
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 1150px) {
  .nav-text-extra {
    display: none;
  }
  .welcome-text {
    display: none;
  }
  .nav-links {
    gap: 1rem;
  }
}

@media (max-width: 1024px) {
  .nav-highlight {
    padding: 0.45rem 1rem !important;
  }
  .nav-links {
    gap: 0.8rem;
  }
  .nav-link-clickable {
    font-size: 0.85rem;
  }
  .logo {
    font-size: 1.3rem;
  }
  .navbar-logo-img {
    width: 34px;
    height: 34px;
    margin-right: 8px;
  }
  .nav-actions {
    gap: 0.8rem;
  }
}

@media (max-width: 900px) {
  .nav-links {
    gap: 0.6rem;
  }
  .nav-link-clickable {
    font-size: 0.8rem;
  }
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }

  .hero-text h1 {
    font-size: 2.8rem;
  }

  .hero-btns, .hero-stats {
    justify-content: center;
  }

  .hero-visual {
    justify-content: center;
    margin-top: 0;
  }
}

@media (max-width: 768px) {
  .navbar {
    height: 70px;
    padding: 0 1rem;
  }

  .nav-links {
    display: none; /* Hide nav links on mobile, or could implement a burger menu */
  }

  .welcome-text {
    display: none;
  }

  .hero {
    padding: 3rem 0;
  }

  .hero-text h1 {
    font-size: 2.2rem;
  }

  .hero-text p {
    font-size: 1rem;
  }

  .hero-btns {
    flex-direction: column;
    gap: 1rem;
  }

  .hero-stats {
    gap: 1.5rem;
    flex-wrap: wrap;
  }

  .stat-value {
    font-size: 1.4rem;
  }

  .exam-grid {
    grid-template-columns: 1fr;
  }

  .modal-content {
    width: 100%;
    height: 100%;
    max-height: 100vh;
    border-radius: 0;
  }

  .modal-filters-row {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .filter-group {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }

  .footer-brand p {
    margin: 1.5rem auto;
  }

  .social-icons {
    justify-content: center;
  }

  .passage-table th:nth-child(3), 
  .passage-table td:nth-child(3),
  .passage-table th:nth-child(4),
  .passage-table td:nth-child(4) {
    display: none; /* Hide Level and Words on very small screens to save space */
  }
}

@media (max-width: 480px) {
  .hero-text h1 {
    font-size: 1.8rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .logo {
    font-size: 1.2rem;
  }

  .btn {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
  }
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 70px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.05);
  z-index: 1000;
  justify-content: space-around;
  align-items: center;
  padding: 0 1rem;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--text-secondary);
  flex: 1;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.nav-item.active {
  color: var(--accent-color);
}

.nav-icon {
  font-size: 1.4rem;
}

.nav-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
}

.start-test-fab {
  position: relative;
  top: -25px;
  flex: 0 0 60px;
}

.fab-inner {
  width: 56px;
  height: 56px;
  background: var(--accent-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.8rem;
  box-shadow: 0 4px 15px rgba(9, 105, 218, 0.4);
  border: 4px solid white;
}

.app-main-content {
  padding-bottom: 0;
}

/* Mobile Responsiveness Enhancements */
@media (max-width: 768px) {
  .mobile-bottom-nav {
    display: flex;
  }

  .navbar {
    position: sticky;
    top: 0;
    height: 60px;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
  }

  .nav-links, .nav-actions {
    display: none;
  }

  .app-main-content {
    padding-bottom: 80px; /* Space for bottom nav */
  }

  .hero {
    padding: 2rem 1rem;
    text-align: left;
  }

  .hero-badge {
    background: rgba(9, 105, 218, 0.1);
    color: var(--accent-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    display: inline-block;
  }

  .hero-text h1 {
    font-size: 2.2rem;
    letter-spacing: -1px;
  }

  .hero-text p {
    font-size: 1rem;
    line-height: 1.5;
  }

  .hero-btns {
    flex-direction: column;
    width: 100%;
  }

  .hero-btns .btn {
    width: 100%;
    padding: 1rem;
  }

  .btn-start-exam {
    border-radius: 12px;
    padding: 1rem !important;
  }

  .section-title {
    text-align: left;
    font-size: 1.8rem;
    margin-bottom: 1rem;
  }

  .section-subtitle {
    text-align: left !important;
    font-size: 0.9rem;
  }

  .footer {
    padding-bottom: 100px;
  }
}

/* Glassmorphism Effect for Modals on Mobile */
@media (max-width: 768px) {
  .modal-content {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-top-left-radius: 25px;
    border-top-right-radius: 25px;
    max-height: 95vh;
    margin-top: 5vh;
  }

  .modal-header {
    padding: 1.5rem;
  }
}

/* Modern "Floating Glass" Update Modal */
.update-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeInOverlay 0.4s ease;
}

.update-glass-card {
  background: rgba(255, 255, 255, 0.95);
  width: 90%;
  max-width: 440px;
  border-radius: 32px;
  padding: 2.5rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 
              0 0 40px rgba(9, 105, 218, 0.1);
  position: relative;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.3);
  animation: slideUpModal 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.update-floating-badge {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #0969da 0%, #034494 100%);
  color: white;
  padding: 0.6rem 1.5rem;
  border-radius: 50px;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 1px;
  box-shadow: 0 10px 20px rgba(9, 105, 218, 0.3);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.update-glass-title {
  font-size: 2.2rem;
  font-weight: 900;
  color: #0f172a;
  margin: 1.5rem 0 0.5rem;
  letter-spacing: -1px;
}

.update-glass-subtitle {
  color: #64748b;
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
}

.update-chip-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.update-chip {
  background: #f1f5f9;
  padding: 0.7rem 1.2rem;
  border-radius: 16px;
  font-weight: 700;
  color: #334155;
  font-size: 0.9rem;
  border: 1px solid #e2e8f0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.update-chip:hover {
  background: white;
  border-color: #0969da;
  color: #0969da;
  transform: scale(1.05);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.update-glass-btn {
  background: #0f172a;
  color: white;
  width: 100%;
  padding: 1.25rem;
  border-radius: 20px;
  font-size: 1.1rem;
  font-weight: 800;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.2);
}

.update-glass-btn:hover {
  transform: translateY(-3px);
  background: #1e293b;
  box-shadow: 0 15px 25px rgba(15, 23, 42, 0.3);
}

.update-glass-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: #f1f5f9;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #64748b;
  font-size: 1.2rem;
  transition: all 0.2s;
}

.update-glass-close:hover {
  background: #e2e8f0;
  color: #0f172a;
  transform: rotate(90deg);
}

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

@keyframes slideUpModal {
  from { opacity: 0; transform: translateY(40px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 992px) {
  .footer-content {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }
}

@media (max-width: 576px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}
