/* ============================================================
   CRACKOFFER — Premium Dark Dashboard CSS
   Matching: Linear / Notion / Stripe / Arc quality
   Dark theme: #0a0c0f base | Green #22c55e | Purple #a855f7 | Gold #f59e0b
   ============================================================ */

/* ===== 1. RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ── Core Background Palette ── */
  --bg-base:       #0a0c0f;
  --bg-1:          #0f1216;
  --bg-2:          #141820;
  --bg-3:          #1a2030;
  --bg-4:          #1e2535;
  --bg-5:          #232d42;
  --bg-glass:      rgba(20, 24, 32, 0.7);
  --bg-glass-light: rgba(30, 37, 53, 0.6);

  /* ── Borders ── */
  --border:         rgba(255,255,255,0.07);
  --border-bright:  rgba(255,255,255,0.13);
  --border-green:   rgba(34,197,94,0.25);
  --border-purple:  rgba(168,85,247,0.25);
  --border-blue:    rgba(59,130,246,0.2);
  --border-gold:    rgba(245,158,11,0.2);

  /* ── Accent Colors ── */
  --green:          #22c55e;
  --green-light:    #4ade80;
  --green-dark:     #15803d;
  --green-glow:     rgba(34,197,94,0.35);
  --green-subtle:   rgba(34,197,94,0.08);
  --green-medium:   rgba(34,197,94,0.15);
  --purple:         #a855f7;
  --purple-dark:    #7c3aed;
  --purple-glow:    rgba(168,85,247,0.3);
  --purple-subtle:  rgba(168,85,247,0.08);
  --blue:           #3b82f6;
  --blue-glow:      rgba(59,130,246,0.25);
  --blue-subtle:    rgba(59,130,246,0.08);
  --gold:           #f59e0b;
  --gold-light:     #fbbf24;
  --gold-glow:      rgba(245,158,11,0.25);
  --gold-subtle:    rgba(245,158,11,0.08);
  --orange:         #f97316;
  --orange-subtle:  rgba(249,115,22,0.08);
  --red:            #ef4444;
  --red-subtle:     rgba(239,68,68,0.08);
  --cyan:           #06b6d4;
  --cyan-subtle:    rgba(6,182,212,0.08);
  --pink:           #ec4899;

  /* ── Text ── */
  --text-primary:  #f1f5f9;
  --text-sec:      #94a3b8;
  --text-muted:    #4e6280;
  --text-faint:    #2d3d55;
  --text-green:    #4ade80;
  --text-gold:     #fbbf24;
  --text-purple:   #c084fc;
  --text-blue:     #93c5fd;
  --text-red:      #fca5a5;

  /* ── Gradients ── */
  --grad-green:   linear-gradient(135deg, #22c55e 0%, #15803d 100%);
  --grad-purple:  linear-gradient(135deg, #a855f7 0%, #6d28d9 100%);
  --grad-blue:    linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  --grad-gold:    linear-gradient(135deg, #f59e0b 0%, #b45309 100%);
  --grad-orange:  linear-gradient(135deg, #f97316 0%, #c2410c 100%);
  --grad-cyan:    linear-gradient(135deg, #06b6d4 0%, #0e7490 100%);
  --grad-dark:    linear-gradient(135deg, #1a2030 0%, #0f1216 100%);

  /* ── Glow Shadows ── */
  --shadow-sm:     0 2px 8px rgba(0,0,0,0.45);
  --shadow-md:     0 8px 24px rgba(0,0,0,0.55);
  --shadow-lg:     0 16px 48px rgba(0,0,0,0.65);
  --shadow-xl:     0 24px 64px rgba(0,0,0,0.75);
  --shadow-green:  0 4px 24px rgba(34,197,94,0.35);
  --shadow-purple: 0 4px 24px rgba(168,85,247,0.35);
  --shadow-blue:   0 4px 24px rgba(59,130,246,0.3);
  --shadow-gold:   0 4px 24px rgba(245,158,11,0.3);

  /* ── Border Radius ── */
  --r-xs:   4px;
  --r-sm:   8px;
  --r-md:   12px;
  --r-lg:   16px;
  --r-xl:   20px;
  --r-2xl:  24px;
  --r-3xl:  32px;

  /* ── Layout Dimensions ── */
  --sidebar-w:        220px;
  --sidebar-w-collapsed: 64px;
  --topbar-h:         68px;
  --right-panel-w:    276px;
  --mobile-nav-h:     68px;

  /* ── Transitions ── */
  --t-fast:  0.12s ease;
  --t-med:   0.22s ease;
  --t-slow:  0.38s cubic-bezier(0.4, 0, 0.2, 1);
  --t-spring: 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-base);
  color: var(--text-primary);
  overflow-x: hidden;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  letter-spacing: -0.01em;
}

a  { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; border: none; outline: none; }
input, select, textarea { font-family: inherit; outline: none; }
svg { display: block; }
img { display: block; max-width: 100%; }

/* ===== 2. CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg-5); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }


/* ===================================================================
   3. LAYOUT
=================================================================== */
.app-wrapper {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr var(--right-panel-w);
  grid-template-rows: 100vh;
  height: 100vh;
  overflow: hidden;
}


/* ===================================================================
   4. SIDEBAR
=================================================================== */
.sidebar {
  background: var(--bg-1);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  position: relative;
  z-index: 20;
  transition: width var(--t-slow);
  flex-shrink: 0;
}

/* Sidebar header with logo */
.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.125rem 1rem;
  border-bottom: 1px solid var(--border);
  min-height: var(--topbar-h);
  flex-shrink: 0;
}

.logo { display: flex; align-items: center; gap: 0.55rem; }
.logo-icon { font-size: 1.4rem; flex-shrink: 0; }
.logo-text { display: flex; flex-direction: column; }
.logo-name {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}
.logo-tagline {
  font-size: 0.6rem;
  color: var(--text-muted);
  line-height: 1.2;
  margin-top: 1px;
}

.sidebar-toggle {
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-sec);
  padding: 0.375rem;
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  transition: all var(--t-fast);
}
.sidebar-toggle:hover { background: var(--bg-4); color: var(--text-primary); }

/* Sidebar nav */
.sidebar-nav {
  flex: 1;
  padding: 0.625rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow-y: auto;
}
.nav-section { margin-bottom: 0.5rem; }
.nav-section + .nav-section {
  border-top: 1px solid var(--border);
  padding-top: 0.5rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.575rem;
  padding: 0.5625rem 0.75rem;
  border-radius: var(--r-md);
  color: var(--text-sec);
  font-size: 0.8125rem;
  font-weight: 500;
  transition: all var(--t-fast);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.nav-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: transparent;
  transition: background var(--t-fast);
  border-radius: var(--r-md);
}
.nav-item:hover {
  background: var(--bg-3);
  color: var(--text-primary);
  transform: translateX(2px);
}
.nav-item.active {
  background: linear-gradient(135deg, rgba(34,197,94,0.16) 0%, rgba(34,197,94,0.05) 100%);
  color: var(--green);
  border: 1px solid rgba(34,197,94,0.22);
  font-weight: 600;
}
.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 20%;
  bottom: 20%;
  width: 3px;
  background: var(--green);
  border-radius: 0 3px 3px 0;
  box-shadow: 0 0 8px var(--green-glow);
}
.nav-icon  { font-size: 0.95rem; width: 18px; text-align: center; flex-shrink: 0; }
.nav-label { font-size: 0.785rem; white-space: nowrap; }

/* Motivator box */
.sidebar-motivator {
  margin: 0 0.625rem 0.5rem;
  padding: 0.7rem 0.875rem;
  background: linear-gradient(135deg, rgba(34,197,94,0.1) 0%, rgba(34,197,94,0.03) 100%);
  border: 1px solid rgba(34,197,94,0.18);
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.motivator-lightning { font-size: 1.1rem; }
.motivator-title { font-size: 0.72rem; font-weight: 700; color: var(--green); display: block; }
.motivator-sub   { font-size: 0.6rem; color: var(--text-muted); }

/* Profile at bottom of sidebar */
.sidebar-profile {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.75rem;
  margin: 0 0.5rem 0.375rem;
  background: var(--bg-2);
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  flex-shrink: 0;
}
.profile-avatar { position: relative; flex-shrink: 0; }
.avatar-ring {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--grad-green);
  padding: 2px;
  flex-shrink: 0;
}
.avatar-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--bg-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--green);
}
.profile-badge {
  position: absolute;
  bottom: -1px;
  right: -1px;
  background: var(--green);
  color: #000;
  font-size: 0.45rem;
  font-weight: 700;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--bg-1);
}
.profile-name  { font-size: 0.78rem; font-weight: 600; display: block; line-height: 1.3; }
.profile-level { font-size: 0.62rem; color: var(--text-gold); }

