:root{
	--header-height: 5rem;
	--game-height: calc(100vh - ( var(--header-height) + 10rem) );
}

.invisible
{
	filter: opacity(0) !important;
}

body
{
	text-align: center;
	background-color: black;
	padding: 0;
	margin: 0;
}

.header
{
	height: var(--header-height);
	background-color: darkgreen;
	align-content: baseline;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-content: center;
}
.header h1
{
	width: 100%;
	margin-top: 0.25rem;
	margin-bottom: 0.5rem;
}
.header button, .header a
{
	margin-left: 0.5rem;
	margin-right: 0.5rem;
}

.game-main-container
{
	width: 100%;
	height: var(--game-height);
	display: flex;
	background-color: darkred;
	justify-content: space-between;
	overflow: hidden;
}

.left-menu
{
	width: 14rem;
	background-color: #99c;
	display: flex;
	flex-direction: column;
	resize: horizontal;
	border: 1px solid white;
	overflow: auto;
	padding:0.25rem;
	row-gap: 0.5rem;
	align-items: center;
}
.left-menu button
{
	min-height: 2rem;
	min-width:80%;
}

.main-viewport
{
	width: 100%;
	background-color: #333;
	border: 1px solid white;
	padding: 2px;
	overflow: auto;
	display: flex;
	align-items: center;
	justify-content: center;
	resize: horizontal;
}

.right-menu
{
	width: 18rem;
	background-color: #99c;
	resize: horizontal;
	border: 1px solid white;
	overflow: auto;
	padding-top: 0.25rem;
}



.right-menu-player-entry
{
	padding: 0.25rem;
	border-bottom: 1px solid white;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	align-content: center;
	position: relative;
}
.right-menu-player-entry:nth-child(1)
{
	border-top: 1px solid white;
	margin-top: 0.5rem;
}


.chat
{
	width: 100%;
	display: flex;
	height: calc(100svh - var(--header-height) - var(--game-height) - 0.75rem);
	bottom:0;
	left: 0;
	right: 0;
	background-color: #bb7;
	border-top: 2px solid white;
	flex-wrap: nowrap;
}

.chat-content
{
	width: 100%;
	height: 100%;
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
}

#system-messages-table
{
	font-size: 0.8rem;
}


.chat-content-messages
{
	height: 100%;
	border:1px solid teal;
	margin: 1px;
	overflow-y: scroll;
	overflow-x: hidden;
	display: flex;
	flex-direction: column-reverse;
	padding-right: 0.5rem;
}


.chat-content-messages table
{
	width: 100%;
	table-layout: fixed;
	border: 0;
	border-collapse: collapse;
	margin-bottom: auto;
}

.chat-content-messages th
{
	height: 0px;
	overflow: hidden;
	border: 0px solid black;
}

.chat-content-messages td 
{
  border:1px solid black;
  border-collapse: collapse;
}

.chat-content-messages td
{
	padding-right: 0.25rem;
	padding-left: 0.25rem;
	text-align: left;
} 

.chat-content-messages tr:nth-child(odd)
{
	background-color: #eeb;
}
.chat-content-messages tr:nth-child(even)
{
	background-color: #dd9;
}

.chat-input-row
{
	width: 100%;
	height: 1.8rem;
	border:1px solid teal;
	margin: 1px;
	text-align: left;
}

.chat-input-row input
{
	height: calc(100% - 3px);
	width: calc(100% - 8rem - 8px);
	padding: 0;
}

.chat-input-row button
{
	height: 100%; 
	width: 8rem;
}

.chat-content-users-list
{
	width: 30%;
	border:1px solid teal;
	margin: 1px;
	overflow-x: hidden;
}

.chat-content-users-list tr
{
	cursor: pointer;
}

.chat-content-users-list tr:nth-child(odd)
{
	background-color: #eeb;
}
.chat-content-users-list tr:nth-child(even)
{
	background-color: #dd9;
}


.scenes-wrapper
{
	width: 100%;
	height: 100%;
}
.scenes-wrapper div
{
	display: none;
}

.scenes-wrapper[scene="login"] #login-scene
{
	display: block;
}

#login-scene
{
	color: #fff;
	background-image: url(/resources/area-backgrounds/login.png);
	height: calc(100% - 2rem);
	padding: 1rem;
	background-position: center;
	background-size: cover;
}

.scenes-wrapper[scene="town"] #town-scene
{
	display: block;
}


.scenes-wrapper[scene="adventure"] #adventure-scene
{
	display: block;
}

#town-overlay-buttons button:hover
{
	filter: brightness(1.15);
}
#town-overlay-buttons button:hover .tooltiptext
{
	filter: brightness(calc(1/1.15));
}
#town-overlay-buttons button:active
{
	filter: brightness(0.85);
}
#town-overlay-buttons button:active .tooltiptext
{
	filter: brightness(calc(1/0.85));
}


#loot-modal .dialogue-modal
{
	min-height: 25rem;
}