*,
*::before,
*::after {
	box-sizing: border-box;
	padding: 0;
	margin: 0;
}


a,
a:visited {
	color: #634ba0;
	text-decoration: none;
}

a:hover {
	color: #9b7edb;
	text-decoration: none;
}

html {
	font-size: 100%;
}

body {
	color: #212529;
	background-color: #f8f9fa;
	font-family:
		system-ui,
		-apple-system,
		"Segoe UI",
		Roboto,
		"Helvetica Neue",
		Arial,
		sans-serif;
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.5;
}

/* Header */
.pageHeader {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 2rem;
	min-height: 4rem;
	padding: 0.5rem max(1rem, calc((100% - 75rem) / 2));
	background-color: #fff;
	border-bottom: 1px solid #dee2e6;
	box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);

	.pageHeaderLogo {
		display: flex;
		align-items: center;
		flex-shrink: 0;

		a {
			display: flex;
			align-items: center;
		}

		.pageHeaderLogoLarge {
			display: block;
			width: auto;
			max-width: 12rem;
			height: 3rem;
			object-fit: contain;
		}
	}

	.pageHeaderContent {
		display: flex;
		align-items: center;
		gap: 1rem;

		.pageHeaderMenu {
			display: flex;
			align-items: center;

			nav {
				display: block;
			}

			.menuItems {
				display: flex;
				align-items: center;
				gap: 0.25rem;
				padding: 0;
				margin: 0;
				list-style: none;

				.menuitem {
					display: block;
					padding: 0.65rem 1rem;
					color: #495057;
					font-weight: 500;
					line-height: 1.25;
					text-decoration: none;
					border-radius: 0.375rem;
					transition:
						color 0.15s ease-in-out,
						background-color 0.15s ease-in-out;

					&:hover,
					&:focus-visible {
						color: #0d6efd;
						background-color: #f1f3f5;
					}

					&:focus-visible {
						outline: 0.2rem solid rgba(13, 110, 253, 0.25);
						outline-offset: 0.125rem;
					}

					&.active {
						color: #fff;
						background-color: #0d6efd;
					}
				}
			}
		}

		.pageHeaderUser {
			display: flex;
			align-items: center;
			gap: 0.75rem;
			padding-left: 1rem;
			color: #6c757d;
			border-left: 1px solid #dee2e6;
			white-space: nowrap;

			form {
				margin: 0;
			}

			button {
				padding: 0.5rem 0.75rem;
				color: #fff;
				background-color: #6c757d;
				border: 0;
				border-radius: 0.375rem;
				cursor: pointer;
				transition: background-color 0.15s ease-in-out;

				&:hover,
				&:focus-visible {
					background-color: #5c636a;
				}

				&:focus-visible {
					outline: 0.2rem solid rgba(108, 117, 125, 0.25);
					outline-offset: 0.125rem;
				}
			}
		}
	}
}

/* Main Area */
main {
	min-height: calc(100vh - 8rem);
	padding: 1.5rem max(1rem, calc((100% - 75rem) / 2));
	background-color: #eef1f4;

	.pagetitle {
		margin: 0 0 0.25rem;
		color: #212529;
		font-size: 2rem;
		font-weight: 600;
		line-height: 1.2;
	}

	.breadcrumbs {
		margin: 0 0 1.5rem;
		color: #6c757d;
		font-size: 0.95rem;
		font-weight: 400;
		line-height: 1.5;
	}
}

