/* StreakForce — mobile-first dark check-in UI */

:root {
  --bg: #0d0d12;
  --surface: #16161f;
  --surface2: #1e1e2a;
  --border: #2a2a38;
  --flame: #ff5c2b;
  --flame-glow: rgba(255,92,43,0.25);
  --accent: #5b8df8;
  --accent-dim: rgba(91,141,248,0.15);
  --text: #eeeef2;
  --text-dim: #8888a2;
  --success: #3dd68c;
  --success-dim: rgba(61,214,140,0.15);
  --warn: #ffb547;
  --radius: 16px;
}

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

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding: 0 16px 80px;
  max-width: 520px;
  margin: 0 auto;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0 20px;
}

.brand {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
}

.streak-hero {
  text-align: center;
  padding: 32px 0 24px;
}

.flame-wrap {
  position: relative;
  display: inline-block;
}

.flame-wrap::before {
  content: '';
  position: absolute;
  inset: -20px;
  border-radius: 50%;
  background: var(--flame-glow);
  filter: blur(20px);
  animation: sf-pulse 2s ease-in-out infinite;
}

@keyframes sf-pulse {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.08); }
}

.streak-num {
  font-size: 80px;
  font-weight: 900;
  color: var(--flame);
  line-height: 1;
  position: relative;
  text-shadow: 0 0 40px rgba(255,92,43,0.5);
}

.streak-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-top: 6px;
}

.streak-meta {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-dim);
}

.streak-meta span { display: flex; align-items: center; gap: 5px; }

.progress-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--surface2);
  border: 1px solid var(--border);
  transition: all 0.3s;
}

.dot.done { background: var(--success); border-color: var(--success); }

.momentum-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 24px;
}

.momentum-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.momentum-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
}

.momentum-pct {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}

.momentum-track {
  height: 6px;
  background: var(--surface2);
  border-radius: 99px;
  overflow: hidden;
}

.momentum-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #8b5cf6);
  border-radius: 99px;
  transition: width 0.6s ease;
}

.section { margin-bottom: 20px; }

.section-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.energy-grid {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 6px;
}

.energy-btn {
  height: 44px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
}

.energy-btn:hover { border-color: var(--accent); color: var(--text); }
.energy-btn.selected {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

.task-list { display: flex; flex-direction: column; gap: 10px; }

.task-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  cursor: pointer;
  transition: all 0.15s;
}

.task-item.completed { opacity: 0.55; }

.task-check {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s;
}

.task-item.completed .task-check {
  background: var(--success-dim);
  border-color: var(--success);
}

.task-item.completed .task-check::after {
  content: '✓';
  font-size: 13px;
  color: var(--success);
  font-weight: 700;
}

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

.task-text {
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  word-break: break-word;
}

.task-item.completed .task-text { text-decoration: line-through; color: var(--text-dim); }

.task-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 7px;
  border-radius: 6px;
  background: rgba(255,180,71,0.15);
  color: var(--warn);
  margin-top: 4px;
  display: inline-block;
}

.add-task-form {
  display: none;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.add-task-form.open { display: flex; }

.add-task-input {
  flex: 1;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s;
}

.add-task-input::placeholder { color: var(--text-dim); }
.add-task-input:focus { border-color: var(--accent); }

.add-btn-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.add-btn {
  padding: 12px 20px;
  background: var(--accent-dim);
  border: 1.5px solid var(--accent);
  border-radius: 14px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.add-btn:hover { background: rgba(91,141,248,0.25); }

.biz-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 4px;
}

.biz-label { font-size: 13px; color: var(--text-dim); }

.toggle-biz {
  width: 40px;
  height: 22px;
  border-radius: 11px;
  background: var(--surface2);
  border: none;
  position: relative;
  cursor: pointer;
  transition: background 0.2s;
}

.toggle-biz.on { background: var(--accent); }

.toggle-biz::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: white;
  top: 3px;
  left: 3px;
  transition: transform 0.2s;
}

.toggle-biz.on::after { transform: translateX(18px); }

.add-task-btn {
  width: 100%;
  padding: 14px;
  background: transparent;
  border: 1.5px dashed var(--border);
  border-radius: 14px;
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
}

.add-task-btn:hover { border-color: var(--accent); color: var(--text); }
.add-task-btn.hidden { display: none; }

.finish-btn {
  width: 100%;
  padding: 16px;
  background: var(--flame);
  border: none;
  border-radius: var(--radius);
  color: white;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 24px;
  letter-spacing: 0.5px;
}

.finish-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(255,92,43,0.35);
}

.finish-btn:disabled {
  background: var(--surface2);
  color: var(--text-dim);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.complete-banner {
  display: none;
  text-align: center;
  padding: 40px 20px;
}

.complete-banner.show { display: block; }

.complete-banner .big-flame {
  font-size: 64px;
  margin-bottom: 16px;
  animation: sf-pulse 2s ease-in-out infinite;
}

.complete-banner h2 {
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 8px;
}

.complete-banner p {
  color: var(--text-dim);
  font-size: 15px;
  line-height: 1.5;
}

.reset-notice {
  background: rgba(255,200,50,0.08);
  border: 1px solid rgba(255,200,50,0.2);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-size: 13px;
  color: var(--warn);
  text-align: center;
  margin-bottom: 20px;
  display: none;
}

.reset-notice.show { display: block; }

/* Partner button */
.partner-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 7px 14px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  color: var(--text-dim);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
}