/* XP progress bar in sidebar */
.sidebar-xp-bar {
  padding: 0 0.875rem;
  margin-bottom: 0.375rem;
  flex-shrink: 0;
}
.xp-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.6rem;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}
.xp-track {
  height: 4px;
  background: var(--bg-4);
  border-radius: 4px;
  overflow: hidden;
}
.xp-fill {
  height: 100%;
  background: var(--grad-green);
  border-radius: 4px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 6px rgba(34,197,94,0.4);
}

/* Streak display in sidebar */
.sidebar-streak {
  display: flex;
  gap: 0.375rem;
  padding: 0 0.625rem 0.875rem;
  flex-shrink: 0;
}
.streak-item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-2);
  padding: 0.45rem 0.5rem;
  border-radius: var(--r-sm);
  border: 1px solid var(--border);
}
.streak-fire { font-size: 0.9rem; }
.streak-val  { font-size: 0.72rem; font-weight: 700; color: var(--gold); }
.streak-lbl  { font-size: 0.52rem; color: var(--text-muted); }


/* ===================================================================
   5. MAIN CONTENT AREA
=================================================================== */
.main-content {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  background: var(--bg-base);
  min-width: 0;
}


/* ===================================================================
   6. TOPBAR
=================================================================== */
.topbar {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.375rem;
  background: rgba(10, 12, 15, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 30;
}

.topbar-left { min-width: 0; flex: 1; }
.topbar-greeting {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, var(--text-primary) 0%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.topbar-sub {
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Date navigation */
.topbar-center { flex-shrink: 0; }
.date-nav { display: flex; align-items: center; gap: 0.4rem; }
.date-btn {
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-sec);
  width: 26px;
  height: 26px;
  border-radius: var(--r-sm);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--t-fast);
  flex-shrink: 0;
}
.date-btn:hover { background: var(--bg-4); color: var(--text-primary); }
.date-display {
  font-size: 0.775rem;
  font-weight: 600;
  color: var(--text-sec);
  background: var(--bg-3);
  border: 1px solid var(--border);
  padding: 0.3rem 0.7rem;
  border-radius: var(--r-sm);
  white-space: nowrap;
}

/* Topbar right cluster */
.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex-shrink: 0;
}
.topbar-stat { display: flex; align-items: center; gap: 0.35rem; }
.ts-icon { font-size: 0.95rem; }
.ts-val  { font-size: 0.82rem; font-weight: 700; line-height: 1; }
.ts-lbl  { font-size: 0.55rem; color: var(--text-muted); }

/* Notification button */
.notif-btn {
  position: relative;
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-sec);
  width: 34px;
  height: 34px;
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--t-fast);
  flex-shrink: 0;
}
.notif-btn:hover { background: var(--bg-4); color: var(--text-primary); }
.notif-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: var(--red);
  color: #fff;
  font-size: 0.52rem;
  font-weight: 700;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--bg-base);
  animation: pulse 2.5s infinite;
}

/* User menu */
.user-menu {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  padding: 0.3rem 0.55rem;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: background var(--t-fast);
  flex-shrink: 0;
}
.user-menu:hover { background: var(--bg-4); }
.user-avatar-sm {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--grad-green);
  color: #000;
  font-size: 0.58rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}


/* ===================================================================
   7. VIEWS CONTAINER & VIEWS
=================================================================== */
.views-container {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1.125rem;
  scroll-behavior: smooth;
}

.view {
  display: none;
  animation: fadeSlideIn 0.28s ease;
}
.view.active { display: block; }

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

.view-header {
  margin-bottom: 1.125rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.view-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.view-sub { font-size: 0.775rem; color: var(--text-muted); }


/* ===================================================================
   8. CARD BASE — The foundation of every panel
=================================================================== */
.card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 1.125rem;
  position: relative;
  overflow: hidden;
  transition: border-color var(--t-med), box-shadow var(--t-med), transform var(--t-med);
}
/* subtle top-edge highlight like screenshots */
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.09) 50%, transparent 100%);
  pointer-events: none;
}
.card:hover {
  border-color: var(--border-bright);
  box-shadow: var(--shadow-sm);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.875rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.card-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.card-title-sm {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.card-sub { font-size: 0.7rem; color: var(--text-muted); }

.view-all-link {
  font-size: 0.7rem;
  color: var(--green);
  transition: color var(--t-fast);
}
.view-all-link:hover { color: var(--text-primary); }


/* ===================================================================
   9. KPI ROW (Top stats row — Day Score, XP, Focus, Streak, etc.)
=================================================================== */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.625rem;
  margin-bottom: 0.875rem;
}

.kpi-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 0.875rem 1rem;
  cursor: pointer;
  transition: all var(--t-med);
  position: relative;
  overflow: hidden;
}
/* Radial shimmer in top-left corner */
.kpi-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 0% 0%, rgba(255,255,255,0.045) 0%, transparent 65%);
  pointer-events: none;
}
.kpi-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-md);
}

