/* ========================================
   TYPIEE - LIGHT & DARK THEME SYSTEM
   Pure Black and White with Proper Contrast
   ======================================== */

@import 'auth.css';
@import 'leaderboard.css';

/* ===== THEME VARIABLES ===== */
:root {
  /* Default: Light Theme (Black & White) */
  --bg-primary: #ffffff;
  --bg-secondary: #f5f5f5;
  --bg-tertiary: #e8e8e8;
  --text-primary: #000000;
  --text-secondary: #333333;
  --text-tertiary: #666666;
  --border-color: #cccccc;
  --border-light: #dddddd;
  --accent-color: #000000;
  --accent-secondary: #333333;
  --input-bg: #ffffff;
  --input-border: #cccccc;
  --input-focus: #000000;
  --label-color: #333333;
  --button-primary: #000000;
  --button-primary-hover: #222222;
  --button-primary-text: #ffffff;
  --button-warning: #333333;
  --button-warning-text: #ffffff;
  --button-danger: #dd0000;
  --button-danger-text: #ffffff;
  --shadow: rgba(0, 0, 0, 0.1);
  --shadow-dark: rgba(0, 0, 0, 0.3);
  --stats-bg: #f0f0f0;
  --stats-border: #d0d0d0;
  --success-color: #008000;
  --success-light: #90EE90;
  --error-color: #dd0000;
}

body.dark-theme {
  /* Dark Theme */
  --bg-primary: #1a1f2e;
  --bg-secondary: #252d3d;
  --bg-tertiary: #2d3748;
  --text-primary: #e2e8f0;
  --text-secondary: #cbd5e1;
  --text-tertiary: #94a3b8;
  --border-color: #3d4455;
  --border-light: #4a5568;
  --accent-color: #60a5fa;
  --accent-secondary: #3b82f6;
  --input-bg: #1a1f2e;
  --input-border: #3d4455;
  --input-focus: #60a5fa;
  --label-color: #94a3b8;
  --button-primary: #1a1f2e;
  --button-primary-hover: #252d3d;
  --button-primary-text: #e2e8f0;
  --button-warning: #fbbf24;
  --button-warning-text: #1a1f2e;
  --button-danger: #ef4444;
  --button-danger-text: #ffffff;
  --shadow: rgba(0, 0, 0, 0.3);
  --shadow-dark: rgba(0, 0, 0, 0.6);
  --stats-bg: #1e2938;
  --stats-border: #3d4455;
  --success-color: #4ade80;
  --success-light: #22c55e;
  --error-color: #ef4444;
}

/* ===== RESET & BASE ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  transition: background-color 0.5s ease, color 0.5s ease, border-color 0.5s ease;
}


html,
body {
  width: 100%;
  height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', sans-serif;
}


body {
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow: hidden;
  transition: background-color 0.6s cubic-bezier(0.4, 0, 0.2, 1),
    color 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}


/* ===== HIDE ALL SCROLLBARS EXCEPT SELECT ===== */
*:not(select) {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

*:not(select)::-webkit-scrollbar {
  display: none;
}

/* ===== CUSTOM SCROLLBAR FOR SELECT DROPDOWN ===== */
select {
  scrollbar-width: thin;
  scrollbar-color: var(--border-light) var(--bg-secondary);
}

select::-webkit-scrollbar {
  width: 8px;
}

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

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

select::-webkit-scrollbar-thumb:hover {
  background: var(--border-color);
}


/* ===== SCREEN SYSTEM ===== */
.screen {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}


.screen.active {
  display: block;
  animation: fadeIn 0.4s ease;
}


@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes keyPressEffect {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(0.98);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes buttonClick {
  0% {
    transform: translateY(0);
    background-color: #60a5fa;
  }

  100% {
    transform: translateY(-2px);
    background-color: #3b82f6;
  }
}

@keyframes pulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(96, 165, 250, 0.7);
  }

  50% {
    box-shadow: 0 0 0 8px rgba(96, 165, 250, 0);
  }
}

@keyframes slideInStats {
  from {
    opacity: 0;
    transform: translateX(10px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes glow {

  0%,
  100% {
    text-shadow: 0 0 5px #60a5fa;
  }

  50% {
    text-shadow: 0 0 15px #60a5fa, 0 0 25px rgba(96, 165, 250, 0.6);
  }
}

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

  to {
    transform: rotate(360deg);
  }
}

@keyframes zoomPulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.15);
  }
}

/* SVG Animations */
.stat-row:nth-child(1) svg {
  animation: rotateSpin 3s linear infinite;
}

.stat-row:nth-child(1) svg:hover {
  animation: rotateSpin 2s linear infinite;
}

.stat-row:nth-child(2) svg {
  animation: zoomPulse 1.5s ease-in-out infinite;
  transition: all 0.3s ease;
}

.stat-row:nth-child(3) svg {
  animation: zoomPulse 1.5s ease-in-out infinite;
  transition: all 0.3s ease;
}

.stat-row:nth-child(3) svg.no-rotation {
  animation: none;
  opacity: 0.5;
}


/* ========================================
   SELECTION SCREEN - DARK THEME
   ======================================== */
#selectionScreen.active {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}


.container {
  background: var(--bg-secondary);
  border-radius: 20px;
  padding: 18px 24px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 20px 60px var(--shadow-dark);
  border: 1px solid var(--border-color);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}


