@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@500;600;700&family=Fira+Sans:wght@400;500;600;700;800;900&display=swap");

:root {
  color-scheme: dark;
  --bg: #050910;
  --bg-deep: #02050a;
  --surface: rgba(8, 18, 30, 0.78);
  --surface-strong: rgba(10, 24, 38, 0.92);
  --surface-soft: rgba(17, 33, 49, 0.62);
  --line: rgba(144, 173, 203, 0.22);
  --line-strong: rgba(177, 215, 245, 0.42);
  --text: #f4f8fb;
  --text-soft: #d5e1eb;
  --muted: #91a7b8;
  --muted-strong: #b7c6d3;
  --lime: #a8ff1a;
  --orange: #f59e0b;
  --blue: #3b82f6;
  --cyan: #2dd4bf;
  --purple: #a855f7;
  --red: #fb7185;
  --shadow: 0 22px 80px rgba(0, 0, 0, 0.42);
  --focus: 0 0 0 3px rgba(168, 255, 26, 0.24), 0 0 0 1px rgba(168, 255, 26, 0.9);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg-deep);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(180deg, rgba(5, 9, 16, 0.2), var(--bg-deep) 760px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.028) 0 1px, transparent 1px 88px),
    repeating-linear-gradient(180deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 88px),
    var(--bg-deep);
  color: var(--text);
  font-family: "Fira Sans", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0;
  text-rendering: geometricPrecision;
  font-variant-numeric: tabular-nums;
}

button,
canvas {
  font: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: none;
  box-shadow: var(--focus);
}

.dashboard-shell {
  width: min(1480px, 100%);
  margin: 0 auto;
  padding: 0 clamp(14px, 2.2vw, 32px) 34px;
  position: relative;
}

.dashboard-shell::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(120deg, rgba(59, 130, 246, 0.11), transparent 32%, rgba(168, 255, 26, 0.08) 72%, transparent),
    linear-gradient(180deg, transparent 0, rgba(2, 5, 10, 0.72) 78%);
  opacity: 0.9;
  z-index: -1;
}

.hero {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  box-shadow: var(--shadow);
  isolation: isolate;
}

.hero__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.92;
  transform: scale(1.015);
}

.hero__shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 5, 10, 0.98) 0%, rgba(2, 7, 13, 0.9) 38%, rgba(2, 7, 13, 0.2) 76%),
    linear-gradient(180deg, rgba(2, 7, 13, 0.22) 0%, rgba(2, 7, 13, 0.82) 100%);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(168, 255, 26, 0.72), rgba(59, 130, 246, 0.46), transparent);
  z-index: 2;
}

.topline {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: max-content 1fr max-content;
  align-items: center;
  gap: 24px;
  padding: 28px clamp(18px, 2vw, 30px) 0;
  color: var(--text-soft);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 13px;
  font-weight: 600;
}

.topline > span:first-child {
  padding: 8px 12px;
  border: 1px solid rgba(177, 215, 245, 0.18);
  border-radius: 999px;
  background: rgba(3, 10, 18, 0.48);
  backdrop-filter: blur(12px);
}

.top-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  white-space: nowrap;
}

#dayBadge {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  border: 1px solid rgba(177, 215, 245, 0.18);
  border-radius: 999px;
  background: rgba(3, 10, 18, 0.48);
  backdrop-filter: blur(12px);
}

.sync-button {
  min-width: 68px;
  min-height: 44px;
  border: 1px solid rgba(168, 255, 26, 0.58);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(168, 255, 26, 0.18), rgba(168, 255, 26, 0.07));
  color: var(--lime);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease, color 0.2s ease;
}

.sync-button:hover {
  border-color: var(--lime);
  background: linear-gradient(180deg, rgba(168, 255, 26, 0.28), rgba(168, 255, 26, 0.1));
  transform: translateY(-1px);
}

.sync-button:active {
  transform: translateY(0) scale(0.98);
}

.sync-button:disabled {
  cursor: wait;
  opacity: 0.62;
  transform: none;
}

.timeline {
  height: 8px;
  border: 1px solid rgba(177, 215, 245, 0.14);
  border-radius: 999px;
  background: rgba(179, 196, 212, 0.14);
  overflow: hidden;
  box-shadow: inset 0 1px 7px rgba(0, 0, 0, 0.45);
}

