.score-chart { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--outline); }
.score-chart-row { display: grid; grid-template-columns: 44px minmax(180px, 1.1fr) minmax(180px, 1.5fr) 60px 122px; align-items: center; gap: 16px; min-height: 76px; padding: 12px 8px; border-bottom: 1px solid rgba(169, 187, 194, .15); animation: score-row-enter 420ms cubic-bezier(.2,.75,.25,1) both; animation-delay: calc(var(--row-order, 0) * 35ms); }
.score-chart-row[data-score-position="1"] { --row-order: 0; }
.score-chart-row[data-score-position="2"] { --row-order: 1; }
.score-chart-row[data-score-position="3"] { --row-order: 2; }
.score-chart-row[data-score-position="4"] { --row-order: 3; }
.score-chart-row[data-score-position="5"] { --row-order: 4; }
.score-chart-row[data-score-position="6"] { --row-order: 5; }
.score-chart-row.is-current-run { border-inline-start: 3px solid var(--cyan); background: linear-gradient(90deg, rgba(74,232,224,.08), transparent 70%); }
.scoreboard-axis { display: flex; justify-content: space-between; margin: 0 122px 8px 52px; color: rgba(169,187,194,.55); font: 8px var(--mono); }
.score-chart-rank { color: var(--muted); font: 500 12px var(--mono); text-align: center; }
.score-chart-name { display: grid; min-width: 0; gap: 5px; }
.score-chart-name strong { overflow: hidden; color: var(--text); font-size: 15px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.score-chart-row.has-context-label .score-chart-name strong { overflow: visible; white-space: normal; text-overflow: clip; line-height: 1.35; }
.score-chart-name small { overflow: hidden; color: var(--muted); font: 10px/1.3 var(--mono); text-overflow: ellipsis; white-space: nowrap; }
.score-chart-plot { display: grid; min-width: 0; gap: 6px; }
.score-chart-track { position: relative; display: block; height: 12px; overflow: hidden; border-radius: 999px; background: repeating-linear-gradient(90deg, rgba(169,187,194,.20) 0 1px, transparent 1px calc(25% - 1px), rgba(169,187,194,.20) calc(25% - 1px) 25%), rgba(169,187,194,.08); }
.score-chart-fill { position: absolute; inset: 0 auto 0 0; display: block; width: var(--score-width); border-radius: inherit; background: linear-gradient(90deg, #288d8a, var(--cyan)); box-shadow: 0 0 16px rgba(74,232,224,.24); transform-origin: left center; animation: score-bar-grow 820ms cubic-bezier(.2,.75,.25,1) both; }
.score-chart-value { color: var(--text); font: 700 16px var(--mono); text-align: right; font-variant-numeric: tabular-nums; }
.score-chart-actions { display: inline-flex; width: 122px; flex: 0 0 122px; align-items: center; justify-content: flex-end; gap: 4px; }
.score-chart-icon { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid transparent; border-radius: 50%; color: var(--cyan-soft); background: rgba(74,232,224,.08); text-decoration: none; cursor: pointer; transition: color 160ms ease, background 160ms ease, border-color 160ms ease, transform 160ms ease; }
.score-chart-icon:hover, .score-chart-icon:focus-visible { border-color: rgba(74,232,224,.48); outline: none; color: #061615; background: var(--cyan); transform: translateY(-1px); }
.score-chart-icon .material-symbols-rounded { font-size: 20px; }
.score-chart-row.is-current-run .score-chart-icon[aria-label^="Run details"] { visibility: hidden; }
.score-chart-unavailable { display: flex; align-items: center; gap: 14px; min-height: 112px; padding: 24px; border: 1px solid rgba(255,128,108,.42); border-radius: 22px; color: var(--text); background: rgba(255,128,108,.06); }
.score-chart-unavailable > .material-symbols-rounded { color: var(--coral); font-size: 28px; }
.score-chart-unavailable p { display: grid; gap: 5px; margin: 0; }
.score-chart-unavailable p span { color: var(--muted); font-size: 13px; line-height: 1.45; }
.run-notice-dialog { width: min(520px, calc(100% - 32px)); max-width: none; max-height: min(78vh, 680px); padding: 0; overflow: auto; border: 1px solid var(--outline); border-radius: 24px; color: var(--text); background: var(--surface); box-shadow: 0 24px 80px rgba(0,0,0,.55); }
.run-notice-dialog::backdrop { background: rgba(2,8,11,.72); backdrop-filter: blur(5px); }
.run-notice-dialog section { padding: 24px; }
.run-notice-dialog header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.run-notice-dialog h2 { margin: 0; font-size: 21px; line-height: 1.2; }
.run-notice-dialog p { margin: 0; color: #cad9dd; font-size: 14px; line-height: 1.65; white-space: pre-line; }
.run-notice-dialog button { flex: 0 0 auto; }

@keyframes score-bar-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes score-row-enter { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }

@media (max-width: 760px) {
  .score-chart-row { grid-template-columns: 26px minmax(0, 1fr) 52px; grid-template-rows: auto auto auto; column-gap: 10px; row-gap: 8px; min-height: 0; padding: 14px 4px; }
  .score-chart-name strong { overflow: visible; font-size: 14px; line-height: 1.25; text-overflow: clip; white-space: normal; }
  .score-chart-name small { overflow: visible; font-size: 10px; line-height: 1.4; text-overflow: clip; white-space: normal; }
  .score-chart-plot { grid-column: 2 / 4; grid-row: 3; padding: 0 2px 2px 0; }
  .score-chart-value { grid-column: 3; grid-row: 1; font-size: 14px; }
  .score-chart-actions { grid-column: 2 / 4; grid-row: 2; justify-self: start; width: auto; flex: 0 0 auto; justify-content: flex-start; gap: 8px; }
  .score-chart-icon { width: 48px; height: 48px; }
  .score-chart-icon .material-symbols-rounded { font-size: 20px; }
  .score-chart-rank { grid-column: 1; grid-row: 1; }
  .score-chart-name { grid-column: 2; grid-row: 1; }
}

@media (max-width: 900px) and (min-width: 761px) {
  .score-chart-row { grid-template-columns: 40px minmax(120px, 1.1fr) minmax(130px, 1.5fr) 56px 122px; gap: 10px; padding-inline: 4px; }
  .scoreboard-axis { margin-inline-start: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  .score-chart-row, .score-chart-fill { animation: none; }
  .score-chart-fill { transform: none; }
  .score-chart-icon { transition: none; }
}
