:root{
  --background:rgb(24,24,24);--foreground:rgb(255,255,255);--card:rgb(45,45,45);
  --card-foreground:rgb(255,255,255);--popover:rgb(45,45,45);--popover-foreground:rgb(255,255,255);
  --primary:rgb(131,195,255);--primary-foreground:rgb(13,13,13);--secondary:rgb(54,54,54);
  --secondary-foreground:rgb(255,255,255);--muted:rgb(50,50,50);--muted-foreground:rgb(176,176,176);
  --accent:rgb(13,39,63);--accent-foreground:rgb(255,255,255);--destructive:rgb(180,64,48);
  --border:rgb(76,76,76);--input:rgb(88,88,88);--ring:rgb(131,195,255);
  --viz-series-1:rgb(131,195,255);--viz-series-2:rgb(245,154,86);--viz-series-3:rgb(116,213,139);
  --viz-series-4:rgb(240,143,192);--viz-series-5:rgb(170,145,239);--viz-series-6:rgb(90,203,194);
  --font-size-base:14px;
}
@media (prefers-color-scheme:light){:root{
  --background:rgb(245,248,252);--foreground:rgb(26,28,31);--card:rgb(232,237,244);
  --card-foreground:rgb(26,28,31);--popover:rgb(255,255,255);--popover-foreground:rgb(26,28,31);
  --primary:rgb(51,156,255);--primary-foreground:rgb(255,255,255);--secondary:rgb(255,255,255);
  --secondary-foreground:rgb(26,28,31);--muted:rgb(224,229,235);--muted-foreground:rgb(92,98,108);
  --accent:rgb(229,242,255);--accent-foreground:rgb(26,28,31);--destructive:rgb(190,70,20);
  --border:rgb(204,211,220);--input:rgb(190,198,210);--ring:rgb(51,156,255);
  --viz-series-1:rgb(51,156,255);--viz-series-2:rgb(230,120,45);--viz-series-3:rgb(55,170,90);
  --viz-series-4:rgb(215,90,155);--viz-series-5:rgb(125,90,215);--viz-series-6:rgb(35,155,150);
}}
*{box-sizing:border-box}
html,body{margin:0;min-height:100%;background:#181818;background:var(--background);color:#fff;color:var(--foreground);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif}
body{overflow-x:hidden}
html.nr-immersive,body.nr-immersive{width:100%;height:100%;overflow:hidden;background:#181919}
html,body.mobile-standalone{height:100%;overflow:hidden}
body.mobile-standalone #nova-run-game{height:100vh;height:100dvh;min-height:0;border-radius:0}
button,select{font:inherit}
.form-label{display:block}
.form-select{display:block;width:100%;max-width:190px;padding:7px 28px 7px 10px;color:#fff;color:var(--foreground);background:#363636;background:var(--secondary);border:1px solid #585858;border-color:var(--input);border-radius:8px}
.btn{display:inline-flex;align-items:center;justify-content:center;padding:9px 14px;color:#fff;color:var(--secondary-foreground);background:#363636;background:var(--secondary);border:1px solid #585858;border-color:var(--input);border-radius:10px;cursor:pointer}
.btn-primary{color:#0d0d0d;color:var(--primary-foreground);background:#83c3ff;background:var(--primary);border-color:#83c3ff;border-color:var(--primary)}
.viz-controls{display:flex;flex-wrap:wrap;gap:6px}
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
[hidden]{display:none!important}
#nova-run-game:fullscreen,#nova-run-game:-webkit-full-screen{width:100%;height:100vh;height:100dvh;border-radius:0}
#nova-run-game.is-immersive,#nova-run-game[data-immersive="true"]{width:100vw!important;height:100vh!important;height:100dvh!important;min-height:0!important;border-radius:0!important}

#nova-run-game{
  --background:rgb(24,25,25);--foreground:rgb(248,242,233);--card:rgb(40,41,40);--card-foreground:rgb(248,242,233);
  --primary:rgb(217,119,83);--primary-foreground:rgb(25,22,20);--secondary:rgb(58,58,55);--secondary-foreground:rgb(255,255,255);
  --muted:rgb(50,50,47);--muted-foreground:rgb(197,188,176);--border:rgb(105,98,89);--input:rgb(125,113,101);
  --destructive:rgb(205,78,61);--viz-series-1:rgb(103,165,164);--viz-series-2:rgb(217,119,83);--viz-series-3:rgb(143,187,127);
  --viz-series-4:rgb(203,132,154);--viz-series-5:rgb(151,130,190);position:relative;width:100%;height:620px;height:clamp(500px,72vw,760px);overflow:hidden;background:#181919;color:#f8f2e9;border-radius:12px;user-select:none
}
  #nova-run-game canvas{display:block;width:100%;height:100%;touch-action:none;-webkit-touch-callout:none}
  #nova-run-game .nr-toolbar{position:absolute;z-index:3;top:12px;right:12px;top:max(12px,env(safe-area-inset-top));right:max(12px,env(safe-area-inset-right));display:grid;gap:6px;align-items:start;transition:opacity .16s ease}
  #nova-run-game .nr-toolbar .form-label{margin:0}
  #nova-run-game .nr-brand{position:absolute;z-index:5;top:12px;left:50%;top:max(12px,env(safe-area-inset-top));transform:translateX(-50%);display:flex;flex-direction:column;align-items:center;color:var(--foreground);font-weight:500;letter-spacing:.22em;line-height:1;white-space:nowrap;pointer-events:none;text-shadow:0 0 5px var(--background),0 0 12px var(--viz-series-1),0 0 24px var(--viz-series-2)}
  #nova-run-game .nr-orientation{position:absolute;z-index:5;top:52px;left:12px;top:max(52px,calc(env(safe-area-inset-top) + 44px));left:max(12px,env(safe-area-inset-left));display:none;min-width:70px;min-height:36px;padding:7px 10px;gap:5px;white-space:nowrap;touch-action:manipulation}
  #nova-run-game[data-mode="play"] .nr-orientation{top:10px;top:max(10px,env(safe-area-inset-top))}
  #nova-run-game .nr-quick-controls{position:absolute;z-index:5;top:10px;right:12px;top:max(10px,env(safe-area-inset-top));right:max(12px,env(safe-area-inset-right));display:none;gap:6px}
  #nova-run-game[data-mode="play"] .nr-quick-controls,#nova-run-game[data-mode="pause"] .nr-quick-controls{display:flex}
  #nova-run-game .nr-quick-controls .btn{width:38px;height:38px;min-width:38px;padding:0;border-radius:12px;touch-action:manipulation}
  #nova-run-game[data-mode="pause"] .nr-toolbar{top:58px}
  #nova-run-game .nr-orientation-hint{position:absolute;z-index:6;top:58px;left:50%;max-width:calc(100% - 32px);transform:translateX(-50%);padding:8px 12px;color:var(--foreground);background:var(--card);border:1px solid var(--border);border-radius:10px;text-align:center;white-space:nowrap;pointer-events:none}
  #nova-run-game .nr-touch{position:absolute;z-index:8;left:14px;right:14px;bottom:14px;left:max(14px,env(safe-area-inset-left));right:max(14px,env(safe-area-inset-right));bottom:max(14px,env(safe-area-inset-bottom));display:none;align-items:end;justify-content:space-between;pointer-events:none;-webkit-touch-callout:none}
  #nova-run-game .nr-move{display:none;gap:8px;pointer-events:auto}
  #nova-run-game[data-game-type="challenge"] .nr-move{display:flex}
  #nova-run-game[data-game-type="challenge"] .nr-move .btn{width:58px;height:52px;min-width:58px;padding:0;border-radius:18px;font-size:22px}
  #nova-run-game[data-game-type="challenge"] [data-act="slide"]{display:none}
  #nova-run-game .nr-touch .btn{pointer-events:auto;width:72px;height:52px;min-width:0;min-height:0;padding:4px;touch-action:none;display:flex;gap:4px;align-items:center;justify-content:center;font-size:12px;font-weight:500;white-space:nowrap}
  #nova-run-game .nr-touch [data-act="dash"]{width:60px;height:60px;flex:0 0 60px;border-radius:16px;padding:0}
  #nova-run-game .nr-touch [data-act="dash"] [data-action-label]{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
  #nova-run-game[data-mode="play"] .nr-toolbar{opacity:0;visibility:hidden;pointer-events:none}
  #nova-run-game .nr-error{position:absolute;z-index:10;left:16px;right:16px;top:44%;padding:14px;text-align:center;color:#fff;background:#7a241d;background:var(--destructive);border-radius:10px}
  #nova-run-game[data-touch="true"] .nr-orientation,#nova-run-game[data-touch="true"][data-mode="play"] .nr-orientation{display:inline-flex}
  #nova-run-game[data-touch="true"][data-mode="play"] .nr-touch{display:flex}
  @media(pointer:coarse),(max-width:700px){#nova-run-game .nr-toolbar{top:52px;top:max(52px,calc(env(safe-area-inset-top) + 40px))}#nova-run-game .nr-orientation,#nova-run-game[data-mode="play"] .nr-orientation{display:inline-flex;top:52px;top:max(52px,calc(env(safe-area-inset-top) + 40px))}#nova-run-game[data-mode="play"] .nr-touch{display:flex}}
  @media(orientation:landscape) and (max-height:600px){
    #nova-run-game .nr-toolbar{top:48px;right:8px;top:max(48px,calc(env(safe-area-inset-top) + 40px));display:flex;flex-wrap:nowrap;gap:4px}
    #nova-run-game .nr-toolbar .form-select{max-width:112px;padding-left:7px;padding-right:20px}
    #nova-run-game .nr-brand{top:8px;top:max(8px,env(safe-area-inset-top));letter-spacing:.18em}
    #nova-run-game .nr-orientation,#nova-run-game[data-mode="play"] .nr-orientation{top:48px;left:8px;top:max(48px,calc(env(safe-area-inset-top) + 40px));left:max(8px,env(safe-area-inset-left));min-height:34px;padding:6px 9px}
    #nova-run-game .nr-orientation-hint{top:50px}
    #nova-run-game .nr-touch{left:8px;right:8px;bottom:8px;left:max(8px,env(safe-area-inset-left));right:max(8px,env(safe-area-inset-right));bottom:max(8px,env(safe-area-inset-bottom))}
    #nova-run-game .nr-touch .btn{width:64px;height:44px;padding:4px}
    #nova-run-game .nr-touch .btn>span[aria-hidden="true"]{display:none}
    #nova-run-game .nr-touch [data-act="dash"]{width:56px;height:56px;flex-basis:56px}
    #nova-run-game .nr-touch [data-act="dash"]>span[aria-hidden="true"]{display:inline}
  }
  @media(orientation:landscape) and (max-width:520px){#nova-run-game .nr-toolbar .form-select{max-width:105px}}

/* Phase 4: clearer controls and a restrained neon interface. */
#nova-run-game .nr-toolbar{
  width:220px;padding:12px;gap:9px;background:linear-gradient(145deg,rgba(18,24,31,.94),rgba(38,43,51,.9));
  border:1px solid rgba(131,195,255,.32);border-radius:16px;box-shadow:0 12px 32px rgba(0,0,0,.28),inset 0 1px rgba(255,255,255,.05);
  backdrop-filter:blur(8px)
}
#nova-run-game .nr-settings-heading{display:flex;align-items:center;gap:7px;color:var(--primary);font-size:12px;font-weight:700;letter-spacing:.12em;text-transform:uppercase}
#nova-run-game .nr-field-title{display:block;margin:0 0 4px;color:var(--muted-foreground);font-size:10px;font-weight:700;letter-spacing:.1em;text-transform:uppercase}
#nova-run-game .form-select{max-width:none;height:36px;padding:6px 30px 6px 10px;color:#f8f2e9;background-color:#3b3b38;border-color:#897b6d;outline:none}
#nova-run-game .form-select option{color:#f8f2e9;background:#30302e}
#nova-run-game .form-select option:disabled{color:#a99f92;background:#292927}
#nova-run-game .form-select:focus{border-color:var(--primary);box-shadow:0 0 0 3px rgba(131,195,255,.14)}
#nova-run-game .nr-motion-toggle{display:flex;align-items:center;gap:8px;min-height:32px;color:var(--foreground);font-size:12px;cursor:pointer}
#nova-run-game .nr-motion-toggle input{position:absolute;opacity:0;pointer-events:none}
#nova-run-game .nr-toggle-track{position:relative;width:34px;height:20px;flex:0 0 34px;border-radius:10px;background:var(--muted);border:1px solid var(--border);transition:background .16s ease,border-color .16s ease}
#nova-run-game .nr-toggle-track span{position:absolute;left:3px;top:3px;width:12px;height:12px;border-radius:50%;background:var(--muted-foreground);transition:transform .16s ease,background .16s ease}
#nova-run-game .nr-motion-toggle input:checked+.nr-toggle-track{background:rgba(116,213,139,.22);border-color:var(--viz-series-3)}
#nova-run-game .nr-motion-toggle input:checked+.nr-toggle-track span{transform:translateX(14px);background:var(--viz-series-3)}
#nova-run-game .nr-motion-toggle input:focus-visible+.nr-toggle-track{box-shadow:0 0 0 3px rgba(131,195,255,.24)}
#nova-run-game .btn{color:#fff;background:linear-gradient(145deg,#50504c,#353633);border-color:#85796c;box-shadow:0 5px 14px rgba(0,0,0,.18);font-weight:700;text-shadow:0 1px 2px rgba(0,0,0,.55);transition:transform .12s ease,border-color .12s ease,filter .12s ease}
#nova-run-game .btn-primary{color:#211b18;background:linear-gradient(145deg,#efa27f,#d97753);border-color:#f2b497;text-shadow:none}
#nova-run-game .btn:disabled{color:#c0c8d2;background:#343b45;border-color:#566474;opacity:.72}
#nova-run-game .btn:hover{border-color:var(--primary);filter:brightness(1.08)}
#nova-run-game .btn:active{transform:translateY(1px) scale(.97)}
#nova-run-game .nr-touch .btn.is-pressed{filter:brightness(1.18);transform:translateY(1px) scale(.94);box-shadow:0 2px 7px rgba(0,0,0,.35)}
#nova-run-game .nr-touch [data-act="jump"]{color:#15191e;background:linear-gradient(145deg,#ffc57e,#f59a56);border-color:#ffd29b}
#nova-run-game .nr-touch [data-act="slide"]{color:#101820;background:linear-gradient(145deg,#a8d8ff,#65b2f5);border-color:#c9e8ff}
#nova-run-game .nr-touch [data-act="dash"]{color:#101a13;background:linear-gradient(145deg,#9be9ae,#55c879);border-color:#c5f4d0;box-shadow:0 5px 16px rgba(62,183,99,.28)}
#nova-run-game .nr-move .btn{color:#f8f2e9;background:linear-gradient(145deg,#59636b,#343b40);border-color:#87949d;text-shadow:none;font-size:22px;font-weight:900}
#nova-run-game .nr-brand{font-weight:800;text-shadow:0 1px 4px var(--background),0 0 10px rgba(131,195,255,.45)}
#nova-run-game[data-mode="play"] .nr-orientation{top:10px!important}
#nova-run-game[data-motion="reduced"] *{scroll-behavior:auto!important}
#nova-run-game[data-motion="reduced"] .btn,#nova-run-game[data-motion="reduced"] .nr-toggle-track,#nova-run-game[data-motion="reduced"] .nr-toggle-track span{transition:none!important}

@media(pointer:coarse),(max-width:700px){
  #nova-run-game .nr-toolbar{top:max(52px,calc(env(safe-area-inset-top) + 42px));left:8px;right:8px;width:auto;padding:8px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
  #nova-run-game .nr-settings-heading{display:none}
  #nova-run-game .nr-field-title{margin-bottom:2px;font-size:9px}
  #nova-run-game .form-select{width:100%;height:32px;padding:4px 18px 4px 6px;font-size:11px}
  #nova-run-game .nr-motion-toggle{grid-column:1/-1;justify-content:center;min-height:26px;font-size:11px}
  #nova-run-game[data-mode="play"] .nr-orientation{top:max(8px,env(safe-area-inset-top))!important}
}
@media(orientation:landscape) and (max-height:460px){
  #nova-run-game .nr-toolbar{top:max(43px,calc(env(safe-area-inset-top) + 36px));padding:5px 7px;gap:4px}
  #nova-run-game .nr-field-title{display:none}
  #nova-run-game .form-select{height:29px}
  #nova-run-game .nr-motion-toggle{position:absolute;right:6px;top:35px;width:auto;padding:2px 6px;background:rgba(18,24,31,.82);border-radius:10px}
  #nova-run-game .nr-toggle-track{width:29px;height:17px;flex-basis:29px}
  #nova-run-game .nr-toggle-track span{width:9px;height:9px}
  #nova-run-game .nr-motion-toggle input:checked+.nr-toggle-track span{transform:translateX(12px)}
}

/* 2026-07 mobile reliability pass. These rules intentionally sit last so older
   phase styles cannot re-introduce fixed-size controls or off-screen panels. */
#nova-run-game{
  min-height:0;
  height:100vh;
  height:100dvh;
}
#nova-run-game .nr-toolbar,
#nova-run-game .nr-profile-panel,
#nova-run-game .nr-results{
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
}
#nova-run-game .nr-settings-heading{
  position:sticky;
  z-index:3;
  top:-18px;
  display:flex!important;
  margin:-18px -18px 0;
  padding:14px 18px 11px;
  background:linear-gradient(180deg,rgba(31,32,31,.99) 82%,rgba(31,32,31,0));
}
#nova-run-game .nr-scene-card[data-locked="true"]{cursor:help;opacity:.72}
#nova-run-game .nr-scene-card[data-locked="true"]:hover{transform:none;border-color:rgba(231,199,171,.25);box-shadow:0 7px 18px rgba(0,0,0,.16)}
#nova-run-game .nr-scene-card.is-choosing{transform:scale(.985);filter:brightness(1.13)}
#nova-run-game .nr-scene-card.is-selected{transform:translateY(-1px);box-shadow:0 0 0 2px rgba(217,119,83,.3),0 10px 24px rgba(0,0,0,.23)}

/* Finger-sized but visually compact controls. Endless mode leaves the entire
   left side clear; challenge mode alone exposes the movement cluster. */
#nova-run-game .nr-touch{
  gap:clamp(8px,2vw,16px);
  align-items:flex-end;
}
#nova-run-game .nr-touch .btn{
  width:clamp(52px,15vw,66px);
  height:clamp(48px,6.7vh,56px);
  min-width:48px;
  min-height:48px;
  padding:5px 7px;
  border-radius:15px;
  font-size:clamp(11px,3.1vw,13px);
}
#nova-run-game .nr-touch [data-act="dash"]{
  width:clamp(56px,16vw,66px);
  height:clamp(56px,16vw,66px);
  min-width:56px;
  min-height:56px;
  flex:0 0 clamp(56px,16vw,66px);
}
#nova-run-game[data-game-type="challenge"] .nr-move .btn{
  width:clamp(50px,14vw,60px);
  height:clamp(48px,6.7vh,56px);
  min-width:48px;
  min-height:48px;
}

