@font-face { font-family: 'Chop'; src: url('../fonts/rubik-regular.woff2')  format('woff2'); font-weight: 400; font-display: swap; }

@font-face { font-family: 'Chop'; src: url('../fonts/rubik-medium.woff2')   format('woff2'); font-weight: 500; font-display: swap; }

@font-face { font-family: 'Chop'; src: url('../fonts/rubik-semibold.woff2') format('woff2'); font-weight: 600; font-display: swap; }

@font-face { font-family: 'Chop'; src: url('../fonts/rubik-bold.woff2')     format('woff2'); font-weight: 700; font-display: swap; }

:root {
    --bg:   #0a0a0c;
    --p1:   #101013;
    --p2:   #16161a;
    --p3:   #1d1e23;

    --acc:  #1c7ef7;
    --acc2: #4b9bff;
    --accs: rgba(28, 126, 247, .15);

    --ok:   #2fbf71;
    --warn: #eab63f;
    --bad:  #ef5f57;

    --t1: #eceef2;
    --t2: rgba(236, 238, 242, .60);
    --t3: rgba(236, 238, 242, .32);

    --ln:  rgba(255, 255, 255, .06);
    --ln2: rgba(255, 255, 255, .12);

    --e: cubic-bezier(.23, 1, .32, 1);

    --i-doc:   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z"/><path d="M14 3v5h5M9 13h6M9 17h4"/></svg>');
    --i-box:   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M3 8l9-5 9 5v8l-9 5-9-5z"/><path d="M3 8l9 5 9-5M12 13v8"/></svg>');
    --i-tree:  url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="5" r="2.4"/><circle cx="6" cy="19" r="2.4"/><circle cx="18" cy="19" r="2.4"/><path d="M12 7.4v4.2M12 11.6H6v5M12 11.6h6v5"/></svg>');
    --i-chart: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M4 20V11M10 20V4M16 20v-6M22 20H2"/></svg>');
    --i-car:   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M5 13l1.5-4.5A2 2 0 0 1 8.4 7h7.2a2 2 0 0 1 1.9 1.5L19 13v4h-2.5M5 17H3v-4M5 17h11"/><circle cx="7.5" cy="17.5" r="1.5"/><circle cx="16.5" cy="17.5" r="1.5"/></svg>');
    --i-sedan: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M3 14l1-4h16l1 4v3h-3M3 17H2v-3M6 17h11M6 10l1.5-3h9L18 10"/><circle cx="7.5" cy="17.5" r="1.4"/><circle cx="16.5" cy="17.5" r="1.4"/></svg>');
    --i-speed: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M4 17a8 8 0 1 1 16 0"/><path d="M12 17l4-5"/></svg>');
    --i-crown: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M4 18h16M4 18L3 7l5 4 4-6 4 6 5-4-1 11"/></svg>');
    --i-wrench:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M15 4.5a4.5 4.5 0 0 0 5.9 5.9L10.9 20.4a2.6 2.6 0 0 1-3.7-3.7z"/></svg>');
    --i-drill: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M4 7h9v6H4zM13 9h4M17 10h3M8 13v5"/></svg>');
    --i-saw:   url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><circle cx="9" cy="12" r="5"/><path d="M14 12h7M9 4v2M9 18v2"/></svg>');
    --i-flame: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M12 3c3 4 5 6 5 9a5 5 0 0 1-10 0c0-2 1-3 2-4 0 2 1 3 2 3 0-3 0-6 1-8z"/></svg>');
    --i-bolt:  url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M13 3L5 14h5l-1 7 8-11h-5z"/></svg>');
    --i-gauge: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="8"/><path d="M12 12l3.5-3.5M12 4v2"/></svg>');
    --i-medal: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="15" r="5"/><path d="M8 4l2 6M16 4l-2 6"/></svg>');
    --i-star:  url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M12 4l2.4 5 5.6.7-4 3.9 1 5.4-5-2.7-5 2.7 1-5.4-4-3.9 5.6-.7z"/></svg>');
    --i-exit:  url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round"><path d="M14 4h4a1 1 0 0 1 1 1v14a1 1 0 0 1-1 1h-4M10 8l-4 4 4 4M6 12h9"/></svg>');
}

* { margin: 0; padding: 0; box-sizing: border-box; cursor: none; }

html, body {
    width: 100%; height: 100%;
    overflow: hidden;
    background: transparent;
    color: var(--t1);
    font: 400 14px/1.45 'Chop', 'Rubik', 'Segoe UI', sans-serif;
    font-feature-settings: 'tnum' 1;
    user-select: none;
}

.off { display: none !important; }

.ico {
    width: 17px; height: 17px;
    flex: none;
    background: currentColor;
    -webkit-mask: var(--i) center/contain no-repeat;
    mask: var(--i) center/contain no-repeat;
}

@keyframes slide { from { opacity: 0; transform: translateX(14px); } }

@keyframes blink { 50% { opacity: .3; } }

@keyframes drop { from { opacity: 0; transform: translateX(-50%) translateY(-12px); } }

#mg { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; background: transparent; }

#mg[data-bg="dim"] { background: rgba(0, 0, 0, .45); }

.mg-box {
    width: 560px;
    display: flex; flex-direction: column;
    padding: 0 5px 5px;
    font: 400 12px/1.35 'Segoe UI', Tahoma, 'Chop', sans-serif;
    background: rgba(158, 196, 232, .30);
    border: 1px solid rgba(255, 255, 255, .42);
    border-radius: 8px 8px 4px 4px;
    box-shadow:
        0 0 0 1px rgba(12, 40, 74, .55),
        0 22px 54px rgba(0, 0, 0, .58),
        inset 0 0 26px rgba(255, 255, 255, .20);
}

#mg[data-s="win"]  .mg-box { box-shadow: 0 0 0 1px rgba(47,191,113,.75), 0 0 30px rgba(47,191,113,.45), 0 22px 54px rgba(0,0,0,.58); }

#mg[data-s="lose"] .mg-box, #mg[data-s="miss"] .mg-box { box-shadow: 0 0 0 1px rgba(239,95,87,.75), 0 0 30px rgba(239,95,87,.45), 0 22px 54px rgba(0,0,0,.58); animation: shake .3s ease; }

@keyframes shake { 25% { transform: translateX(-6px); } 60% { transform: translateX(5px); } }

.mg-box header { display: flex; align-items: center; gap: 7px; height: 29px; padding: 0 2px 0 7px; flex: none; }

.mg-box header b { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12px; font-weight: 400; text-align: left; text-shadow: 0 0 6px rgba(0,0,0,.85), 0 1px 2px rgba(0,0,0,.7); }

.mg-ico { font-size: 12px; color: hsl(207 60% 93%); }

.mg-wb { display: flex; align-items: flex-start; align-self: flex-start; }

.win-btn.dead { opacity: .45; }

.win-btn.dead:hover { background: linear-gradient(180deg, rgba(255,255,255,.34), rgba(255,255,255,.08)); }

#mg .win-btn { cursor: default; }

#mg .win-btn.x { cursor: pointer; }

.mg-body {
    flex: 1; min-height: 0;
    padding: 0;
    color: hsl(0 0% 10%);
    background: hsl(0 0% 94%);
    border: 1px solid rgba(255, 255, 255, .55);
    border-radius: 4px;
    box-shadow: 0 0 0 1px rgba(20, 55, 95, .45);
}

.mg-hint {
    margin: 8px; padding: 7px 9px;
    font-size: 11px; line-height: 1.4; color: hsl(212 52% 25%);
    background: hsl(211 60% 92%);
    border: 1px solid hsl(209 60% 80%); border-radius: 4px;
}

.mg-hint:empty, .mg-hint.off { display: none; }

.mg-load { padding: 18px 14px 26px; text-align: center; }

.mg-cat {

    display: inline-block;
    text-align: left;
    margin-bottom: 12px;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 11px; line-height: 1.15;
    color: hsl(0 0% 60%);
    white-space: pre;
    animation: catIn 420ms cubic-bezier(.23, 1, .32, 1) both;
}

@keyframes catIn {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.mg-load p { margin-bottom: 14px; font-size: 12px; color: hsl(0 0% 15%); }

.mg-load-sub {
    display: block; margin-top: 12px;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 10.5px; color: hsl(0 0% 53%);
}

.xp-bar {
    position: relative;
    width: 172px; height: 17px; margin: 0 auto;
    overflow: hidden;
    background: #fff;
    border: 1px solid #a0aebb; border-top-color: #7c8b99;
    border-radius: 2px;
}

.xp-bar i {
    position: absolute; top: 2px; bottom: 2px;
    width: 12px;
    background: linear-gradient(180deg, #8fd0f5 0%, #2f86c8 45%, #17578f 55%, #4ea3dc 100%);
    border-radius: 1px;
    animation: xpRun 1.15s linear infinite;
}

.xp-bar i:nth-child(2) { animation-delay: .16s; }

.xp-bar i:nth-child(3) { animation-delay: .32s; }

@keyframes xpRun {
    from { transform: translateX(-16px); }
    to   { transform: translateX(174px); }
}

@media (prefers-reduced-motion: reduce) {
.xp-bar i { animation: none; opacity: .55; }
.xp-bar i:nth-child(1) { transform: translateX(40px); }
.xp-bar i:nth-child(2) { transform: translateX(72px); }
.xp-bar i:nth-child(3) { transform: translateX(104px); }
}

.mg-panel {
    margin: 0 9px 9px; padding: 12px;
    color: hsl(0 0% 15%);
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%);
    border-top-color: hsl(0 0% 54%); border-left-color: hsl(0 0% 54%);
    border-radius: 4px;
}

#mg-state { font-size: 10.5px; font-weight: 600; letter-spacing: .8px; color: rgba(255,255,255,.82); text-shadow: 0 1px 2px rgba(0,0,0,.7); }

#mg[data-s] #mg-state { color: hsl(0 0% 100%); }

#mg-state[data-z="green"] { color: var(--ok); }

#mg-state[data-z="orange"] { color: var(--warn); }

#mg-state[data-z="red"] { color: var(--bad); }

#mg-dial {
    position: relative;
    width: 300px; height: 150px;
    margin: 0 auto 18px;
}

