@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:wght@500;600;700;800&family=DM+Sans:wght@400;500;600;650;700&display=swap');

:root {
  color-scheme: light;
  --paper:#f5f6f1; --white:#fff; --ink:#17241e; --muted:#5d6a62; --line:#e1e6df;
  --forest:#142a22; --forest-dark:#10231c; --mint:#e8f1e9; --green:#285744;
  --lime:#d9ef88; --radius:17px;
  font-family:'DM Sans',system-ui,sans-serif; font-size:15px; background:var(--paper); color:var(--ink);
  font-variant-numeric:tabular-nums;
}
* {box-sizing:border-box}
body {margin:0; min-width:320px}
button,input,textarea,select {font:inherit; color:inherit}
button,a,input,select,textarea,summary {-webkit-tap-highlight-color:transparent}
a {color:inherit}
button {cursor:pointer}
button:disabled {cursor:default}
a:focus-visible,button:focus-visible,select:focus-visible,input:focus-visible,textarea:focus-visible,summary:focus-visible {outline:3px solid #609574; outline-offset:3px}
main h1[tabindex="-1"]:focus {outline:none}
h1,h2,h3,p {margin:0}
h1,h2,h3,.brand {font-family:'Bricolage Grotesque','DM Sans',system-ui,sans-serif}
h1 {font-size:clamp(2.2rem,4.3vw,3.75rem); letter-spacing:-.052em; font-weight:800; line-height:1.02}
h2 {font-size:1.26rem; letter-spacing:-.025em; font-weight:800}
p {line-height:1.55}
small {font-size:.83rem}
.sr-only {position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0}
.loading {padding:32px}
.muted {color:var(--muted)}
.shell {display:grid; grid-template-columns:224px minmax(0,1fr); min-height:100dvh}
.rail {position:sticky; top:0; height:100dvh; display:flex; flex-direction:column; padding:26px 16px 16px; color:#e8f0e9; background:var(--forest); z-index:4; overflow:auto}
.brand {display:flex; align-items:center; gap:11px; font-size:1.55rem; font-weight:800; text-decoration:none; letter-spacing:-.055em; line-height:1}
.rail .brand {padding:0 9px; margin-bottom:48px}
.brand-icon,.avatar {display:grid; place-items:center; flex:none}
.brand-icon {width:39px; height:39px; border-radius:11px; background:var(--lime); color:#193124}
.brand-sub {display:block; color:#9eb3a4; font-family:'DM Sans',sans-serif; letter-spacing:.18em; font-size:.56rem; font-weight:700; margin-top:5px}
.nav-heading {color:#9eb3a4; font-size:.67rem; font-weight:700; letter-spacing:.13em; margin:0 12px 11px}
.nav-heading.second {margin-top:33px}
.rail nav {display:grid; gap:4px}
.rail nav a {display:flex; align-items:center; gap:12px; padding:0 12px; min-height:43px; border-radius:9px; text-decoration:none; color:#c9d8ce; font-size:.93rem; font-weight:600}
.rail nav a:hover,.rail nav a[aria-current] {background:#284438; color:#fff}
.rail nav a[aria-current] svg {color:var(--lime)}
.rail-bottom {margin-top:auto; padding-top:20px}
.rail-profile {color:inherit; background:#20392e; border:1px solid #30493e; border-radius:12px; width:100%; min-height:63px; display:flex; align-items:center; text-align:left; gap:11px; padding:9px}
.rail-profile strong,.rail-profile small {display:block}
.rail-profile small {color:#a9bcb0; margin-top:3px}
.rail-profile > svg {margin-left:auto}
.avatar {background:#e5eddf; color:#2a5341; width:37px; height:37px; border:0; border-radius:50%; font-weight:800}
.topbar {height:69px; border-bottom:1px solid var(--line); display:flex; align-items:center; justify-content:space-between; padding:0 max(28px,3.1vw); background:#fff}
.desktop-crumb,.top-right,.mode {display:flex; align-items:center; gap:10px; color:var(--muted)}
.desktop-crumb {font-weight:650}
.top-right {gap:16px}
.mode {font-size:.78rem; gap:6px; font-weight:650}
.mode i,.date-dot {display:inline-block; width:7px; height:7px; border-radius:50%; background:#74a17a}
.mobile-brand,.mobile-nav {display:none}
.content {max-width:1440px; margin:auto; padding:36px max(28px,3.1vw) 56px}
.page-head {display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:27px}
.page-head p {color:var(--muted); margin-top:10px; font-size:1rem}
.eyebrow {display:flex; align-items:center; gap:8px; color:var(--green); text-transform:uppercase; font-weight:800; font-size:.72rem; letter-spacing:.12em; margin-bottom:11px}
.text-link {display:inline-flex; align-items:center; gap:7px; color:var(--green); font-size:.86rem; font-weight:800; text-decoration:none; white-space:nowrap; min-height:38px}
.text-link:hover {text-decoration:underline}
.dashboard-grid {display:grid; grid-template-columns:minmax(0,1.55fr) minmax(285px,1fr); gap:20px; align-items:start}
.dashboard-schedule {display:grid; gap:15px; min-width:0}
.hero {min-height:277px; border-radius:var(--radius); display:flex; align-items:center; color:#fff; background:#0e211a url('/gym.jpg') 63% 54%/cover no-repeat; overflow:hidden; position:relative; isolation:isolate}
.hero:before {content:''; position:absolute; inset:0; z-index:-1; background:linear-gradient(90deg,#10251ef5 0%,#10251edb 34%,#10251e35 85%)}
.hero-content {padding:26px 30px; max-width:100%}
.hero-kicker {display:flex; gap:8px; align-items:center; color:#e3eece; font-weight:800; font-size:.67rem; letter-spacing:.13em; margin-bottom:14px}
.hero-kicker i {width:8px; height:8px; background:var(--lime); border-radius:50%}
.hero h2 {font-size:clamp(2.3rem,4.2vw,4rem); line-height:.98; letter-spacing:-.054em; max-width:12ch}
.hero p {color:#d5e2d9; margin-top:12px}
.hero-meta {display:flex; align-items:center; gap:7px; color:#dae7dc; margin-top:15px; font-size:.83rem; flex-wrap:wrap}
.hero-meta span {margin:0 3px}
.hero .btn {margin-top:19px}
.btn {display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:42px; padding:8px 13px; text-decoration:none; white-space:normal; background:var(--white); border:1px solid var(--line); border-radius:9px; color:var(--ink); font-size:.87rem; font-weight:750; line-height:1.25}
.btn:hover {background:#edf2eb}
.btn.primary {color:#fff; border-color:var(--forest); background:var(--forest)}
.btn.primary:hover {background:var(--green)}
.btn.lime {color:#1c3024; background:var(--lime); border-color:var(--lime); min-height:45px; padding-inline:15px}
.btn.lime:hover {background:#e9f8b3}
.btn.icon-only {font-size:0; gap:0; padding:8px 10px}
.btn.selected {background:var(--mint); color:var(--green); border-color:#b8ccb9}
.panel {border:1px solid var(--line); border-radius:var(--radius); background:var(--white); padding:20px; min-width:0}
.content > .panel + .panel {margin-top:15px}
.panel-head,.section-head {display:flex; justify-content:space-between; align-items:center; gap:10px}
.panel-head {margin-bottom:12px}
.panel h2 + p,.panel h2 + form {margin-top:12px}
.section-head {margin:24px 0 11px}
.section-head h2 {font-size:1.35rem}
.schedule-panel {padding:14px 17px}
.schedule-panel .panel-head {margin-bottom:1px}
.agenda-day {display:grid; grid-template-columns:42px minmax(0,1fr); gap:8px; align-items:start; padding:7px 0}
.agenda-day + .agenda-day {border-top:1px solid var(--line)}
.day-stamp {text-align:center; padding:3px 0; line-height:1.18; border-radius:8px; color:var(--muted)}
.day-stamp span,.day-stamp strong {display:block}
.day-stamp span {font-size:.65rem; font-weight:800; text-transform:uppercase; letter-spacing:.07em}
.day-stamp strong {font-size:1.12rem}
.event-row {width:100%; display:flex; align-items:center; gap:9px; text-align:left; padding:2px 3px; min-height:46px; border:0; border-radius:8px; color:var(--ink); background:transparent}
.event-row:not(:disabled):hover {background:var(--paper)}
.event-copy {min-width:0; flex:1}
.event-copy strong,.event-copy small {display:block}
.event-copy strong {font-size:.86rem}
.event-copy small {margin-top:3px; font-size:.74rem; color:var(--muted); text-transform:capitalize}
.event-icon,.metric-icon,.empty-icon {flex:none; width:37px; height:37px; border-radius:10px; display:grid; place-items:center; color:var(--green); background:var(--mint)}
.event-icon.football {background:#e9edda; color:#4d6233}
.event-icon.rest {background:#f0f0e8; color:#616958}
.event-icon.gym {background:#e3efe9}
.done-icon {color:var(--green)}
.metrics-grid,.quick-grid {display:grid; gap:12px; grid-template-columns:repeat(3,minmax(0,1fr))}
.metric-tile {display:flex; gap:11px; align-items:flex-start; padding:15px; min-height:111px; text-decoration:none}
.metric-tile:hover,.quick-grid a:hover {border-color:#a0b9a6}
.metric-tile > svg:last-child {margin-left:auto; margin-top:3px; flex:none; color:#718477}
.metric-tile .muted {font-size:.77rem}
.metric-value {font-family:'Bricolage Grotesque',sans-serif; font-weight:800; font-size:1.7rem; letter-spacing:-.035em; margin:3px 0}
.metric-value small {font:650 .77rem 'DM Sans',sans-serif; color:var(--muted); letter-spacing:0}
.quick-grid {grid-template-columns:repeat(4,minmax(0,1fr))}
.quick-grid a {display:flex; align-items:center; gap:8px; min-height:56px; padding:9px 12px; background:#fff; border:1px solid var(--line); border-radius:11px; font-weight:750; font-size:.8rem; text-decoration:none}
.quick-grid svg {flex:none; color:var(--green)}
.quick-grid svg:last-child {margin-left:auto}
.today-activities,.dashboard-note {margin-top:22px}
.empty {padding:18px 4px; color:var(--muted)}
.empty h3 {margin:9px 0 5px; color:var(--ink)}
.empty p {font-size:.89rem}
.list-row {display:flex; align-items:center; justify-content:space-between; gap:12px; padding:11px 0; min-height:49px; text-decoration:none; border-bottom:1px solid var(--line)}
.list-row:last-child {border-bottom:0}
.list-row small {display:block; margin-top:4px; color:var(--muted); overflow-wrap:anywhere}
.stack {display:grid; gap:12px; max-width:710px}
.stack > .btn {justify-self:start}
.field {display:grid; gap:6px; min-width:0; font-weight:700; font-size:.85rem}
.field input,.field select,.field textarea,.set-row input {width:100%; min-width:0; min-height:44px; background:#fcfdfb; border:1px solid #cfd9d0; border-radius:8px; padding:8px 10px; font-weight:500}
.field textarea {min-height:85px; resize:vertical}
.check {display:flex; align-items:center; gap:9px; min-height:40px; font-size:.9rem}
input[type=checkbox] {accent-color:#2c684e; width:17px; height:17px}
.form-grid {display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,175px),1fr)); gap:12px}
.actions,.button-group,.tag-row,.settings-links {display:flex; align-items:center; gap:8px; flex-wrap:wrap}
.settings-links {margin-bottom:16px}
.form-error {color:#9c2525; font-size:.85rem; margin-top:7px}
.form-error:empty {display:none}
.banner,.notice {background:#f1f4df; padding:11px 12px; border-radius:9px; color:#374a2f; font-size:.85rem; margin-bottom:13px}
.tag-row span,.pill {display:inline-block; padding:6px 9px; border-radius:7px; background:var(--mint); color:var(--green); font-size:.76rem; font-weight:750}
.pill {margin-top:8px}
.calendar-panel {padding:0; overflow:hidden}
.calendar-controls {display:flex; align-items:center; justify-content:space-between; padding:12px 15px; gap:10px; flex-wrap:wrap}
.calendar-grid {display:grid; grid-template-columns:repeat(7,minmax(0,1fr))}
.cal-label {color:var(--muted); padding:10px 7px; text-align:center; border-top:1px solid var(--line); font-weight:750; font-size:.77rem}
.cal-cell {min-height:103px; padding:4px; border-top:1px solid var(--line); border-right:1px solid var(--line); min-width:0}
.cal-cell:nth-child(7n) {border-right:0}
.calendar-grid.week .cal-cell {min-height:139px}
.cal-cell.picked {background:#f1f6ef}
.cal-cell.outside {background:#f8f9f6}
.day-button {display:flex; align-items:center; justify-content:center; min-width:35px; min-height:38px; padding:0; border:0; background:transparent; font-weight:700; border-radius:8px}
.cal-now {background:var(--forest); color:#fff; min-width:27px; height:27px; display:grid; place-items:center; border-radius:50%}
.cal-dots {display:none}
.cal-event {display:flex; gap:4px; align-items:center; text-align:left; color:var(--green); background:#e8f2e9; border:0; border-radius:7px; padding:5px; font-size:.71rem; font-weight:750; min-height:35px; width:100%; margin:3px 0}
.cal-event svg {flex:none}
.cal-event.football {background:#edf0da; color:#445b2d}
.cal-event.rest,.cal-event.skipped,.cal-event.missed {background:#f0f1ec; color:var(--muted)}
.day-agenda {margin-top:14px}
.metric-tabs {display:flex; flex-wrap:wrap; gap:6px; margin-bottom:15px}
.metric-tabs a {display:inline-flex; align-items:center; padding:7px 10px; min-height:39px; border:1px solid var(--line); background:#fff; border-radius:8px; font-size:.83rem; text-decoration:none; font-weight:700}
.metric-tabs a[aria-current] {color:#fff; background:var(--forest)}
.reading-stats {display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:13px; margin:8px 0 16px}
.reading-stats span,.reading-stats small {display:block; color:var(--muted); font-size:.81rem}
.reading-stats strong {display:block; margin:4px 0; font-size:clamp(1.1rem,2.5vw,1.85rem); line-height:1.15; overflow-wrap:anywhere}
.chart {max-width:760px; margin:14px 0 8px}
.chart svg {display:block; width:100%; height:auto; overflow:visible}
.chart line {stroke:#dbe5dc}
.chart text {fill:var(--muted); font:12px system-ui}
.chart polyline {fill:none; stroke:#316d54; stroke-width:3; stroke-linecap:round; stroke-linejoin:round}
.chart .chart-average {stroke:#7b6d3f; stroke-dasharray:6 5; stroke-width:2}
.chart circle {fill:#316d54}
.chart figcaption,.chart-empty {color:var(--muted); font-size:.81rem}
.chart-empty {display:flex; align-items:center; gap:9px; min-height:95px}
.library-filters {display:grid; grid-template-columns:2fr repeat(4,1fr); gap:8px}
.library-grid {display:grid; grid-template-columns:repeat(auto-fit,minmax(210px,1fr)); gap:12px; margin-top:14px}
.library-card {display:grid; justify-items:start; align-content:start; gap:8px; position:relative; text-align:left}
.library-card:hover {border-color:#a1bba5}
.library-card small,.library-card > span:not(.metric-icon) {color:var(--muted)}
.library-card > svg:last-child {position:absolute; right:14px; top:24px}
dialog {border:1px solid var(--line); border-radius:18px; width:min(560px,calc(100vw - 24px)); max-height:calc(100dvh - 24px); padding:0; color:var(--ink)}
dialog::backdrop {background:#12291f9e}
.dialog-head {display:flex; align-items:center; justify-content:space-between; gap:15px; padding:10px 16px 10px 21px; border-bottom:1px solid var(--line)}
.close-btn,.remove-set {display:grid; place-items:center; border:0; background:transparent; min-width:42px; min-height:42px; border-radius:8px}
.close-btn:hover,.remove-set:hover {background:#edf2eb}
.dialog-body {padding:17px 21px 21px}
.progress-photo {display:block; width:100%; max-height:65dvh; object-fit:contain; border-radius:12px; margin-bottom:12px}
.earned-milestone {display:inline-flex; align-items:center; gap:4px; color:var(--green)}
.dialog-body p + .stack,.dialog-body p + .actions,.dialog-body ul + .actions,.dialog-body .actions + form {margin-top:13px}
.dialog-body ul {padding-left:21px}
.dialog-body li + li {margin-top:4px}
.guidance p {margin-top:12px}
.technique-visuals {margin-top:14px}
.technique-photo {margin:0; border:1px solid var(--line); border-radius:13px; background:var(--paper); overflow:hidden}
.technique-photo img {display:block; width:100%; height:auto; aspect-ratio:3/2; object-fit:contain; background:var(--mint)}
.technique-photo figcaption {display:grid; gap:3px; padding:10px 12px; font-size:.88rem}
.technique-photo figcaption span,.photo-note {color:var(--muted); line-height:1.45}
.technique-station {margin-top:8px}
.technique-station summary {padding:8px 0; color:var(--green)}
.guidance .photo-note {font-size:.76rem; margin-top:8px}
.guidance dt {font-weight:800; margin-top:10px}
.guidance dd {margin:2px 0 0; line-height:1.55}
.workout-page {max-width:960px}
.exercise-head {display:flex; align-items:center; gap:10px; margin-bottom:10px}
.exercise-head > div {flex:1; min-width:0}
.exercise-head p,.previous {font-size:.83rem; color:var(--muted)}
.exercise-head p {margin-top:4px}
.previous {margin:11px 0 5px}
.exercise-block .notice {margin:10px 0}
.first-workout p {margin:6px 0 0; line-height:1.55}
.starting-load .btn {margin-top:7px}
.trial-intro {margin-bottom:12px}
.trial-intro p + p {margin-top:7px}
.set-table {margin:9px 0}
.set-row {display:grid; grid-template-columns:38px minmax(55px,1fr) minmax(48px,1fr) minmax(44px,.75fr) 44px 42px; gap:7px; align-items:center}
.set-row.unloaded {grid-template-columns:38px minmax(48px,1fr) minmax(44px,.75fr) 44px 42px}
.set-header {font-size:.74rem; color:var(--muted); font-weight:750}
.set-entry {padding:6px 0; border-bottom:1px solid var(--line)}
.set-num {display:grid; font-weight:750}
.set-num small {font-size:.64rem; font-weight:600; color:var(--muted)}
.set-row input {text-align:center; padding-inline:3px; font-variant-numeric:tabular-nums}
.set-check {width:44px; height:44px; border-radius:8px; border:1px solid #cfd9d0; background:#fff; display:grid; place-items:center; color:#718075}
.set-check[aria-pressed=true] {background:var(--green); border-color:var(--green); color:#fff}
.set-entry.logged .set-row input {background:#edf5ed}
.form-check {display:flex; align-items:center; gap:5px; margin:3px 0 0 40px; min-height:29px; font-size:.72rem; color:var(--muted); cursor:pointer; width:fit-content}
.block-actions {margin:9px 0}
.set-form-note {color:var(--muted); font-size:.81rem; margin-top:8px}
summary {cursor:pointer; font-weight:750; min-height:28px}
.set-form-note p,.recovery p {margin:5px 0 9px}
.workout-footer {position:sticky; bottom:8px; z-index:2; display:flex; justify-content:space-between; align-items:center; gap:8px; background:#fff; padding:11px 14px; border:1px solid var(--line); border-radius:13px; margin-top:15px; box-shadow:0 7px 24px #10231c18}
.workout-footer small {display:block; color:var(--muted)}
#rest-clock {font-weight:800; color:var(--green); font-size:.87rem}
.toast {position:fixed; z-index:9; bottom:23px; left:50%; transform:translateX(-50%); max-width:calc(100vw - 24px); width:max-content; border-radius:9px; padding:11px 15px; background:var(--forest-dark); color:#fff; box-shadow:0 6px 20px #11241d33}
.login {min-height:100dvh; display:grid; place-items:center; padding:20px; background:var(--forest)}
.login-card {width:min(100%,410px); background:#fff; padding:26px; border-radius:18px}
.login-card h1 {font-size:2.4rem; margin:23px 0 9px}
.login-card p {margin-bottom:15px}
@media(max-width:1100px) {
  .shell {grid-template-columns:194px minmax(0,1fr)}
  .dashboard-grid {gap:13px}
  .metric-tile {padding:12px; gap:8px}
  .metric-tile .metric-icon {width:32px; height:32px}
  .library-filters {grid-template-columns:repeat(2,minmax(0,1fr))}
  .library-filters .field:first-child {grid-column:1/-1}
}
@media(max-width:860px) {
  .shell {display:block}
  .rail,.desktop-crumb {display:none}
  .topbar {height:62px; padding-inline:18px}
  .mobile-brand {display:block}
  .mobile-brand .brand {font-size:1.34rem}
  .mobile-brand .brand-icon {width:34px; height:34px}
  .mobile-brand .brand-sub {color:#5b7062}
  .mobile-nav {display:grid; grid-template-columns:repeat(5,1fr); position:fixed; z-index:5; bottom:0; inset-inline:0; background:#fff; border-top:1px solid var(--line); padding:5px 4px max(5px,env(safe-area-inset-bottom))}
  .mobile-nav a {display:grid; justify-items:center; align-content:center; min-height:48px; gap:3px; text-decoration:none; color:#56655b; font-size:.66rem; font-weight:700; text-align:center}
  .mobile-nav a[aria-current] {color:var(--green); background:var(--mint); border-radius:8px}
  .content {padding:24px 18px calc(79px + env(safe-area-inset-bottom))}
  .workout-footer {bottom:calc(64px + env(safe-area-inset-bottom))}
  .toast {bottom:calc(71px + env(safe-area-inset-bottom))}
  .field input,.field select,.field textarea,.set-row input {font-size:16px}
}
@media(max-width:620px) {
  .page-head {align-items:flex-start; flex-wrap:wrap; margin-bottom:19px; gap:8px}
  .page-head p {margin-top:6px}
  .dashboard-grid {grid-template-columns:1fr}
  .hero {min-height:238px}
  .hero-content {padding:23px 21px}
  .hero h2 {font-size:clamp(2.2rem,9vw,3.15rem)}
  .metrics-grid,.quick-grid {grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px}
  .metric-tile:last-child {grid-column:1/-1}
  .metric-tile {min-height:93px}
  .metric-tile > svg:last-child {display:none}
  .section-head {margin-top:19px}
  .panel {padding:14px}
  .calendar-panel {padding:0}
  .calendar-controls {padding:9px; gap:6px}
  .calendar-controls h2 {font-size:1rem}
  .calendar-controls .btn {min-height:38px; padding:6px 8px}
  .cal-cell,.calendar-grid.week .cal-cell {min-height:48px; padding:0}
  .cal-label {padding:7px 2px}
  .day-button {width:100%; min-height:47px; display:grid; justify-items:center; align-content:center; gap:2px}
  .cal-event {display:none}
  .cal-dots {display:flex; gap:3px}
  .cal-dots i {width:5px; height:5px; border-radius:50%; background:#7f9351}
  .cal-dots .gym {background:#32694d}
  .reading-stats {gap:8px}
  .workout-page {padding-inline:11px}
  .exercise-head .metric-icon {display:none}
  .set-row {gap:4px; grid-template-columns:29px minmax(48px,1fr) minmax(43px,1fr) minmax(42px,.75fr) 44px 34px}
  .set-row.unloaded {grid-template-columns:29px minmax(43px,1fr) minmax(42px,.75fr) 44px 34px}
  .remove-set {min-width:34px}
  .workout-footer {padding:8px}
  .workout-footer small {font-size:.71rem}
}
@media(prefers-reduced-motion:no-preference) {
  .btn,.event-row,.quick-grid a {transition:background-color .15s,border-color .15s}
}

