/*  Initialise variables: We are using different images on the
	watchlist "handle", depending on state *and* language */
body {
	--img-watchlist-open: url("../img/wl-open-en.png");
	--img-watchlist-close: url("../img/wl-close-en.png");
}

body[data-lang="de"] {
	--img-watchlist-open: url("../img/wl-open-de.png");
	--img-watchlist-close: url("../img/wl-close-de.png");
}

body
{
	height: 100vh;
	padding: 0;
	border: none;
	overflow-y: scroll;	/* force a scrollbar, otherwise centered fixed-width content will 'jump' */
	background: #f8f8f8;
	font-family: "Verdana", "Arial", "Helvetica", "Sans Serif";
	font-size: 0.8em;
	text-align: center;
}

pre
{
	text-align: left;
}

ul.menu
{
	margin: 0;
	padding: 2px;
	background: #000000;
	color: #6E727A;
	color: #A3AAB7;
	color: #C5CDDB;
	font-size: 1em;
}

ul.menu.left
{
	float: left;
	margin-right: 2.5em;
	text-align: left;
}

ul.menu > li
{
	display: inline;
	white-space: nowrap;
	margin: 0;
}

ul.menu.left > li.sep
{
	border-left: 1px solid #A3AAB7;
	padding-left: 0.5em;
}

ul.menu.right > li.sep
{
	border-right: 1px solid #A3AAB7;
	padding-right: 0.5em;
}

ul.menu li > a
{
	color: #A3AAB7;
	color: #6E727A;
	font-weight: bold;
}

ul.menu li > a:hover
{
	color: #ffffff;
}

ul.menu li.lang
{
	vertical-align: baseline;
}

ul.menu + div
{
	clear: both;
}

nav img.flag
{
	color: #000000;
	background: #A3AAB7;
}

div.table
{
	margin: auto;
	display: table;
	padding-left: 2em;
	padding-right: 2em;
}

div.row
{
	display: table-row;
}

div.cell
{
	display: table-cell;
}

div.footnote
{
	font-size: 0.8em;
}

img
{
	border: none;
}

img.email
{
	vertical-align: bottom;
}

a
{
	color: #000080;
	text-decoration: none;
}

a:hover
{
	color: #000040;
}

a.back
{
	display: block;
	padding: 1em 0 0 0;
	font-size: 0.8em;
}

fieldset
{
	border: 1px solid #dddddd;
	margin-top: 10px;
	margin-bottom: 10px;
}

div.label
{
	padding-right: 1em;
	text-align: right;
	white-space: nowrap;
}

input[type=submit],
input[type=reset]
{
	min-width: 5em;
	background-color: white;
}

input[type=submit]:disabled,
input[type=reset]:disabled
{
	background-color: white !important;
}

td, th
{
	white-space: nowrap;
}

dl.inline dt
{
	float: left;
	margin: 0 1.2em 0 0;
}

dl.inline dd + dt,
dl.inline dd + dd
{
	clear: left
}

dl.inline dd + dd
{
	float: none
}

dl.inline dt
{
	font-weight: bold
}

ul.help > li
{
	list-style: none;
}

ul.help div
{
	margin: 1em;
}

ul.help img.screen
{
	margin: 0.1em;
	margin-right: 1em;
	padding: 1em 0em;
	vertical-align: middle;
}

#mobile ul.help img
{
	margin: 0.1em;
	margin-right: 1em;
	vertical-align: middle;
}

