body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #333;
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden; /* Prevents scrollbars if content is slightly larger */
}

#authScreen {
    background-color: #444;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

#authScreen h1 {
    color: #ffc107; /* Gold color */
}

#authScreen input {
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #555;
    border-radius: 4px;
    background-color: #222;
    color: #fff;
}

#authScreen button {
    padding: 10px 20px;
    background-color: #ffc107;
    color: #333;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}
#authScreen button:hover {
    background-color: #e0a800;
}
.small-text {
    font-size: 0.8em;
    color: #aaa;
}

#gameScreen {
    display: flex;
    gap: 20px;
    background-color: #2a2a2a;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0,0,0,0.7);
    position: relative; /* Added for positioning fullscreen button */
}

#fullscreenButton {
    position: absolute;
    top: 15px; /* Adjust as needed */
    right: 280px; /* Adjust to be next to rightPanel or over canvas */
    padding: 8px 12px;
    background-color: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    z-index: 50; /* Ensure it's above canvas but below modals */
}
#fullscreenButton:hover {
    background-color: #5a6268;
}

#leftPanel {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#gameCanvas {
    border: 1px solid #555;
    background-color: #1e1e1e; /* Darker game background */
}

#chatArea {
    background-color: #3a3a3a;
    padding: 10px;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

#chatDisplay {
    height: 100px;
    overflow-y: auto;
    border: 1px solid #444;
    padding: 5px;
    background-color: #282828;
    font-size: 0.9em;
    margin-bottom: 5px;
}
#chatDisplay p {
    margin: 2px 0;
    word-break: break-word;
}

#chatInput {
    flex-grow: 1;
    padding: 8px;
    border: 1px solid #555;
    border-radius: 4px;
    background-color: #222;
    color: #fff;
}

#sendChatButton {
    padding: 8px 15px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}
#sendChatButton:hover {
    background-color: #0056b3;
}


#rightPanel {
    width: 250px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#playerListContainer, #questInfoContainer, #playerStatsContainer {
    background-color: #3a3a3a;
    padding: 10px;
    border-radius: 4px;
}

#playerListContainer h2, #questInfoContainer h2, #playerStatsContainer h2 {
    margin-top: 0;
    font-size: 1.2em;
    color: #ffc107;
    border-bottom: 1px solid #555;
    padding-bottom: 5px;
}

#playerList {
    list-style: none;
    padding: 0;
    max-height: 150px;
    overflow-y: auto;
}
#playerList li {
    padding: 3px 0;
    color: #ddd;
}

#playerStats {
    font-size: 0.9em;
    color: #ccc;
    line-height: 1.4;
}

#questInfo {
    font-size: 0.9em;
    color: #ccc;
}

#notifications {
    background-color: rgba(0,0,0,0.7);
    color: #ffc107;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    font-size: 0.9em;
    min-height: 20px; /* So it doesn't collapse when empty */
}

#npcDialog {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #4f4f4f;
    padding: 20px;
    border: 2px solid #ffc107;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0,0,0,0.6);
    z-index: 100;
    width: 350px;
    color: #fff;
}
#npcDialog h3 {
    margin-top: 0;
    color: #ffc107;
}
#npcDialog p {
    margin-bottom: 10px;
}
#npcDialog button {
    padding: 8px 15px;
    background-color: #ffc107;
    color: #333;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 10px;
}
#npcDialog button.quest-button {
    background-color: #007bff;
    color: white;
    display: block;
    margin-top: 5px;
    width: 100%;
}
#npcDialog button.quest-button:hover {
    background-color: #0056b3;
}
#npcDialog #closeNpcDialog {
    background-color: #6c757d;
    color: white;
}
#npcDialog #closeNpcDialog:hover {
    background-color: #5a6268;
}