@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700;800;900&display=swap');

:root {
  --primary: #4C5139;
  --primary-dark: #373A28;
  --primary-light: #656C4D;
  --primary-hover: #5B6244;
  --primary-subtle: rgba(76, 81, 57, 0.08);
  --primary-glow: rgba(76, 81, 57, 0.25);
  
  --bg-cream: #F5F2E9;
  --bg-sand: #ECE7DA;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #FAF8F2;
  
  --accent-gold: #C09848;
  --accent-gold-light: #DFBB73;
  --accent-gold-subtle: rgba(192, 152, 72, 0.12);
  
  --text-main: #24271D;
  --text-muted: #646959;
  --text-light: #8E9484;
  --border-color: #DFDAC9;
  --border-focus: #4C5139;
  
  --shadow-sm: 0 2px 8px rgba(76, 81, 57, 0.06);
  --shadow-md: 0 6px 20px rgba(76, 81, 57, 0.09);
  --shadow-lg: 0 12px 36px rgba(76, 81, 57, 0.14);
  --shadow-gold: 0 8px 24px rgba(192, 152, 72, 0.22);
  
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Tahoma, sans-serif;
  direction: rtl;
  text-align: right;
  background-color: var(--bg-cream);
  color: var(--text-main);
  line-height: 1.65;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(76, 81, 57, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(192, 152, 72, 0.05) 0%, transparent 40%);
  background-attachment: fixed;
  padding-bottom: 70px; /* Space for mobile floating nav */
}

/* Background Leaf Pattern */
.bg-leaf-decor {
  position: fixed;
  pointer-events: none;
  opacity: 0.035;
  z-index: 0;
}
.bg-leaf-top-right {
  top: -50px;
  right: -50px;
  width: 320px;
  height: 320px;
  transform: rotate(25deg);
}
.bg-leaf-bottom-left {
  bottom: -40px;
  left: -40px;
  width: 280px;
  height: 280px;
  transform: rotate(-35deg);
}

/* App Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(245, 242, 233, 0.95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 1.25rem;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-logo-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg-cream);
  box-shadow: 0 4px 12px rgba(76, 81, 57, 0.25);
  flex-shrink: 0;
}

.brand-titles h1 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.3px;
  line-height: 1.25;
}

.brand-titles span {
  font-size: 0.76rem;
  color: var(--text-muted);
  display: block;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--bg-sand);
  padding: 3px;
  border-radius: var(--radius-full);
}

.nav-btn {
  border: none;
  background: transparent;
  padding: 0.42rem 1rem;
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-muted);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
}

.nav-btn.active {
  background: var(--primary);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(76, 81, 57, 0.28);
}

.nav-btn:hover:not(.active) {
  color: var(--primary);
  background: rgba(76, 81, 57, 0.08);
}

/* Container */
.main-container {
  max-width: 1050px;
  margin: 1.5rem auto 3rem;
  padding: 0 1rem;
  position: relative;
  z-index: 1;
}

/* Hero Section */
.hero-card {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 1.8rem 2rem;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
  margin-bottom: 1.4rem;
}

.hero-card::after {
  content: "";
  position: absolute;
  top: -60px;
  left: -60px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(192, 152, 72, 0.25) 0%, transparent 70%);
  pointer-events: none;
}

.hero-title {
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.45;
  margin-bottom: 0.65rem;
  color: #FFFFFF;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.hero-desc {
  font-size: 0.94rem;
  color: #E2DFD2;
  max-width: 820px;
  line-height: 1.65;
}

/* Stepper & Progress */
.progress-card {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  padding: 1rem 1.4rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.2rem;
}

.progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.65rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary);
}

.progress-bar-track {
  width: 100%;
  height: 8px;
  background: var(--bg-sand);
  border-radius: var(--radius-full);
  overflow: hidden;
}

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

/* Candidate Pills Strip */
.candidates-strip-wrapper {
  position: relative;
  margin-bottom: 1.4rem;
}

.candidates-strip {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.3rem 0.2rem 0.6rem;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-light) transparent;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
}

.candidate-pill {
  flex-shrink: 0;
  scroll-snap-align: center;
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface);
  border-radius: var(--radius-full);
  padding: 0.55rem 1.15rem;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  user-select: none;
}

.candidate-pill:active {
  transform: scale(0.96);
}

.candidate-pill.active {
  background: var(--primary);
  color: #FFFFFF;
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(76, 81, 57, 0.25);
}

.candidate-pill.completed {
  border-color: var(--accent-gold);
}

.candidate-pill.completed::after {
  content: "✓";
  font-size: 0.78rem;
  color: var(--accent-gold);
  font-weight: 900;
}

