:root {
  color-scheme: dark;
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Core Theme Neutrals */
  --bg: #070a08;
  --panel: #0f1411;
  --panel-elevated: #161c18;
  --panel-border: rgba(255, 255, 255, 0.08);
  --panel-border-hover: rgba(255, 255, 255, 0.16);
  
  --text-primary: #f8faf8;
  --text-secondary: #9aa89d;
  --text-muted: #67756a;
  
  --track-bg: #151c17;
  --track-border: rgba(255, 255, 255, 0.07);
  
  /* Difficulty Colors */
  --green: #25e86b;
  --green-rgb: 37, 232, 107;
  --yellow: #facc15;
  --yellow-rgb: 250, 204, 21;
  --orange: #fb923c;
  --orange-rgb: 251, 146, 60;
  --red: #f87171;
  --red-rgb: 248, 113, 113;
  --violet: #a855f7;
  --violet-rgb: 168, 85, 247;
  
  /* Premium Accents */
  --gold: #f59e0b;
  --gold-glow: rgba(245, 158, 11, 0.28);
  
  /* Active theme dynamic variable */
  --active: var(--green);
  --active-rgb: var(--green-rgb);
}

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

body {
  min-height: 100vh;
  font-family: var(--font-sans);
  background:
    radial-gradient(ellipse 70% 50% at 50% 10%, rgba(var(--active-rgb), 0.12), transparent 75%),
    radial-gradient(ellipse 45% 35% at 85% 90%, rgba(245, 158, 11, 0.03), transparent 60%),
    linear-gradient(180deg, #070a08 0%, #0c100d 50%, #060807 100%);
  color: var(--text-primary);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button, input {
  font-family: inherit;
}

/* ==========================================================================
   Full-Page Application Layout
   ========================================================================== */

.app-layout {
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
}

.app-header {
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 30;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
}

.header-inner {
  width: min(100%, 540px);
  margin: 0 auto;
  padding: 16px 20px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo {
  font-size: clamp(26px, 7vw, 32px);
  font-weight: 900;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  line-height: 1;
  margin: 0;
}

.day-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  font-size: 11.5px;
  font-weight: 750;
  cursor: pointer;
  white-space: nowrap;
  transition: all 150ms cubic-bezier(0.16, 1, 0.3, 1);
}

.day-chip:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(var(--active-rgb), 0.4);
  color: #fff;
  transform: translateY(-1px);
}

.day-chip svg {
  color: var(--active);
}

.chip-caret {
  font-size: 8px;
  opacity: 0.6;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 140ms ease;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.09);
  color: var(--text-primary);
  border-color: var(--panel-border-hover);
}

.pro-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 34px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(245, 158, 11, 0.05));
  color: #fcd34d;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  cursor: pointer;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.12);
  transition: all 150ms cubic-bezier(0.16, 1, 0.3, 1);
}

.pro-badge:hover {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.28), rgba(245, 158, 11, 0.1));
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.25);
  transform: translateY(-1px);
}

.pro-badge.pro-active {
  border-color: rgba(37, 232, 107, 0.4);
  background: linear-gradient(135deg, rgba(37, 232, 107, 0.18), rgba(37, 232, 107, 0.06));
  color: #25e86b;
  box-shadow: 0 0 12px rgba(37, 232, 107, 0.2);
}

.pro-sparkle {
  font-size: 10px;
}

.streak-box {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.04);
}

.streak-flame {
  color: #f97316;
  filter: drop-shadow(0 0 4px rgba(249, 115, 22, 0.4));
}

.streak-box span {
  font-size: 13px;
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1;
}

.streak-box small {
  display: block;
  color: var(--text-muted);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
}

/* ==========================================================================
   Main Game Container (Full-Page Canvas)
   ========================================================================== */

.main-content {
  flex: 1;
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 24px 20px 48px;
}

.game-container {
  width: min(100%, 540px);
  display: flex;
  flex-direction: column;
  position: relative;
}

/* ==========================================================================
   Archive Active Banner
   ========================================================================== */

.day-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  margin-bottom: 16px;
  border-radius: 8px;
  background: rgba(250, 204, 21, 0.08);
  border: 1px solid rgba(250, 204, 21, 0.24);
  font-size: 12px;
  color: #fde047;
  animation: slideDown 200ms ease;
}

.day-banner[hidden] {
  display: none;
}

.banner-content {
  display: flex;
  align-items: center;
  gap: 6px;
}

.banner-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.roll-songs-btn {
  border: 1px solid rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.18);
  color: #e9d5ff;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 5px;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.2);
  transition: all 120ms ease;
}

.roll-songs-btn:hover {
  background: rgba(168, 85, 247, 0.28);
  transform: translateY(-1px);
}

.roll-songs-btn[hidden] {
  display: none;
}

.return-today-btn {
  border: 0;
  background: #facc15;
  color: #0d120e;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 5px;
  cursor: pointer;
  transition: opacity 120ms ease;
}

.return-today-btn:hover {
  opacity: 0.9;
}

/* ==========================================================================
   Difficulty Switcher
   ========================================================================== */

.difficulty-nav {
  margin-bottom: 22px;
}

.difficulty-bar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  padding: 4px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.pill {
  height: 34px;
  border: 0;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-secondary);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  transition: all 160ms cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.pill:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--pill-color);
  opacity: 0.6;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  line-height: 1;
  transition: all 160ms ease;
}

