/* =========================================================
   MEGA MENU DA LOJA
   Painel escuro com as categorias, preso ao item "Loja" do menu
   principal. Montado em includes/mega-menu-loja.php.
   Abre com hover e com foco de teclado, sem JS.
   ========================================================= */

.elementor-nav-menu--main .asy-mega {
	position: relative;
}

/* Na tela do menu horizontal (desktop) o painel fica escondido ate o hover.
   O padding-top e a ponte invisivel entre a palavra e a caixa: o mouse
   atravessa sem o painel fechar. */
.asy-mega__painel {
	position: absolute;
	top: 100%;
	left: -22px;
	z-index: 120;
	padding-top: 14px;
	width: min(560px, calc(100vw - 32px));
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	pointer-events: none;
	transition:
		opacity 180ms cubic-bezier(.22,.61,.36,1),
		transform 180ms cubic-bezier(.22,.61,.36,1),
		visibility 0s linear 180ms;
}

.asy-mega:hover > .asy-mega__painel,
.asy-mega:focus-within > .asy-mega__painel {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
	pointer-events: auto;
	transition-delay: 0s;
}

/* A palavra "Loja" continua acesa e sublinhada enquanto o painel esta aberto. */
.asy-header__menu.elementor-widget-nav-menu .elementor-nav-menu--main li.asy-mega:is(:hover, :focus-within) > a.elementor-item {
	color: var(--asy-cyan, #00E5FF);
}

.asy-header__menu .elementor-nav-menu--main li.asy-mega:is(:hover, :focus-within) > a.elementor-item::after {
	opacity: 1 !important;
}

.asy-mega__caixa {
	position: relative;
	padding: 10px;
	border: 1px solid rgba(139, 61, 255, .28);
	border-radius: 18px;
	background:
		radial-gradient(120% 70% at 0% 0%, rgba(139, 61, 255, .16), transparent 60%),
		radial-gradient(90% 60% at 100% 100%, rgba(255, 46, 154, .09), transparent 60%),
		var(--asy-black-2, #0F0B1C);
	box-shadow:
		0 28px 60px -12px rgba(0, 0, 0, .7),
		0 0 0 1px rgba(0, 0, 0, .4),
		inset 0 1px 0 rgba(255, 255, 255, .04);
}

/* Fio de luz no topo, o mesmo do cabecalho. */
.asy-mega__caixa::before {
	content: '';
	position: absolute;
	inset: 0 18px auto;
	height: 1px;
	background: linear-gradient(90deg, transparent, var(--asy-pink, #FF2E9A), var(--asy-purple, #8B3DFF), transparent);
	opacity: .8;
}

/* Os seletores levam .elementor-nav-menu--main .elementor-nav-menu na frente
   para ganhar das regras de submenu do widget (ul absoluto de 12em, links com
   padding 13px 20px). */
.elementor-nav-menu--main .elementor-nav-menu ul.asy-mega__grade {
	position: static;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 2px;
	width: auto;
	margin: 0;
	padding: 0;
	border: 0;
	list-style: none;
}

/* Numero impar de categorias: a ultima ocupa a linha inteira. */
.asy-mega__grade > li:last-child:nth-child(odd) {
	grid-column: 1 / -1;
}

.elementor-nav-menu--main .elementor-nav-menu .asy-mega__grade li > a.asy-mega__item {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 10px 12px;
	line-height: 1.25;
	white-space: normal;
	border-radius: 12px;
	color: var(--asy-white, #F5F2FB);
	text-decoration: none;
	transition: background-color 180ms ease;
}

.asy-mega__item:hover,
.asy-mega__item:focus-visible {
	background: rgba(139, 61, 255, .13);
	outline: none;
}

.asy-mega__item:focus-visible {
	box-shadow: inset 0 0 0 1px rgba(0, 229, 255, .6);
}

.asy-mega__icone {
	display: grid;
	flex: 0 0 auto;
	place-items: center;
	width: 42px;
	height: 42px;
	border: 1px solid rgba(139, 61, 255, .3);
	border-radius: 11px;
	background: rgba(139, 61, 255, .14);
	color: #C7A6FF;
	transition: background 180ms ease, color 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.asy-mega__icone svg {
	display: block;
}

.asy-mega__item:hover .asy-mega__icone,
.asy-mega__item:focus-visible .asy-mega__icone {
	border-color: transparent;
	background: var(--asy-grad-brand, linear-gradient(135deg, #FF2E9A 0%, #8B3DFF 100%));
	color: #fff;
	box-shadow: 0 0 22px rgba(255, 46, 154, .38);
}

.asy-mega__texto {
	display: flex;
	min-width: 0;
	flex-direction: column;
	gap: 2px;
}

.asy-mega__nome {
	font-family: var(--font-body, 'Space Grotesk', system-ui, sans-serif);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: 0;
	text-transform: none;
}

.asy-mega__apoio {
	overflow: hidden;
	font-family: var(--font-body, 'Space Grotesk', system-ui, sans-serif);
	font-size: 12.5px;
	font-weight: 400;
	line-height: 1.3;
	letter-spacing: 0;
	text-transform: none;
	white-space: nowrap;
	text-overflow: ellipsis;
	color: var(--asy-muted, #A79FC0);
}

.elementor-nav-menu--main .elementor-nav-menu .asy-mega__caixa > a.asy-mega__todos {
	line-height: 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-top: 8px;
	padding: 14px 12px 6px;
	border-top: 1px solid rgba(139, 61, 255, .2);
	border-radius: 0;
	font-family: var(--font-body, 'Space Grotesk', system-ui, sans-serif);
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0;
	text-transform: none;
	color: #C7A6FF;
	text-decoration: none;
	transition: color 180ms ease;
}

.asy-mega__todos svg {
	transition: transform 180ms ease;
}

.asy-mega__todos:hover,
.asy-mega__todos:focus-visible {
	color: var(--asy-pink, #FF2E9A);
	outline: none;
}

.asy-mega__todos:hover svg,
.asy-mega__todos:focus-visible svg {
	transform: translateX(4px);
}

/* O dropdown do celular nao recebe o painel; por garantia, nunca mostra. */
.elementor-nav-menu--dropdown .asy-mega__painel {
	display: none;
}

/* =========================================================
   MENU SANDUICHE (tablet e celular)
   O dropdown vira um painel escuro na largura toda, logo abaixo do
   cabecalho, e as categorias aparecem em grade embaixo de "Produtos".
   Sem isto o Elementor abria uma coluna de 116px dentro da barra, em
   fundo branco, empurrando a marca.
   ========================================================= */

@media (max-width: 1024px) {

	/* O widget deixa de ser a referencia: a barra (relative, largura toda) passa a ser. */
	.asy-header .asy-header__menu {
		position: static !important;
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown.elementor-nav-menu__container {
		position: absolute;
		top: 100%;
		right: 0;
		left: 0;
		z-index: 110;
		width: auto;
		margin-top: 0;
		border-bottom: 1px solid rgba(139, 61, 255, .28);
		background:
			radial-gradient(90% 50% at 100% 0%, rgba(139, 61, 255, .14), transparent 60%),
			var(--asy-black-2, #0F0B1C);
		box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8);
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown > .elementor-nav-menu {
		padding: 6px 20px 18px;
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .elementor-nav-menu > li > a.elementor-item {
		justify-content: flex-start;
		padding: 16px 0;
		border: 0;
		border-bottom: 1px solid rgba(139, 61, 255, .16);
		background: transparent;
		font-family: var(--font-display, 'Archivo Black', system-ui, sans-serif);
		font-size: 16px;
		font-weight: 400;
		line-height: 1.2;
		letter-spacing: .03em;
		text-transform: uppercase;
		color: var(--asy-white, #F5F2FB);
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .elementor-nav-menu > li:last-child > a.elementor-item {
		border-bottom: 0;
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .elementor-nav-menu > li > a.elementor-item:is(:hover, :focus-visible) {
		background: transparent;
		color: var(--asy-cyan, #00E5FF);
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .elementor-nav-menu > li > a.elementor-item.elementor-item-active {
		color: var(--asy-pink, #FF2E9A);
	}

	/* "Produtos" encosta na grade das categorias; a linha divisoria fica embaixo dela. */
	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .elementor-nav-menu > li.asy-mega-celular > a.elementor-item {
		padding-bottom: 12px;
		border-bottom: 0;
	}

	.asy-mega-celular__grade {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 8px;
		padding-bottom: 16px;
		border-bottom: 1px solid rgba(139, 61, 255, .16);
	}

	/* Numero impar de categorias: a ultima ocupa a linha inteira. */
	.asy-mega-celular__grade > a:last-child:nth-child(odd) {
		grid-column: 1 / -1;
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .asy-mega-celular__grade a.asy-mega-celular__link {
		display: flex;
		align-items: center;
		justify-content: flex-start;
		gap: 10px;
		min-width: 0;
		padding: 8px 10px 8px 8px;
		border: 1px solid rgba(139, 61, 255, .22);
		border-radius: 12px;
		background: rgba(139, 61, 255, .08);
		font-family: var(--font-body, 'Space Grotesk', system-ui, sans-serif);
		font-size: 14px;
		font-weight: 600;
		line-height: 1.2;
		letter-spacing: 0;
		text-transform: none;
		white-space: normal;
		text-decoration: none;
		color: var(--asy-white, #F5F2FB);
		transition: background-color 160ms ease, border-color 160ms ease;
	}

	.asy-header .asy-header__menu .elementor-nav-menu--dropdown .asy-mega-celular__grade a.asy-mega-celular__link:is(:hover, :focus-visible, :active) {
		border-color: rgba(0, 229, 255, .45);
		background: rgba(139, 61, 255, .16);
		color: var(--asy-white, #F5F2FB);
		outline: none;
	}

	.asy-mega-celular__link .asy-mega__icone {
		width: 36px;
		height: 36px;
		border-radius: 9px;
	}

	.asy-mega-celular__link .asy-mega__icone svg {
		width: 19px;
		height: 19px;
	}

	.asy-mega-celular__link:is(:hover, :focus-visible, :active) .asy-mega__icone {
		border-color: transparent;
		background: var(--asy-grad-brand, linear-gradient(135deg, #FF2E9A 0%, #8B3DFF 100%));
		color: #fff;
	}

	.asy-mega-celular__nome {
		min-width: 0;
		overflow-wrap: anywhere;
	}
}

/* Desktop: o dropdown nem aparece, mas por garantia a grade tambem nao. */
@media (min-width: 1025px) {
	.asy-mega-celular__grade { display: none; }
}
