/* «Угадай фильм» в зале (0.32, hall-game.js): the start dialog, the game card over the stage (a bottom sheet on a
   phone) and the pill of a minimised game. Emphasis = the one flat accent button; no glow, no pulse. */
.hg-modal { position: fixed; inset: 0; z-index: 2400; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .66); backdrop-filter: blur(3px); padding: 20px; }
.hg-modal.hidden { display: none; }
.hg-sheet { width: 100%; max-width: 540px; max-height: calc(100vh - 40px); overflow-y: auto; background: linear-gradient(180deg, var(--panel-2), var(--panel)); border: 1px solid var(--line); border-radius: 16px; padding: 18px 18px 16px; box-shadow: 0 24px 70px rgba(0, 0, 0, .6); color: var(--text); }
.hg-mhead { display: flex; align-items: center; gap: 10px; font-size: 17px; }
.hg-x { margin-left: auto; width: 40px; height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 24px; line-height: 1; cursor: pointer; }
.hg-x:hover { color: var(--text); background: rgba(255, 255, 255, .06); }
.hg-msub { margin: 8px 0 4px; color: var(--muted); font-size: 13px; line-height: 1.45; }
.hg-label { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 14px 0 8px; }
.hg-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.hg-chip { display: grid; grid-template-columns: auto 1fr; align-items: center; column-gap: 8px; min-height: 48px; padding: 8px 10px; text-align: left; border-radius: 11px; border: 1px solid var(--line); background: rgba(255, 255, 255, .03); color: var(--text); font: inherit; font-size: 14px; cursor: pointer; }
.hg-chip small { grid-column: 2; color: var(--muted); font-size: 11.5px; line-height: 1.3; }
.hg-chip:hover { border-color: rgba(229, 160, 13, .6); }
.hg-chip[aria-checked="true"] { border-color: var(--accent); background: rgba(229, 160, 13, .13); }
.hg-rounds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hg-rounds .hg-chip { grid-template-columns: 1fr; justify-items: center; font-size: 17px; }
.hg-mnote { margin: 14px 0 0; font-size: 12.5px; color: var(--muted); }
/* 0.33: the dialog's groups — «Угадай фильм» (kinds), «Викторины» (party-games.js + «Опрос клуба»), «Творческие» (games with
   their own dialog: draw-game.js and the others put a button in .hg-others), 0.38 «Для компании» («Шпион»); .hg-msub then
   says what the chosen game is. */