.kpi-label {
  font-size: 0.68rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 0.3rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
.kpi-icon-sm { font-size: 0.8rem; }
.kpi-big {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.kpi-accent  { color: var(--green); }
.kpi-value-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.kpi-sub { font-size: 0.65rem; margin-top: 0.35rem; }
.green-text  { color: var(--text-green); }
.muted-text  { color: var(--text-muted); }

/* Thin progress bar inside KPI cards */
.kpi-progress-bar {
  height: 3px;
  background: var(--bg-4);
  border-radius: 3px;
  margin-top: 0.5rem;
  overflow: hidden;
}
.kpi-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.blue-fill   { background: var(--grad-blue); }
.green-fill  { background: var(--grad-green); }
.gold-fill   { background: var(--grad-gold); }
.purple-fill { background: var(--grad-purple); }

/* Sparkline container */
.kpi-sparkline { height: 32px; margin-top: 0.4rem; }

/* Color variants for KPI cards (matching screenshot gradients) */
.gradient-purple {
  background: linear-gradient(135deg, rgba(168,85,247,0.12) 0%, rgba(109,40,217,0.04) 100%);
  border-color: rgba(168,85,247,0.22);
}
.gradient-blue {
  background: linear-gradient(135deg, rgba(59,130,246,0.12) 0%, rgba(29,78,216,0.04) 100%);
  border-color: rgba(59,130,246,0.2);
}
.gradient-violet {
  background: linear-gradient(135deg, rgba(139,92,246,0.12) 0%, rgba(109,40,217,0.04) 100%);
  border-color: rgba(139,92,246,0.2);
}
.gradient-gold {
  background: linear-gradient(135deg, rgba(245,158,11,0.12) 0%, rgba(180,83,9,0.04) 100%);
  border-color: rgba(245,158,11,0.2);
}


/* ===================================================================
   10. PROGRESS RINGS (small inline SVG rings)
=================================================================== */
.progress-ring-sm {
  position: relative;
  width: 50px;
  height: 50px;
  flex-shrink: 0;
}
.progress-ring-sm svg {
  transform: rotate(-90deg);
  width: 100%;
  height: 100%;
}
.ring-bg {
  fill: none;
  stroke: var(--bg-4);
  stroke-width: 4;
}
.ring-fill {
  fill: none;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 150.8;
  transition: stroke-dashoffset 1.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.ring-green  { stroke: var(--green);  filter: drop-shadow(0 0 5px var(--green-glow)); }
.ring-purple { stroke: var(--purple); filter: drop-shadow(0 0 5px var(--purple-glow)); }
.ring-blue   { stroke: var(--blue);   filter: drop-shadow(0 0 5px var(--blue-glow)); }
.ring-gold   { stroke: var(--gold);   filter: drop-shadow(0 0 5px var(--gold-glow)); }

.ring-center-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.58rem;
  font-weight: 700;
}


/* ===================================================================
   11. MIDDLE ROW (Missions + Schedule)
=================================================================== */
.middle-row {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 0.625rem;
  margin-bottom: 0.875rem;
}

/* Filter tabs above missions list */
.missions-card { height: 100%; }
.mission-filter-tabs { display: flex; gap: 0.275rem; flex-wrap: wrap; }
.tab-btn {
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 500;
  padding: 0.275rem 0.65rem;
  border-radius: 100px;
  transition: all var(--t-fast);
}
.tab-btn:hover { background: var(--bg-4); color: var(--text-primary); }
.tab-btn.active {
  background: var(--green);
  color: #000;
  border-color: var(--green);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(34,197,94,0.35);
}

/* Individual mission rows */
.missions-list { display: flex; flex-direction: column; gap: 0.4rem; }
.mission-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.625rem 0.75rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: all var(--t-fast);
  cursor: pointer;
}
.mission-item:hover {
  background: var(--bg-4);
  border-color: var(--border-bright);
  transform: translateX(2px);
}
.mission-item.completed {
  opacity: 0.55;
}
.mission-item.completed .mission-name {
  text-decoration: line-through;
  color: var(--text-muted);
}

.mission-icon-wrap {
  width: 30px;
  height: 30px;
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}
.mission-info  { flex: 1; min-width: 0; }
.mission-name  { font-size: 0.78rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mission-sub   { font-size: 0.62rem; color: var(--text-muted); margin-top: 1px; }

.mission-progress-wrap { display: flex; align-items: center; gap: 0.4rem; }
.mission-count { font-size: 0.7rem; color: var(--text-sec); white-space: nowrap; }
.mission-xp {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--green);
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.2);
  padding: 0.12rem 0.4rem;
  border-radius: 100px;
  white-space: nowrap;
}
.mission-check {
  width: 19px;
  height: 19px;
  border-radius: 50%;
  border: 2px solid var(--bg-5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.58rem;
  flex-shrink: 0;
  transition: all var(--t-fast);
}
.mission-check.done {
  background: var(--green);
  border-color: var(--green);
  color: #000;
  box-shadow: 0 0 8px rgba(34,197,94,0.4);
}

/* Add custom task button */
.add-task-btn {
  margin-top: 0.65rem;
  width: 100%;
  padding: 0.6rem;
  background: transparent;
  border: 1.5px dashed var(--border-bright);
  border-radius: var(--r-md);
  color: var(--text-muted);
  font-size: 0.775rem;
  font-weight: 500;
  transition: all var(--t-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.add-task-btn:hover {
  border-color: var(--green);
  color: var(--green);
  background: rgba(34,197,94,0.04);
}


/* ===================================================================
   12. TODAY'S SCHEDULE (right-of-missions)
=================================================================== */
.schedule-list { display: flex; flex-direction: column; gap: 0; }
.schedule-item {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  padding: 0.525rem 0;
  border-bottom: 1px solid var(--border);
  position: relative;
}
.schedule-item:last-child { border-bottom: none; }

.schedule-dot-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 5px;
  gap: 0;
  flex-shrink: 0;
}
.schedule-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.schedule-line {
  width: 1px;
  height: 100%;
  background: var(--border);
  flex: 1;
}

.schedule-time { font-size: 0.62rem; color: var(--text-muted); white-space: nowrap; flex-shrink: 0; min-width: 72px; }
.schedule-name { font-size: 0.75rem; font-weight: 600; flex: 1; }
.schedule-badge {
  font-size: 0.6rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 100px;
  white-space: nowrap;
  flex-shrink: 0;
}
.badge-completed { background: rgba(34,197,94,0.15); color: var(--green); border: 1px solid rgba(34,197,94,0.2); }
.badge-pending   { background: rgba(255,255,255,0.05); color: var(--text-muted); border: 1px solid var(--border); }
.badge-break     { background: rgba(245,158,11,0.12); color: var(--gold); border: 1px solid rgba(245,158,11,0.2); }

.add-block-btn {
  margin-top: 0.625rem;
  width: 100%;
  padding: 0.55rem;
  background: transparent;
  border: 1.5px dashed var(--border-bright);
  border-radius: var(--r-md);
  color: var(--text-muted);
  font-size: 0.72rem;
  transition: all var(--t-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.add-block-btn:hover { border-color: var(--green); color: var(--green); }


/* ===================================================================
   13. BOTTOM ROW (multiple 5-col info cards)
=================================================================== */
.bottom-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.625rem;
  margin-bottom: 0.875rem;
}


/* ===================================================================
   14. UPCOMING SESSIONS card
=================================================================== */
.upcoming-list { display: flex; flex-direction: column; gap: 0.35rem; }
.upcoming-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--border);
}
.upcoming-item:last-child { border-bottom: none; }
.upcoming-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.upcoming-time { font-size: 0.62rem; color: var(--text-muted); white-space: nowrap; }
.upcoming-name { font-size: 0.7rem; font-weight: 600; flex: 1; }
.upcoming-dur  { font-size: 0.62rem; color: var(--text-muted); }

.view-all-btn {
  width: 100%;
  margin-top: 0.625rem;
  padding: 0.45rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text-sec);
  font-size: 0.68rem;
  transition: all var(--t-fast);
}
.view-all-btn:hover { background: var(--bg-4); color: var(--text-primary); }


/* ===================================================================
   15. GOALS MINI
=================================================================== */
.goals-list { display: flex; flex-direction: column; gap: 0.55rem; }
.gmi-header { display: flex; justify-content: space-between; margin-bottom: 0.25rem; }
.gmi-name   { font-size: 0.72rem; font-weight: 600; }
.gmi-pct    { font-size: 0.7rem; color: var(--green); font-weight: 700; }
.gmi-bar    { height: 4px; background: var(--bg-4); border-radius: 4px; overflow: hidden; }
.gmi-bar-fill { height: 100%; border-radius: 4px; background: var(--grad-green); transition: width 1s ease; }
.gmi-sub    { font-size: 0.58rem; color: var(--text-muted); margin-top: 2px; }


/* ===================================================================
   16. COMPANIES TARGET card
=================================================================== */
.companies-list { display: flex; flex-direction: column; gap: 0.4rem; }
.company-item { display: flex; align-items: center; gap: 0.5rem; }
.company-logo {
  width: 20px; height: 20px;
  border-radius: 4px;
  background: var(--bg-4);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; flex-shrink: 0;
}
.company-name { font-size: 0.72rem; font-weight: 500; flex: 1; }
.company-bar-wrap { flex: 1.5; height: 3px; background: var(--bg-4); border-radius: 3px; overflow: hidden; }
.company-bar-fill { height: 100%; border-radius: 3px; transition: width 1s ease; }
.company-pct { font-size: 0.62rem; color: var(--text-muted); min-width: 26px; text-align: right; }


/* ===================================================================
   17. ACHIEVEMENTS MINI BADGES
=================================================================== */
.badges-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.4rem; }
.badge-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.55rem 0.25rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: all var(--t-med);
  cursor: pointer;
}
.badge-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-bright);
}
.badge-icon  { font-size: 1.35rem; }
.badge-label { font-size: 0.55rem; color: var(--text-muted); text-align: center; line-height: 1.3; }


/* ===================================================================
   18. QUICK ACTIONS
=================================================================== */
.quick-actions-list { display: flex; flex-direction: column; gap: 0.35rem; }
.qa-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  width: 100%;
  padding: 0.5rem 0.7rem;
  border-radius: var(--r-sm);
  font-size: 0.72rem;
  font-weight: 600;
  transition: all var(--t-fast);
  border: none;
}
.qa-icon { font-size: 0.8rem; }
.qa-green  { background: rgba(34,197,94,0.12);  color: var(--green); }
.qa-green:hover  { background: rgba(34,197,94,0.22); }
.qa-blue   { background: rgba(59,130,246,0.12); color: var(--blue); }
.qa-blue:hover   { background: rgba(59,130,246,0.22); }
.qa-purple { background: rgba(168,85,247,0.12); color: var(--purple); }
.qa-purple:hover { background: rgba(168,85,247,0.22); }
.qa-gold   { background: rgba(245,158,11,0.12); color: var(--gold); }
.qa-gold:hover   { background: rgba(245,158,11,0.22); }


