@font-face {
  font-family: "Manrope";
  src: url("fonts/manrope-cyr.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Manrope";
  src: url("fonts/manrope-lat.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #121417;
  --surface: #1b1e23;
  --surface-2: #252930;
  --line: #2f343c;
  --text: #eef0f2;
  --muted: #9aa3ad;
  --accent: #ff7a1a;
  --accent-ink: #1a0d02;
  --ok: #3fb67a;
  --warn: #f2c14e;
  --radius: 8px;
  --pad: 16px;
  --font: "Manrope", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  font-variant-numeric: lining-nums tabular-nums;
  font-feature-settings: "lnum" 1, "tnum" 1, "onum" 0;
  -webkit-tap-highlight-color: transparent;
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
}
.num { font-variant-numeric: lining-nums tabular-nums; font-feature-settings: "lnum" 1, "tnum" 1, "onum" 0; }

main { max-width: 560px; margin: 0 auto; padding: calc(12px + env(safe-area-inset-top)) var(--pad) 24px; }

h1 { font-size: 28px; line-height: 1.15; margin: 8px 0 4px; font-weight: 800; letter-spacing: -0.01em; }
h2 { font-size: 20px; margin: 28px 0 10px; font-weight: 700; }
h3 { font-size: 16px; margin: 18px 0 6px; font-weight: 700; }
p { margin: 6px 0; }
.muted { color: var(--muted); }
.eyebrow { color: var(--accent); font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }

svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px;
  border: 0; border-radius: var(--radius);
  background: var(--accent); color: var(--accent-ink);
  font: 700 16px/1 var(--font);
  cursor: pointer; text-decoration: none;
}
.btn:active { transform: translateY(1px); }
.btn.ghost { background: var(--surface-2); color: var(--text); }
.btn.wide { width: 100%; }
.btn.small { min-height: 38px; padding: 0 12px; font-size: 14px; }

.phase { border-left: 3px solid var(--accent); padding: 4px 0 4px 12px; margin: 14px 0 18px; }
.phase b { display: block; }

.plan { list-style: none; margin: 0 0 20px; padding: 0; border-top: 1px solid var(--line); }
.plan li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.plan img { width: 64px; height: 48px; object-fit: cover; border-radius: 4px; background: var(--surface-2); }
.plan .t { flex: 1; min-width: 0; }
.plan .t small { display: block; color: var(--muted); font-size: 13px; }
.plan .r { color: var(--muted); font-size: 14px; white-space: nowrap; }

.progress { height: 4px; background: var(--surface-2); border-radius: 2px; overflow: hidden; margin: 4px 0 14px; }
.progress i { display: block; height: 100%; background: var(--accent); }

.top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: var(--radius); background: var(--surface); color: var(--text); cursor: pointer; }

.anim {
  position: relative; aspect-ratio: 3 / 2; margin: 0 calc(var(--pad) * -1);
  background: #000; overflow: hidden;
}
.anim img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.anim img + img { animation: flip 2.6s ease-in-out infinite; }
.anim.paused img + img { animation-play-state: paused; }
.anim .tag {
  position: absolute; left: 10px; bottom: 10px; padding: 4px 8px; border-radius: 4px;
  background: rgba(0,0,0,.65); color: #fff; font-size: 12px; font-weight: 600;
}
@keyframes flip {
  0%, 30% { opacity: 0; }
  50%, 80% { opacity: 1; }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .anim img + img { animation-duration: 5s; }
}

.target { display: flex; gap: 18px; margin: 12px 0 4px; }
.target div b { display: block; font-size: 22px; }
.target div span { color: var(--muted); font-size: 13px; }

.hint { margin: 12px 0; padding: 10px 12px; border-radius: var(--radius); background: var(--surface); font-size: 14px; }
.hint.up { background: rgba(63,182,122,.14); color: #bfeed4; }

.sets { margin: 10px 0 6px; }
.set { display: grid; grid-template-columns: 28px 1fr 1fr 52px; gap: 8px; align-items: center; margin-bottom: 8px; }
.set .n { color: var(--muted); font-weight: 700; text-align: center; }
.set label { display: block; }
.set input {
  width: 100%; min-height: 48px; padding: 0 10px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); color: var(--text);
  font: 700 18px var(--font); font-variant-numeric: lining-nums tabular-nums;
  text-align: center;
}
.set input:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.set .cap { display: block; font-size: 11px; color: var(--muted); text-align: center; margin-bottom: 2px; }
.done-btn {
  width: 52px; height: 48px; align-self: end; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--muted); cursor: pointer;
}
.done-btn.on { background: var(--ok); border-color: var(--ok); color: #06210f; }

.list { margin: 4px 0 0; padding-left: 20px; }
.list li { margin: 4px 0; }
.list.bad li::marker { color: #ff6b6b; }

.links { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 8px; }

.nav-steps { display: grid; grid-template-columns: 1fr 2fr; gap: 8px; margin-top: 24px; }

.row-card { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.row-card img { width: 96px; height: 64px; object-fit: cover; border-radius: 4px; }
.row-card .t { flex: 1; }
.row-card .t small { color: var(--muted); display: block; }

.choice { display: grid; gap: 8px; margin: 10px 0; }
.choice button {
  display: flex; align-items: center; gap: 12px; padding: 8px; text-align: left;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--text);
  font: 600 15px var(--font); cursor: pointer;
}
.choice button.on { border-color: var(--accent); }
.choice img { width: 84px; height: 56px; object-fit: cover; border-radius: 4px; }

.session { padding: 12px 0; border-bottom: 1px solid var(--line); }
.session .h { display: flex; justify-content: space-between; font-weight: 700; }
.session table { width: 100%; border-collapse: collapse; margin-top: 6px; font-size: 14px; }
.session td { padding: 3px 0; vertical-align: top; }
.session td:last-child { text-align: right; color: var(--muted); }

.kv { width: 100%; border-collapse: collapse; font-size: 15px; }
.kv td { padding: 8px 0; border-bottom: 1px solid var(--line); }
.kv td:nth-child(2) { text-align: right; font-weight: 700; white-space: nowrap; }
.kv small { color: var(--muted); display: block; font-size: 12px; }

.rest {
  position: fixed; left: 0; right: 0; bottom: calc(64px + env(safe-area-inset-bottom));
  max-width: 560px; margin: 0 auto; padding: 12px var(--pad);
  display: flex; align-items: center; gap: 12px;
  background: var(--accent); color: var(--accent-ink); z-index: 20;
}
.rest[hidden] { display: none; }
.rest-label { font-weight: 700; }
.rest-time { font-size: 30px; font-weight: 800; flex: 1; }
.rest-actions { display: flex; gap: 6px; }
.rest .btn { min-height: 40px; padding: 0 12px; background: var(--accent-ink); color: #fff; }
.rest .btn.ghost { background: rgba(0,0,0,.18); color: var(--accent-ink); }

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  display: grid; grid-template-columns: repeat(3, 1fr);
  padding-bottom: env(safe-area-inset-bottom);
  background: #0d0f11; border-top: 1px solid var(--line);
}
.tabs button {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  min-height: 64px; justify-content: center;
  border: 0; background: none; color: var(--muted);
  font: 600 12px var(--font); cursor: pointer;
}
.tabs button.on { color: var(--accent); }

.empty { padding: 32px 0; color: var(--muted); }