.timeline span {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--lime), var(--cyan), rgba(59, 130, 246, 0.35));
  border-radius: inherit;
  box-shadow: 0 0 20px rgba(168, 255, 26, 0.44);
  transition: width 0.45s ease-out;
}

.hero__content {
  position: relative;
  z-index: 2;
  width: min(760px, 100%);
  padding: clamp(72px, 8vw, 110px) clamp(18px, 2vw, 30px) 46px;
}

.hero-medal {
  position: absolute;
  z-index: 3;
  right: clamp(92px, 8vw, 150px);
  bottom: clamp(56px, 7vw, 92px);
  width: clamp(172px, 10vw, 210px);
  display: none;
  justify-items: center;
  text-align: center;
}

.hero-medal.is-visible {
  display: grid;
}

.hero-medal img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 22px 42px rgba(0, 0, 0, 0.58));
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--lime);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  color: var(--text);
  font-family: "Fira Sans", "Microsoft YaHei", sans-serif;
  font-size: clamp(54px, 8vw, 104px);
  line-height: 0.9;
  font-weight: 900;
  letter-spacing: 0;
  text-shadow: 0 20px 52px rgba(0, 0, 0, 0.72), 0 0 34px rgba(59, 130, 246, 0.22);
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.12;
  font-weight: 800;
}

.tagline {
  max-width: 620px;
  color: var(--text-soft);
  font-size: clamp(17px, 2vw, 21px);
}

.profile-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.profile-pill {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(177, 215, 245, 0.2);
  background: rgba(5, 16, 25, 0.66);
  padding: 9px 14px;
  border-radius: 999px;
  color: #e2edf5;
  backdrop-filter: blur(12px);
}

.panel {
  position: relative;
  margin-top: 18px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.012)),
    var(--surface);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow);
  backdrop-filter: blur(18px);
  overflow: hidden;
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(177, 215, 245, 0.38), transparent);
  pointer-events: none;
}

.summary-panel {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0;
}

.metric-card {
  min-height: 140px;
  padding: 22px;
  border-right: 1px solid rgba(151, 177, 201, 0.18);
  background: linear-gradient(180deg, rgba(59, 130, 246, 0.035), transparent);
}

.metric-card:last-child {
  border-right: 0;
}

.metric-card span,
.section-title span,
.trend-head span,
.week-card span,
.life-item span,
.diet-item span,
.composition-item span,
.streak small {
  color: var(--muted);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.metric-card strong {
  display: block;
  margin-top: 14px;
  font-size: clamp(25px, 2.5vw, 36px);
  line-height: 1;
  color: var(--text);
}

.metric-card p {
  margin: 10px 0 0;
  min-height: 21px;
  color: var(--muted-strong);
  font-size: 14px;
}

.delta {
  margin-top: 12px;
  color: var(--lime);
  font-weight: 800;
}

.delta.bad {
  color: var(--red);
}

.ring-panel {
  display: block;
  padding: 0;
}

.rings {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  padding: 22px;
}

.ring-card {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 14px;
  min-height: 184px;
  border: 1px solid rgba(151, 177, 201, 0.15);
  border-radius: 8px;
  background: rgba(3, 12, 20, 0.32);
}

.ring {
  width: min(128px, 68%);
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at center, rgba(6, 16, 26, 1) 0 64%, transparent 65%),
    conic-gradient(var(--accent) var(--value), rgba(91, 113, 130, 0.26) 0);
  box-shadow: 0 0 28px color-mix(in srgb, var(--accent) 22%, transparent);
}

.ring strong {
  font-family: "Fira Code", monospace;
  font-size: clamp(28px, 3vw, 36px);
  line-height: 1;
}

.ring-card p {
  margin: 0;
  color: var(--muted-strong);
  font-size: 15px;
  font-weight: 600;
}

.side-metrics,
.lifestyle-list,
.diet-list,
.composition-list {
  display: grid;
  gap: 10px;
}

.side-metric,
.diet-item,
.composition-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  min-height: 58px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(151, 177, 201, 0.15);
}

.life-item {
  display: grid;
  grid-template-columns: auto auto;
  gap: 12px;
  align-items: center;
  min-height: 58px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(151, 177, 201, 0.15);
}


.side-metric:last-child,
.life-item:last-child,
.diet-item:last-child,
.composition-item:last-child {
  border-bottom: 0;
}