/* ===================================================================
   19. WORK SESSION CARD (home view inline timer)
=================================================================== */
.session-card { display: flex; flex-direction: column; gap: 0.7rem; }
.session-status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--green);
}
.session-status-dot.pulsing { animation: pulse 2s infinite; }

.session-info-row { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.session-name    { font-size: 0.82rem; font-weight: 600; }
.session-target-badge {
  font-size: 0.62rem;
  color: var(--text-sec);
  background: var(--bg-4);
  border: 1px solid var(--border);
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
}

/* Timer ring (small, for home card) */
.timer-ring-container { display: flex; justify-content: center; }
.timer-ring { position: relative; width: 130px; height: 130px; }
.timer-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.timer-ring-bg {
  fill: none; stroke: var(--bg-4); stroke-width: 8;
}
.timer-ring-progress {
  fill: none;
  stroke: var(--green);
  stroke-width: 8;
  stroke-linecap: round;
  stroke-dasharray: 553;
  stroke-dashoffset: 553;
  transition: stroke-dashoffset 1s linear;
  filter: drop-shadow(0 0 10px rgba(34,197,94,0.55));
}
.timer-display {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.timer-time {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.15rem; font-weight: 700;
  letter-spacing: -0.5px;
}
.timer-mode-label { font-size: 0.58rem; color: var(--text-muted); margin-top: 2px; }

/* Timer controls */
.timer-controls { display: flex; justify-content: center; gap: 0.65rem; }
.timer-btn {
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t-fast);
}
.timer-play  { background: var(--green); color: #000; box-shadow: var(--shadow-green); }
.timer-play:hover { transform: scale(1.12); box-shadow: 0 6px 22px rgba(34,197,94,0.45); }
.timer-stop  { background: var(--red); color: #fff; }
.timer-stop:hover  { transform: scale(1.08); }
.timer-reset { background: var(--bg-4); color: var(--text-sec); border: 1px solid var(--border); }
.timer-reset:hover { color: var(--text-primary); }

/* Questions checklist inside session */
.qp-header  { display: flex; justify-content: space-between; margin-bottom: 0.45rem; }
.qp-title   { font-size: 0.775rem; font-weight: 600; }
.qp-status  { font-size: 0.7rem; color: var(--green); font-weight: 600; }
.questions-list { display: flex; flex-direction: column; gap: 0.3rem; }
.q-item {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 0.55rem;
  background: var(--bg-3); border-radius: var(--r-sm);
  transition: all var(--t-fast); cursor: pointer;
}
.q-item:hover { background: var(--bg-4); }
.q-checkbox {
  width: 16px; height: 16px; border-radius: 4px;
  border: 2px solid var(--bg-5);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.55rem; flex-shrink: 0;
  transition: all var(--t-fast);
}
.q-checkbox.checked { background: var(--green); border-color: var(--green); color: #000; }
.q-name { flex: 1; font-size: 0.72rem; }
.q-done-icon { font-size: 0.82rem; }

/* Session completion banner */
.session-complete-banner {
  background: linear-gradient(135deg, rgba(34,197,94,0.18) 0%, rgba(34,197,94,0.04) 100%);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: var(--r-md);
  padding: 0.7rem; text-align: center;
  font-size: 0.82rem; font-weight: 600;
  animation: bounceIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}
.xp-reward { color: var(--green); margin-left: 0.4rem; }


/* ===================================================================
   20. DASHBOARD VIEW — Stats Overview
=================================================================== */
.stats-overview-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.625rem;
  margin-bottom: 0.875rem;
}
.stat-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 0.875rem;
  display: flex;
  gap: 0.65rem;
  align-items: center;
  transition: all var(--t-med);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.stat-icon {
  width: 38px; height: 38px;
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.stat-icon-yellow { background: rgba(245,158,11,0.14); }
.stat-icon-green  { background: rgba(34,197,94,0.14); }
.stat-icon-blue   { background: rgba(59,130,246,0.14); }
.stat-icon-purple { background: rgba(168,85,247,0.14); }
.stat-icon-orange { background: rgba(249,115,22,0.14); }
.stat-icon-red    { background: rgba(239,68,68,0.14); }
.stat-number { font-family: 'Space Grotesk', sans-serif; font-size: 1.05rem; font-weight: 700; }
.stat-label  { font-size: 0.65rem; color: var(--text-muted); }
.stat-change { font-size: 0.6rem; }
.stat-change.positive { color: var(--green); }
.stat-change.negative { color: var(--red); }

/* Dashboard mid-row */
.dash-mid-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.625rem;
  margin-bottom: 0.875rem;
}


/* ===================================================================
   21. CONSISTENCY CALENDAR
=================================================================== */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 0.7rem;
}
.cal-day-header {
  font-size: 0.58rem;
  color: var(--text-muted);
  text-align: center;
  padding: 2px 0;
  font-weight: 600;
}
.cal-day {
  aspect-ratio: 1;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--t-fast);
  position: relative;
}
.cal-day:hover { transform: scale(1.2); z-index: 2; }
.cal-day.green-day  { background: rgba(34,197,94,0.78); color: #000; }
.cal-day.yellow-day { background: rgba(245,158,11,0.72); color: #000; }
.cal-day.red-day    { background: rgba(239,68,68,0.55); color: #fff; }
.cal-day.future     { background: var(--bg-3); color: var(--text-muted); cursor: default; }
.cal-day.today      { box-shadow: 0 0 0 2px var(--green); }
.cal-day.empty      { background: transparent; cursor: default; }

.cal-legend { display: flex; gap: 0.875rem; flex-wrap: wrap; }
.leg-item   { display: flex; align-items: center; gap: 0.3rem; font-size: 0.62rem; color: var(--text-muted); }
.leg-dot    { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.green-dot  { background: rgba(34,197,94,0.78); }
.yellow-dot { background: rgba(245,158,11,0.72); }
.red-dot    { background: rgba(239,68,68,0.55); }
.grey-dot   { background: var(--bg-3); border: 1px solid var(--border); }
.blue-dot   { background: rgba(59,130,246,0.72); }
.purple-dot { background: rgba(168,85,247,0.72); }


/* ===================================================================
   22. WEEKLY RINGS GRID
=================================================================== */
.rings-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.625rem; }
.ring-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0.7rem 0.5rem;
}
.ring-item-circle {
  position: relative;
  width: 66px; height: 66px;
}
.ring-item-circle svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.ric-bg   { fill: none; stroke: var(--bg-4); stroke-width: 6; }
.ric-fill {
  fill: none; stroke-width: 6;
  stroke-linecap: round;
  stroke-dasharray: 188.5;
  transition: stroke-dashoffset 1.6s ease;
}
.ring-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.ring-c-val  { font-size: 0.68rem; font-weight: 700; }
.ring-c-lbl  { font-size: 0.5rem; color: var(--text-muted); }
.ring-item-name { font-size: 0.62rem; color: var(--text-muted); font-weight: 500; text-align: center; }


/* ===================================================================
   23. SUBJECT PROGRESS
=================================================================== */
.subject-list { display: flex; flex-direction: column; gap: 0.6rem; }
.sub-header   { display: flex; justify-content: space-between; margin-bottom: 0.22rem; }
.sub-name     { display: flex; align-items: center; gap: 0.35rem; font-size: 0.75rem; font-weight: 600; }
.sub-icon     { font-size: 0.8rem; }
.sub-pct      { font-size: 0.7rem; font-weight: 700; }
.sub-bar      { height: 4px; background: var(--bg-4); border-radius: 4px; overflow: hidden; }
.sub-bar-fill { height: 100%; border-radius: 4px; transition: width 1.2s ease; }


/* ===================================================================
   24. CHART CARDS
=================================================================== */
.chart-card { padding: 1.125rem; }
.chart-container { height: 190px; position: relative; }
.chart-container canvas { width: 100% !important; }


/* ===================================================================
   25. SESSIONS VIEW
=================================================================== */
.sessions-layout { display: grid; grid-template-columns: 1fr 300px; gap: 0.875rem; }

.session-full-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 0.875rem; }
.session-big-name    { font-family: 'Space Grotesk', sans-serif; font-size: 1.15rem; font-weight: 700; }
.session-date-text   { font-size: 0.7rem; color: var(--text-muted); }
.session-badges      { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.badge {
  font-size: 0.65rem;
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
  border: 1px solid;
}
.badge-target { background: rgba(34,197,94,0.1); border-color: rgba(34,197,94,0.3); color: var(--green); }
.badge-status { background: rgba(239,68,68,0.1); border-color: rgba(239,68,68,0.3); color: var(--red); }

.session-details-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.625rem;
  margin-bottom: 1.125rem;
}
.sd-item {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0.7rem;
}
.sd-label { font-size: 0.6rem; color: var(--text-muted); margin-bottom: 2px; }
.sd-val   { font-size: 0.875rem; font-weight: 700; }
.sd-xp    { color: var(--green); }

/* Big timer ring */
.session-main-row { display: grid; grid-template-columns: 260px 1fr; gap: 1.375rem; }
.big-timer-container { display: flex; flex-direction: column; align-items: center; gap: 0.875rem; }
.big-timer-ring { position: relative; width: 220px; height: 220px; }
.big-timer-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
#timer-ring-big {
  stroke-dasharray: 722.6;
  stroke-dashoffset: 722.6;
  stroke: var(--green);
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  filter: drop-shadow(0 0 14px rgba(34,197,94,0.55));
  transition: stroke-dashoffset 1s linear;
}
.big-timer-inner {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.big-timer-time {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.875rem; font-weight: 700;
  letter-spacing: -1.5px;
}
.big-timer-lbl { font-size: 0.62rem; color: var(--text-muted); }

.big-timer-controls { display: flex; gap: 0.625rem; }
.btc-btn {
  display: flex; align-items: center; gap: 0.45rem;
  padding: 0.6rem 1.125rem;
  border-radius: var(--r-md);
  font-size: 0.78rem; font-weight: 600;
  transition: all var(--t-fast);
}
.btc-play { background: var(--green); color: #000; box-shadow: var(--shadow-green); }
.btc-play:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(34,197,94,0.45); }
.btc-stop { background: var(--bg-4); color: var(--text-sec); border: 1px solid var(--border); }
.btc-stop:hover { background: rgba(239,68,68,0.15); color: var(--red); border-color: var(--red); }

/* Questions tracker in sessions */
.questions-tracker { display: flex; flex-direction: column; }
.qt-header { display: flex; justify-content: space-between; margin-bottom: 0.7rem; font-size: 0.82rem; font-weight: 600; }
.qt-count  { color: var(--green); font-weight: 700; }
.qt-list   { display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.qt-item {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.6rem 0.7rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: all var(--t-fast);
}
.qt-item:hover { background: var(--bg-4); border-color: var(--border-bright); }
.qt-item.done  { border-color: rgba(34,197,94,0.28); background: rgba(34,197,94,0.04); }
.qt-item.done .qt-name { text-decoration: line-through; color: var(--text-muted); }
.qt-check {
  width: 20px; height: 20px;
  border-radius: 5px;
  border: 2px solid var(--border-bright);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; flex-shrink: 0;
  transition: all var(--t-fast);
}
.qt-check.checked { background: var(--green); border-color: var(--green); color: #000; }
.qt-name { flex: 1; font-size: 0.75rem; font-weight: 500; }
.qt-xp   { font-size: 0.62rem; color: var(--green); font-weight: 700; }

.add-q-btn {
  margin-top: 0.7rem; padding: 0.45rem;
  background: transparent;
  border: 1.5px dashed var(--border-bright);
  border-radius: var(--r-sm);
  color: var(--text-muted); font-size: 0.72rem;
  transition: all var(--t-fast);
  width: 100%;
}
.add-q-btn:hover { border-color: var(--green); color: var(--green); }

/* Past sessions */
.past-sessions-list { display: flex; flex-direction: column; gap: 0.45rem; }
.ps-item {
  padding: 0.7rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: all var(--t-fast);
}
.ps-item:hover { background: var(--bg-4); }
.ps-header { display: flex; justify-content: space-between; margin-bottom: 0.3rem; }
.ps-name   { font-size: 0.75rem; font-weight: 600; }
.ps-date   { font-size: 0.6rem; color: var(--text-muted); }
.ps-stats  { display: flex; gap: 0.7rem; }
.ps-stat   { font-size: 0.62rem; color: var(--text-muted); }
.ps-stat span { color: var(--text-primary); font-weight: 600; }


/* ===================================================================
   26. PROGRESS VIEW
=================================================================== */
.progress-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  grid-template-rows: auto auto;
  gap: 0.875rem;
}
.readiness-card {
  grid-row: span 1;
  display: flex; flex-direction: column; align-items: center;
}
.big-readiness-ring {
  position: relative;
  width: 170px; height: 170px;
  margin: 0.875rem auto;
}
.big-readiness-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-purple-lg {
  stroke: var(--purple);
  filter: drop-shadow(0 0 10px var(--purple-glow));
  stroke-dasharray: 596.9;
}
.readiness-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.readiness-pct {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.875rem; font-weight: 700;
  color: var(--purple);
}
.readiness-lbl { font-size: 0.68rem; color: var(--text-muted); }

.readiness-breakdown { width: 100%; display: flex; flex-direction: column; gap: 0.45rem; }
.rb-item { display: flex; align-items: center; gap: 0.45rem; }
.rb-icon { font-size: 0.82rem; }
.rb-name { font-size: 0.7rem; flex: 1; }
.rb-val  { font-size: 0.7rem; font-weight: 700; }
.rb-bar  { flex: 2; height: 4px; background: var(--bg-4); border-radius: 4px; overflow: hidden; }
.rb-bar-fill { height: 100%; border-radius: 4px; background: var(--grad-purple); }

.subjects-card-full { grid-row: span 1; }
.subjects-full-list { display: flex; flex-direction: column; gap: 0.8rem; }
.sf-header { display: flex; justify-content: space-between; margin-bottom: 0.3rem; }
.sf-name   { font-size: 0.78rem; font-weight: 600; display: flex; align-items: center; gap: 0.35rem; }
.sf-nums   { font-size: 0.7rem; color: var(--text-muted); }
.sf-pct    { font-size: 0.7rem; font-weight: 700; }
.sf-bar    { height: 6px; background: var(--bg-4); border-radius: 6px; overflow: hidden; }
.sf-bar-fill { height: 100%; border-radius: 6px; transition: width 1.5s cubic-bezier(0.4,0,0.2,1); }

/* GitHub-style heatmap */
.heatmap-card { grid-column: span 2; }
.heatmap-grid { display: flex; gap: 3px; overflow-x: auto; padding-bottom: 0.5rem; }
.heatmap-week { display: flex; flex-direction: column; gap: 3px; }
.hm-cell {
  width: 13px; height: 13px; border-radius: 2px;
  transition: transform var(--t-fast); cursor: pointer;
}
.hm-cell:hover { transform: scale(1.35); z-index: 2; }
.hm-0 { background: var(--bg-3); }
.hm-1 { background: rgba(34,197,94,0.25); }
.hm-2 { background: rgba(34,197,94,0.5); }
.hm-3 { background: rgba(34,197,94,0.75); }
.hm-4 { background: rgba(34,197,94,1); }
.heatmap-months {
  display: flex; gap: 0;
  font-size: 0.58rem; color: var(--text-muted);
  margin-top: 0.3rem;
  overflow-x: auto;
}


/* ===================================================================
   27. GOALS VIEW
=================================================================== */
.goals-layout {
  display: grid;
  grid-template-columns: 290px 1fr 265px;
  gap: 0.875rem;
}

.form-group { margin-bottom: 0.8rem; }
.form-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-sec);
  margin-bottom: 0.35rem;
  letter-spacing: 0.01em;
}
.form-input {
  width: 100%;
  padding: 0.575rem 0.75rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text-primary);
  font-size: 0.78rem;
  transition: all var(--t-fast);
}
.form-input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(34,197,94,0.1);
}
.form-input::placeholder { color: var(--text-muted); }