.pill-dot.check-icon {
  width: auto;
  height: auto;
  background: transparent !important;
  color: var(--pill-color);
  font-size: 12px;
  font-weight: 900;
  opacity: 1;
}

.pill.active .pill-dot.check-icon {
  color: #060e08;
}

.pill-dot.fail-icon {
  width: auto;
  height: auto;
  background: transparent !important;
  color: #f87171;
  font-size: 11px;
  font-weight: 900;
  opacity: 1;
}

.pill.active .pill-dot.fail-icon {
  color: #060e08;
}

.pill.active {
  color: #060e08;
  background: var(--pill-color);
  box-shadow: 0 0 14px color-mix(in srgb, var(--pill-color) 45%, transparent);
}

.pill.active .pill-dot:not(.check-icon):not(.fail-icon) {
  background: #060e08;
  opacity: 1;
}

.easy { --pill-color: var(--green); }
.medium { --pill-color: var(--yellow); }
.hard { --pill-color: var(--orange); }
.expert { --pill-color: var(--red); }
.impossible { --pill-color: var(--violet); }

/* ==========================================================================
   Timeline / Progression Bar
   ========================================================================== */

.timeline-container {
  margin-bottom: 24px;
}

.timeline {
  position: relative;
  height: 22px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--track-bg);
  border: 1px solid var(--track-border);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.4);
}

.timeline-unlocked {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0%;
  background: rgba(var(--active-rgb), 0.22);
  border-right: 2px solid var(--active);
  transition: width 240ms cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
  z-index: 1;
}

.timeline-playhead {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0%;
  background: var(--active);
  box-shadow: 0 0 12px rgba(var(--active-rgb), 0.8);
  pointer-events: none;
  z-index: 2;
}

.timeline-segments {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.segment {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(255, 255, 255, 0.14);
  pointer-events: none;
}

.timeline-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-muted);
}

.active-sec {
  color: var(--active);
  font-weight: 800;
}

/* ==========================================================================
   Stage & Play Button
   ========================================================================== */

.stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 144px;
  margin-bottom: 22px;
  position: relative;
}

.play-wrapper {
  position: relative;
  width: 98px;
  height: 98px;
  display: grid;
  place-items: center;
}

.sound-wave-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(var(--active-rgb), 0.5);
  opacity: 0;
  pointer-events: none;
}

.play-btn.playing ~ .sound-wave-ring.r1 {
  animation: wavePulse 1.4s infinite cubic-bezier(0.2, 0.8, 0.2, 1);
}

.play-btn.playing ~ .sound-wave-ring.r2 {
  animation: wavePulse 1.4s infinite cubic-bezier(0.2, 0.8, 0.2, 1) 0.5s;
}

@keyframes wavePulse {
  0% { transform: scale(0.9); opacity: 0.8; }
  100% { transform: scale(1.45); opacity: 0; }
}

.play-btn {
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--active);
  color: #060e08;
  cursor: pointer;
  box-shadow: 0 0 30px rgba(var(--active-rgb), 0.45), inset 0 -3px 6px rgba(0, 0, 0, 0.15);
  transition: all 150ms cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 2;
}

.play-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 0 38px rgba(var(--active-rgb), 0.6);
}

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

.play-btn:disabled {
  opacity: 0.7;
  cursor: wait;
}

.icon-play, .icon-pause {
  width: 34px;
  height: 34px;
  margin-left: 3px;
}

.icon-pause {
  margin-left: 0;
  display: none;
}

.play-btn.playing .icon-play {
  display: none;
}

.play-btn.playing .icon-pause {
  display: block;
}

.stage-info {
  margin-top: 10px;
  text-align: center;
  min-height: 38px;
}

.seconds {
  display: block;
  font-size: 16px;
  font-weight: 800;
  color: var(--active);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.audio-status {
  margin-top: 2px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* ==========================================================================
   Search & Guess Controls
   ========================================================================== */

.guess-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 116px;
  gap: 8px;
  margin-bottom: 18px;
}

.search-wrap {
  position: relative;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 17px;
  height: 17px;
  color: var(--text-muted);
  pointer-events: none;
}

input[type="search"] {
  width: 100%;
  height: 46px;
  padding: 0 36px 0 38px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  outline: 0;
  color: var(--text-primary);
  background: rgba(15, 21, 17, 0.85);
  font-size: 14px;
  font-weight: 600;
  transition: all 140ms ease;
}

input[type="search"]::-webkit-search-cancel-button {
  display: none;
}

input[type="search"]::placeholder {
  color: var(--text-muted);
  font-weight: 500;
}

input[type="search"]:focus {
  border-color: rgba(var(--active-rgb), 0.6);
  box-shadow: 0 0 0 3px rgba(var(--active-rgb), 0.2), 0 0 16px rgba(var(--active-rgb), 0.1);
}

.clear-search-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  transition: all 120ms ease;
}

.clear-search-btn svg {
  display: block;
  pointer-events: none;
}

.clear-search-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.skip-btn {
  height: 46px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-size: 13.5px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 140ms ease;
}

.skip-btn:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: var(--panel-border-hover);
}

.skip-btn svg {
  width: 15px;
  height: 15px;
}

/* ==========================================================================
   Autocomplete Suggestions Dropdown
   ========================================================================== */