/* Welcome */
.welcome-box {
	position: relative;
	padding: 3.5rem;
	margin: 1.5rem 0;
	color: #fff;
	background:
		linear-gradient(
			135deg,
			#0d6efd 0%,
			#084298 100%
		);
	border: 1px solid #0a58ca;
	border-radius: 0.75rem;
	box-shadow: 0 0.5rem 1.5rem rgba(13, 110, 253, 0.2);
	overflow: hidden;

	&::after {
		content: "";
		position: absolute;
		top: -8rem;
		right: -6rem;
		width: 22rem;
		height: 22rem;
		background-color: rgba(255, 255, 255, 0.08);
		border-radius: 50%;
		pointer-events: none;
	}

	.welcome-label {
		position: relative;
		margin: 0 0 0.75rem;
		font-size: 0.875rem;
		font-weight: 600;
		letter-spacing: 0.1rem;
		text-transform: uppercase;
		opacity: 0.8;
		z-index: 1;
	}

	.welcome-text {
		position: relative;
		max-width: 45rem;
		margin: 0;
		font-size: clamp(2rem, 4vw, 3.5rem);
		font-weight: 700;
		line-height: 1.1;
		letter-spacing: -0.075rem;
		z-index: 1;
	}

	.welcome-subtext {
		position: relative;
		max-width: 42rem;
		margin: 1.25rem 0 0;
		font-size: 1.1rem;
		line-height: 1.7;
		opacity: 0.9;
		z-index: 1;
	}

	.welcome-actions {
		position: relative;
		display: flex;
		align-items: center;
		gap: 0.75rem;
		margin-top: 1.75rem;
		z-index: 1;

		.welcome-button {
			display: inline-block;
			padding: 0.7rem 1.1rem;
			border: 1px solid transparent;
			border-radius: 0.375rem;
			font-weight: 500;
			line-height: 1.5;
			text-decoration: none;
			transition:
				color 0.15s ease-in-out,
				background-color 0.15s ease-in-out,
				border-color 0.15s ease-in-out,
				box-shadow 0.15s ease-in-out;

			&.primary {
				color: #084298;
				background-color: #fff;
				border-color: #fff;

				&:hover,
				&:focus-visible {
					color: #052c65;
					background-color: #e9ecef;
					border-color: #e9ecef;
				}
			}

			&.secondary {
				color: #fff;
				background-color: transparent;
				border-color: rgba(255, 255, 255, 0.65);

				&:hover,
				&:focus-visible {
					color: #084298;
					background-color: #fff;
					border-color: #fff;
				}
			}

			&:focus-visible {
				outline: 0;
				box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.3);
			}
		}
	}
}

/* Features */
.features-box {
	margin: 2rem 0;
	background-color: #fff;
	border: 1px solid #dee2e6;
	border-radius: 0.5rem;
	box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
	overflow: hidden;

	.features-title {
		padding: 2rem;
		text-align: center;
		background-color: #f8f9fa;
		border-bottom: 1px solid #dee2e6;

		.h1 {
			margin: 0;
			color: #212529;
			font-size: 2rem;
			font-weight: 600;
			line-height: 1.2;
		}

		.h2 {
			max-width: 42rem;
			margin: 0.5rem auto 0;
			color: #6c757d;
			font-size: 1rem;
			font-weight: 400;
			line-height: 1.6;
		}
	}

	.features-tiles {
		display: grid;
		grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
		gap: 1rem;
		padding: 1rem;

		.features-tiles-box {
			position: relative;
			padding: 1.5rem;
			background-color: #fff;
			border: 1px solid #dee2e6;
			border-top: 0.25rem solid #0d6efd;
			border-radius: 0.375rem;
			box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.05);
			overflow: hidden;
			transition:
				border-color 0.15s ease-in-out,
				box-shadow 0.15s ease-in-out;

			&:hover {
				border-color: #86b7fe;
				border-top-color: #0d6efd;
				box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
			}

			.features-tiles-box-label {
				display: inline-block;
				padding: 0.25rem 0.5rem;
				margin: 0 0 1rem;
				color: #084298;
				background-color: #cfe2ff;
				border-radius: 50rem;
				font-size: 0.75rem;
				font-weight: 600;
				letter-spacing: 0.05rem;
				text-transform: uppercase;
			}

			.features-tiles-box-title {
				margin: 0;
				color: #212529;
				font-size: 1.25rem;
				font-weight: 600;
				line-height: 1.3;
			}

			.features-tiles-box-description {
				margin: 0.75rem 0 0;
				color: #6c757d;
				font-size: 0.95rem;
				line-height: 1.65;
			}
		}
	}
}

/* News */
.news-box {
	width: 100%;
	margin: 0;
	background-color: #fff;
	border: 1px solid #dee2e6;
	border-radius: 0.5rem;
	box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
	overflow: hidden;

	.news-title {
		padding: 1.5rem;
		text-align: center;
		background-color: #f8f9fa;
		border-bottom: 1px solid #dee2e6;

		.h1 {
			margin: 0;
			color: #212529;
			font-size: 2rem;
			font-weight: 600;
			line-height: 1.2;
		}

		.h2 {
			margin: 0.35rem 0 0;
			color: #6c757d;
			font-size: 1rem;
			font-weight: 400;
			line-height: 1.5;
		}
	}

	.news-tiles {
		display: flex;
		flex-flow: row wrap;
		gap: 1rem;
		padding: 1rem;

		.news-tiles-box {
			position: relative;
			width: 100%;
			padding: 1.25rem;
			background-color: #fff;
			border: 1px solid #dee2e6;
			border-radius: 0.375rem;
			box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
			overflow: hidden;
			transition:
				border-color 0.15s ease-in-out,
				box-shadow 0.15s ease-in-out,
				transform 0.15s ease-in-out;

			&:hover {
				border-color: #adb5bd;
				box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
			}

			.news-tiles-box-title {
				margin: 0;
				color: #212529;
				font-size: 1.5rem;
				font-weight: 600;
				line-height: 1.25;
			}

			.news-tiles-box-metadata {
				margin: 0.35rem 0 0;
				color: #6c757d;
				font-size: 0.875rem;
				line-height: 1.5;

				a {
					color: #0d6efd;
					text-decoration: none;

					&:hover,
					&:focus-visible {
						color: #0a58ca;
						text-decoration: underline;
					}

					&:focus-visible {
						outline: 0.2rem solid rgba(13, 110, 253, 0.25);
						outline-offset: 0.125rem;
					}
				}
			}

			.news-tiles-box-message {
				padding-top: 1rem;
				margin-top: 1rem;
				color: #212529;
				font-size: 1rem;
				line-height: 1.6;
				border-top: 1px solid #dee2e6;

				p {
					margin: 0 0 1rem;

					&:last-child {
						margin-bottom: 0;
					}
				}
			}
		}
	}
}

