html, body { margin: 0; height: 100%; width: 100% }
body {
	background-color: white;
	background-size: 90% auto;
}

main {
	width: 100%;
	height: 95%;
	height: calc(100% - 1em);
	max-height: 95%;
	max-height: calc(100% - 3em);
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	padding: 1.5em;	
	position: relative;
	box-sizing: border-box;
}

.display_panel {
	margin-bottom: 1em;
	width: 95%;
	width: calc(100% - 1em);
	flex: 1 1 auto;
	background-color: white;
	border-radius: 1em;
	color: black;
	padding: 2em;
	border: 1px solid #226;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	max-height: 70%;
	max-height: calc(100% - 9em);
	box-sizing: border-box;
	position: relative;
}

.title {
	margin-bottom: 0.5em;
	font-weight: bold;
}

.admin_panel {
	display: block;
	position: absolute;
	border: 1px solid #226;
	z-index: 10;
	padding: 2em;
	background-color: white;
	background-size: 100% 100%;
	border-radius: 1em;
	width: 26em;
	max-width: 90%;
	left: 40%;
	left: calc(50% - 13em);
	top: 30%;
	color: black;
}

.top_title {
	font-weight: bold;
	font-size: 2em;
	padding-top: 1.2em;
	padding-bottom: 1em;
	color: #234;
	white-space: nowrap;
}

.top_username {
	font-weight: bold;
	color: #999;
	white-space: nowrap;
	float: right;
}

.table-container table {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
}

.table-container > table td,
.table-container > table th {
	border: 1px solid #8ac;
	padding: 0.4em;
	text-align: left;

}

.table-container > table th,
.table-container > table th a,
.table-container > table th a:visited,
.table-container > table th a:hover {
	background-color: #8ac;
	color: white;
	text-decoration: none;
}

.table-container > table th.asc,
.table-container > table th.desc,
.table-container > table th.asc a,
.table-container > table th.desc a {
	background-color: #79b;
}

.table-container > table th {
	position: relative;
	height: 1.2em;
}

.table-container > table th.asc a {
	background: #79b url('/static/scale/images/down_arrow.png') no-repeat right center;
	background-size: auto 0.8em;
}

.table-container > table th.desc a {
	background: #79b url('/static/scale/images/up_arrow.png') no-repeat right center;
	background-size: auto 0.8em;
}

.table-container > table th > a {
	display: block;
	position: absolute; 
	left: 0px;
	top: 0px; 
	right: 0px;
	bottom: 0px;
	padding-top: 0.4em;
}

.even {
	background-color: #f0f8ff;
}

.scrollable-table {
	overflow-y: hidden;
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
}

.scrollable-table .scroll-part {
	flex: 1 1 auto;
	overflow-y: scroll;
	-ms-overflow-style: none;
	min-height: 4em;
}

.user-pagination {
	flex: 0 0 auto;
}

.scrollable-table .pagination li,
.user-pagination li,
.person_names_list li {
	display: inline-block;
        padding: 3px 6px;
	font-size: 1em;
        background-color: #f7f7f7 !important;
        background-image: linear-gradient(to bottom, #c3d3e3, #f0f7f7, #f0f7f7, #c3d3e3) !important;
        border: 1px solid #afafaf;
	color: black !important;
	text-decoration: none;
	cursor: pointer;
          -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
     -khtml-user-select: none; /* Konqueror HTML */
       -moz-user-select: none; /* Old versions of Firefox */
        -ms-user-select: none; /* Internet Explorer/Edge */
            user-select: none; /* Non-prefixed version, currently
                                  supported by Chrome, Opera and Firefox */
}

tr.hoverable:hover td {
	background-color: #def;
	font-weight: bold;
}

.person-name-display {
	font-weight: bold;
	font-size: 1.5em;
}

.scrollable-table .pagination li.active,
.person_names_list li.active,
.user-pagination li.active {
        background-image: linear-gradient(to bottom, #a8b7c7, #d4dbdb, #d4dbdb, #a8b7c7) !important;
}

.scrollable-table .pagination li a,
.scrollable-table .pagination li a:visited,
.scrollable-table .pagination li a:hover,
.user-pagination li a,
.user-pagination li a:visited,
.user-pagination li a:hover {
	text-decoration: none;
	color: black !important;
}

.scrollable-table .pagination li.active a,
.scrollable-table .pagination li.active a:visited,
.scrollable-table .pagination li.active a:hover,
.user-pagination li.active a,
.user-pagination li.active a:visited,
.user-pagination li.active a:hover {
	font-weight: bold;
}


#weight_chart {
	flex: 1 1 auto;
	margin-bottom: 1em;
	box-sizing: border-box;
}

form p {
	display: flex;
	flex-direction: row;
	width: 100%;
	line-height: 100%;
	vertical-align: middle;
	padding-top: 0.5em;
}

form button {
	background: white;
	color: black;
}

form p input[type=text],
form p input[type=email],
form p input[type=password] {
	display: block;
	position: relative;
	flex: 1 0 auto;
	margin-left: 1em;
	background-color: #def;
	color: black;
	padding: 0.5em;
	margin-top: -0.5em;
	border-radius: 0.2em;
	border: 1px solid #444;
}

form p input[type=text]:focus,
form p input[type=password]:focus {
	display: block;
	position: relative;
	flex: 1 0 auto;
	margin-left: 1em;
	background-color: #eff;
	color: black;
	padding: 0.5em;
	margin-top: -0.5em;
	border-radius: 0.2em;
	border: 1px solid #222;
}

.admin_panel .table {
	width: 100%;
}

.admin_panel .table input[type=text],
.admin_panel .table input[type=password] {
	width: 100%;
}

#chess_container {
	display: block; 
	width: 100%;
	height: 100%;
}