.container h1 {
  font-size: 22px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 8px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.header-row {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin-bottom: 8px;
  width: 100%;
  gap: 12px;
}

.header-row h1 {
  margin-bottom: 0;
  font-size: 20px;
  white-space: nowrap;
  margin-right: 8px;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: auto;
  /* Pushes other items to the right on Desktop */
}

/* Header Separator: Not used in flat layout but kept for safety */
.header-separator {
  width: 1px;
  height: 28px;
  background: var(--border-color);
  margin: 0 8px;
}

.theme-toggle-btn {
  width: 36px;
  height: 36px;
  padding: 0;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.theme-toggle-btn:hover {
  background: var(--bg-primary);
  border-color: var(--input-focus);
  transform: scale(1.05);
}

.theme-toggle-btn:active {
  transform: scale(0.95);
}

/* Theme icon sizing and transition */
.theme-icon {
  width: 18px;
  height: 18px;
  position: absolute;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* Sun icon - visible in light mode, hidden in dark */
.sun-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
  color: #f59e0b;
}

/* Moon icon - hidden in light mode, visible in dark */
.moon-icon {
  opacity: 0;
  transform: rotate(-90deg) scale(0.5);
  color: #a78bfa;
}

/* Dark theme - swap icons */
.dark-theme .sun-icon {
  opacity: 0;
  transform: rotate(90deg) scale(0.5);
}

.dark-theme .moon-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

.logo-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  transition: all 0.2s;
}

.logo-icon:hover {
  transform: translateY(-2px) scale(1.05);
}

/* Profile Icon - Square */
.profile-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  /* Slightly reducing radius for smaller size */
  background: linear-gradient(135deg, var(--accent-color), var(--accent-secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.2s;
  border: 2px solid var(--border-color);
}

.profile-icon:hover {
  transform: translateY(-2px);
  border-color: var(--accent-color);
}

.profile-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-icon span {
  color: white;
  font-weight: 700;
  font-size: 16px;
  /* Slightly smaller font for 36px */
}

/* Header Separator - Uniform */
.header-separator {
  width: 1px;
  height: 28px;
  background: var(--border-color);
  margin: 0 8px;
}


.pwa-btn {
  display: block;
  margin: 0 auto 12px;
  padding: 4px 12px;
  border: none;
  border-radius: 20px;
  background: var(--button-primary);
  color: var(--button-primary-text);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.pwa-btn[hidden] {
  display: none !important;
}

.req-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--accent-color);
  background: rgba(96, 165, 250, 0.1);
  border-radius: 6px;
  flex-shrink: 0;
}

.req-icon svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
}


.pwa-btn:hover {
  background: var(--button-primary-hover);
  transform: scale(1.05);
}


/* ===== INPUT ROWS ===== */
.row {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
  align-items: center;
}


.num {
  width: 32px;
  height: 32px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  flex-shrink: 0;
  border: 1px solid var(--border-light);
}


.field {
  flex: 1;
}


.field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--label-color);
  margin-bottom: 4px;
}


.field select {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--input-border);
  border-radius: 8px;
  background: var(--input-bg);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  max-height: 200px;
  overflow-y: auto;
}


.field select:focus {
  outline: none;
  border-color: var(--input-focus);
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.2);
}


.field select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}


#testSelect {
  background: var(--input-bg) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--input-border) !important;
  font-weight: 500 !important;
}


#testSelect option {
  background: var(--bg-secondary) !important;
  color: var(--text-primary) !important;
}


/* ===== EXAM REQUIREMENTS ===== */
.exam-requirements {
  display: flex;
  gap: 8px;
  padding: 10px 12px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  margin-bottom: 12px;
}


.req-icon {
  font-size: 18px;
  flex-shrink: 0;
}


.req-content {
  flex: 1;
}


.req-content strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}


.req-content p {
  font-size: 11px;
  color: var(--text-secondary);
  margin: 0;
}


/* ===== START BUTTON - SPACE KEY STYLE ===== */
#startBtn,
.space-key-btn {
  width: 100%;
  padding: 16px 24px;
  margin-top: 10px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(180deg,
      var(--button-primary) 0%,
      color-mix(in srgb, var(--button-primary) 85%, black) 100%);
  color: var(--button-primary-text);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.1s ease;
  position: relative;

  /* 3D Keyboard Key Effect */
  box-shadow:
    0 6px 0 color-mix(in srgb, var(--button-primary) 60%, black),
    0 8px 15px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transform: translateY(0);
}

#startBtn::before,
.space-key-btn::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 8px;
  right: 8px;
  height: 40%;
  background: linear-gradient(180deg,
      rgba(255, 255, 255, 0.15) 0%,
      transparent 100%);
  border-radius: 10px 10px 50% 50%;
  pointer-events: none;
}

#startBtn:hover,
.space-key-btn:hover {
  background: linear-gradient(180deg,
      var(--button-primary-hover) 0%,
      color-mix(in srgb, var(--button-primary-hover) 85%, black) 100%);
  box-shadow:
    0 6px 0 color-mix(in srgb, var(--button-primary-hover) 60%, black),
    0 10px 20px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

#startBtn:active,
.space-key-btn:active {
  transform: translateY(4px);
  box-shadow:
    0 2px 0 color-mix(in srgb, var(--button-primary) 60%, black),
    0 4px 8px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}


/* ===== COMPLETED LIST ===== */
.completed {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border-color);
}


.completed h3 {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-tertiary);
  margin-bottom: 6px;
}


.list {
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  max-height: 100px;
  overflow-y: auto;
}


.item {
  padding: 8px 12px;
  font-size: 12px;
  color: var(--text-tertiary);
  border-bottom: 1px solid var(--border-color);
}

.item:hover {
  background: var(--bg-tertiary);
}

.item:last-child {
  border-bottom: none;
}


/* ========================================
   TYPING SCREEN - DARK THEME
   ======================================== */
#typingScreen.active {
  display: flex;
}


.main-layout {
  display: flex;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}


/* ===== LEFT PANEL - DARK ===== */
.left-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
  overflow: hidden;
  transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}


/* ===== PARAGRAPH DISPLAY ===== */
.paragraph-display {
  flex: 1;
  padding: 30px 50px;
  font-size: 20px;
  line-height: 1.9;
  color: var(--text-secondary);
  overflow-y: auto;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
}


.menu-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  background: var(--bg-secondary);
  color: var(--text-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 20px;
  cursor: pointer;
  display: none;
  transition: all 0.2s;
  z-index: 10;
}


.menu-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}


.menu-btn.hidden {
  opacity: 0;
  pointer-events: none;
}


.line {
  margin-bottom: 12px;
}


