/*
  Proxy: a theme for bunnyhop.lol custom CSS (https://bunnyhop.lol/custom-css). Black and off-white with signal orange,
  halftone dots, hazard tape and sticker labels; the map tiles are tapes on a video-store shelf.
  Players paste a short file that imports this one and sets the options:

    @import url(https://bunnyhop.lol/custom-css/themes/proxy.css);
    :root { --proxy-accent: #ff6a13; --proxy-panel: #141414; --proxy-art: url(https://...gif); --proxy-art-size: 1; }

  Options:
    --proxy-accent    the signal colour: signs, tape, labels, the entry to press, HUD highlights, the sticker's shadow
    --proxy-panel     panels and the black of the menus
    --proxy-art       a picture in the corner, any image link: url(https://...gif). It gets a white sticker edge and a shadow in the accent.
    --proxy-art-size  1 is normal, 0 hides the picture, above 1 makes it bigger (1.3)

  Fonts: Anton and Barlow Condensed (SIL Open Font License,
  https://bunnyhop.lol/custom-css/themes/proxy-anton-OFL.txt and
  https://bunnyhop.lol/custom-css/themes/proxy-condensed-OFL.txt).
  Everything here uses the hooks the guide promises unless a comment says the class names may change.
*/

@font-face { font-family: "Proxy Anton"; src: url(https://bunnyhop.lol/custom-css/themes/proxy-anton.woff2) format("woff2"); }
@font-face { font-family: "Proxy Condensed"; font-style: italic; font-weight: 600; src: url(https://bunnyhop.lol/custom-css/themes/proxy-condensed-600i.woff2) format("woff2"); }
@font-face { font-family: "Proxy Condensed"; font-style: italic; font-weight: 700 900; src: url(https://bunnyhop.lol/custom-css/themes/proxy-condensed-800i.woff2) format("woff2"); }

:root {
  /* Options (the pasted file sets these). No picture unless one is set: a transparent pixel. */
  --proxy-accent: #ff6a13;
  --proxy-panel: #141414;
  --proxy-art: url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7");
  --proxy-art-size: 1;

  --px-ink: color-mix(in srgb, var(--proxy-panel) 40%, #000);
  --px-raised: color-mix(in srgb, var(--proxy-panel) 90%, #fff);
  --px-edge: color-mix(in srgb, var(--proxy-panel) 78%, #fff);
  --px-hazard: repeating-linear-gradient(-45deg, var(--px-ink) 0 0.42em, var(--proxy-accent) 0.42em 0.84em);
  /* A little TV static: SVG noise, as a data: URL. */
  --px-static: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.9 -0.3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.22'/%3E%3C/svg%3E");
  --px-display: "Proxy Anton", Impact, "Arial Narrow", sans-serif;
  --px-label: "Proxy Condensed", "Arial Narrow", sans-serif;

  --ink-0: var(--px-ink);
  --ink-1: var(--proxy-panel);
  --ink-2: color-mix(in srgb, var(--proxy-panel) 94%, #fff);
  --ink-3: var(--px-raised);
  --ink-4: var(--px-edge);
  --cream: #f4f4ee;
  --cream-2: #b4b4ad;
  --cream-3: #7a7a74;
  --amber: var(--proxy-accent);
  --amber-hi: color-mix(in srgb, var(--proxy-accent) 88%, #fff);
  --amber-deep: color-mix(in srgb, var(--proxy-accent) 62%, #000);
  --amber-ink: #0b0b0b;
  --amber-wash: color-mix(in srgb, var(--proxy-accent) 13%, transparent);
  --gain: var(--proxy-accent);
  --scrim: color-mix(in srgb, var(--px-ink) 82%, transparent);
  --r-1: 0.3rem; --r-2: 0.55rem; --r-3: 0.9rem;

  /* Variables that aren't in the reference (they may change). */
  --panel: color-mix(in srgb, var(--proxy-panel) 96%, transparent);
  --panel-solid: var(--proxy-panel);
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.18);
  --ring: 0 0 0 2px var(--px-ink), 0 0 0 4px var(--proxy-accent);
  --lean: 0px;
}

/* ------------------------------------------------------------------ main menu: street signs on a black wall */

body[data-screen="home"] #grid-bg { display: none; }
/* The wall: solid black on the left, breaking up into halftone dots towards the scene; faint scanlines over all of
   it. (#overlay and its ::before / ::after are not in the reference; they may change.) */
body[data-screen="home"] #overlay::before {
  --px-ht: var(--px-ink); --px-ht-x: 31vw;
  opacity: 1 !important;
  background:
    radial-gradient(circle closest-side, var(--px-ht) 138%, #0000 144%) calc(var(--px-ht-x) + 0.7rem * 0) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 130%, #0000 136%) calc(var(--px-ht-x) + 0.7rem * 1) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 122%, #0000 128%) calc(var(--px-ht-x) + 0.7rem * 2) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 115%, #0000 121%) calc(var(--px-ht-x) + 0.7rem * 3) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 107%, #0000 113%) calc(var(--px-ht-x) + 0.7rem * 4) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 100%, #0000 106%) calc(var(--px-ht-x) + 0.7rem * 5) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 93%, #0000 99%) calc(var(--px-ht-x) + 0.7rem * 6) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 86%, #0000 92%) calc(var(--px-ht-x) + 0.7rem * 7) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 78%, #0000 84%) calc(var(--px-ht-x) + 0.7rem * 8) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 72%, #0000 78%) calc(var(--px-ht-x) + 0.7rem * 9) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 65%, #0000 71%) calc(var(--px-ht-x) + 0.7rem * 10) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 58%, #0000 64%) calc(var(--px-ht-x) + 0.7rem * 11) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 52%, #0000 58%) calc(var(--px-ht-x) + 0.7rem * 12) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 46%, #0000 52%) calc(var(--px-ht-x) + 0.7rem * 13) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 39%, #0000 45%) calc(var(--px-ht-x) + 0.7rem * 14) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 34%, #0000 40%) calc(var(--px-ht-x) + 0.7rem * 15) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 28%, #0000 34%) calc(var(--px-ht-x) + 0.7rem * 16) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 23%, #0000 29%) calc(var(--px-ht-x) + 0.7rem * 17) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 18%, #0000 24%) calc(var(--px-ht-x) + 0.7rem * 18) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 13%, #0000 19%) calc(var(--px-ht-x) + 0.7rem * 19) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 9%, #0000 15%) calc(var(--px-ht-x) + 0.7rem * 20) 0 / 0.7rem 0.7rem repeat-y,
    radial-gradient(circle closest-side, var(--px-ht) 6%, #0000 12%) calc(var(--px-ht-x) + 0.7rem * 21) calc(0.7rem / 2) / 0.7rem 0.7rem repeat-y,
    linear-gradient(90deg, var(--px-ink) var(--px-ht-x), transparent 0) !important;
}
body[data-screen="home"] #overlay::after {
  opacity: 1 !important;
  background:
    var(--px-static),
    repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.2) 0 1px, transparent 1px 3px),
    linear-gradient(180deg, transparent 70%, rgba(0, 0, 0, 0.55)) !important;
}
body[data-screen="home"] #game { filter: saturate(0.85) contrast(1.05); }

/* The name on an orange sign, the line under it on a strip of off-white tape. (.home-brand, .wordmark, .tagline,
   .hop-trail: class names that may change.) */
body[data-screen="home"] .hop-trail { display: none; }
body[data-screen="home"] .wordmark {
  font-size: 2.7rem; gap: 0.25em; padding: 0.22em 0.5em 0.26em 0.35em; color: var(--px-ink);
  background: var(--proxy-accent); border: 0.09em solid var(--px-ink); border-radius: 0.28em;
  box-shadow: 0 0 0 0.06em var(--proxy-accent), 0.14em 0.16em 0 0.06em var(--px-ink);
  transform: rotate(-2.5deg); transform-origin: left bottom;
}
body[data-screen="home"] .wordmark .wm-text { font-family: var(--px-display); font-weight: 400; letter-spacing: 0.01em; font-style: italic; text-transform: uppercase; }
body[data-screen="home"] .wordmark :is(.wm-name, .wm-tld) { color: var(--px-ink); }
body[data-screen="home"] .wordmark .logo-mark { width: 1.05em; height: 1.05em; }
/* Hazard tape under the sign. */
body[data-screen="home"] .brand-row::after {
  content: ""; position: absolute; left: -1.2rem; right: -3.5rem; bottom: -1.05rem; height: 0.7rem;
  background: var(--px-hazard); transform: rotate(1.2deg); box-shadow: 0 0.15rem 0 rgba(0, 0, 0, 0.5);
}
body[data-screen="home"] .tagline {
  margin-top: 1.7rem; padding: 0.2rem 0.6rem; color: var(--px-ink); background: #f4f4ee;
  font: italic 700 1.02rem var(--px-label); letter-spacing: 0.01em; text-shadow: none; transform: rotate(-1deg);
  clip-path: polygon(0.3rem 0, 100% 0.1rem, calc(100% - 0.25rem) 100%, 0 calc(100% - 0.12rem));
}

/* Menu entries: tall italic capitals; the one to press is an orange capsule with hazard tape at its end. */
body[data-screen="home"] .hop-ind { display: none; }
body[data-screen="home"] .home-menu { margin-top: 2.2rem; gap: 0; }
body[data-screen="home"] [data-item] { padding: 0.2rem 0.6rem; color: #f4f4ee; border-radius: 99rem; transform: none; transition: background 0.1s, color 0.1s, transform 0.12s; }
body[data-screen="home"] [data-item] .mb-title { font: italic 400 1.75rem/1.12 var(--px-display); letter-spacing: 0.02em; text-shadow: none; }
body[data-screen="home"] [data-item] small, body[data-screen="home"] [data-item] small b {
  font: italic 700 0.9rem var(--px-label); color: var(--proxy-accent);
}
body[data-screen="home"] [data-item]:hover:not(:disabled), body[data-screen="home"] [data-item]:focus-visible {
  color: var(--px-ink); background: #f4f4ee; transform: translateX(0.4rem);
}
body[data-screen="home"] [data-item]:hover small, body[data-screen="home"] [data-item]:hover small b { color: var(--px-ink); }
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]) {
  margin: 0 0 0.9rem; padding: 0.45rem 4.6rem 0.45rem 1.2rem; color: var(--px-ink); background: var(--proxy-accent);
  border: 0.18rem solid var(--px-ink); border-radius: 99rem; clip-path: none;
  box-shadow: 0 0 0 0.15rem var(--proxy-accent), 0.35rem 0.4rem 0 0.15rem var(--px-ink);
}
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]) .mb-title { font-size: 2.6rem; letter-spacing: 0.03em; }
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]) .mb-hint {
  padding: 0.05rem 0.45rem; color: var(--proxy-accent); background: var(--px-ink); border-radius: 0.25rem;
  font: italic 700 0.85rem var(--px-label); text-transform: uppercase; letter-spacing: 0.06em; transform: rotate(-4deg);
}
/* The player count on Play online, in the capsule's ink. */
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]) :is(small, small b) { color: var(--px-ink); }
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"])::after {
  content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 3.6rem; border-radius: 0 99rem 99rem 0;
  background: var(--px-hazard); background-size: 1.2rem 1.2rem;
}
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]):hover, body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]):focus-visible {
  color: var(--px-ink); background: var(--amber-hi); transform: translateX(0.25rem);
  box-shadow: 0 0 0 0.15rem var(--amber-hi), 0.35rem 0.4rem 0 0.15rem var(--px-ink);
}
body[data-screen="home"] :is([data-item="play"], [data-item="play-online"]):active { transform: translate(0.45rem, 0.3rem); box-shadow: 0 0 0 0.15rem var(--amber-hi), 0.1rem 0.1rem 0 0.15rem var(--px-ink); }