.d-arc {
    position: absolute; inset: 0;
    border-radius: 150px 150px 0 0;
    background: conic-gradient(from 270deg,
        var(--bad) 0deg 26deg, var(--warn) 26deg 62deg, var(--ok) 62deg 118deg,
        var(--warn) 118deg 154deg, var(--bad) 154deg 180deg, transparent 180deg);

    -webkit-mask: radial-gradient(circle 150px at 50% 100%, transparent 58%, #000 58.5%);
    mask: radial-gradient(circle 150px at 50% 100%, transparent 58%, #000 58.5%);
    opacity: .9;
}

.d-needle { position: absolute; left: 50%; bottom: 0; width: 2.5px; height: 126px; margin-left: -1.25px; transform-origin: 50% 100%; background: hsl(0 0% 25%); border-radius: 4px; }

.d-needle::before { content: ''; position: absolute; left: 50%; top: -5px; width: 9px; height: 9px; margin-left: -4.5px; border-radius: 50%; background: currentColor; }

.d-needle[data-z="green"] { color: hsl(109 60% 38%); }

.d-needle[data-z="orange"] { color: hsl(41 60% 49%); }

.d-needle[data-z="red"] { color: hsl(4 60% 48%); }

.d-hub { position: absolute; left: 50%; bottom: -9px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%; background: hsl(0 0% 100%); border: 2.5px solid hsl(0 0% 66%); }

.d-hub[data-z="green"] { border-color: hsl(109 60% 38%); }

.d-hub[data-z="orange"] { border-color: hsl(41 60% 49%); }

.d-hub[data-z="red"] { border-color: hsl(4 60% 48%); }

#mg-track { position: relative; height: 26px; margin-bottom: 14px; background: linear-gradient(180deg, hsl(0 0% 85%), hsl(0 0% 93%)); border: 1px solid hsl(0 0% 66%); border-top-color: hsl(0 0% 54%); border-radius: 4px; overflow: hidden; }

.t-zone { position: absolute; top: 0; bottom: 0; background: linear-gradient(180deg, hsl(96 60% 75%), hsl(103 57% 51%)); border-left: 1px solid hsl(108 60% 30%); border-right: 1px solid hsl(108 60% 30%); }

.t-zone[data-hot="1"] { background: linear-gradient(180deg, hsl(95 60% 86%), hsl(109 60% 38%)); }

.t-mark { position: absolute; top: -2px; bottom: -2px; width: 3px; margin-left: -1.5px; background: hsl(0 0% 25%); border-radius: 4px; }

.t-mark[data-z="green"] { background: hsl(111 60% 25%); }

.mg-pips { display: flex; gap: 3px; margin-bottom: 12px; }

.mg-pips:empty { display: none; }

.mg-pips i { flex: 1; height: 5px; background: hsl(0 0% 87%); border: 1px solid hsl(0 0% 77%); border-radius: 4px; }

.mg-pips i.on { background: linear-gradient(180deg, hsl(104 58% 60%), hsl(109 60% 38%)); border-color: hsl(108 60% 30%); }

.mg-keys { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }

.mg-keys .k {
    display: grid; place-items: center;
    min-width: 40px; height: 26px; padding: 0 12px;
    font: inherit; font-size: 11.5px; font-weight: 600; color: hsl(0 0% 15%);
    background: linear-gradient(180deg, hsl(0 0% 99%) 0%, hsl(210 36% 96%) 45%, hsl(0 0% 91%) 46%, hsl(210 42% 95%) 100%);
    border: 1px solid hsl(0 0% 66%); border-radius: 4px;
    box-shadow: inset 0 1px 0 hsl(0 0% 100%);
}

.mg-keys .k.on {
    color: hsl(203 60% 19%);
    background: linear-gradient(180deg, hsl(203 60% 89%) 0%, hsl(203 60% 84%) 45%, hsl(203 60% 77%) 46%, hsl(203 60% 87%) 100%);
    border-color: hsl(203 60% 56%);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .18);
}

.mg-keys .sep { flex: 1; height: 1px; background: hsl(0 0% 84%); }

.mg-bars .bar {
    height: 15px;
    background: linear-gradient(180deg, hsl(0 0% 85%), hsl(0 0% 93%));
    border: 1px solid hsl(0 0% 66%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px; overflow: hidden;
}

.mg-bars .bar.thin { height: 11px; margin-top: 5px; }

.mg-bars i {
    display: block; height: 100%; width: 0;
    border-radius: 2px 0 0 2px;
    transition: width 140ms linear;
}

#mg-progress { background: linear-gradient(180deg, hsl(96 60% 75%) 0%, hsl(103 57% 51%) 48%, hsl(109 60% 38%) 52%, hsl(104 58% 60%) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.65); }

#mg-strain   { background: linear-gradient(180deg, hsl(200 60% 79%) 0%, hsl(203 60% 57%) 48%, hsl(205 60% 50%) 52%, hsl(201 60% 71%) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.55); }
#mg-strain.warn { background: linear-gradient(180deg, hsl(38 60% 79%) 0%, hsl(36 60% 58%) 48%, hsl(36 60% 49%) 52%, hsl(37 60% 74%) 100%); }
#mg-strain.low  { background: linear-gradient(180deg, hsl(6 60% 80%) 0%, hsl(5 60% 58%) 48%, hsl(4 60% 48%) 52%, hsl(6 60% 70%) 100%); }

#mg-miss:empty { display: none; }
#mg-miss.hot { color: hsl(4 60% 48%); font-weight: 600; }

.mg-foot { display: flex; justify-content: space-between; padding: 4px 9px; font-size: 10.5px; color: hsl(0 0% 42%); background: linear-gradient(180deg, hsl(210 37% 97%), hsl(0 0% 93%)); border-top: 1px solid hsl(0 0% 87%); }

@keyframes pop { from { opacity: 0; transform: scale(.99); } }

@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

body { background: transparent; }

html, body { font-family: 'Rubik', 'Chop', 'Segoe UI', sans-serif; }

@keyframes ndIn {
    from { opacity: 0; transform: translate(-50%, -50%) scale(.92); }
    to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

@keyframes edgeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes btIn {
    from { opacity: 0; transform: translate(-50%, -50%) scale(.94); }
    to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

@keyframes ndPop {
    0%   { transform: translate(-50%, -50%) scale(1); }
    38%  { transform: translate(-50%, -50%) scale(1.16); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

@keyframes ringPop {
    from { opacity: .55; transform: translate(-50%, -50%) scale(1); }
    to   { opacity: 0;   transform: translate(-50%, -50%) scale(1.85); }
}

@keyframes ccIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes mgIn {
    from { opacity: 0; transform: translateY(10px) scale(.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

#mg { animation: mgFade 160ms cubic-bezier(.23, 1, .32, 1); }

.mg-box { animation: mgIn 240ms cubic-bezier(.23, 1, .32, 1); }

@keyframes mgFade { from { opacity: 0; } to { opacity: 1; } }

@keyframes mgWin {
    from { opacity: .5; transform: scale(1); }
    to   { opacity: 0;  transform: scale(1.06); }
}

#mg[data-s="win"] .mg-box { position: relative; }

#mg[data-s="win"] .mg-box::after {
    content: '';
    position: absolute; inset: 0;
    border: 2px solid var(--ok);

    border-radius: 8px 8px 4px 4px;
    animation: mgWin 520ms cubic-bezier(.23, 1, .32, 1) forwards;
    pointer-events: none;
}

.t-zone { transition: left 260ms cubic-bezier(.23, 1, .32, 1), width 260ms cubic-bezier(.23, 1, .32, 1), background 120ms linear; }

.t-mark { transition: background 90ms linear; will-change: transform; }

.d-needle { will-change: transform; transition: color 120ms linear; }

.d-hub { transition: border-color 120ms linear; }

.mg-bars i { transition: none; }

@keyframes pipOn {
    0%   { transform: scaleY(1); }
    45%  { transform: scaleY(2.4); }
    100% { transform: scaleY(1); }
}

.mg-pips i { transition: background 160ms cubic-bezier(.23, 1, .32, 1); }

.mg-pips i.on { animation: pipOn 280ms cubic-bezier(.23, 1, .32, 1); }

.mg-keys .k { transition: background 160ms cubic-bezier(.23, 1, .32, 1), color 160ms cubic-bezier(.23, 1, .32, 1), transform 160ms cubic-bezier(.23, 1, .32, 1); }

.mg-keys .k.on { transition-duration: 80ms; }

#mg-state { transition: color 140ms linear; }

@media (prefers-reduced-motion: reduce) {
.mg-box, #mg { animation: none; }
#mg[data-s="win"] .mg-box::after { animation: none; opacity: 0; }
.mg-pips i.on { animation: none; }
.t-zone { transition: background 120ms linear; }
}

.mg-keys .k.big {
    min-width: 78px; height: 62px;
    font-size: 26px;
    letter-spacing: 1px;
}

.mg-keys:has(.k.big) { justify-content: center; }

#mg-maze {
    display: block;
    width: 300px; height: 300px;
    margin: 0 auto 16px;
    background: hsl(0 0% 4%);
    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 12px;
}

.mg-keys .k.sm { min-width: 34px; height: 30px; padding: 0 10px; font-size: 11px; }

.mg-keys .k.big {
    color: var(--c, hsl(0 0% 100%));
    background: color-mix(in srgb, var(--c, hsl(213 60% 54%)) 18%, hsl(0 0% 10%));
    border-color: transparent;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c, hsl(213 60% 54%)) 55%, transparent);
    transform: none;
}

.mg-pips i { background: color-mix(in srgb, var(--c, hsl(0 0% 100%)) 22%, transparent); }

.mg-pips i.on { background: var(--c, var(--ok)); }

.mg-pips i.next {
    background: color-mix(in srgb, var(--c, hsl(0 0% 100%)) 55%, transparent);
    animation: pipNext 900ms ease-in-out infinite;
}

@keyframes pipNext {
    0%, 100% { opacity: .45; }
    50%      { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
.mg-pips i.next { animation: none; opacity: 1; }
}

#mg-patch {
    display: block;
    width: 300px; height: 300px;
    margin: 0 auto 16px;
    background: hsl(0 0% 5%);
    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 12px;
    cursor: crosshair;
}

@keyframes lockin {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes grow {
    from { transform: scaleY(0); opacity: 0; }
    to   { transform: scaleY(1); opacity: 1; }
}

@keyframes slidein {
    from { opacity: 0; transform: translateY(-50%) translateX(-14px); }
    to   { opacity: 1; transform: translateY(-50%) translateX(0); }
}

#mg-wave { display: block; width: 100%; margin: 4px 0; border-radius: 4px; background: hsl(0 0% 100%); border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%); }

#mg-wave.off, #mg-wave-dials.off, #mg-wires.off, #mg-decode.off { display: none; }

#mg-wave-dials { display: grid; gap: 10px; margin-bottom: 6px; }

#mg-wave-dials .dl { display: flex; align-items: center; gap: 10px; }

#mg-wave-dials .dl span { min-width: 92px; font-size: 10.5px; color: hsl(0 0% 42%); }

#mg-wave-dials .dl b { min-width: 42px; font-size: 10px; font-weight: 600; color: hsl(0 0% 42%); text-align: right; }

#mg-wave-dials .bar { flex: 1; height: 10px; background: linear-gradient(180deg, hsl(0 0% 85%), hsl(0 0% 93%)); border: 1px solid hsl(0 0% 66%); border-radius: 4px; overflow: hidden; }

#mg-wave-dials .bar i { display: block; height: 100%; background: linear-gradient(180deg, hsl(200 60% 79%), hsl(205 60% 50%)); transition: width 60ms linear; }

#mg-decode { display: block; width: 100%; margin: 4px 0; border-radius: 4px; background: hsl(0 0% 100%); border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%); }

@media (prefers-reduced-motion: reduce) {
#mg-wave-dials .bar i { transition: none; }
.wp { transition: none; }
}

#mg-wires {
    position: relative;
    height: 236px;
    margin: 4px 0;
    padding: 14px 0;

    background:
        repeating-linear-gradient(90deg, rgba(0,0,0,.045) 0 1px, transparent 1px 22px),
        hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
    user-select: none;
}

#mg-wires-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

#mg-wires-svg path { fill: none; stroke-linecap: round; }

#mg-wires-svg .on  { stroke-width: 6; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .55)); }

#mg-wires-svg .tmp { stroke-width: 4.5; stroke-dasharray: 8 7; opacity: .85; }

#mg-wires-svg .tmp.off { display: none; }

#mg-wires .side {
    position: absolute; top: 14px; bottom: 14px;
    display: flex; flex-direction: column; justify-content: space-around;
    z-index: 2;
}

#mg-wires-l { left: 0; align-items: flex-start; }

#mg-wires-r { right: 0; align-items: flex-end; }

.wp {
    position: relative;
    display: flex; align-items: center;
    width: 26px; height: 13px;
    padding: 0;
    background: var(--c);
    border: none;
    cursor: grab;
    transition: transform 140ms cubic-bezier(.23,1,.32,1), filter 140ms cubic-bezier(.23,1,.32,1);
}

.wp.l { border-radius: 0 3px 3px 0; justify-content: flex-end; transform-origin: left center; }

.wp.r { border-radius: 3px 0 0 3px; justify-content: flex-start; transform-origin: right center; }

.wp .tip { width: 4px; height: 7px; background: rgba(0, 0, 0, .45); border-radius: 1px; }

.wp.l .tip { margin-right: 3px; }

.wp.r .tip { margin-left: 3px; }

.wp:hover { transform: scaleX(1.18); filter: brightness(1.15); }

.wp.hot { cursor: grabbing; filter: brightness(1.3); }

.wp.set { cursor: default; opacity: .45; }

.wp.set:hover { transform: none; filter: none; }

@media (prefers-reduced-motion: reduce) {
.wp { transition: none; }
}

:root {
    --e-out:  cubic-bezier(.23, 1, .32, 1);
    --e-both: cubic-bezier(.77, 0, .175, 1);
}

@keyframes viewIn {
    from { opacity: 0; transform: translateY(6px); }
}

#mg .bar i { transition: none; }

#mg-wave-dials .bar i { transition: width 60ms linear; }

@keyframes draw   { to { stroke-dashoffset: 0; } }

@keyframes fadeIn { from { opacity: 0; } }

@keyframes qcIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: none; }
}

@keyframes hudIn {
    from { opacity: 0; transform: translateX(-14px); }
}

@keyframes promptIn {
    from { opacity: 0; transform: translateY(8px) scale(.96); }
}

#desk {
    position: fixed; inset: 0; z-index: 50;
    overflow: hidden;
    font: 400 12px/1.35 'Segoe UI', Tahoma, 'Chop', sans-serif;
    color: #fff;
    -webkit-font-smoothing: antialiased;
}

#desk, #desk * { cursor: default; }

#desk button, #desk a, #desk .app-row, #desk .dk-peek { cursor: pointer; }

.dk-wall {
    position: absolute; inset: 0;
    background:
        radial-gradient(115% 78% at 50% 116%, rgba(150, 220, 255, .40), rgba(38, 132, 214, .20) 40%, transparent 64%),
        radial-gradient(46% 34% at 50% 104%, rgba(255, 255, 255, .34), transparent 72%),
        linear-gradient(178deg, #04101d 0%, #072235 42%, #0a2b41 72%, #05182a 100%);
}

.dk-wall .rays {
    position: absolute; left: 50%; bottom: -14%;
    width: 190%; height: 92%;
    transform: translateX(-50%);
    opacity: .30;
    background: repeating-conic-gradient(from 200deg at 50% 100%,
        rgba(255, 255, 255, .11) 0deg 3deg, transparent 3deg 11deg);
    -webkit-mask: radial-gradient(60% 100% at 50% 100%, #000 8%, transparent 76%);
            mask: radial-gradient(60% 100% at 50% 100%, #000 8%, transparent 76%);
}

.dk-icons {
    position: absolute; top: 8px; left: 8px; bottom: 52px;
    display: flex; flex-direction: column; flex-wrap: wrap; align-content: flex-start;
    gap: 4px;
    pointer-events: none;
}

.dk-ico {
    width: 80px; padding: 5px 3px 4px;
    display: block; text-align: center;
    background: none; border: none;
}

.dk-ico .gi { display: block; width: 44px; height: 44px; margin: 0 auto 3px; }

.dk-ico .gi svg { display: block; width: 100%; height: 100%; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .55)); }

.dk-ico span {
    display: block;
    font-size: 11px; line-height: 1.25;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .95), 0 0 5px rgba(0, 0, 0, .75);
}

.dk-wins { position: absolute; inset: 0 0 40px 0; pointer-events: none; }

.dk-wins > * { pointer-events: auto; }

.win {
    position: absolute;
    display: flex; flex-direction: column;
    padding: 0 5px 5px;
    background: rgba(158, 196, 232, .30);
    border: 1px solid rgba(255, 255, 255, .42);
    border-radius: 8px 8px 4px 4px;
    box-shadow:
        0 0 0 1px rgba(12, 40, 74, .55),
        0 22px 54px rgba(0, 0, 0, .58),
        inset 0 0 26px rgba(255, 255, 255, .20);
}

.win:not(.on) { background: rgba(150, 168, 188, .26); box-shadow: 0 0 0 1px rgba(12, 40, 74, .40), 0 14px 34px rgba(0, 0, 0, .45); }

.win:not(.on) .win-bar b { color: rgba(255, 255, 255, .62); }

.win-bar {
    position: relative;
    display: flex; align-items: center; gap: 7px;
    height: 29px; padding: 0 2px 0 7px;
    flex: none;
}

.win-bar .wi { font-size: 12px; color: #dcefff; }

.win-bar b {
    flex: 1; min-width: 0;
    overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
    font-size: 12px; font-weight: 400; text-align: left;
    text-shadow: 0 0 6px rgba(0, 0, 0, .85), 0 1px 2px rgba(0, 0, 0, .7);
}

.win-btn {
    width: 27px; height: 19px;
    display: grid; place-items: center;
    font-size: 9px; color: #eaf6ff;
    background: linear-gradient(180deg, rgba(255, 255, 255, .34), rgba(255, 255, 255, .08));
    border: 1px solid rgba(255, 255, 255, .40);
    border-top: none; border-radius: 0 0 4px 4px;
}

.win-btn + .win-btn { margin-left: 1px; }

.win-btn:hover { background: linear-gradient(180deg, rgba(255, 255, 255, .62), rgba(190, 225, 255, .30)); }

.win-btn.x { width: 45px; }

.win-btn.x:hover { background: linear-gradient(180deg, #f2837a, #cf2a20); border-color: rgba(255, 190, 185, .70); color: #fff; }

.win-body {
    flex: 1; min-height: 0;
    overflow: auto;
    color: #1a1a1a;
    background: #f0f0f0;
    border: 1px solid rgba(255, 255, 255, .55);
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgba(20, 55, 95, .45);
}

.win-menu { display: flex; gap: 2px; padding: 3px 4px; background: linear-gradient(180deg, #fdfefe, #eef3f8); border-bottom: 1px solid #d6dfe8; }

.win-menu span { padding: 2px 8px; font-size: 11.5px; color: #16324f; border-radius: 3px; }

.win-menu span:hover { background: #cfe4fb; }

.win-head { padding: 9px 12px; background: linear-gradient(180deg, #ffffff, #eaf1f9); border-bottom: 1px solid #d6dfe8; }

.win-head h5 { font-size: 13px; font-weight: 600; color: #14395f; }

.win-head p { margin-top: 2px; font-size: 11px; color: #5a6b7d; }

.app-list { padding: 6px; }

.app-row {
    display: flex; align-items: center; gap: 9px;
    padding: 5px 8px;
    border: 1px solid transparent; border-radius: 3px;
}

.app-row:hover { background: #dcebfb; border-color: #b6d6f5; }

.app-row.dead { cursor: default; }

.app-row.dead:hover { background: none; border-color: transparent; }

.app-row .ai svg { display: block; width: 18px; height: 18px; }

.app-row.dead .ai { background: none; box-shadow: none; }

.app-row .ai { display: grid; place-items: center; width: 24px; height: 24px; flex: none; font-size: 13px; color: #fff; background: linear-gradient(180deg, #6fb3e8, #1f5f9e); border-radius: 3px; box-shadow: inset 0 1px 0 rgba(255,255,255,.5); }

.app-row .at { flex: 1; min-width: 0; }

.app-row .at b { display: block; font-size: 12px; font-weight: 600; color: #16324f; }

.app-row .at span { font-size: 10.5px; color: #6b7b8c; }

.app-row .ak { font-size: 10px; color: #7d8b99; }

.app-stage {
    margin: 6px; padding: 26px 14px;
    text-align: center;
    color: #6b7b8c;
    background: repeating-linear-gradient(45deg, #e9eef4 0 8px, #eef2f7 8px 16px);
    border: 1px dashed #b9c5d2; border-radius: 3px;
}

.app-stage b { display: block; margin-bottom: 3px; font-size: 12px; color: #46586a; }

.app-stage span { font-size: 10.5px; }

.win-foot { display: flex; justify-content: space-between; padding: 4px 9px; font-size: 10.5px; color: #5a6b7d; background: linear-gradient(180deg, #f4f7fa, #e7edf3); border-top: 1px solid #d6dfe8; }

.dk-bar {
    position: absolute; left: 0; right: 0; bottom: 0;
    height: 40px;
    display: flex; align-items: center; gap: 3px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .30) 0 1px, rgba(148, 204, 250, .22) 1px 2px, transparent 2px),
        linear-gradient(180deg, rgba(34, 62, 96, .90) 0%, rgba(12, 27, 46, .94) 46%,
                                rgba(20, 42, 68, .92) 54%, rgba(7, 16, 29, .96) 100%);
    box-shadow: 0 -7px 16px rgba(0, 0, 0, .38);
}

.dk-orb {
    position: relative; flex: none;
    width: 50px; height: 40px;
    display: grid; place-items: center;
    background: none; border: none;
}

.dk-orb svg {
    display: block; width: 42px; height: 42px;
    margin-top: -5px;
    filter: drop-shadow(0 0 7px rgba(90, 180, 255, .45)) drop-shadow(0 2px 3px rgba(0, 0, 0, .5));
    transition: filter 140ms var(--e);
}

.dk-orb:hover svg { filter: drop-shadow(0 0 14px rgba(140, 215, 255, .85)) drop-shadow(0 2px 3px rgba(0, 0, 0, .45)); }

.dk-orb:active svg { filter: drop-shadow(0 0 6px rgba(90, 180, 255, .5)) brightness(.92); }

.dk-tasks { display: flex; align-items: center; gap: 3px; padding-left: 3px; }

.dk-task {
    display: flex; align-items: center; gap: 7px;
    min-width: 152px; max-width: 200px; height: 30px; padding: 0 10px;
    font: inherit; font-size: 11.5px; color: #eaf4ff; text-align: left;
    background: linear-gradient(180deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .04));
    border: 1px solid rgba(255, 255, 255, .22); border-radius: 3px;
}

.dk-task span { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

.dk-task:hover { background: linear-gradient(180deg, rgba(255, 255, 255, .30), rgba(150, 205, 250, .14)); }

.dk-task.on {
    background: linear-gradient(180deg, rgba(190, 228, 255, .40), rgba(90, 165, 235, .20));
    border-color: rgba(200, 232, 255, .55);
    box-shadow: inset 0 0 12px rgba(160, 215, 255, .38);
}

.dk-tray { display: flex; align-items: center; gap: 2px; margin-left: auto; padding-left: 8px; height: 100%; }

.dk-tray .t-ico { display: grid; place-items: center; width: 22px; height: 100%; font-size: 10px; color: #cfe4f7; }

.dk-clock {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    min-width: 68px; height: 100%; padding: 0 6px;
    line-height: 1.15;
}

.dk-clock b { font-size: 11.5px; font-weight: 400; }

.dk-clock span { font-size: 10.5px; color: rgba(255, 255, 255, .82); }

.dk-peek { width: 11px; height: 100%; flex: none; border-left: 1px solid rgba(255, 255, 255, .28); background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.02)); }

.dk-peek:hover { background: linear-gradient(180deg, rgba(190,228,255,.34), rgba(120,185,240,.14)); }

.dk-menu { position: absolute; left: 2px; bottom: 42px; width: 348px; }

.m-glass {
    padding: 7px;
    background: linear-gradient(180deg, rgba(46, 82, 122, .92), rgba(14, 32, 54, .94));
    border: 1px solid rgba(255, 255, 255, .38);
    border-radius: 7px 7px 4px 4px;
    box-shadow: 0 0 0 1px rgba(10, 34, 62, .60), 0 18px 44px rgba(0, 0, 0, .60), inset 0 0 22px rgba(255, 255, 255, .12);
}

.m-cols { display: flex; gap: 1px; }

.m-left  { flex: 1; min-width: 0; padding: 5px; background: rgba(255, 255, 255, .96); border-radius: 3px 0 0 0; }

.m-right { width: 132px; flex: none; padding: 8px 6px; background: rgba(222, 234, 248, .95); border-radius: 0 3px 0 0; }

.m-left .app-row .at b { font-size: 11.5px; }

.m-right b { display: block; padding: 0 6px 7px; margin-bottom: 5px; font-size: 11.5px; color: #14395f; border-bottom: 1px solid rgba(20, 57, 95, .18); }

.m-right a { display: block; padding: 4px 6px; font-size: 11.5px; color: #16324f; border-radius: 3px; }

.m-right a:hover { background: #cfe4fb; }

.m-foot { display: flex; align-items: center; gap: 7px; margin-top: 7px; }

.m-search { flex: 1; min-width: 0; padding: 5px 8px; font-size: 11px; color: #8b98a5; background: #fff; border: 1px solid rgba(20, 57, 95, .35); border-radius: 3px; }

.m-off {
    padding: 6px 13px;
    font: inherit; font-size: 11.5px; color: #eaf4ff;
    background: linear-gradient(180deg, rgba(255, 255, 255, .22), rgba(255, 255, 255, .06));
    border: 1px solid rgba(255, 255, 255, .34); border-radius: 3px;
}

.m-off:hover { background: linear-gradient(180deg, rgba(255, 255, 255, .38), rgba(160, 210, 250, .18)); }

#mg-hex, #mg-pin, #mg-ports, #mg-bits, #mg-match { margin-bottom: 10px; }

.hx-b, .pt-p, .bt-b, .mt-c, .pn-k {
    font: inherit; font-size: 11.5px;
    color: hsl(0 0% 15%);
    background: linear-gradient(180deg, hsl(0 0% 99%) 0%, hsl(210 36% 96%) 45%, hsl(0 0% 91%) 46%, hsl(210 42% 95%) 100%);
    border: 1px solid hsl(0 0% 66%);
    border-radius: 4px;
    box-shadow: inset 0 1px 0 hsl(0 0% 100%);
    cursor: pointer;
}

.hx-b:hover, .pt-p:hover, .bt-b:hover, .mt-c:hover, .pn-k:hover {
    background: linear-gradient(180deg, hsl(202 60% 95%) 0%, hsl(203 60% 92%) 45%, hsl(203 60% 87%) 46%, hsl(203 60% 93%) 100%);
    border-color: hsl(203 60% 54%);
}

.hx-b:active, .pt-p:active, .bt-b:active, .mt-c:active, .pn-k:active {
    background: linear-gradient(180deg, hsl(203 60% 89%) 0%, hsl(203 60% 84%) 45%, hsl(203 60% 77%) 46%, hsl(203 60% 87%) 100%);
    border-color: hsl(204 60% 45%);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .18);
}

.hx-ask { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 11.5px; color: hsl(0 0% 25%); }

.hx-ask b { padding: 2px 8px; font-family: 'Consolas', 'Courier New', monospace; font-size: 13px; color: hsl(0 0% 100%); background: hsl(205 60% 50%); border: 1px solid hsl(205 60% 38%); border-radius: 4px; }

.hx-ask i { margin-left: auto; padding: 1px 8px; font-style: normal; font-size: 11.5px; font-weight: 600; color: hsl(0 0% 25%); background: hsl(213 36% 95%); border: 1px solid hsl(0 0% 80%); border-radius: 4px; }

.hx-grid { display: grid; grid-template-columns: repeat(var(--cols, 8), 1fr); gap: 3px; }

.hx-b { padding: 5px 0; font-family: 'Consolas', 'Courier New', monospace; letter-spacing: .5px; }

.hx-b.got { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(104 58% 60%), hsl(109 60% 38%)); border-color: hsl(108 60% 30%); }

.hx-b.bad { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(6 60% 70%), hsl(4 60% 48%)); border-color: hsl(4 60% 39%); }

.hx-b.got:hover, .hx-b.bad:hover { border-color: inherit; }

.pn-log {
    height: 84px; overflow-y: auto; margin-bottom: 8px;
    background: hsl(0 0% 100%); border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%); border-radius: 4px;
}

.pn-log::-webkit-scrollbar { width: 14px; }

.pn-log::-webkit-scrollbar-track { background: hsl(210 36% 96%); border-left: 1px solid hsl(0 0% 84%); }

.pn-log::-webkit-scrollbar-thumb { background: linear-gradient(90deg, hsl(0 0% 90%), hsl(0 0% 77%)); border: 1px solid hsl(0 0% 66%); border-radius: 4px; }

.pn-log:empty::after { content: var(--t-notries, ""); display: block; padding-top: 30px; text-align: center; font-size: 11px; color: hsl(0 0% 60%); }

.pn-r { display: flex; align-items: center; justify-content: center; padding: 3px 7px; }

.pn-r:nth-child(even) { background: hsl(210 44% 96%); }

.pn-g { display: flex; gap: 5px; }

.pn-g i {
    display: grid; place-items: center;
    width: 24px; height: 24px;
    font: 700 13px 'Consolas', 'Courier New', monospace; font-style: normal;
    border-radius: 4px;
}

.pn-g i[data-m="ok"] {
    color: hsl(0 0% 100%);
    background: linear-gradient(180deg, hsl(103 57% 51%), hsl(109 60% 38%));
    border: 2px solid hsl(108 60% 30%);
}

.pn-g i[data-m="mv"] {
    color: hsl(39 60% 15%);
    background: linear-gradient(180deg, hsl(41 60% 72%), hsl(41 60% 51%));
    border: 1px dashed hsl(41 60% 33%);
}

.pn-g i[data-m="no"] {
    color: hsl(0 0% 53%);
    background: hsl(0 0% 93%);
    border: 1px solid hsl(0 0% 83%);
}

.pn-entry { display: flex; justify-content: center; gap: 6px; margin-bottom: 8px; }

.pn-s {
    display: grid; place-items: center;
    width: 36px; height: 34px;
    font-family: 'Consolas', 'Courier New', monospace; font-size: 16px; color: hsl(0 0% 15%);
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%); border-radius: 4px;
}

.pn-s.on { border-color: hsl(203 60% 54%); box-shadow: inset 0 0 0 1px hsl(203 60% 89%); }

.pn-pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }

.pn-k { padding: 6px 0; font-size: 12.5px; font-weight: 600; }

.pn-k.wide { grid-column: span 3; padding: 5px 0; font-size: 11.5px; font-weight: 400; }

.pn-k.go { font-weight: 600; border-color: hsl(204 60% 45%); box-shadow: inset 0 0 0 1px hsl(203 60% 89%), inset 0 1px 0 hsl(0 0% 100%); }

.pt-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }

.pt-p { padding: 8px 0; font-family: 'Consolas', 'Courier New', monospace; font-size: 11.5px; color: hsl(0 0% 42%); }

.pt-p.open { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(104 58% 60%), hsl(109 60% 38%)); border-color: hsl(108 60% 30%); }

.pt-p.trap { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(6 60% 70%), hsl(4 60% 48%)); border-color: hsl(4 60% 39%); }

.bt-ask { margin-bottom: 8px; font-size: 11.5px; color: hsl(0 0% 25%); }

.bt-ask b { margin-left: 4px; padding: 2px 9px; font-size: 13px; color: hsl(0 0% 100%); background: hsl(205 60% 50%); border: 1px solid hsl(205 60% 38%); border-radius: 4px; }

.bt-row { display: flex; gap: 4px; margin-bottom: 8px; }

.bt-b { flex: 1; padding: 7px 0; }

.bt-b b { display: block; font-family: 'Consolas', 'Courier New', monospace; font-size: 15px; color: hsl(0 0% 60%); }

.bt-b span { display: block; margin-top: 1px; font-size: 9.5px; color: hsl(0 0% 60%); }

.bt-b.on { background: linear-gradient(180deg, hsl(203 60% 89%) 0%, hsl(203 60% 84%) 45%, hsl(203 60% 77%) 46%, hsl(203 60% 87%) 100%); border-color: hsl(204 60% 45%); }

.bt-b.on b { color: hsl(203 60% 19%); }

.bt-b.on span { color: hsl(203 38% 39%); }

.bt-now { font-size: 11px; color: hsl(0 0% 42%); }

.bt-now b { font-family: 'Consolas', 'Courier New', monospace; font-size: 12.5px; color: hsl(0 0% 15%); }

.mt-grid { display: grid; grid-template-columns: repeat(var(--cols, 4), 1fr); gap: 4px; }

.mt-c { position: relative; padding: 12px 0; font-size: 11px; font-weight: 600; letter-spacing: .5px; }

.mt-c span { visibility: hidden; }

.mt-c::after { content: var(--t-card, "? ?"); position: absolute; inset: 0; display: grid; place-items: center; color: hsl(0 0% 60%); letter-spacing: 3px; }

.mt-c.up span, .mt-c.got span { visibility: visible; }

.mt-c.up::after, .mt-c.got::after { content: none; }

.mt-c.up  { color: hsl(203 60% 19%); background: linear-gradient(180deg, hsl(203 60% 89%) 0%, hsl(203 60% 84%) 45%, hsl(203 60% 77%) 46%, hsl(203 60% 87%) 100%); border-color: hsl(204 60% 45%); }

.mt-c.got { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(104 58% 60%), hsl(109 60% 38%)); border-color: hsl(108 60% 30%); }

.tp-term {
    padding: 10px 11px; margin-bottom: 9px;
    font-family: 'Consolas', 'Courier New', monospace; font-size: 12.5px;
    color: hsl(0 0% 86%); background: hsl(0 0% 5%);
    border: 1px solid hsl(0 0% 51%); border-top-color: hsl(0 0% 38%);
    border-radius: 4px;
}

.tp-term .tp-path { color: hsl(0 0% 66%); }

.tp-term .tp-want { color: hsl(0 0% 95%); letter-spacing: .5px; }

.tp-typed { margin-top: 6px; word-break: break-all; }

.tp-typed b { color: hsl(120 55% 62%); font-weight: 400; }

.tp-typed s { color: hsl(5 60% 68%); text-decoration: none; background: rgba(255,107,94,.22); }

.tp-typed i { color: hsl(0 0% 86%); font-style: normal; animation: tpCaret 1s steps(1) infinite; }

@keyframes tpCaret { 50% { opacity: 0; } }

.tp-note { font-size: 11px; color: hsl(0 0% 42%); }

.sl-grid { display: grid; grid-template-columns: repeat(var(--cols, 3), 1fr); gap: 4px; }

.sl-c {
    display: grid; place-items: center;
    padding: 14px 0;
    font-family: 'Consolas', 'Courier New', monospace; font-size: 15px; font-weight: 600;
}

.sl-c.gap {
    background: hsl(0 0% 93%);
    border-color: hsl(0 0% 80%); border-top-color: hsl(0 0% 71%);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, .12);
    cursor: default;
}

.sl-c.ok { color: hsl(108 60% 30%); }

.df-legend { margin-bottom: 8px; font-size: 11px; color: hsl(0 0% 42%); }

.df-row { display: grid; grid-template-columns: repeat(var(--cols, 8), 1fr); gap: 3px; margin-bottom: 9px; }

.df-b {
    display: grid; place-items: center;
    padding: 16px 0;
    font-family: 'Consolas', 'Courier New', monospace; font-size: 12px;
}

.df-b.a { background: linear-gradient(180deg, hsl(203 60% 89%), hsl(203 60% 77%)); border-color: hsl(203 60% 56%); }

.df-b.b { background: linear-gradient(180deg, hsl(100 55% 87%), hsl(100 50% 70%)); border-color: hsl(102 36% 48%); }

.df-b.c { background: linear-gradient(180deg, hsl(35 60% 86%), hsl(36 60% 72%)); border-color: hsl(35 60% 53%); }

.df-b.sel { outline: 2px solid hsl(205 60% 50%); outline-offset: -2px; }

.df-b.set { opacity: .55; cursor: default; }

.mn-grid { display: grid; grid-template-columns: repeat(var(--cols, 6), 1fr); gap: 2px; }

.mn-c {
    display: grid; place-items: center;
    padding: 0; height: 30px;
    font-family: 'Consolas', 'Courier New', monospace; font-size: 13px; font-weight: 700;
}

.mn-c.up {
    background: hsl(213 36% 95%);
    border-color: hsl(0 0% 80%); border-top-color: hsl(0 0% 71%);
    box-shadow: inset 1px 1px 2px rgba(0, 0, 0, .10);
    cursor: default;
}

.mn-c.n1 { color: hsl(223 60% 46%); }

.mn-c.n2 { color: hsl(108 60% 30%); }

.mn-c.n3 { color: hsl(4 60% 48%); }

.mn-c.n4 { color: hsl(231 60% 28%); }

.mn-c.n5 { color: hsl(0 60% 28%); }

.mn-c.n6 { color: hsl(180 60% 29%); }

.mn-c.n0 { color: transparent; }

.mn-c.boom { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(6 60% 70%), hsl(4 60% 48%)); border-color: hsl(4 60% 39%); }

.mn-info { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 11px; color: hsl(0 0% 42%); }

.mn-info b { color: hsl(0 0% 15%); }

.dk-tip {
    position: absolute; right: 12px; bottom: 52px; z-index: 3;
    width: 246px; padding: 10px 11px 11px;
    color: #1a2733;
    background: linear-gradient(180deg, #ffffff, #eef4fa);
    border: 1px solid #7c8b99;
    border-radius: 4px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .45);
    animation: tipIn 200ms cubic-bezier(.23, 1, .32, 1) both;
}

.dk-tip::after, .dk-tip::before {
    content: ''; position: absolute; right: 26px; top: 100%;
    border: 9px solid transparent; border-bottom: 0;
}

.dk-tip::before { border-top-color: #7c8b99; }

.dk-tip::after  { border-top-color: #eef4fa; margin-top: -1px; }

.dk-tip b { display: block; padding-right: 16px; margin-bottom: 3px; font-size: 12px; }

.dk-tip span { display: block; padding-right: 4px; font-size: 11px; color: #4a5a68; }

.dk-tip .ti { float: left; margin: 1px 8px 0 0; font-size: 15px; color: #2a8dd4; }

.dk-tip .tx {
    position: absolute; right: 4px; top: 3px;
    width: 17px; height: 15px;
    display: grid; place-items: center;
    font: inherit; font-size: 10px; color: #4a5a68;
    background: none; border: 1px solid transparent; border-radius: 2px;
    cursor: pointer;
}

.dk-tip .tx:hover { background: #fdd; border-color: #c9372c; color: #c9372c; }

@keyframes tipIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

#dk-boot {
    position: fixed; inset: 0; z-index: 70;
    display: grid; place-items: center;
    background: #000;
}

#dk-boot.out { animation: bootOut 420ms ease-in both; }

@keyframes bootOut {
    from { opacity: 1; }
    to   { opacity: 0; }
}

.bt-scr {
    width: 480px; max-width: 86vw;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 12.5px; line-height: 1.65;
    color: #c8c8c8;
}

.bt-go { margin-top: 18px; }

.bt-go p { margin-bottom: 9px; color: #e8e8e8; }

.bt-go .xp-bar { margin: 0; background: #101010; border-color: #3a3a3a; border-top-color: #2a2a2a; }

@keyframes btCaret { 50% { opacity: 0; } }

#mg-rings, #mg-power, #mg-sig, #mg-sort, #mg-latin { margin-bottom: 10px; }

.rg-box { position: relative; width: 230px; height: 230px; margin: 0 auto 10px; }

.rg-notch {
    position: absolute; left: 50%; top: -4px; z-index: 2;
    width: 0; height: 0; margin-left: -8px;
    border: 8px solid transparent; border-top: 12px solid hsl(4 60% 48%);
}

.rg-r {
    position: absolute; inset: calc(var(--k) * 30px);
    border: 3px solid hsl(0 0% 68%); border-radius: 50%;
    background: radial-gradient(circle at 50% 30%, hsl(0 0% 100%), hsl(213 36% 95%));
}

.rg-mark {
    position: absolute; left: 50%; top: -7px;
    width: 12px; height: 12px; margin-left: -6px;
    background: hsl(205 60% 50%); border: 1px solid hsl(205 60% 38%); border-radius: 4px;
}

.rg-r.set { border-color: hsl(109 60% 38%); background: radial-gradient(circle at 50% 30%, hsl(0 0% 100%), hsl(101 52% 92%)); }
.rg-r.set .rg-mark { background: hsl(109 60% 38%); border-color: hsl(108 60% 30%); }

.rg-info { text-align: center; font-size: 11.5px; color: hsl(0 0% 25%); }
.rg-info b { color: hsl(205 60% 50%); }

.pw-info { margin-bottom: 8px; font-size: 11.5px; color: hsl(0 0% 25%); }
.pw-info b { color: hsl(205 60% 50%); }

.pw-grid { display: grid; grid-template-columns: repeat(var(--cols, 4), 1fr); gap: 5px; }

.pw-c {
    height: var(--cell, 54px);
    background: linear-gradient(180deg, hsl(210 37% 97%), hsl(0 0% 90%));
    border: 1px solid hsl(0 0% 66%); border-radius: 4px;
    cursor: pointer;
}

.pw-c.on {
    background: linear-gradient(180deg, hsl(45 60% 83%), hsl(44 60% 60%));
    border-color: hsl(43 60% 45%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 0 10px rgba(245, 195, 60, .55);
}

.sg-reads { margin-bottom: 9px; }
.sg-p { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; font-size: 11px; color: hsl(0 0% 42%); }
.sg-p span { min-width: 66px; }
.sg-bar { flex: 1; height: 10px; background: linear-gradient(180deg, hsl(0 0% 85%), hsl(0 0% 93%)); border: 1px solid hsl(0 0% 66%); border-radius: 4px; overflow: hidden; }
.sg-bar i { display: block; height: 100%; background: linear-gradient(180deg, hsl(200 60% 79%), hsl(205 60% 50%)); }
.sg-p b { min-width: 34px; text-align: right; color: hsl(0 0% 15%); font-family: 'Consolas', monospace; }

.sg-grid { display: grid; grid-template-columns: repeat(var(--cols, 6), 1fr); gap: 3px; }

.sg-c {
    height: var(--cell, 40px);
    font: inherit; font-size: 11px; font-family: 'Consolas', monospace; color: hsl(0 0% 53%);
    background: linear-gradient(180deg, hsl(0 0% 99%), hsl(210 42% 95%));
    border: 1px solid hsl(0 0% 66%); border-radius: 4px; cursor: pointer;
}

.sg-c:hover { border-color: hsl(203 60% 54%); }
.sg-c.probe { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(201 60% 71%), hsl(205 60% 50%)); border-color: hsl(205 60% 38%); font-weight: 700; cursor: default; }
.sg-c.bad   { color: hsl(4 60% 39%); background: hsl(5 60% 94%); border-color: hsl(5 52% 75%); }
.sg-c.hit   { color: hsl(0 0% 100%); background: linear-gradient(180deg, hsl(104 58% 60%), hsl(109 60% 38%)); border-color: hsl(108 60% 30%); }

.so-row { display: flex; justify-content: center; gap: 10px; margin-bottom: 10px; }

.so-t {
    display: flex; flex-direction: column; justify-content: flex-end; gap: 4px;
    width: 52px; padding: 6px;
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
    cursor: pointer;
}

.so-t:hover { border-color: hsl(203 60% 54%); }
.so-t.sel { border-color: hsl(204 60% 45%); box-shadow: inset 0 0 0 2px hsl(203 60% 89%); }

.so-p, .so-e { display: block; height: 26px; border-radius: 4px; }

.so-p {
    background: linear-gradient(180deg,
        hsl(var(--h) 72% 62%), hsl(var(--h) 72% 44%));
    border: 1px solid hsl(var(--h) 60% 34%);
    box-shadow: inset 0 1px 0 hsl(var(--h) 80% 78%);
}

.so-p.up { transform: translateY(-7px); box-shadow: inset 0 1px 0 hsl(var(--h) 80% 78%), 0 3px 6px rgba(0,0,0,.3); }

.so-e { background: hsl(213 36% 95%); border: 1px dashed hsl(0 0% 80%); }

.so-note { font-size: 11px; color: hsl(0 0% 42%); }
.so-note b { color: hsl(0 0% 15%); }

.la-grid { display: grid; grid-template-columns: repeat(var(--cols, 4), 1fr); gap: 5px; margin-bottom: 9px; }

.la-c {
    position: relative;
    height: var(--cell, 62px);
    background: linear-gradient(180deg, hsl(var(--h) 72% 62%), hsl(var(--h) 72% 44%));
    border: 1px solid hsl(var(--h) 60% 34%);
    border-radius: 4px;
    cursor: pointer;
}

.la-c.empty { background: hsl(0 0% 100%); border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%); }
.la-c.empty:hover { border-color: hsl(203 60% 54%); }

.la-c.fix { cursor: default; }
.la-c.fix::after {
    content: ''; position: absolute; inset: 0;
    background: repeating-linear-gradient(45deg, rgba(255,255,255,.22) 0 5px, transparent 5px 10px);
    border-radius: 4px;
}

.la-lock { position: absolute; right: 4px; bottom: 3px; width: 8px; height: 7px; border-radius: 4px;
           background: rgba(255,255,255,.85); box-shadow: 0 -3px 0 -1px rgba(255,255,255,.85); }

.la-note { font-size: 11px; color: hsl(0 0% 42%); }

#mg-gates {
    display: block; width: 100%; margin: 4px 0;
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
}

#fit {
    position: fixed; left: 0; top: 0;
    width: 1024px; height: 576px;
    transform-origin: 0 0;
    transform: scale(var(--k, 1)) translate(var(--fx, 0px), var(--fy, 0px));
}

#fit > #desk, #fit > #mg, #fit > #dk-boot { position: absolute; }

#cur-layer {
    position: absolute; inset: 0;
    z-index: 9000;
    pointer-events: none;
}

.cur { position: absolute; left: 0; top: 0; }

body.drive, body.drive * { cursor: none !important; }

.cur > i {
    position: absolute; left: 0; top: 0;
    width: 0; height: 0;
    border-left: 4px solid hsl(var(--h, 200) 85% 55%);
    border-right: 4px solid transparent;
    border-bottom: 7px solid transparent;
    border-top: 7px solid hsl(var(--h, 200) 85% 55%);
    filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .6));
    transform: rotate(-14deg);
}

.cur > b {
    position: absolute; left: 9px; top: 9px;
    padding: 0 4px;
    font: 600 9px/1.6 'Segoe UI', sans-serif;
    color: #fff; white-space: nowrap;
    background: hsl(var(--h, 200) 70% 38% / .92);
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .5);
}

#dk-off {
    position: fixed; inset: 0; z-index: 200;
    background: #000;
    overflow: hidden;
}

#dk-off.off { display: none; }

#dk-off .bsod {
    position: absolute; inset: 0;
    display: flex; flex-direction: column; justify-content: center;
    padding: 0 8%;
    background: #0a2a8f;
    font-family: 'Consolas', 'Lucida Console', monospace;
    font-size: 12px; line-height: 1.7; color: #e6ecff;
}

#dk-off .bsod b { font-size: 15px; display: block; margin-bottom: 14px; }
#dk-off .bsod i { font-style: normal; opacity: .75; }
#dk-off .bsod .stop { margin-top: 16px; letter-spacing: .5px; }

#dk-off .bsod { animation: bsodIn 90ms steps(2) both; }

@keyframes bsodIn {
    from { opacity: 0; transform: scaleY(.9); }
    to   { opacity: 1; transform: scaleY(1); }
}

#dk-off .bye {
    position: absolute; inset: 0;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 18px;
    background: radial-gradient(120% 90% at 50% 45%, #1b3a63, #0a1626 70%, #050a12);
    color: #dbe7f5;
    font: 300 19px 'Segoe UI', sans-serif;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .6);
}

#dk-off .ring {
    width: 34px; height: 34px;
    border: 3px solid rgba(255, 255, 255, .18);
    border-top-color: rgba(255, 255, 255, .85);
    border-radius: 50%;
    animation: ringSpin 900ms linear infinite;
}

@keyframes ringSpin { to { transform: rotate(360deg); } }

#dk-off .crt {
    position: absolute; left: 0; top: 50%;
    width: 100%; height: 3px; margin-top: -1.5px;
    background: #dceaff;
    box-shadow: 0 0 14px 4px rgba(190, 220, 255, .75);
    opacity: 0;
    transform-origin: 50% 50%;
}

#dk-off.dead .bsod,
#dk-off.dead .bye { animation: crtFold 240ms ease-in both; }

#dk-off.dead .crt { animation: crtLine 520ms linear both; }

@keyframes crtFold {
    from { transform: scaleY(1);   filter: brightness(1); }
    60%  { transform: scaleY(.06); filter: brightness(2.4); }
    to   { transform: scaleY(.01); filter: brightness(3); opacity: 0; }
}

@keyframes crtLine {
    0%   { opacity: 0; transform: scaleX(1); }
    18%  { opacity: 1; transform: scaleX(1); }
    55%  { opacity: 1; transform: scaleX(1); }
    88%  { opacity: 1; transform: scaleX(.015); }
    to   { opacity: 0; transform: scaleX(.015); }
}

#mg-nono, #mg-lock, #mg-chain { margin-bottom: 10px; }

.nn-wrap {
    display: grid;
    grid-template-columns: auto repeat(var(--n), 30px);
    gap: 2px;
    justify-content: center;
}

.nn-top {
    display: flex; flex-direction: column; justify-content: flex-end;
    font: 600 10px/1.15 'Segoe UI', sans-serif;
    color: hsl(0 0% 35%); text-align: center;
    min-height: 34px;
}

.nn-side {
    display: flex; align-items: center; justify-content: flex-end;
    padding-right: 6px;
    font: 600 11px 'Segoe UI', sans-serif;
    color: hsl(0 0% 35%); white-space: nowrap;
}

.nn-c {
    aspect-ratio: 1;
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
    cursor: pointer;
    position: relative;
}

.nn-c:hover { background: hsl(210 55% 96%); }

.nn-c[data-v="1"] { background: linear-gradient(180deg, hsl(0 0% 44%), hsl(0 0% 32%)); border-color: hsl(0 0% 25%); }

.nn-c[data-v="2"]::after {
    content: '\00d7';
    position: absolute; inset: 0;
    display: grid; place-items: center;
    font: 700 13px 'Segoe UI', sans-serif;
    color: hsl(0 0% 75%);
}

.lk-facts {
    margin: 0 0 12px; padding: 10px 12px 10px 26px;
    background: hsl(207 53% 97%);
    border: 1px solid hsl(209 35% 86%); border-radius: 4px;
    font: 12.5px/1.75 'Segoe UI', sans-serif;
    color: hsl(208 35% 22%);
}

.lk-facts b { color: hsl(204 60% 28%); }

.lk-slots { display: flex; justify-content: center; gap: 10px; margin-bottom: 12px; }

.lk-s {
    width: 40px; height: 46px;
    display: grid; place-items: center;
    font: 700 22px 'Consolas', monospace; font-style: normal;
    color: hsl(204 60% 28%); background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 66%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
}

.lk-pad {
    display: grid; grid-template-columns: repeat(9, 1fr); gap: 4px;
    max-width: 420px; margin: 0 auto;
}

.lk-d {
    padding: 9px 0;
    font: 600 14px 'Segoe UI', sans-serif;
    color: hsl(0 0% 15%);
    background: linear-gradient(180deg, hsl(0 0% 99%), hsl(0 0% 93%));
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 85%);
    border-radius: 4px; cursor: pointer;
}

.lk-d:hover { background: linear-gradient(180deg, hsl(208 60% 97%), hsl(208 60% 91%)); border-color: hsl(205 60% 66%); }

.ch-note { margin: 0 0 12px; text-align: center; font: 12.5px 'Segoe UI', sans-serif; color: hsl(0 0% 35%); }

.ch-note b { color: hsl(204 60% 28%); }

.ch-grid {
    display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px;
    max-width: 460px; margin: 0 auto 14px;
}

.ch-s {
    aspect-ratio: 1;
    display: grid; place-items: center;
    font-size: 22px; color: hsl(0 0% 35%);
    background: linear-gradient(180deg, hsl(0 0% 99%), hsl(0 0% 93%));
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 85%);
    border-radius: 4px; cursor: pointer;
}

.ch-s.lit {
    color: hsl(0 0% 100%);
    background: linear-gradient(180deg, hsl(204 60% 71%), hsl(204 60% 50%));
    border-color: hsl(204 60% 37%);
    box-shadow: 0 0 10px rgba(60, 150, 220, .7);
}

#mg-chain[data-phase="show"] .ch-s { cursor: default; }

#mg-chain[data-phase="in"] .ch-s:hover {
    background: linear-gradient(180deg, hsl(208 60% 97%), hsl(208 60% 91%));
    border-color: hsl(205 60% 66%);
}

