/* Custom Scrollbar for nicer UI */
* {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* SVG Map Styles */
#kerala-map {
    filter: drop-shadow(0 0 20px rgba(16, 185, 129, 0.1));
}

.district-path {
    fill: #334155;
    /* slate-700 */
    stroke: #94a3b8;
    /* slate-400 */
    stroke-width: 1px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.district-path:hover {
    fill: #475569;
    /* slate-600 */
    stroke: #e2e8f0;
    /* slate-200 */
    stroke-width: 2px;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.2));
    transform: translateY(-2px);
    z-index: 10;
}

/* Game States */
.district-path.correct {
    fill: #10b981 !important;
    /* emerald-500 */
    stroke: #059669 !important;
    /* emerald-600 */
    animation: pulse-green 1s infinite;
}

.district-path.incorrect {
    fill: #ef4444 !important;
    /* red-500 */
    stroke: #b91c1c !important;
    /* red-700 */
    animation: shake 0.5s cubic-bezier(.36, .07, .19, .97) both;
}

/* Disable pointer events on already guessed or inactive path if needed */
.district-path.disabled {
    pointer-events: none;
    /* Opacity removed to prevent overlap bleed-through */
}

@keyframes pulse-green {
    0% {
        filter: drop-shadow(0 0 0 rgba(16, 185, 129, 0.4));
    }

    70% {
        filter: drop-shadow(0 0 10px rgba(16, 185, 129, 0));
    }

    100% {
        filter: drop-shadow(0 0 0 rgba(16, 185, 129, 0));
    }
}

@keyframes shake {

    10%,
    90% {
        transform: translate3d(-1px, 0, 0);
    }

    20%,
    80% {
        transform: translate3d(2px, 0, 0);
    }

    30%,
    50%,
    70% {
        transform: translate3d(-4px, 0, 0);
    }

    40%,
    60% {
        transform: translate3d(4px, 0, 0);
    }
}