.word {
  display: inline;
  padding: 2px 0;
  transition: all 0.15s;
}


.word.current {
  background: var(--bg-secondary);
  border-bottom: 3px solid var(--accent-color);
  padding: 2px 4px;
}


.word.correct {
  color: var(--success-color);
}


.word.incorrect {
  color: var(--error-color);
  text-decoration: line-through;
}


/* ===== SEPARATOR ===== */
.separator {
  height: 1px;
  background: var(--border-color);
  margin: 0 50px;
  flex-shrink: 0;
}


/* ===== TYPING INPUT ===== */
.typed-wrapper {
  padding: 20px 50px 30px;
  background: var(--bg-secondary);
  flex-shrink: 0;
  border-top: 1px solid var(--border-color);
}


.typed-input {
  width: 100%;
  padding: 16px 18px;
  border: 2px solid var(--input-border);
  border-radius: 12px;
  background: var(--input-bg);
  font-size: 20px;
  line-height: 1.9;
  color: var(--text-primary);
  font-family: inherit;
  resize: none;
  height: 140px;
  outline: none;
  transition: all 0.25s ease;
}


.typed-input:focus {
  border-color: var(--input-focus);
  background: var(--bg-primary);
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.2);
}


.typed-input.wrong-word {
  animation: shake 0.3s;
  border-color: var(--error-color);
}

.typed-input.key-pressed {
  animation: keyPressEffect 0.15s ease-out;
  border-color: var(--input-focus);
  box-shadow: 0 0 12px rgba(96, 165, 250, 0.3);
}


@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-4px);
  }

  75% {
    transform: translateX(4px);
  }
}


/* ========================================
   RIGHT PANEL - DARK SIDEBAR
   ======================================== */
.right-panel {
  width: 260px;
  background: var(--bg-secondary);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
  box-shadow: -4px 0 20px var(--shadow-dark);
  flex-shrink: 0;
  border-left: 1px solid var(--border-color);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}


.close-btn {
  display: none;
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: none;
  border-radius: 6px;
  font-size: 16px;
  cursor: pointer;
  z-index: 10;
}


/* ===== TIME DISPLAY ===== */
.time-section {
  background: var(--stats-bg);
  border: 1px solid var(--stats-border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 2px 8px var(--shadow);
  transition: all 0.3s ease;
}

.time-section:hover {
  border-color: var(--accent-color);
  box-shadow: 0 4px 16px var(--shadow);
}

.time-section .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-tertiary);
  font-weight: 600;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.time-section .label svg {
  color: var(--accent-color);
  stroke-linecap: round;
  stroke-linejoin: round;
}

.time-section .value {
  font-size: 36px;
  font-weight: 700;
  font-family: 'Courier New', monospace;
  color: var(--text-primary);
  transition: all 0.2s ease;
}


/* ===== LIVE STATS CARD ===== */
.live-stats-card {
  background: var(--stats-bg);
  border: 1px solid var(--stats-border);
  border-radius: 12px;
  padding: 14px;
  box-shadow: 0 2px 8px var(--shadow);
  transition: all 0.3s ease;
}

.live-stats-card:hover {
  border-color: var(--accent-color);
  box-shadow: 0 4px 16px var(--shadow);
}

.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  transition: all 0.2s ease;
}


.stat-row:not(:last-child) {
  border-bottom: 1px solid var(--stats-border);
}


.stat-label {
  font-size: 12px;
  color: var(--text-tertiary);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.stat-label svg {
  color: var(--accent-color);
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stat-row:hover .stat-label svg {
  color: var(--accent-secondary);
}


.stat-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  transition: all 0.3s ease;
}

.stat-value:hover {
  animation: slideInStats 0.3s ease;
}

/* WPM Color States */
.live-wpm {
  color: #4ade80;
  transition: all 0.4s ease;
}

.live-wpm:hover {
  color: #22c55e;
  text-shadow: 0 0 8px rgba(34, 197, 94, 0.4);
}

.live-wpm.wpm-excellent {
  color: #10b981;
  text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

.live-wpm.wpm-good {
  color: #4ade80;
  text-shadow: 0 0 8px rgba(74, 222, 128, 0.4);
}

.live-wpm.wpm-fair {
  color: #f59e0b;
  text-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

.live-wpm.wpm-poor {
  color: #ef4444;
  text-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

/* Accuracy Color States */
#liveAccuracy {
  transition: all 0.4s ease;
  color: #4ade80;
}

#liveAccuracy.accuracy-excellent {
  color: #10b981;
  text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

#liveAccuracy.accuracy-good {
  color: #4ade80;
  text-shadow: 0 0 8px rgba(74, 222, 128, 0.4);
}

#liveAccuracy.accuracy-fair {
  color: #f59e0b;
  text-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

#liveAccuracy.accuracy-poor {
  color: #ef4444;
  text-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

.streak-row {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 10px 12px;
  margin-top: 8px;
  transition: all 0.3s ease;
}

/* Streak Color States */
.streak-value {
  color: #94a3b8;
  font-size: 20px;
  transition: all 0.4s ease;
}

.streak-value.streak-low {
  color: #94a3b8;
  opacity: 0.7;
}

.streak-value.streak-medium {
  color: #f59e0b;
  text-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

.streak-value.streak-high {
  color: #4ade80;
  text-shadow: 0 0 10px rgba(74, 222, 128, 0.5);
}

.streak-value.streak-fire {
  color: #f97316;
  text-shadow: 0 0 12px rgba(249, 115, 22, 0.6);
  animation: pulse 0.8s ease-in-out infinite;
}

/* Timer Color Warning */
.time-section .value {
  transition: all 0.3s ease;
  color: #000000;
}

.time-section.time-warning {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.05);
  animation: warningPulse 1s ease-in-out infinite;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.3);
}

.time-section.time-warning .label {
  color: #ef4444;
}

.time-section.time-warning .value {
  color: #ef4444;
  text-shadow: 0 0 12px rgba(239, 68, 68, 0.6);
}

.time-section.time-warning .label svg {
  color: #ef4444;
  animation: warningPulse 1s ease-in-out infinite;
}

@keyframes warningPulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}


