/* ───────────────────────────────────────────────────────────────────────────
   Fitness Vow — dashboard pages (wallet, plan, history, progress)
   Depends on base.css for shared tokens, nav, footer, cards, buttons.
   ─────────────────────────────────────────────────────────────────────────── */

/* ── Page shell ─────────────────────────────────────────────────────────── */
.page {
  flex: 1;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 56px) clamp(20px, 4vw, 32px) clamp(48px, 7vw, 96px);
}

.page-loader {
  flex: 1;
  display: flex; align-items: center; justify-content: center;
  padding: 80px 24px;
}

/* ── Breadcrumb back link ───────────────────────────────────────────────── */
.crumb {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 16px;
  text-decoration: none;
  transition: color 0.15s;
}
.crumb:hover { color: var(--primary); }
.crumb::before { content: '‹'; font-size: 18px; line-height: 1; }

/* ── Hero (smaller than landing hero) ───────────────────────────────────── */
.dash-hero { margin-bottom: clamp(24px, 4vw, 36px); }
.dash-hero .eyebrow {
  display: inline-block;
  font-size: 11px; font-weight: 800; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--primary);
  margin-bottom: 10px;
}
.dash-hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(28px, 4.4vw, 40px);
  font-weight: 900; letter-spacing: -1px; line-height: 1.08;
  margin: 0 0 8px;
}
.dash-hero p {
  color: var(--text-muted); font-size: clamp(14px, 1.5vw, 16px);
  margin: 0; max-width: 620px; line-height: 1.6;
}

/* ── Section header ─────────────────────────────────────────────────────── */
.section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px; font-weight: 800;
  letter-spacing: 1.6px; text-transform: uppercase;
  color: var(--text-dim);
  margin: 36px 0 14px;
}

/* ── Stat cards grid ────────────────────────────────────────────────────── */
.stat-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  margin-bottom: 12px;
}
.stat-card {
  background: linear-gradient(180deg, var(--surface-glass), rgba(15,26,46,0.45));
  border: 1px solid var(--outline-soft);
  border-radius: 18px;
  padding: 20px 22px;
}
.stat-card .label {
  font-size: 11px; font-weight: 800; letter-spacing: 1.2px;
  text-transform: uppercase; color: var(--text-dim);
  margin-bottom: 8px;
}
.stat-card .value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(24px, 3.2vw, 32px);
  font-weight: 900; letter-spacing: -0.6px;
  color: var(--text);
  line-height: 1.1;
}
.stat-card .sub {
  margin-top: 6px;
  font-size: 12px;
  color: var(--text-dim);
}
.stat-card.accent .value { color: var(--primary); }
.stat-card.success .value { color: var(--success); }
.stat-card.danger  .value { color: var(--danger); }

/* ── Data list / row ────────────────────────────────────────────────────── */
.data-list { display: flex; flex-direction: column; gap: 0; }
.data-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(56,189,248,0.08);
}
.data-row:last-child { border-bottom: 0; }
.data-row .left { min-width: 0; }
.data-row .right { text-align: right; flex-shrink: 0; }
.data-row .primary {
  font-size: 14px; font-weight: 700; color: var(--text);
  margin-bottom: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.data-row .secondary {
  font-size: 12px; color: var(--text-dim);
}
.data-row .amount {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 800; font-size: 15px;
  color: var(--text);
}
.data-row .amount.credit { color: var(--success); }
.data-row .amount.debit  { color: var(--danger); }

/* ── Status tag ─────────────────────────────────────────────────────────── */
.tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 11px; font-weight: 800; letter-spacing: 0.8px;
  text-transform: uppercase;
}
.tag.pass    { background: rgba(52,211,153,0.10); color: var(--success); border: 1px solid rgba(52,211,153,0.32); }
.tag.fail    { background: rgba(248,113,113,0.08); color: var(--danger);  border: 1px solid rgba(248,113,113,0.32); }
.tag.pending { background: rgba(245,158,11,0.08);  color: var(--warning); border: 1px solid rgba(245,158,11,0.32); }
.tag.neutral { background: rgba(56,189,248,0.08);  color: var(--primary); border: 1px solid var(--outline-soft); }

/* ── Empty state ────────────────────────────────────────────────────────── */
.empty {
  text-align: center;
  padding: 36px 24px;
  border: 1px dashed var(--outline-soft);
  border-radius: 18px;
  color: var(--text-muted);
}
.empty .ico {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px;
  background: rgba(56,189,248,0.08);
  border-radius: 14px;
  font-size: 22px;
  color: var(--primary);
  margin-bottom: 12px;
}
.empty h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px; font-weight: 800;
  margin: 0 0 6px;
  color: var(--text);
}
.empty p { margin: 0; font-size: 14px; line-height: 1.6; max-width: 380px; margin: 0 auto; }

/* ── Schedule grid (plan page) ──────────────────────────────────────────── */
.schedule-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  margin-top: 6px;
}
.schedule-day {
  text-align: center;
  padding: 10px 4px;
  border-radius: 12px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(56,189,248,0.06);
  font-size: 11px; font-weight: 700;
  color: var(--text-dim);
}
.schedule-day.active {
  background: rgba(56,189,248,0.08);
  border-color: var(--outline-strong);
  color: var(--primary);
}
.schedule-day .name { font-size: 11px; font-weight: 800; letter-spacing: 0.6px; text-transform: uppercase; }
.schedule-day .time { font-size: 11px; color: var(--text); margin-top: 4px; }
.schedule-day:not(.active) .time { display: none; }
@media (max-width: 560px) {
  .schedule-grid { grid-template-columns: repeat(7, 1fr); gap: 4px; }
  .schedule-day { padding: 8px 2px; }
  .schedule-day .time { font-size: 10px; }
}

/* ── Read-only banner (every dashboard page shows this once) ────────────── */
.readonly-banner {
  display: flex; gap: 12px; align-items: flex-start;
  background: rgba(56,189,248,0.06);
  border: 1px solid var(--outline-soft);
  border-radius: 14px;
  padding: 14px 18px;
  margin-bottom: 28px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}
.readonly-banner .ico {
  flex-shrink: 0;
  color: var(--primary);
  font-size: 18px; line-height: 1;
}
.readonly-banner strong { color: var(--text); font-weight: 800; }

/* ── Two-column wrapper used by plan page ───────────────────────────────── */
.two-col {
  display: grid; gap: 20px;
  grid-template-columns: 1.2fr 1fr;
}
@media (max-width: 760px) {
  .two-col { grid-template-columns: 1fr; }
}

/* ── Badge grid (progress page) ─────────────────────────────────────────── */
.badge-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 14px;
  margin-top: 6px;
}
.badge {
  text-align: center;
  padding: 18px 12px;
  background: linear-gradient(180deg, var(--surface-glass), rgba(15,26,46,0.45));
  border: 1px solid var(--outline-soft);
  border-radius: 16px;
}
.badge .glyph {
  width: 44px; height: 44px;
  background: linear-gradient(135deg, var(--primary), var(--primary-deep));
  border-radius: 14px;
  margin: 0 auto 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--on-primary);
  font-size: 20px;
}
.badge .name { font-size: 12px; font-weight: 800; color: var(--text); line-height: 1.3; }
.badge .date { font-size: 11px; color: var(--text-dim); margin-top: 4px; }

/* ── Tier badge (plan page) ─────────────────────────────────────────────── */
.tier-pill {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 100px;
  background: linear-gradient(135deg, rgba(56,189,248,0.18), rgba(2,132,199,0.12));
  border: 1px solid var(--outline-strong);
  color: var(--primary);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 11px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase;
}
