/* --- GLOBAL HEADER BAR --- */
#game-header {
    width: 100%;
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.5rem;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 100;
    pointer-events: none;
    /* Let clicks pass through empty areas */
}

/* Enable clicks on buttons */
.header-left,
.header-right {
    pointer-events: all;
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

#settings-btn,
#sidebar-toggle {
    position: relative !important;
    /* Force into flow */
    top: auto;
    left: auto;
    right: auto;
    bottom: auto;
}

/* --- ONLINE BUTTON VISUAL ENHANCEMENT (FINAL) --- */
#online-btn {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    position: relative;
    overflow: hidden;
    /* Ultra vibrant gradient */
    background: linear-gradient(45deg, #00f260, #0575e6) !important;
    border: 3px solid rgba(255, 255, 255, 0.8) !important;
    box-shadow: 0 0 30px rgba(5, 117, 230, 0.8), inset 0 0 20px rgba(255, 255, 255, 0.5) !important;
    animation: neonPulse 1.5s infinite alternate !important;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
    z-index: 50;
}

@keyframes neonPulse {
    from {
        box-shadow: 0 0 20px rgba(5, 117, 230, 0.6), inset 0 0 10px rgba(255, 255, 255, 0.3);
    }

    to {
        box-shadow: 0 0 50px rgba(0, 242, 96, 0.8), inset 0 0 30px rgba(255, 255, 255, 0.7);
    }
}

#online-btn:hover {
    transform: scale(1.1) translateY(-5px) !important;
    background: linear-gradient(45deg, #00c9ff, #92fe9d) !important;
    box-shadow: 0 0 60px rgba(0, 201, 255, 0.9), inset 0 0 30px rgba(255, 255, 255, 0.9) !important;
    border-color: #fff !important;
}

/* More Visible Mute Button */
.mini-control-btn {
    padding: 10px 25px !important;
    font-size: 1rem !important;
    background: rgba(20, 20, 20, 0.95) !important;
    border: 2px solid var(--accent-gold) !important;
    color: var(--accent-gold) !important;
    font-weight: bold;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.mini-control-btn:hover {
    background: var(--accent-gold) !important;
    color: #000 !important;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
}

/* Header Buttons (Unified Style) */
.header-btn {
    background: rgba(255, 255, 255, 0.05);
    /* Glassy dark */
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 12px;
    padding: 0.8rem;
    min-width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.header-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    border-color: rgba(255, 215, 0, 0.5);
    /* Gold tint on hover */
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

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

/* Specific Button Tweaks */
.menu-btn {
    border-radius: 50%;
    /* Make menu circular again if desired, or keep square rounded */
    border-color: var(--accent-red);
    background: linear-gradient(135deg, rgba(40, 0, 0, 0.6), rgba(20, 0, 0, 0.8));
}

.menu-btn:hover {
    box-shadow: 0 0 15px var(--accent-red);
}

.back-btn {
    padding-right: 1.2rem;
    display: flex;
    gap: 8px;
}

.back-btn .label {
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.settings-btn .icon {
    animation: spinSlow 10s linear infinite;
}

@keyframes spinSlow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* --- TYPOGRAPHY --- */
h1.glitch-title {
    font-size: 4rem;
    color: var(--text-main);
    position: relative;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 900;
    text-shadow: 4px 4px 0px var(--accent-dark-red);
    margin: 0;
    line-height: 1;
    background: linear-gradient(to bottom, #fff, #bbb);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.2));
}

@media (max-width: 400px) {
    h1.glitch-title {
        font-size: 3rem;
    }
}

.screen-title {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 2.5rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    font-weight: 800;
    position: relative;
    display: inline-block;
}

.screen-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-red);
    margin: 0.8rem auto 0;
    border-radius: 2px;
}

/* --- CATEGORY GRID --- */
.category-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    width: 100%;
}

.category-grid .category-btn {
    flex: 0 0 calc(50% - 1rem);
}

@media (min-width: 600px) {
    .category-grid .category-btn {
        flex: 0 0 240px;
    }
}

@media (max-width: 480px) {
    .category-grid .category-btn {
        flex: 0 0 calc(50% - 0.75rem);
        padding: 1.2rem 1rem;
    }
}

/* --- DIFFICULTY & MODE --- */
.difficulty-options,
.mode-options {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
}

.difficulty-btn,
.mode-btn {
    flex: 1;
    min-width: 260px;
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.difficulty-btn:hover,
.mode-btn:hover {
    background: rgba(255, 59, 59, 0.1);
    border-color: var(--accent-red);
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

/* Fix for Category Screen Top Spacing */
#category-screen {
    padding-top: 6rem !important;
    /* Reduced from 10rem to move content up */
    justify-content: flex-start;
    padding-bottom: 2rem;
}

.difficulty-btn span {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-main);
}

.difficulty-btn small,
.mode-btn small {
    font-size: 0.85rem;
    color: var(--text-dim);
    font-weight: 300;
}

/* --- GAME UI --- */
#timer-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-bottom: 2rem;
    overflow: hidden;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.5);
}