/* ===== PROGRESS CIRCLE - PERFECTLY CENTERED ===== */
.progress-circle-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px 0;
  width: 100%;
  flex-shrink: 0;
  min-height: 170px;
}

.progress-circle {
  display: block;
  transform: rotate(-90deg);
  margin: 0 auto;
}


.progress-bg {
  fill: none;
  stroke: var(--border-light);
  stroke-width: 8;
}


.progress-bar {
  fill: none;
  stroke: #4ade80;
  stroke-width: 8;
  stroke-linecap: round;
  stroke-dasharray: 408;
  stroke-dashoffset: 408;
  transition: stroke 0.6s ease, stroke-dashoffset 0.4s ease;
}

.progress-bar.progress-warning {
  stroke: #f59e0b;
}

.progress-bar.progress-danger {
  stroke: #ef4444;
  animation: pulse 1s ease-in-out infinite;
}


.progress-text {
  fill: var(--text-primary);
  font-size: 22px;
  font-weight: 700;
  text-anchor: middle;
  transform: rotate(90deg);
  transform-origin: center;
}


/* ===== SOUND TOGGLE ===== */
.control-row {
  background: var(--stats-bg);
  border: 1px solid var(--stats-border);
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 8px var(--shadow);
}


.control-label {
  font-size: 13px;
  color: var(--text-secondary);
  font-weight: 600;
}


.toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
}


.toggle-switch input {
  display: none;
}


.toggle-slider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--border-light);
  border-radius: 24px;
  cursor: pointer;
  transition: 0.3s;
}


.toggle-slider:before {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  bottom: 3px;
  background: var(--text-primary);
  border-radius: 50%;
  transition: 0.3s;
}


input:checked+.toggle-slider {
  background: #4ade80;
}


input:checked+.toggle-slider:before {
  transform: translateX(20px);
  background: #ffffff;
}


/* ===== BUTTONS ===== */
.btn {
  width: 100%;
  padding: 11px;
  border: none;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.2s ease,
    background-color 0.2s ease,
    color 0.2s ease;
  box-shadow: 0 2px 6px var(--shadow);
}


.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px var(--shadow-dark);
}


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


.btn-warning {
  background: var(--button-warning);
  color: var(--button-warning-text);
}

.btn-warning:hover {
  background: #999999;
  color: #ffffff;
}

.btn-warning:active {
  background: #777777;
}


.btn-primary {
  background: var(--button-primary);
  color: var(--button-primary-text);
}

.btn-primary:hover {
  background: var(--button-primary-hover);
  box-shadow: 0 6px 20px var(--shadow);
}

.btn-primary:active {
  background: #111111;
  opacity: 0.9;
}


.btn-secondary {
  background: var(--border-light);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--border-color);
}

.btn-secondary:active {
  background: #999999;
}

.btn-danger {
  background: var(--button-danger);
  color: var(--button-danger-text);
  border: 1px solid var(--error-color);
}

.btn-danger:hover {
  background: #bb0000;
  box-shadow: 0 6px 20px var(--shadow);
}

.btn-danger:active {
  background: #880000;
}

/* ===== DARK THEME BUTTON OVERRIDES ===== */
body.dark-theme .btn-primary {
  background: #1a1f2e;
  color: #e2e8f0;
  border: 1px solid #3d4455;
}

body.dark-theme .btn-primary:hover {
  background: #252d3d;
  border-color: #60a5fa;
}

body.dark-theme .btn-primary:active {
  background: #1a1f2e;
  border-color: #60a5fa;
  opacity: 0.7;
}

/* ========================================
   PAUSE OVERLAY
   ======================================== */
.pause-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  z-index: 3000;
  align-items: center;
  justify-content: center;
}


.pause-overlay.show {
  display: flex;
}


.pause-content {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border: 2px solid var(--accent-color);
  padding: 50px 70px;
  border-radius: 24px;
  text-align: center;
  box-shadow: 0 25px 80px var(--shadow), 0 0 60px var(--shadow);
  position: relative;
  animation: scaleIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-width: 500px;
}

.pause-content::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-secondary), var(--accent-color));
  z-index: -1;
  opacity: 0.2;
  animation: glow 3s ease-in-out infinite;
}

@keyframes scaleIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.pause-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 30px;
  padding: 20px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  border: 1px solid rgba(96, 165, 250, 0.2);
}

.pause-stat-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  text-align: center;
}

.pause-stat-label {
  font-size: 11px;
  color: var(--text-tertiary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.pause-stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--accent-color);
  font-family: 'Courier New', monospace;
}

.pause-icon {
  font-size: 56px;
  margin-bottom: 20px;
  animation: bounce 1.2s ease-in-out infinite;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100px;
  height: 100px;
  margin-left: auto;
  margin-right: auto;
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.15), rgba(96, 165, 250, 0.05));
  border: 2px solid rgba(96, 165, 250, 0.2);
  border-radius: 16px;
}

.pause-icon svg {
  width: 56px;
  height: 56px;
  color: var(--accent-color);
  stroke: currentColor;
  fill: currentColor;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

@keyframes bounce {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

.pause-content h2 {
  font-size: 32px;
  margin-bottom: 12px;
  color: var(--accent-color);
  font-weight: 700;
}


.pause-content p {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 30px;
  font-weight: 500;
}


/* ========================================
   POPUP
   ======================================== */
.popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}


.popup.show {
  display: flex;
}


.popup-box {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  padding: 35px 55px;
  border-radius: 20px;
  text-align: center;
  box-shadow: 0 20px 60px var(--shadow-dark);
}


.popup-box h2 {
  font-size: 24px;
  margin-bottom: 8px;
  color: var(--text-primary);
}


.popup-box p {
  font-size: 14px;
  color: var(--text-tertiary);
  margin-bottom: 20px;
}


/* ========================================
   RESULTS SCREEN - DARK THEME
   ======================================== */
#resultsScreen {
  padding: 0;
  overflow: hidden;
}


