:root {
  --bg: #000000;
  --card: #141416;
  --ink: #f4f4f6;
  --soft: rgba(244, 244, 246, 0.56);
  --line: rgba(244, 244, 246, 0.12);
  --accent: #ff8a4c;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Mona Sans Variable", "Mona Sans", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

.stage {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: 10px 12px;
}
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; outline: none; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.wt { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; width: min(348px, 100%); padding: 16px 16px 16px; border-radius: 26px; background: var(--card); box-shadow: inset 0 0 0 1px var(--line), inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 30px 50px -30px rgba(0, 0, 0, 0.9); }
.wt__head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 0 2px; }
.wt__head strong { font-size: 16px; line-height: 20px; font-weight: 740; letter-spacing: -0.01em; }
.wt__delta { display: flex; align-items: center; gap: 5px; height: 26px; padding: 0 11px 0 8px; border-radius: 13px; background: rgba(244, 244, 246, 0.07); font-size: 12px; font-weight: 690; white-space: nowrap; font-variant-numeric: tabular-nums; }
.wt__delta svg { display: block; width: 12px; height: 12px; fill: none; stroke: var(--accent); stroke-width: 1.800; stroke-linecap: round; stroke-linejoin: round; }
.wt__clip { display: block; height: 16px; line-height: 16px; overflow: hidden; }
.wt__clip span { display: block; }

.wt__set { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; align-items: center; gap: 8px; }
.wt__step { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(244, 244, 246, 0.07); box-shadow: inset 0 0 0 1px rgba(244, 244, 246, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.wt__step svg { display: block; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.wt__step:focus-visible { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--ink); }
.wt__now { display: flex; justify-content: center; align-items: baseline; gap: 5px; white-space: nowrap; }
.wt__now b { font-size: 44px; line-height: 46px; font-weight: 660; font-stretch: 90%; letter-spacing: -0.025em; font-variant-numeric: tabular-nums; }
.wt__now i { font-style: normal; font-size: 15px; font-weight: 680; color: var(--soft); }

/* the week: the drawing stretches with the card, and the round marker, the goal tag and the tooltip sit over it in HTML so they never stretch with it */
.wt__chart { position: relative; height: min(92px, 23vh); color: var(--accent); touch-action: pan-y; }
.wt__chart svg { display: block; width: 100%; height: 100%; overflow: visible; }
.wt__goal { stroke: rgba(244, 244, 246, 0.32); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.wt__area { fill: url(#wt-fade); stroke: none; }
.wt__line { fill: none; stroke: var(--accent); stroke-width: 2.200; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.wt__guide { stroke: rgba(244, 244, 246, 0.3); stroke-width: 1; vector-effect: non-scaling-stroke; opacity: 0; }
.wt__dot { position: absolute; left: 0; top: 0; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: var(--card); box-shadow: inset 0 0 0 2.500px var(--accent); transition: background-color 0.25s ease; }
.wt__dot.is-saved { background: var(--accent); }
.wt__goaltag { position: absolute; left: 0; top: 0; padding: 0 5px; border-radius: 6px; background: var(--card); font-size: 10.500px; line-height: 14px; font-weight: 680; color: var(--soft); white-space: nowrap; transition: color 0.3s ease; }
.wt__goaltag.is-met { color: var(--accent); }
.wt__tip { position: absolute; left: 0; top: 0; padding: 3px 7px; border-radius: 8px; background: var(--ink); color: #0c0c0e; font-size: 11px; line-height: 14px; font-weight: 720; white-space: nowrap; font-variant-numeric: tabular-nums; opacity: 0; pointer-events: none; }
.wt__days { list-style: none; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); margin-top: -4px; }
.wt__days li { text-align: center; font-size: 10.500px; line-height: 14px; font-weight: 640; color: rgba(244, 244, 246, 0.4); white-space: nowrap; }
.wt__days li.is-today { color: var(--ink); }

.wt__save { display: flex; justify-content: center; align-items: center; gap: 0; height: 44px; border-radius: 22px; background: var(--ink); color: #0c0c0e; font-size: 14px; font-weight: 730; white-space: nowrap; box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.12), 0 14px 20px -12px rgba(244, 244, 246, 0.3); }
.wt__save svg { display: block; width: 0; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.200; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.wt__save svg path { stroke-dasharray: 1; stroke-dashoffset: 1; }
.wt__save:focus-visible { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--ink); }

.ghost { position: absolute; left: 0; top: 0; width: 24px; height: 24px; margin: -3px 0 0 -5px; transform-origin: 20% 15%; pointer-events: none; opacity: 0; fill: #ffffff; stroke: #0c0c0e; stroke-width: 1.300; stroke-linejoin: round; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5)); z-index: 6; }

@media (hover: hover) { .wt__step:hover { background: rgba(244, 244, 246, 0.12); } }
@media (max-width: 350px) { .wt { padding: 14px 13px 14px; } .wt__now b { font-size: 40px; } .wt__days li { font-size: 10px; } }
@media (max-height: 400px) { .wt { gap: 8px; } }
@media (prefers-reduced-motion: reduce) { .wt__dot, .wt__goaltag { transition: none; } }