#timer-progress {
    height: 100%;
    background: linear-gradient(90deg, #ff3b3b, #ff8800);
    box-shadow: 0 0 20px rgba(255, 59, 59, 0.6);
    border-radius: 10px;
    transition: width 0.1s linear;
}

.badge {
    background: rgba(255, 59, 59, 0.15);
    color: #ff6b6b;
    border: 1px solid rgba(255, 59, 59, 0.3);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.8rem;
    letter-spacing: 2px;
    font-weight: 700;
    text-transform: uppercase;
    backdrop-filter: blur(5px);
}

.question-card {
    margin-bottom: 2.5rem;
    width: 100%;
    min-height: 200px;
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    animation: slideUpFade 0.6s ease-out;
}

#question-text {
    font-size: 1.6rem;
    line-height: 1.6;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    max-width: 900px;
}

.options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    width: 100%;
}

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

.option-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    padding: 1.5rem;
    text-align: left;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-dim);
}

/* --- RESULT --- */
#final-score {
    font-size: 7rem;
    font-family: var(--font-heading);
    color: var(--accent-gold);
    text-shadow: 0 0 40px rgba(255, 200, 0, 0.3);
    margin: 1rem 0;
    line-height: 1;
}

/* --- SPECIAL GUNDEM BUTTON --- */
.special-category-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.special-gundem-btn {
    width: 100%;
    max-width: 500px;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.5)), url('../../assets/images/Gundem.jpg');
    background-size: cover;
    background-position: center;
    border: 2px solid var(--accent-gold);
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.3), inset 0 0 20px rgba(255, 215, 0, 0.1);
    position: relative;
    overflow: hidden;
    animation: goldPulse 3s infinite ease-in-out;
    transition: all 0.3s ease;
}

.special-gundem-btn .icon {
    font-size: 3.5rem;
}

.special-gundem-btn .cat-name {
    font-size: 1.5rem;
    color: var(--accent-gold);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
    letter-spacing: 4px;
}

.special-gundem-btn:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 0 50px rgba(255, 215, 0, 0.6), inset 0 0 30px rgba(255, 215, 0, 0.2);
    border-color: #fff;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.3), rgba(255, 140, 0, 0.4));
}

/* --- LUCKY WHEEL BUTTON --- */
.special-wheel-btn {
    width: 100%;
    max-width: 500px;
    padding: 2rem;
    background: linear-gradient(45deg, #ff00cc, #333399, #ffcc00);
    background-size: 200% 200%;
    border: 3px solid #fff;
    border-radius: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    animation: gradientShift 3s ease infinite;
    box-shadow: 0 0 20px rgba(255, 0, 204, 0.6), inset 0 0 20px rgba(255, 255, 255, 0.2);
    transition: transform 0.3s;
}

.special-wheel-btn .icon {
    font-size: 3rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.8));
    animation: spinIcon 5s linear infinite;
}

.special-wheel-btn .cat-name {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 900;
    color: #fff;
    text-transform: uppercase;
    text-shadow: 0 0 10px #ff00cc, 0 0 20px #000;
    letter-spacing: 3px;
}

.special-wheel-btn .glow-effect {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 60%);
    animation: rotateGlow 4s linear infinite;
    pointer-events: none;
}

.special-wheel-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 40px rgba(255, 204, 0, 0.8);
    border-color: #ffd700;
}