#resultsScreen.active {
  display: block;
  background: var(--bg-primary);
}


.results-layout {
  display: flex;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  gap: 20px;
  padding: 20px;
}


/* ===== RESULTS LEFT ===== */
.results-left {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 25px 30px;
  overflow-y: auto;
  box-shadow: 0 10px 40px var(--shadow-dark);
}


.results-left h1 {
  font-size: 24px;
  margin-bottom: 16px;
  color: var(--text-primary);
}


/* ===== STATUS BOX - BRIGHT & CLEAR ===== */
.status-box {
  display: flex;
  gap: 12px;
  padding: 14px 16px;
  background: var(--error-color);
  border: 3px solid var(--error-color);
  border-radius: 10px;
  margin-bottom: 16px;
  box-shadow: 0 0 25px rgba(239, 68, 68, 0.8);
}

.status-box.pass {
  background: var(--success-color);
  border: 3px solid var(--success-color);
  box-shadow: 0 0 25px rgba(74, 222, 128, 0.8);
}

.status-box .icon {
  font-size: 24px;
  color: #ffffff;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
  font-weight: bold;
}

.status-box.pass .icon {
  color: #ffffff;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}


.status-box strong {
  display: block;
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  letter-spacing: 0.5px;
}

.status-box.pass strong {
  color: #ffffff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}


.status-box p {
  font-size: 13px;
  color: #ffffff;
  margin: 0;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.status-box.pass p {
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}


/* ===== STATS TABLE ===== */
.stats-table {
  width: 100%;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 0;
  margin-bottom: 16px;
  background: linear-gradient(to bottom, rgba(60, 82, 125, 0.1), rgba(96, 165, 250, 0.05));
  border-radius: 8px;
  transition: all 0.3s ease;
}

.stats-table:hover {
  background: linear-gradient(to bottom, rgba(60, 82, 125, 0.15), rgba(96, 165, 250, 0.1));
  border-color: var(--accent-color);
}

.stats-table tr {
  display: flex;
  justify-content: space-between;
  padding: 10px 12px;
  font-size: 13px;
  transition: all 0.2s ease;
  border-radius: 4px;
}

.stats-table tr:hover {
  background: rgba(96, 165, 250, 0.08);
}

.stats-table td:first-child {
  font-weight: 600;
  color: var(--text-tertiary);
}


.stats-table td:last-child {
  font-weight: 700;
  color: var(--accent-color);
  text-shadow: 0 0 8px rgba(96, 165, 250, 0.3);
}


/* ===== CHARTS ===== */
.results-left h3 {
  font-size: 15px;
  font-weight: 700;
  margin: 16px 0 10px;
  color: var(--text-secondary);
}


.chart-container {
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px;
  min-height: 140px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 6px;
  margin-bottom: 12px;
}


.chart-bar {
  width: 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.2s ease;
}

.chart-bar:hover {
  transform: scale(1.1);
}

.bar {
  width: 100%;
  background: linear-gradient(180deg, #4ade80, #22c55e);
  border-radius: 4px 4px 0 0;
  transition: all 0.3s;
  box-shadow: 0 -2px 8px rgba(74, 222, 128, 0.3);
}


.bar:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 12px rgba(74, 222, 128, 0.5);
}


.bar.red {
  background: linear-gradient(180deg, #f87171, #ef4444);
  box-shadow: 0 -2px 8px rgba(239, 68, 68, 0.3);
}

.bar.red:hover {
  box-shadow: 0 2px 12px rgba(239, 68, 68, 0.5);
}

.bar-label {
  font-size: 11px;
  font-weight: 700;
  margin-top: 4px;
  color: #94a3b8;
}


/* ===== RESULTS RIGHT ===== */
.results-right {
  width: 280px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 25px 20px;
  overflow-y: auto;
  box-shadow: 0 10px 40px var(--shadow-dark);
  flex-shrink: 0;
}


.comment-header {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
}


.comment-body p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  padding: 10px 12px;
  background: var(--bg-tertiary);
  border-radius: 8px;
  border-left: 3px solid var(--accent-color);
  margin-bottom: 8px;
}


/* ===== OVERLAY ===== */
.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 999;
}


.overlay.show {
  display: block;
}


/* ========================================
   RESPONSIVE - Mobile Adjustments
   ======================================== */
@media (max-width: 768px) {
  .main-layout {
    flex-direction: column;
  }


  .left-panel {
    height: 65vh;
  }


  .right-panel {
    width: 100%;
    height: 35vh;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
  }


  .menu-btn {
    display: flex;
  }


  .results-layout {
    flex-direction: column;
    height: auto;
    overflow-y: auto;
  }


  .results-right {
    width: 100%;
  }
}


/* ========================================
   PROFILE MODAL - PREMIUM DESIGN
   ======================================== */

/* Profile Modal Overlay */
#profileModal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  padding: 20px;
  overflow-y: auto;
}

#profileModal.show {
  display: flex;
  animation: fadeIn 0.3s ease;
}

/* Profile Card */
.profile-card {
  background: var(--bg-secondary);
  border-radius: 20px;
  padding: 24px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-color);
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}



/* Close Button */
.close-profile-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: var(--text-tertiary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  z-index: 10;
}

.close-profile-btn:hover {
  color: var(--text-primary);
  transform: scale(1.1);
  background: var(--bg-tertiary);
  border-radius: 8px;
  /* Rounded square instead of circle */
}

/* Profile Header */
.profile-header {
  text-align: center;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}

.profile-avatar-large {
  width: 90px;
  height: 90px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(96, 165, 250, 0.3);
  border: 3px solid var(--bg-primary);
}

.profile-avatar-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-avatar-large #profileInitials {
  font-size: 36px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
}

#profileName {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.profile-since {
  font-size: 12px;
  color: var(--text-tertiary);
  margin: 0;
}

