#imposter-game-view { width: 100%; text-align: center; gap: 10px; }
#imposter-game-view .game-view-header { text-align: center; box-sizing: border-box; min-height: 148px; flex-shrink: 0; position: relative; }
#imposter-game-view .game-view-caption { padding: 0 85px; width: 100%; box-sizing: border-box; }
#imposter-game-view .game-view-caption h3 { font-size: clamp(1.5rem, 3vw, 2rem); margin: .25rem 0; }
#imposter-game-view .game-view-caption p { font-size: clamp(1.15rem, 2vw, 1.4rem); }
#imposter-game-view .game-view-timer-wrapper { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); margin: 0; }
#imposter-game-view > .skip-button, #imposter-lock-vote { width: fit-content; max-width: 100%; flex: 0 0 auto; align-self: center; margin-inline: auto; }
#imposter-game-view .imposter-header-role { position: absolute; top: 12px; left: 16px; margin: 0; }
#imposter-game-view .game-view-caption { padding-top: 24px; }
#imposter-game-view[data-mode^="WORD:"] .imposter-secret { color: #fff; }
.imposter-header-category { margin: .35rem 0 0; color: var(--highlight-primary); }
.imposter-role { display: inline-block; font-size: .8rem; font-weight: 800; padding: .2rem .55rem; margin-bottom: .35rem; border: 1px solid currentColor; border-radius: 999px; }
.imposter-role-regular { color: #68adff; }
.imposter-role-imposter { color: #ff707b; }
.imposter-role-spectator { color: var(--text-secondary); }
.imposter-secret.imposter-role-regular { color: #68adff; }
.imposter-secret.imposter-role-imposter { color: #ff707b; }
.imposter-missed-clue { font-style: italic; }
#imposter-timer-container[hidden] { display: block; visibility: hidden; }
#imposter-skip-discussion[hidden] { display: none; }
.imposter-phase-heading { margin: .5rem 0; }
#imposter-timer-container { position: relative; width: 80px; height: 80px; }
#imposter-timer-container svg { transform: rotate(-90deg); }
#imposter-clock { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 2em; font-weight: bold; color: var(--text-primary); }
.imposter-enter { animation: imposter-fade .45s ease both; }
.imposter-prompt { margin: auto; padding: clamp(2rem, 8vh, 5rem) 1rem; max-width: 680px; }
.imposter-secret { margin: 0 0 1.5rem; font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: bold; color: var(--highlight-primary); }
.imposter-objective { max-width: 680px; margin: .5rem auto; line-height: 1.6; color: var(--text-secondary); }
.imposter-prompt .imposter-objective { font-size: 1.15rem; color: var(--text-primary); }
.imposter-category { color: var(--highlight-primary); font-size: 1.25rem; }
.imposter-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: .75rem; margin: .25rem 0; width: 100%; align-items: start; flex-shrink: 0; }
.imposter-player-slot { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.imposter-bubble-holder { position: relative; height: 44px; flex: 0 0 44px; }
.imposter-bubble-shell { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: max-content; max-width: 100%; z-index: 2; opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s; }
.imposter-bubble-shell::after { content: ''; position: absolute; top: 100%; left: calc(50% - 8px); border: 8px solid transparent; border-top: 10px solid var(--highlight-primary); border-bottom: 0; }
.imposter-bubble-shell.is-typing { opacity: 1; visibility: visible; }
.imposter-typing-dots { display: none; align-items: center; gap: 5px; height: 18px; padding: 2px; }
.is-typing .imposter-typing-dots { display: inline-flex; }
.imposter-typing-dots i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: imposter-typing 1.1s ease-in-out infinite; }
.imposter-typing-dots i:nth-child(2) { animation-delay: .15s; }
.imposter-typing-dots i:nth-child(3) { animation-delay: .3s; }
.imposter-player { position: relative; display: flex; flex-direction: column; align-items: center; gap: .45rem; padding: .8rem .7rem; border: 2px solid var(--border-color, #444); border-radius: 16px; background: var(--bg-secondary, #24242d); color: inherit; font: inherit; min-width: 0; overflow-wrap: anywhere; transition: border-color .3s, transform .3s; }
.imposter-player:disabled { opacity: 1; cursor: default; }
.imposter-player:not(:disabled) { cursor: pointer; }
.imposter-player:not(:disabled):hover, .imposter-player.active { border-color: var(--highlight-primary); transform: translateY(-3px); }
.imposter-player img { width: 64px; height: 64px; object-fit: contain; border-radius: 50%; border: 3px solid var(--player-color); padding: 3px; box-sizing: border-box; }
.imposter-bubble { position: relative; padding: .7rem .9rem; border-radius: 20px; background: var(--highlight-primary); color: #fff; width: 100%; max-height: var(--bubble-max-height, 240px); overflow-y: auto; overscroll-behavior: contain; box-sizing: border-box; text-align: left; overflow-wrap: anywhere; box-shadow: 0 4px 12px rgba(0,0,0,.12); }
.imposter-clue-log { width: 100%; min-width: 0; flex-shrink: 0; text-align: left; }
#imposter-clue-list { display: flex; align-items: center; gap: .6rem; height: 76px; box-sizing: border-box; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; margin: 0; padding: .65rem .7rem; list-style: none; }
#imposter-clue-list li { flex: 0 0 auto; padding: .55rem 1rem; white-space: nowrap; line-height: 1.4; border-radius: 999px; background: var(--player-color, var(--highlight-primary)); color: #fff; border: 1px solid var(--player-color, var(--highlight-primary)); font-size: 1rem; font-weight: 500; }
.imposter-form { display: flex; gap: .6rem; flex-wrap: wrap; margin: .25rem 0; align-items: center; flex-shrink: 0; }
.imposter-form[hidden] { display: none; }
.imposter-form input { flex: 1; min-width: 150px; }
#imposter-game-view .option-popout { color: #fff; }
.imposter-vote-count { animation: imposter-fade .5s both; animation-delay: var(--vote-delay); }
.imposter-selected { animation: imposter-highlight .5s both; animation-delay: var(--winner-delay); }
.imposter-found { border-color: var(--error-color, #ef6470); }
@keyframes imposter-fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes imposter-highlight { to { box-shadow: 0 0 0 3px var(--highlight-primary); transform: translateY(-4px); } }
@keyframes imposter-typing { 0%, 70%, 100% { opacity: .35; transform: translateY(0); } 35% { opacity: 1; transform: translateY(-3px); } }
@media (max-width: 600px) { #imposter-timer-container { width: 48px; height: 48px; } #imposter-clock { font-size: 1.5em; } #imposter-game-view .game-view-caption { width: 100%; padding-right: 35px; box-sizing: border-box; } .imposter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { #imposter-game-view *, .imposter-enter { animation-duration: .01ms; animation-delay: 0s; transition: none; } }

.imposter-card-timer { position: absolute; top: 8px; left: 8px; display: grid; place-items: center; width: 30px; height: 30px; border: 2px solid #777985; border-radius: 50%; color: #b7b8c1; font-size: .7rem; font-variant-numeric: tabular-nums; }
.imposter-card-timer[hidden] { display: none; }
#imposter-game-view .skip-button[hidden] { display: none; }
.imposter-reveal-screen { width: 100%; min-height: 0; overflow-y: auto; }
.imposter-vote-results { display: flex; flex-direction: column; gap: .75rem; padding: 8px; margin: 0; list-style: none; }
.imposter-result-card { display: flex; align-items: center; flex-wrap: wrap; gap: .8rem; padding: .8rem 1rem; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 14px; text-align: left; animation: imposter-fade .45s both; animation-delay: var(--reveal-delay); }
.imposter-result-card > img, .imposter-identity-card img { width: 64px; height: 64px; object-fit: contain; border: 3px solid var(--player-color); border-radius: 50%; }
.imposter-result-card > span { color: var(--text-secondary); }
.imposter-voter-icons { display: flex; flex-wrap: wrap; gap: .4rem; margin-left: auto; }
.imposter-voter-icons .player-icon-display { width: 32px; height: 32px; flex: 0 0 32px; animation: imposter-pop .6s both; animation-delay: var(--reveal-delay); }
.imposter-voter-icons img { box-sizing: border-box; width: 100%; height: 100%; object-fit: contain; border: 2px solid var(--player-color); border-radius: 50%; }
.imposter-voter-icons .player-icon-display:hover, .imposter-voter-icons .player-icon-display:focus { z-index: 11; }
.imposter-voter-icons .player-icon-display:focus .player-icon-tooltip { visibility: visible; opacity: 1; }
.imposter-identity-card { padding: 1.5rem; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; }
.imposter-revealed-player { display: flex; flex-direction: column; align-items: center; gap: .5rem; animation: imposter-pop .8s both; animation-delay: var(--reveal-delay); }
.imposter-revealed-player h3 { margin: 0; }
.imposter-correct-voters { display: flex; flex-direction: column; gap: .6rem; width: min(100%, 520px); text-align: left; }
.imposter-correct-voter { display: flex; align-items: center; gap: .75rem; padding: .75rem 1rem; background: var(--bg-secondary); border: 1px solid var(--border-color); border-radius: 12px; overflow-wrap: anywhere; }
.imposter-guess-result { display: flex; align-items: center; justify-content: center; gap: .75rem; margin-bottom: 1rem; }
.imposter-guess-result img { width: 48px; height: 48px; object-fit: contain; border: 2px solid var(--player-color); border-radius: 50%; }
.imposter-identity-card img { width: 100px; height: 100px; }
.imposter-correct-voter img { width: 40px; height: 40px; flex: 0 0 40px; }
.imposter-word-comparison { background: var(--bg-secondary); border-radius: 14px; padding: clamp(1.5rem, 4vw, 3rem); margin: 1rem 0; }
.imposter-word-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.imposter-word-pair > div { display: flex; flex-direction: column; gap: .6rem; padding: 1rem; border: 1px solid var(--highlight-primary); border-radius: 10px; overflow-wrap: anywhere; }
.imposter-word-pair span { color: var(--text-secondary); font-size: .85rem; }
.imposter-word-pair strong { font-size: clamp(1.6rem, 3vw, 2.3rem); }
.imposter-guess-result { padding: 1rem 0 1.5rem; font-size: clamp(1.3rem, 2.5vw, 1.8rem); }
.imposter-word-pair .imposter-guess-box { animation: imposter-word-unveil .8s 1s both; }
.imposter-guess-verdict { animation: imposter-fade .4s 2.2s both; }
.imposter-guess-check { display: inline-block; margin-left: .5em; color: var(--success-color, #57e092); animation: imposter-pop .5s 2.2s both; }
.imposter-word-pair .imposter-guess-check { font-size: 1em; color: var(--success-color, #57e092); }
.imposter-guess-incorrect { animation: imposter-wrong .3s 2.2s both; text-decoration-color: var(--error-color, #ff707b); text-decoration-thickness: 3px; }
.imposter-correct-voter { animation: imposter-pop .55s both; animation-delay: var(--reveal-delay); }
.imposter-suspense-text { animation: imposter-suspense 3s ease both; }
#imposter-game-view .game-view-controls { padding: 15px 0; box-sizing: border-box; }
#imposter-game-view .imposter-form { width: 100%; }
.imposter-vote-results { padding-top: 35px; }
@keyframes imposter-pop { from { opacity: 0; transform: scale(1.4); } to { opacity: 1; transform: scale(1); } }
@keyframes imposter-suspense { 0% { opacity: .2; filter: blur(5px); transform: scale(.96); } 45% { opacity: 1; filter: blur(0); } 65% { opacity: .5; } 100% { opacity: 1; transform: scale(1); } }
@keyframes imposter-word-unveil { from { opacity: 0; filter: blur(12px); transform: translateY(10px); } to { opacity: 1; filter: blur(0); transform: translateY(0); } }
@keyframes imposter-wrong { to { color: var(--error-color, #ff707b); text-decoration-line: line-through; } }
.imposter-vote-check { position: absolute; top: 8px; right: 8px; display: grid; place-items: center; width: 24px; height: 24px; border: 2px solid var(--highlight-primary); border-radius: 6px; background: var(--highlight-primary); color: #fff; opacity: 0; transition: opacity .15s; }
.imposter-player.vote-selected { border-color: var(--highlight-primary); }
.vote-selected .imposter-vote-check { opacity: 1; }
.imposter-new-clue { animation: imposter-clue-glow 3.5s ease-out both; }
@keyframes imposter-clue-glow { 0%, 12% { box-shadow: 0 0 0 2px #fff, 0 0 10px 3px #fff; } 100% { box-shadow: 0 0 0 0 transparent, 0 0 0 0 transparent; } }
@media (prefers-reduced-motion: reduce) { #imposter-game-view .imposter-new-clue { animation-duration: .01ms; } }
@media (max-width: 600px) {
    #imposter-game-view .game-view-caption { padding: 24px 50px 0; }
    #imposter-game-view .game-view-timer-wrapper { right: 8px; }
}
#imposter-game-view .game-view-header { display: grid; grid-template-columns: 100px minmax(0, 1fr) 100px; align-content: center; column-gap: 12px; row-gap: 4px; }
#imposter-game-view .game-view-caption { display: contents; }
#imposter-game-view .game-view-caption h3 { grid-column: 2; grid-row: 1; text-align: center; overflow-wrap: anywhere; }
#imposter-game-view .game-view-caption p { grid-column: 2; grid-row: 2; margin: 0; text-align: center; }
#imposter-game-view .imposter-header-role { position: static; grid-column: 1; grid-row: 1; justify-self: start; align-self: center; }
#imposter-game-view .game-view-timer-wrapper { position: static; grid-column: 3; grid-row: 1 / span 2; transform: none; justify-self: end; }
@media (max-width: 600px) { #imposter-game-view .game-view-header { grid-template-columns: 80px minmax(0, 1fr) 80px; padding-inline: 12px; gap: 4px; } }