@media(max-width:700px){
  #nova-run-game .nr-toolbar{
    top:max(48px,calc(env(safe-area-inset-top) + 40px));
    bottom:max(8px,env(safe-area-inset-bottom));
    max-height:none;
    height:auto;
    padding:18px;
    padding-bottom:max(18px,calc(env(safe-area-inset-bottom) + 12px));
    overflow-x:hidden;
    overflow-y:auto;
    -webkit-overflow-scrolling:touch;
    mask-image:linear-gradient(to bottom,transparent 0,#000 18px,#000 calc(100% - 18px),transparent 100%);
  }
  #nova-run-game .nr-toolbar:focus-within{mask-image:none}
  #nova-run-game .nr-settings-heading{top:-18px}
  #nova-run-game .nr-scene-grid{scroll-snap-type:x proximity}
  #nova-run-game .nr-scene-card{touch-action:manipulation}
}

@media(orientation:portrait) and (max-width:700px){
  #nova-run-game .nr-touch{
    left:max(10px,env(safe-area-inset-left));
    right:max(10px,env(safe-area-inset-right));
    bottom:max(10px,calc(env(safe-area-inset-bottom) + 6px));
  }
  #nova-run-game[data-game-type="runner"] .nr-touch{justify-content:flex-end}
}

@media(orientation:landscape) and (max-height:520px){
  #nova-run-game[data-mode="play"] .nr-touch{display:flex}
  #nova-run-game .nr-orientation,#nova-run-game[data-mode="play"] .nr-orientation{display:inline-flex}
  #nova-run-game[data-mode="menu"] .nr-menu-console{
    top:max(8px,env(safe-area-inset-top));
    right:max(10px,env(safe-area-inset-right));
    bottom:max(8px,env(safe-area-inset-bottom));
    transform:none!important;
    max-height:calc(100vh - 16px);
    max-height:calc(100dvh - 16px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    overflow-x:hidden;
    overflow-y:auto;
    overscroll-behavior:contain;
  }
  #nova-run-game .nr-menu-start{position:sticky;z-index:2;bottom:0}
  #nova-run-game.settings-open .nr-toolbar{
    top:max(8px,env(safe-area-inset-top));
    bottom:max(8px,env(safe-area-inset-bottom));
    max-height:none;
    height:auto;
  }
  #nova-run-game .nr-touch{
    left:max(10px,env(safe-area-inset-left));
    right:max(10px,env(safe-area-inset-right));
    bottom:max(8px,calc(env(safe-area-inset-bottom) + 4px));
  }
  #nova-run-game .nr-touch .btn{
    width:clamp(52px,7vw,64px);
    height:clamp(48px,13vh,56px);
    min-width:48px;
    min-height:48px;
    padding:5px;
    font-size:clamp(10px,1.5vw,12px);
  }
  #nova-run-game .nr-touch [data-act="dash"]{
    width:clamp(56px,7.3vw,64px);
    height:clamp(56px,7.3vw,64px);
    min-width:56px;
    min-height:56px;
    flex-basis:clamp(56px,7.3vw,64px);
  }
  #nova-run-game[data-game-type="challenge"] .nr-move .btn{
    width:clamp(50px,6.5vw,58px);
    height:clamp(48px,13vh,54px);
  }
  #nova-run-game .nr-scene-grid{grid-template-columns:repeat(3,minmax(150px,1fr))}
}