/* Stats Grid */
.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.profile-stat {
  background: var(--bg-tertiary);
  border-radius: 12px;
  padding: 14px 8px;
  text-align: center;
  border: 1px solid var(--border-color);
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.profile-stat:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--shadow);
}

.profile-stat .stat-icon {
  width: 28px;
  height: 28px;
  margin: 0 auto 8px;
  color: var(--accent-color);
}

.profile-stat .stat-icon svg {
  width: 100%;
  height: 100%;
}

.profile-stat .stat-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.profile-stat .stat-label {
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Profile Sections */
.profile-section {
  margin-bottom: 20px;
}

.section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title svg {
  width: 18px;
  height: 18px;
  color: var(--accent-color);
}

/* Personal Bests - Premium Style */
.personal-bests {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.best-item {
  background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.best-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent-color);
  opacity: 0.5;
}

.best-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  border-color: var(--accent-color);
}

.best-label {
  display: block;
  font-size: 11px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
  font-weight: 600;
}

.best-value {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
}

/* Improvement Cards - Premium Style */
.improvement-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.improvement-card {
  background: var(--bg-tertiary);
  border-radius: 16px;
  padding: 18px;
  text-align: center;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.improvement-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.improvement-card.positive {
  border-color: rgba(16, 185, 129, 0.3);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, var(--bg-tertiary) 100%);
}

.improvement-card.negative {
  border-color: rgba(239, 68, 68, 0.3);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, var(--bg-tertiary) 100%);
}

.improvement-arrow {
  font-size: 16px;
  font-weight: 700;
  display: inline-block;
  margin-right: 4px;
  vertical-align: middle;
}

.positive .improvement-arrow,
.positive .improvement-value {
  color: #10b981;
}

.negative .improvement-arrow,
.negative .improvement-value {
  color: #ef4444;
}

.improvement-value {
  font-size: 20px;
  font-weight: 700;
  display: inline-block;
  vertical-align: middle;
}

.improvement-label {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 6px;
  display: block;
}

/* Badges Grid - SHINING EFFECT */
.badges-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.badge-item {
  position: relative;
  background: var(--bg-tertiary);
  border-radius: 12px;
  padding: 12px 8px;
  text-align: center;
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: all 0.3s;
}

.badge-item.locked {
  opacity: 0.5;
  filter: grayscale(1);
}

.badge-item.earned {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.15), var(--bg-tertiary));
  border-color: var(--accent-color);
}

/* Shining Animation for Earned Badges */
.badge-item.earned::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg,
      transparent 30%,
      rgba(255, 255, 255, 0.15) 50%,
      transparent 70%);
  animation: badgeShine 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes badgeShine {
  0% {
    transform: translateX(-100%) rotate(45deg);
  }

  50%,
  100% {
    transform: translateX(100%) rotate(45deg);
  }
}

.badge-icon {
  width: 36px;
  height: 36px;
  margin: 0 auto 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-secondary));
  box-shadow: 0 4px 12px rgba(96, 165, 250, 0.3);
}

.badge-icon svg {
  width: 20px;
  height: 20px;
  color: white;
  stroke: white;
  fill: none;
}

.badge-item.locked .badge-icon {
  background: var(--bg-secondary);
  box-shadow: none;
}

.badge-item.locked .badge-icon svg {
  color: var(--text-tertiary);
  stroke: var(--text-tertiary);
}

.badge-name {
  font-size: 9px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px var(--shadow);
}

/* Badge Tooltip */
.badge-item[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-5px);
  background: var(--text-primary);
  color: var(--bg-primary);
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 10px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s;
  z-index: 100;
}

.badge-item:hover[data-tooltip]::after {
  opacity: 1;
  transform: translateX(-50%) translateY(-10px);
}

/* Challenge Card */
.challenge-card {
  background: var(--bg-tertiary);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid var(--border-color);
}

.challenge-title {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.challenge-progress-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-secondary);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 8px;
}

.challenge-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-color), var(--success-color));
  border-radius: 4px;
  transition: width 0.5s ease;
}

.challenge-status {
  font-size: 12px;
  color: var(--text-tertiary);
}

/* Profile Settings */
.profile-settings {
  background: var(--bg-tertiary);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 20px;
  border: 1px solid var(--border-color);
}

.setting-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.setting-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.setting-label svg {
  width: 18px;
  height: 18px;
  color: var(--text-tertiary);
}

/* Profile Action Buttons */
.profile-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.profile-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid var(--border-color);
}

.profile-btn svg {
  width: 18px;
  height: 18px;
}

.cert-btn {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  border-color: #d97706;
}

.cert-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.share-btn {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.share-btn:hover {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
  transform: translateY(-2px);
}

/* Recent Tests List */
.recent-tests-list {
  background: var(--bg-tertiary);
  border-radius: 12px;
  border: 1px solid var(--border-color);
  max-height: 180px;
  overflow-y: auto;
}

.no-tests {
  padding: 20px;
  text-align: center;
  color: var(--text-tertiary);
  font-size: 13px;
}

.recent-test-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s;
}

.recent-test-item:last-child {
  border-bottom: none;
}

.recent-test-item:hover {
  background: var(--bg-secondary);
}

.test-info {
  flex: 1;
}

.test-date {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-bottom: 2px;
}

.test-duration {
  font-size: 12px;
  color: var(--text-secondary);
}

.test-stats {
  display: flex;
  gap: 12px;
  text-align: right;
}

.test-wpm,
.test-acc {
  font-size: 13px;
  font-weight: 600;
}

.test-wpm {
  color: var(--accent-color);
}

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

/* Make profile icon clickable */
#userProfileIcon {
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

#userProfileIcon:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(96, 165, 250, 0.3);
}