.side-metric strong,
.diet-item strong {
  display: block;
  color: var(--text);
  font-size: 22px;
  line-height: 1.2;
}

.life-item strong {
  display: block;
  color: var(--text);
  font-size: 18px;
  line-height: 1.25;
  text-align: right;
  white-space: nowrap;
}

.diet-item strong {
  max-width: 150px;
  font-size: 18px;
  line-height: 1.25;
  text-align: right;
  overflow-wrap: anywhere;
}

.diet-extra {
  display: grid;
  gap: 12px;
  margin-top: 6px;
  padding: 14px;
  border: 1px solid rgba(151, 177, 201, 0.16);
  border-radius: 8px;
  background: rgba(3, 12, 20, 0.3);
}

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

.diet-extra__metric span,
.diet-extra__chips span {
  color: var(--muted);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.diet-extra__metric strong {
  color: var(--lime);
  font-family: "Fira Code", monospace;
  font-size: 20px;
  line-height: 1;
}

.diet-extra__chips div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.diet-extra__chips em {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid rgba(45, 212, 191, 0.22);
  border-radius: 8px;
  background: rgba(45, 212, 191, 0.06);
  color: var(--text-soft);
  font-style: normal;
  font-size: 12px;
}

.section-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 22px 24px 0;
}

.section-title h3 {
  margin-bottom: 0;
  font-size: 22px;
  line-height: 1.2;
}

.trend-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  padding: 22px;
}

.trend-card {
  min-height: 230px;
  padding: 18px;
  border: 1px solid rgba(151, 177, 201, 0.16);
  border-radius: 8px;
  background: rgba(3, 12, 20, 0.34);
}

.trend-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.trend-head strong {
  display: block;
  margin-top: 6px;
  font-family: "Fira Code", monospace;
  font-size: 21px;
  line-height: 1.25;
}

canvas {
  display: block;
  width: 100%;
  height: 142px;
}

.weekly-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding: 22px;
}

.week-card {
  border: 1px solid rgba(151, 177, 201, 0.18);
  background: rgba(3, 12, 20, 0.38);
  border-radius: 8px;
  padding: 20px;
}

.week-card strong {
  display: block;
  color: var(--lime);
  font-family: "Fira Code", monospace;
  font-size: 42px;
  line-height: 1;
  margin: 14px 0;
}

.week-card p {
  margin-bottom: 10px;
  color: var(--muted-strong);
}

.bar,
.mini-bar {
  border-radius: 999px;
  background: rgba(127, 145, 160, 0.2);
  overflow: hidden;
  box-shadow: inset 0 1px 5px rgba(0,0,0,0.35);
}

.bar {
  height: 8px;
}

.bar span,
.mini-bar span {
  display: block;
  height: 100%;
  width: var(--bar);
  border-radius: inherit;
}

.bar span {
  background: linear-gradient(90deg, var(--lime), var(--cyan));
}


.daily-detail-list {
  display: grid;
  gap: 12px;
  padding: 20px 22px 22px;
}

.daily-detail-item {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 18px;
  align-items: center;
  min-height: 72px;
  padding: 14px 16px;
  border: 1px solid rgba(151, 177, 201, 0.16);
  border-radius: 8px;
  background: rgba(3, 12, 20, 0.34);
}

.daily-detail-date strong {
  display: block;
  color: var(--text);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 15px;
}

.daily-detail-date span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-family: "Fira Code", monospace;
  font-size: 11px;
  font-weight: 700;
}


.day-status {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-top: 8px;
  padding: 4px 7px;
  border: 1px solid rgba(151, 177, 201, 0.18);
  border-radius: 8px;
  color: var(--muted-strong);
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
}

.day-status--strong {
  border-color: rgba(168, 255, 26, 0.34);
  background: rgba(168, 255, 26, 0.08);
  color: var(--lime);
}

.day-status--medium {
  border-color: rgba(59, 130, 246, 0.3);
  background: rgba(59, 130, 246, 0.08);
  color: #93c5fd;
}

.day-status--soft {
  border-color: rgba(151, 177, 201, 0.18);
  background: rgba(151, 177, 201, 0.06);
}
.daily-activities {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.activity-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, rgba(151, 177, 201, 0.16));
  border-radius: 8px;
  background: color-mix(in srgb, var(--accent) 9%, rgba(3, 12, 20, 0.38));
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 700;
}

