@import url('https://fonts.googleapis.com/css2?family=Comic+Neue:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

/* ==========================================================================
   1. Global Styles & Layout
   ========================================================================== */
html,
body {
    overflow: hidden;
    margin: 0;
    padding: 0;
}

body {
    background-color: black;
    height: 100%;
    overflow: hidden;
    color: white;
    padding: 10%;
    border: #ff838300 solid 10px;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    height: 100vh;
}

h1,
p {
    font-family: 'Comic Neue', cursive;
    font-weight: 700;
    color: white;
    background-color: rgb(0, 0, 0);
    text-align: center;
    padding: 20px;
}

h1 {
    font-size: 140px;
    margin-bottom: 10px;
}

p {
    font-size: 24px;
    margin-top: 0;
    max-width: 600px;
    line-height: 1.6;
}

.abouttext {
    position: absolute;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%); /* sourced from ChatGPT */
    text-align: center;
    padding: 20px;
}

img {
    padding: 20px;
}

.hidden {
    visibility: hidden;
}

/* ==========================================================================
   3. Backgrounds for Different Pages/Sections
   ========================================================================== */
.index {
    background: url('../img/blink.gif') no-repeat center center fixed;
    background-size: cover;
}

.age_6 {
    background-color: #FF8383;
}

.age_20 {
    background: url('../img/g.gif') no-repeat center center fixed;
    background-size: cover;
}

.age_40 {
    background: url('../img/wall1.png') no-repeat center center fixed;
    background-size: cover;
}

.game_option,
.mini_games {
    background: url('../img/screen.gif') no-repeat center center fixed;
    background-size: cover;
}

.food_drop {
    background: url('../img/picnicw.png') no-repeat center center fixed;
    background-size: cover;
}

.tic_tac_pou {
    background: url('../img/grid.png') no-repeat center center fixed;
    background-size: cover;
}

.skyfall {
    background: url('../img/skyfall.gif') no-repeat center center fixed;
    background-size: cover;
}

/* ==========================================================================
   4. Navigation 
   ========================================================================== */
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
}

.left-arrow:hover {
    content: url('../img/lefthower.png');
}

.right-arrow:hover {
    content: url('../img/righthower.png');
}

/* ==========================================================================
   5. Specific Elements: Lamp, Pou, Games & Mini-Elements
   ========================================================================== */
/* Lamp */
.lamp {
    position: absolute;
    bottom: -10%;
    right: -5%;
}

.lamp:hover {
    content: url('../img/lamphover.png');
}

/* Pou & Related Elements */
.pou {
    position: absolute;
    bottom: 0;
    margin-bottom: 50px;
    padding: 0;
}

.pou:hover {
    content: url('../img/pou40_hower.png');
}

.pougames {
    position: absolute;
    bottom: 0;
    margin-bottom: 50px;
    padding: 0;
}

.pougames:hover {
    content: url('../img/pougames_hower.png');
}

/* Mini Pou Variants */
.minipou,
.miniminipou {
    position: absolute;
    bottom: 0;
    margin-bottom: 50px;
    padding: 0;
    z-index: 10;
}

.minipou:hover {
    content: url('../img/sing.gif');
}

.miniminipou:hover {
    content: url('../img/hi.png');
}

#skyfall_pou {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* sourced from ChatGPT */
    cursor: grab;
}

/* Games */
.games {
    position: fixed;
    bottom: 0;
    right: 0;
    margin: 25px;
}

.game {
    transition: transform 0.3s ease;
}

.game:hover {
    transform: scale(1.05);
}

.game a img:first-of-type {
    border-radius: 20px; /* sourced from ChatGPT */
}

/* Game Container & Items */
.game-container {
    position: absolute;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%); /* sourced from ChatGPT */
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
    width: 90vw;
    max-width: 1400px;
    height: auto;
    min-height: 500px;
    padding: 30px;
    text-align: center;
}

.game {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-width: 300px;
}

.game a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.game img {
    display: block;
    max-width: 100%;
    padding: 5px;
}

/* Game-specific positioning */
.g1 {
    position: absolute;
    width: 200px;
    height: auto;
    top: 5%;
    left: 75%;
}

.g2 {
    position: absolute;
    width: 200px;
    height: auto;
    top: 20%;
    left: 15%;
}

.g3 {
    position: absolute;
    width: 200px;
    height: auto;
    top: 40%;
    left: 50%;
}

.g4 {
    position: absolute;
    width: 200px;
    height: auto;
    top: 60%;
    left: 85%;
}

.g5 {
    position: absolute;
    width: 200px;
    height: auto;
    top: 30%;
    left: 5%;
}

/* Draggable Food Items */
#brocoli,
#cupcake,
#roll,
#tomato,
#grapes {
    position: absolute;
    width: 10%;
    height: auto;
}