@media(prefers-reduced-motion:reduce){
  #nova-run-game .nr-scene-card{transition:none}
}
@media(max-width:360px){#nova-run-game .nr-brand{font-size:11px;letter-spacing:.12em}}
@media(prefers-reduced-motion:reduce){#nova-run-game .btn,#nova-run-game .nr-toggle-track,#nova-run-game .nr-toggle-track span{transition:none}}

/* Phase 5 panels: plain HTML keeps settings, results and sharing accessible. */
#nova-run-game .nr-toolbar{display:none;z-index:9;top:max(58px,calc(env(safe-area-inset-top) + 48px));right:max(10px,env(safe-area-inset-right));width:min(360px,calc(100% - 20px));max-height:calc(100% - 72px);overflow:auto;grid-template-columns:1fr 1fr;padding:14px}
#nova-run-game.settings-open .nr-toolbar{display:grid!important;opacity:1!important;visibility:visible!important;pointer-events:auto!important}
#nova-run-game .nr-settings-heading,#nova-run-game .nr-motion-toggle,#nova-run-game .nr-clear-save{grid-column:1/-1}
#nova-run-game .nr-settings-grid{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:6px 10px}
#nova-run-game .nr-check{display:flex;align-items:center;gap:6px;color:var(--foreground);font-size:11px}
#nova-run-game .nr-check input{accent-color:var(--viz-series-3)}
#nova-run-game .nr-range{display:grid;gap:4px;color:var(--muted-foreground);font-size:10px;font-weight:700;letter-spacing:.04em}
#nova-run-game .nr-range input{width:100%;accent-color:var(--primary)}
#nova-run-game .nr-clear-save{color:#fff;background:rgba(180,64,48,.22);border-color:var(--destructive)}
#nova-run-game .nr-quick-controls{display:flex!important}
#nova-run-game:not([data-mode="play"]):not([data-mode="pause"]) .nr-inplay{display:none}
#nova-run-game[data-mode="play"] [data-open-profile],#nova-run-game[data-mode="pause"] [data-open-profile]{display:none}
#nova-run-game[data-mode="over"] .nr-quick-controls{display:none!important}
#nova-run-game .nr-touch{opacity:var(--touch-opacity,.9)}
#nova-run-game[data-contrast="high"]{filter:contrast(1.18) saturate(1.12)}
#nova-run-game[data-contrast="high"] canvas{outline:2px solid var(--foreground);outline-offset:-2px}

#nova-run-game .nr-profile-panel,#nova-run-game .nr-results,#nova-run-game .nr-share-panel,#nova-run-game .nr-confirm{position:absolute;z-index:8;color:var(--foreground);background:linear-gradient(145deg,rgba(37,38,37,.99),rgba(25,26,26,.99));border:1px solid rgba(217,119,83,.42);box-shadow:0 18px 46px rgba(0,0,0,.42);backdrop-filter:blur(8px)}
#nova-run-game .nr-profile-panel{left:max(12px,env(safe-area-inset-left));bottom:max(12px,env(safe-area-inset-bottom));width:min(380px,calc(100% - 24px));max-height:calc(100% - 72px);overflow:auto;padding:14px;border-radius:18px}
#nova-run-game .nr-panel-head,#nova-run-game .nr-result-head{display:flex;align-items:center;justify-content:space-between;color:var(--primary);letter-spacing:.08em}
#nova-run-game .nr-panel-head button{width:28px;height:28px;color:var(--foreground);background:transparent;border:1px solid var(--border);border-radius:10px}
#nova-run-game .nr-stat-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin:12px 0}
#nova-run-game .nr-stat{padding:9px;background:rgba(0,0,0,.2);border:1px solid var(--border);border-radius:10px}
#nova-run-game .nr-stat span{display:block;color:var(--muted-foreground);font-size:9px;text-transform:uppercase}
#nova-run-game .nr-stat strong{font-size:16px}
#nova-run-game .nr-profile-panel h3{margin:12px 0 7px;color:var(--muted-foreground);font-size:10px;letter-spacing:.12em;text-transform:uppercase}
#nova-run-game .nr-daily-item{display:grid;grid-template-columns:1fr auto;gap:4px;margin:6px 0;font-size:11px}
#nova-run-game .nr-daily-bar{grid-column:1/-1;height:5px;background:var(--muted);border-radius:3px;overflow:hidden}
#nova-run-game .nr-daily-bar i{display:block;height:100%;background:var(--viz-series-3)}
#nova-run-game .nr-achievement-list{display:flex;flex-wrap:wrap;gap:5px}
#nova-run-game .nr-achievement{padding:5px 8px;color:var(--muted-foreground);background:rgba(0,0,0,.18);border:1px solid var(--border);border-radius:10px;font-size:10px}
#nova-run-game .nr-achievement.unlocked{color:var(--foreground);border-color:var(--viz-series-3)}

#nova-run-game .nr-tutorial{position:absolute;z-index:7;left:50%;top:max(154px,calc(env(safe-area-inset-top) + 132px));transform:translateX(-50%);width:min(420px,calc(100% - 28px));padding:13px 15px;text-align:center;color:var(--foreground);background:rgba(24,29,36,.94);border:1px solid var(--viz-series-3);border-radius:16px;pointer-events:none}
#nova-run-game .nr-tutorial-step{color:var(--viz-series-3);font-size:9px;font-weight:800;letter-spacing:.15em}
#nova-run-game .nr-tutorial strong{display:block;margin-top:4px;font-size:18px}
#nova-run-game .nr-tutorial p{margin:5px 0 9px;color:var(--muted-foreground);font-size:12px}
#nova-run-game .nr-tutorial .btn{pointer-events:auto;padding:5px 10px;font-size:10px}

#nova-run-game .nr-results{left:50%;top:50%;transform:translate(-50%,-50%);width:min(580px,calc(100% - 28px));padding:18px;border-radius:22px}
#nova-run-game .nr-result-record{color:var(--viz-series-3);font-size:11px}
#nova-run-game .nr-result-score{margin:14px 0 11px;text-align:center;font-size:34px;font-weight:800}
#nova-run-game .nr-result-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:7px}
#nova-run-game .nr-result-item{padding:9px 11px;background:rgba(0,0,0,.22);border:1px solid var(--border);border-radius:11px}
#nova-run-game .nr-result-item span{display:block;color:var(--muted-foreground);font-size:9px;text-transform:uppercase}
#nova-run-game .nr-result-item strong{font-size:13px}
#nova-run-game .nr-result-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-top:13px}
#nova-run-game .nr-share-panel{z-index:10;left:50%;top:50%;transform:translate(-50%,-50%);width:min(520px,calc(100% - 28px));padding:18px;border-radius:22px}
#nova-run-game .nr-share-panel p{margin:12px 0 8px;color:var(--muted-foreground);font-size:12px;line-height:1.55}
#nova-run-game .nr-share-panel textarea{display:block;width:100%;height:126px;resize:none;padding:12px;color:var(--foreground);background:rgba(0,0,0,.22);border:1px solid var(--border);border-radius:12px;font:500 12px/1.55 ui-monospace,monospace;outline:none}
#nova-run-game .nr-share-panel textarea:focus{border-color:var(--primary);box-shadow:0 0 0 3px rgba(217,119,83,.16)}
#nova-run-game .nr-share-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
#nova-run-game .nr-confirm{left:50%;top:50%;transform:translate(-50%,-50%);width:min(390px,calc(100% - 28px));padding:18px;text-align:center;border-color:var(--destructive);border-radius:18px}
#nova-run-game .nr-confirm{z-index:11}
#nova-run-game .nr-confirm p{color:var(--muted-foreground);font-size:12px}.nr-confirm>div{display:flex;justify-content:center;gap:8px}.nr-danger{color:#fff!important;background:var(--destructive)!important}
#nova-run-game .nr-toast{position:absolute;z-index:12;left:50%;bottom:max(18px,env(safe-area-inset-bottom));transform:translateX(-50%);max-width:calc(100% - 30px);padding:9px 13px;color:var(--foreground);background:rgba(24,29,36,.96);border:1px solid var(--viz-series-3);border-radius:12px;font-size:12px;text-align:center}

@media(max-width:700px){
  #nova-run-game .nr-toolbar{left:8px;right:8px;top:max(48px,calc(env(safe-area-inset-top) + 40px));width:auto;max-height:calc(100% - 58px);grid-template-columns:1fr 1fr}
  #nova-run-game .nr-toolbar .nr-field-title{display:block}
  #nova-run-game .nr-motion-toggle{position:static;width:auto;padding:0;background:transparent}
  #nova-run-game .nr-results{padding:14px}.nr-result-score{font-size:28px!important}
}
@media(max-width:480px){#nova-run-game [data-quick="sound"]{display:none}}
@media(orientation:landscape) and (max-height:430px){
  #nova-run-game .nr-tutorial{top:48px;left:96px;transform:none;width:min(330px,55%);padding:8px}
  #nova-run-game .nr-tutorial p{margin:2px 0 5px}
  #nova-run-game .nr-results{width:min(680px,calc(100% - 22px));padding:10px 14px}
  #nova-run-game .nr-result-score{display:inline-block;width:31%;margin:8px 0;font-size:25px}
  #nova-run-game .nr-result-grid{display:inline-grid;width:67%;vertical-align:middle;grid-template-columns:repeat(3,1fr)}
  #nova-run-game .nr-result-actions{grid-template-columns:repeat(4,1fr);margin-top:8px}
  #nova-run-game .nr-result-actions .btn{padding:7px 5px;font-size:11px}
  #nova-run-game .nr-profile-panel{top:48px;bottom:8px;width:min(540px,calc(100% - 24px))}
}

/* Explicit day mode. It is selected inside the game and does not depend on OS theme. */
#nova-run-game[data-theme="light"]{
  --background:rgb(244,239,231);--foreground:rgb(43,37,32);--card:rgb(255,251,244);--card-foreground:rgb(43,37,32);
  --primary:rgb(190,88,55);--primary-foreground:rgb(255,255,255);--secondary:rgb(235,226,215);--secondary-foreground:rgb(43,37,32);
  --muted:rgb(231,221,209);--muted-foreground:rgb(91,78,66);--border:rgb(171,151,132);--input:rgb(154,129,107);
  --destructive:rgb(184,58,45);--viz-series-1:rgb(55,124,127);--viz-series-2:rgb(190,88,55);--viz-series-3:rgb(76,124,73);
  --viz-series-4:rgb(166,78,112);--viz-series-5:rgb(105,84,158);background:#f4efe7;color:#2b2520
}
#nova-run-game[data-theme="light"] .nr-toolbar{background:linear-gradient(145deg,rgba(255,252,246,.99),rgba(237,228,216,.98));border-color:#b79a80;box-shadow:0 12px 32px rgba(76,57,41,.18)}
#nova-run-game[data-theme="light"] .form-select{color:#2b2520;background:#fffaf2;border-color:#aa8d73}
#nova-run-game[data-theme="light"] .form-select option{color:#2b2520;background:#fffaf2}
#nova-run-game[data-theme="light"] .form-select option:disabled{color:#88786a;background:#eee5da}
#nova-run-game[data-theme="light"] .btn{color:#2b2520;background:linear-gradient(145deg,#fffdf8,#e8ded2);border-color:#aa8d73;text-shadow:none;box-shadow:0 4px 12px rgba(76,57,41,.14)}
#nova-run-game[data-theme="light"] .btn-primary{color:#fff;background:linear-gradient(145deg,#d97b59,#b95738);border-color:#9d472e}
#nova-run-game[data-theme="light"] .nr-profile-panel,#nova-run-game[data-theme="light"] .nr-results,#nova-run-game[data-theme="light"] .nr-share-panel,#nova-run-game[data-theme="light"] .nr-confirm{color:#2b2520;background:linear-gradient(145deg,rgba(255,252,246,.99),rgba(235,225,213,.99));border-color:#b59477;box-shadow:0 18px 42px rgba(76,57,41,.2)}
#nova-run-game[data-theme="light"] .nr-tutorial,#nova-run-game[data-theme="light"] .nr-toast{color:#2b2520;background:rgba(255,251,244,.98);border-color:#8d6b4e}
#nova-run-game[data-theme="light"] .nr-stat,#nova-run-game[data-theme="light"] .nr-result-item,#nova-run-game[data-theme="light"] .nr-achievement{background:rgba(213,193,171,.28)}
#nova-run-game[data-theme="light"] .nr-share-panel textarea{color:#2b2520;background:#fffaf2}
#nova-run-game[data-theme="light"] .nr-clear-save{color:#fff;background:#b83a2d;border-color:#942b21}
#nova-run-game[data-theme="light"] .nr-orientation-hint{color:#172231;background:#fff}

/* Original NOVA RUN brand lockup: orbit badge, sprinting N and creator seal. */
#nova-run-game .nr-brand{top:max(9px,env(safe-area-inset-top));display:flex;align-items:center;gap:3px;font-weight:700;letter-spacing:normal;text-shadow:none;filter:drop-shadow(0 3px 7px rgba(0,0,0,.28));transition:transform .18s ease}
#nova-run-game .nr-wordmark{display:flex;align-items:center;gap:8px}
#nova-run-game .nr-logo-mark{width:29px;height:29px;overflow:visible}
#nova-run-game .nr-logo-orbit{fill:rgba(20,23,28,.82);stroke:var(--viz-series-1);stroke-width:2.4;stroke-linejoin:round;stroke-dasharray:9 3;animation:nr-orbit-flow 2.8s linear infinite}
#nova-run-game .nr-logo-n{fill:none;stroke:var(--foreground);stroke-width:5.3;stroke-linecap:round;stroke-linejoin:round}
#nova-run-game .nr-logo-boost{fill:var(--viz-series-2);stroke:var(--foreground);stroke-width:1.2}
#nova-run-game .nr-logo-star{fill:var(--viz-series-3);stroke:var(--foreground);stroke-width:1;transform-origin:47px 8px;animation:nr-star-pulse 1.6s ease-in-out infinite}
#nova-run-game .nr-title{display:flex;align-items:baseline;gap:6px;font-family:"Arial Black","Segoe UI",system-ui,sans-serif;font-size:21px;font-style:normal;line-height:.9;transform:skewX(-7deg)}
#nova-run-game .nr-title strong{color:var(--foreground);font-weight:900;letter-spacing:.1em;text-shadow:2px 2px 0 rgba(131,195,255,.18)}
#nova-run-game .nr-title em{color:var(--viz-series-2);font-weight:900;font-style:normal;letter-spacing:.04em;text-shadow:2px 2px 0 rgba(245,154,86,.16)}
#nova-run-game .nr-creator{display:flex;align-items:center;gap:5px;padding:3px 8px;color:var(--muted-foreground);background:rgba(20,23,28,.74);border:1px solid rgba(131,195,255,.38);border-radius:999px;font-size:8px;font-weight:800;letter-spacing:.13em;line-height:1}
#nova-run-game .nr-creator strong{color:var(--viz-series-3);font-size:10px;letter-spacing:.16em}
#nova-run-game .nr-creator i{display:block;width:12px;height:1px;background:linear-gradient(90deg,transparent,var(--viz-series-1))}
#nova-run-game .nr-creator i:last-child{transform:scaleX(-1)}
#nova-run-game[data-mode="menu"] .nr-brand{top:max(12px,env(safe-area-inset-top));gap:5px}
#nova-run-game[data-mode="menu"] .nr-logo-mark{width:42px;height:42px}
#nova-run-game[data-mode="menu"] .nr-title{gap:8px;font-size:32px}
#nova-run-game[data-mode="menu"] .nr-creator{padding:4px 10px;font-size:9px}
#nova-run-game[data-mode="menu"] .nr-creator strong{font-size:12px}
#nova-run-game[data-theme="light"] .nr-logo-orbit{fill:rgba(255,255,255,.9)}
#nova-run-game[data-theme="light"] .nr-creator{color:#52667c;background:rgba(255,255,255,.88);border-color:#6795c0}
#nova-run-game[data-theme="light"] .nr-title strong{text-shadow:2px 2px 0 rgba(35,132,222,.13)}
@keyframes nr-orbit-flow{to{stroke-dashoffset:-24}}
@keyframes nr-star-pulse{50%{transform:scale(1.35);opacity:.72}}
#nova-run-game[data-motion="reduced"] .nr-logo-orbit,#nova-run-game[data-motion="reduced"] .nr-logo-star{animation:none}

@media(pointer:coarse),(max-width:700px){
  #nova-run-game[data-mode="menu"] .nr-orientation{top:max(88px,calc(env(safe-area-inset-top) + 78px))}
  #nova-run-game[data-mode="menu"] .nr-quick-controls{top:max(88px,calc(env(safe-area-inset-top) + 78px))}
}
@media(max-width:480px){
  #nova-run-game .nr-brand{gap:1px}
  #nova-run-game .nr-logo-mark{width:21px;height:21px}
  #nova-run-game .nr-wordmark{gap:5px}
  #nova-run-game .nr-title{gap:4px;font-size:15px}
  #nova-run-game .nr-creator{gap:3px;padding:2px 5px;font-size:6px}
  #nova-run-game .nr-creator strong{font-size:8px}
  #nova-run-game .nr-creator i{width:6px}
  #nova-run-game[data-mode="menu"] .nr-logo-mark{width:34px;height:34px}
  #nova-run-game[data-mode="menu"] .nr-title{gap:6px;font-size:25px}
  #nova-run-game[data-mode="menu"] .nr-creator{padding:3px 7px;font-size:7px}
  #nova-run-game[data-mode="menu"] .nr-creator strong{font-size:10px}
}

/* Premium menu console: one real HTML control layer replaces the old canvas pseudo-buttons. */
#nova-run-game .nr-menu-console{display:none}
#nova-run-game[data-mode="menu"] .nr-quick-controls{display:none!important}
#nova-run-game[data-mode="menu"] .nr-brand{left:max(34px,env(safe-area-inset-left));transform:none;align-items:flex-start}
#nova-run-game[data-mode="menu"] .nr-menu-console{
  position:absolute;z-index:5;top:50%;right:max(34px,env(safe-area-inset-right));display:block;width:min(410px,calc(100% - 68px));
  padding:20px;color:#f8f2e9;background:linear-gradient(142deg,rgba(35,35,33,.94),rgba(22,23,23,.88));
  border:1px solid rgba(231,199,171,.46);border-radius:6px 24px 6px 24px;box-shadow:0 28px 70px rgba(12,10,9,.42),inset 0 1px rgba(255,255,255,.08);
  backdrop-filter:blur(14px);transform:translateY(-42%);isolation:isolate
}
#nova-run-game[data-mode="menu"] .nr-menu-console:before{content:"";position:absolute;z-index:-1;left:-1px;top:28px;bottom:28px;width:4px;background:linear-gradient(#db7855,#69a7a6);border-radius:0 4px 4px 0}
#nova-run-game .nr-menu-kicker{display:grid;grid-template-columns:26px auto 1fr;align-items:center;gap:8px;color:#d97753;font-size:9px;font-weight:800;letter-spacing:.17em;text-transform:uppercase}
#nova-run-game .nr-menu-kicker>span{height:2px;background:#d97753}
#nova-run-game .nr-menu-kicker>i{justify-self:end;color:#a9a197;font-family:ui-monospace,"SFMono-Regular",Consolas,monospace;font-style:normal;letter-spacing:.1em}
#nova-run-game .nr-menu-route{margin-top:16px;padding:0 2px}
#nova-run-game .nr-menu-route>p:first-child{margin:0 0 5px;color:#a9a197;font-size:9px;font-weight:800;letter-spacing:.16em;text-transform:uppercase}
#nova-run-game .nr-menu-route h1{margin:0;max-width:100%;overflow-wrap:anywhere;color:#fff9f0;font-family:Georgia,"Times New Roman","Noto Serif SC",serif;font-size:34px;font-weight:650;line-height:1.08;letter-spacing:-.025em}
#nova-run-game .nr-menu-meta{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:17px 0 12px}
#nova-run-game .nr-menu-meta>span{position:relative;display:grid;grid-template-columns:5px 1fr;gap:2px 7px;min-width:0;padding:9px 10px;background:rgba(249,240,227,.055);border:1px solid rgba(231,199,171,.19);border-radius:3px 12px 3px 12px}
#nova-run-game .nr-menu-meta i{grid-row:1/3;align-self:stretch;width:3px;background:#69a7a6;border-radius:2px}
#nova-run-game .nr-menu-meta b{color:#9e978e;font-size:8px;font-weight:800;letter-spacing:.13em;text-transform:uppercase}
#nova-run-game .nr-menu-meta strong{overflow:hidden;color:#f8f2e9;font-size:11px;font-weight:750;text-overflow:ellipsis;white-space:nowrap}
#nova-run-game .nr-menu-features{margin:0;color:#c9c0b5;font-size:11px;line-height:1.55}
#nova-run-game .nr-menu-start{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:64px;margin:18px 0 9px;padding:10px 12px 10px 17px;color:#251f1c;background:linear-gradient(115deg,#f0c6a6,#d97753 72%);border:0;border-radius:3px 18px 3px 18px;box-shadow:0 12px 28px rgba(217,119,83,.24);cursor:pointer;text-align:left;transition:transform .15s ease,filter .15s ease,box-shadow .15s ease}
#nova-run-game .nr-menu-start span{display:grid;gap:3px}
#nova-run-game .nr-menu-start small{font-size:8px;font-weight:850;letter-spacing:.19em;text-transform:uppercase;opacity:.68}
#nova-run-game .nr-menu-start strong{font-family:Georgia,"Times New Roman","Noto Serif SC",serif;font-size:21px;letter-spacing:.02em}
#nova-run-game .nr-menu-start>i{display:grid;place-items:center;width:40px;height:40px;color:#fff7ed;background:#2c2b29;border-radius:12px;font-family:system-ui;font-size:22px;font-style:normal;transition:transform .15s ease}
#nova-run-game .nr-menu-start>i svg{display:block;width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
#nova-run-game .nr-menu-start:hover{filter:brightness(1.06);box-shadow:0 15px 34px rgba(217,119,83,.32);transform:translateY(-2px)}
#nova-run-game .nr-menu-start:hover>i{transform:translateX(2px)}
#nova-run-game .nr-menu-start:focus-visible,#nova-run-game .nr-menu-actions button:focus-visible{outline:3px solid #8cc1c0;outline-offset:3px}
#nova-run-game .nr-menu-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}
#nova-run-game .nr-menu-actions button{display:flex;align-items:center;justify-content:center;gap:7px;min-height:40px;padding:7px 9px;color:#f8f2e9;background:rgba(248,242,233,.055);border:1px solid rgba(231,199,171,.25);border-radius:3px 12px 3px 12px;cursor:pointer}
#nova-run-game .nr-menu-actions button:hover{background:rgba(248,242,233,.11);border-color:#69a7a6}
#nova-run-game .nr-menu-actions span{color:#7ab1b0;font-size:16px}
#nova-run-game .nr-menu-actions span svg{display:block;width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
#nova-run-game .nr-menu-actions b{font-size:10px;font-weight:750;letter-spacing:.06em}
#nova-run-game .nr-controls-help-wrap{position:relative;display:none;height:8px;margin-top:6px;align-items:center;justify-content:center}
#nova-run-game .nr-controls-help{display:block;width:8px;height:8px;padding:0;background:#857d73;border:1px solid rgba(240,229,215,.28);border-radius:4px;box-shadow:none;opacity:.62;cursor:help;transition:opacity .14s ease,background-color .14s ease,transform .12s ease}
#nova-run-game .nr-controls-help:hover,#nova-run-game .nr-controls-help:focus-visible{background:#d47757;opacity:1;transform:scale(1.12)}
#nova-run-game .nr-controls-help:focus-visible{outline:2px solid #74aaa9;outline-offset:3px}
#nova-run-game .nr-controls-tooltip{position:absolute;z-index:4;left:50%;top:calc(100% + 8px);width:max-content;max-width:min(360px,calc(100vw - 32px));padding:8px 11px;color:#eee6dc;background:rgba(31,32,31,.98);border:1px solid rgba(103,165,164,.44);border-left:3px solid #d47757;border-radius:4px 11px 4px 11px;box-shadow:0 10px 24px rgba(0,0,0,.28);font-size:10px;line-height:1.45;text-align:center;white-space:normal;opacity:0;visibility:hidden;pointer-events:none;transform:translate(-50%,-3px);transition:opacity .14s ease,transform .14s ease}
#nova-run-game .nr-controls-help-wrap.is-open .nr-controls-tooltip,#nova-run-game .nr-controls-help-wrap:focus-within .nr-controls-tooltip{opacity:1;visibility:visible;transform:translate(-50%,0)}
@media(hover:hover) and (pointer:fine){#nova-run-game .nr-controls-help-wrap{display:flex}}
@media(hover:none),(pointer:coarse){#nova-run-game .nr-controls-help-wrap{display:none!important;height:0!important;margin:0!important;pointer-events:none!important}}
@media(max-width:700px){#nova-run-game .nr-controls-help-wrap{display:none!important;height:0!important;margin:0!important}}
#nova-run-game[data-theme="light"] .nr-controls-help{background:#9b8f82;border-color:#c7b8a8}
#nova-run-game[data-theme="light"] .nr-controls-help:hover,#nova-run-game[data-theme="light"] .nr-controls-help:focus-visible{background:#bd6248}
#nova-run-game[data-theme="light"] .nr-controls-tooltip{color:#403a34;background:#f4ede5;border-color:rgba(68,126,151,.38);border-left-color:#bd6248;box-shadow:0 10px 24px rgba(78,58,42,.18)}

/* The remaining system panels use the same editorial geometry and spacing language. */
#nova-run-game .nr-toolbar,#nova-run-game .nr-profile-panel,#nova-run-game .nr-results,#nova-run-game .nr-share-panel,#nova-run-game .nr-confirm{border-radius:5px 22px 5px 22px;border-left:4px solid var(--viz-series-2)}
#nova-run-game .nr-toolbar{padding:18px;gap:12px}
#nova-run-game .nr-settings-heading,#nova-run-game .nr-panel-head,#nova-run-game .nr-result-head{padding-bottom:9px;border-bottom:1px solid color-mix(in srgb,var(--border) 65%,transparent)}
#nova-run-game .nr-panel-tabs{grid-column:1/-1;position:sticky;z-index:2;top:30px;display:grid;grid-template-columns:repeat(3,1fr);gap:4px;padding:4px;background:rgba(24,25,25,.94);border:1px solid var(--border);border-radius:12px}
#nova-run-game .nr-panel-tabs button{min-height:38px;padding:6px;color:var(--muted-foreground);background:transparent;border:0;border-radius:9px;font-size:12px;font-weight:750;cursor:pointer;touch-action:manipulation}
#nova-run-game .nr-panel-tabs button[aria-selected="true"]{color:var(--foreground);background:var(--secondary);box-shadow:inset 0 0 0 1px var(--viz-series-2)}
#nova-run-game .nr-panel-tabs button:focus-visible{outline:3px solid var(--viz-series-1);outline-offset:2px}
#nova-run-game .nr-result-item,#nova-run-game .nr-stat{border-radius:3px 12px 3px 12px}
#nova-run-game .nr-result-actions .btn{min-height:42px;border-radius:3px 12px 3px 12px}

@media(max-width:700px){
  #nova-run-game[data-mode="menu"] .nr-brand{left:50%;top:max(10px,env(safe-area-inset-top));transform:translateX(-50%);align-items:center}
  #nova-run-game[data-mode="menu"] .nr-menu-console{top:auto;right:max(12px,env(safe-area-inset-right));bottom:max(12px,env(safe-area-inset-bottom));left:max(12px,env(safe-area-inset-left));width:auto;padding:15px;transform:none;border-radius:5px 20px 5px 20px}
  #nova-run-game[data-mode="menu"] .nr-menu-route{margin-top:10px}
  #nova-run-game .nr-menu-route h1{font-size:clamp(24px,7.2vw,31px)}
  #nova-run-game .nr-menu-meta{margin:11px 0 8px}
  #nova-run-game .nr-menu-start{min-height:56px;margin:12px 0 8px}
  #nova-run-game .nr-menu-start strong{font-size:19px}
  #nova-run-game .nr-menu-start>i{width:36px;height:36px}
}
@media(orientation:landscape) and (max-height:460px){
  #nova-run-game[data-mode="menu"] .nr-brand{left:max(14px,env(safe-area-inset-left));top:max(8px,env(safe-area-inset-top));transform:none;align-items:flex-start}
  #nova-run-game[data-mode="menu"] .nr-logo-mark{width:27px;height:27px}
  #nova-run-game[data-mode="menu"] .nr-title{font-size:20px}
  #nova-run-game[data-mode="menu"] .nr-creator{padding:2px 6px;font-size:6px}
  #nova-run-game[data-mode="menu"] .nr-creator strong{font-size:8px}
  #nova-run-game[data-mode="menu"] .nr-orientation{top:max(65px,calc(env(safe-area-inset-top) + 57px));left:max(10px,env(safe-area-inset-left))}
  #nova-run-game[data-mode="menu"] .nr-menu-console{top:max(8px,env(safe-area-inset-top));right:max(10px,env(safe-area-inset-right));bottom:max(8px,env(safe-area-inset-bottom));left:auto;width:min(355px,57vw);padding:11px 13px;overflow:auto}
  #nova-run-game .nr-menu-kicker{font-size:7px}
  #nova-run-game[data-mode="menu"] .nr-menu-route{margin-top:7px}
  #nova-run-game .nr-menu-route>p:first-child{display:none}
  #nova-run-game .nr-menu-route h1{font-size:23px}
  #nova-run-game .nr-menu-meta{margin:8px 0 6px}
  #nova-run-game .nr-menu-meta>span{padding:6px 8px}
  #nova-run-game .nr-menu-features{display:none}
  #nova-run-game .nr-menu-start{min-height:48px;margin:8px 0 6px;padding:6px 8px 6px 13px}
  #nova-run-game .nr-menu-start strong{font-size:17px}
  #nova-run-game .nr-menu-start>i{width:32px;height:32px;font-size:18px}
  #nova-run-game .nr-menu-actions button{min-height:34px;padding:5px 7px}
}
@media(max-width:360px) and (orientation:portrait){
  #nova-run-game[data-mode="menu"] .nr-menu-console{padding:12px}
  #nova-run-game .nr-menu-kicker{font-size:7px}
  #nova-run-game .nr-menu-meta>span{padding:7px 8px}
  #nova-run-game .nr-menu-features{font-size:9px}
  #nova-run-game .nr-menu-actions button{min-height:36px}
}
@supports not (color:color-mix(in srgb,white,black)){#nova-run-game .nr-settings-heading,#nova-run-game .nr-panel-head,#nova-run-game .nr-result-head{border-bottom-color:rgba(255,255,255,.14)}}

/* Illustrated map picker: six endless routes and one separate handcrafted challenge. */
#nova-run-game .nr-scene-native{display:none!important}
#nova-run-game .nr-scene-picker{grid-column:1/-1;min-width:0}
#nova-run-game.settings-open .nr-toolbar{width:min(700px,calc(100% - 20px))}
#nova-run-game .nr-scene-picker-head{display:flex;align-items:end;justify-content:space-between;margin:1px 1px 10px}
#nova-run-game .nr-scene-picker-head>span{display:grid;gap:3px}
#nova-run-game .nr-scene-picker-head b{color:var(--foreground);font-family:Georgia,"Times New Roman","Noto Serif SC",serif;font-size:18px;letter-spacing:.015em}
#nova-run-game .nr-scene-picker-head small{color:var(--muted-foreground);font-size:9px;letter-spacing:.06em}
#nova-run-game .nr-scene-picker-head>i{color:var(--viz-series-2);font-family:ui-monospace,Consolas,monospace;font-size:20px;font-style:normal;font-weight:800;opacity:.75}
#nova-run-game .nr-scene-tabs{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-bottom:9px}
#nova-run-game .nr-scene-tabs button{display:grid;grid-template-columns:28px 1fr;grid-template-rows:auto auto;column-gap:8px;min-width:0;padding:8px 10px;color:var(--foreground);background:rgba(248,242,233,.045);border:1px solid var(--border);border-radius:3px 13px 3px 13px;cursor:pointer;text-align:left}
#nova-run-game .nr-scene-tabs button>span{grid-row:1/3;align-self:center;color:var(--viz-series-1);font-size:22px;text-align:center}
#nova-run-game .nr-scene-tabs button>b{font-size:11px;line-height:1.2}
#nova-run-game .nr-scene-tabs button>small{overflow:hidden;color:var(--muted-foreground);font-size:8px;text-overflow:ellipsis;white-space:nowrap}
#nova-run-game .nr-scene-tabs button[aria-selected="true"]{background:linear-gradient(135deg,rgba(217,119,83,.2),rgba(103,165,164,.13));border-color:var(--viz-series-2);box-shadow:inset 3px 0 var(--viz-series-2)}
#nova-run-game .nr-scene-tabs button:focus-visible,#nova-run-game .nr-scene-card:focus-visible{outline:3px solid var(--viz-series-1);outline-offset:2px}
#nova-run-game .nr-scene-focus{display:grid;grid-template-columns:minmax(180px,42%) 1fr;min-height:132px;margin-bottom:9px;overflow:hidden;background:rgba(248,242,233,.045);border-radius:4px 16px 4px 16px}
#nova-run-game .nr-scene-focus>img{width:100%;height:100%;min-height:132px;object-fit:cover}
#nova-run-game .nr-scene-focus>div{align-content:center;display:grid;gap:5px;padding:13px 15px}
#nova-run-game .nr-scene-focus span{color:var(--viz-series-2);font-size:9px;font-weight:800;letter-spacing:.12em;text-transform:uppercase}
#nova-run-game .nr-scene-focus strong{font-family:Georgia,"Times New Roman","Noto Serif SC",serif;font-size:20px}
#nova-run-game .nr-scene-focus p{margin:0;color:var(--muted-foreground);font-size:11px}
#nova-run-game .nr-scene-focus-tags{display:flex;flex-wrap:wrap;gap:5px}
#nova-run-game .nr-scene-focus-tags b{padding:4px 7px;color:var(--foreground);background:rgba(103,165,164,.14);border-radius:999px;font-size:9px}
#nova-run-game .nr-scene-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
#nova-run-game .nr-scene-card{min-width:0;padding:0;overflow:hidden;color:#f8f2e9;background:#262725;border:1px solid rgba(231,199,171,.25);border-radius:3px 15px 3px 15px;box-shadow:0 7px 18px rgba(0,0,0,.16);cursor:pointer;text-align:left;transition:transform .14s ease,border-color .14s ease,box-shadow .14s ease}
#nova-run-game .nr-scene-card:hover{transform:translateY(-2px);border-color:var(--viz-series-1);box-shadow:0 10px 24px rgba(0,0,0,.23)}
#nova-run-game .nr-scene-card.is-selected{border-color:var(--viz-series-2);box-shadow:0 0 0 2px rgba(217,119,83,.25),0 10px 24px rgba(0,0,0,.23)}
#nova-run-game .nr-scene-image{position:relative;display:block;aspect-ratio:16/9;overflow:hidden;background:#3b3934}
#nova-run-game .nr-scene-image:after{content:"";position:absolute;inset:auto 0 0;height:48%;background:linear-gradient(transparent,rgba(18,18,17,.62));pointer-events:none}
#nova-run-game .nr-scene-image img{display:block;width:100%;height:100%;object-fit:cover;transition:transform .25s ease,filter .18s ease}
#nova-run-game .nr-scene-card:hover .nr-scene-image img{transform:scale(1.025)}
#nova-run-game .nr-scene-image>i{position:absolute;z-index:2;left:7px;top:6px;display:grid;place-items:center;min-width:23px;height:20px;padding:0 5px;color:#fff8ee;background:rgba(30,29,27,.76);border:1px solid rgba(255,255,255,.32);border-radius:999px;font-family:ui-monospace,Consolas,monospace;font-size:8px;font-style:normal;font-weight:800}
#nova-run-game .nr-scene-image>em{position:absolute;z-index:3;inset:0;display:grid;place-items:center;color:#fff7ed;background:rgba(20,20,19,.64);font-size:11px;font-style:normal;font-weight:800;letter-spacing:.06em;backdrop-filter:grayscale(1) blur(1px)}
#nova-run-game .nr-scene-image>em,#nova-run-game .nr-scene-image>mark{pointer-events:none}
#nova-run-game .nr-scene-image>mark{position:absolute;z-index:4;right:7px;top:7px;width:25px;height:25px;display:grid;place-items:center;border:1px solid rgba(255,255,255,.7);border-radius:50%;color:#17322c;background:#a9d8c4;box-shadow:0 3px 10px rgba(0,0,0,.24);font:900 14px/1 system-ui}
#nova-run-game .nr-scene-copy{display:grid;gap:3px;padding:8px 9px 9px}
#nova-run-game .nr-scene-copy strong{overflow:hidden;color:#fff8ef;font-size:11px;font-weight:800;text-overflow:ellipsis;white-space:nowrap}
#nova-run-game .nr-scene-copy small{overflow:hidden;color:#bcb4aa;font-size:8px;line-height:1.3;text-overflow:ellipsis;white-space:nowrap}
#nova-run-game .nr-scene-copy>b{justify-self:start;margin-top:3px;padding:3px 6px;color:#2b2420;background:#e9af89;border-radius:999px;font-size:7px;letter-spacing:.08em;text-transform:uppercase}
#nova-run-game .nr-scene-card:disabled{cursor:not-allowed;opacity:.72}
#nova-run-game .nr-scene-card:disabled:hover{transform:none;border-color:rgba(231,199,171,.25);box-shadow:0 7px 18px rgba(0,0,0,.16)}
#nova-run-game .nr-scene-challenge{grid-column:1/-1;display:grid;grid-template-columns:minmax(190px,42%) 1fr;align-items:stretch}
#nova-run-game .nr-scene-challenge .nr-scene-image{height:100%;min-height:116px;aspect-ratio:auto}
#nova-run-game .nr-scene-challenge .nr-scene-copy{align-content:center;padding:14px}
#nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-family:Georgia,"Times New Roman","Noto Serif SC",serif;font-size:18px}
#nova-run-game .nr-scene-challenge .nr-scene-copy small{margin-top:2px;font-size:10px;white-space:normal}
#nova-run-game[data-game-type="challenge"] .nr-menu-meta{grid-template-columns:1fr}
#nova-run-game[data-game-type="challenge"] .nr-menu-meta>span:first-child,#nova-run-game[data-game-type="challenge"] .nr-difficulty-setting{display:none}
#nova-run-game[data-game-type="challenge"] .nr-menu-start{background:linear-gradient(115deg,#d8c9aa,#6fa4a0 74%)}
#nova-run-game[data-theme="light"] .nr-scene-tabs button{color:#2b2520;background:rgba(255,252,246,.7);border-color:#b79a80}
#nova-run-game[data-theme="light"] .nr-scene-tabs button[aria-selected="true"]{background:linear-gradient(135deg,rgba(190,88,55,.18),rgba(55,124,127,.12))}
#nova-run-game[data-theme="light"] .nr-scene-card{border-color:#b99d84}

@media(max-width:560px){
  #nova-run-game .nr-scene-focus{grid-template-columns:1fr;min-height:0}
  #nova-run-game .nr-scene-focus>img{height:112px;min-height:0}
  #nova-run-game .nr-scene-focus>div{padding:10px}
  #nova-run-game .nr-scene-focus strong{font-size:17px}
  #nova-run-game .nr-scene-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
  #nova-run-game .nr-scene-copy{padding:7px}
  #nova-run-game .nr-scene-copy strong{font-size:10px}
  #nova-run-game .nr-scene-copy small{font-size:7px}
  #nova-run-game .nr-scene-challenge{grid-template-columns:1fr}
  #nova-run-game .nr-scene-challenge .nr-scene-image{min-height:0;aspect-ratio:16/7}
  #nova-run-game .nr-scene-challenge .nr-scene-copy{padding:9px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-size:15px}
}
@media(orientation:landscape) and (max-height:460px){
  #nova-run-game.settings-open .nr-toolbar{width:min(700px,calc(100% - 16px));max-height:calc(100% - 50px)}
  #nova-run-game .nr-scene-picker-head{margin-bottom:6px}
  #nova-run-game .nr-scene-picker-head small{display:none}
  #nova-run-game .nr-scene-tabs{margin-bottom:6px}
  #nova-run-game .nr-scene-tabs button{padding:5px 8px}
}

/* Typography pass: remove micro-text and restore a clear, balanced hierarchy. */
#nova-run-game .nr-settings-heading{font-size:14px}
#nova-run-game .nr-field-title{font-size:12px;letter-spacing:.075em}
#nova-run-game .form-select{font-size:13px;font-weight:650}
#nova-run-game .nr-motion-toggle,#nova-run-game .nr-check{font-size:13px}
#nova-run-game .nr-range{font-size:12px}
#nova-run-game .nr-stat span,#nova-run-game .nr-result-item span{font-size:11px;letter-spacing:.05em}
#nova-run-game .nr-stat strong{font-size:18px}
#nova-run-game .nr-profile-panel h3{font-size:12px}
#nova-run-game .nr-daily-item{font-size:13px}
#nova-run-game .nr-achievement{font-size:12px}
#nova-run-game .nr-result-record{font-size:13px}
#nova-run-game .nr-result-item strong{font-size:15px}
#nova-run-game .nr-result-badges{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:6px;margin-top:3px}
#nova-run-game .nr-result-badges b{padding:6px 9px;color:var(--muted-foreground);background:rgba(0,0,0,.15);border:1px solid var(--border);border-radius:999px;font-size:10px}
#nova-run-game .nr-result-badges b.earned{color:var(--foreground);border-color:var(--viz-series-3);background:rgba(116,213,139,.13)}
#nova-run-game .nr-creator{font-size:9px}
#nova-run-game .nr-creator strong{font-size:11px}
#nova-run-game[data-mode="menu"] .nr-creator{font-size:10px}
#nova-run-game[data-mode="menu"] .nr-creator strong{font-size:13px}
#nova-run-game .nr-menu-kicker,#nova-run-game .nr-menu-route>p:first-child{font-size:11px}
#nova-run-game .nr-menu-meta b{font-size:10px}
#nova-run-game .nr-menu-meta strong,#nova-run-game .nr-menu-features{font-size:13px}
#nova-run-game .nr-menu-start small{font-size:10px}
#nova-run-game .nr-menu-start strong{font-size:23px}
#nova-run-game .nr-menu-actions b{font-size:12px}
#nova-run-game .nr-scene-picker-head small{font-size:11px}
#nova-run-game .nr-scene-tabs button>b{font-size:13px}
#nova-run-game .nr-scene-tabs button>small{font-size:10px}
#nova-run-game .nr-scene-image>i{font-size:10px}
#nova-run-game .nr-scene-image>em{font-size:13px}
#nova-run-game .nr-scene-copy{gap:5px;padding:10px 11px 11px}
#nova-run-game .nr-scene-copy strong{font-size:13px}
#nova-run-game .nr-scene-copy small{font-size:10px;line-height:1.45}
#nova-run-game .nr-scene-copy>b{font-size:9px}
#nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-size:20px}
#nova-run-game .nr-scene-challenge .nr-scene-copy small{font-size:12px}

@media(max-width:560px){
  #nova-run-game .nr-scene-copy{padding:9px}
  #nova-run-game .nr-scene-copy strong{font-size:12px}
  #nova-run-game .nr-scene-copy small{font-size:9px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy{padding:11px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-size:17px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy small{font-size:11px}
  #nova-run-game[data-mode="menu"] .nr-creator{font-size:8px}
  #nova-run-game[data-mode="menu"] .nr-creator strong{font-size:11px}
}
@media(orientation:landscape) and (max-height:460px){
  #nova-run-game[data-mode="menu"] .nr-creator{font-size:8px}
  #nova-run-game[data-mode="menu"] .nr-creator strong{font-size:10px}
  #nova-run-game .nr-menu-kicker{font-size:9px}
  #nova-run-game .nr-menu-meta b{font-size:9px}
  #nova-run-game .nr-menu-meta strong{font-size:11px}
  #nova-run-game .nr-menu-start strong{font-size:19px}
}

/* Final cascade guard for mobile chrome, safe areas and low-height landscape. */
#nova-run-game .nr-settings-heading{
  position:sticky;z-index:18;top:-18px;display:flex!important;margin:-18px -18px 0;
  padding:14px max(18px,env(safe-area-inset-right)) 11px 18px;background:linear-gradient(180deg,rgba(31,32,31,.99) 82%,rgba(31,32,31,0))
}
#nova-run-game .nr-scene-card[data-locked="true"]{cursor:help;opacity:.72}
#nova-run-game .nr-scene-card[data-locked="true"]:hover{transform:none;border-color:rgba(231,199,171,.25);box-shadow:0 7px 18px rgba(0,0,0,.16)}
#nova-run-game .nr-scene-card.is-choosing{transform:scale(.985);filter:brightness(1.13)}
@media(max-width:700px){
  #nova-run-game .nr-toolbar{
    top:max(48px,calc(env(safe-area-inset-top) + 40px));bottom:max(8px,env(safe-area-inset-bottom));
    max-height:none;height:auto;padding:18px;padding-bottom:max(18px,calc(env(safe-area-inset-bottom) + 12px));
    overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch;overscroll-behavior:contain
  }
}
@media(orientation:landscape) and (max-height:520px){
  #nova-run-game[data-mode="menu"] .nr-menu-console{
    top:max(8px,env(safe-area-inset-top));right:max(10px,env(safe-area-inset-right));
    bottom:max(8px,env(safe-area-inset-bottom));transform:none!important;
    max-height:calc(100vh - 16px);max-height:calc(100dvh - 16px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain
  }
  #nova-run-game[data-mode="menu"] .nr-menu-start{position:sticky;z-index:2;bottom:0}
  #nova-run-game.settings-open .nr-toolbar{
    top:max(8px,env(safe-area-inset-top));bottom:max(8px,env(safe-area-inset-bottom));max-height:none;height:auto
  }
  #nova-run-game .nr-scene-picker{display:grid;grid-template-columns:minmax(250px,.9fr) minmax(290px,1.1fr);gap:7px 10px;align-items:start}
  #nova-run-game .nr-scene-picker-head,#nova-run-game .nr-scene-tabs{grid-column:1/-1}
  #nova-run-game .nr-scene-grid{grid-column:1;grid-row:3;grid-template-columns:1fr;gap:5px}
  #nova-run-game .nr-scene-focus{grid-column:2;grid-row:3;position:sticky;top:82px;grid-template-columns:1fr;margin:0}
  #nova-run-game .nr-scene-focus>img{height:142px;min-height:0}
  #nova-run-game .nr-scene-card,#nova-run-game .nr-scene-challenge{display:grid;grid-template-columns:92px 1fr}
  #nova-run-game .nr-scene-card .nr-scene-image,#nova-run-game .nr-scene-challenge .nr-scene-image{height:62px;min-height:62px;aspect-ratio:auto}
  #nova-run-game .nr-scene-card .nr-scene-copy,#nova-run-game .nr-scene-challenge .nr-scene-copy{align-content:center;padding:6px 8px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-size:13px}
}

/* Challenge controls: manual movement is always available; slide has no challenge action. */
#nova-run-game[data-game-type="challenge"][data-mode="play"] .nr-touch{display:flex}
#nova-run-game[data-game-type="challenge"] .nr-touch [data-act="slide"]{display:none!important}

@media(pointer:fine){#nova-run-game .nr-touch{display:none!important}}

/* Warm editorial settings treatment: one continuous surface in day mode. */

#nova-run-game[data-theme="light"] .nr-toolbar{
  color:#3f3933;background:#f7f3ed;border-color:#d2c4b5;border-left-color:#c56a49;
  box-shadow:0 18px 48px rgba(78,62,48,.16),0 1px 0 rgba(255,255,255,.9) inset;backdrop-filter:none
}
#nova-run-game[data-theme="light"] .nr-settings-heading{
  color:#514941;background:linear-gradient(180deg,#f7f3ed 82%,rgba(247,243,237,0));border-bottom-color:#ddd2c6
}
#nova-run-game[data-theme="light"] .nr-settings-heading>span[aria-hidden="true"]{color:#c56a49}
#nova-run-game[data-theme="light"] .nr-panel-tabs{
  background:#ece5dc;border-color:#d7cbc0;box-shadow:0 1px 0 rgba(255,255,255,.72) inset
}
#nova-run-game[data-theme="light"] .nr-panel-tabs button{color:#766d64;background:transparent}
#nova-run-game[data-theme="light"] .nr-panel-tabs button:hover{color:#453f39;background:rgba(255,251,246,.58)}
#nova-run-game[data-theme="light"] .nr-panel-tabs button[aria-selected="true"]{
  color:#352f2a;background:#fffaf4;box-shadow:0 1px 3px rgba(75,58,43,.1),inset 0 -2px #c56a49
}