.suggestions {
  position: absolute;
  z-index: 15;
  left: 0;
  right: 0;
  bottom: calc(100% + 8px);
  max-height: 250px;
  overflow-y: auto;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 20, 16, 0.98);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
}

.suggestions:empty {
  display: none;
}

.suggestion-item {
  width: 100%;
  padding: 10px 14px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  background: transparent;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  color: var(--text-primary);
  cursor: pointer;
  transition: background 100ms ease;
}

.suggestion-item:last-child {
  border-bottom: 0;
}

.suggestion-item:hover,
.suggestion-item.highlighted {
  background: rgba(var(--active-rgb), 0.14);
}

.suggestion-icon {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  display: grid;
  place-items: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.sugg-artwork {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.06);
}

.suggestion-details {
  min-width: 0;
  flex: 1;
}

.sugg-title {
  display: block;
  font-size: 13.5px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sugg-artist {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================================
   Guess Slots (Attempts 1-6)
   ========================================================================== */

.guess-slots {
  display: grid;
  gap: 6px;
  margin-bottom: 20px;
}

.slot {
  min-height: 42px;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.025);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-muted);
  transition: all 200ms ease;
}

.slot.active-attempt {
  border-color: rgba(var(--active-rgb), 0.3);
  background: rgba(var(--active-rgb), 0.03);
  color: var(--text-secondary);
}

.slot.correct {
  border-color: transparent;
  background: var(--active);
  color: #060e08;
  font-weight: 800;
  box-shadow: 0 0 14px rgba(var(--active-rgb), 0.3);
  animation: slotPop 240ms ease;
}

.slot.partial {
  border-color: rgba(250, 204, 21, 0.45);
  background: rgba(250, 204, 21, 0.16);
  color: #fef08a;
  box-shadow: 0 0 12px rgba(250, 204, 21, 0.2);
  animation: slotPop 240ms ease;
}

.slot.partial .slot-icon {
  color: #fde047;
  font-weight: 900;
}

.slot-tag {
  font-size: 9.5px;
  font-weight: 900;
  letter-spacing: 0.4px;
  padding: 1.5px 6px;
  border-radius: 4px;
  background: rgba(250, 204, 21, 0.25);
  color: #fef08a;
  border: 1px solid rgba(250, 204, 21, 0.5);
  flex-shrink: 0;
  margin-left: 6px;
  text-transform: uppercase;
}

.slot.missed {
  border-color: rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.16);
  color: #fee2e2;
  animation: slotPop 240ms ease;
}

.slot.skipped {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  animation: slotPop 240ms ease;
}

@keyframes slotPop {
  0% { transform: scale(0.97); }
  60% { transform: scale(1.02); }
  100% { transform: scale(1); }
}

.slot-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.slot-num {
  font-size: 11.5px;
  opacity: 0.6;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.slot-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.slot-icon {
  font-size: 13.5px;
  flex-shrink: 0;
}

.app-footer {
  margin-top: 16px;
  text-align: center;
}

.courtesy {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
}

/* ==========================================================================
   Modals Common (Overlay Dialogs)
   ========================================================================== */

.modal-overlay {
  position: fixed;
  z-index: 50;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(3, 6, 4, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: fadeIn 180ms ease;
}

.modal-overlay[hidden] {
  display: none;
}

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

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

.modal-card {
  width: min(100%, 460px);
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  border-radius: 16px;
  background: #111613;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
  animation: slideUp 200ms cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 20px 22px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.modal-header h2 {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.modal-sub {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--text-secondary);
}

.close-btn {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  transition: all 140ms ease;
  flex-shrink: 0;
}

.close-btn svg {
  display: block;
  pointer-events: none;
}

.close-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.modal-absolute-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 10;
}

/* ==========================================================================
   Result Modal
   ========================================================================== */

.result-card {
  padding: 0;
  overflow: hidden;
}

.modal-banner {
  position: relative;
  padding: 16px 20px;
  background: var(--active);
  color: #060e08;
  text-align: center;
}

.result-close-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 50;
  background: rgba(0, 0, 0, 0.18);
  color: #060e08;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  pointer-events: auto;
  transition: all 140ms ease;
}

.result-close-btn::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  cursor: pointer;
}

.result-close-btn:hover {
  background: rgba(0, 0, 0, 0.35);
  transform: scale(1.06);
}

.result-close-btn:active {
  transform: scale(0.94);
}

.banner-day-tag {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.85;
  pointer-events: none;
}

.modal-banner h2 {
  font-size: 26px;
  font-weight: 950;
  letter-spacing: -0.02em;
  pointer-events: none;
}

.modal-body {
  padding: 20px 22px 24px;
}

.song-reveal-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  margin-bottom: 16px;
}

.album-art-wrap {
  width: 68px;
  height: 68px;
  border-radius: 8px;
  overflow: hidden;
  background: #090c0a;
  flex-shrink: 0;
  position: relative;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.album-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.art-fallback {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--text-muted);
}

.song-meta {
  min-width: 0;
  text-align: left;
  flex: 1;
}

.stream-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(29, 185, 84, 0.12);
  border: 1px solid rgba(29, 185, 84, 0.28);
  color: #1ed760;
  font-size: 10.5px;
  font-weight: 800;
  margin-bottom: 4px;
}

