/* ---- PROFILE view ---- */
.profile-rank-card{ background:linear-gradient(135deg, var(--purple), var(--purple-dark)); color:#fff; }
.profile-rank-top{ display:flex; align-items:center; gap:12px; }
.profile-rank-icon{
  width:52px; height:52px; border-radius:16px; flex-shrink:0; font-size:26px;
  background:rgba(255,255,255,.2); display:flex; align-items:center; justify-content:center;
}
.profile-rank-name{ font-family:'Baloo 2'; font-weight:700; font-size:18px; }
.profile-league{ font-size:12px; color:rgba(255,255,255,.78); font-weight:700; margin-top:1px; }
.profile-points{ font-size:12px; font-weight:800; background:rgba(255,255,255,.2); padding:4px 10px; border-radius:20px; white-space:nowrap; flex-shrink:0; }
.progress-outer{ width:100%; height:8px; border-radius:20px; background:rgba(255,255,255,.22); overflow:hidden; }
.progress-inner{ height:100%; border-radius:20px; background:var(--sun); transition:width .4s ease; }
.profile-rank-hint{ font-size:11.5px; color:rgba(255,255,255,.85); margin:8px 0 0; }

.profile-icon{width:40px;height:40px;border-radius:12px;background:var(--purple-light);display:flex;align-items:center;justify-content:center;position:relative;flex-shrink:0;color:var(--purple-dark);}
.profile-icon svg,.subscription-icon svg,.icon-button-gear svg{width:20px;height:20px;stroke-width:2.2;}
.profile-icon-info{color:var(--progress-blue);}
.profile-icon-subscription{background:#fff;}
.icon-button-gear{width:38px;height:38px;border:0;border-radius:12px;background:var(--purple-light);color:var(--purple-dark);display:flex;align-items:center;justify-content:center;cursor:pointer;}
.tracker-heart-icon,.tracker-hearts-list svg{width:18px;height:18px;stroke-width:2.5;fill:currentColor;}
.hgear svg,.tl-settings-btn svg,.modal-banner-icon svg{width:17px;height:17px;stroke-width:2.3;vertical-align:middle;}

.day-level-card{ background:linear-gradient(135deg, var(--purple), var(--purple-dark)); color:#fff; }
.day-level-top{ display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; }
.day-level-badge{ font-family:'Baloo 2'; font-weight:700; font-size:16px; display:flex; align-items:center; gap:6px; }
.day-level-badge .emoji{ font-size:19px; }
.day-level-pct{ font-size:13px; font-weight:800; background:rgba(255,255,255,.2); padding:4px 10px; border-radius:20px; white-space:nowrap; flex-shrink:0; }
.day-level-hint{ font-size:11.5px; color:rgba(255,255,255,.85); margin:8px 0 0; line-height:1.4; }
.step-row{ display:flex; align-items:flex-start; gap:12px; background:var(--cream); border-radius:14px; padding:12px 14px; margin-bottom:10px; }
.step-num{
  width:24px; height:24px; border-radius:50%; background:var(--mint-light); color:var(--mint-dark);
  font-family:'Baloo 2'; font-weight:700; font-size:12.5px; flex-shrink:0;
  display:flex; align-items:center; justify-content:center; margin-top:1px;
}
.step-row p{ margin:0; font-size:13.5px; line-height:1.45; }
.policy-text{ font-size:13px; color:var(--ink); line-height:1.6; }
.policy-text h4{ font-family:'Baloo 2'; font-size:14.5px; margin:16px 0 6px; }
.policy-text h4:first-child{ margin-top:0; }

.habit-card{ background:var(--white); border-radius:18px; box-shadow:var(--shadow); padding:14px; margin-bottom:12px; }
.habit-card-head{ display:flex; align-items:center; gap:10px; margin-bottom:10px; }
.habit-emoji-badge{ width:38px; height:38px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:17px; flex-shrink:0; }
.habit-card-title{ flex:1; min-width:0; }
.habit-card-title .hname{ font-weight:700; font-size:14.5px; }
.habit-card-title .hfreq{ font-size:11px; color:var(--muted); font-weight:700; }
.habit-card .hgear{ width:34px; height:34px; border-radius:50%; background:var(--cream); display:flex; align-items:center; justify-content:center; cursor:pointer; font-size:17px; flex-shrink:0; -webkit-tap-highlight-color:transparent; }
.habit-card .hgear:active{ transform:scale(.94); }
.habit-card .hbell{ font-size:11px; font-weight:700; color:var(--muted); }

.habit-streak-badge{ font-size:11px; font-weight:800; padding:4px 9px; border-radius:20px; white-space:nowrap; flex-shrink:0; }
.habit-streak-badge.tier-low{ background:var(--cream); color:var(--muted); }
.habit-streak-badge.tier-mid{ background:rgba(255,130,113,.15); color:var(--coral-dark); }
.habit-streak-badge.tier-high{ background:rgba(255,130,113,.22); color:var(--coral-dark); }
.habit-streak-badge.tier-top{ background:linear-gradient(135deg, #FFD866, #FFA76B); color:#7A4A00; box-shadow:0 2px 8px rgba(255,168,70,.35); }

.habit-week-days{ display:flex; justify-content:space-between; margin-bottom:10px; }
.hday{ display:flex; flex-direction:column; align-items:center; gap:5px; }
.hday .hdow{ font-size:10px; color:var(--muted); font-weight:700; }
.hday .hcircle{
  width:28px; height:28px; border-radius:50%; border:1.5px solid #E7E1F5; background:var(--cream);
  display:flex; align-items:center; justify-content:center; font-size:12px; cursor:pointer; color:transparent;
}
.hday .hcircle.applicable{ cursor:pointer; }
.hday .hcircle.not-applicable{ opacity:.35; cursor:default; }
.hday.is-today .hcircle{ border-width:2px; }

.habit-days-picker{ display:flex; gap:4px; margin-bottom:10px; }
.habit-days-picker .dchip{
  flex:1; text-align:center; padding:5px 0; border-radius:8px; background:var(--cream);
  font-size:10px; font-weight:700; cursor:pointer; color:var(--muted); border:1.3px solid transparent;
}
.habit-days-picker .dchip.active{ color:#fff; }

.habit-heatmap{ display:grid; grid-template-columns:repeat(10, 1fr); gap:3px; margin-bottom:12px; }
.hcell{ aspect-ratio:1; border-radius:4px; background:var(--cream); cursor:pointer; }
.hcell.future{ cursor:default; background:transparent; }

.habit-checkin-btn{
  width:100%; border:none; border-radius:12px; padding:11px; color:#fff;
  font-family:'Baloo 2'; font-weight:700; font-size:13.5px; cursor:pointer;
}
.habit-checkin-btn.done{ opacity:.55; }