/* Unified mobile shell, settings pages, custom selects and icon buttons. */
:root{
  --safe-top:env(safe-area-inset-top,0px);--safe-right:env(safe-area-inset-right,0px);--safe-bottom:env(safe-area-inset-bottom,0px);--safe-left:env(safe-area-inset-left,0px)
}
#nova-run-game{
  --nr-panel-bg:rgba(21,23,24,.985);--nr-panel-elevated:rgba(35,36,35,.96);--nr-control-bg:rgba(52,51,47,.86);--nr-control-hover:rgba(69,65,59,.94);
  --nr-line:rgba(194,181,164,.42);--nr-line-cool:rgba(95,151,178,.42);--nr-accent:#d97757;--nr-text:#f5efe5;--nr-text-muted:#aaa49a;--nr-icon-size:44px;--nr-icon-radius:13px;
  height:var(--app-height,100dvh);min-height:0;overflow:hidden
}
html,body{height:100%;min-height:100%;overflow:hidden;overscroll-behavior:none}
#nova-run-game .nr-native-select{display:none!important;pointer-events:none!important}

#nova-run-game .nr-toolbar{
  z-index:30;left:50%!important;right:auto!important;top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 10px)!important;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 10px)!important;
  width:min(700px,calc(100% - var(--safe-left) - var(--safe-right) - 20px))!important;height:auto!important;max-height:none!important;padding:0!important;gap:0!important;
  overflow:hidden!important;transform:translateX(-50%)!important;grid-template-columns:none!important;align-content:start;background:var(--nr-panel-bg);border:1px solid var(--nr-line-cool);border-left:4px solid var(--nr-accent);border-radius:6px 22px 6px 22px
}
#nova-run-game.settings-open .nr-toolbar{display:flex!important;flex-direction:column;flex-wrap:nowrap!important;align-items:stretch!important;opacity:1!important;visibility:visible!important;pointer-events:auto!important}
#nova-run-game .nr-settings-heading{
  position:relative!important;z-index:3!important;top:auto!important;display:flex!important;flex:0 0 auto;align-items:center;min-height:64px;margin:0!important;padding:10px 14px 10px 18px!important;
  color:var(--nr-accent);background:rgba(28,30,30,.98)!important;border-bottom:1px solid var(--nr-line-cool)!important;font-size:14px
}
#nova-run-game .nr-settings-heading>span:nth-child(2){flex:1;min-width:0;overflow-wrap:anywhere}
#nova-run-game .nr-diamond-icon{display:inline-grid;place-items:center;flex:0 0 18px;width:18px;height:18px;line-height:0;text-indent:0}
#nova-run-game .nr-diamond-icon svg{display:block;width:12px;height:12px;overflow:visible}
#nova-run-game .nr-diamond-icon.is-outline svg{fill:none;stroke:currentColor;stroke-width:1.4;stroke-linejoin:round}
#nova-run-game .nr-diamond-icon.is-solid svg{fill:currentColor;stroke:none}
#nova-run-game .nr-panel-head>strong{min-width:0;overflow-wrap:anywhere}
#nova-run-game .nr-panel-tabs{position:relative!important;top:auto!important;z-index:2;flex:0 0 auto;margin:12px 16px 0;padding:4px;background:rgba(14,16,17,.72);border:1px solid var(--nr-line);border-radius:14px}
#nova-run-game .nr-panel-tabs button{min-height:44px;border-radius:10px;color:var(--nr-text-muted);transition:background-color .16s ease,border-color .16s ease,transform .12s ease}
#nova-run-game .nr-panel-tabs button[aria-selected="true"]{color:var(--nr-text);background:rgba(217,119,87,.16);box-shadow:inset 0 0 0 1px var(--nr-accent)}
#nova-run-game .nr-panel-tabs button:active{transform:scale(.98)}
#nova-run-game .nr-settings-scroll{flex:1 1 auto;min-height:0;overflow-x:hidden;overflow-y:auto;padding:16px;padding-bottom:calc(18px + var(--safe-bottom));overscroll-behavior:contain;-webkit-overflow-scrolling:touch;scrollbar-color:var(--nr-accent) rgba(255,255,255,.08)}
#nova-run-game .nr-settings-section{min-width:0;align-content:start}
#nova-run-game .nr-settings-section:not([hidden]){display:grid;gap:12px}
#nova-run-game .nr-settings-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
#nova-run-game .nr-settings-fields>.nr-settings-grid,#nova-run-game .nr-settings-fields>.nr-range,#nova-run-game .nr-settings-fields>.nr-motion-toggle,#nova-run-game .nr-settings-fields>.nr-fullscreen-actions,#nova-run-game .nr-settings-fields>.nr-clear-save{grid-column:1/-1}
#nova-run-game .nr-form-field{display:grid;align-content:start;gap:7px;min-width:0}
#nova-run-game .nr-field-title{display:block;color:var(--nr-text-muted);font-size:12px;font-weight:750;letter-spacing:.04em}