.answer-title {
  display: block;
  font-size: 17px;
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1.2;
}

.answer-artist {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.music-links-row {
  display: flex;
  align-items: center;
  margin-top: 6px;
}

.spotify-link {
  display: inline-flex;
  align-items: center;
  gap: 4.5px;
  font-size: 11px;
  font-weight: 700;
  color: #1ed760;
  text-decoration: none;
  transition: all 120ms ease;
}

.spotify-link:hover {
  color: #25e86b;
  text-decoration: underline;
}

.spotify-link svg {
  width: 12px;
  height: 12px;
  color: #1ed760;
  fill: currentColor;
  flex-shrink: 0;
}

.answer-player-box {
  margin-bottom: 16px;
}

.answer-play-btn {
  width: 100%;
  height: 38px;
  border-radius: 8px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-size: 12.5px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 140ms ease;
}

.answer-play-btn:hover {
  background: rgba(255, 255, 255, 0.09);
}

.stats-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 180px;
  margin: 0 auto 14px;
  padding: 3px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.stats-tab {
  height: 26px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-secondary);
  font-size: 11.5px;
  font-weight: 800;
  cursor: pointer;
  transition: all 120ms ease;
}

.stats-tab.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.12);
}

.stats-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.stat-pill {
  padding: 10px 8px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.05);
  text-align: center;
}

.stat-pill span {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 700;
}

.stat-pill strong {
  display: block;
  font-size: 20px;
  font-weight: 900;
  color: var(--text-primary);
  margin-top: 2px;
}

.distribution {
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 16px;
  text-align: left;
}

.distribution-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}

.distribution-head h3 {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text-secondary);
}

.distribution-head span {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 700;
}

.bars {
  display: grid;
  gap: 5px;
}

.bar-row {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}

.bar-label {
  font-size: 12.5px;
  font-weight: 900;
  color: var(--text-secondary);
  text-align: right;
}

.bar-track {
  height: 16px;
  border-left: 2px solid rgba(255, 255, 255, 0.2);
}

.bar-fill {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 5px;
  min-width: 18px;
  height: 100%;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.15);
  font-size: 10px;
  font-weight: 900;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1;
}

.bar-fill.active {
  background: var(--active);
  color: #060e08;
  box-shadow: 0 0 12px rgba(var(--active-rgb), 0.4);
}

#placementLine {
  margin-top: 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
  text-align: center;
}

.modal-actions-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.action-btn {
  height: 44px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 140ms ease;
}

.share-btn {
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

.share-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}

.next-level-btn {
  border: 0;
  background: var(--active);
  color: #060e08;
  box-shadow: 0 0 16px rgba(var(--active-rgb), 0.3);
}

.next-level-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.archive-nav-btn {
  width: 100%;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 750;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 140ms ease;
}

.archive-nav-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* ==========================================================================
   Archive Modal Specifics
   ========================================================================== */

.archive-card {
  padding: 0;
  overflow: hidden;
}

.archive-promo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(245, 158, 11, 0.04));
  border-bottom: 1px solid rgba(245, 158, 11, 0.25);
}

.archive-promo.unlocked {
  background: linear-gradient(135deg, rgba(37, 232, 107, 0.15), rgba(37, 232, 107, 0.03));
  border-bottom-color: rgba(37, 232, 107, 0.2);
}

.promo-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.promo-star {
  font-size: 16px;
  color: #fcd34d;
}

.archive-promo.unlocked .promo-star {
  color: #25e86b;
}

.promo-left strong {
  display: block;
  font-size: 13.5px;
  font-weight: 900;
  color: #fcd34d;
}

.archive-promo.unlocked .promo-left strong {
  color: #25e86b;
}

.promo-left p {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.upgrade-btn-sm {
  border: 0;
  border-radius: 6px;
  padding: 6px 12px;
  background: #f59e0b;
  color: #0b0f0c;
  font-size: 11.5px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.35);
  transition: all 140ms ease;
}

.day-card.unlimited-day-card {
  border-color: rgba(168, 85, 247, 0.35);
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.14), rgba(168, 85, 247, 0.03));
  margin-bottom: 4px;
}

.day-card.unlimited-day-card:hover {
  border-color: rgba(168, 85, 247, 0.55);
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(168, 85, 247, 0.06));
}

.day-card.unlimited-day-card.current-active {
  border-color: rgba(168, 85, 247, 0.7) !important;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(168, 85, 247, 0.08)) !important;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.25) !important;
}

.day-card.unlimited-day-card .day-num-box.unlimited-num-box,
.day-card.unlimited-day-card.current-active .day-num-box.unlimited-num-box {
  background: rgba(168, 85, 247, 0.22) !important;
  border: 1px solid rgba(168, 85, 247, 0.45) !important;
  color: #f3e8ff !important;
  display: grid;
  place-items: center;
  font-size: 20px;
}

.unlimited-card-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.unlimited-badge {
  font-size: 8.5px;
  font-weight: 900;
  padding: 1px 4.5px;
  border-radius: 4px;
  background: rgba(168, 85, 247, 0.3);
  color: #f3e8ff;
  border: 1px solid rgba(168, 85, 247, 0.5);
  letter-spacing: 0.4px;
}

.archive-list {
  display: grid;
  gap: 8px;
  padding: 16px 18px;
  max-height: 380px;
  overflow-y: auto;
}

