* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-drag: none; /* Prevent dragging */
    touch-action: none; /* Disable all browser touch actions */
}

body, html {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Outfit', sans-serif;
    background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
    color: #fff;
    touch-action: none; /* Prevent browser scrolling/zooming */
}

#app {
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 1;
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out;
}

.screen.active {
    opacity: 1;
    pointer-events: auto;
}

/* CHOOSER SCREEN */
#chooser-screen {
    flex-direction: column;
}

#instruction {
    position: absolute;
    top: 20%;
    font-size: 1.5rem;
    font-weight: 300;
    text-align: center;
    padding: 0 20px;
    z-index: 10;
    opacity: 0.7;
    transition: opacity 0.3s;
    pointer-events: none;
}

#touch-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.touch-point {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    background: currentColor;
    box-shadow: 0 0 20px currentColor;
    pointer-events: none;
    z-index: 10;
}

.touch-point::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 4px solid currentColor;
    transform: translate(-50%, -50%);
    opacity: 0;
}

.touch-point.loading::after {
    animation: ripple 1.2s ease-out infinite;
}

.touch-point.winner {
    background: transparent !important;
    border: 28px solid #000;
    box-shadow: none !important;
    animation: winnerPulse 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    z-index: 100;
}

.touch-point.winner::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 12px solid #000;
}

.touch-point.winner::after {
    display: none;
}

.touch-point.loser {
    animation: shrinkOut 0.3s ease-in forwards;
}

@keyframes popIn {
    0% { transform: translate(-50%, -50%) scale(0); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

@keyframes ripple {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
    100% { transform: translate(-50%, -50%) scale(2.5); opacity: 0; }
}

@keyframes shrinkOut {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
}

@keyframes winnerPulse {
    0% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.3); }
    100% { transform: translate(-50%, -50%) scale(1.15); box-shadow: 0 0 40px currentColor; }
}

/* QUESTION SCREEN */
.glass-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    transform: translateY(30px);
    opacity: 0;
    animation: slideUp 0.6s ease-out forwards;
}

.category-badge {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

#question-text {
    font-size: 1.8rem;
    font-weight: 400;
    line-height: 1.4;
    margin-bottom: 40px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: opacity 0.2s ease-in-out;
}

.buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.btn {
    padding: 16px 24px;
    border-radius: 12px;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    outline: none;
}

.btn:active {
    transform: scale(0.95);
}

.btn.primary {
    background: #fff;
    color: #1a1a2e;
    box-shadow: 0 4px 15px rgba(255,255,255,0.3);
}

.btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

@keyframes slideUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* CATEGORY SCREEN STYLES */
.category-card {
    display: flex;
    flex-direction: column;
    max-height: 80vh;
}

.category-card h2 {
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.scrollable-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 5px 0;
    overflow: visible;
}

.cat-btn {
    text-align: center;
    width: 100%;
    margin-bottom: 0;
    padding: 12px 8px;
    font-size: 0.85rem;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.3;
}
