/* Train, You and workouts share one quiet, tungsten-accented app shell. */
:root { --workout-inset: 24px; }
.connection:not(.offline) { display: none; }
.topbar { border-bottom-color: transparent; }
.text-button { min-height: 44px; padding: 10px 0; border: 0; background: transparent; color: var(--orange); font-size: 13px; font-weight: 550; }
.back-link { display: inline-flex; align-items: center; min-height: 44px; margin-bottom: 8px; color: var(--muted); font-size: 13px; }
.loading-copy { padding: 32px 0; color: var(--muted); }
#train-content { max-width: 920px; margin: auto; }
.train-greeting { margin-bottom: 22px; }
.train-greeting h1 { font-size: clamp(38px,5vw,58px); line-height: 1.03; }
.train-greeting p { color: var(--muted); font-size: 13px; }
.train-greeting .eyebrow { color: var(--orange); margin-bottom: 10px; }
.train-hero { position: relative; display: grid; grid-template-columns: 1.15fr 1fr; min-height: 340px; border-radius: 24px; overflow: hidden; background: #1a1b1d; border: 1px solid #34332f; isolation: isolate; text-align: left; width: 100%; padding: 0; color: white; }
.hero-copy { display: flex; align-items: flex-start; flex-direction: column; justify-content: center; padding: 28px; min-width: 0; z-index: 1; }
.hero-copy .eyebrow { color: #ecc28b; font-size: 10px; letter-spacing: .12em; }
.hero-copy h2 { font-family: var(--ff-font-heading); font-size: clamp(29px,4vw,47px); text-transform: uppercase; line-height: 1.06; letter-spacing: .01em; margin: 12px 0; overflow-wrap: anywhere; }
.hero-copy > p:not(.eyebrow) { color: #b9b8b6; font-size: 12px; line-height: 1.6; }
.hero-duration { font-family: var(--ff-font-heading); font-size: 76px; line-height: .98; letter-spacing: -.04em; color: var(--orange); }
.hero-duration small, .hero-duration span { font-family: var(--ff-font-body); font-size: 12px; font-weight: 500; letter-spacing: 0; text-transform: uppercase; margin-left: 6px; color: #c4b39a; }
.hero-start { display: inline-flex; align-items: center; justify-content: space-between; gap: 16px; border-radius: 50px; background: var(--orange); color: #211609; min-height: 46px; margin-top: 24px; padding: 11px 16px; font-size: 13px; font-weight: 650; }
.hero-poster { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; background: #0f1011; align-self: stretch; }
.train-section { margin-top: 30px; }
.train-section .section-heading { margin: 0 0 14px; }
.train-section .section-heading > button { min-height: 44px; padding: 8px 0 8px 12px; color: var(--orange); border: 0; background: transparent; font-size: 13px; }
.duration-picker { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 16px 0; }
.duration-option { flex: 1; min-width: 42px; min-height: 46px; display: flex; align-items: baseline; justify-content: center; gap: 3px; border: 1px solid #34363a; border-radius: 12px; background: #151619; color: #c0c2c8; font-size: 14px; font-weight: 550; padding: 11px 7px; font-variant-numeric: tabular-nums; }
.duration-option small { font-size: 9px; font-weight: 450; }
.duration-option[aria-pressed=true], .duration-option.active { background: var(--orange); color: #251a0c; border-color: var(--orange); }
.workout-list { display: grid; gap: 10px; }
.workout-row { display: flex; align-items: center; gap: 16px; width: 100%; min-height: 98px; padding: 17px 18px; text-align: left; border: 1px solid #292b2f; border-radius: 17px; background: #151619; }
.workout-row:hover { background: #1b1d21; border-color: #59482f; }
.workout-length { display: flex; flex-direction: column; justify-content: center; flex-shrink: 0; align-items: center; width: 54px; height: 60px; color: #edc68d; border-right: 1px solid #383126; padding-right: 15px; font-family: var(--ff-font-heading); font-size: 32px; line-height: 1.1; }
.workout-length small { font-family: var(--ff-font-body); font-size: 9px; line-height: 1.5; text-transform: uppercase; letter-spacing: .08em; }
.workout-copy { flex: 1; min-width: 0; }
.workout-copy h3 { font-size: 16px; line-height: 1.25; margin: 0 0 5px; }
.workout-copy p, .workout-copy small { display: block; color: #9d9fa8; font-size: 11px; line-height: 1.5; }
.workout-arrow { color: var(--orange); font-size: 20px; flex-shrink: 0; }
.empty-workouts { color: var(--muted); font-size: 13px; line-height: 1.65; padding: 4px 0 14px; }
.empty-workouts .button { margin-top: 12px; }
.library-shortcut { margin-top: 28px; }
.you-heading { display: flex; align-items: center; justify-content: space-between; margin: 0 0 28px; gap: 20px; }
.you-heading h1 { font-size: clamp(36px,5vw,56px); line-height: 1.08; }
.you-mark { width: 64px; height: 64px; border: 1px solid #5a4529; border-radius: 50%; display: grid; place-items: center; color: var(--orange); }
.you-mark .icon { width: 29px; height: 29px; }
#you-view { max-width: 720px; margin: auto; }
#you-view .week-summary { background: #191816; border-color: #36312a; }
.you-links { border-top: 1px solid #2a2c30; }
.you-links > a, .you-links > button { display: flex; align-items: center; gap: 15px; min-height: 74px; width: 100%; text-align: left; padding: 15px 3px; background: transparent; border: 0; border-bottom: 1px solid #2a2c30; font-size: 15px; }
.you-links .icon { color: #b4a187; width: 21px; }
.you-links > :is(a,button) > span:nth-child(2) { flex: 1; }
.you-links > :is(a,button) > span:last-child { color: #85868e; }
.gym-card { position: relative; display: block; padding: 24px; margin-top: 32px; border: 1px solid #373128; border-radius: 18px; background: #191816; }
.gym-card .eyebrow { font-size: 9px; color: #bea583; }
.gym-card h2 { font-family: var(--ff-font-heading); font-size: 28px; line-height: 1.1; text-transform: uppercase; letter-spacing: .01em; }
.gym-card h2 span { float: right; color: var(--orange); font-family: var(--ff-font-body); font-weight: 400; }
.gym-card > p:last-child { font-size: 12px; color: var(--muted); margin-top: 14px; }
.you-footnote { margin: 24px 0 6px; color: #888a93; font-size: 11px; line-height: 1.8; }
.you-footnote b { font-weight: 400; }
/* Full-screen workout layers keep the footage and controls in separate rows. */
.workout-overview, .workout-builder, .workout-complete { width: min(620px,calc(100% - 40px)); height: min(960px,calc(100dvh - 40px)); max-height: none; overflow: hidden; }
:is(.workout-overview,.workout-builder,.workout-complete)[open] { display: flex; flex-direction: column; }
:is(.workout-overview,.workout-builder,.workout-complete) .dialog-header { background: var(--bg); border-color: #24262a; }
.overview-scroll, .builder-scroll, .complete-scroll { min-height: 0; overflow-y: auto; overscroll-behavior: contain; flex: 1; padding: 28px var(--workout-inset); }
.overview-title { font-family: var(--ff-font-heading); text-transform: uppercase; font-size: 46px; line-height: 1.08; letter-spacing: .01em; margin-bottom: 18px; }
.overview-meta { display: flex; flex-wrap: wrap; gap: 8px 14px; color: #c6b69d; font-size: 12px; margin: 16px 0 24px; }
.overview-scroll > p { color: #aeb0b8; font-size: 13px; line-height: 1.75; margin: 12px 0; }
.overview-scroll > h3 { margin: 26px 0 12px; }
.overview-scroll label { display: block; color: #b6b8c0; font-size: 12px; margin: 20px 0; }
.overview-scroll select { display: block; width: 100%; margin-top: 7px; }
.overview-scroll select, .builder-scroll input, .builder-scroll select, .workout-small-sheet :is(input,select) { min-height: 48px; font-size: 16px; background: #1b1d21; border: 1px solid #383a40; border-radius: 10px; padding: 10px 12px; color: #f4f4f5; min-width: 0; }
.overview-block { margin: 24px 0; }
.overview-block > h3 { margin-bottom: 4px; }
.overview-block > p, .overview-block > small { display: block; color: var(--muted); font-size: 11px; margin-bottom: 12px; line-height: 1.65; }
.overview-drill { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid #292b30; }
.overview-drill img { width: 42px; height: 72px; object-fit: contain; border-radius: 6px; background: #16171a; }
.overview-drill > div { flex: 1; min-width: 0; }
.overview-drill h4, .overview-drill strong { display: block; font-size: 14px; margin: 0 0 4px; line-height: 1.4; }
.overview-drill p, .overview-drill small { display: block; font-size: 11px; color: var(--muted); line-height: 1.5; }
.overview-actions { padding: 14px var(--workout-inset) max(16px,env(safe-area-inset-bottom)); border-top: 1px solid #2a2c30; background: #111214; flex-shrink: 0; }
.overview-actions .button { width: 100%; min-height: 54px; }
.workout-player { position: fixed; inset: 0; width: 100%; height: 100vh; height: 100dvh; max-height: none; max-width: none; margin: 0; border: 0; border-radius: 0; overflow: hidden; background: #0a0b0c; isolation: isolate; }
.workout-player[open] { display: grid; grid-template-rows: auto minmax(0,1fr) auto auto; }
#workout-backdrop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(32px) brightness(.14); pointer-events: none; z-index: -1; }
#workout-backdrop:not([src]) { display: none; }
.workout-top { display: flex; align-items: center; gap: 14px; padding: max(10px,env(safe-area-inset-top)) max(16px,env(safe-area-inset-right)) 8px max(16px,env(safe-area-inset-left)); }
.workout-top > div { flex: 1; min-width: 0; }
#workout-running-name { display: block; font-size: 12px; color: #dedfe2; line-height: 1.4; }
#workout-round { font-size: 10px; color: #9e9fa7; margin-top: 3px; }
#workout-pause { border-radius: 28px; min-height: 44px; padding: 10px 15px; font-size: 12px; }
.workout-footage { position: relative; display: grid; place-items: center; min-height: 0; min-width: 0; overflow: hidden; }
#workout-video { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; }
#workout-video-message { position: absolute; inset: auto 20px 14px; background: #15171be8; border: 1px solid #41434a; border-radius: 12px; padding: 12px; font-size: 12px; color: #dedfe3; text-align: center; }
.workout-timing { display: flex; align-items: center; gap: 18px; width: 100%; max-width: 720px; margin: 0 auto; padding: 16px max(24px,env(safe-area-inset-right)) 10px max(24px,env(safe-area-inset-left)); }
.countdown-ring { position: relative; display: grid; place-items: center; flex-shrink: 0; width: 112px; height: 112px; }
.countdown-ring > svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.countdown-ring circle { fill: none; stroke: #ffffff13; stroke-width: 3; }
#workout-ring-progress { stroke: var(--orange); stroke-linecap: round; stroke-dasharray: 339.292; stroke-dashoffset: 0; }
.countdown-ring > div { text-align: center; z-index: 1; }
#workout-phase { display: block; color: #c5ad8b; font-size: 9px; letter-spacing: .14em; text-transform: uppercase; }
#workout-clock { display: block; font-family: var(--ff-font-heading); font-size: 36px; font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.25; }
#workout-reps-label { display: block; color: #aeb0b8; font-size: 9px; }
.workout-current { min-width: 0; }
#workout-block { color: #b4a188; font-size: 10px; line-height: 1.5; margin-bottom: 5px; }
#workout-current-name { font-family: var(--ff-font-heading); font-size: clamp(21px,3vw,31px); text-transform: uppercase; line-height: 1.13; letter-spacing: .01em; overflow-wrap: anywhere; }
#workout-notes { font-size: 11px; padding: 7px 0; }
.workout-bottom { width: 100%; max-width: 720px; margin: 0 auto; padding: 0 max(20px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(20px,env(safe-area-inset-left)); }
.workout-next { display: flex; align-items: center; gap: 10px; min-height: 47px; margin: 5px 0 12px; }
#workout-next-poster { width: 23px; height: 40px; border-radius: 4px; object-fit: contain; background: #191b1f; }
.workout-next > div { flex: 1; min-width: 0; }
.workout-next small { display: block; color: #858792; font-size: 8px; letter-spacing: .1em; margin-bottom: 2px; }
#workout-next-name { display: block; color: #babcc4; font-size: 10px; line-height: 1.4; }
#workout-progress-label { color: #999ca6; font-size: 10px; flex-shrink: 0; font-variant-numeric: tabular-nums; }
#workout-progress { display: block; width: 100%; height: 3px; border: 0; border-radius: 5px; overflow: hidden; background: #32343b; accent-color: var(--orange); }
#workout-progress::-webkit-progress-bar { background: #32343b; }
#workout-progress::-webkit-progress-value { background: var(--orange); }
#workout-progress::-moz-progress-bar { background: var(--orange); }
.workout-controls { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 9px; }
.workout-controls .button { min-height: 44px; font-size: 12px; padding: 10px 14px; border-color: #ffffff15; background: #ffffff08; }
.music-level-toggle { display: flex; align-items: center; gap: 7px; min-height: 44px; padding: 6px; color: #c1b49d; background: transparent; border: 0; font-size: 10px; }
#workout-visualiser { width: 48px; height: 20px; }
.workout-pause-cover { position: absolute; inset: 0; z-index: 3; display: grid; place-items: center; padding: max(24px,env(safe-area-inset-top)) 28px max(24px,env(safe-area-inset-bottom)); overflow-y: auto; background: #0d0e11e8; backdrop-filter: blur(15px); }
.workout-pause-cover > div { width: min(330px,100%); margin: auto; text-align: center; }
.workout-pause-cover h2 { font-family: var(--ff-font-heading); font-size: 62px; letter-spacing: .01em; line-height: 1.1; }
.workout-pause-cover h2 span { color: var(--orange); }
#workout-pause-reason { color: #b0b2bb; font-size: 13px; line-height: 1.7; margin: 15px 0 26px; }
.workout-pause-cover .button { width: 100%; margin-bottom: 10px; }
.workout-pause-cover .text-button { margin-top: 5px; }
.workout-small-sheet { position: fixed; inset: auto 0 0; margin: auto auto 0; width: min(620px,100%); max-width: none; max-height: 86dvh; border-radius: 24px 24px 0 0; border-bottom: 0; background: #15171b; padding-bottom: max(18px,env(safe-area-inset-bottom)); }
.workout-small-sheet .dialog-header { position: sticky; top: 0; background: #15171b; padding-top: 10px; min-height: 68px; }
.workout-small-sheet .dialog-header h2 { flex: 1; }
#workout-sheet-content { padding: 20px 24px; font-size: 14px; color: #c4c6ce; line-height: 1.8; }
#workout-sheet-content label { display: block; margin-bottom: 18px; }
#workout-sheet-content select { display: block; width: 100%; margin-top: 8px; }
#workout-sheet-content input[type=range] { width: 100%; min-height: 44px; padding: 0; accent-color: var(--orange); }
/* Builder rows offer buttons as well as any pointer gestures. */
.builder-name-label { display: block; font-size: 11px; color: var(--muted); letter-spacing: .03em; }
#builder-name { display: block; width: 100%; margin-top: 8px; font-size: 20px; min-height: 56px; font-weight: 550; }
#builder-duration { color: #cab18c; font-size: 12px; line-height: 1.6; margin: 0 0 26px; }
.builder-block { padding: 18px; background: #14161a; border: 1px solid #303238; border-radius: 18px; margin-bottom: 18px; }
.builder-block > header { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.builder-block > header input { flex: 1; width: 100%; }
.builder-block label { display: block; font-size: 10px; color: #a5a8b1; }
.builder-block label :is(input,select) { display: block; width: 100%; margin-top: 6px; }
.builder-block .form-row { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.builder-block .builder-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px 10px; margin: 12px 0 18px; }
.builder-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid #2d3036; }
.builder-row > img { width: 29px; height: 50px; object-fit: contain; border-radius: 4px; }
.builder-row > span, .builder-row > div:first-of-type { flex: 1; min-width: 0; font-size: 12px; line-height: 1.5; }
.builder-row-controls { display: flex; gap: 3px; margin-left: auto; }
.builder-row-controls button { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid #33363e; border-radius: 10px; background: #1d2025; padding: 5px; font-size: 13px; }
.builder-add { width: 100%; min-height: 46px; margin-top: 12px; border: 1px dashed #524431; border-radius: 10px; background: transparent; color: #dfbd8b; font-size: 12px; }
.builder-summary { color: var(--muted); font-size: 11px; line-height: 1.6; margin-top: 12px; }
#builder-add-block { width: 100%; border-color: #4c402f; background: #211e19; color: #e7c18b; }
#builder-status, #backup-status { color: #f0c58c; font-size: 12px; line-height: 1.6; margin-top: 14px; }
#builder-search { display: block; width: calc(100% - 40px); margin: 14px 20px; }
#builder-drills { padding: 0 20px; }
.picker-drill { display: flex; width: 100%; align-items: center; text-align: left; gap: 13px; min-height: 76px; border: 0; border-bottom: 1px solid #303239; padding: 8px 0; background: transparent; font-size: 13px; }
.picker-drill img { width: 32px; height: 57px; object-fit: contain; border-radius: 5px; }
.picker-drill span { flex: 1; }
/* The result screen echoes the ring and oversized type of Train. */
.complete-scroll { padding-top: 40px; padding-bottom: max(30px,env(safe-area-inset-bottom)); }
#complete-title { font-family: var(--ff-font-heading); font-size: clamp(48px,10vw,76px); line-height: 1.02; letter-spacing: .01em; }
.complete-stats { display: flex; align-items: center; gap: 32px; margin: 32px 0 22px; padding: 24px 0; border-top: 1px solid #3e3324; border-bottom: 1px solid #3e3324; }
.complete-stats > div { display: flex; flex-direction: column; }
.complete-stats b { font-family: var(--ff-font-heading); font-size: 46px; line-height: 1.1; color: var(--orange); font-weight: 500; font-variant-numeric: tabular-nums; }
.complete-stats span { font-size: 11px; color: #ac9f8c; margin-top: 7px; }
#complete-name { font-size: 20px; font-weight: 550; }
#complete-status { font-size: 12px; line-height: 1.7; color: #aaadb7; margin: 10px 0 26px; }
.complete-scroll > .button { display: flex; width: 100%; margin-top: 10px; }
#share-card-preview { display: block; width: min(220px,65%); height: auto; margin: 24px auto; border: 1px solid #51402a; border-radius: 15px; }
.import-label { margin-top: 8px; cursor: pointer; }
#notes-sheet .detail-actions { flex-wrap: wrap; gap: 8px; }
#notes-sheet .detail-actions #save-drill { flex: 1; min-width: 74px; }
#notes-sheet .detail-actions #add-to-workout { flex: 2; width: auto; padding-inline: 10px; }
#notes-sheet .detail-actions #show-log { flex: 0 0 100%; }
.detail-screen[data-mode=log] #add-to-workout { display: none; }
/* One cold-start signature. The page becomes available within 750 ms. */
#launch-reveal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: #0b0c0e; pointer-events: auto; overflow: hidden; animation: launch-away 250ms ease-out 1300ms both; }
.launch-mark { position: relative; width: 170px; height: 110px; display: grid; place-items: center; }
.launch-mark > svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-8deg); }
.launch-mark ellipse { stroke: var(--orange); fill: none; stroke-width: 2; stroke-dasharray: 680; stroke-dashoffset: 680; animation: ring-draw 950ms cubic-bezier(.25,.5,.5,1) both; }
.launch-mark > img { width: 128px; height: 76px; object-fit: contain; animation: mark-arrive 650ms ease-out 120ms both; }
.launch-sweep { position: absolute; top: -30%; height: 160%; width: 18%; background: linear-gradient(90deg,transparent,#f5ad4218,transparent); transform: skewX(-20deg) translateX(-600%); animation: tungsten-pass 1250ms ease-in-out both; pointer-events: none; }
@keyframes ring-draw { to { stroke-dashoffset: 0; } }
@keyframes mark-arrive { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
@keyframes tungsten-pass { to { transform: skewX(-20deg) translateX(600%); } }
@keyframes launch-away { to { opacity: 0; visibility: hidden; } }
@media (min-width: 901px) {
  body[data-view=home] main { padding-top: 35px; }
  .train-section .workout-list { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .train-hero { grid-template-columns: 1.3fr 1fr; max-height: 430px; }
  .hero-copy { padding: 38px; }
  .hero-duration { font-size: 95px; }
  .hero-poster { max-height: 430px; }
  .workout-timing { padding-top: 16px; }
}
@media (max-width: 900px) {
  :root { --workout-inset: 22px; }
  .sidebar nav { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .sidebar { border-color: #26282c; }
  .sidebar nav a { min-height: 53px; }
  .train-greeting { margin: 0 0 22px; }
  .train-greeting h1 { font-size: 40px; }
  .train-hero { min-height: 300px; border-radius: 20px; grid-template-columns: 1.1fr 1fr; }
  .hero-copy { padding: 20px 16px 22px 20px; }
  .hero-copy h2 { font-size: 29px; }
  .hero-duration { font-size: 66px; }
  .hero-copy .eyebrow { font-size: 8px; }
  .hero-start { padding: 11px 13px; font-size: 11px; margin-top: 20px; gap: 9px; }
  .duration-picker { gap: 6px; }
  .duration-option { min-width: 0; }
  .workout-row { padding: 15px; gap: 13px; }
  .train-section { margin-top: 27px; }
  .workout-overview, .workout-builder, .workout-complete { position: fixed; inset: 0; margin: 0; width: 100%; max-width: none; height: 100vh; height: 100dvh; border: 0; border-radius: 0; }
  .overview-title { font-size: 40px; }
  .workout-small-sheet .dialog-header { padding-top: 10px; min-height: 68px; }
  #workout-player .workout-small-sheet { max-height: 85dvh; }
}
@media (max-width: 359px) {
  :root { --workout-inset: 18px; }
  .train-greeting h1 { font-size: 35px; }
  .train-hero { min-height: 277px; }
  .hero-copy { padding: 17px 12px 18px 16px; }
  .hero-copy h2 { font-size: 25px; }
  .hero-duration { font-size: 56px; }
  .hero-start { padding-inline: 10px; font-size: 10px; }
  .duration-picker { gap: 4px; }
  .duration-option { padding-inline: 4px; font-size: 12px; }
  .duration-option small { font-size: 8px; }
  .you-mark { width: 50px; height: 50px; }
  .workout-timing { padding: 10px 16px 4px; gap: 13px; }
  .countdown-ring { width: 92px; height: 92px; }
  #workout-clock { font-size: 30px; }
  #workout-current-name { font-size: 20px; }
  .workout-top { padding-left: 10px; padding-right: 10px; gap: 8px; }
  .workout-top .icon-button { width: 44px; height: 44px; }
  .workout-bottom { padding-left: 16px; padding-right: 16px; }
  .workout-next { margin-bottom: 8px; }
  .workout-controls { margin-top: 5px; }
  .builder-block { padding: 13px; }
  .builder-row-controls { gap: 2px; }
  .complete-scroll { padding-top: 28px; }
}
@media (max-height: 680px) and (orientation: portrait) {
  .workout-timing { padding-top: 9px; padding-bottom: 3px; }
  .countdown-ring { width: 90px; height: 90px; }
  #workout-clock { font-size: 29px; }
  .workout-next { min-height: 34px; margin-bottom: 7px; }
  #workout-next-poster { width: 19px; height: 33px; }
}
@media (max-height: 500px) and (orientation: landscape) {
  .workout-player[open] { grid-template-columns: minmax(0,1fr) minmax(285px,43%); grid-template-rows: auto minmax(0,1fr) auto; }
  .workout-top { grid-column: 1/-1; }
  .workout-footage { grid-column: 1; grid-row: 2 / 4; padding-bottom: max(10px,env(safe-area-inset-bottom)); }
  .workout-timing { grid-column: 2; grid-row: 2; padding: 5px 20px 0 12px; gap: 13px; }
  .countdown-ring { width: 92px; height: 92px; }
  #workout-clock { font-size: 30px; }
  #workout-current-name { font-size: 21px; }
  .workout-bottom { grid-column: 2; grid-row: 3; padding-left: 12px; }
  .workout-next { margin-top: 0; margin-bottom: 6px; min-height: 33px; }
  #workout-next-poster { height: 33px; width: 19px; }
  .workout-controls { margin-top: 5px; }
  .workout-pause-cover { padding: 18px; }
  .workout-pause-cover h2 { font-size: 38px; }
  #workout-pause-reason { margin: 8px 0 12px; }
  .workout-pause-cover .button { min-height: 44px; margin-bottom: 7px; }
  .workout-small-sheet { max-height: 95dvh; }
}
@media (prefers-reduced-motion: no-preference) {
  .workout-row, .duration-option { transition: background 140ms ease, border-color 140ms ease; }
  :is(.workout-overview,.workout-builder,.workout-complete)[open] { animation: screen-in 180ms ease-out; }
  .workout-small-sheet[open] { animation: sheet-in 180ms ease-out; }
}
@media (prefers-reduced-motion: reduce) {
  #launch-reveal { display: none !important; }
  .launch-mark > svg, .launch-mark ellipse, .launch-mark > img, .launch-sweep { animation: none; }
}
/* Contracts shared with the DOM renderers. */
.hero-copy { grid-column: 1; grid-row: 1; }
.hero-poster { grid-column: 2; grid-row: 1; }
.workout-copy strong { display: block; font-size: 15px; line-height: 1.3; margin-bottom: 5px; font-weight: 600; }
.train-greeting.eyebrow { font-size: 10px; letter-spacing: .12em; color: #c6aa84; }
.train-section .section-heading > span { color: #91949e; font-size: 10px; max-width: 135px; text-align: right; line-height: 1.5; }
button.empty-workouts { width: 100%; text-align: left; min-height: 66px; border: 1px dashed #37322c; border-radius: 13px; background: #151515; padding: 17px; color: #b6afa4; }
.browse-drills { display: flex; align-items: center; min-height: 64px; margin: 20px 0 4px; border-top: 1px solid #2c2e34; font-size: 12px; color: #dcc098; }
.overview-preferences { border-top: 1px solid #303239; padding-top: 6px; margin-top: 28px; }
.overview-preferences .preview-preference { display: flex; margin: 13px 0; }
.overview-preferences .preview-preference input { min-height: 0; }
.overview-preferences > p { font-size: 12px; line-height: 1.7; color: var(--muted); }
.builder-preparation { display: flex; align-items: center; gap: 20px; color: #a5a8b1; font-size: 11px; margin: 18px 0; }
.builder-preparation input { width: 85px; margin-left: auto; }
.builder-block-heading { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.builder-block-name { flex: 1 0 100%; }
.builder-block-defaults { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px 10px; margin-bottom: 20px; }
.builder-row > h3 { flex: 1 0 100%; font-size: 13px; margin-top: 4px; line-height: 1.5; }
.builder-row-controls .text-button { width: auto; padding-inline: 10px; color: #bd9c79; font-size: 10px; }
.builder-row-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px 10px; flex: 1 0 100%; width: 100%; }
.builder-rest-note { color: #90949e; font-size: 10px; line-height: 1.6; align-self: center; }
.picker-drill strong { display: block; font-size: 12px; font-weight: 550; line-height: 1.5; }
.picker-drill small { display: block; color: #90949e; font-size: 10px; margin-top: 4px; }
.picker-drill .picker-plus { flex: 0; font-size: 22px; color: var(--orange); }
.builder-timing-details { flex: 1 0 100%; width: 100%; }
.builder-timing-details > summary { display: flex; align-items: center; justify-content: space-between; min-height: 46px; color: #c9b598; font-size: 11px; list-style: none; cursor: pointer; }
.builder-timing-details > summary::-webkit-details-marker { display: none; }
.builder-timing-details > summary::after { content: '+'; font-size: 19px; color: #a89a85; padding-left: 12px; }
.builder-timing-details[open] > summary::after { content: '−'; }
.builder-timing-details .builder-block-defaults, .builder-timing-details .builder-row-fields { padding-top: 9px; }
.complete-scroll { display: flex; flex-direction: column; }
.complete-scroll > * { flex-shrink: 0; }
#share-card-preview { order: 2; }
@media (max-width: 359px) {
  .builder-row-controls .text-button { padding-inline: 7px; }
  .builder-preparation { font-size: 10px; gap: 14px; }
  #builder-targets .duration-option { font-size: 11px; padding: 11px 3px; white-space: nowrap; }
}
:is(.overview-scroll,.builder-scroll,.workout-small-sheet) select { -webkit-appearance: none; appearance: none; height: 48px; padding-right: 30px; background-image: linear-gradient(45deg,transparent 50%,#ada99f 50%),linear-gradient(135deg,#ada99f 50%,transparent 50%); background-position: calc(100% - 17px) 21px,calc(100% - 12px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.builder-scroll input[type=number] { appearance: textfield; -moz-appearance: textfield; }
.builder-scroll input[type=number]::-webkit-inner-spin-button, .builder-scroll input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }

.app-update { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:12px 16px; margin-bottom:18px; border:1px solid #695031; border-radius:14px; background:#211c15; font-size:13px; }
.app-update .button { flex-shrink:0; font-size:12px; }
#app-version { font-variant-numeric:tabular-nums; }

.unfinished-workout { margin:24px 0; padding:16px; border:1px solid #695031; border-radius:14px; background:#211c15; font-size:13px; line-height:1.6; }
.unfinished-workout p { color:var(--muted); margin:8px 0 0; }
.workout-length { min-width:62px; width:auto; }

.builder-target-label { margin: 22px 0 0; color: #b8bbc4; font-size: 12px; }
.builder-target-label + .duration-picker { margin-top: 10px; }
.builder-draft-notice { margin: 12px 0; padding: 12px 14px; border-left: 2px solid #ab8754; border-radius: 0 8px 8px 0; background: #211e19; color: #d1b58e; font-size: 12px; line-height: 1.6; }
#notes-drill-name { margin: 12px 0 14px; color: #c8cbd2; font-size: 16px; font-weight: 550; line-height: 1.45; }
#workout-current-name .drill-name-detail { display: block; margin-top: 6px; color: #b6b9c2; font-family: var(--ff-font-body); font-size: 12px; font-weight: 400; line-height: 1.4; text-transform: none; letter-spacing: 0; }
.hero-duration { display: flex; flex-wrap: wrap; align-items: baseline; gap: 5px 6px; max-width: 100%; }
.hero-duration :is(small,span) { margin-left: 0; }
