/* style.css */
#landingPage {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-size: contain; /* Resize the background image */
    background-repeat: no-repeat;
    background-position: center;
}

#gameLogo {
    width: 50%; /* Adjust the width as needed */
    height: auto; /* Maintain aspect ratio */
}

#beginButton {
    margin-top: 20px;
    padding: 10px 20px;
    font-size: 20px;
    cursor: pointer;
}

/* Hide game initially */
#gameContainer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

/* Alphabet Container Styles */
#alphabetContainer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
}

.alphabetLetter {
    margin: 5px;
    padding: 10px;
    border: 1px solid white;
    cursor: pointer;
}

body {
    background-image: url('./images/Labyrinth.png'); /* Labyrinth background */
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
    position: relative;
    color: white;
    font-family: Arial, sans-serif;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Adjust opacity */
    z-index: -1;
}

#gameContainer, #landingPage {
    position: relative;
    z-index: 1;
}

.title {
    text-align: center;
    margin-top: 50px;
    font-size: 32px;
    color: white;
}

.scoreboard {
    position: absolute;
    top: 10px;
    right: 10px;
    color: white;
    font-family: Arial, sans-serif;
    font-size: 20px;
}

#grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-gap: 10px;
    max-width: 250px;
    margin: 20px auto;
    outline: none;
}

.cell {
    width: 50px;
    height: 50px;
    border: 2px solid white;
    text-align: center;
    font-size: 30px;
    line-height: 50px;
    color: white;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.6s;
    perspective: 1000px; /* Add perspective for 3D effect */
}

.cell .letter, .cell .back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden; /* Hide the back face of the div */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
}

.cell .back {
    transform: rotateY(180deg); /* Initial rotation for the back */
    color: white; /* Text color for the back side */
}

/* Class to apply the flip animation */
.flip {
    transform: rotateY(180deg); /* Rotate the cell for flip effect */
}

.correct, .present, .absent {
    /* Apply these styles after the flip */
    transition-delay: 0.3s; /* Delay to synchronize with the flip */
}

.correct {
    background-color: green !important;
}

.present {
    background-color: rgb(176, 176, 9) !important; /* Yellow-ish */
}

.absent {
    background-color: rgb(99, 99, 99) !important; /* Grey */
}

#alphabetContainer {
    display: grid;
    grid-template-columns: repeat(9, 1fr); /* 9 columns for 3 rows */
    grid-gap: 5px;
    max-width: 450px; /* Adjust as needed */
    margin: 20px auto;
}

.alphabetLetter {
    padding: 10px;
    border: 1px solid white;
    text-align: center;
    font-size: 20px; /* Adjust font size as needed */
    cursor: pointer;
    transition: background-color 0.3s;
}

/* Add styles for correct, present, and absent states */
.alphabetLetter.correct {
    background-color: green;
}

.alphabetLetter.present {
    background-color: rgb(176, 176, 9); /* Yellow-ish */
}

.alphabetLetter.absent {
    background-color: rgb(99, 99, 99); /* Grey */
}

#hiddenInput {
    position: absolute;
    opacity: 0;
    left: 0;
    top: 0;
    height: 1px;
    width: 1px;
    border: none;
    padding: 0;
    margin: -1px; /* Prevents it from affecting layout */
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap; /* Added for screen reader accessibility */
}

body, html {
    overflow: hidden;
}


