/* --- Google Font Import --- */
@import url('https://fonts.googleapis.com/css2?family=Jua&display=swap');

/* --- General Body & Layout --- */
body {
    font-family: 'Jua', sans-serif;
    background-color: #E3F2FD; /* Light sky blue */
    color: #333;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

main {
    width: 100%;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hidden {
    display: none !important;
}

/* --- Header & Navigation --- */
header, footer {
    width: 100%;
    max-width: 420px;
    text-align: center;
    margin-bottom: 20px;
}

header h1 {
    font-size: 2.5rem;
    color: #1E88E5; /* Stronger blue */
    margin: 10px 0;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
    display: flex;
    justify-content: center;
    gap: 15px;
}

nav a {
    text-decoration: none;
    color: #0277BD; /* Link blue */
    font-size: 1rem;
    padding: 5px 10px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

nav a:hover {
    background-color: #BBDEFB; /* Light blue on hover */
}


/* --- Card-like Sections --- */
section {
    background-color: #fff;
    border-radius: 12px;
    padding: 20px;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    text-align: center;
}

section h2 {
    margin-top: 0;
    color: #1E88E5;
}

/* --- Game Container --- */
#game-container {
    position: relative;
    width: 100%;
    height: 600px;
    border: none; /* Removed border, shadow is enough */
    background-color: #B3E5FC; /* Lighter blue for game bg */
    overflow: hidden;
}

#player {
    position: absolute;
    bottom: 10px;
    left: 175px;
    width: 50px;
    height: 50px;
    background-color: #42A5F5; /* A friendly blue */
    border-radius: 10px;
}

.poop {
    position: absolute;
    width: 35px;
    height: 35px;
    background-color: #6D4C41; /* Brown */
    border-radius: 50%;
    /* Let's use an emoji for a more playful feel */
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="90">💩</text></svg>');
    background-size: cover;
    background-color: transparent;
}


#info-display {
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 1.2rem;
    display: flex;
    gap: 20px;
    background-color: rgba(255, 255, 255, 0.7);
    padding: 5px 10px;
    border-radius: 8px;
}

/* --- Game Over & Start --- */
#game-over-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.5rem;
    color: #D32F2F; /* Red for game over */
    font-weight: bold;
    text-align: center;
    background-color: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 10px;
}

#start-container, #game-over-message {
    z-index: 10;
}

/* --- Buttons & Forms --- */
button, input {
    font-family: 'Jua', sans-serif;
}

button {
    padding: 12px 25px;
    font-size: 1.1rem;
    cursor: pointer;
    border: none;
    border-radius: 8px;
    background-color: #29B6F6;
    color: white;
    transition: background-color 0.3s, transform 0.2s;
}

button:hover {
    background-color: #0288D1;
    transform: translateY(-2px);
}

#start-container input, #partnership-form-container input, #partnership-form-container textarea {
    width: 100%;
    padding: 12px;
    font-size: 1rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    box-sizing: border-box;
    margin-bottom: 10px;
    transition: border-color 0.3s;
}

#start-container input:focus, #partnership-form-container input:focus, #partnership-form-container textarea:focus {
    border-color: #42A5F5;
    outline: none;
}

#partnership-form-container form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
#partnership-form-container button {
    background-color: #66BB6A; /* Green for submit */
}
#partnership-form-container button:hover {
    background-color: #388E3C;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* --- Touch Controls --- */
#touch-controls {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 400px;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    box-sizing: border-box;
    z-index: 5;
}

#touch-controls button {
    width: 70px;
    height: 70px;
    font-size: 2.5rem;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.6);
    color: #333;
    border: 2px solid #ccc;
}

/* --- Leaderboard & How-to --- */
#leaderboard {
    list-style-type: none;
    padding-left: 0;
}

#leaderboard li {
    margin-bottom: 8px;
    font-size: 1.2rem;
    background-color: #F5F5F5;
    padding: 10px;
    border-radius: 8px;
}

#how-to-play p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin: 10px 0;
}

/* --- Footer --- */
footer {
    border-top: 1px solid #BDBDBD;
    padding-top: 20px;
    margin-top: 20px;
    font-size: 0.9rem;
    color: #757575;
}

footer nav ul {
    margin-top: 10px;
    margin-bottom: 0;
}