:root {
  --bg: #f1f1f5;
  --ink: #38383a;
  --text: #111114;
  --muted: #8f8f96;
  --line: #dedee1;
  --card: #ffffff;
  --lavender: #a88cff;
  --lavender-soft: #eadfff;
  --green: #cfee96;
  --green-soft: #eaffd5;
  --mint-dark: #23b99e;
  --black: #252528;
  --shadow-soft: 0 8px 22px rgba(31, 31, 34, .08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html {
  touch-action: manipulation;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  touch-action: manipulation;
  overscroll-behavior: none;
}

button,
input,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.app {
  width: min(100vw, 430px);
  min-height: 100vh;
  margin: 0 auto;
  padding: calc(12px + env(safe-area-inset-top)) 14px calc(118px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-x: hidden;
}

.topbar {
  min-height: 54px;
  display: grid;
  grid-template-columns: 52px 1fr 52px;
  align-items: center;
  gap: 10px;
}

.title {
  margin: 0;
  text-align: center;
  font-size: 25px;
  font-weight: 850;
}

.subtle-title {
  color: var(--muted);
  font-size: 18px;
  font-weight: 650;
}

.round {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--shadow-soft);
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 22px;
}

.avatar {
  border: 2px solid #111114;
  background: linear-gradient(135deg, #fff, var(--lavender-soft));
  position: relative;
  overflow: hidden;
}

.avatar::before {
  content: "";
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: currentColor;
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
}

.avatar::after {
  content: "";
  width: 29px;
  height: 18px;
  border-radius: 16px 16px 8px 8px;
  background: currentColor;
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
}

.avatar.has-photo {
  padding: 0;
  background: #fff;
}

.avatar.has-photo::before,
.avatar.has-photo::after {
  display: none;
}

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

.top-streak {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 5px;
  color: #111114;
  font-size: 27px;
  font-weight: 900;
}

.access-gate {
  min-height: calc(100vh - 160px);
  display: grid;
  align-content: center;
  gap: 16px;
  text-align: center;
}

.access-mark {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--green), var(--lavender-soft));
  color: var(--black);
  font-size: 40px;
  font-weight: 950;
  box-shadow: var(--shadow-soft);
}

.access-gate h1 {
  margin: 0;
  font-size: 29px;
  line-height: 1.05;
}

.access-gate p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.35;
}

.access-card {
  text-align: left;
}

.access-message {
  color: var(--ink) !important;
  font-weight: 700;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
}

.section-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  padding: 0 10px;
  font-size: 16px;
}

.section-label b {
  color: #a9a9af;
}

.habit-row {
  width: 100%;
  min-height: 72px;
  display: grid;
  grid-template-columns: 48px 34px 1fr 18px;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  text-align: left;
}

.habit-open {
  display: contents;
  text-align: left;
  color: inherit;
  background: transparent;
}

.check {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--lavender);
  color: white;
  font-size: 26px;
  border: 1px solid var(--lavender);
}

.check.empty {
  background: white;
  color: transparent;
  border-color: #d8d8dd;
}

.danger-action {
  width: 100%;
  min-height: 54px;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .22), rgba(255, 255, 255, 0) 42%),
    linear-gradient(135deg, #ff8b8b, #e44158);
  border: 1px solid rgba(255, 255, 255, .5);
  color: #fff;
  font-size: 15px;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(228, 65, 88, .18);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(18, 18, 22, .28);
  backdrop-filter: blur(10px);
}

.delete-modal {
  width: min(100%, 340px);
  border-radius: 24px;
  background: rgba(255, 255, 255, .96);
  border: 1px solid rgba(255, 255, 255, .7);
  box-shadow: 0 22px 44px rgba(27, 27, 32, .18);
  padding: 20px;
  text-align: center;
}

.delete-modal h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.delete-modal p {
  margin: 0 0 18px;
  color: var(--muted);
  line-height: 1.35;
}

.notice-modal {
  padding: 24px 20px 20px;
}

