/* Cyberpunk Dark Red/Purple Werewolf Theme */
:root {
    --color-bg-base: #0a050c;
    --color-bg-surface: rgba(18, 9, 23, 0.65);
    --color-bg-card: rgba(30, 15, 38, 0.45);
    --color-border: rgba(239, 68, 68, 0.15);
    --color-border-glow: rgba(239, 68, 68, 0.45);
    
    --color-primary: #ef4444;       /* Blood Red */
    --color-primary-rgb: 239, 68, 68;
    --color-secondary: #c084fc;     /* Neon Purple */
    --color-secondary-rgb: 192, 132, 252;
    --color-accent: #f59e0b;        /* Gold/Amber */
    --color-accent-rgb: 245, 158, 11;
    
    --color-emerald: #10b981;
    --color-slate-100: #f3f4f6;
    --color-slate-300: #d1d5db;
    --color-slate-400: #9ca3af;
    --color-slate-800: #1f1224;
    
    --glass-blur: blur(25px);
    --glow-shadow-primary: 0 0 25px rgba(239, 68, 68, 0.45);
    --glow-shadow-secondary: 0 0 25px rgba(192, 132, 252, 0.45);
    --glow-shadow-accent: 0 0 25px rgba(245, 158, 11, 0.45);
    --card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.55);
    --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    
    --font-heading: 'Outfit', 'Mitr', sans-serif;
    --font-body: 'Mitr', 'Outfit', sans-serif;
}

/* Base resets & styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--color-bg-base);
    color: var(--color-slate-100);
    font-family: var(--font-body);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
}

/* Background animated stars & glows */
.stars-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background-image: 
        radial-gradient(white, rgba(255,255,255,.2) 2px, transparent 40px),
        radial-gradient(white, rgba(255,255,255,.15) 1px, transparent 30px),
        radial-gradient(white, rgba(255,255,255,.1) 2px, transparent 40px);
    background-size: 550px 550px, 350px 350px, 250px 250px;
    background-position: 0 0, 40px 60px, 130px 270px;
    opacity: 0.15;
    animation: starsMove 120s linear infinite;
}

@keyframes starsMove {
    from { background-position: 0 0, 40px 60px, 130px 270px; }
    to { background-position: 550px 1100px, 390px 1160px, 680px 1370px; }
}

.ambient-glow {
    position: fixed;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(239, 68, 68, 0.15) 0%, rgba(0,0,0,0) 70%);
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: -1;
    pointer-events: none;
    filter: blur(80px);
    animation: pulseGlow 15s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    0% { transform: translateX(-50%) scale(1); opacity: 0.8; }
    100% { transform: translateX(-50%) scale(1.25); opacity: 0.5; }
}

/* App Container */
.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Game Header */
.game-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--color-bg-surface);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
}

.game-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.wolf-logo-icon {
    font-size: 2.2rem;
    filter: drop-shadow(0 0 10px var(--color-primary));
    animation: wolfHowl 6s ease-in-out infinite;
}

@keyframes wolfHowl {
    0%, 90%, 100% { transform: rotate(0deg) scale(1); }
    45% { transform: rotate(-10deg) scale(1.15); }
    55% { transform: rotate(15deg) scale(1.1); }
}

.glitch-text {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 2.2rem;
    letter-spacing: 2px;
    color: #fff;
    position: relative;
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.subtitle {
    font-size: 0.95rem;
    color: var(--color-slate-400);
}

/* Screens */
.screen {
    display: none;
    animation: fadeIn 0.4s ease-out forwards;
    flex-grow: 1;
}

.screen.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Card */
.card {
    background: var(--color-bg-surface);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: var(--card-shadow);
    margin-bottom: 1.5rem;
    transition: var(--transition-smooth);
}

.card:hover {
    border-color: var(--color-border-glow);
}

.welcome-card {
    max-width: 480px;
    margin: 0 auto 1.5rem auto;
}

.rules-card {
    max-width: 480px;
    margin: 0 auto;
    background: rgba(18, 9, 23, 0.45);
}

.rules-header h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: var(--color-secondary);
    margin-bottom: 10px;
}

.rules-body p {
    font-size: 0.85rem;
    margin-bottom: 8px;
    color: var(--color-slate-300);
}

.rules-body ul {
    list-style-position: inside;
    font-size: 0.8rem;
    color: var(--color-slate-400);
}

.rules-body li {
    margin-bottom: 6px;
}

.divider {
    border: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-border), transparent);
    margin: 1.5rem 0;
}

/* Forms */
.input-group {
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-slate-300);
}

.input-group input[type="text"] {
    background: rgba(0, 0, 0, 0.4);
    border: 1.5px solid var(--color-border);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-smooth);
    width: 100%;
}

.input-group input[type="text"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.25);
}

