.xsh {
  --c-bg: #0A0A0B; --c-card: #141417; --c-raised: #1B1B1E;
  --c-line: #27272A; --c-line-2: #3F3F46;
  --c-text: #FAFAFA; --c-muted: #A1A1AA;
  --c-blue: #50A2FF; --c-blue-rgb: 80, 162, 255;
  --xsh-p: 1;                  --xsh-lab: 8.75rem;          --xsh-rail-h: 3.25rem;       --xsh-rail-y: 1.5rem;        --ra: 1.5rem; --band: 2.25rem; --rb: 1.5rem;   position: relative; margin: 0; min-width: 0; overflow: clip;
  padding: clamp(1rem, 2.6vw, 1.75rem);
  background: var(--c-card); border: 1px solid var(--c-line); border-radius: var(--radius-xl, 24px);
  color: var(--c-text); font-family: 'IBM Plex Sans', var(--font-heading, system-ui), sans-serif;
}
.xsh p { margin: 0; }
.xsh-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.xsh-s { display: none; }
.x-home #between-rounds .rh-points { margin-top: clamp(3rem, 6vw, 4.5rem); }

.xsh__top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.375rem 1.5rem; margin-bottom: 1.25rem; }
.xsh__title { font-size: 1.125rem; font-weight: 600; line-height: 1.3; }
.xsh__now { display: flex; align-items: baseline; gap: 0.5rem; font-family: var(--font-mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.xsh__now-k { font-size: 0.8125rem; color: var(--c-muted); }
.xsh__now b { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 500; line-height: 1; color: var(--c-text); }
.xsh__now-d { display: inline-block; min-width: 8ch; font-size: 0.8125rem; color: var(--c-muted); }

.xsh__body { display: grid; grid-template-columns: 10rem minmax(0, 1fr); gap: 1.25rem; align-items: stretch; }

.xsh-sheet { display: flex; flex-direction: column; min-width: 0; padding: 0.875rem 1rem 1rem; background: var(--c-bg); border: 1px solid var(--c-line); border-radius: 16px; }
.xsh-sheet__k { padding-bottom: 0.625rem; border-bottom: 1px solid var(--c-line-2); font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-muted); }
.xsh-sheet__rows { list-style: none; margin: 0; padding: 0; }
.xsh-sheet__row { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; padding: 0.625rem 0; border-bottom: 1px solid var(--c-line); font-family: var(--font-mono); font-size: 0.9375rem; font-variant-numeric: tabular-nums; }
.xsh-sheet__t { color: var(--c-muted); }
.xsh-sheet__v { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 500; color: var(--c-text); }
.xsh-sheet__v::after { content: ""; width: 9px; height: 5px; margin-top: -3px; border-left: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); }
.xsh.is-js .xsh-sheet__row:not(.is-done) .xsh-sheet__v { color: var(--c-line-2); }
.xsh.is-js .xsh-sheet__row:not(.is-done) .xsh-sheet__v::after { display: none; }
.xsh-sheet__blank { flex: 1 1 auto; min-height: 5rem; background: repeating-linear-gradient(to bottom, transparent 0 calc(2.5rem - 1px), var(--c-line) calc(2.5rem - 1px) 2.5rem); opacity: 0.65; }

.xsh__chart { position: relative; min-width: 0; touch-action: pan-y; -webkit-user-select: none; user-select: none; }
@media (hover: hover) and (pointer: fine) { .xsh.is-js .xsh__lanes, .xsh.is-js .xsh-rail__track { cursor: col-resize; } }

.xsh__over { position: absolute; z-index: 0; top: 0; bottom: 0; left: var(--xsh-lab); right: 0; pointer-events: none; }
.xsh-roundline { position: absolute; top: var(--xsh-rail-y); bottom: 0; width: 0; border-left: 1px dashed rgba(250, 250, 250, 0.26); }
.xsh-head { position: absolute; top: var(--xsh-rail-y); bottom: 0; left: calc(var(--xsh-p) * 100%); width: 1px; margin-left: -0.5px; background: rgba(var(--c-blue-rgb), 0.55); }
.xsh:not(.is-js) .xsh-head, .xsh.is-end .xsh-head { display: none; }