.day-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--panel-border);
  cursor: pointer;
  transition: all 150ms cubic-bezier(0.16, 1, 0.3, 1);
}

.day-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: var(--panel-border-hover);
  transform: translateY(-1px);
}

.day-card.current-active {
  border-color: rgba(var(--active-rgb), 0.5);
  background: rgba(var(--active-rgb), 0.06);
}

.day-card.locked {
  opacity: 0.75;
}

.day-card.locked:hover {
  opacity: 1;
  border-color: rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.04);
}

.day-card-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.day-num-box {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.day-num-box span {
  font-size: 8.5px;
  color: var(--text-muted);
  font-weight: 800;
  text-transform: uppercase;
}

.day-num-box strong {
  font-size: 15px;
  font-weight: 900;
  color: var(--text-primary);
  margin-top: 1px;
}

.day-card.current-active .day-num-box {
  background: var(--active);
}

.day-card.current-active .day-num-box span,
.day-card.current-active .day-num-box strong {
  color: #060e08;
}

.day-info strong {
  display: block;
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text-primary);
}

.day-info span {
  display: block;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.day-card-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 850;
  letter-spacing: 0.03em;
}

.status-badge.solved {
  background: rgba(37, 232, 107, 0.16);
  color: #25e86b;
  border: 1px solid rgba(37, 232, 107, 0.25);
}

.status-badge.today {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.status-badge.locked {
  background: rgba(245, 158, 11, 0.15);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.status-badge.unplayed {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
}

/* ==========================================================================
   Paywall / Upgrade Modal
   ========================================================================== */

.upgrade-card {
  max-width: 500px;
  padding: 0;
  overflow: hidden;
  border-color: rgba(245, 158, 11, 0.35);
  box-shadow: 0 0 50px rgba(245, 158, 11, 0.18), 0 24px 60px rgba(0, 0, 0, 0.92);
  transition: all 300ms ease;
}

.upgrade-card.is-member {
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: 0 0 60px rgba(16, 185, 129, 0.25), 0 24px 60px rgba(0, 0, 0, 0.94);
}

.upgrade-header {
  padding: 26px 20px 16px;
  text-align: center;
  background: radial-gradient(circle at top center, rgba(245, 158, 11, 0.22), transparent 75%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.plus-crown-wrapper {
  position: relative;
  width: 48px;
  height: 48px;
  margin: 0 auto 10px;
}

.plus-crown-glow {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.6) 0%, transparent 70%);
  filter: blur(8px);
}

.plus-crown-glow.active-glow {
  background: radial-gradient(circle, rgba(16, 185, 129, 0.7) 0%, rgba(16, 185, 129, 0.18) 55%, transparent 75%);
  filter: blur(10px);
}

.plus-crown {
  position: relative;
  z-index: 2;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fcd34d, #f59e0b, #d97706);
  color: #0b0f0c;
  font-size: 22px;
  font-weight: 900;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.45);
}

.plus-crown.active-crown {
  background: linear-gradient(135deg, #fef08a, #fcd34d, #f59e0b);
  color: #0b0f0c;
  box-shadow: 0 0 22px rgba(16, 185, 129, 0.65), 0 4px 14px rgba(245, 158, 11, 0.4);
  border: 2px solid #34d399;
}

.plus-badge-tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fcd34d;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.plus-badge-tag.active-badge-tag {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.35);
  color: #34d399;
}

.upgrade-header h2 {
  font-size: 23px;
  font-weight: 950;
  color: #fff;
  letter-spacing: -0.02em;
}

.text-gold-gradient {
  background: linear-gradient(135deg, #fef08a, #fcd34d, #f59e0b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.plus-tagline {
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.upgrade-body {
  padding: 16px 20px 22px;
}

.pricing-card.premium-offer-card {
  position: relative;
  padding: 14px 12px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(245, 158, 11, 0.25);
  text-align: center;
  margin-bottom: 14px;
}

.pricing-badge {
  position: absolute;
  top: -9px;
  right: 12px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #0b0f0c;
  font-size: 9px;
  font-weight: 900;
  padding: 2px 7px;
  border-radius: 999px;
  letter-spacing: 0.06em;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.price-top {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 3px;
}

.currency {
  font-size: 20px;
  font-weight: 800;
  color: #fcd34d;
}

.amount {
  font-size: 32px;
  font-weight: 950;
  color: #fcd34d;
  letter-spacing: -0.03em;
}

.period {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
}

.price-sub {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.pricing-perks-row {
  display: flex;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.pricing-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  font-weight: 700;
  color: #fde68a;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.2);
  padding: 2px 7px;
  border-radius: 6px;
}

.plus-perks-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.plus-perk-card {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 9px;
  text-align: left;
  transition: all 140ms ease;
}

.plus-perk-card:hover {
  background: rgba(245, 158, 11, 0.05);
  border-color: rgba(245, 158, 11, 0.25);
  transform: translateY(-1px);
}

.perk-icon-bubble {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 7px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.25);
  display: grid;
  place-items: center;
  font-size: 14px;
}

.perk-text strong {
  display: block;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.25;
  margin-bottom: 2px;
}

.perk-text p {
  font-size: 10.5px;
  color: var(--text-secondary);
  line-height: 1.35;
  margin: 0;
}

.purchase-btn {
  width: 100%;
  height: 46px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #0b0f0c;
  font-size: 14.5px;
  font-weight: 950;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  box-shadow: 0 4px 22px rgba(245, 158, 11, 0.45);
  transition: all 140ms ease;
}

.purchase-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(245, 158, 11, 0.55);
}

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

.btn-lock {
  font-size: 14px;
}

.upgrade-trust-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 10.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.upgrade-trust-footer .trust-item {
  display: flex;
  align-items: center;
  gap: 3px;
  color: var(--text-secondary);
}

.trust-dot {
  opacity: 0.4;
}

/* Active Member Dashboard View */
.active-member-header {
  background: radial-gradient(circle at top center, rgba(16, 185, 129, 0.2), transparent 75%);
}

.active-status-card {
  background: rgba(16, 185, 129, 0.07);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 14px;
  text-align: center;
}

.active-status-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 3px;
  font-size: 13px;
  color: #34d399;
  font-weight: 800;
}

.status-indicator-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.active-status-card p {
  font-size: 11px;
  color: var(--text-secondary);
  margin: 0;
}

.active-features-list {
  display: grid;
  gap: 7px;
  margin-bottom: 16px;
}

.active-feature-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 11.5px;
  color: var(--text-primary);
  font-weight: 600;
  text-align: left;
}

.check-icon {
  color: #10b981;
  font-weight: 900;
  font-size: 13px;
}

.active-actions-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.active-play-btn {
  background: linear-gradient(135deg, #a855f7, #7e22ce);
  color: #fff;
  box-shadow: 0 4px 20px rgba(168, 85, 247, 0.4);
}

.active-play-btn:hover {
  box-shadow: 0 6px 25px rgba(168, 85, 247, 0.55);
}

.active-archive-btn {
  width: 100%;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 140ms ease;
}

.active-archive-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}

@media (max-width: 480px) {
  .plus-perks-grid {
    grid-template-columns: 1fr;
  }
  .active-actions-row {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Help / Instructions Modal
   ========================================================================== */

.help-card {
  max-width: 480px;
  background:
    radial-gradient(ellipse 90% 60% at 50% 0%, rgba(var(--active-rgb), 0.12), transparent 70%),
    linear-gradient(180deg, #0e1410 0%, #080c09 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 24px 22px 20px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.75), 0 0 32px rgba(var(--active-rgb), 0.08);
  position: relative;
}

.help-header {
  text-align: center;
  margin-bottom: 16px;
}

.help-kicker-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 4px;
}

.help-title {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.5px;
  color: #ffffff;
  margin: 0 0 6px;
}

.help-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.45;
  max-width: 360px;
  margin: 0 auto;
}

.help-body {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0;
}

/* Inner Visual Instructions Box */
.help-instructions-box {
  background: rgba(18, 24, 20, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  backdrop-filter: blur(8px);
}

/* Timeline wrap */
.help-timeline-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.help-timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--text-muted);
}

.help-timeline-step {
  color: var(--active);
}

.help-progress-bar {
  display: flex;
  gap: 4px;
  height: 18px;
  width: 100%;
  padding: 2px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.hp-segment {
  border-radius: 4px;
  transition: all 200ms ease;
}

.hp-played {
  flex: 0.5;
  background: var(--active);
  box-shadow: 0 0 8px rgba(var(--active-rgb), 0.5);
}

.hp-active {
  flex: 1;
  background: #475569;
}

.hp-locked {
  flex: 1.8;
  background: rgba(255, 255, 255, 0.07);
}

.hp-locked-wide {
  flex: 3;
  background: rgba(255, 255, 255, 0.07);
}

.hp-locked-widest {
  flex: 4.5;
  background: rgba(255, 255, 255, 0.07);
}

.help-timeline-intervals {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  padding: 0 2px;
}

/* Action Rows */
.help-action-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.help-action-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.help-play-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--active);
  color: #060e08;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 0 14px rgba(var(--active-rgb), 0.4);
}