.candidate-pill.active.completed::after {
  color: #FFFFFF;
}

/* Active Candidate Box */
.active-candidate-hero {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border-color);
  padding: 1.4rem 1.6rem;
  box-shadow: var(--shadow-md);
  margin-bottom: 1.4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.active-candidate-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
  min-width: 200px;
}

.candidate-nav-switcher {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.nav-arrow-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface-elevated);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  flex-shrink: 0;
}

.nav-arrow-btn:active {
  transform: scale(0.9);
  background: var(--primary-subtle);
}

.candidate-order-tag {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--accent-gold);
  letter-spacing: 0.5px;
}

.candidate-current-name {
  font-size: 1.75rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1.2;
}

.candidate-score-preview {
  background: var(--bg-surface-elevated);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.6rem 1.2rem;
  text-align: center;
  min-width: 120px;
}

.preview-score-val {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--accent-gold);
  line-height: 1.1;
}

.preview-score-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
  font-weight: 600;
}

/* Criteria Grid */
.criteria-list-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.criteria-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .criteria-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.criteria-card {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.7rem;
}

.criteria-card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-md);
}

.criteria-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}

.criteria-name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.criteria-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: var(--primary-subtle);
  color: var(--primary);
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 800;
  flex-shrink: 0;
}

.criteria-selected-badge {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  background: var(--bg-sand);
  color: var(--text-muted);
  transition: var(--transition);
  white-space: nowrap;
}

.criteria-selected-badge.active {
  background: var(--accent-gold-subtle);
  color: var(--accent-gold);
  border: 1px solid rgba(192, 152, 72, 0.35);
}

.criteria-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Rating Buttons (1 to 5) - Optimized for touch */
.rating-group {
  display: flex;
  gap: 0.4rem;
  justify-content: space-between;
  margin-top: 0.2rem;
}

.score-btn {
  flex: 1;
  min-height: 46px;
  background: var(--bg-surface-elevated);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.2rem;
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  user-select: none;
}

.score-btn:active {
  transform: scale(0.92);
}

.score-btn .score-num {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--text-main);
  line-height: 1;
}

.score-btn .score-text {
  font-size: 0.66rem;
  color: var(--text-light);
  white-space: nowrap;
  font-weight: 600;
}

.score-btn:hover {
  border-color: var(--primary-light);
  background: var(--primary-subtle);
}

.score-btn.selected {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(76, 81, 57, 0.28);
  transform: translateY(-2px);
}

.score-btn.selected .score-num {
  color: #FFFFFF;
}

.score-btn.selected .score-text {
  color: #FAF6ED;
}

/* Action Buttons */
.action-btn {
  border: none;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 0.75rem 1.8rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
}

.action-btn:active {
  transform: scale(0.96);
}

.btn-secondary {
  background: var(--bg-sand);
  color: var(--text-main);
}

.btn-secondary:hover {
  background: #DFD9CB;
}

.btn-primary {
  background: var(--primary);
  color: #FFFFFF;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  background: var(--primary-hover);
  box-shadow: var(--shadow-lg);
}

.btn-gold {
  background: linear-gradient(135deg, var(--accent-gold) 0%, #A97E28 100%);
  color: #FFFFFF;
  box-shadow: var(--shadow-gold);
}

.btn-gold:hover {
  background: linear-gradient(135deg, var(--accent-gold-light) 0%, var(--accent-gold) 100%);
}

/* Submission Card */
.submit-section-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border-color);
  padding: 1.6rem 1.8rem;
  box-shadow: var(--shadow-md);
  margin-bottom: 2.5rem;
}

.submit-header {
  margin-bottom: 1.2rem;
}

.submit-header h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.3rem;
}

.submit-header p {
  color: var(--text-muted);
  font-size: 0.88rem;
}

/* Floating Bottom Bar for Mobile */
.mobile-bottom-bar {
  display: none;
}

@media (max-width: 768px) {
  .mobile-bottom-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--border-color);
    padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom, 0px));
    z-index: 90;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
  }

  .mobile-nav-stepper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
  }

  .mobile-stepper-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-sand);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    cursor: pointer;
  }

  .mobile-stepper-label {
    font-size: 0.82rem;
    font-weight: 800;
    color: var(--primary);
    white-space: nowrap;
  }

  .mobile-submit-btn {
    flex: 1;
    background: var(--accent-gold);
    color: #fff;
    border: none;
    border-radius: var(--radius-full);
    padding: 0.6rem 1rem;
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    box-shadow: var(--shadow-sm);
  }
}

/* Results View */
.results-container {
  display: none;
}

.results-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.6rem;
}

