/* ==========================================================================
   Linux and Virtual PC (app/commands/virtualpc.js)
   The library is the usual Orbit UI kit (.ok-app, .xa-app); the running
   machine (.vm-run) is a black stage with a slim bar on top and a key bar
   at the bottom. Everything that moves is in the "Linux and Virtual PC"
   section at the end of css/motion.css.
   ========================================================================== */

.vm-app { --vm-ink: #f4f6fb; --vm-bar: rgba(16, 18, 24, 0.92); }

/* ---------- Library ---------- */

.vm-app .vm-hero { padding-bottom: 18px; }
.vm-app .vm-hero .ok-hero-sub { max-width: 46ch; }
.vm-app .vm-hero-art {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}
.vm-app .vm-hero-art i {
    position: absolute;
    right: -30px;
    top: -40px;
    width: 180px;
    height: 120px;
    border-radius: 18px;
    border: 2px solid rgba(255, 255, 255, 0.16);
    transform: rotate(-12deg);
}
.vm-app .vm-hero-art i:nth-child(2) { right: 10px; top: 20px; width: 120px; height: 80px; border-radius: 12px; opacity: 0.7; }
.vm-app .vm-hero-art i:nth-child(3) { right: 40px; top: 66px; width: 70px; height: 8px; border-radius: 4px; border: none; background: rgba(255, 255, 255, 0.18); }

.vm-app .vm-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vm-app .vm-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 12px 10px 10px;
    border-radius: 22px;
    border: 1px solid var(--ok-line);
    background: var(--ok-card);
    color: var(--on-surface);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.vm-app .vm-thumb {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 96px;
    aspect-ratio: 4 / 3;
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(150deg, color-mix(in srgb, var(--tile) 50%, #000000), var(--tile));
    color: #ffffff;
}
.vm-app .vm-thumb.has-shot { background: #000000; }
.vm-app .vm-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; image-rendering: auto; }
.vm-app .vm-thumb-icon svg { stroke: #ffffff; opacity: 0.95; }

.vm-app .vm-badge {
    position: absolute;
    left: 6px;
    bottom: 6px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 20px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.62);
    color: #ffffff;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.vm-app .vm-thumb-ring {
    position: absolute;
    inset: 0;
    background: conic-gradient(rgba(255, 255, 255, 0.35) calc(var(--p, 0) * 1%), transparent 0);
    mix-blend-mode: overlay;
}

.vm-app .vm-card-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
    text-align: left;
}
.vm-app .vm-card-text strong {
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.vm-app .vm-card-text > span {
    font-size: 0.8rem;
    line-height: 1.35;
    color: var(--ok-muted);
}
.vm-app .vm-card .vm-card-sub { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vm-app .vm-card-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.vm-app .vm-card-tags i {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 8px;
    border-radius: 999px;
    border: 1px solid var(--ok-line-strong);
    font-style: normal;
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--on-surface);
    white-space: nowrap;
}
.vm-app .vm-card-side { display: flex; flex-direction: column; align-items: center; gap: 6px; flex-shrink: 0; }

.vm-app .vm-card-play {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--ok-ink);
    color: var(--ok-on-ink);
}
.vm-app .vm-card-play svg { margin-left: 2px; }
.vm-app .vm-card-more { width: 30px; height: 30px; }
.vm-app .vm-make { display: flex; flex-direction: column; gap: 10px; }

.vm-app .vm-empty { padding: 26px 18px; }

.vm-app .vm-os-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}
@media (min-width: 620px) {
    .vm-app .vm-os-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.vm-app .vm-os {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    min-height: 0;
    padding: 14px;
    border-radius: 22px;
    border: 1px solid var(--ok-line);
    background: var(--ok-card);
    color: var(--on-surface);
    font-family: var(--font-main);
    text-align: left;
    cursor: pointer;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}
.vm-app .vm-os .ok-tile { margin-bottom: 10px; }
.vm-app .vm-os-name { font-size: 0.95rem; font-weight: 700; line-height: 1.25; }
.vm-app .vm-os-meta { font-size: 0.76rem; color: var(--ok-muted); font-variant-numeric: tabular-nums; }
.vm-app .vm-os-bar {
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 9px;
    height: 4px;
    border-radius: 2px;
    background: color-mix(in srgb, var(--tile) 22%, transparent);
    overflow: hidden;
}
.vm-app .vm-os-bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--tile); }

