/* Fitness RPG Styles */

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

:root {
  --primary: #667eea;
  --primary-dark: #5568d3;
  --secondary: #764ba2;
  --success: #48bb78;
  --danger: #f56565;
  --warning: #ed8936;
  --bg-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --card-bg: #ffffff;
  --text-primary: #2d3748;
  --text-secondary: #718096;
  --border: #e2e8f0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: linear-gradient(to bottom, #87CEEB 0%, #E0F6FF 100%);
  min-height: 100vh;
  padding: 20px;
  color: var(--text-primary);
  position: relative;
  overflow-x: hidden;
}

/* Floating clouds animation */
.clouds {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.cloud {
  position: absolute;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 100px;
  animation: float-cloud 30s infinite ease-in-out;
}

.cloud:nth-child(1) {
  width: 120px;
  height: 50px;
  top: 10%;
  left: -120px;
  animation-delay: 0s;
}

.cloud:nth-child(2) {
  width: 180px;
  height: 70px;
  top: 30%;
  left: -180px;
  animation-delay: 10s;
}

.cloud:nth-child(3) {
  width: 140px;
  height: 60px;
  top: 60%;
  left: -140px;
  animation-delay: 20s;
}

.cloud:nth-child(4) {
  width: 160px;
  height: 65px;
  top: 45%;
  left: -160px;
  animation-delay: 5s;
}

.cloud:nth-child(5) {
  width: 130px;
  height: 55px;
  top: 75%;
  left: -130px;
  animation-delay: 15s;
}

@keyframes float-cloud {
  0%, 100% {
    transform: translateX(0) translateY(0);
  }
  50% {
    transform: translateX(calc(100vw + 200px)) translateY(-20px);
  }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  position: relative;
  z-index: 1;
}

/* Header */
header {
  text-align: center;
  color: white;
  margin-bottom: 2rem;
}

header h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-weight: 700;
  text-shadow: 3px 3px 0px rgba(0, 0, 0, 0.3);
  letter-spacing: 1px;
}

.tagline {
  font-size: 1.2rem;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-weight: 600;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.2);
  color: rgba(255, 255, 255, 0.95);
}

/* Screens */
.screen {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 60vh;
}

/* Welcome Card */
.welcome-card {
  background: var(--card-bg);
  padding: 3rem;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  text-align: center;
  max-width: 500px;
}