.notice-modal h2 {
  margin-bottom: 18px;
}

.disclaimer-modal p {
  font-size: 15px;
}

.modal-actions {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 10px;
}

.modal-actions.single {
  grid-template-columns: 1fr;
}

.modal-cancel,
.modal-delete {
  min-height: 46px;
  border-radius: 16px;
  font-weight: 900;
}

.modal-cancel {
  background: #f3f3f7;
  color: var(--ink);
}

.modal-delete {
  background: linear-gradient(135deg, #ff8b8b, #e44158);
  color: #fff;
  box-shadow: 0 10px 20px rgba(228, 65, 88, .18);
}

.habit-icon {
  color: var(--lavender);
  font-size: 24px;
  text-align: center;
}

.habit-row h3,
.pick h3,
.leader h3 {
  margin: 0;
  color: #0d0d10;
  font-size: 17px;
  line-height: 1.1;
}

.habit-row p,
.pick p,
.leader p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.2;
}

.empty-state {
  padding: 22px;
  text-align: center;
  color: var(--muted);
}

.tabs {
  position: fixed;
  left: 50%;
  bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 20;
  transform: translateX(-50%);
  margin: 0;
  width: min(calc(100vw - 28px), 402px);
  min-height: 70px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: center;
  padding: 6px;
  background: rgba(255, 255, 255, .86);
  border: 1px solid rgba(255, 255, 255, .6);
  border-radius: 999px;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
}

.bottom-actions {
  position: fixed;
  left: 50%;
  bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 20;
  transform: translateX(-50%);
  margin-top: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 64px;
  gap: 16px;
  align-items: center;
  width: min(calc(100vw - 28px), 402px);
}

.bottom-actions .tabs {
  position: static;
  transform: none;
  width: 100%;
  margin: 0;
}

.tab {
  min-width: 0;
  height: 58px;
  display: grid;
  place-items: center;
  gap: 3px;
  border-radius: 999px;
  background: transparent;
  color: #151519;
  font-size: 10px;
  font-weight: 700;
}

.tab.active {
  background: #fff;
}

.menu-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  filter: brightness(0);
}

.fab {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--lavender);
  box-shadow: 0 12px 26px rgba(168, 140, 255, .34);
}

.fab::before,
.fab::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 3px;
  border-radius: 999px;
  background: white;
  transform: translate(-50%, -50%);
}

.fab::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.sheet-title {
  margin: 8px 4px 2px;
  color: var(--ink);
  font-size: 25px;
  line-height: 1.05;
  font-weight: 650;
  text-align: center;
  text-transform: uppercase;
}

.pick-list,
.leaderboard,
.form-stack {
  display: grid;
  gap: 10px;
  width: 100%;
  min-width: 0;
}

.pick {
  width: 100%;
  min-height: 72px;
  display: grid;
  grid-template-columns: 48px 1fr 18px;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  text-align: left;
}

.recommended-pick {
  background: linear-gradient(135deg, #ffffff, rgba(234, 223, 255, .82));
  border-color: rgba(168, 140, 255, .28);
}

.recommend-badge {
  display: inline-flex;
  max-width: 100%;
  margin-bottom: 4px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(168, 140, 255, .16);
  color: var(--lavender);
  font-size: 10px;
  font-weight: 900;
  line-height: 1.1;
}

.mini-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--green-soft);
  font-size: 23px;
}

.mini-icon.purple {
  background: var(--lavender-soft);
}

.mini-icon.danger {
  color: #e83232;
  font-size: 28px;
  font-weight: 950;
}

.form-card {
  display: block;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  padding: 16px;
}

.note-card {
  padding: 16px;
}

.note-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.note-head h2 {
  margin: 0;
  font-size: 22px;
}

.note-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.progress-note {
  padding: 16px;
}

.progress-note p {
  margin: 0;
  padding: 14px;
  border-radius: 18px;
  background: #fafafd;
  border: 1px solid var(--line);
  color: var(--text);
  line-height: 1.45;
  white-space: pre-wrap;
}

