/* anta-latin-400-normal */
@font-face {
    font-family: 'Anta';
    font-style: normal;
    font-display: swap;
    font-weight: 400;
    src: url(https://cdn.jsdelivr.net/fontsource/fonts/anta@latest/latin-400-normal.woff2) format('woff2'), url(https://cdn.jsdelivr.net/fontsource/fonts/anta@latest/latin-400-normal.woff) format('woff');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Anta";
}

body {
    margin: 0;
    background: black;
    font-family: 'Anta', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    width: 100vw;

    /*glow effect*/
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.8));
}

#overhead-UI {
    display: none;
    font-size: 1.5rem;
    /* Adjust this value as needed */
    padding: 1rem;
}

#overhead-UI span {
    margin: 0 0.5rem;
}

#gmOverEl {
    display: none;
    font-size: 1.5rem;
}

#gmOverEl h1 {
    font-size: 3rem;
}

#mainMenuEl {
    display: flex;
    font-size: 1.5rem;
}

.bttn-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    height: 100px;
}

.start-bttn {
    background-color: #2563eb;
    color: white;
    border-radius: 30px;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    padding: 10px 30px 10px 30px;
}

.start-bttn:hover {
    border-radius: 5px;
    background-color: #2563eb;
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 25px rgba(78, 80, 91, 0.786);
}

.game-title {
    font-style: normal;
    font-weight: 200;
    font-size: 36px;
    color: white;
    text-shadow: 3px 3px 0px black;
    margin-bottom: 3px;
    text-align: center;
}

.made-by {
    font-style: normal;
    font-size: 20px;
    color: white;
    margin-bottom: 8px;
    text-align: center;
}

.instructions-panel {
    background: white;
    border-radius: 8px;
    padding: 30px;
    max-width: 900px;
    width: 90%;
    height: 70%;
    margin-bottom: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.instructions-title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: center;
    color: #333;
}

.instructions-text {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    text-align: center;
}

.controls-list {
    margin: 15px 0;
    text-align: left;
    display: inline-block;
}

.controls-list li {
    margin: 5px 0;
    list-style: none;
    position: relative;
    padding-left: 20px;
}

.controls-list li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #666;
}

.highlight {
    font-weight: bold;
    color: #2563eb;
}

canvas {
    border: 2px solid #333;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    .game-title {
        font-size: 36px;
    }

    .instructions-panel {
        padding: 20px;
    }

    .instructions-title {
        font-size: 38px;
    }

    .instructions-text {
        font-size: 14px;
    }
}

/* Animations */
.ui-container #scoreEl,
.ui-container #highscoreEl,
.ui-container #segmentEl {
    transform-origin: center;
    display: inline-block;
    will-change: transform;
}

.ui-container .score-pop {
    animation: scorePop 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55) !important;
}

.ui-container .score-shrink {
    animation: scoreShrink 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55) !important;
}

.ui-container .highscore-pop {
    animation: highscorePop 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.ui-container .segments-pop {
    animation: segmentsPop 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes scorePop {
    0% {
        transform: scale(1) rotate(0deg);
    }

    50% {
        transform: scale(1.3) rotate(5deg);
    }

    100% {
        transform: scale(1) rotate(0deg);
    }
}

@keyframes scoreShrink {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(0.8);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes highscorePop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.4);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes segmentsPop {
    0% {
        transform: scale(1) rotate(0deg);
    }

    50% {
        transform: scale(1.3) rotate(-3deg);
    }

    100% {
        transform: scale(1) rotate(0deg);
    }
}

.cheeky-msg {
    margin: 15px 0;
    color: #333;
    font-size: 18px;
}

.fuzzy-overlay {
    position: absolute;
    inset: -200%;
    z-index: 10;
    background-image: url(images/whitenoise.jpg);
    opacity: 5%;
    animation: shift 0.2s linear infinite both;
    pointer-events: none;
    overflow: hidden;
}

@keyframes shift {
    0% {
        transform: translateX(10%) translateY(10%);
    }

    100% {
        transform: translateX(-10%) translateY(-10%);
    }
}


/* CRT curvature effect */
.crt-curvature {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 20;
    background: radial-gradient(ellipse at center,
            rgba(0, 0, 0, 0) 0%,
            rgba(0, 0, 0, 0) 60%,
            rgba(0, 0, 0, 0.08) 70%,
            rgba(0, 0, 0, 0.08) 100%);
    border-radius: 2px;
    box-shadow:
        inset 0 0 15px rgba(0, 0, 0, 0.3),
        0 0 15px rgba(0, 0, 0, 0.3);
}

.crt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 30;
    background:
        linear-gradient(rgba(18, 16, 16, 0) 50%,
            rgba(0, 0, 0, 0.25) 50%);
    background-size: 100% 4px;
    opacity: 0.6;
}

.crt-border {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 40;
    border: 15px solid #222;
    border-radius: 5px;
    box-sizing: border-box;
    box-shadow:
        inset 0 0 10px rgba(255, 255, 255, 0.1),
        0 0 20px rgba(0, 0, 0, 0.8);
}


/* Horizontal stretch effect */
.crt-horizontal-curve {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 15;
    background: radial-gradient(ellipse 100% 50% at center,
            rgba(0, 0, 0, 0) 0%,
            rgba(0, 0, 0, 0) 85%,
            rgba(0, 0, 0, 0.05) 90%,
            rgba(0, 0, 0, 0.05) 100%);
}