/* Userpage */
.userpage {
	position: relative;
	width: min(100%, 75rem);
	margin: 2rem auto;
	background-color: #f8f9fa;
	border-radius: 0.5rem;
	box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.075);

	.userpage-header {
		position: relative;
		height: 15rem;

		.userpage-banner {
			display: block;
			width: 100%;
			height: 100%;
			background-color: #0d6efd;
			object-fit: cover;
			object-position: center;
			border-radius: 0.5rem 0.5rem 0 0;
		}

		&::after {
			content: '';
			position: absolute;
			inset: 0;
			background:
				linear-gradient(
					90deg,
					rgba(13, 110, 253, 0.25),
					rgba(8, 66, 152, 0.55)
				);
			border-radius: 0.5rem 0.5rem 0 0;
			pointer-events: none;
		}

		.userpage-avatar {
			position: absolute;
			bottom: -1.5rem;
			left: 2rem;
			z-index: 2;
			display: flex;
			align-items: center;
			justify-content: center;
			width: 9rem;
			height: 9rem;
			color: #adb5bd;
			background-color: #495057;
			border: 0.3rem solid #fff;
			border-radius: 0.5rem;
			box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.3);
			overflow: hidden;

			svg {
				display: block;
				width: 4rem;
				height: 4rem;
			}

			img {
				display: block;
				width: 100%;
				height: 100%;
				object-fit: cover;
				object-position: center;
			}
		}
		
		.userpage-title {
			position: absolute;
			right: 2rem;
			bottom: 3.95rem;
			left: 12rem;
			z-index: 2;
			width: fit-content;
			padding: 0 0.2rem 0.25rem;
			color: #fff;
			background-color: rgba(0, 0, 0, 0.4);
			border-left: 0.25rem solid #fff;
			font-size: 1rem;
			text-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.75);
			font-variant: small-caps;
			letter-spacing: -0.02em;
		}

		.userpage-name {
			position: absolute;
			right: 2rem;
			bottom: 1.5rem;
			left: 12rem;
			z-index: 2;
			width: fit-content;
			margin: 0;
			color: #fff;
			font-size: 2rem;
			font-weight: 600;
			line-height: 1.2;
			text-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.85);
			overflow-wrap: anywhere;
		}
	}

	.userpage-profile {
		display: grid;
		grid-template-columns: minmax(0, 2fr) minmax(16rem, 1fr);
		gap: 2rem;
		min-height: 10rem;
		padding: 3.5rem 2rem 2rem;
		background-color: #f8f9fa;
		border-radius: 0 0 0.5rem 0.5rem;

		.userpage-about {
			padding: 1.5rem;
			background-color: #fff;
			border: 1px solid #dee2e6;
			border-radius: 0.375rem;
			box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.04);

			h3 {
				margin: 0 0 1rem;
				color: #212529;
				font-size: 1.25rem;
				font-weight: 600;
			}

			p {
				margin: 0;
				color: #6c757d;
				line-height: 1.6;
			}
		}

		.userpage-details {
			display: flex;
			flex-direction: column;
			gap: 0.75rem;
			margin: 0;

			.userpage-detail {
				padding: 1rem;
				background-color: #fff;
				border: 1px solid #dee2e6;
				border-radius: 0.375rem;
				box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.04);

				dt {
					margin-bottom: 0.25rem;
					color: #6c757d;
					font-size: 0.75rem;
					font-weight: 600;
					letter-spacing: 0.04em;
					text-transform: uppercase;
				}

				dd {
					margin: 0;
					color: #212529;
					font-weight: 500;
				}
			}
		}
	}
}