/* Special Badge Colors */
.badge-speed .badge-icon {
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.badge-accuracy .badge-icon {
  background: linear-gradient(135deg, #10b981, #34d399);
}

.badge-marathon .badge-icon {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.badge-perfect .badge-icon {
  background: linear-gradient(135deg, #ec4899, #f472b6);
}

.badge-streak .badge-icon {
  background: linear-gradient(135deg, #ef4444, #f87171);
}

.badge-consistent .badge-icon {
  background: linear-gradient(135deg, #3b82f6, #60a5fa);
}

.badge-early .badge-icon {
  background: linear-gradient(135deg, #f97316, #fb923c);
}

.badge-night .badge-icon {
  background: linear-gradient(135deg, #6366f1, #818cf8);
}

/* ===== DAILY TASKS STYLING ===== */
.daily-reset-timer {
  margin-left: auto;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-tertiary);
  background: var(--bg-tertiary);
  padding: 4px 10px;
  border-radius: 12px;
}

.daily-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.daily-task {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-tertiary);
  border-radius: 10px;
  border: 1px solid var(--border-color);
  transition: all 0.2s;
}

.daily-task.completed {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.05));
  border-color: rgba(16, 185, 129, 0.3);
}

.daily-task .task-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

.daily-task.completed .task-icon {
  background: #10b981;
  border-color: #10b981;
  color: white;
}

.daily-task .task-info {
  flex: 1;
}

.daily-task .task-title {
  font-weight: 600;
  font-size: 13px;
  color: var(--text-primary);
}

.daily-task .task-desc {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

.daily-task .task-count {
  font-size: 11px;
  color: var(--accent-color);
  font-weight: 600;
  margin-top: 4px;
}

.daily-task .task-progress-bar {
  width: 60px;
  height: 6px;
  background: var(--bg-primary);
  border-radius: 3px;
  overflow: hidden;
  flex-shrink: 0;
}

.daily-task .task-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-color), var(--accent-secondary));
  border-radius: 3px;
  transition: width 0.3s ease;
}

.daily-task.completed .task-progress-fill {
  background: #10b981;
}

/* ===== BADGE TOOLTIP (Hover Info) ===== */
.badge-item {
  position: relative;
  cursor: pointer;
}

.badge-item .badge-tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 10px 12px;
  min-width: 180px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  z-index: 100;
  pointer-events: none;
}

.badge-item:hover .badge-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(-4px);
}

.badge-tooltip .tooltip-title {
  font-weight: 700;
  font-size: 13px;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.badge-tooltip .tooltip-desc {
  font-size: 11px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.badge-tooltip .tooltip-criteria {
  font-size: 10px;
  color: var(--accent-color);
  font-weight: 600;
  padding: 4px 8px;
  background: rgba(96, 165, 250, 0.1);
  border-radius: 4px;
  display: inline-block;
}

.badge-tooltip .tooltip-progress {
  margin-top: 8px;
  height: 4px;
  background: var(--bg-tertiary);
  border-radius: 2px;
  overflow: hidden;
}

.badge-tooltip .tooltip-progress-fill {
  height: 100%;
  background: var(--accent-color);
  border-radius: 2px;
}

.badge-tooltip .tooltip-season {
  margin-top: 6px;
  font-size: 10px;
  color: var(--text-tertiary);
  font-style: italic;
}

/* Badge Category Colors */
.badge-item[data-category="streak"] .badge-icon {
  background: linear-gradient(135deg, #3b82f6, #60a5fa);
}

.badge-item[data-category="accuracy"] .badge-icon {
  background: linear-gradient(135deg, #10b981, #34d399);
}

.badge-item[data-category="speed"] .badge-icon {
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.badge-item[data-category="endurance"] .badge-icon {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.badge-item[data-category="time"] .badge-icon {
  background: linear-gradient(135deg, #ec4899, #f472b6);
}

.badge-item[data-category="milestone"] .badge-icon {
  background: linear-gradient(135deg, #06b6d4, #22d3ee);
}

.badge-item[data-category="recovery"] .badge-icon {
  background: linear-gradient(135deg, #ef4444, #f87171);
}

.badge-item[data-category="leaderboard"] .badge-icon {
  background: linear-gradient(135deg, #f97316, #fb923c);
}

.badge-item[data-category="special"] .badge-icon {
  background: linear-gradient(135deg, #6366f1, #818cf8);
}

/* ===== ACHIEVEMENTS BUTTON ===== */
.achievements-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: linear-gradient(135deg, var(--bg-tertiary), var(--bg-secondary));
  border: 1px solid var(--border-color);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.achievements-btn:hover {
  border-color: var(--accent-color);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.achievements-btn-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.achievements-btn-icon svg {
  width: 24px;
  height: 24px;
  color: white;
  stroke: white;
}

.achievements-btn-info {
  flex: 1;
  text-align: left;
}

.achievements-btn-title {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.achievements-btn-count {
  display: block;
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

/* ===== DAILY TASKS ===== */
.daily-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}

.daily-task {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.daily-task:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);
}

.daily-task.completed {
  border-color: var(--accent-color);
  background: rgba(96, 165, 250, 0.05);
}

.task-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.daily-task.completed .task-icon {
  background: var(--accent-color);
  color: white;
}

.task-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.task-info {
  flex: 1;
}

.task-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.task-desc {
  font-size: 11px;
  color: var(--text-tertiary);
}

.task-count {
  font-size: 11px;
  color: var(--accent-color);
  font-weight: 600;
  margin-top: 2px;
}

.task-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: transparent;
}

.task-progress-fill {
  height: 100%;
  background: var(--accent-color);
  width: 0%;
  transition: width 0.5s ease;
}

.achievements-btn-arrow {
  width: 20px;
  height: 20px;
  color: var(--text-tertiary);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.achievements-btn:hover .achievements-btn-arrow {
  transform: translateX(4px);
  color: var(--accent-color);
}

/* ===== ACHIEVEMENTS MODAL ===== */
.achievements-card {
  width: 90%;
  max-width: 600px;
  max-height: 85vh;
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.achievements-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-tertiary);
}

.achievements-header h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  flex: 1;
}

.achievements-header h2 svg {
  width: 24px;
  height: 24px;
  color: var(--accent-color);
}

.achievements-progress {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-color);
  background: rgba(96, 165, 250, 0.1);
  padding: 6px 12px;
  border-radius: 20px;
}

.close-achievements-btn {
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: var(--text-tertiary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.close-achievements-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-radius: 8px;
}

.achievements-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
}

/* Badge Categories */
.badge-category {
  margin-bottom: 24px;
}

.badge-category:last-child {
  margin-bottom: 0;
}

.category-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-secondary);
  margin: 0 0 12px 0;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-color);
}

/* Badges Grid inside modal */
.achievements-content .badges-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(85px, 1fr));
  gap: 10px;
}

.achievements-content .badge-item {
  padding: 10px 8px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  text-align: center;
  transition: all 0.2s;
  position: relative;
  cursor: pointer;
  opacity: 0.5;
}

.achievements-content .badge-item.earned {
  opacity: 1;
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.1), var(--bg-tertiary));
  border-color: var(--accent-color);
}

.achievements-content .badge-icon {
  width: 32px;
  height: 32px;
  margin: 0 auto 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.achievements-content .badge-icon svg {
  width: 18px;
  height: 18px;
  stroke: white;
}

.achievements-content .badge-name {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-secondary);
  line-height: 1.2;
}

/* Badge Tooltip */
/* Global Tooltip (JS positioned) */
.global-tooltip {
  position: fixed;
  /* Fixed to viewport to avoid clipping */
  z-index: 10000;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  padding: 12px;
  border-radius: 12px;
  width: 200px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  text-align: left;
}

.global-tooltip.visible {
  opacity: 1;
  visibility: visible;
}

.tooltip-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.tooltip-desc {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
  line-height: 1.4;
}

.tooltip-criteria {
  font-size: 11px;
  color: var(--accent-color);
  font-weight: 600;
  background: rgba(96, 165, 250, 0.1);
  padding: 4px 8px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 8px;
}

.tooltip-progress {
  width: 100%;
  height: 4px;
  background: var(--bg-secondary);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 4px;
}

.tooltip-progress-fill {
  height: 100%;
  background: var(--accent-color);
  width: 0%;
}

.tooltip-season {
  font-size: 10px;
  color: var(--text-tertiary);
  margin-top: 6px;
  font-style: italic;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
  .profile-icon {
    width: 44px;
    height: 44px;
  }
}

/* ===== DAILY CLAIM SECTION ===== */
.daily-claim-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
  border-radius: 12px;
  margin-bottom: 12px;
  border: 1px solid var(--border-color);
}

.daily-claim-streak {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(0, 0, 0, 0.2);
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid var(--border-color);
}

.streak-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.streak-value {
  font-size: 16px;
  font-weight: 800;
  color: #FF6B6B;
  display: flex;
  align-items: center;
  gap: 4px;
}

.streak-value::before {
  content: '🔥';
  font-size: 16px;
  animation: flamePulse 1.5s infinite;
}

@keyframes flamePulse {
  0% {
    transform: scale(1);
    filter: brightness(100%);
  }

  50% {
    transform: scale(1.2);
    filter: brightness(120%);
  }

  100% {
    transform: scale(1);
    filter: brightness(100%);
  }
}

.daily-claim-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
  border: none;
  border-radius: 25px;
  color: #1a1a1a;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.daily-claim-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.5);
}