.ch-dots { display: flex; justify-content: center; gap: 5px; }

.ch-dots i {
    width: 9px; height: 9px; border-radius: 50%;
    background: hsl(0 0% 85%); border: 1px solid hsl(0 0% 75%);
}

.ch-dots i.on { background: hsl(104 60% 40%); border-color: hsl(108 60% 30%); }

#mg-proc {
    display: flex; gap: 14px; align-items: flex-start;
    justify-content: center;
    margin-bottom: 10px;
}

#mg-proc.off { display: none; }

#mg-proc-map {
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
    flex: none;
}

.pr-side { flex: 1; max-width: 260px; }

.pr-cap {
    font: 12px 'Segoe UI', sans-serif; color: hsl(0 0% 35%);
    margin-bottom: 6px;
}

.pr-cap b { color: hsl(204 60% 28%); }

.pr-prog {
    background: hsl(210 50% 98%);
    border: 1px solid hsl(209 35% 86%); border-radius: 4px;
    padding: 8px; margin-bottom: 10px;
    min-height: 96px;
}

.pr-list { display: flex; flex-wrap: wrap; gap: 4px; }

.pr-i {
    width: 22px; height: 22px;
    display: grid; place-items: center;
    font: 13px/1 'Segoe UI', sans-serif; font-style: normal;
    color: hsl(208 35% 22%); background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-radius: 4px;
}