.shine-effect {
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.4), transparent);
    transform: skewX(-25deg);
    animation: shineMove 3s infinite;
}

/* --- CATEGORY SPECIFIC HOVERS & STYLES --- */

/* Tarih - Sepya/Altın + Resim */
.category-btn[data-category="tarih"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/tarih.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(212, 175, 55, 0.5);
}

.category-btn[data-category="tarih"]:hover {
    border-color: #d4af37;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/tarih.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="tarih"]:hover .icon {
    filter: drop-shadow(0 0 15px #d4af37);
}

/* Coğrafya - Mavi/Turkuaz + Resim */
.category-btn[data-category="cografya"] {
    background: linear-gradient(rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0.7)), url('../../assets/images/coğrafya.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(0, 229, 255, 0.5);
}

.category-btn[data-category="cografya"]:hover {
    border-color: #00e5ff;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/coğrafya.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(0, 229, 255, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="cografya"]:hover .icon {
    filter: drop-shadow(0 0 15px #00e5ff);
}

/* Psikoloji - Mor + Resim */
.category-btn[data-category="psikoloji"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/pisikoloji.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(170, 0, 255, 0.5);
}

.category-btn[data-category="psikoloji"]:hover {
    border-color: #aa00ff;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/pisikoloji.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(170, 0, 255, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="psikoloji"]:hover .icon {
    filter: drop-shadow(0 0 15px #aa00ff);
}

/* Sosyoloji - Turuncu + Resim */
.category-btn[data-category="sosyoloji"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/sosyoloji.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(255, 109, 0, 0.5);
}

.category-btn[data-category="sosyoloji"]:hover {
    border-color: #ff6d00;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/sosyoloji.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(255, 109, 0, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="sosyoloji"]:hover .icon {
    filter: drop-shadow(0 0 15px #ff6d00);
}

/* Edebiyat - Gül Kurusu/Pembe + Resim */
.category-btn[data-category="edebiyat"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/edebiyat.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(255, 64, 129, 0.5);
}

.category-btn[data-category="edebiyat"]:hover {
    border-color: #ff4081;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/edebiyat.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(255, 64, 129, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="edebiyat"]:hover .icon {
    filter: drop-shadow(0 0 15px #ff4081);
}

/* Fen Bilimleri - Yeşil + Resim */
.category-btn[data-category="fen_bilimleri"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/fen bilgisi.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(0, 255, 0, 0.5);
}

.category-btn[data-category="fen_bilimleri"]:hover {
    border-color: #00ff00;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/fen bilgisi.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(0, 255, 0, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="fen_bilimleri"]:hover .icon {
    filter: drop-shadow(0 0 15px #00ff00);
}

/* Siyaset - Koyu Kırmızı/Bordo + Resim */
.category-btn[data-category="siyaset"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/siyaset.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(183, 28, 28, 0.5);
}

.category-btn[data-category="siyaset"]:hover {
    border-color: #b71c1c;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/siyaset.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(183, 28, 28, 0.3);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="siyaset"]:hover .icon {
    filter: drop-shadow(0 0 15px #ff0000);
}

/* Karışık - Renkli + Resim */
.category-btn[data-category="karisik"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/karışık.png');
    background-size: cover;
    background-position: center;
    border-image: linear-gradient(45deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f) 1;
}

.category-btn[data-category="karisik"]:hover {
    border-image: linear-gradient(45deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f) 1;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/karışık.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.2);
    animation: rainbowBorder 2s linear infinite;
    transform: translateY(-5px) scale(1.02);
}

/* Din - Turkuaz/Yeşil + Resim */
.category-btn[data-category="din"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/din.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(26, 188, 156, 0.5);
}

.category-btn[data-category="din"]:hover {
    border-color: #1abc9c;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/din.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(26, 188, 156, 0.2);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="din"]:hover .icon {
    filter: drop-shadow(0 0 15px #1abc9c);
}

/* Sinema - Kırmızı/Bordo (Netflix Style) + Resim */
.category-btn[data-category="sinema"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/sinama.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(229, 9, 20, 0.5);
}

.category-btn[data-category="sinema"]:hover {
    border-color: #e50914;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/sinama.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(229, 9, 20, 0.3);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="sinema"]:hover .icon {
    filter: drop-shadow(0 0 15px #e50914);
}

/* Spor - Mavi + Resim */
.category-btn[data-category="spor"] {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../../assets/images/spor.png');
    background-size: cover;
    background-position: center;
    border-color: rgba(33, 150, 243, 0.5);
}

.category-btn[data-category="spor"]:hover {
    border-color: #2196f3;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2)), url('../../assets/images/spor.png');
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(33, 150, 243, 0.3);
    transform: translateY(-5px) scale(1.02);
}

.category-btn[data-category="spor"]:hover .icon {
    filter: drop-shadow(0 0 15px #2196f3);
}

/* --- LOBBY SCREEN --- */
/* Modernized Lobby Styles */
.lobby-selection-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    width: 100%;
    max-width: 700px;
    margin: 3rem auto;
}

.lobby-type-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-align: center;
    color: white;
    backdrop-filter: blur(15px);
    position: relative;
    overflow: hidden;
}

.lobby-type-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.lobby-type-card.create:hover {
    border-color: #00f2fe;
    box-shadow: 0 20px 40px rgba(0, 242, 254, 0.2);
}

.lobby-type-card.join:hover {
    border-color: #ffd83b;
    box-shadow: 0 20px 40px rgba(255, 216, 59, 0.2);
}

.lobby-type-card .icon {
    font-size: 4rem;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

.lobby-type-card.create .icon {
    color: #00f2fe;
}

.lobby-type-card.join .icon {
    color: #ffd83b;
}

.lobby-type-card .title {
    font-weight: 900;
    font-size: 1.5rem;
    letter-spacing: 2px;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

.lobby-type-card .desc {
    font-size: 0.9rem;
    opacity: 0.8;
    line-height: 1.4;
}

.lobby-sub-panel {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    animation: panelSlide 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.lobby-options-grid {
    display: grid;
    gap: 1.2rem;
}

.panel-btns {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1rem;
}

.mini {
    padding: 0.6rem 1.2rem;
    font-size: 0.8rem;
}

/* Enhanced Selection Indicators */
.selection-indicators {
    position: absolute;
    top: -10px;
    right: -10px;
    display: flex;
    gap: 5px;
    pointer-events: none;
}

.selection-dot {
    width: 25px;
    height: 25px;
    background: var(--accent-gold);
    border: 2px solid #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 900;
    color: #000;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    animation: indicatorEntrance 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.hidden {
    display: none !important;
}

#room-id-display {
    background: var(--accent-gold);
    color: black;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-weight: 800;
    font-size: 0.9rem;
    margin-left: 5px;
}

/* --- WAITING ROOM STYLES --- */
.waiting-room-container {
    max-width: 500px;
    width: 100%;
    padding: 2rem;
    text-align: center;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.room-id-display {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: rgba(255, 215, 0, 0.1);
    border: 2px solid var(--accent-gold);
    border-radius: 16px;
    flex-shrink: 0;
}

.players-list {
    margin: 1.5rem 0;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    max-height: 30vh;
    overflow-y: auto;
    flex-grow: 1;
}

.players-list p {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
}

.players-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.players-list li {
    padding: 0.5rem;
    color: #fff;
    font-size: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.players-list li:last-child {
    border-bottom: none;
}

.waiting-hint {
    font-size: 0.85rem;
    color: var(--text-dim);
    margin: 1rem 0;
}

#start-multiplayer-btn {
    margin-top: 1rem;
    width: 100%;
}

#start-multiplayer-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Seçilen Cevap Stili (Sonuç Bekleniyor) */
.option-btn.selected {
    background: linear-gradient(135deg, #ffd700, #ff8c00);
    color: #000;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
    transform: scale(0.98);
}

.option-btn.selected .opt-badge {
    background: #000;
    color: #ffd700;
}

/* --- QUICK MUSIC CONTROL WIDGET --- */
.quick-music-controls {
    position: relative;
    z-index: 1000 !important;
    /* Force on top */
}

.mini-control-btn {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-dim);
    border-radius: 20px;
    padding: 8px 16px;
    /* Slightly larger hit area */
    font-size: 0.85rem;
    cursor: pointer !important;
    /* Force pointer */
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    backdrop-filter: blur(5px);
    pointer-events: auto;
    /* Ensure clickable */
    user-select: none;
}

.mini-control-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--accent-gold);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.mini-control-btn:active {
    transform: translateY(0);
}

.mini-control-btn.arrow-btn {
    padding: 8px 12px;
    border-radius: 50%;
    justify-content: center;
}

.music-dropdown-wrapper {
    position: relative;
    display: inline-block;
}

.music-list-dropdown {
    position: absolute;
    top: 110%;
    /* Push down slightly */
    left: 50%;
    transform: translateX(-50%);
    background: rgba(10, 10, 10, 0.98);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 12px;
    padding: 8px;
    width: 220px;
    max-height: 250px;
    /* Scrollable height */
    overflow-y: auto;
    z-index: 2000 !important;
    /* Higher than controls */
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
    display: flex;
    flex-direction: column;
    gap: 4px;
    /* Custom Scrollbar */
    scrollbar-width: thin;
    scrollbar-color: var(--accent-gold) rgba(255, 255, 255, 0.1);
}

.music-list-dropdown::-webkit-scrollbar {
    width: 6px;
}

.music-list-dropdown::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.music-list-dropdown::-webkit-scrollbar-thumb {
    background-color: var(--accent-gold);
    border-radius: 10px;
}

.music-list-dropdown.hidden {
    display: none;
    pointer-events: none;
}

.music-item {
    padding: 10px 14px;
    font-size: 0.9rem;
    color: #bbb;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.music-item:last-child {
    border-bottom: none;
}

.music-item:hover {
    background: rgba(255, 215, 0, 0.15);
    color: var(--accent-gold);
    padding-left: 18px;
    /* Slide effect */
}

/* Ensure Online Button is pill shaped */
#online-btn {
    border-radius: 50px !important;
}

/* --- WHEEL SCREEN --- */
.wheel-container {
    position: relative;
    width: 500px;
    height: 500px;
    margin: 2rem auto;
    border-radius: 50%;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
}

#wheel-canvas {
    border-radius: 50%;
    transition: transform 4s cubic-bezier(0.17, 0.67, 0.12, 0.99);
}

.wheel-pointer {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    color: #fff;
    text-shadow: 0 0 10px #000;
    z-index: 10;
    filter: drop-shadow(0 5px 5px rgba(0, 0, 0, 0.5));
}

.wheel-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 110px;
    height: 110px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    z-index: 5;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px;
    backdrop-filter: blur(5px);
}

#spin-btn {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: none;
    background: radial-gradient(circle at 30% 30%, #ff0055, #d50000, #ff9100);
    background-size: 200% 200%;
    color: #fff;
    font-weight: 900;
    font-size: 1.3rem;
    cursor: pointer;
    box-shadow:
        0 0 10px rgba(255, 0, 85, 0.8),
        0 0 30px rgba(255, 145, 0, 0.6),
        inset 0 0 15px rgba(255, 255, 255, 0.4);
    transition: all 0.2s ease-out;
    text-transform: uppercase;
    animation: spinGradient 2s infinite alternate, pulseSpinBtn 1.5s infinite;
    z-index: 20;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 1px;
}

#spin-btn:hover {
    transform: scale(1.15) rotate(180deg);
    box-shadow:
        0 0 50px rgba(255, 0, 85, 1),
        0 0 30px rgba(255, 215, 0, 0.8),
        inset 0 0 20px rgba(255, 255, 255, 0.6);
    background: radial-gradient(circle at 50% 50%, #ff00cc, #ff3333, #ffcc00);
    font-size: 1.4rem;
}

#spin-btn:active {
    transform: translateY(0);
}

#spin-btn:disabled {
    background: #333;
    box-shadow: none;
    animation: none;
    cursor: not-allowed;
    transform: none;
    color: #777;
}

.wheel-stats {
    text-align: center;
    font-size: 1.5rem;
    margin-top: 1rem;
    font-weight: bold;
}

#wheel-results-container {
    margin-top: 2rem;
    width: 100%;
    max-width: 600px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 16px;
    padding: 1rem;
    max-height: 200px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-gold) rgba(0, 0, 0, 0.3);
}

#wheel-results-container h3 {
    color: var(--text-dim);
    font-size: 1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
}

#collected-questions-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    justify-content: center;
}