.stat-card {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-color);
  padding: 1.2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--primary-subtle);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.stat-info-val {
  font-size: 1.65rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1.1;
}

.stat-info-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Leaderboard Ranking Table */
.leaderboard-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border-color);
  padding: 1.5rem 1.6rem;
  box-shadow: var(--shadow-md);
  margin-bottom: 2rem;
}

.leaderboard-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
}

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

.ranking-item {
  background: var(--bg-surface-elevated);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  transition: var(--transition);
  cursor: pointer;
}

.ranking-item:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-sm);
  transform: translateX(-3px);
}

.ranking-rank {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-sand);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  font-weight: 900;
  flex-shrink: 0;
}

.ranking-rank.rank-1 {
  background: #FFD700;
  color: #7A5800;
  box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4);
}

.ranking-rank.rank-2 {
  background: #E0E0E0;
  color: #555555;
}

.ranking-rank.rank-3 {
  background: #CD7F32;
  color: #FFFFFF;
}

.ranking-details {
  flex: 1;
}

.ranking-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--primary);
}

.ranking-bar-wrapper {
  flex: 1;
  max-width: 240px;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.ranking-bar-track {
  flex: 1;
  height: 9px;
  background: var(--bg-sand);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.ranking-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-gold) 0%, var(--primary) 100%);
  border-radius: var(--radius-full);
}

.ranking-score-num {
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--primary);
  min-width: 44px;
  text-align: left;
}

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(36, 39, 29, 0.65);
  backdrop-filter: blur(5px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 1.8rem;
  box-shadow: var(--shadow-lg);
  transform: translateY(20px);
  transition: transform 0.28s ease;
  position: relative;
}

.modal-overlay.open .modal-content {
  transform: translateY(0);
}

.modal-close-btn {
  position: absolute;
  top: 1rem;
  left: 1rem;
  border: none;
  background: var(--bg-sand);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: var(--text-main);
  transition: var(--transition);
}

.modal-close-btn:hover {
  background: var(--primary);
  color: #FFFFFF;
}

/* Toast Notification */
.toast-notice {
  position: fixed;
  bottom: 4.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--primary-dark);
  color: #FFFFFF;
  padding: 0.8rem 1.4rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  z-index: 300;
  font-weight: 700;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  pointer-events: none;
}

.toast-notice.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* Confetti Canvas */
#confettiCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 500;
}

/* ========================================================
   SPECIFIC MOBILE UX ENHANCEMENTS (< 640px)
   ======================================================== */
@media (max-width: 640px) {
  body {
    padding-bottom: 80px;
  }

  .app-header {
    padding: 0.5rem 0.8rem;
  }

  .header-inner {
    justify-content: center;
    gap: 0.5rem;
  }

  .brand-wrapper {
    gap: 0.5rem;
  }

  .brand-logo-icon {
    width: 36px;
    height: 36px;
  }

  .brand-titles h1 {
    font-size: 1rem;
  }

  .brand-titles span {
    font-size: 0.7rem;
  }

  .header-nav {
    width: 100%;
    justify-content: space-between;
  }

  .nav-btn {
    flex: 1;
    justify-content: center;
    padding: 0.4rem 0.5rem;
    font-size: 0.78rem;
  }

  .main-container {
    padding: 0 0.75rem;
    margin-top: 1rem;
  }

  .hero-card {
    padding: 1.3rem 1.2rem;
    border-radius: var(--radius-md);
  }

  .hero-title {
    font-size: 1.2rem;
    line-height: 1.4;
  }

  .hero-desc {
    font-size: 0.86rem;
    line-height: 1.6;
  }

  .active-candidate-hero {
    padding: 1.1rem 1rem;
    border-radius: var(--radius-md);
  }

  .candidate-current-name {
    font-size: 1.45rem;
  }

  .candidate-score-preview {
    min-width: 90px;
    padding: 0.45rem 0.7rem;
  }

  .preview-score-val {
    font-size: 1.35rem;
  }

  /* Score buttons on mobile */
  .score-btn {
    min-height: 44px;
    padding: 0.35rem 0.1rem;
  }

  .score-btn .score-num {
    font-size: 1.15rem;
  }

  .score-btn .score-text {
    font-size: 0.6rem;
  }

  .ranking-bar-wrapper {
    display: none; /* Hide progress bar on tiny mobile to save space, show score number clearly */
  }

  .ranking-item {
    padding: 0.75rem 0.85rem;
  }

  /* Mobile Bottom Sheet Modal */
  .modal-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .modal-content {
    border-radius: 22px 22px 0 0;
    max-height: 82vh;
    padding: 1.5rem 1.2rem;
  }
}