.pr-i.now {
    color: hsl(0 0% 100%); background: hsl(204 60% 50%); border-color: hsl(204 60% 37%);
    box-shadow: 0 0 6px rgba(60, 150, 220, .6);
}

.pr-pad { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }

.pr-b {
    padding: 9px 0;
    font: 600 15px 'Segoe UI', sans-serif;
    color: hsl(0 0% 15%);
    background: linear-gradient(180deg, hsl(0 0% 99%), hsl(0 0% 93%));
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 85%);
    border-radius: 4px; cursor: pointer;
}

.pr-b:hover { background: linear-gradient(180deg, hsl(208 60% 97%), hsl(208 60% 91%)); border-color: hsl(205 60% 66%); }

.pr-b.wide { grid-column: span 2; font-size: 12px; }

.pr-b.go {
    grid-column: span 2;
    font-size: 12px; font-weight: 700; color: hsl(128 53% 17%);
    background: linear-gradient(180deg, hsl(97 60% 87%), hsl(99 51% 67%));
    border-color: hsl(102 36% 48%);
}

.pr-b.go:hover { background: linear-gradient(180deg, hsl(97 60% 92%), hsl(98 58% 73%)); }

:root.nui #fit { transform: none; width: 100%; height: 100%; }

.tp-line { opacity: .4; }
.tp-line[data-s="now"] { opacity: 1; }
.tp-line[data-s="done"] { opacity: .35; text-decoration: line-through; }
.tp-line[data-s="done"] .tp-want { color: hsl(109 60% 38%); }