.fs12 { font-size: 12pt; }
.smaller { font-size: smaller; }
.b { font-weight: bold; }
.i { font-style: italic; }
.bi { font-weight: bold; font-style: italic; }
.underline { text-decoration: underline; }
.strikethrough { text-decoration: line-through; }
.left { text-align: left; }
.center { text-align: center; }
.right { text-align: right; }
.top { vertical-align: top; }
.nobr { white-space: nowrap; }
.explain { background: #EAEAFF; }
.success { background: #EAFFEA; }
.notice { background: #FFFFEA; }
.error { background: #FFEAEA; }
.noscript
{
	z-index: 3;
	margin: auto 2em 1em;
	padding: 0.2em 0.8em;
	background: #ffffcc;
	border: thin solid #dddddd;
	display: block;
	text-align: center;
}

.box
{
	display: inline-block;
	margin: auto;
	padding: 10px;
	background: #ffffff;
	box-shadow: 0 0 3px #666666;
}

#head h1,
#head h3
{
	margin: 0 2px;
}

#head h1
{
	font-size: 2em;
}

#head h3
{
	font-size: 1.5em;
}

#head
{
	background-image: url("../img/header.jpg");
	background-color: #51555C;
	background-attachment: scroll;
	background-repeat: no-repeat;
	background-size: auto 100%;
	background-position: right center;
	color: white;
}

#error
{
	margin: 1em 0;
}

#error h1
{
	margin: 0;
}

.nodb
{
	margin-top: 1em;
	font-size: 14pt;
}

form
{
	margin: auto;
	padding: 1.5em;
	text-align: left;
}

form div.cell
{
	min-width: 8em;
	padding: 5px;
}

form div.hint
{
	text-align: right;
	font-size: 0.85em;
	font-style: italic;
}

form.stretched input[type=text],
form.stretched input[type=password],
form.stretched select
{
	width: 100%;
	padding: 0;
	margin: 0;
}

form div.explainatory
{
	margin: 1em 1em 1.5em 1em;
}

#timefmt
{
	width: 90%;
}

#notification
{
	margin-bottom: 10px;
	padding: 4px;
	border: 1px #dddddd solid;
	text-align: center;
}

#content
{
	margin: 0;
	padding: 6px 0;
	width: 792px;
}

#admin
{
	margin: 1em auto 1em auto;
	padding: 0.5em 1em;
	border: 1px solid #A3AAB7;
}

#rwy_cont
{
	display: inline-grid;
	margin: 0 0 6px 0;
	border: 1px solid grey;
}

#rwy_div
{
	display: inline-flex;
}

#rwy_l
{
	display: flex;
	align-items: center;
	padding: 0 2px;
	background: black;
	color: yellow;
}

#rwy_r
{
	padding: 0 4px;
	background: red;
	color: white;
}

#watchlist-container {
	position: fixed;
	height: 0;	/* We only need the width for the floating child div */
	width: inherit;
}

#watchlist-container > div {
	float: right;
	margin-right: -10px;
}

#watchlist {
	display: flex;
	height: 66vh;
	background-color: white;
	border-left: 1px solid;
	border-top: 1px solid;
	border-bottom: 1px solid;
	box-shadow: 5px 5px 10px #ccc;
}

#watchlist-handle {
	padding: 0.5em 2px 0 2px;
	cursor: pointer;
	-webkit-user-select: none;  /* Chrome all / Safari all */
	-moz-user-select: none;     /* Firefox all */
	-ms-user-select: none;      /* IE 10+ */
	user-select: none;
}

#watchlist-handle div {
	width: 16px;
}

#watchlist:not(.expanded)
#watchlist-handle div::before {
	content: var(--img-watchlist-open);
}

#watchlist.expanded
#watchlist-handle div::before {
	content: var(--img-watchlist-close);
}

#watchlist:not(.expanded)
#watchlist-handle + div {
	display: none;
}

#watchlist-handle + div {
	display: flex;
	align-items: stretch;
	padding: 0.5em;
}

#watchlist .tabs {
	padding: 0;
	padding-top: 1em;
}

#watchlist .tabs input[type=radio] {
	position: absolute;
	opacity: 0;
}

#watchlist .tabs input[type=radio] ~ label {
	padding: 0.2em 1em;
	border-top: 1px solid grey;
	border-left: 1px solid grey;
	border-right: 1px solid grey;
	border-radius: 6px 6px 0 0 !important;
	cursor: pointer;
}

#watchlist .tabs input[name=watchlist-tab]:not(:checked) + label {
	color: #ccc;
}

#watchlist .tabs input[name=watchlist-tab]:checked + label {
	color: #000;
}

#watchlist .tabs > div.divider {
	height: 0.2em;
	border-bottom: 1px solid lightgrey;
}

#watchlist input[name="watchlist-tab"][value="private"] ~ div form div[data-owner="private"] {
	display: none !important;
}

#watchlist input[name="watchlist-tab"][value="private"]:checked ~ div form div[data-owner="private"] {
	display: flex !important;
}

#watchlist input[name="watchlist-tab"][value="shared"] ~ div form div[data-owner="shared"] {
	display: none !important;
}

#watchlist input[name="watchlist-tab"][value="shared"]:checked ~ div form div[data-owner="shared"] {
	display: flex !important;
}

#watchlist section {
	margin: 0;
	padding: 0;
	overflow-y: scroll;
}

#form-container {
	height: 92%;
	margin-top: 1em;
}

#watchlist form {
	display: flex;
	flex-direction: column;
	height: 100%;
	margin: 0;
	padding: 0;
}

#watchlist form section > div {
	display: flex;
	flex-direction: column;
	padding-top: 0.5em;
}

#watchlist form button
{
	text-align: center;
	background-color: transparent;
	background-position: center;
	background-repeat: no-repeat;
	width: 20px;
	height: 20px;
	border: none;
	border-top:    solid 1px #eee;
	border-left:   solid 1px #eee;
	border-radius: 3px;
	box-shadow: 2px 2px 3px #ddd;
	-webkit-box-shadow: 2px 2px 3px #ddd;
}

#watchlist form button:active
{
	border-top: solid 1px #aaa;
	border-left: solid 1px #aaa;
	box-shadow: 2px 2px 3px #eee;
	-webkit-box-shadow: 2px 2px 3px #eee;
}

