:root {
	--color-white: #f7f7f7;
	--color-peach: #ff6868;
	--color-light-peach: #ff7d7d;
	--color-blue: #00b1ff;
	--color-light-blue: #55ccff;
	--color-black: #222222;
	--color-gray: #8a8a8a;
	--color-light-gray: #cccccc;
}

@font-face {
	font-family: 'Sen';
	font-style: normal;
	font-weight: 400;
	font-display: swap;
	src: local('Sen Regular'), local('Sen-Regular'), url(/assets/sen.woff2) format('woff2');
}
@font-face {
	font-family: 'Sen';
	font-style: normal;
	font-weight: 700;
	font-display: swap;
	src: local('Sen Bold'), local('Sen-Bold'), url(/assets/sen-bold.woff2) format('woff2');
}

* {
	box-sizing: border-box;
}

h1, h2, h3, h4, h5, h6 {
	margin-top: 0;
	margin-bottom: 20px;
}

hr {
	height: 0;
	border: 0;
	border-bottom: 1px solid var(--color-light-gray);
}

a {
	color: var(--color-blue);
	cursor: pointer;
}

a:hover, a:focus {
	color: var(--color-light-blue);
}

body {
	font-family: 'Sen', sans-serif;
	background-image: url(/assets/salsa-bg.min.svg);
	background-color: var(--color-black);
	background-size: cover;
	background-repeat: no-repeat;
	background-position-y: bottom;
	background-attachment: fixed;
	color: var(--color-white);
	margin: 0;
}

@keyframes spin {
	from {transform: rotate(0deg);}
	to {transform: rotate(360deg);}
}

@keyframes fade-in {
	from {opacity: 0.0;}
	to {opacity: 1.0;}
}

@keyframes slide-up {
	from { transform: translate(0, 40px); }
	to { transform: translate(0, 0); }
}

@keyframes grow-width {
	from { transform: scaleX(0); }
	to { transform: scaleX(1); }
}

.lefty-righty {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.lefty-righty > * {
	margin-bottom: 0;
}

.center {
	display: flex;
	justify-content: center;
}

.right {
	display: flex;
	justify-content: end;
}

.subtle {
	margin: 20px auto;
	text-align: center;
	font-style: italic;
}

span.tiny {
	font-size: 12px;
	font-style: italic;
}

div.page, nav.page {
	margin: 0 auto;
	max-width: 1000px;
}

/* INPUTS */
label {
	display: block;
	margin-bottom: 5px;
	font-size: 18px;
}

label~input, label~select {
	margin-bottom: 20px;
}

button {
	cursor: pointer;
	background-color: var(--color-peach);
	border: 0;
	border-radius: 3px;
	padding: 12px 30px;
	font-size: 16px;
	color: var(--color-white);
}

button:hover, button:focus {
	background-color: var(--color-light-peach);
}

button.loading, div.loading {
	display: flex;
	align-items: center;
	justify-content: center;
}

button.loading::before, div.loading::before {
	content: '';
	display: inline-block;
	width: 20px;
	height: 20px;
	background-color: transparent;
	margin-right: 10px;
	border-radius: 20px;
	border: solid 2px transparent;
	border-top-color: currentColor;
	animation-name: spin;
	animation-duration: 500ms;
	animation-iteration-count: infinite;
}

input, select {
	width: 100%;
	padding: 8px;
	border-radius: 3px;
	border: solid 2px var(--color-gray);
	transition: 300ms border-color;
}

input:focus, select:focus {
	border-color: var(--color-peach);
}

select[multiple] {
	padding: 0;
}

select[multiple] option {
	padding: 8px;
}

input::placeholder {
	color: #cccccc;
	opacity: 1;
}

/* CHECKBOX & RADIO */
label > input[type="radio"],
label > input[type="checkbox"] {
	display: inline-block;
	width: auto;
	margin: 0 10px 0 0;
}

label.checkbox, label.radio {
	display: flex;
	align-items: center;
	font-size: 14px;
}


/* TABLE */
table {
	width: 100%;
	border-collapse: collapse;
}

table thead th {
	text-align: left;
	font-size: 18px;
}

table td, table th {
	padding: 15px 10px;
	border: 0;
	border: 0;
	border-bottom: 1px solid var(--color-light-gray);
}

table td:first-child, table th:first-child {
	padding-left: 0;
}

table td:last-child, table th:last-child {
	padding-right: 0;
}

table.mini-table thead th {
	font-size: 16px;
}

table.mini-table td, table.mini-table th {
	padding: 6px;
}

table.left-headers th {
	text-align: left;
	padding-left: 0;;
	width: 120px;
}

/* MODAL */
div.modal-wrap {
	background-color: rgba(0,0,0,.4);
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 2;
	animation-name: fade-in;
	animation-iteration-count: initial;
	animation-fill-mode: forwards;
	animation-duration: 300ms;
	overflow: auto;
}

div.modal-wrap .modal {
	margin: 20vh auto;
	background-color: white;
	padding: 20px;
	left: calc(50% - 300px);
	width: 600px;
	top: 20vh;
	color: var(--color-black);
	border-radius: 4px;
	animation-name: slide-up;
	animation-iteration-count: initial;
	animation-fill-mode: forwards;
	animation-duration: 300ms;
}

/* NOTIFICATIONS */
div#notification-box {
	position: fixed;
	bottom: 10px;
	right: 10px;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	flex-direction: column-reverse;
	z-index: 3;
}