#nova-run-game .nr-icon-button{
  position:relative;display:inline-grid;place-items:center;inline-size:var(--nr-icon-size)!important;block-size:var(--nr-icon-size)!important;min-inline-size:var(--nr-icon-size)!important;min-block-size:var(--nr-icon-size)!important;
  flex:0 0 var(--nr-icon-size);padding:0!important;color:var(--nr-text)!important;background:linear-gradient(145deg,rgba(58,57,53,.94),rgba(33,34,34,.97))!important;border:1px solid var(--nr-line)!important;border-radius:var(--nr-icon-radius)!important;
  box-shadow:inset 0 1px rgba(255,255,255,.08),0 5px 14px rgba(0,0,0,.22)!important;cursor:pointer;touch-action:manipulation;transition:transform .12s ease,background-color .14s ease,border-color .14s ease,filter .14s ease
}
#nova-run-game .nr-icon-button:hover{background:var(--nr-control-hover)!important;border-color:rgba(232,213,192,.7)!important}
#nova-run-game .nr-icon-button:active{transform:translateY(1px) scale(.96)!important;filter:brightness(1.08)}
#nova-run-game .nr-icon-button:focus-visible{outline:3px solid var(--nr-accent)!important;outline-offset:2px}
#nova-run-game .nr-icon-button:disabled{opacity:.42;transform:none!important;cursor:not-allowed}
#nova-run-game .nr-close-button>span:before,#nova-run-game .nr-close-button>span:after{content:"";position:absolute;left:50%;top:50%;width:17px;height:2px;background:currentColor;border-radius:2px}
#nova-run-game .nr-close-button>span:before{transform:translate(-50%,-50%) rotate(45deg)}
#nova-run-game .nr-close-button>span:after{transform:translate(-50%,-50%) rotate(-45deg)}
#nova-run-game .nr-panel-head,#nova-run-game .nr-result-head{min-height:46px;gap:10px}
#nova-run-game .nr-panel-head .nr-close-button,#nova-run-game .nr-result-head .nr-close-button{margin-left:auto}
#nova-run-game .nr-quick-controls{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 10px)!important;right:calc(var(--safe-right) + 12px)!important;gap:8px}
#nova-run-game .nr-quick-controls .btn span{display:grid;place-items:center;width:24px;height:24px;font:800 19px/1 ui-sans-serif,system-ui}
#nova-run-game .nr-quick-controls svg{display:block;width:22px;height:22px;overflow:visible;fill:currentColor;stroke:none}
#nova-run-game .nr-quick-controls svg .nr-icon-stroke{fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
#nova-run-game .nr-quick-controls [data-quick="pause"] span{letter-spacing:1px;transform:translateX(1px)}
#nova-run-game .nr-orientation{border-radius:13px!important;background:linear-gradient(145deg,rgba(58,57,53,.94),rgba(33,34,34,.97))!important;border:1px solid var(--nr-line)!important;box-shadow:inset 0 1px rgba(255,255,255,.08),0 5px 14px rgba(0,0,0,.2)!important}
#nova-run-game .nr-orientation svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
#nova-run-game[data-mode="play"] .nr-orientation{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 10px)!important;left:calc(var(--safe-left) + 12px)!important}
#nova-run-game .nr-brand{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 9px)!important}
#nova-run-game .nr-menu-start>i{border-radius:12px!important;transform:translateX(1px)}

#nova-run-game .nr-select-trigger{display:grid;grid-template-columns:minmax(0,1fr) 18px;align-items:center;gap:10px;width:100%;min-height:46px;padding:9px 12px;color:var(--nr-text);background:var(--nr-control-bg);border:1px solid var(--nr-line);border-radius:12px;box-shadow:inset 0 1px rgba(255,255,255,.06);font:700 13px/1.25 inherit;text-align:left;cursor:pointer;touch-action:manipulation;transition:background-color .14s ease,border-color .14s ease,transform .12s ease}
#nova-run-game .nr-select-trigger:hover{background:var(--nr-control-hover);border-color:rgba(217,119,87,.65)}
#nova-run-game .nr-select-trigger:active{transform:scale(.985)}
#nova-run-game .nr-select-trigger:focus-visible{outline:3px solid rgba(217,119,87,.65);outline-offset:2px}
#nova-run-game .nr-select-value{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#nova-run-game .nr-select-arrow{position:relative;width:14px;height:14px;justify-self:end}
#nova-run-game .nr-select-arrow:before,#nova-run-game .nr-select-arrow:after{content:"";position:absolute;top:6px;width:8px;height:2px;background:var(--nr-text-muted);border-radius:2px}
#nova-run-game .nr-select-arrow:before{left:0;transform:rotate(42deg)}#nova-run-game .nr-select-arrow:after{right:0;transform:rotate(-42deg)}
#nova-run-game .nr-select-overlay{position:absolute;z-index:60;inset:0;display:grid;place-items:center;padding:calc(var(--safe-top) + 12px) calc(var(--safe-right) + 12px) calc(var(--safe-bottom) + 12px) calc(var(--safe-left) + 12px);opacity:0;pointer-events:none;transition:opacity .18s ease}
#nova-run-game .nr-select-overlay.is-open{opacity:1;pointer-events:auto}
#nova-run-game .nr-select-backdrop{position:absolute;inset:0;width:100%;height:100%;padding:0;background:rgba(8,10,11,.66);border:0;border-radius:0;backdrop-filter:blur(3px)}
#nova-run-game .nr-select-dialog{position:relative;display:flex;flex-direction:column;width:min(430px,100%);max-height:min(620px,calc(var(--app-height,100dvh) - var(--safe-top) - var(--safe-bottom) - 28px));overflow:hidden;color:var(--nr-text);background:var(--nr-panel-bg);border:1px solid var(--nr-line-cool);border-left:4px solid var(--nr-accent);border-radius:6px 20px 6px 20px;box-shadow:0 22px 58px rgba(0,0,0,.48);transform:translateY(12px) scale(.985);transition:transform .18s ease}
#nova-run-game .nr-select-overlay.is-open .nr-select-dialog{transform:none}
#nova-run-game .nr-select-dialog>header{display:flex;align-items:center;gap:12px;min-height:66px;padding:10px 12px 10px 18px;border-bottom:1px solid var(--nr-line-cool)}
#nova-run-game .nr-select-dialog>header strong{flex:1;min-width:0;font-size:16px;overflow-wrap:anywhere}
#nova-run-game .nr-select-list{display:grid;gap:8px;min-height:0;padding:12px;overflow-y:auto;overscroll-behavior:contain;scrollbar-color:var(--nr-accent) rgba(255,255,255,.08)}
#nova-run-game .nr-select-option{position:relative;display:grid;grid-template-columns:minmax(0,1fr) 24px;align-items:center;gap:12px;width:100%;min-height:52px;padding:10px 13px 10px 17px;color:var(--nr-text);background:rgba(53,52,48,.58);border:1px solid rgba(194,181,164,.3);border-radius:12px;font:700 14px/1.35 inherit;text-align:left;cursor:pointer;transition:transform .1s ease,background-color .13s ease,border-color .13s ease}
#nova-run-game .nr-select-option:before{content:"";position:absolute;left:0;top:8px;bottom:8px;width:3px;background:transparent;border-radius:0 3px 3px 0}
#nova-run-game .nr-select-option[aria-selected="true"]{background:rgba(217,119,87,.15);border-color:rgba(217,119,87,.72)}
#nova-run-game .nr-select-option[aria-selected="true"]:before{background:var(--nr-accent)}
#nova-run-game .nr-select-option i{display:grid;place-items:center;justify-self:center;width:24px;height:24px;border:0;transform:none}
#nova-run-game .nr-select-option i:before{content:"";display:block;width:10px;height:10px;box-sizing:border-box;border:1px solid var(--nr-line);transform:rotate(45deg)}
#nova-run-game .nr-select-option[aria-selected="true"] i:before{background:var(--nr-accent);border-color:#f6c1aa;box-shadow:0 0 0 3px rgba(94,151,178,.16)}
#nova-run-game .nr-select-option:hover{background:rgba(75,70,64,.72);border-color:var(--nr-line-cool)}
#nova-run-game .nr-select-option:active{transform:scale(.987)}
#nova-run-game .nr-select-option:focus-visible{outline:3px solid rgba(217,119,87,.6);outline-offset:1px}
#nova-run-game .nr-select-option:disabled{opacity:.45;cursor:not-allowed;transform:none}

#nova-run-game .nr-character-page{gap:14px}
#nova-run-game .nr-character-focus{display:grid;grid-template-columns:minmax(220px,1.15fr) minmax(180px,.85fr);min-height:260px;overflow:hidden;background:rgba(255,255,255,.035);border:1px solid var(--nr-line-cool);border-radius:6px 18px 6px 18px}
#nova-run-game .nr-character-stage{min-width:0;background:linear-gradient(145deg,rgba(95,151,178,.08),rgba(217,119,87,.07))}
#nova-run-game .nr-character-stage canvas{display:block;width:100%;height:100%;min-height:240px}
#nova-run-game .nr-character-copy{display:flex;flex-direction:column;justify-content:center;gap:8px;padding:18px}
#nova-run-game .nr-character-copy>span{color:var(--nr-accent);font-size:10px;font-weight:800;letter-spacing:.13em;text-transform:uppercase}
#nova-run-game .nr-character-copy strong{font-size:24px;line-height:1.1}
#nova-run-game .nr-character-copy p{margin:0;color:var(--nr-text-muted);font-size:13px;line-height:1.6}
#nova-run-game .nr-character-copy small{color:var(--nr-text-muted);font-family:inherit;font-size:9px;font-weight:600;line-height:1.3;letter-spacing:.1em;text-align:left;text-shadow:none}
#nova-run-game .nr-skin-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px}
#nova-run-game .nr-skin-card{position:relative;display:grid;grid-template-rows:auto auto 1fr;min-width:0;padding:0 0 10px;overflow:hidden;color:var(--nr-text);background:rgba(45,46,44,.82);border:1px solid var(--nr-line);border-radius:5px 15px 5px 15px;text-align:left;cursor:pointer;transition:transform .13s ease,border-color .13s ease,box-shadow .13s ease}
#nova-run-game .nr-skin-card canvas{display:block;width:100%;background:#202526}
#nova-run-game .nr-skin-card span{padding:9px 9px 3px;font-size:12px;font-weight:800}
#nova-run-game .nr-skin-card small{padding:0 9px;color:var(--nr-text-muted);font-size:8px;line-height:1.35}
#nova-run-game .nr-skin-card i{position:absolute;right:7px;top:7px;display:grid;place-items:center;width:22px;height:22px;color:#fff;background:rgba(21,23,24,.76);border:1px solid rgba(255,255,255,.38);border-radius:8px;font-style:normal}
#nova-run-game .nr-skin-card i:before{content:"";display:block;width:8px;height:8px;box-sizing:border-box;border:1.4px solid currentColor;transform:rotate(45deg);transform-origin:50% 50%}
#nova-run-game .nr-skin-card i[data-state="selected"]:before{background:currentColor}
#nova-run-game .nr-skin-card i[data-state=""]:before{visibility:hidden}
#nova-run-game .nr-skin-card.is-selected{transform:translateY(-2px);border-color:var(--nr-accent);box-shadow:0 0 0 2px rgba(217,119,87,.16),0 10px 22px rgba(0,0,0,.2)}
#nova-run-game .nr-skin-card[data-locked="true"]{opacity:.57}
#nova-run-game .nr-skin-card:focus-visible{outline:3px solid var(--nr-accent);outline-offset:2px}

#nova-run-game.modal-open .nr-touch,#nova-run-game.modal-open .nr-orientation,#nova-run-game.modal-open canvas{pointer-events:none}
#nova-run-game .nr-profile-panel,#nova-run-game .nr-results,#nova-run-game .nr-share-panel,#nova-run-game .nr-confirm{z-index:36;max-height:calc(var(--app-height,100dvh) - var(--safe-top) - var(--safe-bottom) - 24px);overflow:auto;padding-bottom:calc(14px + var(--safe-bottom));overscroll-behavior:contain}
#nova-run-game .nr-tutorial-head{display:flex;align-items:center;justify-content:space-between;gap:8px}
#nova-run-game .nr-tutorial .nr-close-button{pointer-events:auto;--nr-icon-size:38px}
#nova-run-game .nr-install-prompt,#nova-run-game .nr-update-prompt{position:absolute;z-index:50;left:50%;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 14px);width:min(520px,calc(100% - var(--safe-left) - var(--safe-right) - 24px));padding:14px 16px;color:var(--nr-text);background:var(--nr-panel-bg);border:1px solid var(--nr-line-cool);border-left:4px solid var(--nr-accent);border-radius:6px 18px 6px 18px;transform:translateX(-50%);box-shadow:0 16px 40px rgba(0,0,0,.42)}
#nova-run-game .nr-install-prompt p{margin:7px 0 12px;color:var(--nr-text-muted);font-size:12px;line-height:1.5}
#nova-run-game .nr-install-prompt>div,#nova-run-game .nr-update-prompt{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#nova-run-game .nr-update-prompt span{flex:1;min-width:140px;font-weight:750}
#nova-run-game .nr-fullscreen-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}
#nova-run-game .nr-app-install:not([hidden]){grid-column:1/-1;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;padding:13px 14px;color:var(--nr-text);background:var(--nr-panel-elevated);border:1px solid var(--nr-line-cool);border-left:3px solid var(--nr-accent);border-radius:5px 15px 5px 15px}
#nova-run-game .nr-app-install>div{display:grid;gap:4px;min-width:0}
#nova-run-game .nr-app-install strong{font-size:14px;line-height:1.25}
#nova-run-game .nr-app-install small{color:var(--nr-text-muted);font-size:11px;line-height:1.4}
#nova-run-game .nr-app-install .btn{min-width:138px}
#nova-run-game .nr-app-install .btn[hidden]{display:none}
#nova-run-game .nr-scene-image>em{display:flex;align-items:center;justify-content:center;gap:8px}
#nova-run-game .nr-scene-image>em:before{content:"";display:block;flex:0 0 9px;width:9px;height:9px;box-sizing:border-box;border:1.4px solid currentColor;transform:rotate(45deg);transform-origin:50% 50%}
#nova-run-game.is-standalone [data-fullscreen-enter],#nova-run-game.is-standalone [data-fullscreen-exit]{display:none}
#nova-run-game .nr-touch{left:calc(var(--safe-left) + 12px)!important;right:calc(var(--safe-right) + 12px)!important;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 12px)!important}
#nova-run-game .nr-touch .btn{border-radius:15px!important;box-shadow:inset 0 1px rgba(255,255,255,.18),0 5px 14px rgba(0,0,0,.24)!important}
#nova-run-game .nr-touch [data-act="dash"]{border-radius:16px!important}