.hg-group { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.hg-group:first-of-type { margin-top: 10px; border-top: 0; padding-top: 0; }
.hg-group[hidden] { display: none; }
.hg-ghead { display: flex; flex-direction: column; gap: 2px; margin-bottom: 9px; }
.hg-gtitle { font-size: 15px; }
.hg-gdesc { font-size: 12.5px; color: var(--muted); line-height: 1.35; }
.hg-kinds .hg-chip[data-kind="mix"] { grid-column: 1 / -1; }
.hg-others { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.hg-others > [hidden] { display: none !important; }
.hg-others .dg-entry { margin: 0; padding: 0; border: 0; display: grid; } /* 0.38: grid — its button fills the row's height like the others */
.hg-group[data-group="create"]:not(:has(.hg-others > :not([hidden]))) { display: none; }
/* 0.38: «Для компании» shows only with a game in it; «Викторины» keeps its chips when its button row is empty */
.hg-group[data-group="company"]:not(:has(.hg-others > :not([hidden]))) { display: none; }
.hg-group[data-group="quiz"] .hg-others { margin-top: 8px; }
.hg-group[data-group="quiz"] .hg-others:not(:has(> :not([hidden]))) { display: none; }
.hg-sheet > .hg-msub { margin: 14px 0 0; padding: 9px 11px; border-radius: 10px; background: rgba(255, 255, 255, .035); }
.hg-mwarn { margin: 8px 0 0; font-size: 13px; color: var(--bad); }
.hg-mbtns { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }
.hg-mbtns button { min-height: 44px; padding: 0 18px; border-radius: 11px; font: inherit; font-weight: 600; cursor: pointer; }
.hg-cancel { border: 1px solid var(--line); background: transparent; color: var(--text); }
.hg-go { border: 0; background: var(--accent); color: #111; font-size: 15.5px; padding: 0 24px !important; }

.hg-card { position: absolute; inset: 10px; margin: auto; z-index: 45; width: min(700px, calc(100% - 20px)); height: fit-content; max-height: calc(100% - 20px); overflow-y: auto; overscroll-behavior: contain;
  display: flex; flex-direction: column; gap: 10px; padding: 12px 14px 14px; border-radius: 14px; background: #101218; border: 1px solid var(--line); box-shadow: 0 18px 50px rgba(0, 0, 0, .55); color: var(--text); }
.hg-card.hidden { display: none; } /* 0.35 G1b: the card opaque (it was 97 %: the lobby's posters showed through the options on a phone) */
body.hg-on.lobby-on .video-wrap { overflow: hidden; } /* the lobby does not scroll away under the game */
.hg-head { display: flex; align-items: center; gap: 10px; min-height: 34px; }
.hg-kicker { font-size: 11px; font-weight: 800; letter-spacing: .12em; color: var(--accent); }
.hg-step { font-size: 12.5px; color: var(--muted); }
.hg-min { margin-left: auto; width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--line); background: transparent; color: var(--muted); font-size: 20px; line-height: 1; cursor: pointer; }
.hg-body { display: flex; flex-direction: column; gap: 10px; }
.hg-riddle { border-radius: 11px; background: #07080b; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.hg-frame img { display: block; width: 100%; max-height: clamp(140px, 36vh, 330px); object-fit: contain; user-select: none; -webkit-user-drag: none; }
.hg-quote { margin: 0; padding: 18px 20px; flex-direction: column; align-items: flex-start; gap: 6px; background: rgba(255, 255, 255, .04); font-size: 18px; line-height: 1.45; font-style: italic; }
.hg-quote p { margin: 0; }
.hg-emoji { padding: 18px 12px; background: rgba(255, 255, 255, .04); font-size: clamp(34px, 7vw, 54px); line-height: 1.2; letter-spacing: .06em; text-align: center; flex-wrap: wrap; }
.hg-music { flex-direction: column; gap: 10px; padding: 22px 12px; background: radial-gradient(circle at 50% 35%, rgba(229, 160, 13, .16), transparent 70%), #07080b; color: var(--muted); font-size: 14px; }
.hg-eq { display: flex; gap: 5px; align-items: flex-end; height: 38px; }
.hg-eq i { width: 7px; height: 8px; border-radius: 3px; background: var(--accent); animation: hg-eq .9s ease-in-out infinite; }
.hg-eq i:nth-child(2) { animation-delay: -.25s; } .hg-eq i:nth-child(3) { animation-delay: -.5s; } .hg-eq i:nth-child(4) { animation-delay: -.7s; } .hg-eq i:nth-child(5) { animation-delay: -.15s; }
@keyframes hg-eq { 0%, 100% { height: 8px; } 50% { height: 38px; } }
.hg-card:not([data-phase="round"]) .hg-eq i { animation: none; height: 14px; }
.hg-mrow { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.hg-sound, .hg-again { min-height: 44px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line); background: rgba(255, 255, 255, .06); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; }
.hg-sound { border: 0; background: var(--accent); color: #111; }
.hg-sound.hidden, .hg-again.hidden { display: none; }
.hg-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.hg-opt { display: flex; align-items: center; gap: 9px; min-height: 52px; padding: 8px 12px; text-align: left; border-radius: 11px; border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .05); color: var(--text); font: inherit; font-size: 14.5px; font-weight: 600; line-height: 1.25; cursor: pointer; }
.hg-opt:hover:not(:disabled) { border-color: var(--accent); }
.hg-opt:disabled { cursor: default; }
.hg-n { flex: none; width: 24px; height: 24px; border-radius: 7px; display: inline-flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, .08); color: var(--muted); font-size: 12px; }
.hg-t { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.hg-c { margin-left: auto; font-style: normal; font-size: 12px; color: var(--muted); }
.hg-opt.mine { border-color: var(--accent); background: rgba(229, 160, 13, .14); }
.hg-opt.right { border-color: var(--ok); background: rgba(62, 207, 122, .16); }
.hg-opt.wrong { border-color: var(--bad); background: rgba(255, 107, 107, .14); }
.hg-bar { height: 4px; border-radius: 3px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.hg-bar i { display: block; height: 100%; width: 100%; background: var(--accent); transition: width .2s linear; }
.hg-hurry .hg-bar i { background: var(--bad); }
.hg-status { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: var(--muted); }
.hg-secs { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--text); }
.hg-note { font-size: 13px; color: var(--muted); line-height: 1.4; }
.hg-note:empty { display: none; }
.hg-prep, .hg-lead { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 26px 10px; text-align: center; }
.hg-prep span { color: var(--muted); font-size: 13px; }
.hg-spin { width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .12); border-top-color: var(--accent); animation: hg-spin .9s linear infinite; }
@keyframes hg-spin { to { transform: rotate(360deg); } }
.hg-lead-k { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.hg-big { font-size: 28px; }
.hg-lead-n { min-height: 1.1em; font-size: 44px; font-weight: 800; font-variant-numeric: tabular-nums; }
.hg-film { display: flex; align-items: center; gap: 12px; }
.hg-poster { flex: none; width: 72px; aspect-ratio: 2 / 3; border-radius: 8px; overflow: hidden; background: #1a1d24; }
.hg-poster img { display: block; width: 100%; height: 100%; object-fit: cover; }
.hg-ftext { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.hg-kick2 { font-size: 12px; color: var(--muted); }
.hg-ftitle { font-size: 18px; line-height: 1.25; }
.hg-year { font-weight: 500; color: var(--muted); }
.hg-orig { font-size: 13px; color: var(--muted); }
.hg-plus { font-size: 22px; color: var(--ok); }
.hg-miss { font-size: 14px; font-weight: 700; color: var(--bad); }
.hg-btitle { font-size: 15px; font-weight: 700; }
.hg-board { display: flex; flex-direction: column; gap: 4px; }
.hg-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto auto; align-items: center; gap: 10px; min-height: 40px; padding: 6px 10px; border-radius: 9px; background: rgba(255, 255, 255, .04); font-size: 14px; }
.hg-row.me { background: rgba(229, 160, 13, .14); }
.hg-place { text-align: center; font-weight: 700; color: var(--muted); }
.hg-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hg-delta { font-size: 12.5px; font-weight: 700; color: var(--ok); }
.hg-score { font-variant-numeric: tabular-nums; }
.hg-gap { text-align: center; color: var(--muted); line-height: .8; }
.hg-podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 8px; }
div.hg-step { min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; padding: 10px 6px; border-radius: 11px 11px 6px 6px; background: rgba(255, 255, 255, .05); text-align: center; }
.hg-s0 { min-height: 106px; } .hg-s1 { min-height: 132px; background: rgba(229, 160, 13, .14); } .hg-s2 { min-height: 92px; }
div.hg-step.me { box-shadow: inset 0 0 0 2px var(--accent); }
div.hg-step .hg-name { max-width: 100%; font-size: 14px; }
.hg-empty { background: transparent; }
.hg-medal { font-size: 26px; line-height: 1; }
.hg-club { font-size: 12.5px; font-weight: 700; color: var(--accent); }
.hg-foot { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.hg-btn { min-height: 40px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: var(--text); font: inherit; font-size: 13.5px; cursor: pointer; }
.hg-btn:hover { border-color: var(--muted); }
.hg-end { color: var(--bad); }
.hg-pill { position: fixed; left: 14px; bottom: 90px; z-index: 46; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--accent); background: rgba(16, 18, 24, .95); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; box-shadow: 0 8px 24px rgba(0, 0, 0, .5); }
.hg-pill.hidden { display: none; }
@media (min-width: 1100px) { .hg-card[data-phase="round"], .hg-card[data-phase="reveal"] { width: min(880px, calc(100% - 20px)); } }
@media (max-width: 760px) {
  .hg-card { position: fixed; inset: auto 0 0 0; margin: 0; width: 100%; max-height: 88vh; z-index: 1900; border-radius: 16px 16px 0 0; padding: 12px 12px calc(14px + env(safe-area-inset-bottom, 0px)); }
  .hg-opts { grid-template-columns: 1fr; }
  .hg-opt { min-height: 48px; }
  .hg-frame img { max-height: 32vh; }
  .hg-quote { padding: 14px; font-size: 16px; }
  .hg-pill { left: 10px; bottom: 74px; }
  .hg-sheet { padding: 16px 14px 14px; }
  .hg-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 380px) and (max-width: 760px) { .hg-opts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .hg-eq i { animation: none; height: 22px; } .hg-spin { animation-duration: 3s; } .hg-bar i { transition: none; } }