/* Footer: black capsules with a white rim, orange when pointed at. (.home-foot, .home-act, .home-link, .account:
   class names that may change.) */
/* The footer's buttons wrap under the name before they reach the picture in the corner (a guest's name with Save
   progress is long), so the picture never covers one. */
body[data-screen="home"] .home-foot { max-width: calc(36.5vw - 0.6rem); }
body[data-screen="home"] .home-act {
  height: 2.5rem; padding: 0 1.1rem; border-radius: 99rem; background: var(--px-ink); color: #f4f4ee;
  box-shadow: inset 0 0 0 0.14rem #f4f4ee; font: italic 800 1.1rem var(--px-label); text-transform: uppercase; letter-spacing: 0.02em;
}
body[data-screen="home"] .home-act:hover, body[data-screen="home"] .home-act:focus-visible { background: var(--proxy-accent); color: var(--px-ink); box-shadow: inset 0 0 0 0.14rem var(--px-ink), 0 0 0 0.14rem var(--proxy-accent); }
body[data-screen="home"] :is(.act-support svg path:last-child, .act-discord svg) { color: currentColor; fill: currentColor; }
body[data-screen="home"] .home-link { font: italic 600 0.95rem var(--px-label); color: var(--cream-2); }
body[data-screen="home"] .home-link:hover { color: var(--proxy-accent); }
body[data-screen="home"] .account .name-btn { font: italic 700 1.05rem var(--px-label); }
body[data-screen="home"] .account .save-progress { font: italic 700 1rem var(--px-label); color: var(--proxy-accent); }

