/* Gym page: white hovers, a clearer routine volume, the glass exercise picker and a tidier Strength Signal. */

/* ---------- Hover and keyboard focus are white, not the section's colour (which can be red) ---------- */
html body #gymPage#gymPage :is(button.ghost,button.danger,.ly-icon-act,.ly-icon-del):not(.active):is(:hover,:focus-visible){
 background:rgba(255,255,255,.12)!important;border-color:rgba(255,255,255,.75)!important;color:#fff!important;box-shadow:0 0 0 3px rgba(255,255,255,.12),0 8px 20px rgba(0,0,0,.28)!important}
html body #gymPage#gymPage .compact-routine>.routine-summary:hover::before,
html body #gymPage#gymPage .compact-routine[open]>.routine-summary::before{border-color:rgba(255,255,255,.6)!important;box-shadow:0 0 0 3px rgba(255,255,255,.14),inset 0 1px 0 rgba(255,255,255,.1)!important}
html[data-theme="light"] body #gymPage#gymPage :is(button.ghost,button.danger,.ly-icon-act,.ly-icon-del):not(.active):is(:hover,:focus-visible){
 background:rgba(0,0,0,.07)!important;border-color:rgba(0,0,0,.55)!important;color:#14151b!important;box-shadow:0 0 0 3px rgba(0,0,0,.08)!important}

/* ---------- Routine header: the volume is the number you read ---------- */
html body #gymPage .routine-summary .ly-routine-volume{display:inline-block;margin-left:10px;padding:5px 12px;border-radius:999px;background:rgba(255,255,255,.12);border:1px solid rgba(255,255,255,.22);
 color:#fff;-webkit-text-fill-color:#fff;font-size:16px;font-weight:900;line-height:1.35;font-variant-numeric:tabular-nums;white-space:nowrap;vertical-align:middle}
html[data-theme="light"] body #gymPage .routine-summary .ly-routine-volume{background:#14151b;border-color:#14151b;color:#fff;-webkit-text-fill-color:#fff}

/* ---------- Numbers are never cut off at the bottom ---------- */
html body .xi-cell strong,html body #gymPage .strength-signal-kpi strong{line-height:1.4!important;padding-bottom:2px}

/* ---------- Strength Signal: glass exercise bar ---------- */
html body #gymPage .tidy-pick.tidy-pick{min-height:58px;background:linear-gradient(180deg,rgba(255,255,255,.12),rgba(255,255,255,.03))!important;border:1px solid rgba(255,255,255,.24)!important;
 backdrop-filter:blur(18px) saturate(1.5);-webkit-backdrop-filter:blur(18px) saturate(1.5);box-shadow:inset 0 1px 0 rgba(255,255,255,.22),0 8px 24px rgba(0,0,0,.2)!important}
html body #gymPage .tidy-pick.tidy-pick:hover{scale:1.02;border-color:rgba(255,255,255,.65)!important}