.duration-tabs { display: flex; gap: 0.3rem; flex-wrap: wrap; }
.dur-btn {
  padding: 0.3rem 0.7rem;
  border-radius: var(--r-sm);
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.7rem;
  transition: all var(--t-fast);
}
.dur-btn:hover { background: var(--bg-4); color: var(--text-primary); }
.dur-btn.active {
  background: var(--green);
  color: #000;
  border-color: var(--green);
  font-weight: 600;
}

/* Primary CTA button (green) */
.cta-btn {
  background: var(--grad-green);
  color: #000;
  border: none;
  border-radius: var(--r-md);
  padding: 0.6rem 1.125rem;
  font-size: 0.78rem;
  font-weight: 700;
  box-shadow: var(--shadow-green);
  transition: all var(--t-fast);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(34,197,94,0.45);
}

/* Active goals list */
.active-goals-list { display: flex; flex-direction: column; gap: 0.7rem; }
.goal-item {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0.875rem;
  transition: all var(--t-fast);
}
.goal-item:hover { border-color: var(--border-bright); }
.goal-item-header { display: flex; justify-content: space-between; margin-bottom: 0.45rem; }
.goal-item-name   { font-size: 0.82rem; font-weight: 600; }
.goal-item-pct    { font-size: 0.82rem; font-weight: 700; color: var(--green); }
.goal-item-bar    { height: 5px; background: var(--bg-4); border-radius: 5px; overflow: hidden; margin-bottom: 0.35rem; }
.goal-item-fill   { height: 100%; border-radius: 5px; background: var(--grad-green); transition: width 1.2s ease; }
.goal-item-sub    { display: flex; justify-content: space-between; }
.goal-item-progress { font-size: 0.65rem; color: var(--text-muted); }
.goal-item-unit   {
  font-size: 0.62rem; color: var(--text-sec);
  background: var(--bg-4);
  padding: 0.1rem 0.4rem;
  border-radius: 100px;
}