div#notification-box > .notification {
	margin-bottom: 10px;
	padding: 12px 16px;
	background-color: var(--color-info);
	border-radius: 2px;

	animation-name: notification-animation;
	animation-duration: 20s; /* This needs to match the duration in notification.jsx */
	animation-fill-mode: forwards;
	animation-timing-function: linear;
}

@keyframes notification-animation {
	0% {
		transform: translateX(30px);
		opacity: 0;
	}
	1% {
		transform: translateX(0px);
		opacity: 1;
	}
	99% {
		transform: translateX(0px);
		opacity: 1;
	}
	100% {
		transform: translateX(-30px);
		opacity: 0;
	}
}

div#notification-box > .notification.error {
	background-color: var(--color-peach);
}

/* NAVIGATION */
.nav-wrap {
	background-color: var(--color-white);
	margin-bottom: 40px;
	animation-name: slide-in;
	animation-duration: 400ms;
}

nav {
	display: flex;
}

nav > a {
	outline: 0;
	padding: 20px 10px;
	text-decoration: none;
}

nav > a:first-child {
	padding-left: 0;
}

nav > a:last-child {
	padding-right: 0;
}

nav > a.active::after {
	display: block;
	width: 100%;
	height: 3px;
	content: '';
	background-color: var(--color-blue);
	margin-top: 4px;

	animation-name: grow-width;
	animation-iteration-count: initial;
	animation-fill-mode: forwards;
	animation-duration: 200ms;
}

@keyframes slide-in {
	from {
		transform: translate(0, -100px);
	}
	to {
		transform: translate(0, 0);
	}
}

nav > span {
	margin-left: auto;
	color: var(--color-peach);
	padding: 20px 10px;
}

/* LOGIN */
.login-wrap {
	width: 300px;
	margin: 20vh auto;
}

.login-wrap .heading {
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 40px;
	margin-bottom: 10px;
}

.login-wrap .heading h1 {
	margin: 0;
	margin-left: 10px;
}

.login-wrap .login-box label {
	font-size: 20px;
}

.login-wrap .login-box input,
.login-wrap .login-box select {
	border-color: transparent;
	padding: 12px;
	font-size: 20px;
}

.login-wrap button {
	width: 100%;
	padding: 12px;
	font-size: 20px;
}

/* HOME */
div.home {
	margin-top: 120px;
	display: flex;
}

div.home h1 {
	margin-bottom: 0;
}

div.home h3.timer {
	font-size: 80px;
	text-align: center;
	margin: 30px 0 0 0;
}


/* GROUPS / ACLS / USERS */
div.groups-table-wrap,
div.acls-table-wrap,
div.users-table-wrap {
	background-color: var(--color-white);
	border-radius: 3px;
	padding: 5px 20px 20px 20px;
	color: var(--color-black);

	animation-name: fade-in;
	animation-iteration-count: initial;
	animation-fill-mode: forwards;
	animation-duration: 250ms;
}
.checkbox-container {
	border-radius: 3px;
	border: solid 2px var(--color-gray);
	padding: 5px;
	margin-bottom: 15px;
	max-height: 100px;
	overflow-y: auto;
}

.checkboxtext {
  	font-size: 80%;
  	display: inline;
}

.close {
	font-size: 35px;
	cursor: pointer;
    position: absolute;
	right: 15px;
	top: 5px;
}

table.groups-table td:last-child,
table.groups-table th:last-child,
table.acls-table td:last-child,
table.acls-table th:last-child,
table.users-table td:last-child,
table.users-table th:last-child {
	text-align: right;
}

table.groups-table td:nth-child(3),
table.groups-table td:nth-child(4),
table.groups-table th:nth-child(3),
table.groups-table th:nth-child(4) {
	text-align: center;
}

.groups-table-wrap > div.subtle,
.acls-table-wrap > div.subtle,
.users-table-wrap > div.subtle {
	margin-bottom: 6px;
}

/* USER VIEW */
div.user-view-modal > h3 {
	margin-bottom: 10px;
}

div.user-view-modal > p {
	margin-top: 0;
	margin-bottom: 6px;
}

div.user-view-modal > hr {
	margin: 6px 0 15px;
}

table.view-users tr td:nth-child(2) {
	word-break: break-word;
}