.collected-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.9rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: #fff;
    text-shadow: 0 1px 2px #000;
}

/* --- SIDE BY SIDE LAYOUT --- */
.wheel-content-wrapper {
    display: flex;
    flex-direction: row;
    /* Enforce Row */
    align-items: flex-start;
    /* Align top */
    justify-content: center;
    gap: 2rem;
    flex-wrap: nowrap;
    /* Don't wrap on desktop */
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 2rem;
}

.wheel-section-left {
    flex: 0 0 500px;
    /* Fixed width for wheel */
    display: flex;
    justify-content: center;
}

.wheel-section-right {
    flex: 1;
    /* Take remaining space */
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 300px;
    max-width: 500px;
    /* Restrict width */
}

/* Adjust existing wheel styles for context */
.wheel-container {
    margin: 0;
}

.wheel-stats {
    margin: 0 0 2rem 0;
}

#wheel-results-container {
    width: 100%;
    height: 300px;
    max-height: 400px;
    margin-top: 0;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

#wheel-actions {
    margin-top: 2rem;
    width: 100%;
    display: flex;
    justify-content: center;
}

#wheel-actions.hidden {
    display: none;
}

#spin-result-text {
    color: var(--accent-gold);
    min-height: 2rem;
    margin-top: 0.5rem;
}