.help-skip-pill {
  height: 34px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 5px;
  font-weight: 900;
  font-size: 11.5px;
  letter-spacing: 0.3px;
  flex-shrink: 0;
}

.help-skip-pill small {
  color: var(--text-secondary);
  font-size: 10px;
  font-weight: 700;
}

.help-action-desc strong {
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: #ffffff;
}

.help-action-desc p {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 1px;
}

.help-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 2px 0;
}

/* Guess Result Legend */
.help-legend-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.help-legend-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.help-status-icon {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.help-status-icon.correct {
  background: rgba(37, 232, 107, 0.16);
  border: 1px solid rgba(37, 232, 107, 0.4);
  color: #25e86b;
  box-shadow: 0 0 10px rgba(37, 232, 107, 0.25);
}

.help-status-icon.partial {
  background: rgba(250, 204, 21, 0.16);
  border: 1px solid rgba(250, 204, 21, 0.4);
  color: #facc15;
  box-shadow: 0 0 10px rgba(250, 204, 21, 0.25);
}

.help-status-icon.wrong {
  background: rgba(248, 113, 113, 0.16);
  border: 1px solid rgba(248, 113, 113, 0.4);
  color: #f87171;
  box-shadow: 0 0 10px rgba(248, 113, 113, 0.25);
}

.help-legend-desc strong {
  display: block;
  font-size: 12.5px;
  font-weight: 800;
  color: #ffffff;
}

.help-legend-desc p {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 1px;
}

/* 5 Tiers Strip */
.help-tiers-strip {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 11px 13px;
  text-align: center;
}

.tiers-strip-title {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: var(--text-muted);
  margin-bottom: 7px;
}

.tiers-chips {
  display: flex;
  justify-content: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.tier-pill {
  font-size: 10.5px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.2px;
}

.tier-pill.easy {
  background: rgba(37, 232, 107, 0.14);
  color: #25e86b;
  border: 1px solid rgba(37, 232, 107, 0.3);
}

.tier-pill.medium {
  background: rgba(250, 204, 21, 0.14);
  color: #facc15;
  border: 1px solid rgba(250, 204, 21, 0.3);
}

.tier-pill.hard {
  background: rgba(251, 146, 60, 0.14);
  color: #fb923c;
  border: 1px solid rgba(251, 146, 60, 0.3);
}

.tier-pill.extreme {
  background: rgba(248, 113, 113, 0.14);
  color: #f87171;
  border: 1px solid rgba(248, 113, 113, 0.3);
}

.tier-pill.impossible {
  background: rgba(168, 85, 247, 0.14);
  color: #a855f7;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.tiers-caption {
  font-size: 11px;
  color: var(--text-secondary);
  margin: 0;
}

.help-cta-btn {
  width: 100%;
  height: 46px;
  border: 0;
  border-radius: 10px;
  background: var(--active);
  color: #060e08;
  font-size: 14.5px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 0 20px rgba(var(--active-rgb), 0.35);
  transition: all 140ms ease;
}

.help-cta-btn:hover {
  filter: brightness(1.12);
  transform: translateY(-1px);
  box-shadow: 0 0 26px rgba(var(--active-rgb), 0.5);
}

/* ==========================================================================
   Toast Notification
   ========================================================================== */

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  padding: 10px 18px;
  border-radius: 999px;
  background: #1f2722;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  font-size: 12.5px;
  font-weight: 800;
  color: var(--text-primary);
  animation: toastSlideUp 200ms cubic-bezier(0.16, 1, 0.3, 1);
}

.toast[hidden] {
  display: none;
}

@keyframes toastSlideUp {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* ==========================================================================
   Profile, Google Auth & Settings
   ========================================================================== */

.profile-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: all 140ms ease;
  overflow: hidden;
}

.profile-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.avatar-circle {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
  color: #fff;
  background: #1e2621;
  border-radius: 50%;
  overflow: hidden;
}

.avatar-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.avatar-circle.signed-in {
  background: linear-gradient(135deg, #1db954, #0e7030);
}

.profile-card {
  width: min(100%, 480px);
}

.profile-body {
  padding: 18px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.auth-box {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  overflow: hidden;
}

.google-auth-card {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #ffffff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.auth-info strong {
  display: block;
  font-size: 14.5px;
  color: var(--text-primary);
}

.auth-info p {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
  line-height: 1.3;
}

.google-sign-in-btn {
  width: 100%;
  height: 40px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #ffffff;
  color: #1f1f1f;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: all 140ms ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.google-sign-in-btn:hover {
  background: #f1f3f4;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.user-profile-header {
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(29, 185, 84, 0.06);
  border: 1px solid rgba(29, 185, 84, 0.2);
  border-radius: 12px;
}

.user-avatar-large {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1db954, #0e7030);
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(29, 185, 84, 0.3);
  overflow: hidden;
  position: relative;
}

.avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.user-details {
  flex: 1;
  min-width: 0;
}

.user-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.user-name-row strong {
  font-size: 15px;
  font-weight: 900;
  color: var(--text-primary);
}

.synced-pill {
  font-size: 9.5px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(37, 232, 107, 0.16);
  color: #25e86b;
  border: 1px solid rgba(37, 232, 107, 0.3);
}

.user-email {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 1px;
}

.sign-out-btn {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  font-size: 11.5px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 120ms ease;
}

.sign-out-btn:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.section-kicker {
  display: block;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.profile-stats-card {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 14px 16px;
}

.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.pstat-item {
  display: flex;
  flex-direction: column;
  padding: 10px 8px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.04);
  text-align: center;
}

.pstat-label {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-secondary);
}

.pstat-val-row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
  margin-top: 4px;
}

.pstat-val {
  font-size: 18px;
  font-weight: 900;
  color: var(--text-primary);
}

.pstat-sub {
  font-size: 10px;
  color: var(--text-muted);
}

.pstat-badge {
  font-size: 11px;
  font-weight: 800;
  color: #fcd34d;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.pstat-badge.pro {
  color: #25e86b;
  background: rgba(37, 232, 107, 0.14);
  border-color: rgba(37, 232, 107, 0.3);
}

.settings-section {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

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

.setting-row.volume-row {
  flex-direction: column;
  align-items: stretch;
}

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

.setting-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.vol-icon {
  color: var(--active);
}

.setting-info strong {
  display: block;
  font-size: 13.5px;
  color: var(--text-primary);
}

.setting-info p {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 1px;
}

.volume-slider-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.volume-slider {
  flex: 1;
  -webkit-appearance: none;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.16);
  outline: none;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--active);
  cursor: pointer;
  box-shadow: 0 0 8px rgba(var(--active-rgb), 0.5);
  transition: transform 100ms ease;
}

