*, *::before, *::after {
	box-sizing: border-box;
}

html {
	line-height: 1;
	-webkit-text-size-adjust: 100%;
	-moz-tab-size: 4;
	tab-size: 4;
}

body {
	margin: 0;
	min-height: 100vh;
	font-family: "Open Sans","Arial","sans-serif";
	font-size: var(--font-medium);
	color: dimgrey;
}

a, a:link, a:visited, a:hover, a:active {
	color: inherit;
}
a:hover {
	text-decoration-color: #e02b20;
}

p {
	margin: auto;
}

div.top-decoration {
	height: 10px;
	background-color: #e02b20;
}

header {
	height: 70px;
	@media screen and (max-width: 800px) {
		height: 60px;
	}
	padding: 10px;
	background-color: white;
	border-bottom: 1px solid lightgrey;
	display: flex;
	flex-flow: row;
	justify-content: space-between;
	align-items: center;
	column-gap: 10px;
	position: sticky;
	top: -1px;
	& > a {
		height: 100%;
		& img {
			height: 100%;
		}
	}
	& h1 {
		white-space: nowrap;
		text-overflow: ellipsis;
		overflow: hidden;
		@media screen and (max-width: 800px) {
			font-size: x-large;
		}
	}
	& nav {
		display: flex;
		flex-flow: column;
		justify-content: center;
		align-items: center;
		row-gap: 5px;
		font-size: smaller;
	}
}

main {
	display: flex;
	flex-flow: row wrap;
	justify-content: flex-start;
	align-items: flex-start;
	column-gap: 10px;
	row-gap: 10px;
	padding: 10px;
	margin-bottom: 200px;
}

footer {
	background: black;
	color: lightgrey;
	padding: 1rem;
	position: fixed;
	bottom: 0px;
	width: 100%;
}

table {
	flex-grow: 1;
	min-width: 25%;
	border-collapse: collapse;
	text-indent: 0;
	border-color: inherit;
	border: 1px solid grey;
	& caption {
		background-color: dimgrey;
		color: white;
		font-size: smaller;
		padding: 0.125rem 0.5rem;
	}
	& tr:hover td {
		/* background-color: lightyellow; */
		color: black;
	}
	& th {
		font-size: xx-small;
		padding: 0.125rem 0.5rem;
	}
	& td {
		border: 1px solid grey;
		text-align: center;
		padding: 0.125rem 0.5rem;
	}
}

p.login-error {
	width: 100%;
	text-align: center;
	color: red;
	padding: 0.25rem;
	margin-top: 0.5rem;
}

p.password-forgotten-sent {
	width: 100%;
	text-align: center;
	color: green;
	padding: 0.25rem;
	margin-top: 0.5rem;
}

form#password-forgotten,
form#login {
	margin: 1rem auto;
	border: 1px solid lightgray;
	border-radius: 0.5rem;
	padding: 1rem;
	display: flex;
	flex-flow: column;
	justify-content: flex-start;
	align-items: stretch;
	background-color: whitesmoke;
	min-width: 250px;
	& label {
		font-size: smaller;
		margin-bottom: 2px;
	}
	& input {
		text-align: center;
	}
	& a.password-forgotten {
		text-align: center;
		font-size: x-small;
	}
}

form#coach-edit {
	flex-grow: 1;
	min-width: 25%;
	display: flex;
	& table {
		& input[type="text"],
		& input[type="email"],
		& input[type="tel"] {
			width: 100%;
			text-align: center;
		}
	}
}

form#participant-edit {
	flex-grow: 1;
	min-width: 25%;
	display: flex;
	& table {
		& input[type="number"],
		& input[type="text"] {
			width: 100%;
			text-align: center;
		}
	}
}

form#training-attendance-register {
	flex-grow: 1;
	min-width: 25%;
	padding: 0.25rem;
	text-align: center;
	background-color: whitesmoke;
	line-height: 1.25;
	font-size: small;
	border: 1px solid grey;
	& label {
		font-size: smaller;
	}
}

form#lesson-edit {
	flex-grow: 1;
	min-width: 25%;
	display: flex;
	& textarea {
		width: 100%;
	}
}

div.lesson-detail {
	flex-grow: 1;
	& a {
		display: block;
		text-align: center;
	}
}

table.coach-detail,
table.training-detail,
table.lesson-detail {
	& th {
		border: 1px solid grey;
	}
}

table.training-dates {
	& tr.error td {
		background: pink !important;
	}
	& tr.skipped td {
		background: lightgrey !important;
	}
}

b.error {
	color: red;
	text-shadow: 0 0 1px black;
}

div.import-error-new-participant,
div.import-error-duplicate,
div.import-error-date-difference,
div.import-error-update-detected {
	padding: 0 1rem;
	width: 100%;
}
div.import-error-duplicate,
div.import-error-date-difference {
	border: 1px solid red;
}
div.import-error-update-detected,
div.import-error-new-participant {
	border: 1px solid orange;
}

p.import-completed {
	width: 100%;
	padding: 1rem;
	text-align: center;
	font-weight: bold;
	color: black;
	&.with-errors {
		background: pink;
	}
	&.with-success {
		background: lightgreen;
	}
}

table.participants-list {
	& tr.not-in-clubdesk {
		background-color: red;
		color: white;
	}
	& tr.not-in-clubdesk-but-forwarded {
		background-color: mistyrose;
	}
	& tr.not-billed {
		background-color: yellow;
	}
	& tr.not-paid {
		background-color: lemonchiffon;
	}
	& tr.paid-incomplete {
		background-color: lightblue;
	}
	& tr.cancelled {
		background-color: grey;
	}
	& tr.not-yet-processable {
		background-color: lightgrey;
	}
	& tr:target {
		outline: 2px solid black;
	}
}