.note-action {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  background: #fff;
  color: var(--lavender);
  border: 1px solid rgba(168, 140, 255, .36);
  font-size: 20px;
}

.note-action.save {
  background: var(--lavender);
  color: #fff;
  border-color: transparent;
}

.saved-note {
  background: linear-gradient(135deg, #fff, rgba(245, 241, 255, .9));
}

.saved-note p {
  margin: 0;
  padding: 14px;
  min-height: 72px;
  border-radius: 18px;
  background: #fafafd;
  border: 1px solid var(--line);
  color: var(--text);
  line-height: 1.45;
  white-space: pre-wrap;
}

.form-label {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.input,
.textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fafafd;
  color: var(--text);
  padding: 14px;
  outline: none;
}

.textarea {
  min-height: 112px;
  resize: vertical;
}

.icon-choice {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  display: flex;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.icon-choice::-webkit-scrollbar {
  display: none;
}

.emoji-choice,
.frequency-pill {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f7f7f8;
  border: 1px solid var(--line);
  font-size: 23px;
}

.emoji-choice.active,
.frequency-pill.active {
  border-color: var(--lavender);
  background: var(--lavender);
  color: white;
}

.frequency-pill {
  width: auto;
  min-width: 52px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 850;
}

.primary {
  min-height: 56px;
  width: 100%;
  border-radius: 18px;
  background: var(--lavender);
  color: white;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(168, 140, 255, .26);
}

.primary.compact {
  min-height: 44px;
  width: auto;
  padding: 0 18px;
  box-shadow: none;
}

.habit-hero {
  margin: -12px -14px 0;
  min-height: 190px;
  background: linear-gradient(180deg, #eaffd5 0%, #edf8e7 62%, var(--bg) 100%);
  position: relative;
  padding: 54px 24px 24px;
  text-align: center;
  display: grid;
  align-content: end;
}

.back {
  position: absolute;
  top: 56px;
  left: 20px;
}

.hero-edit {
  position: absolute;
  top: 56px;
  right: 20px;
}

.hero-edit.disabled,
.hero-edit:disabled {
  color: #a9a9b2;
  background: rgba(255, 255, 255, .68);
  box-shadow: none;
  cursor: default;
}

.badge {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .96);
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  box-shadow: 0 14px 30px rgba(31, 31, 34, .16);
  font-size: 32px;
}

.habit-hero h2 {
  margin: 0;
  font-size: 30px;
  color: var(--ink);
}

.goal-card {
  padding: 20px;
  text-align: center;
}

.goal-card h2 {
  margin: 0 0 18px;
  font-size: 28px;
}

.dots {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 18px;
}

.dot {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #e8e8ea;
  display: grid;
  place-items: center;
  color: white;
  font-size: 24px;
}

.dot.done {
  background: var(--lavender);
}

.muted-note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.score-grid,
.profile-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.score {
  min-height: 86px;
  padding: 13px;
  border-radius: 18px;
  border: 1px solid #cfcfd4;
  background: var(--card);
  display: grid;
  place-items: center;
  text-align: center;
  align-content: center;
}

.score b {
  font-size: 26px;
}

.score span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.wide {
  grid-column: 1 / -1;
}

.level {
  padding: 18px;
  text-align: center;
}

.level h2 {
  margin: 0 0 16px;
  text-align: left;
  font-size: 25px;
}

.level-person {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  margin: 0 auto 8px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #f1eaff, #ffffff);
  border: 1px solid rgba(168, 140, 255, .28);
  font-size: 42px;
}

.level-stars {
  color: #d3ba86;
  display: flex;
  justify-content: center;
  gap: 3px;
  font-size: 25px;
  line-height: 1;
  margin: 6px 0 2px;
}

.level-stars .empty {
  color: #dedee3;
}

.meter {
  height: 10px;
  border-radius: 999px;
  background: #e6e6e8;
  margin: 16px 0 8px;
  position: relative;
}

.meter::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--progress, 0%);
  border-radius: inherit;
  background: var(--lavender);
}