/* Mobile Responsive Fix */
@media (max-width: 1000px) {
    .wheel-content-wrapper {
        flex-direction: column;
        flex-wrap: wrap;
        gap: 2rem;
        padding-top: 0;
    }

    .wheel-section-left {
        flex: 0 0 auto;
        /* Allow shrink */
    }

    .wheel-container {
        /* Scale down wheel slightly on mobile */
        transform: scale(0.8);
    }

    #wheel-results-container {
        width: 90%;
    }
}

@media (max-width: 600px) {

    .wheel-container,
    #wheel-canvas {
        width: 300px;
        height: 300px;
    }
}


/* --- BALANCED COMPACT MAIN SCREEN --- */
#category-screen {
    padding-top: 2rem !important;
    /* Move up, but not too high */
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    /* Removed fixed 100vh to allow natural flow if needed, but try to fit */
    overflow-y: auto;
}

/* Shrink Title Moderately */
h1.glitch-title {
    font-size: 2.5rem !important;
    margin-bottom: 1rem !important;
    margin-top: 0 !important;
}

.special-section-title {
    font-size: 1rem !important;
    margin: 0.5rem 0 1rem 0 !important;
}

/* Tighter Grid */
.featured-grid {
    gap: 15px !important;
    margin-bottom: 1.5rem !important;
    max-width: 900px;
}

