.rider-exercise-card {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 22px;
  overflow: hidden;
  border: 1px solid rgba(29, 95, 77, .18);
  background: linear-gradient(130deg, #f4faf6 0%, #fff 62%);
}

.rider-exercise-card-art {
  width: 108px;
  height: 108px;
  display: grid;
  place-items: center;
  border-radius: 26px;
  color: #1d5f4d;
  background: #e2f0e8;
}
.rider-exercise-card-art .rider-exercise-figure-wrap { gap: 0; }
.rider-exercise-card-art figcaption { display: none; }
.rider-exercise-card-art .rider-exercise-figure { max-width: 96px; }

.rider-exercise-card-copy h2,
.rider-exercise-card-copy p { margin: 3px 0 7px; }
.rider-exercise-card-copy > p { color: #5d6965; max-width: 650px; }
.rider-exercise-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.rider-exercise-stats span { padding: 7px 10px; border-radius: 999px; background: #fff; color: #5d6965; font-size: 12px; box-shadow: inset 0 0 0 1px #dfe9e4; }
.rider-exercise-stats b { color: #153b32; }
.rider-exercise-card-loading { min-height: 130px; display: grid; place-items: center; color: #62706b; }

.rider-exercises-page { display: grid; gap: 18px; }
.rider-exercise-page-grid { display: grid; gap: 16px; }
.rider-exercise-page-hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(260px, .8fr); gap: 28px; align-items: center; overflow: hidden; padding: 28px; border: 1px solid rgba(29, 95, 77, .18); background: linear-gradient(135deg, #f0f8f3, #fff 62%); }
.rider-exercise-page-hero h2 { max-width: 680px; margin: 4px 0 10px; font-size: clamp(26px, 4vw, 42px); line-height: 1.08; }
.rider-exercise-page-hero-copy > p:not(.kicker) { max-width: 680px; margin: 0; color: #596862; font-size: 16px; line-height: 1.55; }
.rider-exercise-page-hero-art { display: grid; place-items: center; min-height: 250px; padding: 18px; border-radius: 28px; background: rgba(255, 255, 255, .76); box-shadow: inset 0 0 0 1px rgba(29, 95, 77, .1); }
.rider-exercise-page-hero-art .rider-exercise-figure { max-width: 250px; }
.rider-exercise-page-hero .rider-exercise-actions { margin-top: 18px; }
.rider-exercise-purpose-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rider-exercise-purpose-grid article { position: relative; min-height: 142px; padding: 20px; overflow: hidden; border: 1px solid #dfe8e3; border-radius: 20px; background: #fff; }
.rider-exercise-purpose-grid b { display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: 14px; border-radius: 11px; color: #fff; background: #1d5f4d; font-size: 13px; }
.rider-exercise-purpose-grid strong { display: block; margin-bottom: 6px; font-size: 17px; }
.rider-exercise-purpose-grid p { margin: 0; color: #62706b; line-height: 1.45; }
.rider-exercise-benefits-panel { padding: 23px; }
.rider-exercise-benefits-panel h3 { margin: 0 0 15px; }
.rider-exercise-benefits-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.rider-exercise-benefits-grid div { padding: 15px; border-radius: 15px; background: #f2f7f4; }
.rider-exercise-benefits-grid strong { display: block; color: #1b463a; }
.rider-exercise-benefits-grid span { display: block; margin-top: 4px; color: #62706b; font-size: 13px; line-height: 1.4; }
.rider-exercise-page-note { margin: 14px 0 0; color: #6e7773; font-size: 12px; }
.dashboard-exercise-action svg { width: 18px; height: 18px; }

.rider-exercise-dialog {
  width: min(920px, calc(100vw - 28px));
  max-height: min(900px, calc(100dvh - 28px));
  padding: 0;
  border: 0;
  border-radius: 28px;
  color: #172b25;
  background: #fbfcfa;
  box-shadow: 0 32px 90px rgba(12, 38, 31, .28);
}
.rider-exercise-dialog::backdrop { background: rgba(12, 33, 27, .48); backdrop-filter: blur(5px); }
.rider-exercise-shell > header { position: sticky; z-index: 3; top: 0; display: flex; justify-content: space-between; align-items: center; padding: 20px 24px; border-bottom: 1px solid #e3e9e6; background: rgba(251, 252, 250, .95); backdrop-filter: blur(12px); }
.rider-exercise-shell > header p { margin: 0 0 2px; color: #bb6d56; font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.rider-exercise-shell > header h2 { margin: 0; font-size: 25px; }
.rider-exercise-shell > header button { width: 44px; height: 44px; border: 1px solid #dbe4e0; border-radius: 14px; color: #29483f; background: #fff; font-size: 28px; line-height: 1; cursor: pointer; }
.rider-exercise-body { padding: 24px; overflow: auto; max-height: calc(100dvh - 120px); }
.rider-exercise-loading { min-height: 260px; display: grid; place-items: center; color: #65736e; }

.rider-exercise-setup { display: grid; gap: 24px; }
.rider-exercise-setup h3 { margin: 0 0 12px; font-size: 17px; }
.rider-exercise-goals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.rider-exercise-goal { position: relative; cursor: pointer; }
.rider-exercise-goal input { position: absolute; opacity: 0; }
.rider-exercise-goal > span { min-height: 92px; display: flex; flex-direction: column; justify-content: center; gap: 4px; padding: 13px 15px; border: 1px solid #dce5e1; border-radius: 16px; background: #fff; transition: border-color .15s, background .15s, transform .15s; }
.rider-exercise-goal small { color: #bb6d56; font-weight: 800; }
.rider-exercise-goal em { color: #68746f; font-size: 12px; font-style: normal; line-height: 1.35; }
.rider-exercise-goal input:checked + span { border-color: #1d5f4d; background: #edf7f1; box-shadow: 0 0 0 2px rgba(29, 95, 77, .1); }
.rider-exercise-goal input:focus-visible + span { outline: 3px solid rgba(29, 95, 77, .22); }
.rider-exercise-durations { display: flex; gap: 9px; flex-wrap: wrap; }
.rider-exercise-durations label { position: relative; cursor: pointer; }
.rider-exercise-durations input { position: absolute; opacity: 0; }
.rider-exercise-durations span { display: block; min-width: 72px; padding: 11px 14px; border: 1px solid #dce5e1; border-radius: 13px; text-align: center; background: #fff; font-weight: 750; }
.rider-exercise-durations input:checked + span { border-color: #1d5f4d; color: #fff; background: #1d5f4d; }
.rider-exercise-level { display: grid; gap: 7px; font-weight: 700; }
.rider-exercise-level select { min-height: 48px; padding: 0 14px; border: 1px solid #d7e1dd; border-radius: 13px; color: #17332b; background: #fff; font: inherit; }
.rider-exercise-confirm { display: grid; grid-template-columns: auto 1fr; gap: 11px; align-items: start; padding: 15px; border-radius: 15px; background: #fff5e9; color: #59483a; cursor: pointer; }
.rider-exercise-confirm input { width: 21px; height: 21px; accent-color: #1d5f4d; }
.rider-exercise-disclaimer { margin: -10px 0 0; color: #6a7571; font-size: 13px; }

.rider-exercise-preview-head,
.rider-exercise-live-top { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.rider-exercise-preview-head h3 { margin: 2px 0 0; font-size: 24px; }
.rider-exercise-preview-head > span { padding: 7px 10px; border-radius: 999px; background: #edf4f0; font-size: 12px; font-weight: 700; }
.rider-exercise-reason { margin-bottom: 20px; padding: 16px 18px; border-left: 4px solid #c9775e; border-radius: 0 14px 14px 0; background: #fff3ee; }
.rider-exercise-reason p { margin: 5px 0 0; color: #635750; }
.rider-exercise-plan-list { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 18px 0; }
.rider-exercise-plan-list article { display: grid; grid-template-columns: 148px 1fr; gap: 18px; align-items: center; padding: 14px; border: 1px solid #e0e8e4; border-radius: 18px; background: #fff; }
.rider-exercise-plan-figure { min-width: 0; display: grid; place-items: center; padding: 8px; border-radius: 16px; color: #1d5f4d; background: #eff7f3; }
.rider-exercise-plan-list p { margin: 5px 0; color: #65716d; font-size: 13px; }
.rider-exercise-plan-list .rider-exercise-preview-how { color: #344e45; }
.rider-exercise-plan-list .rider-exercise-preview-how b,
.rider-exercise-plan-list .rider-exercise-preview-benefit b { color: #1d5f4d; }
.rider-exercise-plan-list small { color: #ba6d56; font-weight: 700; }
.rider-exercise-safety,
.rider-exercise-benefit { padding: 15px 17px; border-radius: 15px; background: #edf6f1; }
.rider-exercise-safety p,
.rider-exercise-benefit p { margin: 5px 0 0; color: #52655e; }
.rider-exercise-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 20px; }
.rider-exercise-actions .button.ghost { color: #52655e; background: transparent; }

.rider-exercise-resume { display: grid; grid-template-columns: 170px 1fr; gap: 22px; align-items: center; }
.rider-exercise-resume > .rider-exercise-figure-wrap { color: #1d5f4d; background: #eaf5ef; border-radius: 26px; }
.rider-exercise-resume h3 { margin: 3px 0 6px; font-size: 24px; }
.rider-exercise-resume p { color: #5c6a65; }
.rider-exercise-resume .rider-exercise-actions { grid-column: 1 / -1; }
.rider-exercise-safety-hold { max-width: 650px; margin: 30px auto; padding: 25px; border: 1px solid #efc8ba; border-radius: 20px; background: #fff3ee; }
.rider-exercise-safety-hold strong { display: block; color: #9c4f3c; font-size: 20px; }
.rider-exercise-safety-hold p { color: #654f48; }
.rider-exercise-safety-hold small { display: block; margin-bottom: 18px; color: #76655e; }

.rider-exercise-live-top { align-items: center; margin-bottom: 12px; color: #65726d; font-weight: 700; }
.rider-exercise-live-top button { border: 0; color: #a54232; background: transparent; font-weight: 800; text-decoration: underline; cursor: pointer; }
.rider-exercise-live-grid { display: grid; grid-template-columns: minmax(230px, .8fr) 1.2fr; gap: 28px; align-items: center; }
.rider-exercise-live-art { display: grid; place-items: center; aspect-ratio: 1; padding: 10px; border-radius: 26px; color: #1d5f4d; background: linear-gradient(145deg, #e9f6ef, #f7fbf9); }
.rider-exercise-live-grid h3 { margin: 3px 0 10px; font-size: clamp(25px, 4vw, 38px); }
.rider-exercise-timer { color: #153b32; font-size: clamp(40px, 8vw, 72px); font-weight: 850; font-variant-numeric: tabular-nums; letter-spacing: -.04em; }
.rider-exercise-progress { height: 8px; overflow: hidden; border-radius: 99px; background: #dce8e2; }
.rider-exercise-progress span { display: block; width: 0; height: 100%; border-radius: inherit; background: #c9775e; transition: width .3s linear; }
.rider-exercise-live ol { display: grid; gap: 10px; padding-left: 24px; margin: 22px 0; }
.rider-exercise-live li { padding-left: 6px; line-height: 1.5; }
.rider-exercise-how { margin-top: 20px; padding: 17px; border: 1px solid #e1e9e5; border-radius: 16px; background: #fff; }
.rider-exercise-how ol { margin-bottom: 0; }
.rider-exercise-caution { margin-top: 10px; padding: 14px 16px; border-radius: 14px; color: #654f48; background: #fff3ee; font-size: 13px; }
.rider-exercise-caution strong { display: block; margin-bottom: 4px; color: #9c4f3c; }
.rider-exercise-caution p { margin: 0; }
.rider-exercise-technique-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.rider-exercise-technique-grid .rider-exercise-caution { margin-top: 0; }
.rider-exercise-option { padding: 14px 16px; border-radius: 14px; color: #3b5b51; background: #edf6f1; font-size: 13px; }
.rider-exercise-option strong { display: block; margin-bottom: 4px; color: #1d5f4d; }
.rider-exercise-option p { margin: 0; line-height: 1.45; }
.rider-exercise-option.harder { background: #edf2f8; }
.rider-exercise-option.harder strong { color: #315b7a; }
.rider-exercise-caution.safety { border: 1px solid #efcbbd; background: #fff7f2; }

.rider-exercise-finished { max-width: 610px; margin: 20px auto; text-align: center; }
.rider-exercise-award { width: 82px; height: 82px; display: grid; place-items: center; margin: 0 auto 14px; border-radius: 50%; color: #fff; background: #1d5f4d; font-size: 42px; box-shadow: 0 12px 30px rgba(29, 95, 77, .2); }
.rider-exercise-finished h3 { margin: 4px 0 8px; font-size: 28px; }
.rider-exercise-finished > p { color: #64706c; }
.rider-exercise-badge { display: flex; flex-direction: column; gap: 4px; margin-top: 18px; padding: 15px; border-radius: 16px; background: #fff3d8; }
.rider-exercise-finished .rider-exercise-actions { justify-content: center; }

.rider-exercise-figure-wrap { width: 100%; max-width: 210px; display: grid; gap: 6px; justify-items: center; margin: 0; }
.rider-exercise-figure-wrap figcaption { max-width: 100%; display: flex; gap: 6px; align-items: flex-start; justify-content: center; color: #405e55; font-size: 11px; font-weight: 750; line-height: 1.3; text-align: center; }
.rider-exercise-figure-wrap figcaption span { flex: 0 0 auto; color: #c9775e; font-size: 14px; line-height: 1; }
.rider-exercise-figure { width: 100%; max-width: 190px; height: auto; overflow: visible; }
.rider-exercise-figure .rx-scene { fill: #f8fbf9; stroke: #dce9e3; stroke-width: 1.5; }
.rider-exercise-figure .rx-ground,
.rider-exercise-figure .rx-floor { fill: none; stroke: #cddbd5; stroke-width: 3; stroke-linecap: round; }
.rider-exercise-figure .rx-head { fill: #f1c5a2; stroke: #194c3e; stroke-width: 3; }
.rider-exercise-figure .rx-torso { fill: none; stroke: #1d5f4d; stroke-width: 12; stroke-linecap: round; stroke-linejoin: round; }
.rider-exercise-figure .rx-limb { fill: none; stroke: #548879; stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; }
.rider-exercise-figure .rx-prop { fill: none; stroke: #8f9b96; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.rider-exercise-figure .rx-motion { fill: none; stroke: #c9775e; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 5 5; }
.rider-exercise-figure .rx-ghost { fill: #f5ddcb; stroke: #9eb9af; stroke-width: 2; opacity: .62; }
.rider-exercise-figure .rx-ghost-line { fill: none; stroke: #9eb9af; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 4 4; opacity: .65; }
.rider-exercise-figure .rx-foot { fill: #548879; stroke: #1d5f4d; stroke-width: 2; }
.rider-exercise-figure .rx-ghost-foot { opacity: .38; }
.rider-exercise-figure .rx-wall { fill: none; stroke: #8f9b96; stroke-width: 5; stroke-linecap: round; }
.rider-exercise-figure .rx-guide { fill: none; stroke: #7aa99a; stroke-width: 2; stroke-dasharray: 3 4; }
.rider-exercise-figure .rx-joint { fill: #fff; stroke: #c9775e; stroke-width: 3; }
.rider-exercise-figure .rx-breath { fill: none; stroke: #62a98e; stroke-width: 3; stroke-linecap: round; animation: rider-exercise-breathe 2.8s ease-in-out infinite; transform-origin: center; }
@keyframes rider-exercise-breathe { 50% { transform: scale(1.12); opacity: .65; } }

@media (max-width: 700px) {
  .rider-exercise-page-hero { grid-template-columns: 1fr; gap: 14px; padding: 18px; }
  .rider-exercise-page-hero-art { order: -1; min-height: 184px; padding: 8px; }
  .rider-exercise-page-hero-art .rider-exercise-figure { max-width: 190px; }
  .rider-exercise-purpose-grid,
  .rider-exercise-benefits-grid { grid-template-columns: 1fr; }
  .rider-exercise-purpose-grid article { min-height: 0; }
  .dashboard-exercise-action { width: 100%; justify-content: center; }
  .rider-exercise-card { grid-template-columns: 76px 1fr; gap: 13px; padding: 16px; }
  .rider-exercise-card-art { width: 76px; height: 76px; border-radius: 19px; }
  .rider-exercise-card > .button { grid-column: 1 / -1; width: 100%; }
  .rider-exercise-dialog { width: 100vw; max-width: none; max-height: 94dvh; margin: auto 0 0; border-radius: 26px 26px 0 0; }
  .rider-exercise-shell > header { padding: 15px 17px; }
  .rider-exercise-body { max-height: calc(94dvh - 75px); padding: 17px; }
  .rider-exercise-goals,
  .rider-exercise-plan-list { grid-template-columns: 1fr; }
  .rider-exercise-plan-list article { grid-template-columns: 112px 1fr; gap: 12px; padding: 10px; }
  .rider-exercise-plan-figure { padding: 5px; }
  .rider-exercise-resume { grid-template-columns: 100px 1fr; gap: 13px; }
  .rider-exercise-live-grid { grid-template-columns: 130px 1fr; gap: 13px; }
  .rider-exercise-live-art { border-radius: 18px; }
  .rider-exercise-technique-grid { grid-template-columns: 1fr; }
  .rider-exercise-figure-wrap figcaption { font-size: 10px; }
  .rider-exercise-actions { display: grid; grid-template-columns: 1fr; }
  .rider-exercise-actions .button { width: 100%; min-height: 47px; }
  .rider-exercise-stats { display: grid; grid-template-columns: repeat(3, 1fr); }
  .rider-exercise-stats span { text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .rider-exercise-figure .rx-breath { animation: none; }
  .rider-exercise-progress span { transition: none; }
}