/* Milestones list */
.milestones-list { display: flex; flex-direction: column; gap: 0.45rem; }
.milestone-item {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.7rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}
.ms-icon { font-size: 1rem; }
.ms-name { font-size: 0.75rem; font-weight: 600; flex: 1; }
.ms-days {
  font-size: 0.62rem;
  background: rgba(34,197,94,0.1);
  color: var(--green);
  padding: 0.18rem 0.5rem;
  border-radius: 100px;
  white-space: nowrap;
}
.ms-days.red { background: rgba(239,68,68,0.1); color: var(--red); }


/* ===================================================================
   28. ANALYTICS VIEW
=================================================================== */
.analytics-layout {
  display: grid;
  grid-template-columns: 1fr 250px;
  grid-template-rows: auto auto;
  gap: 0.875rem;
}
.analytics-hero { grid-row: span 2; }
.analytics-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.875rem;
  margin-bottom: 1.25rem;
}
.an-stat {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0.875rem;
  text-align: center;
}
.an-icon { font-size: 1.4rem; margin-bottom: 0.3rem; }
.an-val  { font-family: 'Space Grotesk', sans-serif; font-size: 1.35rem; font-weight: 700; }
.an-lbl  { font-size: 0.65rem; color: var(--text-muted); }

.chart-title { font-size: 0.82rem; font-weight: 600; margin-bottom: 0.875rem; }
.bar-chart-container {
  height: 165px;
  display: flex; align-items: flex-end; gap: 5px;
}
.bar-chart-bar-wrap {
  display: flex; flex-direction: column; align-items: center; flex: 1; gap: 3px;
}
.bar-chart-bar {
  width: 100%; border-radius: 4px 4px 0 0;
  background: linear-gradient(to top, rgba(34,197,94,0.3) 0%, rgba(34,197,94,0.8) 100%);
  transition: height 1.5s cubic-bezier(0.4,0,0.2,1);
  cursor: pointer;
}
.bar-chart-bar:hover {
  background: linear-gradient(to top, rgba(34,197,94,0.5) 0%, var(--green) 100%);
}
.bar-chart-lbl { font-size: 0.52rem; color: var(--text-muted); }

/* Donut chart */
.donut-card {}
.donut-container { display: flex; justify-content: center; margin-bottom: 0.875rem; }
.donut-legend { display: flex; flex-direction: column; gap: 0.35rem; }
.dl-item { display: flex; align-items: center; gap: 0.45rem; font-size: 0.7rem; }
.dl-dot  { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dl-name { flex: 1; color: var(--text-sec); }
.dl-pct  { font-weight: 700; }

/* Analytics heatmap */
.heatmap-card-an { grid-column: span 1; }
.heatmap-grid-an { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }


/* ===================================================================
   29. ACHIEVEMENTS VIEW
=================================================================== */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 0.7rem;
}
.achievement-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 1.125rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.45rem;
  cursor: pointer;
  transition: all var(--t-med);
  position: relative; overflow: hidden;
}
.achievement-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.achievement-card.unlocked { border-color: rgba(245,158,11,0.28); }
.achievement-card.locked   { opacity: 0.38; }
.achievement-card.unlocked::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(245,158,11,0.09) 0%, transparent 70%);
}
.ach-badge  { font-size: 2.25rem; filter: drop-shadow(0 4px 10px rgba(0,0,0,0.35)); }
.ach-name   { font-size: 0.72rem; font-weight: 700; text-align: center; }
.ach-desc   { font-size: 0.6rem; color: var(--text-muted); text-align: center; }
.ach-xp {
  font-size: 0.62rem;
  color: var(--gold);
  font-weight: 700;
  background: rgba(245,158,11,0.1);
  padding: 0.12rem 0.45rem;
  border-radius: 100px;
}
.ach-locked-badge { position: absolute; top: 0.45rem; right: 0.45rem; font-size: 0.8rem; opacity: 0.45; }


/* ===================================================================
   30. ROADMAP VIEW
=================================================================== */
.roadmap-container { position: relative; }
.roadmap-phase { margin-bottom: 1.875rem; position: relative; }
.roadmap-phase-header {
  display: flex; align-items: center; gap: 0.7rem;
  margin-bottom: 0.875rem;
}
.rp-num {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--grad-green); color: #000;
  font-size: 0.72rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; box-shadow: var(--shadow-green);
}
.rp-phase-title { font-family: 'Space Grotesk', sans-serif; font-size: 0.95rem; font-weight: 700; }
.rp-phase-sub   { font-size: 0.7rem; color: var(--text-muted); }
.roadmap-cards  { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 0.625rem; }
.roadmap-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 0.875rem;
  transition: all var(--t-med);
}
.roadmap-card:hover { transform: translateY(-2px); border-color: var(--border-bright); }
.rc-icon { font-size: 1.4rem; margin-bottom: 0.45rem; }
.rc-name { font-size: 0.78rem; font-weight: 600; margin-bottom: 0.22rem; }
.rc-desc { font-size: 0.65rem; color: var(--text-muted); }
.rc-status {
  display: inline-block; margin-top: 0.45rem;
  font-size: 0.6rem; padding: 0.12rem 0.45rem;
  border-radius: 100px;
}
.rc-done   { background: rgba(34,197,94,0.14); color: var(--green); }
.rc-active { background: rgba(245,158,11,0.14); color: var(--gold); }
.rc-locked { background: rgba(255,255,255,0.05); color: var(--text-muted); }


/* ===================================================================
   31. RIGHT PANEL
=================================================================== */
.right-panel {
  background: var(--bg-1);
  border-left: 1px solid var(--border);
  height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}
.rp-section {
  padding: 0.875rem 0.875rem;
  border-bottom: 1px solid var(--border);
}
.rp-section-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 0.65rem;
}
.rp-title {
  font-size: 0.775rem; font-weight: 600;
  margin-bottom: 0.65rem;
  letter-spacing: -0.01em;
}

/* Mini progress rings in right panel */
.rp-rings { display: flex; flex-direction: column; gap: 0.45rem; }
.rp-ring-row { display: flex; align-items: center; gap: 0.45rem; }
.rp-ring-mini { position: relative; width: 36px; height: 36px; flex-shrink: 0; }
.rp-ring-mini svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.rp-ring-bg   { fill: none; stroke: var(--bg-4); stroke-width: 5; }
.rp-ring-fill {
  fill: none; stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 101;
  transition: stroke-dashoffset 1.5s ease;
}
.rp-ring-label { font-size: 0.65rem; font-weight: 600; }
.rp-ring-sub   { font-size: 0.56rem; color: var(--text-muted); }
.rp-chart { height: 115px; }