/* Buttons: Restore Vertical Layout but Smaller */
.special-wheel-btn,
.special-gundem-btn,
.special-category-container button {
    padding: 1.25rem !important;
    /* Slightly larger */
    min-height: 120px !important;
    /* Slightly taller */
    flex-direction: column !important;
    /* Restore vertical stack */
    justify-content: center !important;
    gap: 10px !important;
}

.special-wheel-btn .icon,
.special-gundem-btn .icon,
.special-category-container .icon {
    font-size: 2rem !important;
    /* Slightly larger icon */
    margin-bottom: 0 !important;
}

.special-wheel-btn .cat-name,
.special-gundem-btn .cat-name,
.special-category-container .cat-name {
    font-size: 1.1rem !important;
    /* Slightly larger text */
    white-space: normal !important;
    /* Allow wrapping */
}

/* Compact Main Actions */
.main-actions-container {
    margin-top: 1rem !important;
    gap: 1.5rem !important;
    padding-bottom: 3rem;
}

.toggle-cats-btn,
#online-btn {
    padding: 1.2rem 1.5rem !important;
    /* Slightly taller */
    min-height: 65px !important;
    font-size: 1.1rem !important;
    flex: 1 !important;
}

/* Adjust Music Controls spacer */
.quick-music-controls {
    margin-bottom: 0.5rem !important;
}