.daily-claim-btn:disabled {
  background: var(--bg-tertiary);
  color: var(--text-tertiary);
  cursor: not-allowed;
  box-shadow: none;
}

.daily-claim-btn svg {
  width: 16px;
  height: 16px;
}

/* ===== DAILY TASKS LIST ===== */
.daily-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.daily-task {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.daily-task:hover {
  transform: translateX(4px);
  border-color: var(--accent-color);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.daily-task.completed {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), var(--bg-tertiary));
  border-color: rgba(16, 185, 129, 0.3);
}

.task-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
  background: var(--bg-primary);
  color: var(--text-tertiary);
  border: 2px solid var(--border-color);
}

.daily-task.completed .task-icon {
  background: #10B981;
  color: white;
  border-color: #10B981;
}

.task-info {
  flex: 1;
}

.task-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.task-desc {
  font-size: 11px;
  color: var(--text-tertiary);
}

.task-count {
  font-size: 10px;
  color: var(--accent-color);
  font-weight: 600;
  margin-top: 2px;
}

.task-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(0, 0, 0, 0.1);
}

.task-progress-fill {
  height: 100%;
  background: var(--accent-color);
  transition: width 0.5s ease;
}

.daily-task.completed .task-progress-fill {
  background: #10B981;
}

/* ===== PUBLIC BADGE INFO MODAL ===== */
#publicBadgeInfoModal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 10000;
  padding: 20px;
}

.badge-info-card {
  background: var(--bg-primary);
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 30px;
  max-width: 350px;
  box-shadow: 0 10px 40px var(--shadow-dark);
  position: relative;
  animation: slideUp 0.3s ease-out;
}

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

.close-badge-info-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: none;
  border: none;
  font-size: 28px;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.close-badge-info-btn:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.badge-info-content {
  text-align: center;
}

.badge-info-icon {
  font-size: 60px;
  margin-bottom: 15px;
  display: block;
}

.badge-info-card h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 10px 0;
}

.badge-info-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 12px 0;
  line-height: 1.4;
}

.badge-info-stats {
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid var(--border-light);
}

.badge-info-criteria {
  margin: 18px 0;
  padding: 12px;
  background: var(--bg-secondary);
  border-radius: 8px;
  border-left: 3px solid var(--accent-color);
}

.criteria-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.criteria-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

.criteria-value {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-color);
  background: var(--bg-primary);
  padding: 4px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.progress-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.progress-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.progress-bar-small {
  width: 100%;
  height: 8px;
  background: var(--bg-tertiary);
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #4CAF50, #81C784);
  border-radius: 4px;
  transition: width 0.3s ease;
}

.progress-value {
  font-size: 12px;
  color: var(--text-tertiary);
  font-weight: 600;
}

.badge-earned-text {
  font-size: 14px;
  font-weight: 600;
  color: #10B981;
  padding: 10px;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 6px;
}
