body {
    font-family: 'Arial', sans-serif; /* Changed font slightly */
    background-color: #e8f5e9; /* Light green background */
    color: #333;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
}

.container {
    background-color: #ffffff;
    padding: 30px; /* Increased padding */
    border-radius: 12px; /* More rounded */
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.12); /* Different shadow */
    width: 100%;
    max-width: 750px; /* Slightly wider */
    text-align: center;
}

h1, h2 {
    color: #2e7d32; /* Dark green for headings */
}

label {
    display: block;
    margin-top: 12px;
    margin-bottom: 6px;
    font-weight: bold;
    text-align: left;
    color: #4caf50; /* Medium green for labels */
}

input[type="text"],
input[type="password"] {
    width: calc(100% - 24px);
    padding: 12px;
    margin-bottom: 18px;
    border: 1px solid #a5d6a7; /* Light green border */
    border-radius: 6px; /* More rounded inputs */
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}
input[type="text"]:focus,
input[type="password"]:focus {
    border-color: #4caf50; /* Medium green on focus */
    box-shadow: 0 0 0 0.2rem rgba(76, 175, 80, 0.25); /* Green glow */
    outline: none;
}

button {
    background-color: #4caf50; /* Medium green for buttons */
    color: white;
    padding: 12px 20px; /* Slightly more padding */
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    margin: 10px 5px; /* Increased margin */
    transition: background-color 0.2s ease-in-out, transform 0.1s ease;
}
button:hover {
    background-color: #388e3c; /* Darker green on hover */
    transform: translateY(-1px); /* Slight lift */
}
button:active {
    transform: translateY(0px); /* Press down */
}
button:disabled {
    background-color: #c8e6c9; /* Very light green for disabled */
    color: #757575;
    cursor: not-allowed;
    transform: translateY(0px);
}

.error-message { color: #f44336; margin-top: 10px; font-size: 0.9em; }
.success-message { color: #4caf50; margin-top: 10px; font-size: 0.9em; }
.info-message { color: #555; margin-top: 12px; font-size: 1em; }

/* CAPTCHA Styles - can be reused or customized */
#captcha-container { margin-bottom: 18px; text-align: left; }
.captcha-line { display: flex; align-items: center; }
#captchaInput { width: 100px; padding: 10px; margin-right: 10px; margin-bottom: 0; text-align: center; letter-spacing: 2px;}
.captcha-display { display: inline-block; padding: 10px 15px; background-color: #e8f5e9; border: 1px solid #a5d6a7; border-radius: 4px; font-size: 1.2em; font-weight: bold; letter-spacing: 3px; user-select: none; margin-right: 10px; }
.captcha-refresh-btn { padding: 8px 10px; font-size: 1.2em; background-color: #81c784; border: none; color: white; cursor: pointer; border-radius: 4px; }
.captcha-refresh-btn:hover { background-color: #66bb6a; }

/* Game Section Specific Styles */
#game-section, #leaderboard-section {
    margin-top: 35px; /* More space */
    padding-top: 30px;
    border-top: 2px solid #a5d6a7; /* Green separator */
}

.game-info {
    display: flex;
    justify-content: space-around;
    margin-bottom: 20px;
    font-size: 1.2em; /* Larger game info */
    font-weight: bold;
}
.game-info span {
    background-color: #c8e6c9; /* Light green background for info */
    padding: 10px 18px;
    border-radius: 8px;
    color: #2e7d32; /* Dark green text */
}

#gameArea {
    width: 100%;
    max-width: 450px; /* Control game area size */
    min-height: 300px;
    background-color: #a5d6a7; /* Greenish background for game area (grass) */
    border: 5px solid #66bb6a; /* Darker green border */
    border-radius: 10px;
    margin: 20px auto; /* Center game area */
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3x3 grid for holes */
    grid-template-rows: repeat(3, 1fr);    /* 3x3 grid for holes */
    gap: 15px; /* Space between holes */
    padding: 15px;
    box-sizing: border-box;
    position: relative; /* For hit effect */
}

.hole {
    background-color: #5d4037; /* Dark brown for hole */
    border-radius: 50%; /* Circular holes */
    position: relative;
    overflow: hidden; /* To contain the mole */
    border: 5px solid #4e342e; /* Darker border for hole depth */
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5); /* Inner shadow for depth */
}

.mole {
    width: 70%; /* Mole size relative to hole */
    height: 70%;
    background-color: #795548; /* Mole color */
    background-image: url('mole_face.png'); /* Optional: if you have a mole face image */
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center bottom;
    border-radius: 40% 40% 20% 20%; /* Mole head shape */
    position: absolute;
    bottom: -80%; /* Initially hidden below */
    left: 50%;
    transform: translateX(-50%);
    transition: bottom 0.2s ease-out; /* Smooth pop-up */
    cursor: pointer;
    border: 2px solid #4e342e;
}
.hole.up .mole {
    bottom: 10%; /* Mole pops up */
}

.hit-effect {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    background-image: url('hit_star.png'); /* Optional: if you have a hit effect image */
    background-color: yellow; /* Fallback */
    background-size: contain;
    transform: translate(-50%, -50%) scale(0);
    animation: hitAnimation 0.3s ease-out;
    pointer-events: none; /* So it doesn't interfere with clicks */
}

@keyframes hitAnimation {
    0% { transform: translate(-50%, -50%) scale(0); opacity: 1; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.8; }
    100% { transform: translate(-50%, -50%) scale(0.8); opacity: 0; }
}


/* Leaderboard Styles - can be reused or customized */
.leaderboard-filters button { background-color: #81c784; margin-bottom: 15px; }
.leaderboard-filters button:hover { background-color: #66bb6a; }
#leaderboardTable { width: 100%; border-collapse: collapse; margin-top: 15px; }
#leaderboardTable th, #leaderboardTable td { border: 1px solid #c8e6c9; padding: 10px; text-align: left; }
#leaderboardTable th { background-color: #4caf50; color: white; text-align: center; font-weight: bold; }
#leaderboardTable tbody tr:nth-child(even) { background-color: #e8f5e9; }

/* Basic mole face using CSS if no image */
.mole::before {
    content: '';
    position: absolute;
    width: 10px;
    height: 10px;
    background: black;
    border-radius: 50%;
    top: 20%;
    left: 25%;
    box-shadow: 20px 0 0 black; /* Second eye */
}
.mole::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 8px;
    background: #ffc107; /* Nose color */
    border-radius: 3px;
    top: 40%;
    left: 50%;
    transform: translateX(-50%);
}