#watchlist form button.add
{
	background-image: url("../img/add.png") ;
}

#watchlist form button.del
{
	background-image: url("../img/trash.png");
}

#watchlist form button.del:disabled
{
	background-image: url("../img/trash-disabled.png");
}

#watchlist form input:disabled {
	color: #aaa !important;
	background-color: #ddd;
}

#watchlist form table,
#watchlist form th,
#watchlist form td
{
	font-size: 8pt;
	padding: 0 2px;
}

#watchlist form tr[data-submit="del"] input {
	text-decoration: line-through;
	color: #ccc;
}

#watchlist form td
{
	align-items: center;
}

#watchlist form td:first-child {
	display: flex;
}

#watchlist form tr > th div,
#watchlist form tr > td div {
	/* Extend to the dimensions of the photodb image */
	width: 13px;
	height: 12px;
	display: inline-block;
}

#watchlist form tr > th > div,
#watchlist form tr > td > div {
	margin-right: 0.5em;
}

#watchlist form tr > td a div {
	background-image: url("../img/camera.png");
}

#watchlist form tr > td > div:empty {
	background-image: url("../img/camera-disabled.png");
	background-repeat: no-repeat;
	background-position: center;
}

#watchlist form input[type=text]
{
	border: 1px solid grey;
}

#watchlist form input[type=text].comment
{
	width: 20em;
}

#watchlist div[data-owner="shared"] input[type=checkbox].notify,
#watchlist div[data-owner="shared"] th[data-key="notify"] a {
	visibility: hidden;
}

#watchlist form input[type=submit] {
	margin-top: 1em;
}

#schedule
{
	margin-right: 24px;
	width: auto;
}

#schedule a img
{
	margin-top: 1px;
	margin-left: 1px;
	margin-right: 2px;
}

#schedule table
{
	border: none;
	border-spacing: 0;
	border-collapse: collapse;
}

#schedule tr:nth-child(odd) { background-color:#f0f0f0; }
#schedule tr:nth-child(even)    { background-color:#ffffff; }
#schedule tr:hover { background-color:#ddd; }
#schedule tr.past { color: #aaa; }

#schedule th
{
	background: #aaaaaa;
	font-weight: normal;
	text-align: center;
	vertical-align: bottom;
	padding: 1px 4px;
}

#schedule th.sep
{
	border-left: 1px solid white;
}

#schedule td
{
	padding: 1px 4px;
	vertical-align: middle;
	white-space: nowrap;
}

#schedule td:nth-child(3),
#schedule td:nth-child(6)
{
	overflow: hidden;			/* required for text-overflow */
	-o-text-overflow: ellipsis;	/* for Opera since 9.0 */
	-ms-text-overflow: ellipsis;
	text-overflow: ellipsis;	/* for IE and WebKit (Safari, Chrome) */
	max-width: 15em;
}

#schedule td.early
{
	color: #cf0000;
}

#schedule td.model
{
	padding-left: 10px;
}

#schedule td.cargo
{
	background: url("../img/ld3-9.png") no-repeat left center;
	font-weight: bold;
}

#schedule th.reg,
#schedule td.reg {
	display: flex;
	align-items: center; /* Vertically centers the pseudo-element */
}

#schedule th.reg div,
#schedule td.reg a div {
	width: 13px;
	height: 12px;
	margin-right: 0.2em;
}

#schedule td.reg a div {
	background-image: url("../img/camera.png");
}

#schedule td.watch
{
	color: #009900;
	font-weight: bold;
}

#schedule td.special
{
	color: #006633;
	font-weight: bold;
}

#schedule td.rare
{
	color: #000000;
	font-weight: bold;
}

#phone-slider,
#tablet-slider,
#notification-slider
{
	display: inline-block;
	margin: 0 1em;
	min-width: 12em;
}

body .ui-tooltip
{
	border: 1px solid black !important;
	z-index: 9999;
	position: absolute;
	padding: 0.1em 0.2em;
	max-width: 300px;
	background: #FFFFE1;
	-webkit-box-shadow: 0 0 2px #AAA;
	box-shadow: 0 0 2px #AAA;
	border-radius: 0;
	font-size: 0.85em;
}

.fi {
	position: static !important;	/* Keep below watchlist! */
	margin: 0 0.5em;
}

#update-bookmarks
{
	display: flex;
	justify-content: center;
}

#requesturi-old
{
	font-weight: normal;
	color: #999;
}

#flighttype
{
	margin-top: 1em;
}

#freq
{
	margin-top: 0.5em;
}

#each div
{
	margin: 0.5em 0 0 2em;
}

.shrink
{
	min-width: auto !important;
}

#addflight_interval
{
	display: grid;
	margin-top: 0.5em;
}

fieldset .label
{
	min-width: 4em !important;
}