#mg-beat, #mg-flap {
    display: block; width: 100%; margin: 4px 0;
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
}

#mg-beat.off, #mg-wheel.off, #mg-flap.off, #mg-term.off { display: none; }

#mg-term {
    display: flex; flex-direction: column; gap: 7px;
    margin-bottom: 8px;
    padding: 9px 10px;
    font-family: 'Consolas', 'Courier New', monospace;
    color: hsl(131 60% 57%); background: hsl(127 39% 5%);
    border: 1px solid hsl(0 0% 51%); border-top-color: hsl(0 0% 38%);
    border-radius: 4px;
    text-shadow: 0 0 6px rgba(60, 230, 90, .35);
}

.tm-head {
    display: flex; flex-direction: column; gap: 1px;
    font-size: 12px; line-height: 1.35;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(60, 230, 90, .22);
}

.tm-head b { font-weight: 400; letter-spacing: .6px; }
.tm-head span { opacity: .75; }
.tm-head i { font-style: normal; color: hsl(45 60% 65%); text-shadow: 0 0 6px rgba(255, 211, 77, .35); }

.tm-body { display: flex; gap: 12px; align-items: flex-start; }

.tm-cols { display: flex; gap: 14px; flex: none; }

.tm-col { display: flex; flex-direction: column; }