.volume-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.vol-val {
  font-size: 12px;
  font-weight: 800;
  color: var(--text-primary);
  min-width: 32px;
  text-align: right;
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 24px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: rgba(255, 255, 255, 0.14);
  transition: 180ms ease;
  border-radius: 24px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 180ms ease;
  border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
  background-color: var(--green);
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(18px);
}

/* Google Chooser Modal */
.google-chooser-card {
  width: min(100%, 400px);
  background: #ffffff;
  color: #1f1f1f;
  padding: 24px;
  border-radius: 16px;
}

.google-chooser-head {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
}

.google-chooser-head h2 {
  font-size: 19px;
  font-weight: 700;
  color: #1f1f1f;
  margin-top: 4px;
}

.google-chooser-head p {
  font-size: 13px;
  color: #5f6368;
}

.google-accounts-list {
  display: flex;
  flex-direction: column;
  border: 1px solid #dadce0;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 16px;
}

.g-account-item {
  width: 100%;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0;
  border-bottom: 1px solid #f1f3f4;
  background: #ffffff;
  cursor: pointer;
  text-align: left;
  transition: background 100ms ease;
}

.g-account-item:last-child {
  border-bottom: 0;
}

.g-account-item:hover {
  background: #f8f9fa;
}

.g-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 13px;
  color: #ffffff;
}