.activity-chip strong {
  color: var(--text);
  font-family: "Fira Code", monospace;
  font-size: 16px;
  line-height: 1;
}

.activity-chip em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.daily-empty {
  padding: 18px;
  border: 1px dashed rgba(151, 177, 201, 0.2);
  border-radius: 8px;
  color: var(--muted);
}
.daily-detail-panel {
  display: flex;
  flex-direction: column;
}

.daily-detail-list {
  display: grid;
  gap: 8px;
  padding: 18px 22px 8px;
}

.daily-detail-list.is-expanded {
  max-height: 430px;
  overflow-y: auto;
  padding-right: 14px;
  scrollbar-color: rgba(168, 255, 26, 0.5) rgba(151, 177, 201, 0.12);
  scrollbar-width: thin;
}

.daily-detail-list.is-expanded::-webkit-scrollbar {
  width: 7px;
}

.daily-detail-list.is-expanded::-webkit-scrollbar-track {
  background: rgba(151, 177, 201, 0.1);
  border-radius: 999px;
}

.daily-detail-list.is-expanded::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--lime), var(--cyan));
  border-radius: 999px;
}

.daily-detail-item {
  display: grid;
  grid-template-columns: 120px 64px 78px 92px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 46px;
  padding: 9px 12px;
  border: 1px solid rgba(151, 177, 201, 0.14);
  border-radius: 7px;
  background: rgba(3, 12, 20, 0.28);
}

.daily-detail-date,
.daily-detail-week,
.daily-detail-day {
  color: var(--muted-strong);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.daily-detail-date {
  color: var(--text);
}

.day-status {
  margin-top: 0;
  justify-self: start;
  white-space: nowrap;
}

.daily-activities {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.activity-chip {
  min-height: 26px;
  padding: 4px 8px;
  gap: 4px;
  font-size: 12px;
}

.activity-chip strong {
  font-size: 14px;
}

.activity-chip em {
  font-size: 11px;
}

.daily-no-activity {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.daily-detail-toggle {
  align-self: center;
  margin: 8px 0 18px;
  padding: 8px 18px;
  border: 1px solid rgba(168, 255, 26, 0.42);
  border-radius: 999px;
  background: rgba(168, 255, 26, 0.08);
  color: var(--lime);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.daily-detail-toggle:hover {
  border-color: rgba(168, 255, 26, 0.7);
  background: rgba(168, 255, 26, 0.14);
}
.lower-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: 18px;
  row-gap: 18px;
  margin-top: 18px;
}

.lower-grid .panel {
  margin-top: 0;
  padding-bottom: 20px;
}

.composition-list,
.diet-list,
.lifestyle-list,
.streak-grid {
  padding: 18px 24px 0;
}

.composition-item {
  grid-template-columns: minmax(92px, 120px) 1fr 70px;
}

.composition-item small {
  grid-column: 2 / 4;
  color: var(--muted);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 11px;
}

.composition-item strong {
  text-align: right;
  font-family: "Fira Code", monospace;
  color: var(--text-soft);
}

.mini-bar {
  height: 7px;
}

.mini-bar span {
  background: var(--accent);
}

.streak-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.habit-panel .streak-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding-top: 14px;
}

.streak {
  min-height: 106px;
  display: grid;
  place-items: center;
  gap: 6px;
  border: 1px solid rgba(151, 177, 201, 0.16);
  border-radius: 8px;
  padding: 12px 8px;
  text-align: center;
  background:
    linear-gradient(180deg, rgba(168, 255, 26, 0.045), transparent),
    rgba(3, 12, 20, 0.32);
}

.streak small {
  font-size: 11px;
}

.streak strong {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 2px;
  width: 100%;
  margin-top: 0;
  color: var(--lime);
  font-family: "Fira Code", monospace;
  line-height: 1;
}

.streak strong span {
  font-size: clamp(24px, 2.2vw, 30px);
}

.streak strong em {
  font-style: normal;
  font-size: 13px;
  font-weight: 700;
}


.achievement-panel {
  padding-bottom: 24px;
}

.achievement-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  padding: 22px;
}

.badge-card {
  min-height: 238px;
  display: grid;
  grid-template-rows: 1fr auto auto auto auto;
  align-items: end;
  gap: 9px;
  padding: 14px 12px;
  border: 1px solid rgba(151, 177, 201, 0.16);
  border-radius: 8px;
  background: rgba(3, 12, 20, 0.36);
  text-align: center;
}

.badge-card--active {
  border-color: rgba(168, 255, 26, 0.42);
  background: linear-gradient(180deg, rgba(168, 255, 26, 0.07), rgba(3, 12, 20, 0.42));
}

.badge-card--earned {
  border-color: rgba(45, 212, 191, 0.44);
  background: linear-gradient(180deg, rgba(45, 212, 191, 0.08), rgba(3, 12, 20, 0.42));
}

.badge-card--locked {
  opacity: 0.58;
}

.badge-card--locked .badge-image {
  filter: grayscale(1) brightness(0.56) contrast(0.9);
}

.badge-image-wrap {
  min-height: 132px;
  display: grid;
  place-items: center;
}

.badge-image {
  width: min(128px, 92%);
  height: auto;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.42));
}