.welcome-card h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.welcome-card p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.welcome-card .description {
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.welcome-card .note {
  font-size: 0.875rem;
  margin-top: 1rem;
  color: var(--text-secondary);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 18px;
  font-size: 1rem;
  font-weight: 700;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary {
  background: rgba(255, 255, 255, 0.4);
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover {
  background: rgba(255, 255, 255, 0.55);
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.3);
  color: white;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.btn-large {
  padding: 1rem 2rem;
  font-size: 1.1rem;
}

.user-actions {
  margin-left: auto;
  display: flex;
  gap: 0.5rem;
}

.btn-refresh, .btn-sync {
  padding: 0.5rem 1rem;
  background: var(--primary);
  color: white;
  font-size: 1rem;
}

.btn-refresh {
  font-size: 1.2rem;
}

.btn-refresh:hover {
  background: var(--primary-dark);
  transform: rotate(-90deg);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-sync:hover {
  background: var(--primary-dark);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-sync:disabled {
  background: var(--text-secondary);
  cursor: not-allowed;
}

.btn-dismiss {
  background: transparent;
  border: none;
  color: var(--success);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  margin-left: 0.5rem;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.btn-dismiss:hover {
  opacity: 1;
  transform: none;
}

/* Dashboard */
#dashboardScreen {
  display: block;
}

/* User Info - Hidden (replaced by Chao Garden header) */
.user-info {
  display: none !important;
}

.user-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-gradient);
}

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

.avatar-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: white;
}

.user-details h2 {
  font-size: 1.75rem;
  margin-bottom: 0.25rem;
}

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

/* Level Progress - Hidden (replaced by Chao Garden header) */
.level-progress {
  display: none !important;
}

.progress-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-weight: 600;
  color: var(--text-primary);
}

.progress-bar {
  height: 24px;
  background: #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: var(--bg-gradient);
  transition: width 0.5s ease;
  border-radius: 12px;
}

.progress-fill.import {
  background: var(--warning);
}

.progress-fill.import.animated {
  width: 100% !important;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--warning) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% {
    background-position: -100% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

/* Import Status */
.import-status {
  background: #fef5e7;
  border: 2px solid var(--warning);
  padding: 1.5rem;
  border-radius: 16px;
  margin-bottom: 2rem;
}

.import-status.completed {
  background: #e8f5e9;
  border-color: var(--success);
}

.import-status.completed .import-header {
  color: var(--success);
}

.import-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-weight: 600;
  color: var(--warning);
}

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

.card {
  background: rgba(100, 180, 255, 0.85);
  border: 4px solid rgba(255, 255, 255, 0.6);
  padding: 2rem;
  border-radius: 35px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
}

.radar-card {
  grid-column: span 2;
}

.chart-container {
  position: relative;
  height: 400px;
  width: 100%;
  max-width: 500px;
  margin: 1rem auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.stat-icon {
  font-size: 3rem;
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-gradient);
  border-radius: 12px;
}

.stat-details h4 {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

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

/* Sport Breakdown */
.sport-breakdown h3 {
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.sport-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.sport-item {
  padding: 1rem;
  background: #f7fafc;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sport-name {
  font-weight: 600;
  color: var(--text-primary);
}

.sport-stats {
  display: flex;
  gap: 1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.sport-xp {
  font-weight: 600;
  color: var(--primary);
}

.stat-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.stat-badge.strength {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.stat-badge.endurance {
  background: rgba(59, 130, 246, 0.1);
  color: #2563eb;
}

.stat-badge.balanced {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
}

.loading, .no-data {
  text-align: center;
  color: var(--text-secondary);
  padding: 2rem;
}

/* Recent Activities */
.recent-activities h3 {
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.activity-item {
  padding: 1.25rem;
  background: #f7fafc;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.activity-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.activity-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.activity-title {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
}

.activity-name {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
}

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

.activity-sport {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
}

.activity-stats {
  display: flex;
  gap: 1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  flex-wrap: wrap;
}

.activity-xp {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.75rem;
  border-top: 1px solid #e2e8f0;
}

.xp-total {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.xp-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

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

.xp-breakdown {
  display: flex;
  gap: 1rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.xp-strength {
  color: #dc2626;
}

.xp-endurance {
  color: #2563eb;
}

.xp-agility {
  color: #d97706;
}

.intensity-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  background: rgba(102, 126, 234, 0.1);
  color: var(--primary);
}

.intensity-badge.hr {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.intensity-badge.watts {
  background: rgba(251, 191, 36, 0.1);
  color: #d97706;
}

.intensity-badge.pace {
  background: rgba(59, 130, 246, 0.1);
  color: #2563eb;
}

/* Expandable Activity Details */
.activity-item {
  cursor: pointer;
  position: relative;
}

.activity-details {
  display: none;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed #cbd5e1;
}

.activity-item.expanded .activity-details {
  display: block;
}

.activity-item.expanded .expand-indicator {
  display: none;
}

.expand-indicator {
  position: absolute;
  bottom: 0.5rem;
  right: 0.75rem;
  font-size: 0.7rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.expand-hint {
  text-align: center;
  font-size: 0.7rem;
  color: #94a3b8;
  margin-top: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.xp-formula {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-radius: 8px;
  padding: 1rem;
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.85rem;
}

.formula-row {
  display: flex;
  justify-content: space-between;
  padding: 0.35rem 0;
}

.formula-label {
  color: #64748b;
}

.formula-value {
  color: #334155;
  font-weight: 500;
}

.formula-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 0.5rem 0;
}

.formula-total {
  font-weight: 700;
}

.formula-total .formula-label {
  color: #334155;
}

.formula-total .formula-value {
  color: var(--primary);
}

.intensity-row .formula-value {
  color: #059669;
}

.intensity-note {
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: rgba(251, 191, 36, 0.1);
  border-radius: 6px;
  font-size: 0.8rem;
  color: #92400e;
  text-align: center;
}

/* Tabs - Chao Garden Style */
.tabs {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 2rem;
  justify-content: center;
}

.tab-btn {
  padding: 0.875rem 2rem;
  background: rgba(100, 180, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.4);
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  cursor: pointer;
  border-radius: 20px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.tab-btn:hover {
  background: rgba(100, 180, 255, 0.5);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.tab-btn.active {
  background: rgba(100, 180, 255, 0.85);
  border-color: rgba(255, 255, 255, 0.8);
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* Friend Search */
.friend-search h3 {
  margin-bottom: 1.5rem;
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
}

.search-container {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.search-input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  font-size: 1rem;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  background: rgba(255, 255, 255, 0.9);
  transition: all 0.3s;
}

.search-input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.8);
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.search-results {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.search-result-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.search-result-item:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.search-result-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.search-result-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.6);
}

.search-result-name {
  font-weight: 700;
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
}

.search-result-username {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
}

/* Friend Requests */
.friend-requests h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
}

.friend-requests-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.friend-request-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  transition: all 0.3s;
}

.friend-request-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.friend-request-actions {
  display: flex;
  gap: 0.5rem;
}

/* Friends Grid */
.friends-list h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
}

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

.friend-card {
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 25px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
}

.friend-card:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.friend-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.friend-name {
  font-weight: 700;
  font-size: 1.2rem;
  color: white;
  text-align: center;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
}

.friend-level {
  font-size: 0.95rem;
  color: #FFD700;
  font-weight: 700;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.friend-stats {
  display: flex;
  gap: 1.5rem;
  width: 100%;
  justify-content: center;
  padding-top: 0.75rem;
  border-top: 2px solid rgba(255, 255, 255, 0.4);
}

.friend-stat {
  text-align: center;
}

.friend-stat-label {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
  font-weight: 700;
}

.friend-stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: white;
  margin-top: 0.25rem;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 2rem;
}

.modal-content {
  background: rgba(100, 180, 255, 0.95);
  border: 4px solid rgba(255, 255, 255, 0.6);
  border-radius: 35px;
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem;
  border-bottom: 3px solid rgba(255, 255, 255, 0.4);
}

.modal-header h2 {
  margin: 0;
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
}

.modal-close {
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-weight: 400;
  padding: 0;
  flex-shrink: 0;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: scale(1.1);
}

.modal-body {
  padding: 2rem;
}

.comparison-users {
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-bottom: 2rem;
}

.comparison-user {
  text-align: center;
}

.comparison-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(255, 255, 255, 0.8);
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.comparison-user h3 {
  margin: 0 0 0.5rem 0;
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 1.5rem;
}

.comparison-level {
  color: #FFD700;
  font-weight: 700;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.comparison-vs {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
}

.comparison-chart {
  height: 400px;
  margin-bottom: 2rem;
  background: rgba(255, 255, 255, 0.2);
  border: 3px solid rgba(255, 255, 255, 0.4);
  border-radius: 20px;
  padding: 1rem;
}

.stats-table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(255, 255, 255, 0.2);
  border: 3px solid rgba(255, 255, 255, 0.4);
  border-radius: 20px;
  overflow: hidden;
}

.stats-table th {
  text-align: left;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.3);
  font-weight: 700;
  color: white;
  border-bottom: 3px solid rgba(255, 255, 255, 0.4);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
}

.stats-table td {
  padding: 1rem;
  border-bottom: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
}

.stats-table td:first-child {
  font-weight: 700;
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.stats-table td:not(:first-child) {
  text-align: center;
  font-weight: 700;
  font-size: 1.1rem;
}

.stat-higher {
  color: #00FF88;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.stat-lower {
  color: rgba(255, 255, 255, 0.6);
}

/* Footer */
footer {
  margin-top: 4rem;
  text-align: center;
  color: white;
  opacity: 0.8;
}

footer a {
  color: white;
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
  /* General */
  header h1 {
    font-size: 2rem;
  }

  .card {
    padding: 1.5rem 1rem;
  }

  /* Welcome Screen */
  .welcome-card {
    padding: 2rem 1.5rem;
    max-width: 100%;
    margin: 0 1rem;
  }

  .welcome-card h2 {
    font-size: 1.75rem;
  }

  .welcome-card .description {
    font-size: 1rem;
  }

  /* Tabs */
  .tabs {
    gap: 0.5rem;
    margin-bottom: 1.5rem;
  }

  .tab-btn {
    font-size: 0.85rem;
    padding: 0.65rem 0.75rem;
    flex: 1;
    white-space: nowrap;
    border-radius: 16px;
    border-width: 2px;
  }

  /* Stats Grid */
  .radar-card {
    grid-column: span 1;
  }

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

  .user-info {
    flex-direction: column;
    text-align: center;
  }

  .sport-item {
    flex-direction: column;
    gap: 0.5rem;
  }

  .sport-stats {
    flex-wrap: wrap;
    justify-content: center;
  }

  .activity-header {
    flex-direction: column;
    gap: 0.5rem;
  }

  .activity-xp {
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
  }

  /* Friends Tab */
  .friend-search h3,
  .friends-list h3 {
    font-size: 1.5rem;
  }

  .search-container {
    flex-direction: column;
  }

  .search-input {
    font-size: 0.95rem;
  }

  .friend-item {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1rem;
  }

  .friend-info {
    align-items: center;
  }

  .friend-actions {
    width: 100%;
    justify-content: center;
    margin-top: 0.75rem;
  }

  /* Leaderboards */
  .leaderboard-controls h3 {
    font-size: 1.5rem;
  }

  .period-selector {
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem;
  }

  .period-btn {
    flex: 1 1 calc(50% - 0.25rem);
    min-width: 120px;
    font-size: 0.85rem;
    padding: 0.6rem 0.75rem;
  }

  .category-selector {
    flex-direction: column;
    gap: 0.75rem;
  }

  .category-selector label {
    font-size: 0.9rem;
  }

  .category-selector select {
    font-size: 0.9rem;
    width: 100%;
  }
}

/* ====================================
   Leaderboards Styles
   ==================================== */

.leaderboard-controls {
  margin-bottom: 1.5rem;
}

.leaderboard-controls h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.period-selector {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.2);
  padding: 0.75rem;
  border-radius: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.period-btn {
  flex: 1;
  padding: 0.75rem 1.5rem;
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 15px;
  font-size: 1rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.period-btn:hover {
  color: white;
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
}

.period-btn.active {
  background: rgba(255, 255, 255, 0.4);
  color: white;
  border-color: rgba(255, 255, 255, 0.8);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  transform: scale(1.05);
}

.category-selector {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 1rem;
}

.category-select {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  font-size: 1rem;
  font-weight: 700;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  background: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  transition: all 0.3s;
}

.category-select:hover {
  border-color: rgba(255, 255, 255, 0.8);
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.category-select:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.sport-filter {
  margin-bottom: 1.5rem;
}

.sport-filter h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
}

.sport-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1rem 0;
}

.sport-btn {
  padding: 0.75rem 1.25rem;
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  color: white;
  border-radius: 18px;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.sport-btn:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.sport-count {
  opacity: 0.8;
  font-size: 0.85rem;
  margin-left: 0.25rem;
}

.user-ranking {
  background: rgba(255, 255, 255, 0.25);
  border: 4px solid rgba(255, 255, 255, 0.5);
  color: white;
  margin-bottom: 1.5rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.user-ranking h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.rank-display {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.rank-number {
  font-size: 3.5rem;
  font-weight: 700;
  min-width: 100px;
  text-align: center;
  color: white;
  text-shadow: 3px 3px 0px rgba(0, 0, 0, 0.3);
}

.rank-details {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  flex: 1;
}

.rank-stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.rank-label {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 700;
  text-transform: uppercase;
}

.rank-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.leaderboard-card {
  margin-bottom: 2rem;
}

.leaderboard-card h3 {
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.leaderboard-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.leaderboard-entry {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.3);
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.leaderboard-entry:hover {
  background: rgba(255, 255, 255, 0.45);
  transform: translateX(4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.leaderboard-entry.current-user {
  background: rgba(255, 255, 255, 0.45);
  border: 4px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  font-weight: 700;
}

.entry-rank {
  font-size: 1.8rem;
  font-weight: 700;
  min-width: 60px;
  text-align: center;
  color: white;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.3);
}

.entry-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 3px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

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

.entry-avatar .avatar-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.4);
  font-size: 1.5rem;
}

.entry-info {
  flex: 1;
  min-width: 0;
}

.entry-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: white;
  margin-bottom: 0.25rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
}

.entry-stats {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
}

.gap-info {
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 0.35rem;
  display: inline-block;
  padding: 0.15rem 0.6rem;
  border-radius: 8px;
  margin-right: 0.5rem;
}

.gap-info.behind {
  color: #FF6B6B;
  background: rgba(255, 107, 107, 0.2);
  border: 1px solid rgba(255, 107, 107, 0.3);
}

.gap-info.ahead {
  color: #51CF66;
  background: rgba(81, 207, 102, 0.2);
  border: 1px solid rgba(81, 207, 102, 0.3);
}

.gap-info.leading {
  color: #FFD700;
  background: rgba(255, 215, 0, 0.25);
  border: 1px solid rgba(255, 215, 0, 0.4);
}

.entry-level {
  font-size: 1.4rem;
  font-weight: 700;
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  min-width: 60px;
  text-align: right;
}

/* Expandable Leaderboard Entries */
.leaderboard-entry {
  cursor: pointer;
  flex-wrap: wrap;
  position: relative;
}

.entry-expand-hint {
  width: 100%;
  text-align: center;
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.5rem;
  order: 10;
}

.leaderboard-entry.expanded .entry-expand-hint {
  display: none;
}

.entry-activities {
  width: 100%;
  display: none;
  order: 11;
}

.leaderboard-entry.expanded .entry-activities {
  display: block;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.3);
}

.lb-activities-header {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.lb-activities-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.lb-activity-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 8px;
}

.lb-activity-info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  flex: 1;
}

.lb-activity-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: white;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lb-activity-type {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
}

.lb-activity-xp {
  font-size: 0.85rem;
  font-weight: 700;
  color: #90EE90;
  white-space: nowrap;
  margin-left: 0.75rem;
}

.lb-activities-hint {
  text-align: center;
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.75rem;
}

.lb-activities-loading,
.lb-activities-empty,
.lb-activities-error {
  text-align: center;
  padding: 1rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
}

.lb-activities-error {
  color: #FF6B6B;
}

/* Responsive leaderboards */
@media (max-width: 768px) {
  .leaderboard-entry {
    padding: 0.75rem;
  }

  .rank-display {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .rank-details {
    flex: 1 1 100%;
    order: 2;
    justify-content: center;
  }

  .entry-rank {
    min-width: 40px;
    font-size: 1.25rem;
    order: 1;
  }

  .entry-level {
    min-width: 50px;
    font-size: 1.1rem;
    order: 3;
  }

  .entry-avatar {
    width: 40px;
    height: 40px;
  }

  .entry-name {
    font-size: 0.95rem;
  }

  .entry-username {
    font-size: 0.8rem;
  }

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

  .stat-label {
    font-size: 0.7rem;
  }
}

/* Weekly Reset Banner */
.weekly-reset-banner {
  background: linear-gradient(135deg, #E8F4F8 0%, #D4EEFF 100%);
  border: 3px solid rgba(168, 216, 240, 0.8);
  border-radius: 20px;
  padding: 15px 20px;
  margin-bottom: 20px;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
  animation: float 3s ease-in-out infinite;
}

.reset-banner {
  display: flex;
  align-items: center;
  gap: 15px;
}

.reset-icon {
  font-size: 32px;
  animation: pulse 2s ease-in-out infinite;
}

.reset-text {
  flex: 1;
}

.reset-title {
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-weight: 600;
  color: #4A90E2;
  font-size: 16px;
  margin-bottom: 4px;
}

.reset-countdown {
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  color: #667EEA;
  font-size: 14px;
  font-weight: 500;
}

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

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* Mobile adjustments for reset banner */
@media (max-width: 768px) {
  .weekly-reset-banner {
    padding: 12px 15px;
  }

  .reset-icon {
    font-size: 24px;
  }

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

  .reset-countdown {
    font-size: 12px;
  }
}

/* ============================================
   Stats Explainer Modal
   ============================================ */

/* Help link */
.stats-help-link {
  text-align: center;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 2px solid rgba(255, 255, 255, 0.3);
}

.stats-help-link a {
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  transition: all 0.2s ease;
}

.stats-help-link a:hover {
  color: #fff;
  text-decoration: underline;
}

/* Stats explainer modal content */
.stats-explainer-content {
  max-width: 650px;
  max-height: 90vh;
  /* Hide scrollbar but keep functionality */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}

.stats-explainer-content::-webkit-scrollbar {
  display: none; /* Chrome/Safari/Opera */
}

.stats-explainer-body {
  overflow-y: auto;
  max-height: calc(90vh - 70px);
  padding: 1.2rem 1.5rem;
  /* Hide scrollbar but keep functionality */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}

.stats-explainer-body::-webkit-scrollbar {
  display: none; /* Chrome/Safari/Opera */
}

/* Sections */
.explainer-section {
  margin-bottom: 1.5rem;
}

.explainer-section:last-child {
  margin-bottom: 0;
}

.explainer-section h3 {
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.7rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Formula box */
.formula-box {
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 12px;
  padding: 0.7rem 1rem;
  text-align: center;
  margin-bottom: 1rem;
}

.formula-box code {
  font-family: 'Fredoka', monospace;
  font-size: 0.95rem;
  color: #fff;
  font-weight: 600;
}

.formula-example {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  padding: 0.6rem 0.8rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.95);
  line-height: 1.5;
}

/* Stats explanation */
.stats-explanation {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 0.7rem;
}

.stat-explain {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.5rem 0.8rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.15);
}

.stat-explain.strength {
  border-left: 3px solid #FF6B6B;
}

.stat-explain.endurance {
  border-left: 3px solid #4ECDC4;
}

.stat-explain.agility {
  border-left: 3px solid #FFE66D;
}

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

.stat-explain strong {
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 0.9rem;
  color: #fff;
  display: block;
}

.stat-explain p {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.8);
  margin: 0;
}

.stat-note {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  font-style: italic;
  text-align: center;
}

/* Activity search */
.activity-search-container {
  margin-bottom: 1rem;
}

.activity-search-input {
  width: 100%;
  padding: 0.8rem 1rem;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
  font-size: 1rem;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  outline: none;
  transition: all 0.2s ease;
}

.activity-search-input::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.activity-search-input:focus {
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.25);
}

/* Activity table */
.activity-table-container {
  border-radius: 12px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  overflow: hidden;
}

.activity-mapping-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Fredoka', 'Comic Neue', sans-serif;
}

.activity-mapping-table thead {
  background: rgba(80, 150, 220, 0.95);
}

.activity-mapping-table th {
  padding: 0.5rem 0.4rem;
  font-weight: 600;
  color: #fff;
  text-align: left;
  font-size: 0.8rem;
}

.activity-mapping-table th.stat-col {
  text-align: center;
  width: 50px;
}

.activity-mapping-table td {
  padding: 0.4rem;
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.8rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.activity-mapping-table td.stat-col {
  text-align: center;
  font-weight: 600;
}

.activity-mapping-table td.stat-col.strength {
  color: #FF8A8A;
}

.activity-mapping-table td.stat-col.endurance {
  color: #7FEDD8;
}

.activity-mapping-table td.stat-col.agility {
  color: #FFE66D;
}

.activity-mapping-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.08);
}

.activity-mapping-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.15);
}

.activity-mapping-table .no-results {
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-style: italic;
  padding: 1.5rem;
}

/* Intensity zones */
.intensity-intro {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 0.6rem;
}

.intensity-formula {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  text-align: center;
}

.intensity-formula code {
  font-family: 'Fredoka', sans-serif;
  font-size: 0.85rem;
  color: #FFD700;
  background: none;
  padding: 0;
  font-weight: 600;
}

.intensity-zones {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.4rem;
}

.zone-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.4rem 0.7rem;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 6px;
}

.zone-label {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.9);
}