#brocoli {
    top: 20%;
    left: 5%;
}

#cupcake {
    top: 10%;
    left: 25%;
}

#roll {
    top: 30%;
    left: 45%;
}

#tomato {
    top: 15%;
    left: 65%;
}

#grapes {
    top: 18%;
    left: 85%;
}

/* Tic Tac Poe Items */
#b1,
#b2,
#b3,
#b4,
#b5,
#r1,
#r2,
#r3,
#r4,
#r5 {
    position: absolute;
    width: 200px;
    height: auto;
}

#b1 {
    top: 10%;
    left: 5%;
}

#b2 {
    top: 25%;
    left: 40%;
}

#b3 {
    top: 50%;
    left: 60%;
}

#b4 {
    top: 70%;
    left: 20%;
}

#b5 {
    top: 50%;
    left: 50%;
}

#r1 {
    top: 15%;
    left: 60%;
}

#r2 {
    top: 30%;
    left: 20%;
}

#r3 {
    top: 55%;
    left: 70%;
}

#r4 {
    top: 65%;
    left: 10%;
}

#r5 {
    top: 62%;
    left: 30%;
}

/* Ensure images scale well */
.miniminipou,
.lamp {
    max-width: 100%;
    height: auto;
}

.stop {
    cursor: url('../img/stopcursor.png') 16 16, auto;
}

.pou:hover {
    background-image: url('../img/pou40_hower.png');
}

.pougames:hover {
    background-image: url('../img/pougames_hower.png');
}

.hoverElement {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%); /* sourced from ChatGPT */
    cursor: pointer;
    text-align: center;
    z-index: 10;
}

/* Image hover effect */
.hoverElement:hover .minipousinging {
    transform: scale(1.1);
    transition: transform 0.3s ease;
    content: url('../img/sing.gif');
}

.about {
    cursor: url('../img/spiral1.png') 16 16, auto;
}

/* ==========================================================================
   6. Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
    /* Adjust size for lamp and miniminipou */
    .miniminipou,
    .lamp {
        width: 50vw;
    }
    .minipou,
    .lamp {
        width: 60vw;
    }
    .pou,
    .lamp {
        width: 100vw;
    }

    /* Navigation adjustments */
    .nav-container {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 10px;
        padding: 10px;
        position: absolute;
        top: 10%;
        left: 50%;
        transform: translate(-50%, -50%); /* sourced from ChatGPT */
        width: fit-content;
        gap: 5px;
        padding: 5px;
        width: 90vw;
        max-width: 100%;
    }

    .stop,
    .right-arrow,
    .left-arrow {
        width: 15vw;
    }

    .nav-container img[alt*="age"] {
        height: 50px;
    }

    /* Game container width */
    .game-container img {
        width: 150px;
        height: auto;
        padding: 0;
    }

    .game-container {
        position: absolute;
        top: 58%;
        left: 50%;
        transform: translate(-50%, -50%); /* sourced from ChatGPT */
    }

    .game-container img:nth-child(2) {
        width: auto;
        height: 30px;
        padding: 0;
    }

    .mini_games_text {
        height: 32px !important;
        width: auto !important;
    }

    /* Lamp specific adjustments */
    .lamp {
        width: 50%;
        height: auto;
        position: absolute;
        bottom: -2.5%;
        right: -5%;
    }

    /* Individual Game: Scale down if needed */
    .games {
        width: 30%;
        position: absolute;
        bottom: 0%;
        right: -5%;
        z-index: 5;
    }

    /* Make Pou smaller only on the food_drop page */
    .food_drop .pou {
        width: 60vw;
        height: auto;
    }

    .food_drop {
        background: url('../img/picnic1.png') no-repeat center center;
        background-size: cover;
        background-attachment: fixed;
    }

    .tic_tac_pou {
        background: url('../img/grid2.png') no-repeat center center;
        background-size: cover;
        background-attachment: fixed;
    }

    /* Reduce the size of food items */
    .food_drop #brocoli img,
    .food_drop #cupcake img,
    .food_drop #roll img,
    .food_drop #tomato img,
    .food_drop #grapes img {
        width: 60px !important;
        height: auto;
    }

    #grapes {
        position: absolute;
        top: 49%;
        left: 50%;
    }

    /* Adjusting size of elements for tic tac pou */
    #b1,
    #b2,
    #b3,
    #b4,
    #b5,
    #r1,
    #r2,
    #r3,
    #r4,
    #r5 {
        position: absolute;
        width: 40px !important;
        height: auto !important;
    }

    html,
    body {
        overflow: hidden;
        height: 100%;
        width: 100%;
        margin: 0;
        padding: 0;
    }
}

@media (min-width: 1700px) {
    /* Targets larger screens like Macs */
    .lamp {
        position: absolute;
        bottom: -6%;
        right: -1%;
    }
}