.xsh-rail { position: relative; z-index: 1; display: grid; grid-template-columns: var(--xsh-lab) minmax(0, 1fr); }
.xsh-rail__track { position: relative; height: var(--xsh-rail-h); border-radius: 6px; outline: none; }
.xsh-rail__track:focus-visible { box-shadow: 0 0 0 2px var(--c-card), 0 0 0 4px var(--c-blue); }
.xsh-rail__line, .xsh-rail__fill { position: absolute; left: 0; top: calc(var(--xsh-rail-y) - 1.5px); height: 3px; border-radius: 2px; }
.xsh-rail__line { right: 0; background: var(--c-line); }
.xsh-rail__fill { right: calc((1 - var(--xsh-p)) * 100%); background: var(--c-line-2); }
.xsh-rail__knob { position: absolute; z-index: 2; top: var(--xsh-rail-y); left: calc(var(--xsh-p) * 100%); width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: var(--c-blue); box-shadow: 0 0 0 4px rgba(var(--c-blue-rgb), 0.22); }
.xsh-rail__track:focus-visible .xsh-rail__knob { box-shadow: 0 0 0 2px var(--c-card), 0 0 0 4px var(--c-blue); }
.xsh:not(.is-js) .xsh-rail__knob { display: none; }
.xsh-tick { position: absolute; top: var(--xsh-rail-y); width: 0; }
.xsh-tick::before { content: ""; position: absolute; left: -0.5px; top: 4px; width: 1px; height: 5px; background: var(--c-line-2); }
.xsh-tick b { position: absolute; top: 11px; left: 0; transform: translateX(-50%); padding: 1px 3px; background: var(--c-card); font: 400 0.6875rem/1 var(--font-mono); color: var(--c-muted); white-space: nowrap; }   .xsh-tick--first b { left: -3px; transform: none; }
.xsh-tick--last b { left: 3px; transform: translateX(-100%); }
.xsh-round { position: absolute; top: 0; width: 0; height: var(--xsh-rail-y); }
.xsh-round::after { content: ""; position: absolute; left: -1px; top: calc(var(--xsh-rail-y) - 6px); width: 2px; height: 12px; border-radius: 1px; background: var(--c-text); }
.xsh-round b { position: absolute; top: 0; left: 0; transform: translateX(-50%); font: 500 0.6875rem/1 var(--font-mono); letter-spacing: 0.02em; color: var(--c-text); white-space: nowrap; }