.navigator {
	display: block;
	position: fixed;
	z-index: 1000000;
	background-color: #124;
	padding: 0.5em 1em;
	left: 0px;
	right: 0px;
	min-height: 1em;
}

.navigator a {
	display: inline-block;
	color: white;
	text-decoration: none;
	margin-right: 1.5em;
}

.navigator a:visited {
	color: white;
}

.navigator a:hover {
	color: #ffd;
}

#game_message {
	display: block;
	color: red;
	font-weight: bold;
	padding: 0.5em;
}

.nav_buttons {
	padding-bottom: 0.5em;
}

#game_state {
	color: white;
}

@keyframes flasher {
  0% { opacity: 1.0; }
  50% { opacity: 0.0; }
  100% { opacity: 1.0; }
}

.flash_message {
  animation-name: flasher;
  animation-duration: 0.2s;
  animation-iteration-count: 3;
}

footer {
	display: block;
	position: fixed;
	z-index: 1000000;
	bottom: 0;
	left: 0;
	right: 0;
}

.messages {
	display: block;
	color: white;
	padding: 0.5em 1em;
	list-style-type: none;
}

.messages .success {
	color: green;
	font-weight: bold;
}

.messages .info {
	color: white;
	font-weight: bold;
}

.messages .error {
	color: red;
	font-weight: bold;
}

.messages .warning {
	color: yellow; 
	font-weight: bold;
}

.messages .info {
	color: white;
	font-weight: bold;
}

.footer {
	display: block;
	position: relative;
	background-color: #124;
	color: #aaa;
	padding: 0.5em 1em;
}

button,
.button,
.button:visited,
input[type="submit"] {
        display: inline-block;
        padding: 3px 6px;
	font-size: 1em;
        background-color: #f7f7f7 !important;
        background-image: linear-gradient(to bottom, #c3d3e3, #f0f7f7, #f0f7f7, #c3d3e3) !important;
        border: 1px solid #afafaf;
	color: black !important;
	text-decoration: none;
	cursor: pointer;
          -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
     -khtml-user-select: none; /* Konqueror HTML */
       -moz-user-select: none; /* Old versions of Firefox */
        -ms-user-select: none; /* Internet Explorer/Edge */
            user-select: none; /* Non-prefixed version, currently
                                  supported by Chrome, Opera and Firefox */
}

input[type="submit"].page-link,
button.page-link {
        position: relative;
        display: block;
        padding: .5rem .75rem;
        margin-left: -1px !important;
        line-height: 1.25;
        color: #007bff;
        background: #fff;
        border: 1px solid #dee2e6;
}

.float-right {
	display: block;
	float: right;
}

@keyframes error_message_animation {
  0%   {color: black;}
  25%  {color: white;}
  75%  {color: white;}
  100% {color: black;}
}

.error_message {
	display: block;
	position: absolute;
	right: 1em;
	top: 0.4em;
	color: black;
  	animation-name: error_message_animation;
  	animation-duration: 4s;
}

.back_button {
	display: block;
	position: absolute;
	top: 4em;
	right: 4.5em;
}

.alignment_table {
	display: table;
	width: 100%;
	margin-bottom: 0.5em;
}

.alignment_table > div {
	display: table-row;
}

.alignment_table > div > * {
	display: table-cell;
}

.alignment_table > div > *:last-child {
	text-align: right;
}

.summary_report {
	display: table;
}

.summary_report > div {
	display: table-row;
}

.summary_report > div > div {
	display: table-cell;
}

.summary_report > div > div:first-child {
	font-weight: bold;
	text-align: right;
	padding: 0.5em;
}

.person_summary > .summary_report {
	font-size: 0.7em;
	position: absolute;
	border: 1px solid #444;
	top: 10em;
	left: 11em;
	background-color: white;
	background-color: rgba(255,255,255,0.90);
	border-radius: 1em;
	padding: 1em;
}

.person_names_list {
	display: block;
	overflow-x: scroll;
	overflow-y: hidden;
	flex: 0 0 auto;
	margin-bottom: 2em;
}

.person_names_list li a {
	display: inline-block;
	color: black;
	text-decoration: none;
}

.person_name_display {
	position: absolute;
	left: 1em;
	top: 1em;
	font-weight: bold;
	font-size: 1.5em;
}

#date_picker_li {
        border: 1px solid #afafaf;
	background-color: white !important;
	background-image: none !important;
	color: black !important;
	padding: 0px;
	margin-right: 15px;
}

.user-pagination li.text_only_li {
        border: none;
	background-color: white !important;
	background-image: none !important;
	color: black !important;
}

#date_picker {
	width: 8em;
	border: none;
	margin: 0px;
	padding: 6px 6px;
}