#nova-run-game[data-theme="light"]{--nr-panel-bg:rgba(247,243,237,.99);--nr-panel-elevated:#f0e9e0;--nr-control-bg:#ece5dc;--nr-control-hover:#e2d7ca;--nr-line:rgba(125,105,86,.4);--nr-line-cool:rgba(78,130,156,.36);--nr-text:#37312c;--nr-text-muted:#746c64}
#nova-run-game[data-theme="light"] .nr-settings-heading{color:#a9543e;background:#f7f3ed!important;border-bottom-color:#d8ccc0!important}
#nova-run-game[data-theme="light"] .nr-panel-tabs{background:#e9e1d7}
#nova-run-game[data-theme="light"] .nr-icon-button,#nova-run-game[data-theme="light"] .nr-orientation{color:#463f38!important;background:linear-gradient(145deg,#f4eee6,#dfd4c8)!important;border-color:#b9aa9b!important;box-shadow:inset 0 1px #fff,0 4px 12px rgba(78,58,42,.12)!important}
#nova-run-game[data-theme="light"] .nr-select-backdrop{background:rgba(72,61,51,.34)}
#nova-run-game[data-theme="light"] .nr-select-option{background:#eee7de;color:var(--nr-text)}
#nova-run-game[data-theme="light"] .nr-select-option:hover{background:#e3d8cc}
#nova-run-game[data-theme="light"] .nr-character-focus,#nova-run-game[data-theme="light"] .nr-skin-card{background:#eee7de}

@media(max-width:700px){
  #nova-run-game .nr-toolbar{width:calc(100% - var(--safe-left) - var(--safe-right) - 16px)!important;top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 8px)!important;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 8px)!important}
  #nova-run-game .nr-settings-heading{min-height:58px;padding-left:14px!important}
  #nova-run-game .nr-panel-tabs{margin:10px 12px 0}
  #nova-run-game .nr-settings-scroll{padding:12px;padding-bottom:calc(16px + var(--safe-bottom))}
  #nova-run-game .nr-settings-fields{grid-template-columns:1fr}
  #nova-run-game .nr-settings-fields>*{grid-column:1!important}
  #nova-run-game .nr-character-focus{grid-template-columns:1fr;min-height:0}
  #nova-run-game .nr-character-stage canvas{min-height:190px;max-height:230px}
  #nova-run-game .nr-character-copy{padding:14px}
  #nova-run-game .nr-skin-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  #nova-run-game .nr-select-dialog{align-self:end;width:100%;max-height:min(72dvh,calc(var(--app-height,100dvh) - var(--safe-top) - 18px));border-radius:16px 16px 5px 5px;transform:translateY(18px)}
  #nova-run-game .nr-select-option{min-height:54px}
}
@media(pointer:coarse){
  #nova-run-game{--nr-icon-size:48px}
  #nova-run-game .nr-orientation{min-height:48px!important;padding:8px 12px!important}
}
@media(max-width:480px){#nova-run-game .nr-quick-controls [data-quick="sound"]{display:none}}
@media(orientation:landscape) and (max-height:520px){
  #nova-run-game .nr-toolbar{left:50%!important;top:calc(var(--safe-top) + 6px)!important;bottom:calc(var(--safe-bottom) + 6px)!important;width:min(760px,calc(100% - var(--safe-left) - var(--safe-right) - 16px))!important}
  #nova-run-game .nr-settings-heading{min-height:48px}.nr-panel-tabs{margin-top:6px!important}
  #nova-run-game .nr-character-focus{grid-template-columns:minmax(210px,1fr) minmax(180px,.8fr)}
  #nova-run-game .nr-character-stage canvas{min-height:180px;max-height:210px}
  #nova-run-game .nr-skin-grid{grid-template-columns:repeat(5,minmax(120px,1fr));overflow-x:auto;padding-bottom:4px}
  #nova-run-game .nr-select-dialog{align-self:center;width:min(520px,86vw);max-height:calc(var(--app-height,100dvh) - var(--safe-top) - var(--safe-bottom) - 16px);border-radius:6px 20px 6px 20px}
}
@media(hover:none){#nova-run-game .nr-icon-button:hover,#nova-run-game .nr-select-trigger:hover,#nova-run-game .nr-select-option:hover{filter:none}}
@media(prefers-reduced-motion:reduce){#nova-run-game .nr-icon-button,#nova-run-game .nr-select-trigger,#nova-run-game .nr-select-option,#nova-run-game .nr-select-overlay,#nova-run-game .nr-select-dialog,#nova-run-game .nr-skin-card{transition:none!important;transform:none!important}}
#nova-run-game[data-motion="reduced"] .nr-icon-button,#nova-run-game[data-motion="reduced"] .nr-select-trigger,#nova-run-game[data-motion="reduced"] .nr-select-option,#nova-run-game[data-motion="reduced"] .nr-select-overlay,#nova-run-game[data-motion="reduced"] .nr-select-dialog,#nova-run-game[data-motion="reduced"] .nr-skin-card{transition:none!important;transform:none!important}

/* Desktop settings are a compact centered console. Mobile keeps the full-height sheet above. */
@media(min-width:901px) and (min-height:600px){
  #nova-run-game .nr-toolbar{
    top:50%!important;bottom:auto!important;width:min(920px,calc(100% - 64px))!important;height:min(650px,calc(100% - 56px))!important;
    transform:translate(-50%,-50%)!important;border-radius:8px 24px 8px 24px;box-shadow:0 28px 78px rgba(0,0,0,.46)
  }
  #nova-run-game .nr-settings-heading{min-height:60px;padding:9px 16px 9px 20px!important}
  #nova-run-game .nr-panel-tabs{align-self:center;width:min(430px,calc(100% - 32px));margin:10px 16px 0}
  #nova-run-game .nr-panel-tabs button{min-height:40px}
  #nova-run-game .nr-settings-scroll{padding:14px 18px 18px}
  #nova-run-game[data-settings-page="settings"] .nr-settings-scroll{
    display:grid;grid-template-columns:minmax(250px,.72fr) minmax(430px,1.28fr);grid-template-rows:auto 1fr;align-content:start;gap:14px 18px
  }
  #nova-run-game[data-settings-page="settings"] .nr-settings-general{grid-column:1;grid-row:1}
  #nova-run-game[data-settings-page="settings"] .nr-settings-performance{grid-column:1;grid-row:2;align-self:start}
  #nova-run-game[data-settings-page="settings"] .nr-settings-controls{grid-column:2;grid-row:1/3;align-self:start}
  #nova-run-game .nr-settings-controls>.nr-range{grid-column:auto}
  #nova-run-game .nr-settings-controls>.nr-fullscreen-actions,#nova-run-game .nr-settings-controls>.nr-clear-save{grid-column:1/-1}
  #nova-run-game[data-settings-page="settings"] .nr-toolbar{height:min(520px,calc(100% - 56px))!important}
  #nova-run-game .nr-character-focus{min-height:250px}
  #nova-run-game .nr-character-stage canvas{min-height:230px}
  #nova-run-game .nr-skin-card canvas{max-height:112px}
}

/* Settings typography: readable on phones, deliberate on desktop, safe for long translations. */
#nova-run-game .nr-panel-tabs button{min-height:48px;font-size:15px;font-weight:800;letter-spacing:.025em}
#nova-run-game .nr-scene-picker-head b{font-size:21px;line-height:1.15}
#nova-run-game .nr-scene-picker-head small{font-size:12px;line-height:1.45}
#nova-run-game .nr-scene-tabs button>b{font-size:15px;line-height:1.25}
#nova-run-game .nr-scene-tabs button>small{font-size:11px;line-height:1.35}
#nova-run-game .nr-scene-focus strong{font-size:20px;line-height:1.18}
#nova-run-game .nr-scene-focus p{font-size:12px;line-height:1.5}
#nova-run-game .nr-scene-focus-tags b{font-size:11px;line-height:1.25}
#nova-run-game .nr-scene-image>i{font-size:11px}
#nova-run-game .nr-scene-copy{align-content:start;min-height:82px;gap:5px;padding:10px 11px 12px}
#nova-run-game .nr-scene-copy strong,#nova-run-game .nr-scene-copy small{display:-webkit-box;overflow:hidden;white-space:normal;text-overflow:ellipsis;-webkit-box-orient:vertical}
#nova-run-game .nr-scene-copy strong{min-height:2.5em;font-size:14px;line-height:1.25;-webkit-line-clamp:2}
#nova-run-game .nr-scene-copy small{font-size:11px;line-height:1.4;-webkit-line-clamp:2}
#nova-run-game .nr-scene-copy>b{font-size:10px;line-height:1.25}
#nova-run-game .nr-scene-challenge .nr-scene-copy{min-height:0}
#nova-run-game .nr-scene-challenge .nr-scene-copy strong{min-height:0;font-size:19px;line-height:1.2}
#nova-run-game .nr-scene-challenge .nr-scene-copy small{font-size:12px}

#nova-run-game .nr-character-copy>span{font-size:12px;line-height:1.3}
#nova-run-game .nr-character-copy strong{font-size:24px;line-height:1.12}
#nova-run-game .nr-character-copy p{font-size:14px;line-height:1.6}
#nova-run-game .nr-character-copy small{font-size:11px;line-height:1.4}
#nova-run-game .nr-skin-card{grid-template-rows:auto auto 1fr}
#nova-run-game .nr-skin-card span{padding:10px 10px 4px;font-size:14px;line-height:1.25;white-space:normal;overflow-wrap:anywhere}
#nova-run-game .nr-skin-card small{display:-webkit-box;min-height:4.35em;padding:0 10px;color:var(--nr-text-muted);font-size:11px;line-height:1.45;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow-wrap:anywhere}

#nova-run-game .nr-field-title{font-size:14px;line-height:1.35}
#nova-run-game .nr-select-trigger{font-size:15px;line-height:1.3}
#nova-run-game .nr-motion-toggle,#nova-run-game .nr-check{font-size:15px;line-height:1.35}
#nova-run-game .nr-range{font-size:14px;line-height:1.35}
#nova-run-game .nr-toolbar .btn{font-size:15px;font-weight:750}

@media(orientation:landscape) and (max-height:520px){
  #nova-run-game .nr-panel-tabs button{min-height:44px;font-size:14px}
  #nova-run-game .nr-scene-picker-head b{font-size:19px}
  #nova-run-game .nr-scene-picker-head small{font-size:11px}
  #nova-run-game .nr-scene-copy{min-height:68px;padding:7px 9px}
  #nova-run-game .nr-scene-copy strong{font-size:13px}
  #nova-run-game .nr-scene-copy small{font-size:11px}
  #nova-run-game .nr-skin-card span{font-size:13px}
  #nova-run-game .nr-skin-card small{min-height:2.9em;font-size:10px;-webkit-line-clamp:2}
  #nova-run-game .nr-field-title,#nova-run-game .nr-range{font-size:13px}
  #nova-run-game .nr-select-trigger,#nova-run-game .nr-motion-toggle,#nova-run-game .nr-check,#nova-run-game .nr-toolbar .btn{font-size:14px}
}

@media(min-width:901px) and (min-height:600px){
  #nova-run-game .nr-panel-tabs{width:min(500px,calc(100% - 32px))}
  #nova-run-game .nr-panel-tabs button{min-height:46px;font-size:16px}
  #nova-run-game .nr-scene-picker-head b{font-size:22px}
  #nova-run-game .nr-scene-picker-head small{font-size:13px}
  #nova-run-game .nr-scene-tabs button>small{font-size:12px}
  #nova-run-game .nr-scene-focus strong{font-size:24px}
  #nova-run-game .nr-scene-focus p{font-size:13px}
  #nova-run-game .nr-scene-copy{min-height:88px}
  #nova-run-game .nr-scene-copy strong{font-size:15px}
  #nova-run-game .nr-scene-copy small{font-size:12px}
  #nova-run-game .nr-scene-copy>b{font-size:11px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy strong{font-size:22px}
  #nova-run-game .nr-scene-challenge .nr-scene-copy small{font-size:13px}
  #nova-run-game .nr-character-copy strong{font-size:28px}
  #nova-run-game .nr-character-copy p{font-size:15px}
  #nova-run-game .nr-skin-card span{font-size:15px}
  #nova-run-game .nr-skin-card small{font-size:12px}
}

/* Modal pause ownership and ergonomic two-thumb touch controls. */
#nova-run-game .nr-settings-backdrop{position:absolute;z-index:29;inset:0;display:none;padding:0;background:rgba(8,10,11,.38);border:0;border-radius:0;cursor:default;touch-action:manipulation}
#nova-run-game .nr-pause-status{position:absolute;z-index:7;left:50%;top:18px;display:none;align-items:center;gap:8px;padding:7px 11px;color:var(--nr-text);background:rgba(25,27,28,.9);border:1px solid var(--nr-line-cool);border-left:3px solid var(--nr-accent);border-radius:4px 11px 4px 11px;box-shadow:0 7px 18px rgba(0,0,0,.22);transform:translateX(-50%);pointer-events:none}
#nova-run-game .nr-pause-status strong{font-size:12px;letter-spacing:.08em}
#nova-run-game .nr-pause-status small{color:var(--nr-text-muted);font-size:10px}
#nova-run-game[data-mode="pause"]:not(.modal-open) .nr-pause-status{display:flex}
#nova-run-game[data-theme="light"] .nr-pause-status{color:#403a34;background:rgba(247,243,237,.95);border-color:rgba(78,130,156,.36);border-left-color:#bd6248}

#nova-run-game .nr-touch{display:none;grid-template-columns:auto minmax(0,1fr) auto;align-items:end;gap:12px;pointer-events:none}
#nova-run-game .nr-move{grid-column:1;grid-row:1;align-self:end}
#nova-run-game .nr-touch-jump{grid-column:1;grid-row:1;align-self:end;justify-self:start;width:clamp(68px,18vw,72px)!important;height:clamp(56px,7vh,58px)!important;min-width:68px!important;min-height:56px!important;padding:6px 9px!important;font-size:clamp(12px,3.4vw,14px)!important}
#nova-run-game .nr-action-right{position:relative;grid-column:3;grid-row:1;width:clamp(128px,34vw,136px);height:clamp(76px,10vh,84px);pointer-events:none}
#nova-run-game .nr-action-right .btn{position:absolute;pointer-events:auto}
#nova-run-game .nr-action-right [data-act="dash"]{left:0;top:0;width:clamp(58px,15.5vw,62px)!important;height:clamp(58px,15.5vw,62px)!important;min-width:58px!important;min-height:58px!important}
#nova-run-game .nr-action-right [data-act="slide"]{right:0;bottom:0;width:clamp(58px,15.5vw,62px)!important;height:clamp(50px,6.5vh,54px)!important;min-width:58px!important;min-height:50px!important;padding:5px 7px!important;font-size:clamp(11px,3vw,13px)!important}
#nova-run-game[data-game-type="runner"] .nr-move{display:none!important}
#nova-run-game[data-game-type="challenge"] .nr-touch{grid-template-columns:auto minmax(0,1fr) auto auto}
#nova-run-game[data-game-type="challenge"] .nr-touch-jump{grid-column:3;justify-self:end;width:clamp(62px,16vw,68px)!important}
#nova-run-game[data-game-type="challenge"] .nr-action-right{grid-column:4;width:clamp(58px,15.5vw,62px);height:clamp(58px,15.5vw,62px)}
#nova-run-game[data-game-type="challenge"] .nr-action-right [data-act="dash"]{left:0;top:0}
#nova-run-game[data-game-type="challenge"] .nr-action-right [data-act="slide"]{display:none!important}

@media(pointer:coarse){
  #nova-run-game.settings-open .nr-settings-backdrop{display:block}
  #nova-run-game[data-mode="play"] .nr-touch{display:grid!important}
  #nova-run-game .nr-toolbar{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + clamp(58px,9dvh,76px))!important}
  #nova-run-game .nr-pause-status{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 68px)}
}
@media(max-width:700px){#nova-run-game.settings-open .nr-settings-backdrop{display:block}#nova-run-game[data-mode="play"] .nr-touch{display:grid!important}}
@media(pointer:coarse) and (orientation:landscape) and (max-height:520px){
  #nova-run-game .nr-toolbar{top:calc(var(--safe-top) + 44px)!important}
  #nova-run-game .nr-touch-jump{width:clamp(62px,7.4vw,66px)!important;height:clamp(50px,13vh,54px)!important;min-width:62px!important;min-height:50px!important;font-size:clamp(11px,1.5vw,13px)!important}
  #nova-run-game .nr-action-right{width:clamp(122px,15vw,128px);height:clamp(68px,18vh,74px)}
  #nova-run-game .nr-action-right [data-act="dash"]{width:clamp(56px,7vw,60px)!important;height:clamp(56px,7vw,60px)!important;min-width:56px!important;min-height:56px!important}
  #nova-run-game .nr-action-right [data-act="slide"]{width:clamp(56px,7vw,60px)!important;height:clamp(48px,13vh,52px)!important;min-width:56px!important;min-height:48px!important;font-size:clamp(10px,1.4vw,12px)!important}
  #nova-run-game[data-game-type="challenge"] .nr-touch-jump{width:clamp(60px,7vw,64px)!important}
  #nova-run-game[data-game-type="challenge"] .nr-action-right{width:clamp(56px,7vw,60px);height:clamp(56px,7vw,60px)}
  #nova-run-game .nr-pause-status{top:auto;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 12px);padding:5px 9px}
}
@media(prefers-reduced-motion:reduce){#nova-run-game .nr-pause-status{transition:none}}

/* Mobile-only regression fixes. Desktop geometry intentionally remains untouched. */
#nova-run-game .nr-move .btn>span{display:grid;place-items:center;width:100%;height:100%;pointer-events:none}
#nova-run-game .nr-move .btn svg{display:block;width:24px;height:24px;overflow:visible;fill:none;stroke:currentColor;stroke-width:2.4;stroke-linecap:round;stroke-linejoin:round}

@media(pointer:coarse),(hover:none){
  #nova-run-game .nr-touch button,#nova-run-game .nr-orientation,#nova-run-game .nr-quick-controls button{
    -webkit-user-select:none;user-select:none;-webkit-touch-callout:none;touch-action:manipulation
  }
  #nova-run-game .nr-touch [data-act="left"],#nova-run-game .nr-touch [data-act="right"],#nova-run-game .nr-touch [data-act="jump"],#nova-run-game .nr-touch [data-act="slide"]{touch-action:none}
  #nova-run-game .nr-scene-card:hover{transform:none}
  #nova-run-game .nr-scene-card.is-choosing{filter:none}
}

@media(max-width:700px){
  #nova-run-game[data-settings-page="map"] .nr-settings-scroll{padding-bottom:calc(30px + var(--safe-bottom))}
  #nova-run-game[data-settings-page="map"] [data-settings-section="map"]{padding-bottom:calc(18px + var(--safe-bottom))}
  #nova-run-game .nr-scene-focus>img,#nova-run-game .nr-scene-image img{object-fit:cover;object-position:center center;background:var(--nr-panel-elevated)}
  #nova-run-game .nr-scene-image:after{height:30%}
  #nova-run-game .nr-scene-grid{padding-bottom:calc(12px + var(--safe-bottom))}
  #nova-run-game .nr-app-install:not([hidden]){grid-template-columns:1fr}
  #nova-run-game .nr-app-install .btn{width:100%;min-width:0}
}

@media(pointer:coarse) and (orientation:portrait), (max-width:700px) and (orientation:portrait){
  #nova-run-game[data-mode="play"] .nr-brand,#nova-run-game[data-mode="pause"] .nr-brand{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 6px)!important;left:50%!important;transform:translateX(-50%)!important}
  #nova-run-game[data-mode="play"] .nr-orientation,#nova-run-game[data-mode="pause"] .nr-orientation{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 54px)!important;left:calc(var(--safe-left) + 10px)!important}
  #nova-run-game[data-mode="play"] .nr-quick-controls,#nova-run-game[data-mode="pause"] .nr-quick-controls{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 54px)!important;right:calc(var(--safe-right) + 10px)!important}
}

@media(pointer:coarse) and (orientation:landscape) and (max-height:600px){
  #nova-run-game[data-mode="play"] .nr-brand,#nova-run-game[data-mode="pause"] .nr-brand{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 6px)!important;left:50%!important;transform:translateX(-50%)!important}
  #nova-run-game[data-mode="play"] .nr-orientation,#nova-run-game[data-mode="pause"] .nr-orientation{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 6px)!important;left:calc(var(--safe-left) + 8px)!important}
  #nova-run-game[data-mode="play"] .nr-quick-controls,#nova-run-game[data-mode="pause"] .nr-quick-controls{top:calc(var(--safe-top) + var(--visual-top-offset,0px) + 6px)!important;right:calc(var(--safe-right) + 8px)!important}
  #nova-run-game[data-settings-page="settings"] .nr-motion-toggle{position:static;top:auto;right:auto;width:auto;padding:0;background:transparent;border-radius:0}
  #nova-run-game[data-settings-page="map"] .nr-settings-scroll{overflow:hidden;padding-bottom:10px}
  #nova-run-game[data-settings-page="map"] [data-settings-section="map"]{grid-template-rows:minmax(0,1fr) auto;height:100%;min-height:0;overflow:hidden;padding-bottom:0}
  #nova-run-game[data-settings-page="map"] .nr-scene-picker{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto minmax(0,1fr);gap:6px 10px;height:100%;min-height:0;overflow:hidden}
  #nova-run-game[data-settings-page="map"] .nr-scene-picker-head,#nova-run-game[data-settings-page="map"] .nr-scene-tabs{grid-column:1/-1}
  #nova-run-game[data-settings-page="map"] .nr-scene-grid{grid-column:1;grid-row:4;align-content:start;height:100%;min-height:0;overflow-x:hidden;overflow-y:auto;padding:0 4px calc(16px + var(--safe-bottom)) 0;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
  #nova-run-game[data-settings-page="map"] .nr-scene-card{min-height:118px;flex-shrink:0}
  #nova-run-game[data-settings-page="map"] .nr-scene-card .nr-scene-image,#nova-run-game[data-settings-page="map"] .nr-scene-challenge .nr-scene-image{height:100px;min-height:100px;aspect-ratio:16/9}
  #nova-run-game[data-settings-page="map"] .nr-scene-image img{object-fit:cover;object-position:center center;background:var(--nr-panel-elevated)}
  #nova-run-game[data-settings-page="map"] .nr-scene-focus{grid-column:1;grid-row:3;position:relative;top:auto;align-self:stretch;grid-template-columns:1fr;grid-template-rows:minmax(96px,1fr) auto;height:100%;min-height:0;margin:0;overflow:hidden}
  #nova-run-game[data-settings-page="map"] .nr-scene-focus>img{width:100%;height:100%;min-height:0;object-fit:cover;object-position:center center;background:var(--nr-panel-elevated)}
  #nova-run-game[data-settings-page="map"] .nr-scene-focus>div{align-content:center;min-height:68px;padding:8px 10px}
  #nova-run-game[data-settings-page="map"] .nr-scene-focus strong{min-height:1.2em}
  #nova-run-game[data-settings-page="map"] .nr-difficulty-setting{margin:0}
}
/* =========================================================
   NOVA RUN — FINAL MOBILE REGRESSION FIX
   Scope:
   - mobile portrait
   - low-height mobile landscape
   Does not change desktop, PWA, game logic, saves or map data.
   ========================================================= */

/* Remove the old mobile fade mask that can create a dark/light
   block above the settings panel. */
#nova-run-game.settings-open .nr-toolbar {
  -webkit-mask-image: none !important;
  mask-image: none !important;
}

/* =========================================================
   MOBILE MAP COVER GEOMETRY
   ========================================================= */
@media (max-width: 700px) {

  /* Current-route preview:
     replace the old short fixed-height crop with a stable ratio. */
  #nova-run-game[data-settings-page="map"] .nr-scene-focus > img {
    display: block;
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    object-position: center center;
  }

  /* Challenge-map covers:
     the old mobile layout used an excessively short 16/7 strip. */
  #nova-run-game[data-settings-page="map"]
  .nr-scene-challenge
  .nr-scene-image {
    display: block;
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: 16 / 9 !important;
    overflow: hidden;
  }

  #nova-run-game[data-settings-page="map"] .nr-scene-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
  }
}