/* Map tiles: tapes in their cases on a shelf. The cover is the map picture under a plastic sheen, with a ridged spine
   on the left, a rental sticker for the name and a round sticker for the tier. (.home-right, .home-grid, .home-tile*:
   class names that may change.) */
body[data-screen="home"] .home-right::before {
  inset: -1.6rem -1.4rem -0.3rem; z-index: -1; border-radius: 0.6rem;
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.05) 0.09rem, transparent 0.11rem) 0 0 / 0.8rem 0.8rem,
    color-mix(in srgb, var(--px-ink) 88%, transparent);
  box-shadow: inset 0 0 0 0.16rem var(--px-edge);
}
body[data-screen="home"] .home-grid { gap: 1.45rem 0.9rem; }
body[data-screen="home"] .home-tile {
  position: relative; gap: 0.35rem; padding: 0.35rem 0.35rem 0.4rem 0.85rem; border-radius: 0.35rem;
  background: repeating-linear-gradient(0deg, #3a3a3a 0 2px, #121212 2px 4px) 0.18rem 0.35rem / 0.42rem calc(100% - 0.7rem) no-repeat, #0e0e0e;
  box-shadow: inset 0 0 0 1px #2c2c2c, 0 0.2rem 0 #000;
  transition: transform 0.12s;
}
body[data-screen="home"] .home-tile-art { position: relative; border-radius: 0.15rem; box-shadow: none; }
body[data-screen="home"] .home-tile-art::after {
  display: block; content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.22) 0 18%, transparent 18.5% 62%, rgba(255, 255, 255, 0.08) 62.5% 70%, transparent 70.5%);
}
body[data-screen="home"] .home-tile:hover, body[data-screen="home"] .home-tile:focus-visible { transform: translateY(-0.3rem); }
body[data-screen="home"] .home-tile:hover .home-tile-art, body[data-screen="home"] .home-tile:focus-visible .home-tile-art { transform: none; box-shadow: 0 0 0 0.15rem var(--proxy-accent); }
/* The shelf under each tape. */
body[data-screen="home"] .home-tile::after {
  content: ""; position: absolute; left: -0.6rem; right: -0.6rem; bottom: -0.85rem; height: 0.45rem; pointer-events: none;
  background: linear-gradient(var(--proxy-accent) 0 0.12rem, #3a3a36 0.12rem 0.24rem, #1c1c1a 0.24rem);
  box-shadow: 0 0.3rem 0.6rem rgba(0, 0, 0, 0.6);
}
body[data-screen="home"] .home-tile:hover::after { transform: translateY(0.3rem); }
/* The rental sticker. */
body[data-screen="home"] .home-tile-text { padding: 0.2rem 4.2rem 0.25rem 0.45rem; gap: 0; color: #111; background: #ecebe2; border-radius: 0.12rem; text-shadow: none; }
/* The tape's window on the right of the sticker: two reels. */
body[data-screen="home"] .home-tile-text::after {
  content: ""; position: absolute; right: 0.7rem; bottom: 0.92rem; width: 3.5rem; height: 1.7rem; border-radius: 0.3rem;
  background:
    radial-gradient(circle at 0.85rem 50%, #ecebe2 0 0.2rem, #0b0b0b 0.21rem 0.28rem, #4a4a46 0.29rem 0.56rem, transparent 0.57rem),
    radial-gradient(circle at 2.65rem 50%, #ecebe2 0 0.2rem, #0b0b0b 0.21rem 0.28rem, #4a4a46 0.29rem 0.42rem, transparent 0.43rem),
    linear-gradient(transparent 46%, rgba(255, 255, 255, 0.12) 46% 54%, transparent 54%),
    #0b0b0b;
  box-shadow: inset 0 0 0 0.12rem #2c2c2c;
}
body[data-screen="home"] .home-tile-name b { font: italic 400 1.05rem/1.15 var(--px-display); letter-spacing: 0.02em; text-transform: uppercase; color: #111; }
body[data-screen="home"] .home-tile:hover .home-tile-name b { color: #111; }
body[data-screen="home"] .home-tile-times { font: italic 700 0.85rem var(--px-label); }
body[data-screen="home"] .home-tile-times small { font: italic 600 0.8rem var(--px-label); color: #666; }
body[data-screen="home"] .home-tile-times b, body[data-screen="home"] .home-tile-times b.wr { color: #111; font-weight: 800; }
/* The tier: a round sticker stuck on the cover's corner. */
body[data-screen="home"] .home-tile .home-tile-tier {
  position: absolute; right: 0.1rem; top: -0.1rem; display: grid; place-items: center; width: 2.3rem; height: 2.3rem; border-radius: 50%;
  color: var(--px-ink); background: var(--proxy-accent); border: 0.16rem solid var(--px-ink);
  font: italic 400 1rem var(--px-display); transform: rotate(12deg); box-shadow: 0.12rem 0.15rem 0 var(--px-ink);
}

/* ------------------------------------------------------------------ the picture: a sticker with a white die-cut edge and an orange shadow */

#custom-art { z-index: 30; }
#custom-art::after {
  content: ""; position: absolute; left: 41vw; bottom: 0.5vh;
  width: calc(15vw * var(--proxy-art-size)); height: calc(15vw * var(--proxy-art-size)); max-height: calc(34vh * var(--proxy-art-size));
  background: var(--proxy-art) bottom center / contain no-repeat;
  filter: drop-shadow(0.16rem 0 0 #fff) drop-shadow(-0.16rem 0 0 #fff) drop-shadow(0 0.16rem 0 #fff) drop-shadow(0 -0.16rem 0 #fff) drop-shadow(0.35rem 0.35rem 0 var(--proxy-accent));
}
body.in-game:not(.menu-open) #custom-art::after { left: 1.2vw; bottom: 0.8vh; width: calc(12vw * var(--proxy-art-size)); height: calc(12vw * var(--proxy-art-size)); background-position: bottom left; }
body:not([data-screen="home"]).menu-open #custom-art { display: none; }

/* ------------------------------------------------------------------ pause menu and other screens */

/* (.pause-rail, .pause-panel, .rail-item, .hop-ind: class names that may change.) */
body[data-screen="pause"] :is(.pause-rail, .pause-panel) { border-radius: 0.9rem; box-shadow: inset 0 0 0 0.14rem var(--px-edge), 0.35rem 0.4rem 0 rgba(0, 0, 0, 0.6); }
body[data-screen="pause"] .hop-ind { display: none; }
body[data-screen="pause"] .pause-map { font: italic 400 1.6rem var(--px-display); letter-spacing: 0.02em; text-transform: uppercase; }
body[data-screen="pause"] [data-item] { border-radius: 99rem; font: italic 700 1.05rem var(--px-label); text-transform: uppercase; letter-spacing: 0.02em; }
body[data-screen="pause"] [data-item]:hover:not(:disabled), body[data-screen="pause"] [data-item]:focus-visible { background: #f4f4ee; color: var(--px-ink); box-shadow: none; }
body[data-screen="pause"] [data-item]:hover .ri-icon { color: var(--px-ink); }
body[data-screen="pause"] [data-item].primary { clip-path: none; color: var(--px-ink); background: var(--proxy-accent); box-shadow: inset 0 0 0 0.14rem var(--px-ink); font: italic 400 1.4rem var(--px-display); }
body[data-screen="pause"] [data-item].primary .ri-icon { color: var(--px-ink); }
body[data-screen="pause"] [data-item].primary:hover { background: var(--amber-hi); }
body[data-screen="pause"] [data-item="main-menu"] { border: 0; background: var(--px-ink); color: #f4f4ee; box-shadow: inset 0 0 0 0.14rem #f4f4ee; }
body[data-screen="pause"] [data-item="main-menu"]:hover:not(:disabled) { background: var(--loss); color: var(--px-ink); box-shadow: none; }

/* Titles of the full-screen menus (settings, maps, profile...) in the sign type. (.screen-title: may change.) */
#overlay .screen-title h2 { font: italic 400 2.4rem/1.1 var(--px-display); letter-spacing: 0.02em; text-transform: uppercase; }

/* ------------------------------------------------------------------ HUD: chunky italic numbers, a segmented bar */

#hud [data-el] { --shadow-text: none; color: #f4f4ee; }
/* Speed: outlined italic numbers on a slanted bar that fills to 1000 u/s (live number --hud-speed), with the sync
   of the run as a thin off-white bar under it (--hud-sync). */
#hud [data-el="speed"] {
  font-family: var(--px-display); font-style: italic;
  text-shadow: 0.05em 0.05em 0 var(--px-ink), -0.03em -0.03em 0 var(--px-ink), 0.03em -0.03em 0 var(--px-ink), -0.03em 0.03em 0 var(--px-ink);
}
#hud [data-el="speed"] * { font-weight: 400 !important; }
#hud [data-el="speed"]::before {
  content: ""; position: absolute; left: 50%; bottom: -0.32em; width: 13em; height: 0.62em; translate: -50% 0; z-index: -1;
  transform: skewX(-24deg); border: 0.12em solid var(--px-ink); border-radius: 0.1em;
  background:
    repeating-linear-gradient(90deg, transparent 0 calc(10% - 0.12em), var(--px-ink) calc(10% - 0.12em) 10%),
    linear-gradient(var(--proxy-accent), var(--proxy-accent)) left / calc(min(var(--hud-speed, 0), 1000) * 0.1%) 100% no-repeat,
    color-mix(in srgb, var(--px-ink) 70%, transparent);
}
#hud [data-el="speed"]::after {
  content: ""; position: absolute; left: 50%; bottom: -0.62em; width: 11.6em; height: 0.2em; translate: calc(-50% - 0.35em) 0; z-index: -1;
  transform: skewX(-24deg); border: 0.08em solid var(--px-ink);
  background: linear-gradient(#f4f4ee, #f4f4ee) left / calc(var(--hud-sync, 0) * 1%) 100% no-repeat, var(--px-ink);
}
/* Timer: white numbers in a black capsule with an orange rim. */
#hud [data-el="timer"] { font-family: var(--px-display); font-style: italic; }
#hud [data-el="timer"] * { font-weight: 400 !important; }
#hud [data-el="timer"]::before {
  content: ""; position: absolute; inset: -0.05em -0.75em -0.05em; z-index: -1; border-radius: 99em;
  background: var(--px-ink); box-shadow: inset 0 0 0 0.11em var(--proxy-accent);
}
/* Map line: a strip of orange tape with hazard stripes at its start. (The parts inside may change.) */
#hud [data-el="map"]::before {
  content: ""; position: absolute; inset: -0.35em -0.7em -0.35em -2.6em; z-index: -1;
  background: var(--px-hazard) left / 2em 100% no-repeat, var(--proxy-accent);
  background-size: 1.9em 100%, auto; clip-path: polygon(0 0, 100% 0, calc(100% - 0.5em) 100%, 0 100%);
}
#hud [data-el="map"] { color: var(--px-ink); font-family: var(--px-label); font-style: italic; font-weight: 700; }
#hud [data-el="map"] * { color: inherit !important; opacity: 1 !important; }
#hud [data-el="pb"]::before { content: ""; position: absolute; inset: -0.3em -0.7em; z-index: -1; border-radius: 99em; background: var(--px-ink); box-shadow: inset 0 0 0 0.11em #f4f4ee; }
#hud [data-el="pb"] { font-family: var(--px-label); font-style: italic; font-weight: 700; }
#hud [data-el="pb"] small { color: var(--proxy-accent) !important; }
#hud [data-el="split"] { font-family: var(--px-label); font-style: italic; font-weight: 800; }
#hud [data-el="stats"] { font-family: var(--px-label); font-style: italic; font-weight: 600; }
#hud [data-el="stats"] * { color: #f4f4ee !important; }
#hud [data-el="stats"] b { color: var(--proxy-accent) !important; font-weight: 800; }
#hud [data-el="stats"] { text-shadow: 0 0.08em 0 var(--px-ink); }
/* The keys overlay sets its colours from Settings on .keys itself (a class that may change); the theme wins with !important. */
#hud [data-el="keys"] .keys { --k-on: var(--proxy-accent) !important; --k-idle: #f4f4ee !important; }
#hud [data-el="keys"] { font-family: var(--px-label); font-style: italic; font-weight: 800; }
/* (.keys .k: class names that may change.) */
#hud [data-el="keys"] .k { background: color-mix(in srgb, var(--px-ink) 75%, transparent); border: 0.12em solid color-mix(in srgb, #f4f4ee 70%, transparent); border-radius: 0.5em; }
#hud [data-el="keys"] .k.on { background: var(--proxy-accent); border-color: var(--px-ink); color: var(--px-ink); }

/* ------------------------------------------------------------------ recent world records and room races */
/* The recent world records (#home-records) under the maps, with the stickers' lettering; the race HUD (#mp-race,
   #mp-count, #mp-place) in the HUD's faces. (.home-rec-*: class names that may change.) */
#home-records h2 { font-family: var(--px-label); font-style: italic; font-weight: 800; text-transform: uppercase; letter-spacing: 0.02em; }
#home-records .home-rec-map b { font-family: var(--px-label); font-style: italic; font-weight: 800; }
/* A record's tier stays a plain label beside the map (it shares the tiles' class). */
#home-records .home-tile-tier { font: italic 800 0.85rem var(--px-label); }

/* ------------------------------------------------------------------ the Daily Challenge */
/* On the main menu (#home-daily): today's map is the tape on the shelf with a PLAY tag on its sticker, the three
   fastest and your place beside it in the stickers' lettering. (.home-daily-*: class names that may change.) */
#home-daily h2 { font-family: var(--px-label); font-style: italic; font-weight: 800; text-transform: uppercase; letter-spacing: 0.02em; }
#home-daily [data-part="style"] { font: italic 700 0.9rem var(--px-label); color: var(--proxy-accent); text-transform: none; }
#home-daily [data-part="left"] { font: italic 700 0.9rem var(--px-label); color: var(--proxy-accent); }
#home-daily [data-part="map"] { margin-bottom: 0.85rem; }
#home-daily [data-part="map"] .home-tile-name b { padding-right: 0.15em; }
#home-daily [data-part="map"] .home-daily-play {
  padding: 0.02rem 0.3rem 0.02rem 0.45rem; color: var(--proxy-accent); background: var(--px-ink); border-radius: 0.25rem;
  font: italic 800 0.8rem var(--px-label); text-transform: uppercase; letter-spacing: 0.06em;
}
#home-daily [data-part="map"]:is(:hover, :focus-visible) .home-daily-play { color: var(--px-ink); background: var(--proxy-accent); }
#home-daily [data-part="top"] .home-daily-rank { font: italic 400 1.05rem var(--px-display); color: var(--cream-2); }
#home-daily [data-part="top"] li:first-child .home-daily-rank { color: var(--proxy-accent); }
#home-daily :is([data-part="player"] b, [data-part="you"] span) { font-family: var(--px-label); font-style: italic; font-weight: 800; }
/* The Daily Challenge page keeps the game's layout; its headings take the stickers' lettering. (.dy-*: may change.) */
body[data-screen="daily"] :is(.dy-head h2, .dy-map b) { font-family: var(--px-label); font-style: italic; font-weight: 800; }

/* ------------------------------------------------------------------ the map vote */
/* #mp-menu[data-menu="vote"] and the other numbered menus: a black plate with a white rim, the numbers in the sign
   type, your vote an orange capsule. (.mm-title, .mm-label, .mm-detail: class names that may change.) */
#hud #mp-menu {
  border: 0; border-radius: 0.7em; color: #f4f4ee; background: color-mix(in srgb, var(--px-ink) 90%, transparent);
  box-shadow: inset 0 0 0 0.12em var(--px-edge), 0.3em 0.35em 0 rgba(0, 0, 0, 0.5); font-family: var(--px-label); font-style: italic; font-weight: 600;
}
#hud #mp-menu .mm-title { font-weight: 800; text-transform: uppercase; letter-spacing: 0.02em; color: var(--proxy-accent); }
#hud #mp-menu .mm-key { font: italic 400 1.05em var(--px-display); color: var(--proxy-accent); }
#hud #mp-menu .mm-label { font-weight: 700; }
#hud #mp-menu .mm-item { border-radius: 99em; padding: 0.1em 0.6em; margin: 0 -0.4em; }
#hud #mp-menu .mm-item.sel { color: var(--px-ink); background: var(--proxy-accent); }
#hud #mp-menu .mm-item.sel :is(.mm-key, .mm-detail) { color: var(--px-ink); }
#hud :is(#mp-count, #mp-place .pl-n) { font-family: var(--px-display); font-style: italic; font-weight: 400; }
#hud :is(#mp-race, #mp-place .pl-t) { font-family: var(--px-label); font-style: italic; color: #f4f4ee; }