.tm-row { font-size: 12px; line-height: 1.3; white-space: pre; }

.tm-adr { opacity: .55; margin-right: 7px; }

.tm-ln b {
    font-weight: 400; cursor: pointer;
    padding: 0 1px; margin: 0 -1px;
}

.tm-ln b:hover { color: hsl(127 39% 5%); background: hsl(131 60% 57%); }

.tm-ln b.used { opacity: .38; cursor: default; }
.tm-ln b.used:hover { color: inherit; background: none; }
.tm-ln b.used[data-like]::after { content: " [" attr(data-like) "]"; opacity: .8; }

.tm-ln b.ok { color: hsl(127 39% 5%); background: hsl(131 60% 57%); opacity: 1; }

.tm-log {
    flex: 1; min-width: 0;
    display: flex; flex-direction: column; justify-content: flex-end;
    font-size: 12.5px; line-height: 1.32;
    max-height: 250px; overflow: hidden;
    word-break: break-all;
}

.tm-log .me { color: hsl(137 60% 96%); }
.tm-log .no { color: hsl(5 60% 68%); text-shadow: 0 0 6px rgba(255, 107, 94, .3); }
.tm-log .ok { color: hsl(45 60% 65%); text-shadow: 0 0 6px rgba(255, 211, 77, .35); }

#mg-wheel {
    display: block; margin: 4px auto;
    max-width: 100%;
    background: hsl(0 0% 100%);
    border: 1px solid hsl(0 0% 68%); border-top-color: hsl(0 0% 54%);
    border-radius: 4px;
}

.mg-go {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 9px;
    min-height: 240px;
    padding: 26px 20px 30px;
    text-align: center;
}

.mg-go.off { display: none; }

.mg-go .go-ico {
    font-size: 30px; color: hsl(207 60% 47%);
    margin-bottom: 2px;
}

.mg-go b {
    font: 600 17px 'Segoe UI', sans-serif; color: hsl(208 60% 22%);
}

.mg-go p {
    max-width: 420px;
    font: 13px 'Segoe UI', sans-serif; color: hsl(0 0% 35%); line-height: 1.45;
    margin: 0;
}

.mg-go .go-note {
    font: 11px 'Segoe UI', sans-serif; color: hsl(0 0% 58%);
}

.win7 {
    padding: 7px 22px;
    font: 13px 'Segoe UI', sans-serif; color: hsl(0 0% 16%);
    background: linear-gradient(180deg, hsl(207 60% 97%) 0%, hsl(209 60% 93%) 49%, hsl(206 55% 89%) 51%, hsl(207 60% 94%) 100%);
    border: 1px solid hsl(0 0% 65%); border-radius: 4px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.75), 0 1px 1px rgba(0,0,0,.06);
    cursor: pointer;
}

.win7:hover {
    background: linear-gradient(180deg, hsl(206 60% 96%) 0%, hsl(204 60% 91%) 49%, hsl(205 60% 86%) 51%, hsl(204 60% 93%) 100%);
    border-color: hsl(203 60% 54%);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.85), 0 0 6px rgba(60,157,216,.45);
}

.win7:active {
    background: linear-gradient(180deg, hsl(206 57% 88%) 0%, hsl(206 52% 83%) 49%, hsl(207 49% 79%) 51%, hsl(206 59% 86%) 100%);
    box-shadow: inset 0 1px 3px rgba(0,0,0,.16);
}

.win7.go {
    margin-top: 4px;
    padding: 9px 30px;
    font-size: 14px; font-weight: 600;
}

#dk-idle {
    position: fixed; inset: 0; z-index: 68;
    display: grid; place-items: center;
    background: #05070a;
}

#dk-idle.off { display: none; }

.id-scr { display: flex; flex-direction: column; align-items: center; gap: 14px; }

.id-scr .xp-bar {
    width: 210px;
    background: #0d1117; border-color: #33404d; border-top-color: #232d38;
}

.id-scr p {
    margin: 0;
    font: 12px 'Segoe UI', sans-serif; color: #6a7b8c; letter-spacing: .4px;
}

/* =============================================================================
   SKORA OKNA PROBY

   Jeden system z dwoch, ktore w 2010 wygladaly podobniej, niz sie wtedy
   wydawalo: chrom i swiatlo z Mac OS X, uklad i logika okna z Windows 7.

   Stad neutralnie szara belka zamiast niebieskiej, trzy okragle przyciski po
   lewej, biale plansze na cienkich kreskach, jeden blekit jako akcent i
   pigulkowe paski postepu. Zadnych pasow i ostrych rogow - to nie jest
   System 7, tylko sprzet z konca tamtej dekady.

   Dotyczy WYLACZNIE okna minigry (#mg). Pulpit, pasek zadan, rozruch i ekran
   czuwania zostaja przy swoim wygladzie.
   ========================================================================== */

#mg {
    --frame: #6e6e6e;
    --edge:  #c2c2c2;
    --panel: #ffffff;
    --txt:   #2b2b2b;
    --dim:   #808080;
    --acc:   #2f7fd6;
    --acc2:  #1a63b8;
}

#mg .mg-box {
    width: 566px;
    padding: 0;
    font: 400 12px/1.4 'Chop', 'Rubik', 'Segoe UI', 'Lucida Grande', sans-serif;
    color: var(--txt);
    background: linear-gradient(180deg, #f6f6f6 0%, #e9e9e9 100%);
    border: 1px solid var(--frame);
    border-radius: 7px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .85),
        0 1px 3px rgba(0, 0, 0, .3),
        0 20px 48px rgba(0, 0, 0, .52);
}

#mg[data-s="win"] .mg-box {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .85),
        0 0 0 1px rgba(63, 154, 68, .85),
        0 0 26px rgba(63, 154, 68, .40),
        0 20px 48px rgba(0, 0, 0, .52);
}

#mg[data-s="lose"] .mg-box,
#mg[data-s="miss"] .mg-box {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .85),
        0 0 0 1px rgba(207, 68, 54, .85),
        0 0 26px rgba(207, 68, 54, .40),
        0 20px 48px rgba(0, 0, 0, .52);
}

/* --- belka: jednolity chrom, tytul na srodku --- */

#mg .mg-box header {
    position: relative;
    height: 27px;
    gap: 7px;
    padding: 0 13px 0 9px;
    background: linear-gradient(180deg, #f8f8f8 0%, #e6e6e6 48%, #dedede 52%, #d4d4d4 100%);
    border-bottom: 1px solid #a6a6a6;
    border-radius: 6px 6px 0 0;
}

#mg .mg-box header b {
    position: absolute; left: 0; right: 0;
    padding: 0 112px;
    font: 600 12px/27px 'Chop', 'Rubik', 'Segoe UI', 'Lucida Grande', sans-serif;
    text-align: center;
    color: #3c3c3c;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
    pointer-events: none;
}

#mg .mg-ico {
    position: relative; z-index: 1;
    font-size: 11px;
    color: #6a6a6a;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg #mg-state {
    position: relative; z-index: 1;
    margin-left: auto;
    font: 600 10.5px/27px 'Chop', 'Rubik', 'Segoe UI', sans-serif;
    letter-spacing: .04em;
    color: #5f5f5f;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg #mg-state[data-z="green"]  { color: #2e7d32; }
#mg #mg-state[data-z="red"]    { color: #c0392b; }
#mg #mg-state[data-z="orange"] { color: #b07d10; }

/* --- trzy lampki po lewej --- */

#mg .mg-wb {
    order: -1;
    z-index: 1;
    align-self: center;
    gap: 8px;
    margin-right: 2px;
}

#mg .mg-wb .win-btn {
    width: 12px; height: 12px;
    padding: 0;
    font-size: 0;
    border: 1px solid rgba(0, 0, 0, .32);
    border-radius: 50%;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55);
    opacity: 1;
}

#mg .mg-wb .win-btn i { display: none; }

#mg .mg-wb .win-btn.x { order: 0; background: radial-gradient(circle at 50% 32%, #ff8f85, #e5493c); }
#mg .mg-wb .win-btn.dead { order: 1; background: radial-gradient(circle at 50% 32%, #ffd98a, #e0a92a); }
#mg .mg-wb .win-btn.dead + .win-btn.dead { order: 2; background: radial-gradient(circle at 50% 32%, #a8e88f, #45a83b); }

#mg .mg-wb .win-btn.x:hover { background: radial-gradient(circle at 50% 32%, #ffaba2, #d13a2d); }
#mg .mg-wb .win-btn.dead:hover { background: radial-gradient(circle at 50% 32%, #ffd98a, #e0a92a); }

/* --- korpus --- */

#mg .mg-body {
    padding: 0;
    color: var(--txt);
    background: linear-gradient(180deg, #ededed 0%, #e4e4e4 100%);
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, .70);
    border-radius: 0 0 6px 6px;
    box-shadow: none;
}

#mg .mg-hint {
    margin: 10px 11px 0;
    padding: 7px 10px;
    font-size: 11.5px; line-height: 1.45;
    color: #33546f;
    background: linear-gradient(180deg, #f3f8fd, #e8f1fa);
    border: 1px solid #c4d8ea;
    border-radius: 5px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .80);
}

#mg .mg-panel {
    margin: 10px 11px;
    padding: 13px;
    color: var(--txt);
    background: var(--panel);
    border: 1px solid var(--edge);
    border-radius: 5px;
    box-shadow: inset 0 1px 0 #fff, 0 1px 2px rgba(0, 0, 0, .05);
}

#mg .mg-load { padding: 20px 14px 26px; }
#mg .mg-load p { color: var(--txt); }
#mg .mg-load-sub { color: var(--dim); }

/* --- paski: pigulka z polyskiem --- */

#mg .xp-bar,
#mg .mg-bars .bar {
    background: linear-gradient(180deg, #d8d8d8, #e8e8e8);
    border: 1px solid #adadad;
    border-radius: 6px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .16);
    overflow: hidden;
}

#mg .xp-bar i,
#mg .mg-bars i {
    background: linear-gradient(180deg, #8cc4f0 0%, #3d8ada 48%, #2a76c8 52%, #5aa4e6 100%);
    border-radius: 5px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45);
}

#mg #mg-strain.warn { background: linear-gradient(180deg, #ffd98a 0%, #e0a92a 48%, #cf9a1c 52%, #f0c45e 100%); }
#mg #mg-strain.low  { background: linear-gradient(180deg, #ff9c92 0%, #d94b3d 48%, #c73e31 52%, #ef7a6d 100%); }

#mg .mg-pips i {
    background: linear-gradient(180deg, #dcdcdc, #ececec);
    border: 1px solid #b4b4b4;
    border-radius: 3px;
}

#mg .mg-pips i.on {
    background: linear-gradient(180deg, #8ddc8a, #3f9a44);
    border-color: #2f7d33;
}