/* Buttons */
.btn {
    font-family: var(--font-heading);
    font-weight: 600;
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition-smooth);
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    gap: 0.5rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, #b91c1c 100%);
    color: #fff;
    box-shadow: var(--glow-shadow-primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(239, 68, 68, 0.6);
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-accent {
    background: linear-gradient(135deg, var(--color-secondary) 0%, #7e22ce 100%);
    color: #fff;
    box-shadow: var(--glow-shadow-secondary);
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(192, 132, 252, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: var(--color-slate-300);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    border-radius: 8px;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.15rem;
    border-radius: 16px;
}

/* Lobby View Layout */
.host-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 1.5rem;
}

@media (max-width: 820px) {
    .host-layout {
        grid-template-columns: 1fr;
    }
}

.host-main-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
}

@media (max-width: 550px) {
    .info-card {
        flex-direction: column;
        text-align: center;
    }
}

.room-code-display {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.room-code-display .label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--color-secondary);
}

.room-code-display .code {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: 4px;
    text-shadow: 0 0 15px rgba(192, 132, 252, 0.4);
    line-height: 1.1;
}

.connection-info {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.5rem;
}

@media (max-width: 550px) {
    .connection-info {
        align-items: center;
        text-align: center;
    }
}

.connection-info p {
    font-size: 0.85rem;
    color: var(--color-slate-400);
}

.badge {
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-owner {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-primary);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.badge-player {
    background: rgba(192, 132, 252, 0.15);
    color: var(--color-secondary);
    border: 1px solid rgba(192, 132, 252, 0.3);
}

.radar-pulse {
    width: 8px;
    height: 8px;
    background: var(--color-secondary);
    border-radius: 50%;
    position: relative;
    margin-bottom: 5px;
}

.radar-pulse::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    border: 1.5px solid var(--color-secondary);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: radarRipple 1.8s infinite ease-out;
}

@keyframes radarRipple {
    0% { width: 8px; height: 8px; opacity: 1; }
    100% { width: 36px; height: 36px; opacity: 0; }
}

.pulse-text {
    animation: blinkText 2s infinite ease-in-out;
}

@keyframes blinkText {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Player Grid / List */
.players-card h3 {
    margin-bottom: 1rem;
    font-size: 1.15rem;
    display: flex;
    justify-content: space-between;
}

.player-list-scroll {
    max-height: 280px;
    overflow-y: auto;
    padding-right: 5px;
}

.player-list-scroll::-webkit-scrollbar {
    width: 6px;
}

.player-list-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.player-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
    list-style: none;
}

.player-card-lobby {
    background: rgba(255, 255, 255, 0.03);
    border: 1.5px solid rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
    transition: var(--transition-smooth);
    position: relative;
}

.player-card-lobby.is-me {
    border-color: var(--color-secondary);
    background: rgba(192, 132, 252, 0.05);
}

.player-card-lobby.is-host {
    border-color: var(--color-primary);
    background: rgba(239, 68, 68, 0.05);
}

.player-avatar-icon {
    font-size: 1.8rem;
}

.player-name-lbl {
    font-size: 0.9rem;
    font-weight: 500;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    width: 100%;
}

.player-status-badge {
    font-size: 0.65rem;
    color: var(--color-slate-400);
}

/* Settings Card */
.settings-card h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 1.25rem;
    color: var(--color-secondary);
}

.setting-item {
    margin-bottom: 1.5rem;
}

.setting-item label {
    display: block;
    font-size: 0.85rem;
    color: var(--color-slate-300);
    margin-bottom: 0.6rem;
    font-weight: 500;
}

.setting-item select {
    width: 100%;
    background: rgba(0, 0, 0, 0.4);
    border: 1.5px solid var(--color-border);
    border-radius: 10px;
    padding: 0.7rem 1rem;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition-smooth);
}

.setting-item select:focus {
    border-color: var(--color-primary);
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.8rem;
    border-radius: 10px;
    border: 1px solid var(--color-border);
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    margin: 0;
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--color-primary);
    cursor: pointer;
}

.range-display {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.range-display input[type="range"] {
    flex-grow: 1;
    accent-color: var(--color-primary);
}

.range-display .badge {
    min-width: 60px;
    text-align: center;
    background: rgba(255,255,255,0.06);
    color: var(--color-slate-100);
    border: 1px solid rgba(255,255,255,0.1);
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* GAME SCREEN: PHASE BANNER */
.phase-banner {
    background: rgba(239, 68, 68, 0.15);
    border: 1.5px solid rgba(239, 68, 68, 0.25);
    border-radius: 14px;
    padding: 0.75rem;
    text-align: center;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 1px;
    color: var(--color-primary);
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.2);
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: var(--transition-smooth);
}

.phase-banner.day-phase {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.25);
    color: var(--color-accent);
    text-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

/* NIGHT PHASE CARD */
.night-view-card {
    padding: 0;
    overflow: hidden;
    border-color: transparent;
    background: #000;
}

.night-backdrop-black {
    background: radial-gradient(circle at center, #0e0513 0%, #000 100%);
    min-height: 480px;
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    position: relative;
}

.timer-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    z-index: 2;
}

.radar-pulse-night {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.05);
    border: 1.5px dashed rgba(239, 68, 68, 0.35);
    position: relative;
    margin-bottom: 1.5rem;
    animation: rotateDashed 20s linear infinite;
}

