.topbar-actions{display:flex;align-items:center;justify-self:end;gap:18px}
.change-button{border:2px solid var(--blue);border-radius:999px;padding:7px 14px;background:#eff0ff;color:#3039a1;font:800 13px/1.2 inherit;cursor:pointer}
.change-button:hover{background:#dfe2ff}
.game-account-link{border:2px solid var(--blue);border-radius:999px;padding:7px 14px;background:#eff0ff;color:#3039a1;font:800 13px/1.2 inherit;text-decoration:none;white-space:nowrap}
.mode-dialog{width:min(860px,calc(100% - 28px));max-height:calc(100dvh - 32px);padding:28px;border:3px solid #fff;border-radius:26px;background:var(--paper);color:var(--ink);box-shadow:0 24px 70px rgba(23,24,33,.25)}
.mode-dialog::backdrop{background:rgba(23,24,33,.76)}
.mode-dialog-head{display:flex;justify-content:space-between;gap:16px;align-items:start;margin-bottom:22px}
.mode-dialog-head h2{margin:0;font-size:clamp(28px,4vw,42px);line-height:1.1;letter-spacing:-.01em;word-spacing:.02em}
.close-mode{flex:0 0 38px;width:38px;height:38px;border:0;border-radius:50%;background:#e8e6e0;color:var(--ink);font-size:25px;line-height:1;cursor:pointer}
.close-mode[hidden]{display:none}
.gameplay-group+.gameplay-group{margin-top:24px}
.group-heading{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:10px}
.group-heading h3{margin:0;font-size:19px;line-height:1.2}
.times-carousel{display:grid;grid-template-columns:36px minmax(0,1fr) 36px;align-items:center;gap:8px}
.scroll-tables{width:36px;height:36px;border:1px solid var(--line);border-radius:50%;background:#fffefa;color:var(--ink);font:800 20px/1 inherit;cursor:pointer}
.scroll-tables:disabled{opacity:.35;cursor:default}
.mode-tiles{display:grid;gap:10px}
.times-tiles{display:flex;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain;scroll-snap-type:x mandatory;padding:2px;scrollbar-width:none}
.times-tiles::-webkit-scrollbar{display:none}
.times-tiles .mode-tile{flex:0 0 160px;min-height:112px;flex-direction:column;align-items:flex-start;scroll-snap-align:start}
.other-tiles{grid-template-columns:repeat(auto-fit,minmax(220px,1fr))}
.mode-tile{position:relative;display:flex;align-items:center;gap:13px;min-height:74px;width:100%;padding:10px 14px;border:2px solid #d7d3ca;border-radius:18px;background:#fffefa;color:var(--ink);text-align:left;font:inherit;cursor:pointer;box-shadow:0 3px 0 #d7d3ca}
.mode-tile:hover:not(:disabled){border-color:var(--blue)}
.mode-tile.selected{border-color:var(--blue);background:#eff0ff;box-shadow:0 3px 0 #444ec5}
.mode-tile:disabled{cursor:default;opacity:.7}
.mode-tile .mode-icon{display:grid;place-items:center;flex:0 0 48px;width:48px;height:48px;border-radius:13px;background:#e8e6e0;color:#363da4;font-size:20px;font-weight:900}
.mode-tile.selected .mode-icon{background:var(--lime);color:var(--ink)}
.mode-tile strong,.mode-tile small{display:block}
.mode-tile strong{font-size:17px;line-height:1.15}
.mode-tile small{margin-top:3px;color:#4f5058;font-size:13px;line-height:1.25}
.mode-tile .tile-best{position:absolute;top:11px;right:10px;padding:4px 6px;border-radius:7px;background:#e9eaff;color:#333ca1;font-size:12px;font-weight:850;line-height:1.1;white-space:nowrap}
.results li b{font-size:18px;text-align:right}
@media(max-width:700px){.topbar-actions{gap:12px}.mode-tile{min-height:68px}.mode-tile small{font-size:14px}.score-stat small{font-size:12px}.score-stat small::after{content:none}}
@media(max-width:500px){.topbar{padding-inline:12px;flex-wrap:wrap}.topbar-actions{width:100%;justify-content:space-between;gap:8px}.how-button{font-size:12px}.change-button,.game-account-link{padding:6px 9px;font-size:12px}.mode-dialog{padding:22px 18px}.mode-dialog-head{margin-bottom:16px}.group-heading{display:block}.times-carousel{display:block}.scroll-tables{display:none}.times-tiles .mode-tile{flex-basis:150px;min-height:112px}}
@media(max-width:500px){#score{font-size:clamp(26px,8vw,38px);white-space:nowrap}}