.partner-btn:hover { border-color: var(--accent); color: var(--accent); }

/* Partner badge */
.partner-badge {
  display: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 20px;
  flex-direction: column;
  gap: 4px;
}

.partner-badge.show { display: flex; }

.partner-badge-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--success);
}

.partner-badge-streak {
  display: flex;
  align-items: center;
  gap: 8px;
}

.partner-flame { font-size: 22px; }

#partnerStreakCount {
  font-size: 28px;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
}

.partner-streak-label {
  font-size: 13px;
  color: var(--text-dim);
}

/* Modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  z-index: 999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.show { display: flex; }

.modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  width: 100%;
  max-width: 420px;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.modal-header h2 {
  font-size: 18px;
  font-weight: 700;
}

.modal-close {
  background: var(--surface2);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  color: var(--text-dim);
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover { color: var(--text); }

.modal-desc {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.5;
  margin-bottom: 20px;
}

.code-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 8px;
}

.code-display {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: 6px;
  color: var(--accent);
  text-align: center;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 12px;
}

.modal-copy-btn {
  width: 100%;
  padding: 12px;
  background: var(--accent-dim);
  border: 1.5px solid var(--accent);
  border-radius: 14px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
}

.modal-copy-btn:hover { background: rgba(91,141,248,0.25); }

.code-hint {
  font-size: 13px;
  color: var(--text-dim);
  text-align: center;
  margin-top: 10px;
}

.code-hint strong {
  letter-spacing: 2px;
  color: var(--text);
}

.modal-divider {
  text-align: center;
  font-size: 12px;
  color: var(--text-dim);
  margin: 20px 0;
  position: relative;
}

.modal-divider::before,
.modal-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 30%;
  height: 1px;
  background: var(--border);
}

.modal-divider::before { left: 0; }
.modal-divider::after { right: 0; }

.modal-input-row {
  display: flex;
  gap: 10px;
}

.modal-code-input {
  flex: 1;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  letter-spacing: 2px;
  text-transform: uppercase;
  outline: none;
  transition: border-color 0.15s;
}

.modal-code-input::placeholder { letter-spacing: 0; text-transform: none; color: var(--text-dim); }
.modal-code-input:focus { border-color: var(--accent); }

.modal-submit-btn {
  padding: 12px 20px;
  background: var(--success-dim);
  border: 1.5px solid var(--success);
  border-radius: 14px;
  color: var(--success);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.modal-submit-btn:hover { background: rgba(61,214,140,0.25); }

.modal-error {
  font-size: 13px;
  color: #ff5c5c;
  margin-top: 8px;
  min-height: 18px;
}

.linked-info {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--success-dim);
  border: 1px solid rgba(61,214,140,0.3);
  border-radius: 14px;
  padding: 14px 16px;
  margin-top: 16px;
}

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

.linked-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--success);
}

.linked-streak {
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 2px;
}
/* Leaderboard button */
.leaderboard-btn {
  width: 36px;
  height: 36px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  color: var(--text);
  font-size: 16px;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.leaderboard-btn:hover { border-color: var(--flame); transform: scale(1.05); }

/* Leaderboard modal */
.leaderboard-box { max-height: 85vh; overflow: hidden; display: flex; flex-direction: column; }

.leaderboard-subtitle {
  font-size: 13px;
  color: var(--text-dim);
  margin-bottom: 16px;
  margin-top: -4px;
}

#leaderboardList {
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-right: 4px;
}

.lb-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface2);
  border-radius: 12px;
  border: 1px solid transparent;
  transition: border-color 0.15s;
}

.lb-row.is-you {
  border-color: var(--flame);
  background: rgba(255,92,43,0.06);
}

.lb-rank {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-dim);
  min-width: 28px;
  text-align: center;
}

.lb-rank.top1 { color: #ffd700; }
.lb-rank.top2 { color: #c0c0c0; }
.lb-rank.top3 { color: #cd7f32; }
.lb-rank.is-you { color: var(--flame); }

.lb-flame { font-size: 20px; flex-shrink: 0; }

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

.lb-streak {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.lb-meta {
  font-size: 12px;
  color: var(--text-dim);
  margin-top: 2px;
}

.lb-you-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  background: var(--flame-glow);
  color: var(--flame);
  border: 1px solid rgba(255,92,43,0.3);
  border-radius: 8px;
  padding: 3px 8px;
  flex-shrink: 0;
}

.lb-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-dim);
  font-size: 14px;
}

.lb-loading {
  text-align: center;
  padding: 30px;
  color: var(--text-dim);
  font-size: 14px;
}

/* ── Onboarding Modal ─────────────────────────────────────────────────────── */

.ob-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.82);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.ob-modal.show { display: flex; }

