@font-face {
    font-family: 'Transport Medium';
    src: url('Transport Medium.ttf') format('truetype');
}
@font-face {
    font-family: 'Motorway Permanent';
    src: url('motorway_permanent.ttf') format('truetype');
}
body {
    margin: 0;
    padding: 0;
    font-family: 'Transport Medium', sans-serif;
}
#map {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100%;
}
header {
    width: 100%;
    background: rgba(255, 255, 255, 0.3);
    height: 60px;
    display: flex;
    justify-content: center; /* Center the logo */
    align-items: center;
    position: relative; /* Position for the absolute positioning of buttons */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    text-align: center;
    z-index: 1;
}
#logo {
    max-height: 100%;
    height: 60%;
}
#header-buttons {
    position: absolute;
    right: 20px; /* Adjust for desired spacing from right edge */
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    gap: 10px;
}
#sign-out-button {
    padding: 5px 10px;
    background-color: #d9534f;
    color: white;
    border: 2px solid black;
    cursor: pointer;
    border-radius: 5px;
    font-family: 'Transport Medium', sans-serif;
}

#leaderboard-button {
    padding: 5px 10px;
    background-color: white;
    color: black;
    border: 2px solid black;
    cursor: pointer;
    border-radius: 5px;
    font-family: 'Transport Medium', sans-serif;
}

#sign-out-button:hover {
    background-color: #c9302c;
}
#leaderboard-button:hover {
    background-color: #f0f0f0;
}
#user-box {
    position: absolute;
    top: 80px; /* Move user box lower */
    right: 85px; /* Adjusted from 10px to 85px */
    background-color: white;
    padding: 10px;
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 2;
}

#username {
    font-weight: bold;
}

.user-star {
    color: gold;
    font-size: 20px; /* Smaller size for star in user box */
}

#user-stars {
    font-weight: bold;
}

#player-score-box {
    position: absolute;
    top: 140px; /* Move player score box lower */
    right: 85px; /* Adjusted to align with user box */
    background-color: white;
    padding: 10px;
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    font-weight: bold;
    font-size: 16px;
    z-index: 2;
}

#destinationSign, #routeTime, #searchBox, #progressBox, #giveUpBox, #unguessedRoadsBox {
    position: absolute;
    left: 10px;
    width: 280px;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    z-index: 2;
    box-sizing: border-box;
    margin-bottom: 5px; /* Add some spacing between boxes */
}
#destinationSign {
    top: 80px;
    background-color: green;
    color: yellow;
    font-family: 'Transport Medium', sans-serif;
    border: 4px solid white;
}
#routeTime {
    top: 140px;
    background-color: #F9D74A; /* Updated to match the provided yellow color */
    color: black;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid black;
}
#progressBox {
    top: 195px;
    background-color: #7B3F00;
    color: white;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid white;
}
#stars {
    margin-top: 10px;
}
.star {
    font-size: 48px; /* Increased size of stars */
    color: gold;
}
.star.gray {
    color: gray;
}
#searchBox {
    top: 550px; /* Adjust this to move the search box lower */
    background-color: white;
    color: black;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid black;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#guessInput {
    flex: 1;
    font-size: 16px;
    border: none;
    outline: none;
    padding: 5px;
}
#submitGuess {
    font-family: 'Transport Medium', sans-serif;
    font-size: 16px;
    background-color: white;
    color: black;
    border: 2px solid black;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 5px;
    margin-left: 10px;
}
#submitGuess:hover {
    background-color: #f0f0f0;
}
#giveUpBox {
    top: 630px; /* Adjust this to move the give up box lower */
    background-color: white;
    color: black;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid black;
    display: flex;
    justify-content: center;
    align-items: center;
}
#giveUpButton {
    font-family: 'Transport Medium', sans-serif;
    font-size: 16px;
    background-color: white;
    color: black;
    border: 2px solid black;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 5px;
}
#giveUpButton:hover {
    background-color: #f0f0f0;
}
#unguessedRoadsBox {
    top: 700px; /* Adjust this to move the unguessed roads box lower */
    background-color: white;
    color: black;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid black;
    display: none;
    max-height: 300px; /* Set maximum height */
    overflow-y: auto; /* Enable vertical scrolling */
}
.road-sign, .no-entry-sign {
    position: fixed;
    top: 80%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 10px;
    display: none;
    z-index: 1000;
    text-align: center;
    font-size: 32px;
    padding: 15px 30px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
    opacity: 0;
}
.road-sign.green {
    background-color: green;
    color: yellow;
    font-family: 'Transport Medium', sans-serif;
    border: 4px solid white;
}
.road-sign.blue {
    background-color: #003399;
    color: white;
    font-family: 'Motorway Permanent', sans-serif;
    border: 4px solid white;
}
.road-sign.white {
    background-color: white;
    color: black;
    font-family: 'Transport Medium', sans-serif;
    border: 2px solid black;
}
.no-entry-sign {
    background: url('no_entry_sign.png') no-repeat center center;
    background-size: cover;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    padding: 0;
    border: none;
    box-shadow: none;
}
@keyframes fadeInOut {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
    10% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    90% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
}
.road-sign.show, .no-entry-sign.show {
    display: block;
    animation: fadeInOut 3s ease-in-out;
}
.popup {
    display: none; /* Hidden by default */
    position: fixed; 
    z-index: 999; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.4); 
    justify-content: center;
    align-items: center;
}

.popup-content {
    background-color: white;
    margin: auto;
    padding: 20px;
    border: 2px solid black; 
    width: 80%;
    max-width: 500px;
    border-radius: 8px;
    text-align: center;
    font-family: 'RoadSignFont', Arial, sans-serif;
}

#popup-button {
    background-color: #ffcc00; 
    border: 2px solid black; 
    color: black; 
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    font-family: 'RoadSignFont', Arial, sans-serif;
}

#popup-button:hover {
    background-color: #e6b800; 
}
li {
  margin: 20px 0;
}
button {
    background-color: #ffcc00; /* Yellow color */
    border: 2px solid black;
    color: black;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    font-family: 'RoadSignFont', Arial, sans-serif; /* Use the road sign font */
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 5px;
}

button:hover {
    background-color: #e6b800; /* Slightly darker shade for hover effect */
}
.mapboxgl-ctrl-top-right {
    top: 65px; /* Adjust this value to move the top controls lower */
}
.mapboxgl-ctrl-top-right {
    transform: scale(1.5); /* Increase the size of the controls */
    transform-origin: top right; /* Ensure the controls scale from their top-right corner */
}