.g-avatar.green { background: #1b73e8; }
.g-avatar.blue { background: #e37400; }

.g-acc-info {
  display: flex;
  flex-direction: column;
}

.g-acc-info strong {
  font-size: 13.5px;
  color: #202124;
}

.g-acc-info span {
  font-size: 12px;
  color: #5f6368;
}

.custom-google-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.custom-label {
  font-size: 12px;
  font-weight: 600;
  color: #5f6368;
}

.custom-inputs-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.custom-inputs-row input {
  height: 38px;
  padding: 0 12px;
  border: 1px solid #dadce0;
  border-radius: 6px;
  font-size: 13px;
  color: #202124;
  outline: none;
}

.custom-inputs-row input:focus {
  border-color: #1a73e8;
  box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

.close-google-btn {
  width: 100%;
  margin-top: 10px;
  height: 36px;
  border: 0;
  background: transparent;
  color: #5f6368;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border-radius: 6px;
}

.close-google-btn:hover {
  background: #f1f3f4;
  color: #202124;
}

/* ==========================================================================
   Mobile Responsive Tweaks
   ========================================================================== */

@media (max-width: 540px) {
  .header-inner {
    padding: 12px 14px;
  }

  .main-content {
    padding: 16px 14px 32px;
  }
  
  .guess-row {
    grid-template-columns: minmax(0, 1fr) 96px;
  }
  
  .play-btn {
    width: 78px;
    height: 78px;
  }
  
  .play-wrapper {
    width: 88px;
    height: 88px;
  }
}

/* ==========================================================================
   Developer Tools Floating Drawer (Bottom Right)
   ========================================================================== */

.dev-panel-toggle {
  position: fixed;
  bottom: 18px;
  right: 18px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(18, 26, 20, 0.85);
  backdrop-filter: blur(12px);
  color: #fff;
  font-size: 16px;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 9999;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  transition: all 160ms cubic-bezier(0.16, 1, 0.3, 1);
}

.dev-panel-toggle:hover {
  transform: scale(1.1);
  background: rgba(30, 42, 33, 0.95);
  border-color: rgba(37, 232, 107, 0.5);
  box-shadow: 0 0 14px rgba(37, 232, 107, 0.35);
}

.dev-panel {
  position: fixed;
  bottom: 66px;
  right: 18px;
  width: 290px;
  border-radius: 12px;
  background: #0f1611;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.65), 0 0 1px rgba(255, 255, 255, 0.2);
  z-index: 9999;
  animation: slideUpFade 180ms cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.dev-panel[hidden] {
  display: none;
}

.dev-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dev-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #fff;
}

.dev-close-btn {
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: all 120ms ease;
}

.dev-close-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.dev-panel-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dev-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.dev-label {
  font-size: 9.5px;
  font-weight: 900;
  letter-spacing: 0.6px;
  color: var(--text-muted);
}

.dev-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 6px;
}

.dev-val {
  font-size: 12px;
  font-weight: 800;
  color: #25e86b;
  text-align: center;
}

.dev-btn {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  padding: 7px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 140ms ease;
  text-align: center;
}

.dev-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}

.dev-btn.secondary {
  border-color: rgba(250, 204, 21, 0.25);
  background: rgba(250, 204, 21, 0.08);
  color: #fef08a;
}

.dev-btn.secondary:hover {
  background: rgba(250, 204, 21, 0.18);
  border-color: rgba(250, 204, 21, 0.45);
}

.dev-btn.danger {
  border-color: rgba(248, 113, 113, 0.25);
  background: rgba(248, 113, 113, 0.08);
  color: #fca5a5;
}

.dev-btn.danger:hover {
  background: rgba(248, 113, 113, 0.2);
  border-color: rgba(248, 113, 113, 0.5);
}

.dev-btn-sm {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 8px;
  border-radius: 5px;
  cursor: pointer;
  transition: all 120ms ease;
}

.dev-btn-sm:hover {
  background: rgba(255, 255, 255, 0.12);
}