.vm-app .vm-own {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border-radius: 22px;
    border: 1px dashed var(--ok-line-strong);
    background: transparent;
    color: var(--on-surface);
    font-family: var(--font-main);
    cursor: pointer;
}

/* ---------- Sheets ---------- */

.vm-app .vm-sheet .xa-sheet-card {
    gap: 12px;
    max-height: 86%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
.vm-app .vm-grab {
    align-self: center;
    width: 38px;
    height: 4px;
    margin: 2px 0 2px;
    border-radius: 2px;
    background: var(--ok-line-strong);
    flex-shrink: 0;
}
.vm-app .vm-sheet-hero { display: flex; align-items: center; gap: 14px; padding-top: 4px; }
.vm-app .vm-sheet-hero .ok-tile { background: var(--tile); }
.vm-app .vm-sheet-title { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.vm-app .vm-sheet-title strong { font-size: 1.2rem; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vm-app .vm-sheet-title span { font-size: 0.82rem; color: var(--ok-muted); }
.vm-app .vm-sheet-text { margin: 0; font-size: 0.9rem; line-height: 1.55; color: var(--on-surface); }
.vm-app .vm-sheet-note { margin: 0; font-size: 0.78rem; line-height: 1.45; color: var(--ok-muted); }

.vm-app .vm-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-radius: 18px;
    border: 1px solid var(--ok-line);
    overflow: hidden;
}
.vm-app .vm-facts span {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 11px 6px;
    font-size: 0.72rem;
    color: var(--ok-muted);
    text-align: center;
}
.vm-app .vm-facts span + span { border-left: 1px solid var(--ok-line); }
.vm-app .vm-facts b { font-size: 0.95rem; color: var(--on-surface); font-variant-numeric: tabular-nums; }
.vm-app .vm-tags { gap: 6px; }

.vm-app .vm-sheet-actions { display: flex; gap: 10px; padding-top: 2px; }
.vm-app .vm-sheet-actions .ok-btn { flex: 1; height: 48px; font-size: 0.92rem; gap: 8px; }
.vm-app .vm-spin { width: 16px; height: 16px; }

.vm-app .vm-progress { display: flex; flex-direction: column; gap: 7px; }
.vm-app .vm-progress[hidden] { display: none; }
.vm-app .vm-progress-bar { height: 8px; border-radius: 4px; background: color-mix(in srgb, var(--hue) 18%, transparent); overflow: hidden; }
.vm-app .vm-progress-bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--hue); }
.vm-app .vm-progress-text { font-size: 0.78rem; color: var(--ok-muted); font-variant-numeric: tabular-nums; }

.vm-app .vm-field { display: flex; flex-direction: column; gap: 6px; font-size: 0.78rem; font-weight: 600; color: var(--ok-muted); }
.vm-app .vm-field .ok-input { flex: none; height: 46px; padding: 0 14px; border-radius: 14px; font-size: 16px; font-weight: 500; }
.vm-app .vm-pick-label { margin-top: 2px; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ok-muted); }
.vm-app .vm-presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.vm-app .vm-preset {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 11px 12px;
    border-radius: 14px;
    border: 1px solid var(--ok-line-strong);
    background: transparent;
    color: var(--on-surface);
    font: 600 0.84rem var(--font-main);
    text-align: left;
    cursor: pointer;
}
.vm-app .vm-preset svg { flex-shrink: 0; }
.vm-app .vm-preset-text { display: flex; flex-direction: column; gap: 1px; flex: 1; min-width: 0; }
.vm-app .vm-preset-text b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vm-app .vm-preset em { font-style: normal; font-size: 0.7rem; font-weight: 500; color: var(--ok-muted); white-space: nowrap; }
.vm-app .vm-preset.is-on { border-color: transparent; background: var(--ok-ink); color: var(--ok-on-ink); }
.vm-app .vm-preset.is-on em { color: inherit; opacity: 0.7; }
.vm-app .vm-warn { padding: 10px 12px; }

