/* Retro Video Game Theme */
body {
    background: #111;
    color: #ffe600;
    font-family: 'Press Start 2P', 'VT323', monospace, 'Courier New', Courier, monospace;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

a {
    color: yellow;
}
a:visited {
    color: gold;
}

header {
    background: #000000;
    border-bottom: 4px solid #ffe600;
    text-align: center;
    padding: 2rem 0 1rem 0;
    box-shadow: 0 4px 0 #333;
}

header h1 a {
    color: #ffe600;
    text-decoration: none;
    font-size: 2.5rem;
    letter-spacing: 0.1em;
    text-shadow: 2px 2px 0 #333, 4px 4px 0 #00f;
    transition: color 0.2s;
}

header h1 a:hover {
    color: #00f;
}

.container {
    max-width: 600px;
    margin: 2rem auto;
}

p {
    max-width: 600px;
    margin: 2rem auto;
    background: #222;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 0 #333;
    font-size: 1.1rem;
    line-height: 1.7;
    border: 2px dashed #ffe600;
}

footer {
    text-align: center;
    padding: 1rem 0;
    background: #222;
    border-top: 4px solid #ffe600;
    color: #ffe600;
    font-size: 1rem;
    box-shadow: 0 -4px 0 #333;
    /* position: fixed; */
    width: 100%;
    bottom: 0;
}

@media (max-width: 600px) {
    header h1 a {
        font-size: 1.5rem;
    }
    p {
        font-size: 1rem;
        padding: 1rem;
    }
}

/* Optional: Add a pixelated border around the main content */
body::before {
    content: "";
    display: block;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
    /* border: 12px solid #00f; */
    border-radius: 0;
    z-index: 0;
    opacity: 0.2;
}

.collected-item {
    display: inline-block;
    width: 40px;
    height: 40px;
    margin: 5px;
}
.collected-item.power-pellet-1,
.collected-item.power-pellet-2,
.collected-item.power-pellet-3 {
    background-color: white;
    border-radius: 50%;
}
.collected-item.cherry-1 {
    background-image: url('images/PM_Cherry.webp');
    background-size: cover;
}
.strawberry-1 {
    background-image: url('images/PM_Strawberry.webp');
    background-size: cover;
}
.collected-item.orange-1 {
    background-image: url('images/PM_Orange.png');
    background-size: cover;
}
.collected-item.apple-1 {
    background-image: url('images/PM_Apple.png');
    background-size: cover;
}
.collected-item.melon-1 {
    background-image: url('images/PM_Melon.webp');
    background-size: cover;
}
.collected-item.galaxian-1 {
    background-image: url('images/PM_Galaxian.webp');
    background-size: cover;
}
.collected-item.bell-1 {
    background-image: url('images/PM_Bell.webp');
    background-size: cover;
}
.collected-item.key-1 {
    background-image: url('images/PM_Key.webp');
    background-size: cover;
}
.collected-item.ghost-blinky {
    background-image: url('images/Blinky8bit.webp');
    background-size: cover;
}
.collected-item.ghost-pinky {
    background-image: url('images/Pinky8bit.webp');
    background-size: cover;
}
.collected-item.ghost-inky {
    background-image: url('images/Inky8bit.webp');
    background-size: cover;
}
.collected-item.ghost-clyde {
    background-image: url('images/Clyde8bit.webp');
    background-size: cover;
}

#collect-item {
    max-width: 600px;
    margin: 2rem auto;
    text-align: center;
    margin-top: 1rem;
}

#scoreboard {
    max-width: 600px;
    margin: 2rem auto;
    background: #222;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 0 #333;
    font-size: 1.1rem;
    line-height: 1.7;
    border: 2px dashed #ffe600;
}

#collection {

}
#final-score {
    /* line-height: 3rem; */
    font-size: 3rem;
    text-align: center;
    color: rgb(0, 187, 255);
    text-shadow: 2px 2px 0 #333, 4px 4px 0 rgb(255, 251, 0);
}



#scoreboard #collection {
    /* margin-top: 1rem; */
    text-align: center;
}
ul.collection-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}
ul.collection-list li {
    margin: 0.2rem;
    --item-index: 0; /* Default index */
}

@keyframes appear {
    to {
        opacity: 1;
    }
}

#scoreboard #collection h3#you-collected-heading {
    display: none;
}

h2#congratulations-heading {
    /* margin-top: 1rem; */
    /* display: none; */
    text-align: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #ffe600;
    text-shadow: 2px 2px 0 #333, 4px
}
#scoreboard h2#final-score-heading {
    /* margin-top: 1rem; */
    display: none;
}


#scoreboard #collection ul li {
    opacity: 0;
}
#scoreboard #collection ul li.animate-on {
    animation: appear 0.5s forwards;
    animation-delay: calc(var(--item-index, 0) * 0.25s);
    opacity: 0;
}

#scoreboard h2 {
    text-align: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #ffe600;
    text-shadow: 2px 2px 0 #333, 4px 4px 0 #00f;
}

#scoreboard #initials {
    width: 50%;
    padding: 0.5rem;
    font-size: 1.2rem;
    border: 2px solid #ffe600;
    border-radius: 8px;
    background: #111;
    color: #ffe600;
    box-shadow: 0 4px 0 #333;
    text-transform: uppercase;
}

#submit-score {
    width: 50%;
    padding: 0.5rem;
    font-size: 1.2rem;
    border: 2px solid #00f;
    border-radius: 8px;
    background: rgb(234, 255, 0);
    color: #000000;
    /* box-shadow: 0 4px 0 #8e8e8e; */
    cursor: pointer;
    margin-top: 0.5rem;
    text-transform: uppercase;
    transition: background 0.2s, border-color 0.2s;
}

#initials-entry {
    text-align: center;
    margin-top: 1rem;
}

h2#initials-heading {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #ffe600;
    text-shadow: 2px 2px 0 #333, 4px 4px 0 #00f;
}