/* THE PHONE VERSION (Justin, 2026-11-14): on a phone the room is replaced by the handheld Amanda is playing.
   The device is his picture (img/hh-device.webp, 861 x 1488); everything inside #hhdev is placed in that picture's own
   pixels and the whole thing is scaled to the phone by handheld.js, so the screen and buttons always sit on the picture. */
html.hh #view,html.hh #vig,html.hh .hud,html.hh #radio{display:none!important}
#hh{position:fixed;inset:0;z-index:2;background:#0a0708 url(img/hh-bg.jpg) center/cover;overflow:hidden}
#hhdev{position:absolute;left:50%;top:50%;width:861px;height:1488px;transform:translate(-50%,-50%);-webkit-tap-highlight-color:transparent}
#hhdev.settle{transition:transform .7s cubic-bezier(.3,.7,.2,1)}
#hhimg{position:absolute;left:0;top:0;width:861px;height:1488px;display:block;pointer-events:none;filter:drop-shadow(0 30px 50px rgba(0,0,0,.55))}
/* "Enter The Room" (his words). 2026-11-19 (Justin): the room is the real thing and the handheld is the convenience, and a
   button under the device was "too easy to miss" - so it is ON the device, in the purple gap between the screen and the
   blue streak (device pixels, like everything in #hhdev): a lit blue button like the others, a slow glow, a shine that sweeps across.
   Shown once the device has started up. */
#hhroom{display:none;position:absolute;left:80px;top:733px;width:490px;height:45px;z-index:3;box-sizing:border-box;overflow:hidden;
  /* 2026-11-19 (Justin): "match the style of the blue buttons" - the MODE button's blue, navy rim and cream block letters */
  background:linear-gradient(#3aa0e6,#1877c9 55%,#0f5aa6);border:3px solid #0a2a5e;border-radius:12px;padding:0;
  color:#f3e4c0;font:bold 27px/1 Arial,Helvetica,sans-serif;letter-spacing:.2em;text-transform:uppercase;text-shadow:0 2px 0 rgba(6,30,70,.6);
  white-space:nowrap;cursor:pointer;-webkit-tap-highlight-color:transparent;
  box-shadow:0 0 18px 3px rgba(90,180,255,.6),0 5px 9px rgba(0,0,0,.6),inset 0 2px 0 rgba(160,215,255,.6),inset 0 -4px 6px rgba(5,30,80,.5);
  animation:hhroomglow 2.2s ease-in-out infinite}
#hhroom span{position:relative;z-index:1}
#hhroom::after{content:"";position:absolute;top:0;bottom:0;left:-40%;width:30%;transform:skewX(-20deg);
  background:linear-gradient(90deg,transparent,rgba(255,255,255,.55),transparent);animation:hhroomshine 3.6s ease-in-out infinite}
#hhroom:active{filter:brightness(.88)}
@keyframes hhroomglow{50%{box-shadow:0 0 40px 12px rgba(120,200,255,.95),0 5px 9px rgba(0,0,0,.6),inset 0 2px 0 rgba(160,215,255,.6),inset 0 -4px 6px rgba(5,30,80,.5)}}
@keyframes hhroomshine{0%,55%{left:-40%}100%{left:120%}}
#hh.up #hhroom{display:block}
@media (prefers-reduced-motion:reduce){ #hhroom,#hhroom::after{animation:none} }

/* ---- the glass ---- */
#hhscr{position:absolute;left:104px;top:130px;width:654px;height:558px;overflow:hidden;background:#05060a;border-radius:8px;
  color:#f0deb2;font:bold 30px/1.25 "Courier New",ui-monospace,Menlo,Consolas,monospace;letter-spacing:.01em}
/* a game on the device's own screen: the site's games page, shown at true size (handheld.js sizes it) */
#hhgame{position:absolute;inset:0;z-index:5;background:#05060a;overflow:hidden}
#hhgame[hidden]{display:none}
#hhgame iframe{position:absolute;left:0;top:0;border:0;transform-origin:0 0;background:#05060a;visibility:hidden}
#hhgame iframe.ready{visibility:visible}
#hhboot{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:#05060a;transition:opacity .45s;z-index:6}
#hhboot img{height:283px;filter:drop-shadow(0 0 14px rgba(240,222,178,.75))}
#hhboot.gone{opacity:0;pointer-events:none}
#hhui{position:absolute;inset:0;display:flex;flex-direction:column}
#hhui[hidden]{display:none}
#hhbar{flex:0 0 54px;display:flex;align-items:center;justify-content:space-between;padding:0 16px;background:#f0deb2;color:#0b0a10;
  text-transform:uppercase;letter-spacing:.08em;font-size:28px}