/* =========================================================
   CHALLENGE MODE — PORTRAIT TOP HUD
   Challenge status panel is painted at the top of the canvas.
   Put the HTML logo and controls below it.
   ========================================================= */
@media (pointer: coarse) and (orientation: portrait) {

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-brand,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-brand {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      82px
    ) !important;

    left: 50% !important;
    transform: translateX(-50%) !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-orientation,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-orientation {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      142px
    ) !important;

    left: calc(var(--safe-left) + 10px) !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-quick-controls,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-quick-controls {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      142px
    ) !important;

    right: calc(var(--safe-right) + 10px) !important;
  }
}

/* =========================================================
   MOBILE LANDSCAPE
   ========================================================= */
@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {

  /* The challenge status panel occupies approximately y=18–72.
     Keep the orientation button beneath it. */
  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-orientation,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-orientation {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      82px
    ) !important;

    left: calc(var(--safe-left) + 10px) !important;
  }

  /* Restore only the challenge left/right SVG arrows.
     Do not alter jump, dash or slide labels. */
  #nova-run-game[data-game-type="challenge"]
  .nr-move
  .btn > span[aria-hidden="true"] {
    display: grid !important;
    place-items: center;
    width: 100%;
    height: 100%;
    pointer-events: none;
  }

  #nova-run-game[data-game-type="challenge"]
  .nr-move
  .btn svg {
    display: block !important;
    width: 27px;
    height: 27px;
    overflow: visible;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  /* Outer settings body owns scrolling.
     This replaces the broken nested clipping chain. */
  #nova-run-game[data-settings-page="map"]
  .nr-settings-scroll {
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding-bottom: calc(20px + var(--safe-bottom));
  }

  #nova-run-game[data-settings-page="map"]
  [data-settings-section="map"] {
    grid-template-rows: auto auto !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding-bottom: calc(18px + var(--safe-bottom));
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-picker {
    display: grid !important;

    /* Fractional columns shrink safely on narrower phones.
       No fixed minimum width that can force horizontal overflow. */
    grid-template-columns:
      minmax(0, 0.92fr)
      minmax(0, 1.08fr) !important;

    grid-template-rows: auto auto auto !important;
    align-items: start;
    gap: 7px 10px;

    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-picker-head,
  #nova-run-game[data-settings-page="map"]
  .nr-scene-tabs {
    grid-column: 1 / -1 !important;
  }

  /* Left column: real selectable cards. */
  #nova-run-game[data-settings-page="map"]
  .nr-scene-grid {
    grid-column: 1 !important;
    grid-row: 3 !important;

    display: grid !important;
    grid-template-columns: 1fr !important;
    align-content: start;
    gap: 7px;

    width: 100%;
    height: auto !important;
    min-height: 0 !important;

    overflow: visible !important;
    padding: 0 4px calc(18px + var(--safe-bottom)) 0;

    position: relative;
    z-index: 4;
    pointer-events: auto !important;
  }

  /* Right column: current-route preview.
     It cannot cover or steal taps from the left list. */
  #nova-run-game[data-settings-page="map"]
  .nr-scene-focus {
    grid-column: 2 !important;
    grid-row: 3 !important;

    position: relative !important;
    top: auto !important;
    align-self: start;

    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    margin: 0;

    overflow: hidden;
    z-index: 1;
    pointer-events: none !important;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-focus > img {
    display: block;
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: 16 / 9;

    object-fit: cover;
    object-position: center center;
  }

  /* Only visible cards are forced into the landscape layout.
     Hidden cards from the other mode remain hidden. */
  #nova-run-game[data-settings-page="map"]
  .nr-scene-card:not([hidden]) {
    display: grid !important;
    grid-template-columns: 116px minmax(0, 1fr) !important;
    grid-column: auto !important;

    width: 100%;
    height: auto !important;
    min-height: 84px !important;

    padding: 0;
    flex-shrink: 0;

    position: relative;
    z-index: 5;

    overflow: hidden;
    cursor: pointer;
    pointer-events: auto !important;
    touch-action: manipulation;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-card:not([hidden])
  .nr-scene-image {
    display: block;
    width: 116px;
    height: 84px !important;
    min-height: 84px !important;
    aspect-ratio: auto !important;

    overflow: hidden;
    pointer-events: none;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-card:not([hidden])
  .nr-scene-image img {
    display: block;
    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center center;
    pointer-events: none;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-card:not([hidden])
  .nr-scene-copy {
    min-width: 0;
    min-height: 84px;

    align-content: center;
    padding: 7px 9px;

    pointer-events: none;
  }

  /* Every visual child ignores touch so the button itself
     receives the click. */
  #nova-run-game[data-settings-page="map"]
  .nr-scene-image::after,
  #nova-run-game[data-settings-page="map"]
  .nr-scene-image > i,
  #nova-run-game[data-settings-page="map"]
  .nr-scene-image > em,
  #nova-run-game[data-settings-page="map"]
  .nr-scene-image > mark {
    pointer-events: none !important;
  }
}

/* Keep the portrait pause label on its own row below the top controls. */
@media (pointer: coarse) and (orientation: portrait) {
  #nova-run-game[data-game-type="runner"][data-mode="pause"] > .nr-pause-status {
    top: calc(var(--safe-top) + var(--visual-top-offset, 0px) + 128px);
    bottom: auto;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="pause"] > .nr-pause-status {
    top: calc(var(--safe-top) + var(--visual-top-offset, 0px) + 230px);
    bottom: auto;
  }
}

/* Extra-narrow landscape fallback:
   stack the preview and cards instead of squeezing both columns. */
@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) and
       (max-width: 680px) {

  #nova-run-game[data-settings-page="map"]
  .nr-scene-picker {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto auto !important;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-focus {
    grid-column: 1 !important;
    grid-row: 3 !important;
  }

  #nova-run-game[data-settings-page="map"]
  .nr-scene-grid {
    grid-column: 1 !important;
    grid-row: 4 !important;
  }
}
/* =========================================================
   NOVA RUN — FINAL UI POLISH V17

   Fixes:
   1. Desktop pause message overlapping NOVA RUN
   2. Portrait challenge logo above all HUD and controls
   3. Larger portrait runner logo
   4. Prevent button long-press text selection/callout
   ========================================================= */

/* Prevent game buttons from being selected, copied or dragged. */
#nova-run-game button,
#nova-run-game button *,
#nova-run-game [role="button"],
#nova-run-game [role="button"] * {
  -webkit-user-select: none !important;
  user-select: none !important;
  -webkit-touch-callout: none !important;
}

#nova-run-game button img,
#nova-run-game button svg,
#nova-run-game [role="button"] img,
#nova-run-game [role="button"] svg {
  -webkit-user-drag: none;
  pointer-events: none;
}

/* Desktop pause layout:
   NOVA RUN stays at the top.
   The pause status moves clearly underneath it. */
@media (hover: hover) and
       (pointer: fine) and
       (min-width: 901px) and
       (min-height: 600px) {

  #nova-run-game[data-mode="pause"] .nr-brand {
    top: calc(env(safe-area-inset-top, 0px) + 12px) !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    z-index: 7 !important;
  }

  #nova-run-game[data-mode="pause"] .nr-pause-status {
    top: calc(env(safe-area-inset-top, 0px) + 86px) !important;
    bottom: auto !important;
    left: 50% !important;
    right: auto !important;
    margin: 0 !important;
    transform: translateX(-50%) !important;
    z-index: 6 !important;
  }
}

/* Portrait runner:
   increase the logo scale without affecting landscape or desktop. */
@media (pointer: coarse) and (orientation: portrait) {

  #nova-run-game[data-game-type="runner"][data-mode="play"] .nr-brand,
  #nova-run-game[data-game-type="runner"][data-mode="pause"] .nr-brand {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      8px
    ) !important;

    left: 50% !important;
    transform: translateX(-50%) scale(1.16) !important;
    transform-origin: top center;
    z-index: 7 !important;
  }

  #nova-run-game[data-game-type="runner"][data-mode="play"] .nr-orientation,
  #nova-run-game[data-game-type="runner"][data-mode="pause"] .nr-orientation {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      70px
    ) !important;
  }

  #nova-run-game[data-game-type="runner"][data-mode="play"] .nr-quick-controls,
  #nova-run-game[data-game-type="runner"][data-mode="pause"] .nr-quick-controls {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      70px
    ) !important;
  }
}

/* Portrait challenge final hierarchy:

   Row 1: NOVA RUN
   Row 2: challenge status panel, painted by map JS
   Row 3: orientation / pause / settings

   The status panel is moved to y=76 in all three challenge maps. */
@media (pointer: coarse) and (orientation: portrait) {

  #nova-run-game[data-game-type="challenge"][data-mode="play"] .nr-brand,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"] .nr-brand {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      8px
    ) !important;

    left: 50% !important;
    transform: translateX(-50%) scale(1.04) !important;
    transform-origin: top center;
    z-index: 7 !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"] .nr-orientation,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"] .nr-orientation {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      144px
    ) !important;

    left: calc(var(--safe-left) + 10px) !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"] .nr-quick-controls,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"] .nr-quick-controls {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      144px
    ) !important;

    right: calc(var(--safe-right) + 10px) !important;
  }
}
/* =========================================================
   NOVA RUN — SAFE UI FIX V19
   Scope:
   - landscape settings compact layout
   - neutral character preview frame
   - portrait challenge HUD hierarchy
   - long-press protection
   ========================================================= */

/* Prevent selection, copying, callouts and dragging in game UI. */
#nova-run-game,
#nova-run-game * {
  -webkit-user-select: none !important;
  user-select: none !important;
  -webkit-touch-callout: none !important;
  -webkit-tap-highlight-color: transparent;
}

#nova-run-game img,
#nova-run-game svg,
#nova-run-game canvas {
  -webkit-user-drag: none;
}

#nova-run-game input,
#nova-run-game textarea,
#nova-run-game select,
#nova-run-game [contenteditable="true"] {
  -webkit-user-select: text !important;
  user-select: text !important;
  -webkit-touch-callout: default !important;
}

/* Challenge mode has no difficulty selection. */
#nova-run-game[data-settings-scene-mode="challenge"]
.nr-difficulty-setting {
  display: none !important;
}

/* Character focus frame must stay neutral.
   Character-specific colors remain inside the canvas. */
#nova-run-game .nr-character-focus,
#nova-run-game .nr-character-stage {
  border-color: var(--nr-line-cool) !important;
}

#nova-run-game .nr-character-focus {
  box-shadow:
    inset 0 1px rgba(255,255,255,.05),
    0 10px 26px rgba(0,0,0,.18) !important;
}

/* Compact settings header on short landscape screens. */
@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {

  #nova-run-game.settings-open .nr-toolbar {
    top: calc(var(--safe-top) + 8px) !important;
    bottom: calc(var(--safe-bottom) + 8px) !important;
  }

  #nova-run-game .nr-settings-heading {
    min-height: 54px !important;
    padding: 5px 10px 5px 16px !important;
  }

  #nova-run-game .nr-settings-heading .nr-close-button {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;

    inline-size: 44px !important;
    block-size: 44px !important;
    min-inline-size: 44px !important;
    min-block-size: 44px !important;
  }

  #nova-run-game .nr-panel-tabs {
    margin: 8px 12px 0 !important;
    padding: 3px !important;
  }

  #nova-run-game .nr-panel-tabs button {
    min-height: 42px !important;
  }

  #nova-run-game .nr-settings-scroll {
    padding: 10px 12px
      calc(10px + var(--safe-bottom)) !important;
  }
}

/* Portrait challenge hierarchy:
   brand -> status panel -> controls. */
@media (pointer: coarse) and
       (orientation: portrait) {

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-brand,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-brand {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      7px
    ) !important;

    left: 50% !important;
    transform: translateX(-50%) scale(.92) !important;
    transform-origin: top center;
    z-index: 7 !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-orientation,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-orientation {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      172px
    ) !important;

    left: calc(var(--safe-left) + 16px) !important;

    width: 108px !important;
    min-width: 108px !important;
    height: 50px !important;
    min-height: 50px !important;

    padding: 0 13px !important;
    border-radius: 16px !important;
    font-size: 14px !important;
  }

  #nova-run-game[data-game-type="challenge"][data-mode="play"]
  .nr-quick-controls,
  #nova-run-game[data-game-type="challenge"][data-mode="pause"]
  .nr-quick-controls {
    top: calc(
      var(--safe-top) +
      var(--visual-top-offset, 0px) +
      172px
    ) !important;

    right: calc(var(--safe-right) + 16px) !important;
    gap: 8px !important;
  }

  #nova-run-game[data-game-type="challenge"]
  .nr-quick-controls .btn {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
    min-height: 50px !important;

    inline-size: 50px !important;
    block-size: 50px !important;
    min-inline-size: 50px !important;
    min-block-size: 50px !important;

    padding: 0 !important;
    border-radius: 16px !important;
  }
}