.ob-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  width: 100%;
  max-width: 460px;
  padding: 36px 32px;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6);
  position: relative;
}

/* Step indicator */
.ob-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 32px;
}

.ob-step-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--surface2);
  border: 2px solid var(--border);
  transition: all 0.25s;
}

.ob-step-dot.active {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 8px rgba(91,141,248,0.5);
  width: 12px;
  height: 12px;
}

.ob-step-dot.done {
  background: var(--success);
  border-color: var(--success);
}

.ob-step-line {
  width: 48px;
  height: 2px;
  background: var(--border);
  transition: background 0.25s;
}

.ob-step-line.done { background: var(--success); }

/* Panels */
.ob-panel { display: flex; flex-direction: column; gap: 0; }
.ob-hide { display: none; }

.ob-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.ob-heading {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 10px;
}

.ob-sub {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.55;
  margin-bottom: 24px;
}

/* Step 1 — goal textarea */
.ob-textarea {
  width: 100%;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  resize: none;
  outline: none;
  transition: border-color 0.15s;
  line-height: 1.5;
}

.ob-textarea::placeholder { color: var(--text-dim); }
.ob-textarea:focus { border-color: var(--accent); }

.ob-char-count {
  font-size: 12px;
  color: var(--text-dim);
  text-align: right;
  margin-top: 6px;
  margin-bottom: 20px;
}

.ob-btn-primary {
  width: 100%;
  padding: 15px 24px;
  background: var(--accent);
  border: none;
  border-radius: 14px;
  color: white;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.3px;
}

.ob-btn-primary:hover:not(:disabled) {
  background: #4a7df0;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(91,141,248,0.35);
}

.ob-btn-primary:disabled {
  background: var(--surface2);
  color: var(--text-dim);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.ob-btn-ghost {
  padding: 12px 20px;
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
}

.ob-btn-ghost:hover { border-color: var(--text-dim); color: var(--text); }

/* Step 2 — time picker */
.ob-time-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.ob-time-btn {
  padding: 12px 8px;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  color: var(--text-dim);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
}

.ob-time-btn:hover { border-color: var(--accent); color: var(--text); }

.ob-time-btn.selected {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

.ob-custom-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.ob-custom-label {
  font-size: 13px;
  color: var(--text-dim);
  white-space: nowrap;
}

.ob-time-input {
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s;
}

.ob-time-input:focus { border-color: var(--accent); }

.ob-nav-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.ob-nav-row .ob-btn-ghost { flex-shrink: 0; }
.ob-nav-row .ob-btn-primary { flex: 1; }

/* Step 3 — explainer */
.ob-explain-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.ob-explain-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
}

.ob-explain-icon { font-size: 22px; flex-shrink: 0; }

.ob-explain-item strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.ob-explain-item p {
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.5;
  margin: 0;
}

/* ── Stats view (post-onboarding) ─────────────────────────────────── */
.stats-view {
  display: none;
  flex-direction: column;
  gap: 32px;
  padding: 48px 0 24px;
  animation: fadeUp 0.5s ease both;
}

.stats-view.show { display: flex; }

.stats-header { text-align: center; }

.stats-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--flame);
  margin-bottom: 10px;
}

.stats-title {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.2;
  color: var(--text);
  margin-bottom: 10px;
}

.stats-sub {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.5;
}

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

.stats-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.stats-card-icon { font-size: 22px; }

.stats-card-value {
  font-size: 28px;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
}

.stats-card:first-child .stats-card-value { color: var(--flame); }

.stats-card-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-dim);
}

.stats-cta {
  background: var(--flame);
  color: #fff;
  border: none;
  border-radius: 14px;
  padding: 16px 24px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  text-align: center;
  letter-spacing: 0.3px;
  transition: opacity 0.15s;
}

.stats-cta:hover { opacity: 0.88; }

/* ── Streak-at-risk banner ──────────────────────────────────────────── */
.at-risk-banner {
  background: rgba(255,92,43,0.08);
  border: 1.5px solid rgba(255,92,43,0.35);
  border-radius: var(--radius);
  padding: 14px 16px 14px 14px;
  margin-bottom: 16px;
  display: none;
  align-items: center;
  gap: 12px;
  animation: fadeUp 0.4s ease both;
}

.at-risk-banner.show { display: flex; }

.at-risk-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.at-risk-text { flex: 1; min-width: 0; }

.at-risk-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.at-risk-sub {
  font-size: 12px;
  color: var(--text-dim);
  margin-top: 2px;
}

.at-risk-cta {
  padding: 9px 16px;
  background: var(--flame);
  border: none;
  border-radius: 10px;
  color: white;
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity 0.15s;
}

.at-risk-cta:hover { opacity: 0.85; }

.at-risk-dismiss {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
  line-height: 1;
  transition: color 0.15s;
}

.at-risk-dismiss:hover { color: var(--text); }

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