@keyframes rotateDashed {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.radar-pulse-night::after {
    content: '🌙';
    font-size: 1.8rem;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulseMoon 3s ease-in-out infinite alternate;
}

@keyframes pulseMoon {
    0% { transform: translate(-50%, -50%) scale(0.9); opacity: 0.6; }
    100% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; filter: drop-shadow(0 0 8px rgba(192, 132, 252, 0.5)); }
}

.night-instruction {
    font-size: 1.1rem;
    font-weight: 500;
    max-width: 450px;
    color: var(--color-slate-300);
    line-height: 1.6;
    animation: pulseBlink 2.5s ease-in-out infinite;
}

@keyframes pulseBlink {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Fingerprint scanner container */
.secret-scanner-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    z-index: 2;
}

.scan-tip {
    font-size: 0.85rem;
    color: var(--color-slate-400);
    text-align: center;
}

.fingerprint-scan-btn {
    width: 90px;
    height: 90px;
    background: rgba(255,255,255,0.03);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 2px solid rgba(192, 132, 252, 0.2);
    transition: var(--transition-smooth);
    position: relative;
}

.fingerprint-scan-btn:hover {
    border-color: var(--color-secondary);
    box-shadow: var(--glow-shadow-secondary);
}

.fingerprint-scan-btn:active,
.fingerprint-scan-btn.scanning {
    border-color: var(--color-primary);
    box-shadow: var(--glow-shadow-primary);
    transform: scale(0.95);
}

.fingerprint-svg {
    width: 55px;
    height: 55px;
}

.rotating-ring {
    transform-origin: center;
    animation: rotateRing 10s linear infinite;
}

@keyframes rotateRing {
    to { transform: rotate(360deg); }
}

/* Decrypted Role Panel */
.decrypted-role-panel {
    z-index: 2;
    width: 100%;
    max-width: 320px;
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes popIn {
    from { opacity: 0; transform: scale(0.85); }
    to { opacity: 1; transform: scale(1); }
}

.decrypted-card {
    background: rgba(30, 15, 38, 0.7);
    border: 2px solid var(--color-primary);
    border-radius: 20px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 0 25px rgba(239, 68, 68, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.role-avatar {
    font-size: 3.5rem;
    filter: drop-shadow(0 0 10px rgba(239, 68, 68, 0.4));
}

.role-highlight {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 2rem;
    color: var(--color-primary);
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
    letter-spacing: 1px;
}

.role-desc {
    font-size: 0.85rem;
    color: var(--color-slate-300);
}

/* Active action panel during night */
.active-night-action-panel {
    z-index: 2;
    width: 100%;
    max-width: 440px;
    animation: popIn 0.4s ease-out forwards;
    background: rgba(0, 0, 0, 0.65);
    padding: 1.5rem;
    border-radius: 16px;
    border: 1.5px solid var(--color-secondary);
    box-shadow: 0 0 20px rgba(192, 132, 252, 0.2);
}

.active-night-action-panel h3 {
    font-family: var(--font-heading);
    color: var(--color-secondary);
    font-size: 1.05rem;
    margin-bottom: 12px;
    text-align: center;
}

.action-options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 10px;
}

.action-btn {
    background: rgba(255,255,255,0.03);
    border: 1.5px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 0.8rem;
    color: #fff;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    transition: var(--transition-smooth);
}

.action-btn:hover {
    border-color: var(--color-secondary);
    background: rgba(192, 132, 252, 0.05);
}

.action-btn.selected {
    border-color: var(--color-primary);
    background: rgba(239, 68, 68, 0.1);
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.25);
}

.action-btn .icon {
    font-size: 1.5rem;
}

/* DAY PHASE / DISCUSSION */
.day-layout {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .day-layout {
        grid-template-columns: 1fr;
    }
}

.day-main {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.discussion-timer-box {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.timer-label {
    font-size: 0.85rem;
    color: var(--color-slate-300);
}

.timer-value {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-accent);
    text-shadow: 0 0 10px rgba(245, 158, 11, 0.3);
}

.voting-section h3 {
    font-size: 1.05rem;
    margin-bottom: 12px;
    color: var(--color-slate-300);
}

.player-vote-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 0.75rem;
}

.vote-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1.5px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    text-align: center;
    transition: var(--transition-smooth);
}

