/* 0.60 «Сезоны» Halloween — «Хоррор-викторина» (public/horror-quiz.js): a haunted late-night TV show — an old wooden TV
   set with a rounded glass screen (soft static, scanlines, a green-grey glow), the question on the screen in titles only,
   four big remote buttons below (each its own colour + number, not colour alone), the pumpkin ×2, the scores. No sounds,
   no posters. Phones first: the TV on top, two buttons a row; reduced motion: the static stands still. The Halloween row in
   «Игры в зале» (.htq-*) is styled in scary-tale.css. */
.hq-board { position: fixed; inset: 0; z-index: 2650; display: flex; align-items: center; justify-content: center; padding: 18px; background: rgba(5, 4, 10, .8); }
.hq-board.hidden { display: none; }
.hq-room { position: relative; display: flex; flex-direction: column; gap: 10px; width: min(760px, 100%); max-height: calc(100dvh - 36px); overflow-y: auto; padding-bottom: 14px; border-radius: 18px; color: #f1ecff;
  background: radial-gradient(70% 40% at 50% 18%, rgba(140, 220, 170, .08), transparent 70%), linear-gradient(180deg, #17101f, #231530 60%, #150d1c);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .7), inset 0 0 0 1px rgba(255, 170, 90, .16); }
.hq-top { display: flex; align-items: center; gap: 10px; padding: 12px 14px 0; }
.hq-title { display: flex; align-items: center; gap: 8px; min-width: 0; font-family: 'Playfair Display', Georgia, serif; font-size: 20px; color: #ffb35c; }
.hq-title img { width: 26px; height: 26px; object-fit: contain; }
.hq-where { margin-left: auto; color: #c2b8dc; font-size: 13px; white-space: nowrap; }
.hq-x { width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .06); color: inherit; font-size: 22px; line-height: 1; cursor: pointer; }
.hq-x:focus-visible, .hq-go:focus-visible, .hq-opt:focus-visible, .hq-pump:focus-visible, .hq-end:focus-visible { outline: 2px solid #ffc46b; outline-offset: 2px; }

/* the TV set */
.hq-tv { position: relative; margin: 0 16px; padding: 16px 16px 22px; border-radius: 22px; background: linear-gradient(180deg, #6b4526, #4a2e17); box-shadow: inset 0 2px 0 rgba(255, 255, 255, .15), inset 0 -4px 0 rgba(0, 0, 0, .35), 0 10px 24px rgba(0, 0, 0, .5); }
.hq-screen { position: relative; min-height: 150px; border-radius: 26px / 20px; overflow: hidden; background: radial-gradient(120% 120% at 50% 40%, #2c3a33, #121a16 70%, #070a08); box-shadow: inset 0 0 40px rgba(0, 0, 0, .8), 0 0 0 6px #1c120a; }
.hq-static { position: absolute; inset: -20%; opacity: .12; pointer-events: none;
  background-image: repeating-linear-gradient(0deg, rgba(255, 255, 255, .5) 0 1px, transparent 1px 3px), radial-gradient(circle at 20% 30%, rgba(255, 255, 255, .7) 0 1px, transparent 2px), radial-gradient(circle at 70% 60%, rgba(255, 255, 255, .6) 0 1px, transparent 2px);
  background-size: 100% 3px, 7px 9px, 11px 7px; animation: hq-drift 1.4s steps(6) infinite; }
@keyframes hq-drift { to { transform: translate(3%, 2%); } }
.hq-glass { position: relative; display: flex; align-items: center; justify-content: center; min-height: 150px; padding: 16px 18px; text-align: center; color: #e9fff1; text-shadow: 0 0 8px rgba(150, 255, 200, .35); }
.hq-card { display: flex; flex-direction: column; gap: 6px; }
.hq-card small, .hq-q small { color: #a8d8bd; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.hq-card b { font-family: 'Playfair Display', Georgia, serif; font-size: 28px; line-height: 1.15; color: #fff; }
.hq-q { display: flex; flex-direction: column; gap: 8px; }
.hq-q p { margin: 0; font-size: 20px; line-height: 1.35; font-weight: 600; }
.hq-verdict { font-size: 14px !important; font-weight: 500 !important; color: #ffd9a0; }
.hq-time { position: absolute; left: 40px; right: 40px; bottom: 8px; height: 5px; border-radius: 3px; background: rgba(0, 0, 0, .35); overflow: hidden; visibility: hidden; }
.hq-time.on { visibility: visible; }
.hq-time > i { display: block; height: 100%; background: linear-gradient(90deg, #ffb35c, #ff7a1a); transform-origin: 0 50%; }

/* the remote */
.hq-main { display: flex; flex-direction: column; gap: 10px; padding: 0 16px; }
.hq-rules { margin: 0; padding: 0 0 0 20px; color: #ddd6f3; line-height: 1.5; display: flex; flex-direction: column; gap: 4px; }
.hq-go { align-self: center; min-height: 44px; padding: 0 24px; border-radius: 999px; border: 0; font: inherit; font-weight: 700; color: #2a1606; cursor: pointer; background: linear-gradient(180deg, #ffc277, #f08a2c); box-shadow: 0 6px 18px rgba(240, 140, 50, .35); }
.hq-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hq-opt { --c: #7b5cd6; display: flex; align-items: center; gap: 10px; min-height: 60px; padding: 8px 12px; border-radius: 14px; border: 2px solid var(--c); background: color-mix(in srgb, var(--c) 18%, #1a1226); color: #fff; font: inherit; font-size: 15px; text-align: left; cursor: pointer; }
.hq-opt.c1 { --c: #2f9e8f; } .hq-opt.c2 { --c: #d0702a; } .hq-opt.c3 { --c: #c0447a; }
.hq-opt:hover:not(:disabled) { background: color-mix(in srgb, var(--c) 32%, #1a1226); }
.hq-opt:disabled { cursor: default; opacity: .72; }
.hq-opt.mine { opacity: 1; box-shadow: 0 0 0 3px rgba(255, 255, 255, .55); }
.hq-opt.right { opacity: 1; background: #2f8a46; border-color: #8ff0a8; box-shadow: 0 0 18px rgba(120, 240, 150, .45); }
.hq-opt.wrong { opacity: 1; background: #5a1f2a; border-color: #ff8a9a; }
.hq-k { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--c); font-weight: 800; font-size: 14px; }
.hq-o { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.hq-o small { color: rgba(255, 255, 255, .7); font-size: 12px; }
.hq-under { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.hq-pump { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px 0 8px; border-radius: 999px; border: 1px solid rgba(255, 170, 90, .5); background: rgba(255, 140, 40, .08); color: #ffd9a0; font: inherit; font-size: 14px; cursor: pointer; }
.hq-pump svg { width: 26px; height: 26px; filter: grayscale(.6) brightness(.8); transition: filter .2s; }
.hq-pump.on { background: rgba(255, 140, 40, .3); border-color: #ffb35c; color: #fff; }
.hq-pump.on svg { filter: drop-shadow(0 0 8px rgba(255, 160, 50, .9)); }
.hq-pump.used { opacity: .5; cursor: default; }
.hq-pump.static { cursor: default; }
.hq-note { margin: 0; color: #c2b8dc; font-size: 13px; }
.hq-end { align-self: center; min-height: 36px; padding: 0 16px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .18); background: transparent; color: #c9c6ea; font: inherit; font-size: 13px; cursor: pointer; }

/* scores */
.hq-rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.hq-rows li { display: grid; grid-template-columns: 24px auto 1fr auto; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 10px; background: rgba(255, 255, 255, .05); }
.hq-rows li.me { box-shadow: inset 0 0 0 1px #ffb35c; }
.hq-rows i { font-style: normal; color: #c2b8dc; }
.hq-pl { color: #ffb35c; font-weight: 700; }
.hq-nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-av { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; overflow: hidden; background: #4a3066; color: #fff; font-weight: 700; font-size: 13px; flex: none; }
.hq-av img { width: 100%; height: 100%; object-fit: cover; }
.hq-steps { list-style: none; margin: 0; padding: 0; display: flex; justify-content: center; align-items: flex-end; gap: 12px; }
.hq-step { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 12px; min-width: 92px; border-radius: 12px 12px 4px 4px; background: rgba(255, 255, 255, .06); text-align: center; }
.hq-step .hq-av { width: 40px; height: 40px; }
.hq-step.p1 { order: 2; padding-top: 18px; background: linear-gradient(180deg, rgba(255, 179, 92, .32), rgba(255, 179, 92, .06)); }
.hq-step.p2 { order: 1; } .hq-step.p3 { order: 3; }
.hq-step b { font-size: 14px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-step small { color: #c9c6ea; }

@media (max-width: 560px) {
  .hq-board { padding: 0; }
  .hq-room { width: 100%; max-height: 100dvh; height: 100dvh; border-radius: 0; }
  .hq-tv { margin: 0 10px; padding: 10px 10px 18px; }
  .hq-screen, .hq-glass { min-height: 128px; }
  .hq-q p { font-size: 17px; }
  .hq-card b { font-size: 23px; }
  .hq-main { padding: 0 10px; }
  .hq-opt { min-height: 56px; font-size: 14px; padding: 6px 8px; gap: 8px; }
  .hq-steps { gap: 6px; } .hq-step { min-width: 0; flex: 1; }
}
@media (max-width: 360px) { .hq-top { padding: 10px 10px 0; gap: 8px; } .hq-title { font-size: 16px; } .hq-title img { display: none; } .hq-where { font-size: 12px; } }
@media (prefers-reduced-motion: reduce) { .hq-static { animation: none; } .hq-pump svg { transition: none; } }