/* Mini select dropdowns */
.mini-select {
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--text-sec);
  font-size: 0.65rem;
  padding: 0.22rem 0.45rem;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: border-color var(--t-fast);
}
.mini-select:hover { border-color: var(--border-bright); }
.mini-select-sm { padding: 0.15rem 0.35rem; font-size: 0.6rem; }

/* Upcoming sessions in right panel */
.rp-upcoming { display: flex; flex-direction: column; gap: 0.35rem; }
.rp-up-item {
  display: flex; align-items: center; gap: 0.45rem;
  padding: 0.45rem;
  background: var(--bg-2);
  border-radius: var(--r-sm);
}
.rp-up-time { font-size: 0.6rem; color: var(--green); font-weight: 700; white-space: nowrap; }
.rp-up-name { font-size: 0.68rem; flex: 1; }
.rp-up-dur  { font-size: 0.58rem; color: var(--text-muted); }


/* ===================================================================
   32. MOBILE BOTTOM NAV
=================================================================== */
.mobile-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--mobile-nav-h);
  background: rgba(15, 18, 22, 0.96);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-top: 1px solid var(--border);
  align-items: center;
  justify-content: space-around;
  padding: 0 0.375rem;
}
.mn-item {
  display: flex; flex-direction: column; align-items: center; gap: 0.22rem;
  color: var(--text-muted); font-size: 0.58rem; flex: 1;
  padding: 0.45rem;
  transition: color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.mn-item.active { color: var(--green); }
.mn-icon { font-size: 1.15rem; }
.mn-lbl  { font-size: 0.55rem; }
.mn-fab {
  background: var(--grad-green);
  width: 46px; height: 46px;
  border-radius: 50%;
  color: #000 !important;
  box-shadow: var(--shadow-green);
  flex: 0; align-self: center;
  margin-bottom: 18px;
}
.mn-fab-icon { font-size: 1.4rem; font-weight: 300; }


/* ===================================================================
   33. NOTES & RESOURCES
=================================================================== */
.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 0.7rem;
}
.note-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 0.875rem;
  cursor: pointer;
  transition: all var(--t-med);
}
.note-card:hover { transform: translateY(-2px); border-color: var(--border-bright); }
.note-title   { font-size: 0.82rem; font-weight: 600; margin-bottom: 0.45rem; }
.note-content { font-size: 0.72rem; color: var(--text-muted); line-height: 1.55; }
.note-date    { font-size: 0.6rem; color: var(--text-muted); margin-top: 0.7rem; }
.note-tag {
  display: inline-block;
  font-size: 0.58rem;
  padding: 0.12rem 0.45rem;
  border-radius: 100px;
  margin-right: 0.25rem;
}

.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
  gap: 0.7rem;
}
.resource-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 0.875rem;
  transition: all var(--t-med); cursor: pointer;
}
.resource-card:hover { transform: translateY(-2px); border-color: var(--border-bright); }
.rc-type   { font-size: 1.4rem; margin-bottom: 0.45rem; }
.rc-rtitle { font-size: 0.78rem; font-weight: 600; margin-bottom: 0.22rem; }
.rc-rsub   { font-size: 0.65rem; color: var(--text-muted); }


/* ===================================================================
   34. MODAL
=================================================================== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.modal-box {
  background: var(--bg-2);
  border: 1px solid var(--border-bright);
  border-radius: var(--r-2xl);
  padding: 1.625rem;
  width: 90%; max-width: 420px;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.92) translateY(-16px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.05rem; font-weight: 700;
  margin-bottom: 1.125rem;
  letter-spacing: -0.025em;
}
.modal-actions {
  display: flex; gap: 0.45rem;
  justify-content: flex-end;
  margin-top: 1.125rem;
}
.modal-cancel {
  padding: 0.5rem 0.95rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text-sec); font-size: 0.78rem;
  transition: all var(--t-fast);
}
.modal-cancel:hover { background: var(--bg-4); color: var(--text-primary); }


/* ===================================================================
   35. NOTIFICATION PANEL
=================================================================== */
.notif-panel {
  position: fixed; top: 72px; right: 80px; z-index: 500;
  width: 290px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  animation: fadeSlideIn 0.2s ease;
  overflow: hidden;
}
.notif-panel-header {
  padding: 0.7rem 0.875rem;
  font-size: 0.78rem; font-weight: 600;
  border-bottom: 1px solid var(--border);
}
.notif-item {
  display: flex; align-items: flex-start; gap: 0.7rem;
  padding: 0.7rem 0.875rem;
  border-bottom: 1px solid var(--border);
  transition: background var(--t-fast);
}
.notif-item:hover  { background: var(--bg-3); }
.notif-item:last-child { border-bottom: none; }
.notif-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; margin-top: 4px; }
.notif-msg  { font-size: 0.72rem; }
.notif-time { font-size: 0.6rem; color: var(--text-muted); margin-top: 2px; }


/* ===================================================================
   36. XP TOAST
=================================================================== */
.xp-toast {
  position: fixed; top: 78px; right: 18px; z-index: 2000;
  background: linear-gradient(135deg, rgba(34,197,94,0.92), rgba(21,128,61,0.92));
  color: #000; font-weight: 800; font-size: 0.875rem;
  padding: 0.55rem 1.125rem; border-radius: var(--r-lg);
  box-shadow: var(--shadow-green);
  display: flex; align-items: center; gap: 0.45rem;
  animation: toastIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}
.xp-toast.hidden { display: none; }
.xp-toast-icon { font-size: 1rem; }
@keyframes toastIn {
  from { transform: translateX(80px) scale(0.8); opacity: 0; }
  to   { transform: translateX(0) scale(1); opacity: 1; }
}
@keyframes toastOut {
  from { transform: translateX(0) scale(1); opacity: 1; }
  to   { transform: translateX(80px) scale(0.8); opacity: 0; }
}


/* ===================================================================
   37. CONFETTI
=================================================================== */
#confetti-container {
  position: fixed; inset: 0;
  pointer-events: none; z-index: 9999;
  overflow: hidden;
}
.confetti-piece {
  position: absolute; top: -10px;
  width: 8px; height: 8px; border-radius: 2px;
  animation: confettiFall linear forwards;
}
@keyframes confettiFall {
  0%   { transform: translateY(-10px) rotateZ(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotateZ(720deg); opacity: 0; }
}


/* ===================================================================
   38. SHARED ANIMATIONS
=================================================================== */
@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34,197,94,0.45); }
  50%       { opacity: 0.75; box-shadow: 0 0 0 7px rgba(34,197,94,0); }
}
@keyframes bounceIn {
  from { transform: scale(0.8); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}
@keyframes shimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Loading shimmer effect */
.shimmer {
  position: relative; overflow: hidden;
}
.shimmer::after {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.04), transparent);
  animation: shimmer 2.5s infinite;
}