@media (pointer: coarse) and
       (orientation: portrait) and
       (max-width: 360px) {

  #nova-run-game[data-game-type="challenge"]
  .nr-orientation {
    left: calc(var(--safe-left) + 12px) !important;
    width: 98px !important;
    min-width: 98px !important;
  }

  #nova-run-game[data-game-type="challenge"]
  .nr-quick-controls {
    right: calc(var(--safe-right) + 12px) !important;
    gap: 6px !important;
  }

  #nova-run-game[data-game-type="challenge"]
  .nr-quick-controls .btn {
    width: 46px !important;
    height: 46px !important;
    min-width: 46px !important;
    min-height: 46px !important;

    inline-size: 46px !important;
    block-size: 46px !important;
    min-inline-size: 46px !important;
    min-block-size: 46px !important;
  }
}

/* =========================================================
   NOVA RUN — FINAL LOCKED ROUTE + ORIENTATION UI V23

   Scope:
   - premium locked challenge cards
   - no fake completion checkmarks
   - orientation hint never overlaps NOVA RUN
   - cross-browser selection CSS complement
   ========================================================= */

/* ---------------------------------------------------------
   Cross-browser selection protection
   Complements the long-press JavaScript already in ui.js.
   --------------------------------------------------------- */

#nova-run-game,
#nova-run-game * {
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
  user-select: none !important;

  -webkit-touch-callout: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

/* Inputs and share text remain usable. */
#nova-run-game input,
#nova-run-game textarea,
#nova-run-game select,
#nova-run-game [contenteditable="true"] {
  -webkit-user-select: text !important;
  -moz-user-select: text !important;
  -ms-user-select: text !important;
  user-select: text !important;

  -webkit-touch-callout: default !important;
}

/* Ordinary controls keep normal taps. */
#nova-run-game button,
#nova-run-game [role="button"] {
  touch-action: manipulation;
}

/* Map and character cards must remain vertically scrollable. */
#nova-run-game .nr-scene-card,
#nova-run-game .nr-skin-card {
  touch-action: pan-y !important;
}

/* Gameplay controls retain continuous press/release input. */
#nova-run-game [data-act],
#nova-run-game canvas {
  touch-action: none !important;
}

/* The tutorial is a compact lower-third. The opening step owns the game clock,
   so the route stays still until the player performs the first jump. */
#nova-run-game .nr-tutorial{
  top:auto;
  bottom:max(22px,calc(var(--safe-bottom) + 18px));
  display:grid;
  grid-template-columns:1fr auto;
  gap:2px 14px;
  width:min(520px,calc(100% - 28px));
  padding:11px 13px 12px;
  text-align:left;
  border-color:rgba(116,213,139,.62);
  box-shadow:0 12px 30px rgba(0,0,0,.25),inset 3px 0 rgba(116,213,139,.58);
}
#nova-run-game .nr-tutorial-head{display:contents}
#nova-run-game .nr-tutorial-step{align-self:center;grid-column:1;grid-row:1}
#nova-run-game .nr-tutorial-head .nr-close-button{grid-column:2;grid-row:1/4;align-self:center;pointer-events:auto}
#nova-run-game .nr-tutorial strong{grid-column:1;margin-top:1px;font-size:16px}
#nova-run-game .nr-tutorial p{grid-column:1;margin:3px 0 0;line-height:1.45}
#nova-run-game .nr-tutorial>.btn{display:none}
#nova-run-game[data-tutorial-gate="on"] .nr-tutorial{border-color:var(--viz-series-3);box-shadow:0 14px 34px rgba(0,0,0,.3),inset 3px 0 var(--viz-series-3)}
@media(pointer:coarse),(max-width:700px){
  #nova-run-game .nr-tutorial{bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 96px);width:min(480px,calc(100% - 20px));padding:9px 11px}
  #nova-run-game .nr-tutorial strong{font-size:15px}
  #nova-run-game .nr-tutorial p{font-size:11px}
}
@media(pointer:coarse) and (orientation:landscape) and (max-height:520px){
  #nova-run-game .nr-tutorial{top:auto;left:50%;bottom:calc(var(--safe-bottom) + var(--visual-bottom-offset,0px) + 68px);transform:translateX(-50%);width:min(500px,58%)}
}

/* ---------------------------------------------------------
   Premium locked challenge-card treatment
   --------------------------------------------------------- */

#nova-run-game .nr-scene-card[data-locked="true"] {
  opacity: 1 !important;
  cursor: not-allowed;

  background:
    linear-gradient(
      145deg,
      rgba(35, 37, 36, .98),
      rgba(25, 27, 27, .98)
    );

  border-color: rgba(112, 159, 163, .34) !important;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .035),
    0 10px 26px rgba(0, 0, 0, .22) !important;
}

#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image img {
  transform: none !important;

  filter:
    grayscale(.88)
    saturate(.34)
    brightness(.46)
    contrast(1.08);
}

/* Dark cinematic wash over the cover. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image::after {
  inset: 0;
  height: auto;

  background:
    linear-gradient(
      135deg,
      rgba(8, 12, 13, .22),
      rgba(10, 14, 15, .78)
    ),
    repeating-linear-gradient(
      135deg,
      transparent 0 13px,
      rgba(255, 255, 255, .018) 13px 14px
    );
}

/* Replace the old full-screen plain text with a compact badge. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image > em {
  inset:
    50%
    auto
    auto
    50%;

  width: max-content;
  max-width: calc(100% - 34px);

  transform: translate(-50%, -50%);

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;

  padding: 12px 17px 11px;

  color: rgba(245, 239, 230, .94);

  background:
    linear-gradient(
      145deg,
      rgba(24, 29, 30, .88),
      rgba(14, 18, 19, .94)
    );

  border: 1px solid rgba(117, 174, 178, .52);
  border-radius: 13px;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .055),
    0 10px 24px rgba(0, 0, 0, .36),
    0 0 22px rgba(103, 165, 164, .08);

  backdrop-filter:
    blur(9px)
    saturate(.82);

  -webkit-backdrop-filter:
    blur(9px)
    saturate(.82);

  font-size: clamp(11px, 3vw, 14px);
  font-style: normal;
  font-weight: 750;
  letter-spacing: .035em;
  line-height: 1.3;
  text-align: center;
  white-space: normal;
}

/* Small translated LOCKED heading. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image > em::before {
  content: attr(data-label);

  color: rgb(122, 183, 186);

  font-size: 9px;
  font-weight: 900;
  letter-spacing: .22em;
  line-height: 1;
  text-transform: uppercase;
}

/* Fine accent line under the requirement. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image > em::after {
  content: "";

  width: 38px;
  height: 1px;

  margin-top: 1px;

  background:
    linear-gradient(
      90deg,
      transparent,
      rgba(217, 119, 83, .82),
      transparent
    );
}

/* Make the text area quieter without making it unreadable. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy {
  opacity: .74;
}

#nova-run-game
.nr-scene-card[data-locked="true"]:hover {
  transform: none !important;

  border-color: rgba(112, 159, 163, .34) !important;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .035),
    0 10px 26px rgba(0, 0, 0, .22) !important;
}

/* ---------------------------------------------------------
   Orientation hint
   Move it away from the centered NOVA RUN logo.
   --------------------------------------------------------- */

@media (pointer: coarse) {
  #nova-run-game .nr-orientation-hint {
    top: auto !important;
    left: 50% !important;
    right: auto !important;

    width: max-content;
    max-width: min(86vw, 430px);

    padding: 9px 15px;

    color: rgba(246, 240, 231, .96);

    background:
      linear-gradient(
        145deg,
        rgba(25, 29, 30, .94),
        rgba(14, 18, 19, .96)
      );

    border: 1px solid rgba(111, 170, 174, .54);
    border-radius: 12px;

    box-shadow:
      inset 0 1px rgba(255, 255, 255, .055),
      0 8px 22px rgba(0, 0, 0, .34);

    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    transform: translateX(-50%) !important;

    font-size: 13px;
    line-height: 1.35;
    text-align: center;
    white-space: normal;

    pointer-events: none;
    z-index: 10;
  }
}

/* Portrait: above the bottom gameplay controls. */
@media (pointer: coarse) and
       (orientation: portrait) {
  #nova-run-game .nr-orientation-hint {
    bottom: calc(
      var(--safe-bottom) +
      var(--visual-bottom-offset, 0px) +
      126px
    ) !important;
  }
}

/*
 * Landscape:
 * controls sit on the left and right, so the bottom centre is free.
 */
@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {
  #nova-run-game .nr-orientation-hint {
    bottom: calc(
      var(--safe-bottom) +
      var(--visual-bottom-offset, 0px) +
      14px
    ) !important;

    max-width: min(52vw, 420px);
  }
}
/* =========================================================
   NOVA RUN — SAFE LOCKED CARD LAYOUT V24

   Lock requirements are placed inside the normal text area,
   never over the preview image.
   ========================================================= */

/* Fail-safe: no lock text is ever allowed over the image. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image > em {
  display: none !important;
}

/* Refined locked card surface. */
#nova-run-game .nr-scene-card[data-locked="true"] {
  position: relative;

  opacity: 1 !important;
  cursor: not-allowed;

  border-color: rgba(103, 165, 164, .38) !important;

  background:
    linear-gradient(
      145deg,
      rgba(34, 36, 35, .98),
      rgba(24, 26, 26, .98)
    ) !important;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .035),
    0 9px 24px rgba(0, 0, 0, .2) !important;
}

/* Keep the location visible, but clearly unavailable. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image img {
  transform: none !important;

  filter:
    grayscale(.7)
    saturate(.44)
    brightness(.62)
    contrast(1.04) !important;
}

/* Simple cinematic shading, no centre badge. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-image::after {
  inset: 0 !important;
  height: auto !important;

  background:
    linear-gradient(
      180deg,
      rgba(8, 12, 13, .08),
      rgba(8, 12, 13, .48)
    ) !important;
}

/* Do not fade the title and description. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy {
  opacity: 1 !important;
}

/*
 * “独立关卡” and “锁定条件” should not compete
 * for attention on a locked challenge card.
 */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy > b {
  display: none !important;
}

/* Premium lock-information row inside the copy area. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy > em {
  position: relative !important;
  inset: auto !important;

  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;

  width: 100%;
  max-width: 100%;

  margin: 6px 0 0;
  padding: 7px 9px;

  transform: none !important;

  color: rgba(232, 225, 215, .94);

  background:
    linear-gradient(
      110deg,
      rgba(103, 165, 164, .12),
      rgba(217, 119, 83, .055)
    );

  border:
    1px solid
    rgba(103, 165, 164, .34);

  border-left:
    3px solid
    rgba(217, 119, 83, .86);

  border-radius: 8px;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .035);

  font-size: 10px;
  font-style: normal;
  font-weight: 750;
  letter-spacing: .035em;
  line-height: 1.3;
  text-align: left;
  white-space: normal;

  pointer-events: none;
}

/* Small LOCKED label. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy > em::before {
  content: attr(data-label);

  flex: 0 0 auto;

  padding: 3px 6px;

  color: rgb(153, 205, 205);

  background:
    rgba(103, 165, 164, .14);

  border:
    1px solid
    rgba(103, 165, 164, .3);

  border-radius: 999px;

  font-size: 8px;
  font-weight: 900;
  letter-spacing: .1em;
  line-height: 1;
}

/* Remove the decorative V23 line from the old centre badge. */
#nova-run-game
.nr-scene-card[data-locked="true"]
.nr-scene-copy > em::after {
  content: none !important;
}

/* Locked cards never jump upward on mouse hover. */
#nova-run-game
.nr-scene-card[data-locked="true"]:hover {
  transform: none !important;

  border-color:
    rgba(103, 165, 164, .38) !important;

  box-shadow:
    inset 0 1px rgba(255, 255, 255, .035),
    0 9px 24px rgba(0, 0, 0, .2) !important;
}

/*
 * Low-height landscape uses compact horizontal cards.
 * Keep the lock row compact enough to remain inside the copy column.
 */
@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {

  #nova-run-game
  .nr-scene-card[data-locked="true"]
  .nr-scene-copy > em {
    gap: 5px;
    margin-top: 4px;
    padding: 5px 7px;
    font-size: 9px;
    line-height: 1.2;
  }

  #nova-run-game
  .nr-scene-card[data-locked="true"]
  .nr-scene-copy > em::before {
    padding: 2px 5px;
    font-size: 7px;
  }
}
/* =========================================================
   NOVA RUN — LANDSCAPE PROFILE LAYOUT V25
   横屏成长记录：减少空白并充分利用宽度
   ========================================================= */

@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {

  /* 横屏时让成长记录居中并利用屏幕宽度 */
  #nova-run-game .nr-profile-panel {
    left: 50% !important;
    right: auto !important;

    top: calc(var(--safe-top) + 8px) !important;
    bottom: calc(var(--safe-bottom) + 8px) !important;

    width: min(
      760px,
      calc(
        100% -
        var(--safe-left) -
        var(--safe-right) -
        16px
      )
    ) !important;

    max-height: none !important;
    transform: translateX(-50%) !important;

    padding: 10px 12px 12px !important;
    border-radius: 6px 18px 6px 18px !important;

    overflow-x: hidden;
    overflow-y: auto;
  }

  /* 压缩原来过高的标题区域 */
  #nova-run-game
  .nr-profile-panel
  .nr-panel-head {
    min-height: 42px !important;
    margin: 0 !important;
    padding: 0 0 7px !important;
  }

  /* 横屏关闭按钮稍微缩小 */
  #nova-run-game
  .nr-profile-panel
  .nr-close-button {
    --nr-icon-size: 42px;
  }

  /* 四项统计改成同一行，减少纵向浪费 */
  #nova-run-game
  .nr-profile-panel
  .nr-stat-grid {
    grid-template-columns:
      repeat(4, minmax(0, 1fr)) !important;

    gap: 7px !important;
    margin: 8px 0 7px !important;
  }

  #nova-run-game
  .nr-profile-panel
  .nr-stat {
    min-width: 0;
    padding: 7px 8px !important;
  }

  #nova-run-game
  .nr-profile-panel
  .nr-stat span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  #nova-run-game
  .nr-profile-panel
  .nr-stat strong {
    font-size: 17px !important;
    white-space: nowrap;
  }

  /* 压缩每日任务和成就之间的无效间距 */
  #nova-run-game
  .nr-profile-panel h3 {
    margin: 8px 0 5px !important;
  }

  #nova-run-game
  .nr-profile-panel
  .nr-daily-item {
    margin: 4px 0 !important;
  }
}
/* =========================================================
   NOVA RUN V30 — HIDE GAME HUD BEHIND MODALS
   /* =========================================================
   NOVA RUN V31 — SETTINGS LAYER HARD ISOLATION
   ========================================================= */

/*
 * 设置或其他模态窗口打开时，彻底移除底层 HUD。
 * 使用直接子元素选择器，避免误伤设置窗口内部元素。
 */
#nova-run-game.settings-open > .nr-quick-controls,
#nova-run-game.settings-open > .nr-orientation,
#nova-run-game.settings-open > .nr-brand,
#nova-run-game.settings-open > .nr-pause-status,
#nova-run-game.modal-open > .nr-quick-controls,
#nova-run-game.modal-open > .nr-orientation,
#nova-run-game.modal-open > .nr-brand,
#nova-run-game.modal-open > .nr-pause-status {
  display: none !important;
}

/*
 * 设置面板建立独立绘制层，避免手机浏览器的合成层残影。
 */
#nova-run-game.settings-open > .nr-toolbar {
  isolation: isolate;
}

/*
 * 面板使用完全不透明背景。
 */
#nova-run-game[data-theme="light"].settings-open > .nr-toolbar {
  background: rgb(247, 243, 237) !important;
}

#nova-run-game[data-theme="dark"].settings-open > .nr-toolbar {
  background: rgb(21, 23, 24) !important;
}

/*
 * 固定日间模式标签栏和选中项的绘制效果。
 * 防止旧规则、点击状态或手机合成层形成深色上沿。
 */
#nova-run-game[data-theme="light"].settings-open .nr-panel-tabs {
  background: rgb(233, 225, 215) !important;
  border-color: rgb(215, 203, 192) !important;
}

#nova-run-game[data-theme="light"].settings-open
.nr-panel-tabs button[aria-selected="true"] {
  position: relative;
  z-index: 1;
  transform: none !important;
  filter: none !important;
  background: rgb(255, 250, 244) !important;
  box-shadow:
    0 1px 3px rgba(75, 58, 43, 0.10),
    inset 0 -2px rgb(197, 106, 73) !important;
}
/* =========================================================
   NOVA RUN V33 — MOBILE LANDSCAPE COMPOSITOR FIX
   ========================================================= */

@media (pointer: coarse) and
       (orientation: landscape) and
       (max-height: 600px) {

  /*
   * Android Chromium may retain/sample dark HUD layers through
   * backdrop-filter even after the HUD is hidden.
   */
  #nova-run-game.settings-open > .nr-toolbar {
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;

    contain: paint;
    isolation: isolate;
  }

  /*
   * Use a fully opaque paint surface.
   */
  #nova-run-game[data-theme="light"].settings-open > .nr-toolbar {
    background: rgb(247, 243, 237) !important;
  }

  #nova-run-game[data-theme="dark"].settings-open > .nr-toolbar {
    background: rgb(21, 23, 24) !important;
  }

  /*
   * Keep the underlying HUD out of both layout and compositing.
   */
  #nova-run-game.settings-open > .nr-quick-controls,
  #nova-run-game.settings-open > .nr-orientation,
  #nova-run-game.settings-open > .nr-brand,
  #nova-run-game.settings-open > .nr-pause-status {
    display: none !important;
    box-shadow: none !important;
    filter: none !important;
  }
}
