/* Stuntfahrer (js/stuntui.js): track select with stars, the canvas ride, touch pads, cards. */

.sf { position: absolute; inset: 0; background: #12100e; color: #f5efe6; font-family: 'Nunito', sans-serif; overflow: auto; }
.sf-menu { max-width: 860px; margin: 0 auto; padding: 30px 18px 40px; box-sizing: border-box; }
.sf-menu h1 { margin: 0; font: 900 clamp(40px, 8vw, 64px) 'Nunito', sans-serif; letter-spacing: -.03em; font-style: italic; }
.sf-menu h1 span { color: #f97316; }
.sf-sub { color: #c9bba8; font-weight: 700; margin: 6px 0 10px; max-width: 620px; }
.sf-total { font-weight: 800; color: #e9dcc9; margin: 0 0 16px; }
.sf-stars b { color: #fbbf24; text-shadow: 0 0 8px rgba(251, 191, 36, .5); }
.sf-stars i { font-style: normal; color: rgba(255, 255, 255, .15); }
.sf-levels { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.sf-level { display: grid; gap: 4px; text-align: left; padding: 14px; border-radius: 14px; cursor: pointer; color: inherit; font: inherit;
	border: 1.5px solid rgba(255, 255, 255, .1); background: linear-gradient(160deg, hsl(var(--h) 45% 32%), hsl(var(--h) 35% 14%)); transition: transform .12s, border-color .12s; }
.sf-level:hover, .sf-level:focus-visible { transform: translateY(-3px); border-color: #f97316; outline: none; }
.sf-n { font: 900 28px 'Nunito', sans-serif; font-style: italic; color: #fff; opacity: .85; }
.sf-name { font-weight: 900; font-size: 17px; }
.sf-check { font-style: normal; color: #4ade80; }
.sf-level .sf-stars { font-size: 20px; letter-spacing: 2px; }
.sf-time { font-size: 13px; font-weight: 700; color: #d8cbb8; }
.sf-opts { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin: 18px 0 10px; }
.sf-keys { color: #a29482; font-size: 14px; }
.sf-btn, .sf-row button { font: 800 15px 'Nunito', sans-serif; padding: 10px 18px; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .06); color: #fff; cursor: pointer; }
.sf-btn:hover, .sf-row button:hover { background: rgba(255, 255, 255, .14); }

.sf-play { position: absolute; inset: 0; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; }
.sf-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.sf-hud { position: absolute; top: 10px; left: 12px; display: flex; gap: 14px; align-items: baseline; font-weight: 900; text-shadow: 0 2px 4px rgba(0, 0, 0, .6); pointer-events: none; }
.sf-lvl { font-size: 15px; opacity: .9; }
.sf-clock { font-size: 26px; font-variant-numeric: tabular-nums; }
.sf-flips { color: #fbbf24; }
.sf-pop { position: absolute; top: 22%; left: 50%; transform: translateX(-50%) scale(.8); font: 900 clamp(24px, 5vw, 40px) 'Nunito', sans-serif; font-style: italic; color: #fbbf24;
	text-shadow: 0 3px 0 #7c2d12, 0 6px 16px rgba(0, 0, 0, .5); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; white-space: nowrap; }
.sf-pop.on { opacity: 1; transform: translateX(-50%) scale(1); }
.sf-pause { position: absolute; top: 8px; right: 10px; width: 40px; height: 40px; border-radius: 10px; border: 0; background: rgba(0, 0, 0, .4); color: #fff; font: 900 16px 'Nunito', sans-serif; cursor: pointer; }
.sf-touch { display: none; position: absolute; left: 0; right: 0; bottom: 14px; justify-content: space-between; padding: 0 14px; pointer-events: none; }
.sf-touch div { display: flex; gap: 10px; }
.sf-touch button { pointer-events: auto; width: 74px; height: 74px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .5); background: rgba(0, 0, 0, .35); color: #fff; font: 900 16px 'Nunito', sans-serif; touch-action: none; }
.sf-touch button.gas { background: rgba(249, 115, 22, .55); }
.sf-touch button.on { background: rgba(255, 255, 255, .35); }
@media (pointer: coarse) { .sf-touch { display: flex; } }
.sf-over { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(10, 8, 6, .55); padding: 16px; }
.sf-over[hidden] { display: none; }
.sf-card { background: #1d1915; border: 1.5px solid rgba(255, 255, 255, .14); border-radius: 18px; padding: 24px 26px; max-width: 440px; text-align: center; box-shadow: 0 30px 60px -20px #000; }
.sf-card h2 { margin: 0 0 6px; font: 900 32px 'Nunito', sans-serif; font-style: italic; }
.sf-card.win h2 { color: #f97316; }
.sf-big .sf-stars { font-size: 44px; letter-spacing: 6px; }
.sf-card p { color: #d6c8b4; margin: 8px 0 18px; line-height: 1.5; }
.sf-row { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.sf-row button.go { background: #f97316; border-color: #f97316; }

/* online races: the friends box in the menu, the lobby, the countdown, the place in the HUD */
.sf-friends { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 18px 0 0; padding: 14px 16px; border-radius: 14px; background: rgba(249, 115, 22, .1); border: 1.5px solid rgba(249, 115, 22, .35); }
.sf-friends > div { flex: 1 1 220px; display: grid; gap: 2px; }
.sf-friends > div span { color: #c9bba8; font-size: 14px; font-weight: 700; }
.sf-friends form { display: flex; gap: 6px; }
.sf-friends input, .sf-link input, .sf-track select { font: 800 15px 'Nunito', sans-serif; padding: 9px 12px; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, .2); background: rgba(0, 0, 0, .3); color: #fff; }
.sf-friends input { width: 92px; text-transform: uppercase; letter-spacing: .12em; }
.sf-btn.go, .sf-row button.go { background: #f97316; border-color: #f97316; }
.sf-lobby h1 span { letter-spacing: .08em; }
.sf-link { display: flex; gap: 8px; margin: 6px 0 16px; max-width: 620px; }
.sf-link input { flex: 1; min-width: 0; }
.sf-players { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 6px; max-width: 620px; text-align: left; }
.sf-players li { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; background: rgba(255, 255, 255, .06); }
.sf-players li.me { background: rgba(249, 115, 22, .16); }
.sf-players i { font-style: normal; font-size: 12px; color: #fbbf24; font-weight: 800; }
.sf-dot { width: 12px; height: 12px; border-radius: 50%; flex: none; }
.sf-res { margin-left: auto; font-weight: 800; color: #e9dcc9; font-variant-numeric: tabular-nums; }
.sf-track { margin: 0 0 16px; font-weight: 800; }
.sf-lobby .sf-row { justify-content: flex-start; }
.sf-wait { color: #c9bba8; font-weight: 800; align-self: center; }
.sf-card .sf-players { margin: 10px 0; }
.sf-count { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; font: 900 clamp(80px, 18vw, 180px) 'Nunito', sans-serif; font-style: italic; color: #fff; text-shadow: 0 6px 0 #7c2d12, 0 12px 30px rgba(0, 0, 0, .5); }
.sf-count[hidden] { display: none; }
.sf-place { color: #fff; }