.zone-mult {
  font-family: 'Fredoka', monospace;
  font-weight: 700;
  font-size: 0.85rem;
  color: #FFE66D;
}

.intensity-fallback {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 0.5rem;
  font-style: italic;
}

/* Leveling info */
.leveling-info p {
  font-size: 0.95rem;
  color: #fff;
  margin-bottom: 0.6rem;
  text-align: center;
}

.level-examples {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.level-examples span {
  background: rgba(255, 255, 255, 0.15);
  padding: 0.35rem 0.7rem;
  border-radius: 15px;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.9);
}

/* Mobile adjustments for stats explainer */
@media (max-width: 768px) {
  .stats-explainer-content {
    max-width: 95%;
    max-height: 92vh;
  }

  .stats-explainer-body {
    padding: 0.8rem 1rem;
    max-height: calc(92vh - 60px);
  }

  .explainer-section h3 {
    font-size: 1rem;
  }

  .formula-box code {
    font-size: 0.85rem;
  }

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

  .activity-mapping-table th,
  .activity-mapping-table td {
    padding: 0.35rem 0.3rem;
    font-size: 0.75rem;
  }

  .intensity-zones {
    grid-template-columns: 1fr;
  }

  .level-examples {
    flex-direction: column;
    gap: 0.5rem;
    align-items: center;
  }
}
