@use "../../scss/abstracts/colors" as *;
@use "../../scss/abstracts/fonts" as *;

#navbar-container {
	clear: both;
	display: block;
}

nav {
	position: fixed;
	z-index: 1;
	margin: 0;
	width: 100vw;
	padding: 0;
	height: 4.5rem;
	display: flex;
	align-items: center;

	.details {
		align-items: flex-start;
		margin-left: 1.5rem;
		color: $dark;

		& > a:first-of-type {
			margin: 0;
			font-size: 1.2rem;
		}

		& > a:last-of-type {
			margin: 0 1.5rem;
			font-size: 1.2rem;
		}
	}

.title-and-menu {
	margin: 0 auto;

		#navbar-title {
			font-family: "Cutive Mono";
			font-size: 2.5rem;
			font-weight: bold;
			color: $dark;
			margin: 0;

			span {
				margin: 0;
				padding: 0;
			}
		}
	
	.menu-toggle-container {
		display: none;
	}
}
	#contact-btn {
		margin-right: 1.5rem;
		padding-left: 99px;

		button {
			background: $primary;
			color: white;
			border: none;
			transition: all 300ms ease-in-out;
		}

		&:hover,
		&:focus {
			button {
				border: none;
				box-shadow: 0 0 2px 1px $primary;
			}
		}
	}
}

@media screen and (max-width: 800px) {
	#navbar-container {
		position: fixed;
		top: 0;
		right: 0;
		left: 0;
		z-index: 1312;
		position: relative;
		display: flex;
		flex-wrap: wrap;
		align-items: center;
		justify-content: space-between;
	}

	nav {
		width: 100%;
		padding-right: var(--bs-gutter-x, 0.75rem);
		padding-left: var(--bs-gutter-x, 0.75rem);
		margin: 4rem auto 0 auto;
		display: flex;
		flex-direction: column-reverse;
		align-items: center;
	}
	
	
	.details {
		position: absolute;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: flex-end;
		top: 5rem;

		.menu-item-hidden {
			display: none;
		}
	}

	.details-open {
		position: absolute;
		display: flex;
		flex-direction: column;
		align-items:center;
		top: 4.5rem;
		background-color: white;
		width: 100%;

		.menu-item {
			width: 100%;
			line-height: 2.5rem;
			display: flex;
			justify-content: center;

			&:hover, &:focus{
				background-color: $light;
			}
		}
	}

	.title-and-menu {
		margin-left: .5rem;
		display: flex;
		width: 100%;
		z-index: 2;

		button.menu-toggle-container {
			display: inline-block;
			margin-left: auto;
			margin-right: 1.5rem;
			padding: 0.25rem 0.75rem;
			font-size: 1.25rem;
			line-height: 1;
			background-color: transparent;
			border: 1px solid transparent;
			border-radius: 0.25rem;
			transition: box-shadow 0.15s ease-in-out;

			&:hover, &:focus {
				cursor: pointer;
				box-shadow: 0 0 1px 1px $dark;
			}
		}
	}

	#contact-btn {
		display: none;
	}
}