.meter-labels {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 14px;
}

.month-completions {
  padding: 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  background: linear-gradient(135deg, rgba(234, 255, 213, .95), rgba(220, 248, 213, .72) 62%, rgba(255, 255, 255, .9));
  border-color: rgba(44, 191, 154, .18);
}

.month-completions h2 {
  margin: 0;
  font-size: 18px;
}

.completion-count {
  color: var(--ink);
  font-size: 34px;
  font-weight: 950;
}

.calendar-card,
.habit-month-calendar {
  padding: 16px 14px 14px;
  min-width: 0;
  overflow: hidden;
}

.cal-head,
.habit-month-head {
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  text-align: center;
  margin-bottom: 14px;
  font-weight: 850;
  font-size: 22px;
  column-gap: 6px;
}

.cal-nav {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  justify-self: center;
  align-self: center;
  padding: 0 0 2px;
  background: rgba(168, 140, 255, .2);
  color: var(--lavender);
  font-size: 26px;
  font-weight: 750;
  line-height: 1;
}

.calendar,
.mini-calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 7px 4px;
  text-align: center;
  color: #111114;
  font-size: 12px;
  width: 100%;
  min-width: 0;
}

.dow {
  color: #aaaab1;
  font-size: 11px;
}

.day,
.mini-day {
  min-height: 45px;
  min-width: 0;
  padding: 0;
  display: grid;
  place-items: center;
  gap: 2px;
}

.bubble {
  width: clamp(30px, 8.6vw, 38px);
  height: clamp(30px, 8.6vw, 38px);
  border-radius: 50%;
  background: #f0f0f4;
  color: #dddddf;
  display: grid;
  place-items: center;
  font-size: 22px;
  border: 1px solid transparent;
}

.day.done .bubble,
.mini-day.done .bubble {
  background: var(--lavender);
  color: white;
}

.day.selected .bubble {
  border-color: #111114;
  box-shadow: 0 0 0 3px rgba(168, 140, 255, .18);
}

.day.missed .bubble,
.mini-day.missed .bubble {
  background: white;
  border-color: #d8d8dd;
}

.day.locked,
.mini-day.locked {
  color: #c9c9cf;
}

.day.locked .bubble,
.mini-day.locked .bubble {
  background: #eeeef2;
  color: #d8d8de;
}

.day.user-locked:not(.done) .bubble,
.mini-day.user-locked:not(.done) .bubble {
  opacity: .82;
}

.dev-toggle {
  width: 100%;
  min-height: 42px;
  border-radius: 14px;
  background: #fff;
  border: 1px dashed rgba(168, 140, 255, .55);
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  box-shadow: 0 8px 18px rgba(27, 27, 32, .06);
}

.dev-toggle.active {
  background: linear-gradient(135deg, rgba(234, 255, 213, .96), rgba(255, 255, 255, .96));
  border-style: solid;
  border-color: rgba(44, 191, 154, .34);
}

.habit-select {
  min-height: 62px;
  display: grid;
  grid-template-columns: 30px 1fr 22px;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 14px;
}

.habit-select p {
  margin: 0 0 2px;
  color: var(--muted);
  font-size: 10px;
}

.habit-select h3 {
  margin: 0;
  font-size: 15px;
}

.habit-menu {
  display: grid;
  gap: 2px;
  padding: 8px;
  border-radius: 16px;
}

.habit-option {
  min-height: 48px;
  display: grid;
  grid-template-columns: 30px 1fr 24px;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  color: var(--ink);
  text-align: left;
  font-weight: 850;
}

.habit-option.active {
  background: rgba(168, 140, 255, .13);
  color: var(--lavender);
}

.habit-option > span:last-child {
  text-align: center;
  color: var(--lavender);
}

.chart-title {
  display: grid;
  grid-template-columns: 32px 1fr 32px;
  align-items: center;
  gap: 8px;
}