/* --- klawisze --- */

#mg .mg-keys .k {
    padding: 0 11px;
    font: 600 10.5px/26px 'Chop', 'Rubik', 'Segoe UI', sans-serif;
    letter-spacing: .05em;
    color: #3c3c3c;
    background: linear-gradient(180deg, #ffffff, #e8e8e8);
    border: 1px solid #b0b0b0;
    border-radius: 5px;
    box-shadow: inset 0 1px 0 #fff, 0 1px 1px rgba(0, 0, 0, .10);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg .mg-keys .k.on {
    color: #fff;
    background: linear-gradient(180deg, #5aa4e6, #2a76c8);
    border-color: var(--acc2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35);
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
}

#mg .mg-keys .sep { background: #c6c6c6; }

#mg .mg-foot {
    padding: 0 12px 11px;
    font: 400 10.5px/1 'Chop', 'Rubik', 'Segoe UI', sans-serif;
    color: var(--dim);
    background: transparent;
    border-top: 0;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .8);
}

#mg #mg-miss.hot { color: #c0392b; }

/* --- ekran startowy --- */

#mg .mg-go { padding: 28px 22px 32px; gap: 10px; }

#mg .mg-go .go-ico {
    font-size: 27px;
    color: var(--acc);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg .mg-go b {
    font: 600 16px 'Chop', 'Rubik', 'Segoe UI', 'Lucida Grande', sans-serif;
    color: #2f2f2f;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg .mg-go p { color: #5c5c5c; font-size: 12px; }
#mg .mg-go .go-note { color: var(--dim); }

/* --- przyciski --- */

#mg .win7 {
    padding: 5px 18px;
    font: 500 12px 'Chop', 'Rubik', 'Segoe UI', sans-serif;
    color: #333;
    background: linear-gradient(180deg, #ffffff, #ebebeb);
    border: 1px solid #ababab;
    border-radius: 5px;
    box-shadow: inset 0 1px 0 #fff, 0 1px 1px rgba(0, 0, 0, .10);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

#mg .win7:hover  { border-color: #7fb0dd; background: linear-gradient(180deg, #ffffff, #f2f7fc); }
#mg .win7:active { background: linear-gradient(180deg, #dcdcdc, #ececec); box-shadow: inset 0 1px 3px rgba(0, 0, 0, .20); }

/* przycisk domyslny - jedyny mocny kolor w calym oknie */
#mg .win7.go {
    margin: 8px 0 2px;
    padding: 8px 30px;
    font-size: 13px; font-weight: 600;
    color: #fff;
    background: linear-gradient(180deg, #6fb2ea 0%, #2f7fd6 48%, #2372c9 52%, #4f9ae2 100%);
    border-color: #1a5da8;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 1px 2px rgba(0, 0, 0, .22);
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .28);
}

#mg .win7.go:hover  { background: linear-gradient(180deg, #86c0ef 0%, #3c8cdf 48%, #2f7fd6 52%, #63a8e8 100%); border-color: #1a5da8; }
#mg .win7.go:active { background: linear-gradient(180deg, #2372c9, #4f9ae2); box-shadow: inset 0 1px 4px rgba(0, 0, 0, .30); }

/* =============================================================================
   PULPIT

   Ten sam system, co okno proby: neutralny chrom zamiast niebieskiego szkla,
   miekkie zaokraglenia, jeden blekit jako akcent. Tapeta schodzi glebiej i
   ciszej, zeby okna mialy na czym stanac, a caly detal siedzi tam, gdzie oko
   naprawde patrzy: w ikonach, na pasku i w zegarze.
   ========================================================================== */

.dk-wall {
    background:
        radial-gradient(120% 82% at 50% 118%, rgba(126, 196, 240, .34), rgba(30, 104, 170, .16) 42%, transparent 66%),
        radial-gradient(44% 32% at 50% 106%, rgba(255, 255, 255, .26), transparent 74%),
        linear-gradient(176deg, #0b1622 0%, #10283a 38%, #143349 70%, #0a1a28 100%);
}

/* winieta - bez niej rogi ekranu sa jasniejsze niz srodek */
.dk-wall::after {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(78% 62% at 50% 46%, transparent 40%, rgba(0, 0, 0, .34) 100%);
    pointer-events: none;
}

.dk-wall .rays { opacity: .20; }

/* --- ikony --- */

.dk-icons { top: 10px; left: 10px; gap: 2px; }

.dk-ico {
    width: 84px; padding: 7px 4px 6px;
    border: 1px solid transparent;
    border-radius: 4px;
    pointer-events: auto;
    transition: background 120ms var(--e), border-color 120ms var(--e);
}

.dk-ico:hover {
    background: linear-gradient(180deg, rgba(160, 210, 250, .22), rgba(110, 170, 225, .14));
    border-color: rgba(180, 220, 252, .38);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22);
}

.dk-ico:active {
    background: linear-gradient(180deg, rgba(120, 180, 235, .30), rgba(80, 140, 205, .20));
    border-color: rgba(160, 205, 245, .50);
}

.dk-ico .gi svg { filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .6)); }

.dk-ico span {
    font-size: 11px; letter-spacing: .01em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .9), 0 0 6px rgba(0, 0, 0, .6);
}

/* --- okna pulpitu: ten sam chrom, co okno proby --- */

.win {
    padding: 0;
    background: linear-gradient(180deg, #f6f6f6 0%, #e9e9e9 100%);
    border: 1px solid #6e6e6e;
    border-radius: 7px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .85),
        0 1px 3px rgba(0, 0, 0, .3),
        0 18px 42px rgba(0, 0, 0, .48);
}

.win:not(.on) {
    background: linear-gradient(180deg, #f1f1f1 0%, #e6e6e6 100%);
    border-color: #8d8d8d;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .2), 0 10px 26px rgba(0, 0, 0, .34);
}

.win-bar {
    height: 27px;
    padding: 0 10px;
    background: linear-gradient(180deg, #f8f8f8 0%, #e6e6e6 48%, #dedede 52%, #d4d4d4 100%);
    border-bottom: 1px solid #a6a6a6;
    border-radius: 6px 6px 0 0;
}

.win:not(.on) .win-bar { background: linear-gradient(180deg, #f2f2f2, #e4e4e4); }

.win-bar .wi { font-size: 11px; color: #6a6a6a; text-shadow: 0 1px 0 rgba(255, 255, 255, .9); }

.win-bar b {
    font-size: 12px; font-weight: 600; text-align: center;
    color: #3c3c3c;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
}

.win:not(.on) .win-bar b { color: #8a8a8a; }

.win-btn {
    width: 12px; height: 12px;
    padding: 0;
    font-size: 0; color: transparent;
    background: radial-gradient(circle at 50% 32%, #ffd98a, #e0a92a);
    border: 1px solid rgba(0, 0, 0, .32);
    border-radius: 50%;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55);
}

.win-btn i { display: none; }
.win-btn + .win-btn { margin-left: 8px; }
.win-btn:hover { filter: brightness(1.08); }

.win-btn.x {
    width: 12px;
    background: radial-gradient(circle at 50% 32%, #ff8f85, #e5493c);
    border-color: rgba(0, 0, 0, .32); color: transparent;
}

.win-btn.x:hover { background: radial-gradient(circle at 50% 32%, #ffaba2, #d13a2d); border-color: rgba(0, 0, 0, .32); }

.win-body {
    color: #2b2b2b;
    background: #fff;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, .7);
    border-radius: 0 0 6px 6px;
    box-shadow: none;
}

.win-menu {
    padding: 4px 6px;
    background: linear-gradient(180deg, #fbfbfb, #f0f0f0);
    border-bottom: 1px solid #dcdcdc;
}

.win-menu span { color: #3c3c3c; }
.win-menu span:hover { background: #e4eef8; }

/* --- pasek zadan --- */

.dk-bar {
    height: 38px;
    gap: 4px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .34) 0 1px, rgba(255, 255, 255, .08) 1px 2px, transparent 2px),
        linear-gradient(180deg, rgba(48, 56, 66, .92) 0%, rgba(26, 32, 40, .95) 48%,
                                rgba(32, 39, 48, .94) 52%, rgba(16, 20, 26, .97) 100%);
    box-shadow: 0 -6px 18px rgba(0, 0, 0, .42);
}

.dk-orb { width: 48px; height: 38px; }
.dk-orb svg { width: 40px; height: 40px; }

.dk-task {
    min-width: 148px; height: 28px;
    border-radius: 4px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .03));
    border-color: rgba(255, 255, 255, .18);
    transition: background 130ms var(--e), box-shadow 130ms var(--e);
}

.dk-task:hover {
    background: linear-gradient(180deg, rgba(150, 200, 245, .26), rgba(110, 165, 220, .12));
    box-shadow: inset 0 0 14px rgba(150, 205, 250, .28);
}

.dk-task.on {
    background: linear-gradient(180deg, rgba(170, 214, 250, .34), rgba(80, 150, 220, .18));
    border-color: rgba(190, 226, 255, .48);
    box-shadow: inset 0 0 12px rgba(160, 215, 255, .34), inset 0 -2px 0 rgba(110, 180, 240, .55);
}

.dk-tray .t-ico {
    width: 24px;
    color: #c3d4e4;
    transition: color 130ms var(--e);
}

.dk-tray .t-ico:hover { color: #fff; }

.dk-clock { min-width: 72px; }
.dk-clock b { font-size: 12px; font-weight: 500; letter-spacing: .01em; }
.dk-clock span { font-size: 10.5px; color: rgba(255, 255, 255, .74); }

.dk-peek {
    width: 10px;
    border-left: 1px solid rgba(255, 255, 255, .22);
    background: linear-gradient(180deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .01));
    transition: background 130ms var(--e);
}

.dk-peek:hover { background: linear-gradient(180deg, rgba(170, 214, 250, .30), rgba(110, 175, 235, .12)); }

/* --- menu start --- */

.m-glass {
    background: linear-gradient(180deg, rgba(40, 48, 58, .95), rgba(20, 25, 32, .96));
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 7px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .12);
}

.m-right a { border-radius: 4px; transition: background 120ms var(--e); }
.m-right a:hover { background: rgba(150, 200, 245, .18); }

.m-search {
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 4px;
}

.m-off {
    background: linear-gradient(180deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .05));
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 4px;
    transition: background 120ms var(--e);
}

.m-off:hover { background: linear-gradient(180deg, rgba(180, 218, 250, .30), rgba(120, 175, 230, .14)); }

/* =============================================================================
   ZEGAR I RUCH W OKNIE PROBY

   Dwie rzeczy naraz. Po pierwsze czas: siedzial w belce jako szary napis na
   szarym chromie i po prostu ginal. Dostaje wlasny ciemny wyswietlacz z
   cyframi o stalej szerokosci, wiec nie skacze przy odliczaniu, a pod szesc
   sekund zaczyna pulsowac.

   Po drugie ruch. Wszystko, co dzieje sie caly czas, jedzie na transformacie
   albo przezroczystosci - te dwie rzeczy skladacz robi na karcie i nie
   przemalowuje tekstury laptopa. Reszta to animacje jednorazowe, ktore w
   spoczynku nie kosztuja nic.
   ========================================================================== */

/* --- wyswietlacz czasu --- */

#mg #mg-state {
    padding: 3px 9px;
    font: 700 11.5px/1 'Consolas', 'SF Mono', 'Chop', monospace;
    font-variant-numeric: tabular-nums;
    letter-spacing: .02em;
    color: #eaf2f9;
    background: linear-gradient(180deg, #4d5864 0%, #39424c 52%, #2f373f 100%);
    border: 1px solid rgba(0, 0, 0, .38);
    border-radius: 10px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .20), 0 1px 0 rgba(255, 255, 255, .65);
    text-shadow: 0 1px 1px rgba(0, 0, 0, .55);
}

#mg #mg-state[data-z="green"] {
    color: #dcffe2;
    background: linear-gradient(180deg, #3f9a44 0%, #2f7d33 52%, #276b2b 100%);
}

#mg #mg-state[data-z="orange"] {
    color: #fff4d8;
    background: linear-gradient(180deg, #d9a021 0%, #bd8814 52%, #a5760f 100%);
}

#mg #mg-state[data-z="red"] {
    color: #ffe6e3;
    background: linear-gradient(180deg, #d94b3d 0%, #c0392b 52%, #a72f23 100%);
    animation: stateHot .9s ease-in-out infinite;
}

@keyframes stateHot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%      { opacity: .82; transform: scale(1.06); }
}

/* --- pasek czasu: plynacy polysk, zeby bylo widac, ze zegar idzie --- */

#mg .mg-bars i { position: relative; overflow: hidden; }

#mg .mg-bars i::after {
    content: '';
    position: absolute; top: 0; bottom: 0; left: -60%;
    width: 220%;
    background: repeating-linear-gradient(115deg,
        rgba(255, 255, 255, .00) 0 9px,
        rgba(255, 255, 255, .26) 9px 18px);
    animation: barFlow 1.1s linear infinite;
}

@keyframes barFlow {
    to { transform: translateX(18px); }
}

#mg #mg-strain.low { animation: strainLow .8s ease-in-out infinite; }

@keyframes strainLow {
    0%, 100% { opacity: 1; }
    50%      { opacity: .62; }
}

/* --- wejscie okna i jego zawartosci --- */

#mg .mg-box { animation: boxIn 260ms cubic-bezier(.16, 1, .3, 1) both; }

@keyframes boxIn {
    from { opacity: 0; transform: translateY(14px) scale(.97); }
    to   { opacity: 1; transform: none; }
}

#mg .mg-hint { animation: hintIn 320ms cubic-bezier(.16, 1, .3, 1) 60ms both; }

@keyframes hintIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: none; }
}

#mg .mg-panel { animation: panelIn 320ms cubic-bezier(.16, 1, .3, 1) 90ms both; }

@keyframes panelIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: none; }
}

