/* Offscreen Menu
--------------------------------------------- */

/* Header Placement */
.site-header-main-section-right {
	display: flex;
	align-items: center;
}

.brioche-offscreen-toggle-wrap {
	display: flex;
	align-items: center;
	flex: 0 0 auto;
	margin-left: 46px;
	margin-right: 0 !important;
}

/* Offscreen Menu Toggle */
#brioche-offscreen-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: auto;
	padding: 0;
	margin: 0;
	color: var(--global-palette3);
	background: transparent !important;
	border: 0;
	border-radius: 0 !important;
	box-shadow: none;
	cursor: pointer;
	appearance: none;
}

#brioche-offscreen-toggle:hover,
#brioche-offscreen-toggle:focus,
#brioche-offscreen-toggle:focus-visible,
#brioche-offscreen-toggle:active {
	color: var(--global-palette2);
	background: transparent !important;
	border: 0;
	box-shadow: none;
}

#brioche-offscreen-toggle svg {
	display: block;
	width: 22px;
	height: auto;
}

#brioche-offscreen-toggle svg rect {
	fill: currentColor;
	transition: fill 0.2s ease-in-out;
}

/* Offscreen Menu Area */
#brioche-offscreen-area {
	position: fixed;
	inset: 0;
	z-index: 999999;
	visibility: hidden;
	pointer-events: none;
	transition: visibility 0s linear 0.75s;
}

#brioche-offscreen-area.open {
	visibility: visible;
	pointer-events: auto;
	transition-delay: 0s;
}

/* Offscreen Overlay */
#brioche-offscreen-area .brioche-offscreen-overlay,
#brioche-offscreen-area .brioche-offscreen-overlay:hover,
#brioche-offscreen-area .brioche-offscreen-overlay:focus,
#brioche-offscreen-area .brioche-offscreen-overlay:focus-visible,
#brioche-offscreen-area .brioche-offscreen-overlay:active {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	padding: 0;
	margin: 0;
	background: rgba(0, 0, 0, 0.35) !important;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	opacity: 0;
	cursor: pointer;
	appearance: none;
	transition: opacity 0.75s ease;
}

#brioche-offscreen-area.open .brioche-offscreen-overlay {
	opacity: 1;
}

/* Offscreen Menu Panel */
.brioche-offscreen-menu {
	position: absolute;
	top: 0;
	right: 0;
	width: 22%;
	min-width: 420px;
	height: 100%;
	padding: 0 2.5rem;
	overflow-y: auto;
	background-color: #f9f7f6;
	text-align: center;
	transform: translateX(100%);
	transition: transform 0.75s cubic-bezier(0.25, 0.8, 0.25, 1);
}

#brioche-offscreen-area.open .brioche-offscreen-menu {
	transform: translateX(0);
}

.brioche-offscreen-menu .brioche-2-column-nav .kb-navigation{
	display: grid !important;
	grid-template-columns: repeat(2, 1fr);
	column-gap: 30px;
	width: 100%;
}

.brioche-offscreen-categories .kb-section-has-link {
    opacity: 1 !important;
}

.brioche-offscreen-categories img,
.brioche-offscreen-categories .kb-section-has-link .wp-block-kadence-advancedheading{
    -webkit-transition: all .25s ease-in-out;
    -moz-transition: all .25s ease-in-out;
    -ms-transition: all .25s ease-in-out;
    -o-transition: all .25s ease-in-out;
    transition: all .25s ease-in-out;
}

.brioche-offscreen-categories .kb-section-has-link:hover img {
    opacity: .75 !important;
}

.brioche-offscreen-categories .kb-section-has-link:hover .wp-block-kadence-advancedheading {
    color: var(--global-palette-highlight-alt);
}

/* Offscreen Menu Close Button */
.brioche-offscreen-close,
.brioche-offscreen-close:hover,
.brioche-offscreen-close:focus,
.brioche-offscreen-close:focus-visible,
.brioche-offscreen-close:active {
	display: flex;
	align-items: center;
	justify-content: center;
	width: auto;
	height: 36px;
	padding: 0;
	margin: 1.25rem 0 0 auto;
	color: var(--global-palette3);
	background: transparent !important;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	cursor: pointer;
	appearance: none;
}

.brioche-offscreen-close:hover,
.brioche-offscreen-close:focus-visible {
	color: var(--global-palette2);
}

.brioche-offscreen-close svg {
	display: block;
	fill: currentColor;
	transition: fill 0.2s ease-in-out;
}

/* Offscreen Menu Content */
.brioche-offscreen-inner {
	padding: .2rem 0 4rem;
}

/* Prevent Page Scrolling While Open */
body.brioche-offscreen-open {
	overflow: hidden;
}

/* WordPress Admin Bar */
.admin-bar .brioche-offscreen-menu {
	top: 32px;
	height: calc(100% - 32px);
}

/* Kadence Navigation Submenus */
.brioche-offscreen-menu .wp-block-kadence-navigation-link .kb-nav-sub-menu {
	max-height: 0;
	overflow: hidden;
	opacity: 0;
	transform: translateY(-6px);
	transition:
		max-height 0.75s cubic-bezier(0.25, 0.8, 0.25, 1),
		opacity 0.55s ease,
		transform 0.55s ease;
}

.brioche-offscreen-menu .wp-block-kadence-navigation-link.menu-item--toggled-on > .kb-nav-sub-menu {
	max-height: 1000px;
	opacity: 1;
	transform: translateY(0);
}

.brioche-offscreen-menu .kb-nav-dropdown-toggle-btn svg {
	transition: transform 0.55s ease;
}

/* Mobile */
@media (max-width: 782px) {
	.admin-bar .brioche-offscreen-menu {
		top: 46px;
		height: calc(100% - 46px);
	}
}

@media (max-width: 600px) {
	.admin-bar .brioche-offscreen-menu {
		top: 0;
		height: 100%;
	}

	.brioche-offscreen-menu {
		width: 100%;
		min-width: 0;
		padding-right: 1.5rem;
		padding-left: 1.5rem;
	}
}