/* ---------- Strength Signal: the section keeps the picker; each exercise opens its own pop-up ---------- */
html body #gymPage .ly-strength-disclosure .exercise-trend-controls{margin-top:14px;max-width:520px}
html.ss-lock,html.ss-lock body{overflow:hidden!important}
html body #gymPage dialog.ss-detail{box-sizing:border-box;width:min(640px,calc(100vw - 24px));max-height:calc(100dvh - 40px);overflow:auto;overscroll-behavior:contain;padding:24px;border-radius:28px;color:#fff;
 background:radial-gradient(60% 45% at 10% 0%,color-mix(in srgb,var(--c,#a5b4fc) 30%,transparent),transparent 70%),rgba(10,12,24,.72);
 backdrop-filter:blur(26px) saturate(1.5);-webkit-backdrop-filter:blur(26px) saturate(1.5);border:1px solid rgba(255,255,255,.22);box-shadow:inset 0 1px 0 rgba(255,255,255,.22),0 30px 80px rgba(0,0,0,.5)}
html body #gymPage dialog.ss-detail[open]{animation:lyGlassIn .45s cubic-bezier(.34,1.56,.64,1) both}
html body #gymPage dialog.ss-detail::backdrop{background:rgba(4,6,14,.5);backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}
html body #gymPage .ss-head{display:flex;align-items:center;gap:14px;margin-bottom:20px}
html body #gymPage .ss-head>div{flex:1;min-width:0}
html body #gymPage .ss-head h2{margin:0;font-size:21px;line-height:1.3;overflow-wrap:anywhere}
html body #gymPage .ss-head small{display:block;font-size:13px;font-weight:800;color:var(--c,#a5b4fc)}
html body #gymPage .ss-art{width:60px;height:60px;flex:none;border-radius:50%;background:#fff;object-fit:cover;box-shadow:0 0 0 3px var(--c,#a5b4fc)}
html body #gymPage .ss-head button.ss-round{display:grid;place-items:center;flex:none;width:50px;height:50px;min-height:50px;margin:0;padding:0 0 4px!important;border-radius:16px!important;background:rgba(255,255,255,.1)!important;border:1.5px solid rgba(255,255,255,.28)!important;color:#fff!important;font-size:34px!important;line-height:1;box-shadow:none!important;cursor:pointer;transition:scale .18s}
html body #gymPage .ss-head button.ss-round:is(:hover,:focus-visible){scale:1.08;background:rgba(255,255,255,.2)!important}
html body #gymPage .ss-controls .exercise-trend-controls{display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:10px!important;margin:0!important}
html body #gymPage .ss-controls .exercise-trend-controls label{margin:0!important}
html body #gymPage .ss-label{display:block;margin:20px 0 10px;font-weight:700}
html body #gymPage .ss-controls .exercise-trend-periods{margin:0!important}
html body #gymPage .ss-results{margin-top:20px}
html body #gymPage .ss-results .strength-signal-summary{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:14px!important;margin:0!important}
html body #gymPage .ss-results .strength-signal-kpi{padding:18px!important;border-radius:18px!important}
html body #gymPage .ss-results .strength-signal-kpi strong{font-size:30px!important}
html body #gymPage #exerciseTrendSummary:empty{display:none}
@media(max-width:600px){html body #gymPage dialog.ss-detail{padding:18px 14px}html body #gymPage .ss-head{gap:10px}html body #gymPage .ss-art{width:48px;height:48px}
 html body #gymPage .ss-head button.ss-round{width:44px;height:44px;min-height:44px}html body #gymPage .ss-head h2{font-size:17px}
 html body #gymPage .ss-results .strength-signal-kpi{padding:14px!important}html body #gymPage .ss-results .strength-signal-kpi strong{font-size:24px!important}}

/* ---------- "Choose an exercise": big frosted window whose tiles pop in, each with its muscle ---------- */
html body dialog.tidy-picker.tidy-picker{width:min(880px,calc(100vw - 24px));padding:26px;border-radius:28px;color:#fff;
 background:radial-gradient(38% 30% at 12% 22%,rgba(99,102,241,.32),transparent 70%),radial-gradient(34% 30% at 88% 18%,rgba(236,72,153,.24),transparent 70%),
  radial-gradient(36% 32% at 30% 78%,rgba(20,184,166,.24),transparent 70%),radial-gradient(34% 30% at 82% 80%,rgba(245,158,11,.2),transparent 70%),rgba(10,12,24,.55)!important;
 backdrop-filter:blur(26px) saturate(1.6)!important;-webkit-backdrop-filter:blur(26px) saturate(1.6)!important;
 border:1px solid rgba(255,255,255,.22)!important;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 30px 80px rgba(0,0,0,.45)!important}
html body dialog.tidy-picker.tidy-picker[open]{animation:lyGlassIn .45s cubic-bezier(.34,1.56,.64,1) both}
html body dialog.tidy-picker.tidy-picker::backdrop{background:rgba(4,6,14,.3);backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}
html body dialog.tidy-picker h2{font-size:24px}
html body dialog.tidy-picker .grid{grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:14px;padding:6px}
html body dialog.tidy-picker.tidy-picker .grid button{position:relative;display:grid;grid-template-columns:minmax(0,1fr) 84px;grid-template-areas:"name art" "muscle art";grid-template-rows:auto 1fr;gap:6px 12px;min-height:116px;padding:16px!important;border-radius:22px!important;
 background:radial-gradient(80% 70% at 0% 0%,color-mix(in srgb,var(--c) 16%,transparent),transparent 65%),rgba(255,255,255,.05)!important;
 border:1px solid color-mix(in srgb,var(--c) 60%,transparent)!important;box-shadow:inset 0 1px 0 rgba(255,255,255,.2),0 8px 22px rgba(0,0,0,.2)!important;
 font-size:16px!important;line-height:1.3;opacity:0;transform:scale(.6);animation:lyGlassPop .5s cubic-bezier(.34,1.56,.64,1) forwards;transition:scale .2s cubic-bezier(.34,1.56,.64,1),box-shadow .2s,border-color .2s,background .2s}
html body dialog.tidy-picker .grid button .tidy-name{grid-area:name}
html body dialog.tidy-picker.tidy-picker .grid button small{grid-area:muscle;align-self:start;font-size:13px;color:var(--c)}
html body dialog.tidy-picker .grid button img{grid-area:art;align-self:start;justify-self:end;width:84px;height:84px;border-radius:50%;background:#fff;object-fit:cover;box-shadow:0 0 0 3px color-mix(in srgb,var(--c) 70%,transparent)}
html body dialog.tidy-picker.tidy-picker .grid button[aria-current="true"]{border-color:var(--c)!important;border-width:2px!important;
 background:color-mix(in srgb,var(--c) 22%,rgba(255,255,255,.04))!important}
html body dialog.tidy-picker .grid button:nth-child(2){animation-delay:.04s}html body dialog.tidy-picker .grid button:nth-child(3){animation-delay:.08s}
html body dialog.tidy-picker .grid button:nth-child(4){animation-delay:.12s}html body dialog.tidy-picker .grid button:nth-child(5){animation-delay:.16s}
html body dialog.tidy-picker .grid button:nth-child(6){animation-delay:.2s}html body dialog.tidy-picker .grid button:nth-child(7){animation-delay:.24s}
html body dialog.tidy-picker .grid button:nth-child(8){animation-delay:.28s}html body dialog.tidy-picker .grid button:nth-child(n+9){animation-delay:.32s}
@media(max-width:600px){html body dialog.tidy-picker.tidy-picker{padding:18px 12px}html body dialog.tidy-picker .grid{grid-template-columns:minmax(0,1fr);gap:10px}
 html body dialog.tidy-picker.tidy-picker .grid button{min-height:96px;grid-template-columns:minmax(0,1fr) 68px}html body dialog.tidy-picker .grid button img{width:68px;height:68px}}

/* ---------- "Show hidden routines" is a plain button, never the section's colour ---------- */
html body #gymPage button.ghost.ly-hidden-routines-toggle:not(:hover):not(:focus-visible){background:rgba(255,255,255,.05)!important;border:1px solid rgba(255,255,255,.18)!important;color:#fff!important;box-shadow:none!important}
html[data-theme="light"] body #gymPage button.ghost.ly-hidden-routines-toggle:not(:hover):not(:focus-visible){background:rgba(0,0,0,.04)!important;border-color:rgba(0,0,0,.18)!important;color:#14151b!important}

/* ---------- Workout history: the + lights up in a white box when you point at its row, like the other row buttons ---------- */
html body #historyList summary.ly-session-summary.ly-chev::before{display:block!important;content:""!important;position:absolute!important;left:auto!important;right:-7px!important;top:5px!important;width:40px!important;height:40px!important;margin:0!important;box-sizing:border-box!important;
 border:1px solid transparent!important;border-radius:12px!important;background:transparent!important;box-shadow:none!important;-webkit-mask:none!important;mask:none!important;transform:none!important;pointer-events:none;transition:background .18s,border-color .18s,box-shadow .18s,scale .18s!important}
html body #historyList summary.ly-session-summary.ly-chev:is(.ly-arrow-hot,:focus-visible)::before{border-color:rgba(255,255,255,.75)!important;background:rgba(255,255,255,.12)!important;box-shadow:0 0 0 3px rgba(255,255,255,.12),0 0 18px rgba(255,255,255,.28)!important;scale:1.08}
html[data-theme="light"] body #historyList summary.ly-session-summary.ly-chev:is(.ly-arrow-hot,:focus-visible)::before{border-color:rgba(0,0,0,.5)!important;background:rgba(0,0,0,.06)!important;box-shadow:0 0 0 3px rgba(0,0,0,.08)!important}
html[data-theme="light"] body #historyList summary.ly-session-summary.ly-chev::after{background:#14151b!important}

/* ---------- Strength Signal's arrow lights up exactly like the routine arrows ---------- */
html body #gymPage#gymPage .ly-strength-disclosure>summary:is(:hover,:focus-visible)::before,
html body #gymPage#gymPage .ly-strength-disclosure[open]>summary::before{border-color:rgba(255,255,255,.6)!important;box-shadow:0 0 0 3px rgba(255,255,255,.14),inset 0 1px 0 rgba(255,255,255,.1)!important}

/* ---------- Every Gym box lights up when you point at it, like Strength Signal ---------- */
html body #gymPage#gymPage#gymPage :is(.compact-routine,.ly-strength-disclosure,.category-stat,.history-category,.ov-activity):hover{
 border-color:#93a9ff!important;box-shadow:0 0 0 1px rgba(133,153,255,.73),0 0 25px rgba(117,141,255,.33),0 15px 34px rgba(0,0,0,.27)!important}

/* ---------- Small row buttons: black and white by default, no glow; they just grow a touch on hover ---------- */
html body #gymPage#gymPage#gymPage :is(.routine .actions button:not(:disabled),button.ly-icon-act){
 background:rgba(255,255,255,.08)!important;border:1.5px solid rgba(255,255,255,.7)!important;color:#fff!important;-webkit-text-fill-color:#fff!important;box-shadow:none!important;transition:scale .18s,background .18s}
html body #gymPage#gymPage#gymPage :is(.routine .actions button:not(:disabled),button.ly-icon-act) svg{color:#fff!important;stroke:currentColor!important}
html body #gymPage#gymPage#gymPage :is(.routine .actions button:not(:disabled),button.ly-icon-act):is(:hover,:focus-visible){scale:1.08;background:rgba(255,255,255,.18)!important;border-color:#fff!important;box-shadow:none!important}
/* Pinned = the same button filled in white */
html body #gymPage#gymPage#gymPage .routine .actions button.is-on:not(:disabled){background:#fff!important;border-color:#fff!important;color:#08080b!important;-webkit-text-fill-color:#08080b!important}
html body #gymPage#gymPage#gymPage .routine .actions button.is-on:not(:disabled) svg{color:#08080b!important;stroke:#08080b!important;fill:#08080b!important}
html[data-theme="light"] body #gymPage#gymPage#gymPage :is(.routine .actions button:not(:disabled),button.ly-icon-act){background:#fff!important;border-color:#14151b!important;color:#14151b!important;-webkit-text-fill-color:#14151b!important}
html[data-theme="light"] body #gymPage#gymPage#gymPage :is(.routine .actions button:not(:disabled),button.ly-icon-act) svg{color:#14151b!important}
html[data-theme="light"] body #gymPage#gymPage#gymPage .routine .actions button.is-on:not(:disabled){background:#14151b!important;color:#fff!important;-webkit-text-fill-color:#fff!important}
html[data-theme="light"] body #gymPage#gymPage#gymPage .routine .actions button.is-on:not(:disabled) svg{color:#fff!important;stroke:#fff!important;fill:#fff!important}

/* ---------- Workout history arrow (boxed arrow or +) lights up like the other boxes when you point at its row ---------- */
html body #gymPage#gymPage#gymPage .history-entry summary.ly-session-summary:not(.ly-chev):is(.ly-arrow-hot,:focus-visible)::after,
html body #historyList#historyList#historyList summary.ly-session-summary.ly-chev:is(.ly-arrow-hot,:focus-visible)::before{
 border-color:#93a9ff!important;background-color:rgba(147,169,255,.18)!important;box-shadow:0 0 0 1px rgba(133,153,255,.73),0 0 20px rgba(117,141,255,.5)!important}

/* ---------- Every bin button: black and white by default ---------- */
html body :is(button.ly-icon-del,button.gl-del,button.mini-trash,.routine .actions button.danger,button[aria-label^="Delete"]:has(>svg:only-child),button[title^="Delete"]:has(>svg:only-child)):not(#_):not(#__):not(#___):not(:disabled){
 background:rgba(255,255,255,.08)!important;border:1.5px solid rgba(255,255,255,.7)!important;color:#fff!important;-webkit-text-fill-color:#fff!important;box-shadow:none!important}
html body :is(button.ly-icon-del,button.gl-del,button.mini-trash,.routine .actions button.danger,button[aria-label^="Delete"]:has(>svg:only-child),button[title^="Delete"]:has(>svg:only-child)):not(#_):not(#__):not(#___) svg{color:#fff!important;stroke:#fff!important}
html body :is(button.ly-icon-del,button.gl-del,button.mini-trash,.routine .actions button.danger,button[aria-label^="Delete"]:has(>svg:only-child),button[title^="Delete"]:has(>svg:only-child)):not(#_):not(#__):not(#___):not(:disabled):is(:hover,:focus-visible){
 scale:1.08;background:rgba(255,255,255,.18)!important;border-color:#fff!important;box-shadow:none!important}
html[data-theme="light"] body :is(button.ly-icon-del,button.gl-del,button.mini-trash,.routine .actions button.danger,button[aria-label^="Delete"]:has(>svg:only-child),button[title^="Delete"]:has(>svg:only-child)):not(#_):not(#__):not(#___):not(#____):not(:disabled){background:#fff!important;border-color:#14151b!important;color:#14151b!important;-webkit-text-fill-color:#14151b!important}
html[data-theme="light"] body :is(button.ly-icon-del,button.gl-del,button.mini-trash,.routine .actions button.danger,button[aria-label^="Delete"]:has(>svg:only-child),button[title^="Delete"]:has(>svg:only-child)):not(#_):not(#__):not(#___):not(#____) svg{color:#14151b!important;stroke:#14151b!important}

/* ---------- Workout history: no totals line underneath ---------- */
html body #historyList .history-total{display:none!important}