.vm-app .vm-steps { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
.vm-app .vm-steps li { display: flex; align-items: flex-start; gap: 12px; padding: 11px 12px; border-radius: 16px; border: 1px solid var(--ok-line); font-size: 0.86rem; line-height: 1.45; color: var(--on-surface); }
.vm-app .vm-steps b { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; flex-shrink: 0; border-radius: 50%; background: var(--hue); color: #ffffff; font-size: 0.78rem; }
.vm-app .vm-steps strong { font-weight: 700; }

.vm-app .vm-fade { opacity: 1; }

/* Close sheet (Ask me): three buttons stack on a phone. */
.vm-close-sheet .ok-sheet-actions { flex-direction: column-reverse; }
.vm-close-sheet .ok-sheet-actions .ok-sheet-btn { width: 100%; }

/* ---------- Running machine ---------- */

.vm-app .vm-run {
    position: absolute;
    inset: 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    background: #000000;
    color: var(--vm-ink);
    overflow: hidden;
}

.vm-app .vm-top {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    padding-top: max(8px, env(safe-area-inset-top, 0px));
    min-height: 56px;
    background: var(--vm-bar);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    flex-shrink: 0;
    z-index: 3;
}
.vm-app .vm-top-btn {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-color: transparent;
    background: rgba(255, 255, 255, 0.07);
    color: var(--vm-ink);
}
.vm-app .vm-top-btn svg { stroke: currentColor; }
.vm-app .vm-top-text { display: flex; flex-direction: column; gap: 1px; flex: 1; min-width: 0; padding: 0 4px; }
.vm-app .vm-top-text strong { font-size: 0.95rem; font-weight: 700; color: var(--vm-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vm-app .vm-status { display: inline-flex; align-items: center; gap: 6px; font-size: 0.74rem; color: rgba(244, 246, 251, 0.62); }
.vm-app .vm-status em { font-style: normal; }
.vm-app .vm-mips { font-weight: 600; color: rgba(244, 246, 251, 0.82); font-variant-numeric: tabular-nums; }
.vm-app .vm-mips::before { content: '·'; margin-right: 6px; color: rgba(244, 246, 251, 0.4); }
.vm-app .vm-dot { width: 7px; height: 7px; border-radius: 50%; background: #f59e0b; flex-shrink: 0; }
.vm-app .vm-run[data-state="running"] .vm-dot { background: #22c55e; }
.vm-app .vm-run[data-state="paused"] .vm-dot { background: #94a3b8; }
.vm-app .vm-run[data-state="saving"] .vm-dot { background: #38bdf8; }
.vm-app .vm-run[data-state="error"] .vm-dot { background: #ef4444; }

.vm-app .vm-stage {
    position: relative;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    touch-action: none;
    outline: none;
    background: radial-gradient(120% 90% at 50% 40%, #0b0d12 0%, #000000 70%);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}
.vm-app .vm-run[data-state="running"] .vm-stage { cursor: none; }

.vm-app .vm-screen {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(calc(-50% + var(--px, 0px)), calc(-50% + var(--py, 0px))) scale(var(--s, 1));
    transform-origin: center center;
    background: #000000;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04);
}
.vm-app .vm-screen canvas {
    display: block;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
}
.vm-app .vm-smooth .vm-screen canvas { image-rendering: auto; }
.vm-app .vm-screen .vm-text {
    white-space: pre;
    font: 14px/14px monospace;
    color: #ffffff;
}
.vm-app .vm-screen .vm-text:empty { display: none; }

/* Booting / errors */
.vm-app .vm-boot {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 24px;
    background: radial-gradient(90% 70% at 50% 42%, #10131a 0%, #000000 75%);
    text-align: center;
}
.vm-app .vm-boot[hidden] { display: none; }
.vm-app .vm-boot-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    margin-bottom: 8px;
    border-radius: 26px;
    background: linear-gradient(150deg, color-mix(in srgb, var(--tile) 55%, #000000), var(--tile));
    color: #ffffff;
}
.vm-app .vm-boot-icon svg { stroke: #ffffff; }
.vm-app .vm-boot-icon i {
    position: absolute;
    inset: -8px;
    border-radius: 32px;
    border: 2px solid color-mix(in srgb, var(--tile) 60%, transparent);
    opacity: 0;
}
.vm-app .vm-boot-icon.is-error { background: color-mix(in srgb, #ef4444 85%, #000000); }
.vm-app .vm-boot-title { font-size: 1.12rem; font-weight: 700; color: var(--vm-ink); }
.vm-app .vm-boot-step { max-width: 34ch; font-size: 0.86rem; line-height: 1.45; color: rgba(244, 246, 251, 0.7); }
.vm-app .vm-boot-bar {
    position: relative;
    width: min(240px, 70%);
    height: 4px;
    margin-top: 6px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.1);
    overflow: hidden;
}
.vm-app .vm-boot-bar i { display: block; height: 100%; width: 4%; border-radius: inherit; background: #ffffff; }
.vm-app .vm-boot-bar.is-busy i { width: 34%; }
.vm-app .vm-boot-tip { position: absolute; left: 24px; right: 24px; bottom: calc(22px + env(safe-area-inset-bottom, 0px)); font-size: 0.78rem; color: rgba(244, 246, 251, 0.45); }
.vm-app .vm-boot-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 10px; }
.vm-app .vm-boot-actions .ok-btn--outline { border-color: rgba(255, 255, 255, 0.25); color: var(--vm-ink); }
.vm-app .vm-boot-actions .ok-btn--ink { background: #ffffff; color: #0b0d12; }

/* Paused */
.vm-app .vm-paused {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(0, 0, 0, 0.55);
    font-size: 0.86rem;
    font-weight: 600;
    color: rgba(244, 246, 251, 0.8);
}
.vm-app .vm-paused[hidden] { display: none; }
.vm-app .vm-paused-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    border: none;
    border-radius: 50%;
    background: #ffffff;
    color: #0b0d12;
    cursor: pointer;
}
.vm-app .vm-paused-btn svg { margin-left: 4px; }

/* Hint line and saving pill */
.vm-app .vm-hint,
.vm-app .vm-saving {
    position: absolute;
    left: 50%;
    top: 14px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: calc(100% - 32px);
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(20, 22, 30, 0.88);
    color: var(--vm-ink);
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.35;
    text-align: center;
    width: max-content;
    overflow: hidden;
    pointer-events: none;
    translate: -50% 0;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.vm-app .vm-hint.is-on { opacity: 1; }
.vm-app .vm-hint[hidden] { display: none; }
.vm-app .vm-saving { opacity: 1; }
.vm-app .vm-saving.is-leaving { opacity: 0; }

.vm-app .vm-flash { position: absolute; inset: 0; z-index: 4; background: #ffffff; pointer-events: none; opacity: 0; }

/* Peek button: brings the bar back in full screen */
.vm-app .vm-peek {
    position: absolute;
    top: max(10px, env(safe-area-inset-top, 0px));
    right: 10px;
    z-index: 3;
    display: none;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(20, 22, 30, 0.7);
    color: var(--vm-ink);
    cursor: pointer;
}
.vm-app .vm-run.top-hidden .vm-peek { display: inline-flex; }

/* Extra keys */
.vm-app .vm-keys {
    display: flex;
    gap: 6px;
    padding: 8px 10px;
    padding-bottom: max(8px, env(safe-area-inset-bottom, 0px));
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    background: var(--vm-bar);
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    flex-shrink: 0;
    z-index: 3;
}
.vm-app .vm-keys::-webkit-scrollbar { display: none; }
.vm-app .vm-run.keys-hidden .vm-keys { display: none; }
.vm-app .vm-key {
    flex-shrink: 0;
    min-width: 44px;
    height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.08);
    color: var(--vm-ink);
    font: 600 0.84rem var(--font-main);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}
.vm-app .vm-key.is-mod { background: rgba(255, 255, 255, 0.04); }
.vm-app .vm-key.is-held { background: #ffffff; color: #0b0d12; border-color: transparent; }
.vm-app .vm-key[data-key="Esc"] { color: #fca5a5; }

/* The hidden field the phone keyboard types into */
.vm-app .vm-input {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 1px;
    height: 1px;
    padding: 0;
    border: 0;
    opacity: 0;
    resize: none;
    font-size: 16px; /* stops iOS zooming in */
    pointer-events: none;
}
.vm-app .vm-run.kbd-open [data-r="kbd"] { background: #ffffff; color: #0b0d12; }

/* Full screen (and sideways): the machine moves to a layer on <body> (.vm-portal,
   under sheets and toasts), the bar floats and hides itself. */
.vm-portal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: #000000;
    font-family: var(--font-main);
}
.vm-app .vm-run.vm-full .vm-top {
    position: absolute;
    left: 10px;
    right: 10px;
    top: max(8px, env(safe-area-inset-top, 0px));
    min-height: 0;
    padding: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
}
.vm-app .vm-run.vm-full.top-hidden .vm-top { opacity: 0; pointer-events: none; transform: translateY(-120%); }

@media (orientation: landscape) and (max-height: 520px) {
    .vm-app .vm-top { min-height: 46px; padding-top: 4px; padding-bottom: 4px; }
    .vm-app .vm-top-btn { width: 36px; height: 36px; }
    .vm-app .vm-keys { padding-top: 5px; padding-bottom: max(5px, env(safe-area-inset-bottom, 0px)); }
    .vm-app .vm-key { height: 32px; min-width: 40px; }
}

/* Light themes: the machine itself always stays dark. */
html.theme-solar-flare .vm-app .vm-run,
html.theme-arctic .vm-app .vm-run,
html.theme-paper .vm-app .vm-run,
html.theme-blossom .vm-app .vm-run,
html.theme-sage .vm-app .vm-run { color: var(--vm-ink); }

/* Navigation buttons and the status bar can step aside while a machine runs
   (Settings > While a machine runs). */
body.vm-hide-nav { --nav-h: 0px !important; }
body.vm-hide-nav #hs-navbar,
body.vm-hide-nav #hs-pill,
body.vm-hide-nav #hs-gesture-pill { display: none !important; }
body.vm-hide-status #status-bar { display: none !important; }
body.vm-hide-status .os-container { padding-top: 0 !important; }

/* Machine bar hidden on a normal screen (Machine bar: Hide after a few seconds) */
.vm-app .vm-run:not(.vm-full) .vm-top { position: relative; }
.vm-app .vm-run.top-hidden:not(.vm-full) .vm-top { margin-top: -64px; opacity: 0; pointer-events: none; }

/* ---------- Computers: hover, focus, wide windows ----------
   The window itself is the container, so a resized desktop window gets the
   wide layout too, not only big screens. */
.vm-app { container-type: inline-size; container-name: vmwin; }

@media (hover: hover) and (pointer: fine) {
    .vm-app .vm-card:hover,
    .vm-app .vm-os:hover,
    .vm-app .vm-own:hover { border-color: var(--ok-line-strong); background: color-mix(in srgb, var(--on-surface) 4%, var(--ok-card)); }
    .vm-app .vm-card:hover .vm-card-play { transform: scale(1.08); }
    .vm-app .vm-preset:hover:not(.is-on) { border-color: color-mix(in srgb, var(--on-surface) 40%, transparent); }
    .vm-app .vm-key:hover,
    .vm-app .vm-top-btn:hover { background: rgba(255, 255, 255, 0.16); }
    .vm-app .vm-run[data-state="running"] .vm-stage:hover { cursor: none; }
}
html.kbd-nav .vm-app :is(.vm-card, .vm-os, .vm-own, .vm-preset, .vm-key):focus-visible { outline: 2px solid var(--hue); outline-offset: 2px; }

@container vmwin (min-width: 700px) {
    .vm-app .ok-column { max-width: 1120px; }
    .vm-app .vm-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .vm-app .vm-os-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
    .vm-app .vm-make { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .vm-app .vm-hero { padding: 28px; }
    .vm-app .vm-hero .ok-hero-stats { max-width: 560px; }
    .vm-app .vm-thumb { width: 120px; }
    /* Sheets become a dialog in the middle instead of a bottom sheet. */
    .vm-app .vm-sheet { align-items: center; padding: 24px; }
    .vm-app .vm-sheet .xa-sheet-card { max-width: 520px; max-height: 90%; border-radius: 26px; border-bottom: 1px solid var(--ok-line); padding-bottom: 20px; }
    .vm-app .vm-sheet .vm-grab { display: none; }
    .vm-app .vm-presets { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@container vmwin (min-width: 1100px) {
    .vm-app .vm-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