.vote-card:hover {
    border-color: var(--color-secondary);
    background: rgba(192, 132, 252, 0.04);
}

.vote-card.selected {
    border-color: var(--color-primary);
    background: rgba(239, 68, 68, 0.08);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.2);
}

.vote-card.voted-for-me {
    box-shadow: 0 0 10px var(--color-emerald);
    border-color: var(--color-emerald);
}

.vote-card .name {
    font-size: 0.85rem;
    font-weight: 500;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vote-count-badge {
    background: var(--color-primary);
    color: #fff;
    font-size: 0.7rem;
    padding: 0.1rem 0.4rem;
    border-radius: 10px;
    font-weight: 600;
    margin-top: 2px;
}

.rules-side-card h4 {
    font-size: 1rem;
    margin-bottom: 10px;
    color: var(--color-accent);
}

.rules-side-card p {
    font-size: 0.8rem;
    line-height: 1.5;
    color: var(--color-slate-300);
}

/* REVEAL / END GAME VIEW */
.reveal-view-card {
    text-align: center;
}

.winner-title {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--color-emerald);
    text-shadow: 0 0 15px rgba(16, 185, 129, 0.3);
    margin-bottom: 0.5rem;
}

.winner-desc {
    font-size: 0.95rem;
    color: var(--color-slate-300);
    margin-bottom: 2rem;
}

.reveal-boards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    text-align: left;
}

@media (max-width: 768px) {
    .reveal-boards-grid {
        grid-template-columns: 1fr;
    }
}

.reveal-board-section h3 {
    font-size: 1.05rem;
    margin-bottom: 12px;
    color: var(--color-secondary);
    border-left: 3px solid var(--color-secondary);
    padding-left: 8px;
}

.reveal-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    overflow: hidden;
}

.reveal-table th, .reveal-table td {
    padding: 0.75rem 1rem;
    font-size: 0.85rem;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}

.reveal-table th {
    background: rgba(255,255,255,0.03);
    font-weight: 600;
    color: var(--color-slate-300);
}

.reveal-table td {
    color: var(--color-slate-100);
}

.reveal-table tr:last-child td {
    border-bottom: none;
}

.role-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
}

.role-badge.werewolf {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.role-badge.villager {
    background: rgba(255, 255, 255, 0.05);
    color: var(--color-slate-300);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.role-badge.seer {
    background: rgba(6, 182, 212, 0.15);
    color: #67e8f9;
    border: 1px solid rgba(6, 182, 212, 0.3);
}

.role-badge.robber {
    background: rgba(245, 158, 11, 0.15);
    color: #fde047;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.role-badge.troublemaker {
    background: rgba(168, 85, 247, 0.15);
    color: #e9d5ff;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.role-badge.minion {
    background: rgba(157, 23, 77, 0.15);
    color: #fbcfe8;
    border: 1px solid rgba(157, 23, 77, 0.3);
}

.role-badge.tanner {
    background: rgba(20, 83, 45, 0.15);
    color: #bbf7d0;
    border: 1px solid rgba(20, 83, 45, 0.3);
}

.role-badge.drunk {
    background: rgba(180, 83, 9, 0.15);
    color: #fed7aa;
    border: 1px solid rgba(180, 83, 9, 0.3);
}

.role-badge.insomniac {
    background: rgba(13, 148, 136, 0.15);
    color: #99f6e4;
    border: 1px solid rgba(13, 148, 136, 0.3);
}

.center-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.center-card-reveal {
    background: rgba(0, 0, 0, 0.3);
    border: 1.5px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 1rem 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
}

.center-card-reveal .idx {
    font-size: 0.7rem;
    color: var(--color-slate-400);
    text-transform: uppercase;
}

.center-card-reveal .val {
    font-size: 0.8rem;
    font-weight: 600;
}

/* Footer styling */
.game-footer {
    text-align: center;
    padding: 1.5rem 0;
    margin-top: 3rem;
    border-top: 1px solid var(--color-border);
}

.game-footer p {
    font-size: 0.85rem;
    color: var(--color-slate-400);
}

.highlight-text {
    color: var(--color-primary);
    font-weight: 500;
}

/* Modal styling */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-box {
    background: #180d20;
    border: 2px solid var(--color-primary);
    box-shadow: var(--glow-shadow-primary);
    border-radius: 20px;
    max-width: 400px;
    width: 100%;
    padding: 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.modal-box h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--color-primary);
}

.modal-box p {
    font-size: 0.9rem;
    color: var(--color-slate-300);
    line-height: 1.5;
}

/* Utility classes */
.hidden {
    display: none !important;
}

/* Mute control styling */
.mute-control-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 0.75rem;
}

.btn-mute {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: var(--color-slate-400);
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: var(--transition-smooth);
}

.btn-mute:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
}