/* Login */
.login-box {
	width: min(100%, 32rem);
	margin: 2rem auto;
	background-color: #fff;
	border: 1px solid #dee2e6;
	border-radius: 0.5rem;
	box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.075);
	overflow: hidden;

	.login-box-header {
		padding: 1.5rem;
		text-align: center;
		background-color: #f8f9fa;
		border-bottom: 1px solid #dee2e6;

		.login-box-title {
			margin: 0;
			color: #212529;
			font-size: 1.5rem;
			font-weight: 600;
			line-height: 1.25;
		}

		.login-box-description {
			margin: 0.5rem 0 0;
			color: #6c757d;
			font-size: 0.95rem;
			line-height: 1.5;
		}
	}

	.alert {
		margin: 1rem 1.5rem 0;
	}

	.login-form {
		padding: 1.5rem;

		.login-field {
			margin-bottom: 1.25rem;

			label {
				display: block;
				margin-bottom: 0.5rem;
				color: #212529;
				font-size: 0.95rem;
				font-weight: 500;
			}

			input {
				display: block;
				width: 100%;
				padding: 0.75rem;
				color: #212529;
				background-color: #fff;
				background-clip: padding-box;
				border: 1px solid #ced4da;
				border-radius: 0.375rem;
				font: inherit;
				line-height: 1.5;
				transition:
					border-color 0.15s ease-in-out,
					box-shadow 0.15s ease-in-out;

				&::placeholder {
					color: #6c757d;
					opacity: 0.75;
				}

				&:hover {
					border-color: #adb5bd;
				}

				&:focus {
					border-color: #86b7fe;
					outline: 0;
					box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
				}
			}
		}

		.login-actions {
			display: flex;
			justify-content: flex-end;

			.login-button {
				display: inline-block;
				padding: 0.65rem 1.25rem;
				color: #fff;
				background-color: #0d6efd;
				border: 1px solid #0d6efd;
				border-radius: 0.375rem;
				font: inherit;
				font-weight: 500;
				line-height: 1.5;
				text-align: center;
				cursor: pointer;
				transition:
					background-color 0.15s ease-in-out,
					border-color 0.15s ease-in-out,
					box-shadow 0.15s ease-in-out;

				&:hover {
					background-color: #0b5ed7;
					border-color: #0a58ca;
				}

				&:focus-visible {
					outline: 0;
					box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
				}

				&:active {
					background-color: #0a58ca;
					border-color: #0a53be;
				}
			}
		}
	}

	.login-box-footer {
		padding: 1rem 1.5rem;
		color: #6c757d;
		background-color: #f8f9fa;
		border-top: 1px solid #dee2e6;
		font-size: 0.875rem;
		text-align: center;

		p {
			margin: 0;
		}
	}
}

/* Footer */
.footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 2rem;
	padding: 1rem max(1rem, calc((100% - 75rem) / 2));
	color: #6c757d;
	background-color: #f8f9fa;
	border-top: 1px solid #dee2e6;

	.copyright,
	.footer-links {
		margin: 0;
	}

	.footer-links {
		display: flex;
		align-items: center;
		gap: 0.5rem;

		a {
			color: #495057;
			text-decoration: none;
			transition: color 0.15s ease-in-out;

			&:not(:last-child)::after {
				content: "|";
				margin-left: 0.5rem;
				color: #adb5bd;
			}

			&:hover,
			&:focus-visible {
				color: #0d6efd;
				text-decoration: underline;
			}

			&:focus-visible {
				outline: 0.2rem solid rgba(13, 110, 253, 0.25);
				outline-offset: 0.125rem;
			}
		}
	}
}

/* Alert Boxes */
.alert {
	position: relative;
	padding:  0.5rem 1rem;
	margin: 0.75rem 0;
	color: #212529;
	background-color: #fff;
	border: 1px solid transparent;
	border-left-width: 0.3rem;
	border-radius: 0.375rem;
	line-height: 1.5;

	a,
	a:visited {
		color: inherit;
		font-weight: 500;
		text-decoration: underline;
	}

	&.success {
		color: #0f5132;
		background-color: #d1e7dd;
		border-color: #badbcc;
		border-left-color: #198754;

		a:hover {
			color: #0a3622;
		}
	}

	&.info {
		color: #084298;
		background-color: #cfe2ff;
		border-color: #b6d4fe;
		border-left-color: #0d6efd;

		a:hover {
			color: #052c65;
		}
	}

	&.warning {
		color: #7a3e00;
		background-color: #ffe5bf;
		border-color: #ffd08a;
		border-left-color: #fd7e14;

		a:hover {
			color: #522900;
		}
	}

	&.error {
		color: #842029;
		background-color: #f8d7da;
		border-color: #f5c2c7;
		border-left-color: #dc3545;

		a:hover {
			color: #58151c;
		}
	}
	
	&.note {
		color: #055160;
		background-color: #cff4fc;
		border-color: #b6effb;
		border-left-color: #0dcaf0;

		a:hover {
			color: #033c47;
		}
	}
}