:root {
	--max-page-width: 1280px;
}

* {
	box-sizing: border-box;
}

body {
	display: flex;
	flex-flow: column;
	justify-content: center;
	align-items: center;
	min-height: 100vh;
	font-family: PulpDisplay, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;
	font-size: 14px;
	width: 100%;
}

a {
	text-decoration: none;
	color: black;
}

img {
	object-fit: contain;
	object-position: center;
	width: 100%;
	max-height: 100%;
	user-select: none;
	border: 1px solid var(--border-main-clr);
	background-color: white;
}

main {
	max-width: var(--max-page-width);
	width: 100%;
	padding: 2% 4% 0%;
	flex: 1;
}

button {
	display: inline-block;
	position: relative;
	font-size: 12px;
	white-space: nowrap;
	border-radius: .25em;
}

/* Chrome, Safari, Edge, Opera */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

/* Firefox */
input[type=number] {
	-moz-appearance: textfield;
}

.hidden {
	display: none !important;
}

.button {
	color: white;
	background-color: black;
	border: 2px solid black;
	font-size: 16px;
	padding: .5rem;
	cursor: pointer;
	border-radius: 0;
	width: 100%;
	margin: .5rem 0;
	text-align: center;
	text-transform: uppercase;
}

.button:hover {
	background-color: white;
	color: black;
}

.button-secondary {
	color: black;
	background-color: white;
	border: 2px solid black;
}

input,
select {
	border: 1px solid #ddd;
	line-height: 1.5rem;
	padding: .65rem;
	margin: .25rem 0;
	font-size: 16px;
	background-color: white;
	width: 100%;
}


/* HEADER */
.header {
	display: flex;
	flex-direction: column;
	align-items: center;
	position: sticky;
	top: 0;
	z-index: 10;
	background-color: white;
	width: 100%;
}

.header-first-line {
	align-items: center;
	display: grid;
	grid-template-columns: 1fr 2fr 1fr;
	padding-top: 2rem;
}

.logo img {
	max-height: 150px;
}

.icons {
	display: flex;
	align-items: center;
	gap: .5rem;
	position: relative;
}

.search-wrapper {
	position: relative;
}

.search-wrapper input::placeholder {
	font-style: italic;
	color: #cccccc;
}

.input-container {
	display: flex;
	align-items: center;
}

.input-container input {
	display: inline;
	height: 2em;
	font-size: 1em;
	border: 1px solid #cfcfcf;
	outline: none;
}

.search-autocomplete-result {
	position: absolute;
	border: 1px solid #ddd;
	left: 0;
	width: 100%;
  	top: 2.25em;
	background-color: #fff;
	z-index: 10;
}

.search-autocomplete-result>a {
	display: flex;
	align-items: center;
	gap: 10px;
	border-bottom: 1px solid #eee;
	padding: .6em;
	color: var(--color-black);
	text-decoration: none;
	background-color: #fff;
}

.cart-icon, .login-icon {
	position: relative;
	display: flex;
	align-items: center;
	cursor: pointer;
}

.user-icon svg,
.cart-icon svg,
.login-icon svg,
.input-icon svg {
	width: 24px;
	height: 24px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.logged-user-wrapper {
	position: relative;
}

.user-icon {
	cursor: pointer;
}

.logged-user-menu {
	display: none;
	flex-direction: column;
	position: absolute;
	right:0;
	border: 1px solid #ccc;
	padding: .5rem;
	background-color: white;
	z-index: 5;
}

.logged-user-menu button {
	background-color: white;
	border: none;
	margin: 0;
	padding: 0;
}

.logged-user-menu a, .logged-user-menu button {
	font-size: 14px;
	color: #636161;
	width: 100%;
	min-width: 100px;
}

.logged-user-menu a:hover,
.logged-user-menu button:hover {
	color: black;
	cursor: pointer;
}

.header-first-line-mobile {
	display: none;
	width: 100%;
}

.header-second-line {
	display: flex;
	width: 100%;
	position: relative;
	min-height: 2rem;
	justify-content: center;
}

.header-second-line * {
	text-transform: uppercase;
}

.showToggle::after {
	display: inline-block;
	margin-left: .255em;
	vertical-align: .255em;
	content: "";
	border-top: .3em solid;
	border-right: .3em solid transparent;
	border-bottom: 0;
	border-left: .3em solid transparent;
}

.groups {
	display: flex;
	gap: 2rem;
	margin: 1rem 0;
}

.header-second-line-mobile-search {
	display: none;
}

@media only screen and (max-width: 630px) {
	.header-first-line {
		display: none;
	}
	
	.header-first-line-mobile {
		display: flex;
		justify-content: center;
		padding: 0 1rem;
	}

	.groups {
		display: none;
		flex-direction: column;
	}

	.header-second-line-mobile-search {
		display: flex;
		width: 100%;
		padding: 1rem 3rem 0;
	}

	.header-second-line-mobile-search>form {
		width: 100%;
	}


}

/* FOOTER */
.footer {
	display: flex;
	justify-content: center;
	width: 100%;
	margin-top: 2rem;
	padding: 2rem;
	border-top: 1px solid #ddd;
	gap: 5rem;
}
