*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1;
    margin: 0;
    padding: 0;
    background: #111;
    overflow: auto;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-image: linear-gradient(to top, black 0%, transparent 90%), url('/image1.png');
    background-size: cover;
    background-position: center -5vh;

}

header {
    background: transparent;
    color: #fff;
    text-align: center;
    width: 100%;
}

#header {
    height: 30vh;
    /* Set the height to 25% of the viewport height */
    /*background-image: url('/image1.png'); /* Set the background image */
    /*background-size: cover; /* Scale the image to cover the header */
    /*background-position: center -20vh; /* Center the background image */
    position: relative;
    /* Set the position to relative to allow positioning of child elements */
    text-align: center;
    /* Center the text horizontally */
}

#bannerImage {
    width: 100%;
    /*border-radius: 20%;*/
}

section {
    text-shadow: 1px 1px 3px #fff;
}

h1,
h2 {
    text-transform: uppercase;
}

main {
    flex: 1 0 auto;
    width: 80%;
    background: rgba(255, 255, 255, .75);
    padding: 3rem;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    border-radius: 70px;
    max-width: 500px;
    margin: 20px auto;
}

footer {
    background-color: #111;
    color: #fff;
    text-align: center;
    padding: 10px;
    width: 100%;
}

#inputGuess {
    display: flex;
    flex-direction: row;
    width: 100%;
    padding: 0;
    margin: 0 auto;
    align-items: center;
    justify-content: center;
}

.guessInput {
    width: 4rem;
    height: 4rem;
    margin: 0 10px;
    border-radius: 50%;
    background: gray;
    cursor: pointer;
    border: 0.5px solid #fff;
}

.colorPicker {
    position: fixed;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 20px;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
    display: none;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 475px;
}

.colorOption {
    width: 50px;
    height: 50px;
    margin: 10px;
    border-radius: 50%;
    cursor: pointer;
}

.show {
    display: flex;
}

#guessLog {
    margin-top: 20px;
    width: 100%;
    display: none;
}

#guessLog table {
    width: 100%;
    border-collapse: collapse;
}

#guessLog table td {
    padding: 9px;
    text-align: center;
    background-color: #fff;
    border-collapse: separate;
}

/* Top-left corner */
#guessLog table tr:first-of-type td:first-child {
    border-top-left-radius: 8px;
}

/* Top-right corner */
#guessLog table tr:first-of-type td:last-child {
    border-top-right-radius: 8px;
}

/* Bottom-left corner */
#guessLog table tr:last-of-type td:first-child {
    border-bottom-left-radius: 8px;
}

/* Bottom-right corner */
#guessLog table tr:last-of-type td:last-child {
    border-bottom-right-radius: 8px;
}

#shotCountSection {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#shotCountSection h2 {
    flex: 1;
}

#shotCountSection div {
    text-align: center;
    flex: 1;
    font-size: 4rem;
    font-weight: 800;
    color: red;
    text-shadow: 2px 2px 1px #fff;
}

#header {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

#header h1 {
    position: absolute;
    bottom: 0%;
    left: 50%;
    transform: translate(-50%, 0%);
    color: white;
    text-align: center;
    text-shadow: 4px 4px 4px rgba(0, 0, 0, 0.5);
    font-size: 4rem;
    margin: 0 auto;
    padding: 1rem;
}

.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background: transparent;
    width: 90%;
    margin: 15% auto;
    text-align: center;
    max-width: 500px;
}

.modal-content .overlay {
    position: relative;
}

.modal-content img {
    width: 100%;
    object-fit: cover;
    position: relative;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    border-radius: 20%;
}

.modal-content .text-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    text-align: center;
    line-height: 0.85;
}

.modal-content h2 {
    font-size: 5rem;
    margin-bottom: 15px;
    text-shadow: 4px 4px 4px rgba(0, 0, 0, 0.5);
}

.modal-content button {
    padding: 10px 20px;
    font-size: 1.5rem;
    background: #007BFF;
    color: #fff;
    border: none;
}

#secretPatternDisplay {
    margin: 15px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
}

@media screen and (max-width: 768px) {
    #header h1 {
        font-size: 3.2rem;
    }

    #header{
        height: 26vh;
    }

    main {
        padding: 3rem;  
        width:100%;
        border-radius: 0;      
    }

    #inputGuess {
        justify-content: left;
    }
}

@media screen and (max-width: 480px) {
    #header h1 {
        font-size: 2.99rem;
    }

    .guessInput {
        width: 3.0rem;
        height: 3.0rem;
    }

    #guessLog table td {
        font-size: 0.8rem;
        width: 50%;
    }

    #shotCountSection div {
        flex: .1;
    }
}