#mg .mg-go { animation: goIn 360ms cubic-bezier(.16, 1, .3, 1) both; }

@keyframes goIn {
    from { opacity: 0; transform: scale(.96); }
    to   { opacity: 1; transform: none; }
}

#mg .mg-go .go-ico { animation: goIco 2.6s ease-in-out infinite; }

@keyframes goIco {
    0%, 88%, 100% { transform: translateY(0); }
    94%           { transform: translateY(-3px); }
}

#mg .win7.go { animation: goPulse 2.2s ease-in-out infinite; }

@keyframes goPulse {
    0%, 100% { box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 1px 2px rgba(0,0,0,.22), 0 0 0 0 rgba(47,127,214,.45); }
    55%      { box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 1px 2px rgba(0,0,0,.22), 0 0 0 6px rgba(47,127,214,0); }
}

/* --- reakcja na dotyk --- */

#mg .mg-panel button,
#mg .mg-keys .k,
#mg .win7 {
    transition:
        transform 110ms cubic-bezier(.16, 1, .3, 1),
        background 130ms var(--e),
        border-color 130ms var(--e),
        box-shadow 130ms var(--e);
}

#mg .mg-panel button:hover { transform: translateY(-1px); }
#mg .mg-panel button:active { transform: translateY(1px); }

#mg .win7:hover  { transform: translateY(-1px); }
#mg .win7:active { transform: translateY(1px); }

/* --- kropki etapow --- */

#mg .mg-pips i { transition: background 160ms var(--e), border-color 160ms var(--e); }
#mg .mg-pips i.on { animation: pipPop 300ms cubic-bezier(.16, 1, .3, 1); }

@keyframes pipPop {
    0%   { transform: scaleY(1); }
    45%  { transform: scaleY(1.9); }
    100% { transform: scaleY(1); }
}

/* --- wynik: pieczatka nad plansza --- */

#mg .mg-panel { position: relative; }

#mg[data-s] .mg-panel::after {
    position: absolute; inset: 0;
    display: grid; place-items: center;
    font: 700 92px/1 'Chop', 'Segoe UI', sans-serif;
    pointer-events: none;
    animation: stampIn 420ms cubic-bezier(.16, 1, .3, 1) both;
}

#mg[data-s="win"] .mg-panel::after {
    content: '\2713';
    color: rgba(63, 154, 68, .30);
    text-shadow: 0 2px 0 rgba(255, 255, 255, .55);
}

#mg[data-s="lose"] .mg-panel::after,
#mg[data-s="miss"] .mg-panel::after {
    content: '\2715';
    color: rgba(207, 68, 54, .28);
    text-shadow: 0 2px 0 rgba(255, 255, 255, .55);
}

@keyframes stampIn {
    from { opacity: 0; transform: scale(1.5) rotate(-9deg); }
    to   { opacity: 1; transform: scale(1) rotate(-9deg); }
}

/* --- ladowanie --- */

#mg .mg-load { animation: loadIn 240ms var(--e) both; }

@keyframes loadIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Kto prosi system o mniej ruchu, dostaje mniej ruchu. Czytelnosc zegara
   zostaje - pulsowanie znika, kolor i wyswietlacz nie. */
@media (prefers-reduced-motion: reduce) {
    #mg #mg-state[data-z="red"],
    #mg #mg-strain.low,
    #mg .mg-bars i::after,
    #mg .mg-go .go-ico,
    #mg .win7.go { animation: none; }

    #mg .mg-box,
    #mg .mg-hint,
    #mg .mg-panel,
    #mg .mg-go,
    #mg .mg-load { animation-duration: 1ms; }

    #mg[data-s] .mg-panel::after { animation: none; }
}

/* --- klawisze z kolorem przypisanym na stale (kod immobilisera) --- */

#mg .mg-keys .k.tint {
    position: relative;
    padding-bottom: 2px;
    border-color: color-mix(in srgb, var(--c) 45%, #b0b0b0);
    box-shadow: inset 0 1px 0 #fff, inset 0 -3px 0 var(--c), 0 1px 1px rgba(0, 0, 0, .10);
}

#mg .mg-keys .k.tint.hit {
    color: #fff;
    background: linear-gradient(180deg,
        color-mix(in srgb, var(--c) 78%, #ffffff) 0%,
        var(--c) 52%,
        color-mix(in srgb, var(--c) 82%, #000000) 100%);
    border-color: color-mix(in srgb, var(--c) 70%, #000000);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 0 10px color-mix(in srgb, var(--c) 55%, transparent);
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .28);
    transform: translateY(1px) scale(1.06);
}

/* --- stos rygli (wieza Hanoi) --- */

#mg-hanoi, #mg-sweep { margin-bottom: 10px; }
#mg-hanoi.off, #mg-sweep.off { display: none; }

.hn-note, .sw-note {
    margin-bottom: 10px;
    font-size: 11.5px; color: #5c5c5c;
    text-align: center;
}

.hn-pegs {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    align-items: end;
}

.hn-peg {
    position: relative;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 0 6px 6px;
    font: inherit;
    background: none; border: 0;
    cursor: pointer;
}

/* trzpien */
.hn-peg::before {
    content: '';
    position: absolute; left: 50%; bottom: 26px;
    width: 5px; height: 132px;
    margin-left: -2.5px;
    background: linear-gradient(180deg, #c8c8c8, #a4a4a4);
    border: 1px solid #8e8e8e;
    border-radius: 3px 3px 0 0;
}

.hn-stack {
    position: relative; z-index: 1;
    display: flex; flex-direction: column-reverse; align-items: center; gap: 3px;
    width: 100%; height: 132px;
    justify-content: flex-start;
}

.hn-d {
    width: var(--w, 60%); height: 17px;
    display: grid; place-items: center;
    font: 600 10px/1 'Chop', 'Segoe UI', sans-serif; font-style: normal;
    color: #fff;
    background: linear-gradient(180deg,
        color-mix(in srgb, var(--c) 74%, #ffffff) 0%,
        var(--c) 52%,
        color-mix(in srgb, var(--c) 84%, #000000) 100%);
    border: 1px solid color-mix(in srgb, var(--c) 68%, #000000);
    border-radius: 4px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .38), 0 1px 1px rgba(0, 0, 0, .16);
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .3);
    transition: transform 130ms cubic-bezier(.16, 1, .3, 1);
}

.hn-d.up { transform: translateY(-9px) scale(1.04); box-shadow: 0 4px 10px rgba(0, 0, 0, .3); }

.hn-peg b {
    display: grid; place-items: center;
    width: 100%; height: 22px;
    font: 600 11px/1 'Chop', 'Segoe UI', sans-serif;
    color: #4a4a4a;
    background: linear-gradient(180deg, #f2f2f2, #e2e2e2);
    border: 1px solid #b6b6b6;
    border-radius: 4px;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .9);
    transition: background 130ms var(--e), border-color 130ms var(--e);
}

.hn-peg:hover b { border-color: #7fb0dd; background: linear-gradient(180deg, #ffffff, #eef5fc); }

.hn-peg.pick b {
    color: #fff;
    background: linear-gradient(180deg, #5aa4e6, #2a76c8);
    border-color: #1a63b8;
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
}

.hn-count {
    margin-top: 10px;
    font-size: 11px; color: #6a6a6a; text-align: center;
}

#mg-hanoi.no .hn-pegs { animation: hnNo 220ms ease; }

@keyframes hnNo {
    25% { transform: translateX(-5px); }
    60% { transform: translateX(4px); }
}

/* --- znaki kontrolne --- */

.sw-field {
    position: relative;
    height: 232px;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, .04) 1px, transparent 1px) 0 0 / 28px 28px,
        linear-gradient(180deg, rgba(0, 0, 0, .04) 1px, transparent 1px) 0 0 / 28px 28px,
        #fbfbfb;
    border: 1px solid #dcdcdc;
    border-radius: 5px;
    overflow: hidden;
    transition: opacity 320ms var(--e), filter 320ms var(--e);
}

.sw-field i {
    position: absolute;
    font-family: 'Chop', 'Segoe UI', sans-serif;
    font-weight: 700; font-style: normal; line-height: 1;
}

.sw-note { margin: 10px 0 8px; }

.sw-slots { display: flex; justify-content: center; gap: 6px; }

.sw-slots b {
    display: grid; place-items: center;
    width: 34px; height: 36px;
    font: 700 15px/1 'Chop', 'Segoe UI', sans-serif;
    color: #2b2b2b;
    background: linear-gradient(180deg, #ffffff, #f0f0f0);
    border: 1px solid #bdbdbd;
    border-radius: 5px;
    box-shadow: inset 0 1px 0 #fff;
    transition: background 150ms var(--e), border-color 150ms var(--e), transform 150ms var(--e);
}

.sw-slots b.on {
    color: #fff;
    background: linear-gradient(180deg, #5aa4e6, #2a76c8);
    border-color: #1a63b8;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35);
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
    transform: translateY(-2px);
}

#mg-sweep.no .sw-slots { animation: hnNo 220ms ease; }

/* --- znaki kontrolne: plansza zagaszona, kursor niesie okno --- */

#mg-sweep .sw-field {
    position: relative;
    height: 236px;
    background: #10141a;
    border: 1px solid #b6b6b6;
    border-radius: 5px;
    overflow: hidden;
    cursor: none;
}

#mg-sweep .sw-marks { position: absolute; inset: 0; }

#mg-sweep .sw-marks i {
    position: absolute;
    font-family: 'Chop', 'Segoe UI', sans-serif;
    font-weight: 700; font-style: normal; line-height: 1;
    text-shadow: 0 0 12px rgba(0, 0, 0, .55);
}

/* znaleziony znak zostaje na wierzchu, ponad mgla */
#mg-sweep .sw-marks i.found {
    z-index: 3;
    filter: saturate(.35) brightness(1.25);
    opacity: .55;
}

/* Mgla to jedna plaszczyzna z dziura w miejscu kursora. Przesuwamy ja
   zmienna CSS, wiec przemalowuje sie tylko ten jeden element. */
#mg-sweep .sw-fog {
    position: absolute; inset: 0; z-index: 2;
    pointer-events: none;
    background:
        radial-gradient(circle var(--r, 52px) at var(--x, -400px) var(--y, -400px),
            transparent 0 70%,
            rgba(16, 20, 26, .70) 88%,
            #10141a 100%),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, .035) 0 1px, transparent 1px 26px),
        repeating-linear-gradient(180deg, rgba(255, 255, 255, .035) 0 1px, transparent 1px 26px);
}

#mg-sweep .sw-ring {
    position: absolute; top: 0; left: 0; z-index: 4;
    width: calc(var(--r, 52px) * 2); height: calc(var(--r, 52px) * 2);
    border: 1px solid rgba(150, 200, 240, .55);
    border-radius: 50%;
    box-shadow: 0 0 14px rgba(120, 180, 235, .28), inset 0 0 18px rgba(120, 180, 235, .12);
    opacity: 0;
    pointer-events: none;
    transition: opacity 160ms var(--e);
    will-change: transform;
}

#mg-sweep .sw-ring::after {
    content: '';
    position: absolute; left: 50%; top: 50%;
    width: 9px; height: 9px;
    margin: -4.5px 0 0 -4.5px;
    border: 1px solid rgba(170, 215, 250, .7);
    border-radius: 50%;
}

/* --- dwa paski, dwa znaczenia ---

   Do tej pory postep i czas mialy ten sam blekit, wiec z drugiego konca
   pokoju nie dalo sie odroznic "idzie mi dobrze" od "konczy mi sie czas".
   Sukces rosnie na zielono, czas odplywa na blekitno i przechodzi w
   bursztyn i czerwien, kiedy zostaje go malo. */

#mg #mg-progress {
    background: linear-gradient(180deg, #9adf96 0%, #4faf52 48%, #3f9a44 52%, #6cc46e 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45);
}

#mg #mg-progress::after {
    background: repeating-linear-gradient(115deg,
        rgba(255, 255, 255, .00) 0 9px,
        rgba(255, 255, 255, .30) 9px 18px);
}

#mg #mg-strain {
    background: linear-gradient(180deg, #8cc4f0 0%, #3d8ada 48%, #2a76c8 52%, #5aa4e6 100%);
}

/* pasek czasu ma wlasny tor - cienszy i chlodniejszy niz pasek sukcesu */
#mg .mg-bars .bar.thin {
    background: linear-gradient(180deg, #cdd7df, #e2e9ee);
    border-color: #a2b0bb;
}