.chart-title b {
  text-align: center;
}

.chart-nav {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 0 2px;
  background: rgba(168, 140, 255, .16);
  color: var(--lavender);
  font-size: 25px;
  font-weight: 850;
  line-height: 0;
}

.chart {
  height: 205px;
  padding: 18px 18px 28px;
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 10px;
  align-items: stretch;
  border-top: 1px solid var(--line);
  margin-top: 10px;
}

.chart-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-bottom: 18px;
  color: var(--muted);
  font-size: 10px;
  text-align: right;
}

.chart-bars {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
  align-items: end;
  min-width: 0;
}

.bar {
  min-height: 18px;
  border-radius: 8px 8px 4px 4px;
  background: var(--lavender);
  position: relative;
}

.bar::before {
  content: attr(data-value);
  position: absolute;
  left: 50%;
  top: -18px;
  transform: translateX(-50%);
  color: var(--ink);
  font-size: 10px;
  font-weight: 850;
}

.bar::after {
  content: attr(data-label);
  position: absolute;
  left: 50%;
  bottom: -24px;
  transform: translateX(-50%);
  color: var(--muted);
  font-size: 10px;
}

.leaderboard {
  display: grid;
  gap: 9px;
}

.ranking-review {
  padding: 16px;
  display: grid;
  gap: 12px;
}

.ranking-review h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.18;
}

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

.review-footer span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.leader {
  min-height: 56px;
  display: grid;
  grid-template-columns: 36px 44px 1fr 42px;
  gap: 9px;
  align-items: center;
  padding: 8px 12px;
}

.place {
  color: var(--muted);
  font-weight: 900;
  text-align: center;
}

.medal-place {
  font-size: 24px;
  line-height: 1;
}

.points {
  color: var(--ink);
  font-weight: 900;
  justify-self: end;
}

.rank-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--lavender-soft);
  color: var(--lavender);
  font-size: 15px;
  font-weight: 950;
}

.rank-avatar.green {
  background: var(--green-soft);
  color: var(--mint-dark);
}

.rank-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  padding: 2px 10px;
}

.rank-divider::before,
.rank-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--line);
}

.leader.you {
  border-color: rgba(168, 140, 255, .34);
  background: linear-gradient(135deg, #ffffff, rgba(244, 237, 255, .72));
}

.timer {
  padding: 16px 18px;
  background:
    linear-gradient(135deg, rgba(234, 255, 213, .38) 0%, rgba(234, 255, 213, .12) 34%, rgba(31, 31, 34, 0) 58%),
    linear-gradient(135deg, #151517 0%, #252528 100%);
  color: white;
  border-radius: 22px;
  display: grid;
  grid-template-columns: 44px 1fr;
  align-items: center;
  gap: 12px;
}

.timer span {
  color: rgba(255, 255, 255, .66);
  font-size: 13px;
}

.timer b {
  font-size: 30px;
}

.timer-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(234, 255, 213, .92);
  color: #151517;
  font-size: 23px;
}

.profile-card {
  padding: 18px;
  text-align: center;
}

.profile-avatar {
  width: 88px;
  height: 88px;
  margin: 0 auto 8px;
  color: #151517;
  font-size: 42px;
  box-shadow: none;
}

.profile-username {
  max-width: 100%;
  margin: 10px auto 18px;
  color: var(--muted);
  overflow-wrap: anywhere;
  line-height: 1.25;
}

.profile-card .profile-stats {
  margin-top: 0;
}

.support-link {
  color: inherit;
}

@media (max-width: 360px) {
  .app { padding-inline: 10px; }
  .tabs,
  .bottom-actions { width: calc(100vw - 20px); }
  .bottom-actions .tabs { width: 100%; }
  .habit-row { grid-template-columns: 44px 30px 1fr 16px; }
  .emoji-choice {
    width: 44px;
    height: 44px;
  }
  .frequency-pill {
    min-width: 46px;
    height: 44px;
    padding: 0 12px;
  }
}