/* ===================================================================
   39. UTILITY CLASSES
=================================================================== */
.hidden       { display: none !important; }
.flex         { display: flex; }
.flex-center  { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.text-green   { color: var(--green); }
.text-gold    { color: var(--gold); }
.text-purple  { color: var(--purple); }
.text-blue    { color: var(--blue); }
.text-red     { color: var(--red); }
.text-muted   { color: var(--text-muted); }
.font-mono    { font-family: 'Space Grotesk', sans-serif; }
.fw-700       { font-weight: 700; }
.fw-600       { font-weight: 600; }
.mt-05        { margin-top: 0.5rem; }
.mt-1         { margin-top: 1rem; }
.mb-05        { margin-bottom: 0.5rem; }
.mb-1         { margin-bottom: 1rem; }
.w-full       { width: 100%; }


/* ===================================================================
   40. RESPONSIVE — Tablet (≤1400px): hide right panel
=================================================================== */
@media (max-width: 1400px) {
  .right-panel { display: none; }
  .app-wrapper { grid-template-columns: var(--sidebar-w) 1fr; }
  .kpi-row     { grid-template-columns: repeat(4, 1fr); }
  .bottom-row  { grid-template-columns: repeat(4, 1fr); }
  .stats-overview-row { grid-template-columns: repeat(4, 1fr); }
}

/* ===================================================================
   41. RESPONSIVE — Small Desktop/Tablet (≤1200px): collapse sidebar
=================================================================== */
@media (max-width: 1200px) {
  :root { --sidebar-w: var(--sidebar-w-collapsed); }
  .logo-text,
  .nav-label,
  .sidebar-motivator,
  .sidebar-profile .profile-info,
  .sidebar-xp-bar .xp-label,
  .sidebar-streak,
  .logo-tagline { display: none; }
  .nav-item { justify-content: center; padding: 0.625rem; }
  .nav-icon { width: auto; }
  .sidebar-header { justify-content: center; }
  .sidebar-toggle { display: none; }
  .sidebar-profile { justify-content: center; padding: 0.45rem; }
  .kpi-row { grid-template-columns: repeat(3, 1fr); }
  .bottom-row { grid-template-columns: repeat(3, 1fr); }
  .stats-overview-row { grid-template-columns: repeat(3, 1fr); }
  .dash-mid-row { grid-template-columns: 1fr 1fr; }
  .goals-layout { grid-template-columns: 1fr 1fr; }
  .sessions-layout { grid-template-columns: 1fr; }
  .progress-layout { grid-template-columns: 1fr 1fr; }
  .session-main-row { grid-template-columns: 220px 1fr; }
}

/* ===================================================================
   42. RESPONSIVE — Tablet (≤900px)
=================================================================== */
@media (max-width: 900px) {
  .middle-row { grid-template-columns: 1fr; }
  .kpi-row { grid-template-columns: repeat(3, 1fr); }
  .bottom-row { grid-template-columns: repeat(2, 1fr); }
  .goals-layout { grid-template-columns: 1fr; }
  .dash-mid-row { grid-template-columns: 1fr 1fr; }
  .analytics-layout { grid-template-columns: 1fr 200px; }
  .session-main-row { grid-template-columns: 1fr; }
  .big-timer-container { align-items: flex-start; flex-direction: row; gap: 1.5rem; }
}

/* ===================================================================
   43. RESPONSIVE — Mobile (≤768px): full mobile layout
=================================================================== */
@media (max-width: 768px) {
  .app-wrapper    { grid-template-columns: 1fr; }
  .sidebar        { display: none; }
  .mobile-nav     { display: flex; }
  .main-content   { padding-bottom: var(--mobile-nav-h); }
  .views-container { padding: 0.75rem; }
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .middle-row     { grid-template-columns: 1fr; }
  .bottom-row     { grid-template-columns: 1fr 1fr; }
  .stats-overview-row { grid-template-columns: repeat(2, 1fr); }
  .dash-mid-row   { grid-template-columns: 1fr; }
  .goals-layout   { grid-template-columns: 1fr; }
  .analytics-layout { grid-template-columns: 1fr; }
  .sessions-layout { grid-template-columns: 1fr; }
  .session-details-row { grid-template-columns: repeat(2, 1fr); }
  .progress-layout { grid-template-columns: 1fr; }
  .heatmap-card   { grid-column: span 1; }
  .session-main-row { grid-template-columns: 1fr; }
  .big-timer-container { align-items: center; flex-direction: column; }
  .topbar-center  { display: none; }
  .topbar-left .topbar-sub { display: none; }
}

/* ===================================================================
   44. RESPONSIVE — Small Mobile (≤480px)
=================================================================== */
@media (max-width: 480px) {
  html { font-size: 13px; }
  .kpi-row  { grid-template-columns: 1fr 1fr; }
  .bottom-row { grid-template-columns: 1fr; }
  .analytics-stats-row { grid-template-columns: 1fr; }
  .rings-grid { grid-template-columns: repeat(2, 1fr); }
  .topbar  { padding: 0 0.7rem; }
  .topbar-stat { display: none; }
  .achievements-grid { grid-template-columns: repeat(2, 1fr); }
  .kpi-big { font-size: 1.35rem; }
  .card { padding: 0.875rem; }
  .views-container { padding: 0.625rem; }
  .session-details-row { grid-template-columns: 1fr 1fr; }
}

/* ===================================================================
   45. FOCUS MODE / PRINT UTILITIES
=================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ===================================================================
   46. MISSIONS FULL VIEW (Missions page)
=================================================================== */
.missions-full-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 0.875rem;
}
.mission-full-item {
  display: flex; align-items: center; gap: 0.875rem;
  padding: 0.875rem 1rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  transition: all var(--t-fast);
  cursor: pointer;
  margin-bottom: 0.5rem;
}
.mission-full-item:hover { background: var(--bg-4); border-color: var(--border-bright); transform: translateX(3px); }
.mission-full-item.completed { opacity: 0.5; }
.mission-full-item.completed .mission-name { text-decoration: line-through; }
.mf-icon {
  width: 36px; height: 36px;
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.mf-info { flex: 1; min-width: 0; }
.mf-name { font-size: 0.875rem; font-weight: 600; }
.mf-sub  { font-size: 0.65rem; color: var(--text-muted); }
.mf-right { display: flex; align-items: center; gap: 0.75rem; flex-shrink: 0; }
.mf-count { font-size: 0.78rem; font-weight: 600; }
.mf-xp-badge {
  font-size: 0.65rem; font-weight: 700;
  color: var(--green);
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.2);
  padding: 0.15rem 0.45rem;
  border-radius: 100px;
}
.mf-check {
  width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--bg-5);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; flex-shrink: 0;
  transition: all var(--t-fast);
}
.mf-check.done { background: var(--green); border-color: var(--green); color: #000; box-shadow: 0 0 8px rgba(34,197,94,0.4); }

/* Level badge */
.level-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: linear-gradient(135deg, rgba(245,158,11,0.15), rgba(245,158,11,0.05));
  border: 1px solid rgba(245,158,11,0.25);
  padding: 0.3rem 0.65rem;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--gold);
}
/* =====================================================
   LIGHT THEME OVERRIDES
===================================================== */
body.light-theme {
  --bg-base:       #f4f6fa;
  --bg-1:          #ffffff;
  --bg-2:          #f1f4f9;
  --bg-3:          #e8ecf3;
  --bg-4:          #dde3ee;
  --bg-5:          #cfd7e6;
  --bg-glass:      rgba(255, 255, 255, 0.75);
  --bg-glass-light: rgba(241, 244, 249, 0.7);

  --border:         rgba(15,23,42,0.08);
  --border-bright:  rgba(15,23,42,0.14);

  --text-primary:  #0f172a;
  --text-sec:      #475569;
  --text-muted:    #94a3b8;
  --text-faint:    #cbd5e1;
}

body.light-theme,
body.light-theme .view,
body.light-theme .card,
body.light-theme .sidebar,
body.light-theme .topbar {
  background: var(--bg-base);
  color: var(--text-primary);
}

body.light-theme .card,
body.light-theme .kpi-card,
body.light-theme .stat-card,
body.light-theme .note-card,
body.light-theme .resource-card,
body.light-theme .session-full-card,
body.light-theme .sidebar,
body.light-theme .modal,
body.light-theme .settings-section,
body.light-theme .auth-card,
body.light-theme [style*="background:#111827"],
body.light-theme [style*="background: #111827"] {
  background: var(--bg-1) !important;
  border-color: var(--border) !important;
  color: var(--text-primary);
}

body.light-theme [style*="background:#1e2433"],
body.light-theme [style*="background: #1e2433"] {
  background: var(--bg-3) !important;
  color: var(--text-primary) !important;
}

body.light-theme .form-input,
body.light-theme input,
body.light-theme textarea,
body.light-theme select {
  background: var(--bg-2) !important;
  border-color: var(--border-bright) !important;
  color: var(--text-primary) !important;
}

body.light-theme .muted-text,
body.light-theme .text-muted,
body.light-theme [style*="color:#64748b"],
body.light-theme [style*="color: #64748b"] {
  color: var(--text-sec) !important;
}

body.light-theme .nav-item,
body.light-theme .icon-btn,
body.light-theme .icon-btn-sm,
body.light-theme .tab-btn {
  color: var(--text-sec);
  border-color: var(--border);
}

body.light-theme .nav-item.active,
body.light-theme .nav-item:hover {
  background: var(--bg-3);
  color: var(--text-primary);
}

body.light-theme ::-webkit-scrollbar-thumb { background: var(--bg-5); }