.xsh__lanes { position: relative; z-index: 1; }
.xsh-lane { display: grid; grid-template-columns: var(--xsh-lab) minmax(0, 1fr); align-items: center; border-top: 1px solid var(--c-line); }
.xsh-lane[data-pillar="alerts"] { --ra: 1.875rem; --rb: 1.875rem; }
.xsh-lane__k { display: flex; align-items: center; gap: 0.5rem; min-width: 0; padding-right: 0.75rem; font-size: 0.875rem; font-weight: 500; line-height: 1.25; color: var(--c-text); }
.xsh-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--pillar-accent, #50A2FF); box-shadow: 0 0 0 3px rgba(var(--pillar-accent-rgb, 80, 162, 255), 0.18); }
.xsh-lane__plot { position: relative; min-width: 0; height: calc(var(--ra) + var(--band) + var(--rb)); }
.xsh-lane__trace { position: absolute; left: 0; right: 0; top: var(--ra); height: var(--band); clip-path: inset(-6px calc((1 - var(--xsh-p)) * 100%) -6px 0); }
.xsh-lane__svg { display: block; width: 100%; height: 100%; }
.xsh-trace { fill: rgba(var(--pillar-accent-rgb, 80, 162, 255), 0.08); stroke: var(--pillar-accent, #50A2FF); stroke-width: 1.5; stroke-linejoin: round; }
.xsh-floor, .xsh-floor__span { position: absolute; top: 50%; }
.xsh-floor { left: 0; right: 0; height: 4px; margin-top: -2px; opacity: 0.75; background: radial-gradient(circle, rgba(var(--pillar-accent-rgb, 207, 139, 232), 0.9) 0 1.1px, transparent 1.6px) 0 50% / 6px 4px repeat-x; }
.xsh-floor__span { height: 6px; margin-top: -3px; background: radial-gradient(circle, var(--sev-c) 0 1.7px, transparent 2.2px) 0 50% / 6px 6px repeat-x; }
.xsh-floor__span[data-sev="warn"] { --sev-c: var(--sev-warn, #F59E0B); }
.xsh-floor__span[data-sev="crit"] { --sev-c: var(--sev-crit, #F87171); }

.xsh [data-sev="adv"]  { --sev-c: var(--sev-adv, #FCD34D);  --sev-rgb: var(--sev-adv-rgb, 252, 211, 77); }
.xsh [data-sev="warn"] { --sev-c: var(--sev-warn, #F59E0B); --sev-rgb: var(--sev-warn-rgb, 245, 158, 11); }
.xsh [data-sev="crit"] { --sev-c: var(--sev-crit, #F87171); --sev-rgb: var(--sev-crit-rgb, 248, 113, 113); }
.xsh-flag { position: absolute; z-index: 2; top: 0; bottom: 0; width: 0; transition: opacity var(--dur-base, 240ms) var(--ease-out, ease), visibility 0s; }
.xsh.is-js .xsh-flag:not(.is-on) { opacity: 0; visibility: hidden; }
.xsh-flag__mk { position: absolute; z-index: 1; left: -5px; top: calc(var(--ra) + var(--band) * var(--y) - 5px); width: 10px; height: 10px; border-radius: 50%; background: var(--sev-c); box-shadow: 0 0 0 2px var(--c-card), 0 0 0 5px rgba(var(--sev-rgb), 0.22); }
.xsh-flag--led .xsh-flag__mk { left: -4px; top: calc(var(--ra) + var(--band) * 0.5 - 4px); width: 8px; height: 8px; border-radius: 2px; }
.xsh-flag__stem { position: absolute; left: -0.5px; width: 1px; background: rgba(var(--sev-rgb), 0.6); }
.xsh-flag[data-pos="up"] .xsh-flag__stem { top: calc(var(--ra) - 4px); height: calc(var(--band) * var(--y) + 4px); }
.xsh-flag[data-pos="down"] .xsh-flag__stem { top: calc(var(--ra) + var(--band) * var(--y)); bottom: calc(var(--rb) - 4px); }
.xsh-flag__lab {
  position: absolute; display: flex; align-items: center; gap: 0.45rem; height: calc(var(--ra) - 4px);
  padding: 0 0.5rem; border: 1px solid rgba(var(--sev-rgb), 0.5); border-radius: 6px; background: var(--c-card);
  font-size: 0.8125rem; line-height: 1; white-space: nowrap; color: var(--c-text);
  transform: translateX(var(--dx, 0px));
}
.xsh-flag[data-pos="up"] .xsh-flag__lab { top: 0; }
.xsh-flag[data-pos="down"] .xsh-flag__lab { bottom: 0; }
.xsh-flag[data-al="r"] .xsh-flag__lab { left: -12px; }
.xsh-flag[data-al="l"] .xsh-flag__lab { right: -12px; }
.xsh-flag__lab b { font: 500 0.75rem/1 var(--font-mono); font-variant-numeric: tabular-nums; color: var(--c-text); }
.xsh-flag--led .xsh-flag__lab { height: auto; padding: 0; border: 0; border-radius: 6px; background: none; }
.xsh .led--mini { --led-hole: 0.45; }
.xsh-sev { display: inline-flex; align-items: center; gap: 0.3rem; font: 500 0.6875rem/1 var(--font-mono); letter-spacing: 0.02em; color: var(--sev-c); white-space: nowrap; }
.xsh-sev::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--sev-c); }
.xsh-flag.is-pop .xsh-flag__mk { animation: xsh-pop 900ms var(--ease-out, ease-out) 1; }
@keyframes xsh-pop { 0% { box-shadow: 0 0 0 2px var(--c-card), 0 0 0 0 rgba(var(--sev-rgb), 0.55); } 100% { box-shadow: 0 0 0 2px var(--c-card), 0 0 0 12px rgba(var(--sev-rgb), 0); } }

.xsh-log { display: none; margin: 1rem 0 0; padding: 0.75rem 0 0; border-top: 1px solid var(--c-line); }
.xsh-log__k { font-family: var(--font-mono); font-size: 0.6875rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-muted); }
.xsh-log__list { display: grid; gap: 0.375rem; list-style: none; margin: 0.5rem 0 0; padding: 0; }
.xsh-log__i { display: grid; grid-template-columns: 2.625rem 2.75rem minmax(0, 1fr); column-gap: 0.375rem; align-items: baseline; font-size: 0.8125rem; line-height: 1.4; color: var(--c-text); transition: opacity var(--dur-base, 240ms) var(--ease-out, ease), visibility 0s; }
.xsh-log__i b { font: 500 0.75rem var(--font-mono); font-variant-numeric: tabular-nums; }
.xsh-log__a { font-family: var(--font-mono); font-size: 0.6875rem; color: var(--c-muted); }
.xsh-log__w { min-width: 0; }
.xsh-log__i .xsh-sev { grid-column: 3; justify-self: start; margin-top: 0.125rem; }
.xsh.is-js .xsh-log__i:not(.is-on) { opacity: 0; visibility: hidden; }

.xsh__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem; min-height: 44px; margin-top: 1.25rem; }
.xsh__play {
  appearance: none; flex: none; display: inline-flex; align-items: center; gap: 0.625rem; min-height: 44px; padding: 0 1rem 0 0.875rem; cursor: pointer;
  color: var(--c-text); background: transparent; border: 1px solid var(--c-line-2); border-radius: 999px; font: 500 0.875rem var(--font-body, system-ui);
  transition: border-color var(--dur-fast, 160ms) var(--ease-out, ease), background-color var(--dur-fast, 160ms) var(--ease-out, ease);
}
.xsh__play:hover { border-color: var(--c-blue); background: rgba(var(--c-blue-rgb), 0.08); }
.xsh__play:focus-visible { outline: 2px solid var(--c-blue); outline-offset: 3px; }
.xsh__play[hidden] { display: none; }
.xsh__play-i { flex: none; width: 0; height: 0; border-left: 9px solid var(--c-blue); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.xsh.is-playing .xsh__play-i { width: 9px; height: 11px; border: 0; border-left: 3px solid var(--c-blue); border-right: 3px solid var(--c-blue); }
.xsh.is-reduced .xsh__play-i { display: inline-flex; align-items: center; width: auto; height: 12px; border: 0; }
.xsh.is-reduced .xsh__play-i::before { content: ""; border-left: 7px solid var(--c-blue); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.xsh.is-reduced .xsh__play-i::after { content: ""; width: 2px; height: 12px; margin-left: 1px; background: var(--c-blue); }
.xsh__beat { flex: 1 1 18rem; min-width: 0; min-height: 1.45em; font-size: 0.9375rem; line-height: 1.45; color: var(--c-text); }
.xsh__hint { flex: none; font-size: 0.8125rem; color: var(--c-muted); }
.xsh:not(.is-js) .xsh__hint { display: none; }
.xsh__hint-t { display: none; }
@media (hover: none) { .xsh__hint-f { display: none; } .xsh__hint-t { display: inline; } }
.xsh__cap { margin: 0; }

@media (max-width: 61.99em) {
  .xsh__body { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .xsh-sheet { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 0.25rem 1.25rem; padding: 0.625rem 0.875rem; border-radius: 12px; }
  .xsh-sheet__k { padding: 0; border: 0; }
  .xsh-sheet__rows { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
  .xsh-sheet__row { gap: 0.625rem; padding: 0; border: 0; font-size: 0.875rem; }
  .xsh-sheet__blank { display: none; }
  .xsh__hint { flex-basis: 100%; }
}
@media (max-width: 47.99em) {
  .xsh-tick--odd { display: none; }   }
@media (max-width: 39.99em) {
  .xsh {
    --xsh-lab: 0px; --xsh-rail-h: 2.75rem; --xsh-rail-y: 1.25rem;
    --ra: 1.25rem; --band: 1.75rem; --rb: 1.25rem;
  }
  .xsh-l { display: none; }
  .xsh-s { display: inline; }
  .xsh__top { flex-direction: column; align-items: flex-start; margin-bottom: 1rem; }
  .xsh__title { font-size: 1rem; }
  .xsh-sheet { flex-direction: column; align-items: flex-start; gap: 0.375rem; }   .xsh-sheet__k { font-size: 0.6875rem; }
  .xsh-sheet__row { font-size: 0.8125rem; }
  .xsh-rail { grid-template-columns: minmax(0, 1fr); }
  .xsh-rail__k { display: none; }
  .xsh-tick:not(.xsh-tick--ph) { display: none; }
  .xsh-lane { grid-template-columns: minmax(0, 1fr); padding-top: 0.5rem; }
  .xsh-lane[data-pillar="alerts"] { --ra: 1.625rem; --rb: 1.625rem; }
  .xsh-lane__k { position: relative; z-index: 2; justify-self: start; padding: 0 0.375rem 0 0; background: var(--c-card); font-size: 0.75rem; }
  .xsh-flag__what { display: none; }
  .xsh-flag__lab { gap: 0.35rem; padding: 0 0.375rem; }
  .xsh-flag__lab b { font-size: 0.6875rem; }
  .xsh-sev { font-size: 0.625rem; }
  .xsh .led--mini { --led-size: 0.625rem; padding: 0.45em 0.6em; letter-spacing: 0.08em; }
  .xsh-log { display: block; }
  .xsh__foot { flex-direction: column; align-items: flex-start; gap: 0.625rem; }
  .xsh__beat { flex: none; width: 100%; min-height: 4.35em; font-size: 0.875rem; }   }
@media (prefers-reduced-motion: reduce) {
  .xsh *, .xsh *::before, .xsh *::after { animation: none !important; transition: none !important; }
}
