/* ============================================================
   LQ Mega Menu (lqmm) — styles
   Lives inside an Elementor popup, which aggressively styles
   buttons/links. Two defences are used:
     1) element resets via :where() = ZERO specificity, so the
        component classes below always win (fixes the collapsed
        "tiny chip" padding bug).
     2) !important on the few structural/visual properties that
        Elementor's popup kit overrides (background, padding,
        and the back/chevron display toggles).
   Brand red uses the site token with a hard fallback.
   ============================================================ */

.lqmm {
	--lqmm-red: var(--primary-red, #CF1212);
	--lqmm-soft: #f4f5f6;
	--lqmm-line: #e4e4e4;
	--lqmm-ink: #171717;
	--lqmm-ink-2: #4a4d52;
	--lqmm-ink-3: #8a8e95;
	--lqmm-radius: 12px;

	
	display: grid;
	grid-template-columns: 248px 1fr;
	gap: 0;
	width: 100% !important;
	min-width: 100% !important;
	margin: 0 auto;
	color: var(--lqmm-ink);
	font-family: Miranda Sans !important;
	text-align: left;
}

/* zero-specificity resets so component classes below always win */
.lqmm :where(a) { text-decoration: none; color: inherit; }
.lqmm :where(button) {
	font: inherit; color: inherit; background: none; border: 0;
	margin: 0; padding: 0; cursor: pointer; text-align: inherit;
	-webkit-appearance: none; appearance: none;
}
.lqmm :where(img) { max-width: 100%; height: auto; display: block; }
.lqmm *, .lqmm *::before, .lqmm *::after { box-sizing: border-box; }

/* ---------- industry rail (left) ---------- */
.lqmm__rail {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 8px 14px 8px 0;
	border-right: 1px solid var(--lqmm-line);
	min-width: 0;
}

.lqmm__industry {
	white-space: unset!important;
	position: relative;
	display: flex !important;
	align-items: center;
	gap: 11px;
	width: 100% !important;
	padding: 11px 14px !important;
	border-radius: 10px !important;
	text-align: left !important;
	background: transparent !important;
	border: 1px solid transparent !important;
	color: var(--lqmm-ink-2)!important;
	font-size: 14.5px!important;
	font-weight: 500!important;
	line-height: 1.3;
	transition: background .15s ease, color .15s ease!important;
}
.lqmm__industry:hover { background: var(--lqmm-soft) !important; color: var(--lqmm-ink); }
.lqmm__industry.is-active { background: rgba(207, 18, 18, .06) !important; color: var(--lqmm-red); font-weight: 600; }
.lqmm__industry.is-active::before {
	content: "";
	position: absolute;
	left: 0; top: 8px; bottom: 8px;
	width: 3px;
	border-radius: 3px;
	background: var(--lqmm-red);
}

.lqmm__industry--all { display: none !important; }   /* desktop: redundant, hidden */
.lqmm__industry-icon {
	flex: 0 0 auto;
	width: 22px; height: 22px;
	display: flex; align-items: center; justify-content: center;
}
.lqmm__industry-icon img { width: 100%; height: 100%; object-fit: contain; }
.lqmm__industry-name { flex: 1 1 auto; min-width: 0; }
.lqmm__industry-chev { display: none; }  /* desktop: hidden */

/* ---------- panel (right) ---------- */


.lqmm__panel {
	min-width: 0;
	width: 100% !important;
	padding: 8px 4px 8px 26px;
	display: flex;
	flex-direction: column;
}

.lqmm__panel-title {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.lqmm__panel-head {
	display: block;
	align-items: center;
	margin-bottom: 14px;
}
.lqmm__back { display: none !important; }  /* desktop: hidden */
.lqmm__panel-name {
	font-size: 16px;
	font-weight: 700;
	color: var(--lqmm-ink);
	margin:0;
}
.lqmm__viewall {
	font-size: 13px;
	font-weight: 600;
	color: var(--lqmm-red);
	white-space: nowrap;
}
.lqmm__viewall:hover { text-decoration: underline; }

/* ---------- category chips ---------- */
.lqmm__cats {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 18px;
}
.lqmm__cat {
	display: inline-flex !important;
	align-items: center;
	gap: 6px;
	padding: 6px 13px !important;
	border-radius: 9999px !important;
	background: var(--lqmm-soft) !important;
	color: var(--lqmm-ink-2)!important;
	font-size: 13px!important;
	font-weight: 500!important;
	line-height: 1.2;
	transition: background .15s ease, color .15s ease!important;
	border: 1px solid var(--lqmm-soft)!important;
}
.lqmm__cat:hover { background: rgba(0, 0, 0, .08) !important; color: var(--lqmm-ink); }
.lqmm__cat.is-active { background: var(--lqmm-red) !important; color: #fff !important; }
.lqmm__cat-count {
	font-size: 11px;
	font-weight: 600;
	opacity: .6;
}
.lqmm__cat.is-active .lqmm__cat-count { opacity: .85; }



/* ---------- sub-category reveal (parent -> children) ---------- */
.lqmm__cat-sub{
	display:inline-flex;
	align-items:center;
	gap:3px;
	font-size:11px;
	font-weight:600;
	opacity:.7;
}
.lqmm__folder-ic{ width:12px; height:12px; }
.lqmm__cat.is-active .lqmm__cat-sub{ opacity:.85; }

.lqmm__subcats{
	display:flex;
	flex-wrap:wrap;
	align-items:center;
	gap:7px;
	margin:-8px 0 16px;
	padding:9px 12px;
	background:rgba(207,18,18,.05);
	border:1px solid rgba(207,18,18,.12);
	border-radius:10px;
}
.lqmm__subcats[hidden]{ display:none !important; }
.lqmm__subcat{
	padding:5px 11px !important;
	font-size:12px !important;
	background:#fff !important;
	border:1px solid var(--lqmm-line) !important;
}
.lqmm__subcat.is-active{
	background:var(--lqmm-red) !important;
	color:#fff !important;
	border-color:var(--lqmm-red) !important;
}


/* ---------- product grid ---------- */
.lqmm__grid {
	
	display: grid !important;
	grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
	width: 100% !important;
	gap: 10px !important;
}
.lqmm__product {
	display: flex !important;
	flex-direction: column !important;
	width: 100% !important;
	gap: 10px;
	border-radius: 13px;
	padding: 8px !important;
	background-color: #ffffff;
	min-width: 0;
	height: 100%;
}


.lqmm__product-img {
	position: relative !important;     /* anchor for the absolute image */
	display: block !important;
	flex: 0 0 auto !important;         /* the flex column can't compress the square */
	width: 100% !important;
	aspect-ratio: 1 / 1 !important;
	height: auto !important;
	border-radius: var(--lqmm-radius);
	background: var(--lqmm-soft);
	overflow: hidden;
}

.lqmm__product-img img {
	position: absolute !important;     /* OUT OF FLOW — can no longer drive the box height */
	top: 0 !important; left: 0 !important;
	width: 100% !important; height: 100% !important;
	object-fit: contain;
	transition: transform .25s ease;
	border: 1px solid #D2D1D6 !important;
	border-radius: var(--lqmm-radius) !important;
}


.lqmm__product:hover .lqmm__product-img img { transform: scale(1.04);  border: 1px solid #CF1212!important; }
.lqmm__product-title {
	font-size: 13.5px;
	font-weight: 500;
	color: var(--lqmm-ink-2);
	text-align: center;
	line-height: 1.35;
}
.lqmm__product:hover .lqmm__product-title { color: var(--lqmm-red); }

.lqmm__empty {
	grid-column: 1 / -1;
	padding: 28px 0;
	text-align: center;
	color: var(--lqmm-ink-3);
	font-size: 14px;
}

/* ---------- skeleton ---------- */
.lqmm__sk { 
	display: flex; 
	flex-direction: column; 
	gap: 10px; 
	width: 100%; /* Forces the column to stay open */
}
.lqmm__sk-img {
	width: 100%; /* Forces the gray box to hold the horizontal space */
	min-width: 60px; /* Safety fallback for narrow mobile screens */
	aspect-ratio: 1 / 1;
	border-radius: var(--lqmm-radius);
	background: linear-gradient(100deg, #eee 30%, #f6f6f6 50%, #eee 70%);
	background-size: 200% 100%;
	animation: lqmm-shimmer 1.2s infinite linear;
}


.lqmm__sk-line {
	height: 12px; width: 75%;
	margin: 0 auto;
	border-radius: 6px;
	background: linear-gradient(100deg, #eee 30%, #f6f6f6 50%, #eee 70%);
	background-size: 200% 100%;
	animation: lqmm-shimmer 1.2s infinite linear;
}
@keyframes lqmm-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* ---------- focus ---------- */
.lqmm__industry:focus-visible,
.lqmm__cat:focus-visible,
.lqmm__back:focus-visible,
.lqmm__product:focus-visible,
.lqmm__viewall:focus-visible {
	outline: 2px solid var(--lqmm-red);
	outline-offset: 2px;
}

/* ============================================================
   Tablet
   ============================================================ */
	 @media (max-width: 1100px) {
		.lqmm { grid-template-columns: 216px 1fr; }
		.lqmm__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	}

/* ============================================================
   Mobile drill-down (<= 880px)
   View 1 = industries list ; View 2 = category rail + products
   ============================================================ */
@media (max-width: 880px) {
	.lqmm {
		display: block;
		max-width: 100%;
		position: relative;
		overflow: hidden;
	}

	/* View 1: industries list */
	.lqmm__rail {
		display: flex !important;
		flex-direction: column;
		gap: 0;
		padding: 4px 0;
		border-right: 0;
		animation: lqmm-fade .2s ease;
	}
	.lqmm__industry {
		justify-content: space-between !important;
		gap: 10px;
		padding: 17px 4px !important;
		border-radius: 0 !important;
		border-bottom: 1px solid var(--lqmm-line);
		font-size: 16px;
		text-align: left !important;
		
	}
	.lqmm__industry--all { display: flex !important; }   /* mobile: show "All" on top */
	.lqmm__industry:hover,
	.lqmm__industry.is-active { background: transparent !important; color: var(--lqmm-ink)!important; font-weight: 600!important; }
	.lqmm__industry.is-active::before { content: none; }
	.lqmm__industry-icon { display: none; }   /* text-only list on mobile */
	.lqmm__industry-chev {
		display: block !important;
		flex: 0 0 auto;
		width: 9px; height: 9px;
		border-right: 2px solid var(--lqmm-ink-3);
		border-top: 2px solid var(--lqmm-ink-3);
		transform: rotate(45deg);    /* points right */
	}

	/* the panel is hidden until an industry is chosen */
	.lqmm__panel { display: none; }

.lqmm[data-view="detail"] .lqmm__panel {
		display: grid;
		grid-template-columns: 134px 1fr;
		grid-template-areas:
			"head head"
			"subs subs"
			"cats grid";
		gap: 0;
		padding: 0;
		animation: lqmm-fade .2s ease;
	}
	.lqmm[data-view="detail"] .lqmm__subcats{
		grid-area: subs;
		margin: 0;
		border-radius: 0;
		border-width: 1px 0;
		flex-wrap: nowrap;
		overflow-x: auto;
		scrollbar-width: none;
	}
	.lqmm[data-view="detail"] .lqmm__subcats::-webkit-scrollbar{ display: none; }
	.lqmm[data-view="detail"] .lqmm__subcat{ flex: 0 0 auto; }

	.lqmm[data-view="detail"] .lqmm__panel-head {
		grid-area: head;
		justify-content: flex-start;
		gap: 8px;
		padding: 6px 2px 14px;
		margin: 0;
		border-bottom: 1px solid var(--lqmm-line);
	}
	.lqmm__back {
		display: inline-flex !important;
		align-items: center;
		justify-content: center;
		width: 34px; height: 34px;
		border-radius: 8px !important;
		background: var(--lqmm-soft) !important;
		color: var(--lqmm-ink) !important;
		flex: 0 0 auto;
	}
	.lqmm__back-arrow {
		width: 9px; height: 9px;
		border-top: 2px solid currentColor;
		border-left: 2px solid currentColor;
		transform: rotate(-45deg);
		margin-left: 3px;
	}
	.lqmm__panel-name { font-size: 15px; }
	.lqmm__viewall { margin-left: auto; }

	/* vertical category rail */
	.lqmm__cats {
		grid-area: cats;
		flex-direction: column;
		flex-wrap: nowrap;
		gap: 2px;
		margin: 0;
		padding: 10px 12px 10px 0;
		border-right: 1px solid var(--lqmm-line);
	}
	.lqmm__cat {
		justify-content: flex-start;
		width: 100%;
		padding: 11px 12px !important;
		border-radius: 8px !important;
		background: transparent !important;
		color: var(--lqmm-ink-2);
		font-size: 14px;
		text-align: left;
	}
	.lqmm__cat:hover { background: var(--lqmm-soft) !important; color: var(--lqmm-ink); }
	.lqmm__cat.is-active { background: transparent !important; color: var(--lqmm-red) !important; font-weight: 700; }
	.lqmm__cat-count { display: none; }

	/* products: 2 columns, left aligned */
	.lqmm__grid {
		grid-area: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 14px;
		padding: 12px 0 12px 14px;
	}
	.lqmm__product-title { text-align: left; font-size: 13px; }
}

@keyframes lqmm-fade {
	from { opacity: 0; transform: translateY(6px); }
	to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
	.lqmm__rail,
	.lqmm[data-view="detail"] .lqmm__panel,
	.lqmm__product-img img,
	.lqmm__sk-img,
	.lqmm__sk-line { animation: none !important; transition: none !important; }
}










/* Fix first-open width reflow: force the mega-menu shortcode content
   to full width from the first frame so the product grid never renders
   narrow-then-expands. */
.e-n-menu-content .elementor-element-9d28130,
.e-n-menu-content .elementor-widget-shortcode,
.e-n-menu-content .elementor-shortcode,
.e-n-menu-content .lqmm{
	width: 100% !important;
	max-width: 100% !important;
}
.e-n-menu-content .elementor-element-9d28130,
.e-n-menu-content .elementor-widget-shortcode{
	flex: 1 1 100% !important;
}