.badge-card strong {
  display: block;
  color: var(--text);
  font-size: 15px;
  line-height: 1.22;
}

.badge-card span,
.badge-card em {
  color: var(--muted);
  font-family: "Fira Code", "Microsoft YaHei", monospace;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

.badge-progress {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(127, 145, 160, 0.2);
  overflow: hidden;
}

.badge-progress span {
  display: block;
  width: var(--bar);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--lime), var(--cyan));
}

.badge-card--locked .badge-progress span {
  background: rgba(145, 167, 184, 0.36);
}

.site-footer {
  padding: 10px 4px 0;
  color: rgba(183, 198, 211, 0.68);
  font-size: 12px;
  text-align: center;
}
@media (hover: hover) {
  .metric-card,
  .trend-card,
  .week-card,
  .ring-card,
  .streak,
  .badge-card {
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
  }

  .metric-card:hover,
  .trend-card:hover,
  .week-card:hover,
  .ring-card:hover,
  .streak:hover,
  .badge-card:hover {
    border-color: rgba(177, 215, 245, 0.32);
    background-color: rgba(16, 35, 52, 0.42);
    transform: translateY(-1px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}

@media (max-width: 1180px) {
  .hero-medal,
  .hero-medal.is-visible {
    display: none;
  }

  .summary-panel,
  .trend-grid,
  .rings,
  .weekly-grid,
  .lower-grid,
  .achievement-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ring-panel {
    grid-template-columns: 1fr;
  }

  .summary-panel .metric-card:nth-child(2n) {
    border-right: 0;
  }
}

@media (max-width: 760px) {
  .dashboard-shell {
    padding: 0 12px 22px;
  }

  .topline {
    grid-template-columns: 1fr;
    gap: 12px;
    padding-inline: 14px;
  }

  .top-actions {
    justify-content: space-between;
  }

  .timeline {
    order: 3;
  }

  .hero {
    min-height: 610px;
  }

  .hero__shade {
    background:
      linear-gradient(180deg, rgba(2, 5, 10, 0.58) 0%, rgba(2, 5, 10, 0.98) 78%),
      linear-gradient(90deg, rgba(2, 5, 10, 0.82), rgba(2, 5, 10, 0.34));
  }

  .hero__content {
    padding: 72px 14px 30px;
  }

  .profile-row {
    gap: 8px;
  }

  .profile-pill {
    width: 100%;
    justify-content: space-between;
  }

  .summary-panel,
  .trend-grid,
  .rings,
  .weekly-grid,
  .lower-grid {
    grid-template-columns: 1fr;
  }

  .trend-grid,
  .weekly-grid,
  .rings {
    padding: 16px;
  }

  .daily-detail-list {
    padding: 16px;
  }

  .daily-detail-item {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .metric-card,
  .summary-panel .metric-card:nth-child(2n) {
    border-right: 0;
    border-bottom: 1px solid rgba(151, 177, 201, 0.18);
  }

  .metric-card:last-child {
    border-bottom: 0;
  }

  .section-title {
    flex-wrap: wrap;
    padding: 20px 18px 0;
  }

  .composition-list,
  .diet-list,
  .lifestyle-list,
  .streak-grid {
    padding-inline: 18px;
  }

  .composition-item {
    grid-template-columns: 1fr;
  }

  .composition-item strong {
    text-align: left;
  }

  .habit-panel .streak-grid,
  .streak-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .final-panel {
    padding: 26px 22px;
  }
}

