html, body {
    margin: 0;
    padding: 0;
    background: #F5F5E9;
    height: 100%;
    position: relative;
}

/* Ensure images scale with their container */
img {
    max-width: 100%;
    height: auto;
}

h1 {
    color: #344131;
    font-family: Mansalva;
    font-size: 4rem;
    font-style: normal;
    font-weight: 400;
    text-align: center;
    margin-bottom: 2rem;
}

.header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    padding-top: 0.4em;
    position: relative;
    z-index: 2;
}

.header-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-left: 0.4em;
    gap: 1rem;
}

/* Player Scores */
.player-scores {
    display: flex;
    flex-direction: row;
    justify-content: center;
    width: 100%;
    gap: 70em;
}

.player1-score, .player2-score {
    color: #344131;
    font-family: Mansalva;
    font-size: 2.2rem;
}

/* Game Scene */
#scene {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

#table {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
}

/* Tiles */
.tile-pile {
    display: flex;
    justify-content: center;
}

#pile1, #pile2 {
    position: absolute;
    top: 26%;
}

#pile1 {
    left: 33%;
}

#pile2 {
    right: 33%;
}

/* The tile images will default to 220px width but scale down on smaller screens */
.tile-pile img {
    width: 220px;
}

/* Direction arrow */
#direction-arrow {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
}

/* Game Buttons */
.game-button {
    position: absolute;
    padding: 10px 20px;
    background-color: rgba(255, 255, 255, 0.7);
    border: 2px solid #344131;
    border-radius: 20px;
    color: #344131;
    font-family: Mansalva;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s;
}

.game-button:hover {
    background-color: rgba(255, 255, 255, 0.9);
}

#draw-button {
    bottom: 20%;
    left: 50%;
    transform: translateX(-50%);
}

#pass-button {
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
}

#person1, #person2 {
    width: 560px;
    height: auto;
    position: absolute;
    bottom: 0;
    z-index: 1;
}

#person1 {
    left: 0;
}

#person2 {
    right: 0;
}

/* Win Message and Other Overlays */
#win-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #EDE5C0;
    padding: 6rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

#win-message.hidden {
    display: none;
}

.message {
    position: absolute;
    background-color: #F5F5E9;
    padding: 2rem 3rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 10;
    width: 300px;
}

#snake-eyes-message,
#single-one-message {
    top: 65%;
    left: 50%;
    transform: translateX(-50%);
}

.message.hidden {
    display: none;
}

.message-content {
    font-family: Mansalva;
    color: #344131;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.4rem;
}

.message-content h2 {
    font-size: 2rem;
    margin: 0;
}

.result-text {
    font-size: 1.5rem;
    margin: 0;
}

.winner-text {
    font-size: 2.4rem;
    margin: 0;
}

.game-button {
    margin-top: 8rem;
}

#new-round {
    margin-top: 10rem;
}