#hhnote{opacity:0}
html.sound-on #hhnote{opacity:1;animation:hhblink 1.2s steps(2) infinite}
@keyframes hhblink{50%{opacity:.25}}
#hhbody{flex:1;position:relative;overflow:hidden}
#hhlcd{position:absolute;inset:0;pointer-events:none;z-index:9;border-radius:8px;
  background:repeating-linear-gradient(0deg,rgba(0,0,0,.2) 0 2px,transparent 2px 5px);box-shadow:inset 0 0 60px rgba(0,0,0,.6)}

/* lists: one thing is always picked; the buttons move the pick, or tap a line */
.hhlist{position:absolute;inset:0;overflow-y:auto;touch-action:pan-y;scrollbar-width:none;padding:6px 0 10px}
.hhlist::-webkit-scrollbar{display:none}
.hhrow{display:flex;align-items:center;gap:16px;padding:9px 16px;min-height:44px;color:#f0deb2;text-decoration:none;cursor:pointer}
.hhrow span{flex:1;min-width:0}
.hhrow img{width:76px;height:76px;object-fit:cover;flex:0 0 76px;border:2px solid rgba(240,222,178,.5)}
.hhrow i{font-style:normal;flex:0 0 44px;text-align:center;font-size:32px}
.hhrow i img{width:36px;height:36px;border:0;vertical-align:middle}
.hhrow.on{background:#29a8f0;color:#05060a}
.hhrow.on img{border-color:#05060a}
.hhhead{padding:14px 16px 4px;color:#f0208a;font-size:24px;text-transform:uppercase;letter-spacing:.1em}
.hhlist.small .hhrow{font-size:26px;padding:7px 16px}

/* the MODE menu */
#hhmenu{position:absolute;left:0;right:0;top:54px;bottom:0;background:#05060a;z-index:5;display:grid;grid-template-columns:1fr 1fr;grid-auto-rows:1fr;gap:8px;padding:10px}
#hhmenu[hidden]{display:none}
#hhmenu button{font:inherit;font-size:29px;color:#f0deb2;background:none;border:3px solid rgba(240,222,178,.45);border-radius:6px;padding:0 4px;cursor:pointer;text-transform:uppercase}
#hhmenu button.on{background:#f0208a;border-color:#f0208a;color:#fff}

/* the strip that shows the song or the volume for a moment */
#hhosd{position:absolute;left:10px;right:10px;bottom:10px;background:#f0deb2;color:#05060a;padding:8px 12px;border-radius:4px;z-index:7;
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:0;transition:opacity .2s;pointer-events:none;font-size:26px}
#hhosd.on{opacity:1}

/* videos */
.hhvid{position:absolute;left:0;top:28px;width:654px;height:368px;background:#000;overflow:hidden}
.hhvid>div{transform-origin:0 0}
.hhvid iframe{width:100%;height:100%;border:0;display:block}
.hhvt{position:absolute;left:14px;right:14px;top:410px;font-size:25px;line-height:1.2;max-height:92px;overflow:hidden}
/* Videos = the TV (2026-11-20): the picture fills the glass under the bar, the channel number shows in green like the TV's */
.hhtv{top:0;height:504px}
.hhtv video,.hhtv canvas,.hhtv img,.hhtv .hhtvw{position:absolute;left:0;top:0;width:100%;height:100%;border:0;display:none;object-fit:cover;background:#000}
#hhtvsnow{display:block;opacity:0;image-rendering:pixelated;pointer-events:none}
.hhtv>div:first-child{position:absolute;left:0;top:0}
.hhtv .hhtvw{display:block}
.hhtvshield{position:absolute;inset:0;z-index:2}
.hhtvosd{position:absolute;left:24px;top:20px;right:24px;z-index:3;font-size:34px;line-height:1.25;color:#5cff7a;text-shadow:0 0 8px #1d8a35;
  white-space:pre-line;opacity:0;transition:opacity .4s;pointer-events:none}
.hhtvosd.on{opacity:1}
/* the channel Mom didn't pay for: scrambled, the same look as the room's TV */
.hhtv.scram #hhyt,.hhtv.scram video,.hhtv.scram #hhtvbars,.hhtv.scram #hhtvcard{filter:blur(6px) invert(1) contrast(1.8) saturate(2.4) hue-rotate(80deg);animation:scrwob 1.3s steps(11) infinite}
.hhtv.scram::after{content:"";position:absolute;inset:-20% 0;pointer-events:none;z-index:2;animation:scrroll 2.6s linear infinite;
  background:repeating-linear-gradient(0deg,rgba(0,0,0,.55) 0 18px,transparent 18px 46px,rgba(255,255,255,.08) 46px 52px,transparent 52px 80px)}
@keyframes scrwob{0%{transform:none}18%{transform:translate(-7%,4%) skewX(16deg) scaleY(1.1)}36%{transform:translate(6%,-9%) skewX(-11deg)}
  54%{transform:translate(-4%,13%) skewX(22deg) scaleX(1.12)}72%{transform:translate(9%,-5%) skewX(-18deg)}90%{transform:translate(-2%,7%) skewX(8deg)}100%{transform:none}}
@keyframes scrroll{to{transform:translateY(16%)}}

/* phonograph */
.hhph{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding:16px 12px 18px;text-align:center}
.hhrolls{display:flex;gap:10px;flex-wrap:wrap;justify-content:center}
.hhrolls button{font:inherit;font-size:22px;color:#f0deb2;background:none;border:2px solid rgba(240,222,178,.45);border-radius:20px;padding:4px 14px;cursor:pointer}
.hhrolls button.on{background:#f0deb2;color:#05060a;border-color:#f0deb2}
.hhcyl{width:300px;height:96px;border:4px solid #f0deb2;border-radius:48px/50%;position:relative;overflow:hidden;
  background:repeating-linear-gradient(90deg,transparent 0 14px,rgba(240,222,178,.55) 14px 18px)}
html.sound-on .hhcyl{animation:hhroll .5s linear infinite}
@keyframes hhroll{to{background-position:18px 0}}
.hhtt{font-size:40px;line-height:1.1}
.hhct{font-size:24px;opacity:.75}
.hhctl{display:flex;gap:26px}
.hhctl button{font:inherit;font-size:30px;width:112px;height:62px;color:#05060a;background:#29a8f0;border:0;border-radius:8px;cursor:pointer}

/* MP3: the bands and their albums. It looks like every other mode (Justin, 2026-11-18: "visually the handheld mp3 mode
   should not be different than the other modes"): the same dark glass, the same lettering, the same blue bar on the
   picked line, the same pink heading as Links, and a playing screen laid out like the Phonograph's. */
.hhmp3{position:absolute;inset:0;display:flex;flex-direction:column}
.mptop{flex:0 0 auto;display:flex;align-items:center;gap:12px;padding:12px 16px 4px;color:#f0208a;font-size:24px;text-transform:uppercase;letter-spacing:.1em}
.mptop span{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mptop i{font-style:normal;font-size:20px;color:#f0deb2}
.mpin{flex:1;position:relative;overflow:hidden}
.hhlist.mp .hhrow img{width:76px;height:114px;flex:0 0 76px;object-fit:contain;background:#f5f2ea}
.mpnow{display:flex;gap:18px;align-items:center;padding:8px 16px 0;cursor:pointer}
.mpnow img{width:190px;height:285px;flex:0 0 190px;object-fit:contain;background:#f5f2ea;border:2px solid rgba(240,222,178,.5)}
.mptx{flex:1;min-width:0;display:flex;flex-direction:column;gap:8px}
.mptx b{font-size:36px;line-height:1.1}
.mptx span{font-size:25px;font-weight:normal}
.mptx em{font-style:normal;font-weight:normal;font-size:24px;opacity:.75;margin-top:6px}
.mpbar{margin:20px 16px 6px;height:20px;border:3px solid #f0deb2;overflow:hidden}
.mpbar i{display:block;height:100%;width:0;background:#29a8f0}
.mptime{display:flex;justify-content:space-between;margin:0 16px;font-size:22px;opacity:.75}

/* catalog */
.hhcat{position:absolute;inset:0;display:flex;gap:16px;padding:14px;align-items:center}
.hhcat>img{width:280px;height:380px;object-fit:cover;background:#fff;flex:0 0 280px}
.hhcat .txt{flex:1;display:flex;flex-direction:column;gap:14px;align-items:flex-start}
.hhcat .nm{font-size:32px;line-height:1.15}
.hhcat .pr{font-size:44px;color:#f0208a}
.hhcat a{font:inherit;color:#05060a;background:#29a8f0;text-decoration:none;padding:8px 22px;border-radius:6px}
.hhcover{position:absolute;inset:0;display:flex;justify-content:center;cursor:pointer}
.hhcover>div{height:100%;aspect-ratio:2/3;background:#8e1418 url(img/catalog-cover.jpg) center/cover;position:relative}
.hhcover b{position:absolute;left:0;right:0;top:0;height:22%;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#fff;text-align:center;font-weight:normal}
.hhcover b span{font:900 30px/1 "Arial Black",Arial,sans-serif;letter-spacing:.02em;text-transform:uppercase}
.hhcover b em{font:italic 700 28px/1.1 Georgia,serif;color:#ffe9a8}
.hhpg{position:absolute;right:14px;bottom:10px;font-size:22px;opacity:.75}

/* about */
.hhabout{position:absolute;inset:0;overflow-y:auto;touch-action:pan-y;scrollbar-width:none;padding:14px 18px 30px;font-size:28px;line-height:1.3}
.hhabout::-webkit-scrollbar{display:none}
.hhabout p{margin:0 0 16px}

/* a new program being put on (the maze) */
.hhsetup{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:22px;background:#05060a;z-index:4;font-size:70px}
.hhsetup b{display:block;width:420px;height:30px;border:3px solid #f0deb2}
.hhsetup b i{display:block;height:100%;width:0;background:#f0deb2}

/* ---- the buttons: clear boxes over the picture's own buttons, darkened while held ---- */
.hhb{position:absolute;background:transparent;border:0;padding:0;margin:0;cursor:pointer;-webkit-tap-highlight-color:transparent;touch-action:none;outline:0}
.hhb.dn i{background:rgba(0,0,30,.34);box-shadow:inset 0 8px 16px rgba(0,0,0,.55)}

/* ---- a game or the chat takes the whole phone (the device's screen is too small to play on) ---- */
#hhprog{position:fixed;inset:0;z-index:40;display:flex;flex-direction:column;background:#111;transform-origin:50% 32%;transition:transform .28s,opacity .28s}
#hhprog[hidden]{display:none}
#hhprog.in{transform:scale(.3);opacity:0}
#hhprog .hhpbar{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;background:#5b1f7a;color:#f0deb2;
  font:bold 15px "Courier New",ui-monospace,monospace;padding:6px 6px 6px 12px;padding-top:calc(6px + env(safe-area-inset-top))}
#hhprog .hhpbar button{font:bold 18px Arial,sans-serif;width:40px;height:34px;color:#fff;background:#1273c4;border:0;border-radius:6px;cursor:pointer}
#hhprog .hhpbody{flex:1;position:relative;background:#111}
#hhprog iframe{position:absolute;inset:0;width:100%;height:100%;border:0;background:#111;visibility:hidden}
#hhprog iframe.ready{visibility:visible}
