/* General Styles */
body {
    background-color: #f0f0f0;
    color: #333;
    font-family: Arial, sans-serif;
    text-align: center;
    margin: 0;
    padding: 0;
    transition: background-color 0.3s, color 0.3s;
}

.game-container {
    margin: 20px auto;
    width: 90%;
    max-width: 600px;
}

#game-board {
    display: grid;
    gap: 10px;  /* Keeps spacing between cards */
    margin: 20px 0;
}

.card {
    width: 100%;
    padding-top: 100%; /* Makes cards square */
    position: relative;
    background-color: #007bff;
    cursor: pointer;
    border-radius: 5px;
    overflow: hidden;
}

.card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none; /* Hidden until flipped */
}

.card.flipped img {
    display: block;
}

/* Button Styles */
.btn, .button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    margin: 10px;
    transition: background-color 0.3s, transform 0.2s;
}

.btn:hover, .button:hover {
    background-color: #0056b3;
    transform: scale(1.05);
}

/* Theme Toggle Button */
.theme-toggle-container {
    text-align: right;
    padding: 10px;
}

#theme-toggle {
    background-color: #ffcc00;
    color: #121212;
    font-weight: bold;
}

#theme-toggle:hover {
    background-color: #ffaa00;
}

#results-table {
    width: 25%; /* Set the table width to 25% of the screen */
    margin: 0 auto; /* Center the table on the page */
    border-collapse: collapse; /* Remove extra space between cells */
    font-family: Arial, sans-serif; /* Clean font */
    font-size: 12px; /* Compact font size */
}

/* Header styles for compact leaderboard */
#results-table th {
    background-color: #f2f2f2; /* Light background for headers */
    padding: 6px; /* Compact padding */
    text-align: center;
    border: 1px solid #ccc; /* Subtle border */
}

/* Row styles for compact leaderboard */
#results-table td {
    padding: 4px; /* Minimal padding for compactness */
    text-align: center;
    border: 1px solid #ccc; /* Subtle border */
}

/* Alternating row colors for readability */
#results-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

#results-table tr:nth-child(odd) {
    background-color: #fff;
}


/* Footer */
.footer {
    background: #222;
    color: white;
    padding: 10px;
    margin-top: 20px;
}

.footer a {
    color: #ffcc00;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

dark-mode {
    background-color: #121212;
    color: #f0f0f0;
}

.dark-mode {
    background-color: #121212;
    color: #f0f0f0;
}

.dark-mode table {
    border-color: #fff;
    color: #121212;
}

.dark-mode .button, .dark-mode .btn {
    background-color: #ffcc00;
    color: #121212;
}

.dark-mode .btn:hover {
    background-color: #ffaa00;
}

/* Mobile Responsiveness */
@media screen and (max-width: 600px) {
    #game-board {
        grid-template-columns: repeat(3, 80px);
    }
}

/* Styling for the difficulty dropdown container */
.difficulty-container {
    margin: 30px 0;
    text-align: center; /* Center the content */
}

/* Styling the label to make it look good */
.difficulty-label {
    font-size: 1.5em;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
    display: block;
}

/* Styling the dropdown */
.difficulty-dropdown {
    padding: 15px;
    font-size: 1.2em;
    border: 2px solid #007BFF;
    border-radius: 8px;
    background-color: #f0f8ff;
    color: #333;
    transition: all 0.3s ease;
    width: 250px; /* Adjust the width to make it bigger */
    cursor: pointer;
    box-shadow: 0px 4px 8px rgba(0, 123, 255, 0.2); /* Add a light shadow */
}

/* Hover effect for dropdown */
.difficulty-dropdown:hover {
    border-color: #0056b3;
    background-color: #cce5ff; /* Light blue background on hover */
}

/* Focus effect for dropdown */
.difficulty-dropdown:focus {
    outline: none;
    border-color: #0056b3;
    background-color: #cce5ff; /* Light blue background on focus */
    box-shadow: 0 0 8px rgba(0, 91, 255, 0.7);
}

/* Center and style the login container */
.login-container {
    background-color: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 400px;
}

.login-container h2 {
    margin-bottom: 20px;
    font-size: 2.5em; /* Bigger title */
    color: #333;
}

.login-container input {
    width: 100%;
    padding: 15px;
    margin: 15px 0;
    border: 2px solid #ccc;
    border-radius: 10px;
    font-size: 1.2em; /* Larger input field */
    background-color: #f8f9fa; /* Light background for input fields */
}

.login-container button {
    width: 100%;
    padding: 15px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.5em; /* Bigger button */
    cursor: pointer;
    transition: background-color 0.3s;
}

.login-container button:hover {
    background-color: #0056b3; /* Darker blue on hover */
}

.error {
    color: red;
    font-size: 1.2em;
    margin-bottom: 15px;
}
