/* AL TAJ Category Icons */
:root {
	--altaj-ci-accent: #b08d3c;
	--altaj-ci-line: #e6dfd2;
	--altaj-ci-text: #222;
}
body.altaj-ci-mode-reem,
body.altaj-skin-reemstore {
	--altaj-ci-accent: #8A5A5A;
}

/* Menu link "Categories": phones only (Avada switches awb-menu_desktop / awb-menu_mobile). */
.awb-menu_desktop .altaj-mobile-only {
	display: none !important;
}

/* ---------- one icon ---------- */
.altaj-ci-icon {
	display: flex;
	flex-direction: column;
	align-items: center;
	width: 112px;
	color: var(--altaj-ci-text) !important;
	text-decoration: none !important;
	-webkit-tap-highlight-color: transparent;
}
.altaj-ci-pic {
	position: relative;
	display: block;
	width: 96px;
	height: 96px;
	border: 1px solid var(--altaj-ci-line);
	border-radius: 50%;
	background: #fff;
	overflow: hidden;
	box-sizing: border-box;
	transition: border-color .2s ease, box-shadow .2s ease;
}
.altaj-ci-pic img.altaj-ci-img {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	object-fit: contain;
	padding: 8%;
	box-sizing: border-box;
	border-radius: 50%;
	background: #fff;
}
.altaj-ci-icon.is-logo .altaj-ci-pic img.altaj-ci-img {
	padding: 16%;
	border-radius: 0;
}
.altaj-ci-ph {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	font-size: 28px;
	color: var(--altaj-ci-accent);
}
.altaj-ci-icon:is(:hover, :focus-visible) .altaj-ci-pic {
	border-color: var(--altaj-ci-accent);
}
.altaj-ci-icon.is-active .altaj-ci-pic {
	border: 2px solid var(--altaj-ci-accent);
	box-shadow: 0 0 0 3px rgba(0, 0, 0, .04);
}
.altaj-ci-name {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
	max-width: 100%;
	margin-top: 8px;
	font-size: 13px;
	line-height: 1.3;
	text-align: center;
	word-break: break-word;
}
.altaj-ci-icon.is-active .altaj-ci-name {
	font-weight: 600;
	color: var(--altaj-ci-accent);
}

/* ---------- "Shop by category" row ---------- */
.altaj-ci-row {
	width: 100%;
	margin: 0 0 22px;
}
.altaj-ci-row[hidden] {
	display: none !important;
}
.altaj-ci-row .altaj-ci-title {
	margin: 0 0 14px !important;
	font-size: 20px !important;
	line-height: 1.3 !important;
	text-align: center;
}
.altaj-ci-track {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 18px 14px;
}

/* The row replaces the left sidebar list (and the All Categories title, and the Reem Store text buttons). */
body.altaj-ci-has-row #sidebar.fusion-shopsidebar {
	display: none !important;
}
body.altaj-ci-has-row.has-sidebar #content {
	float: none !important;
	width: 100% !important;
	max-width: 100% !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
}
body.altaj-ci-notitle :is(.fusion-tb-page-title-bar, .fusion-page-title-bar) {
	display: none !important;
}
body.altaj-ci-has-row #altaj-rc-filters .altaj-rc-cats {
	display: none !important;
}
body.altaj-ci-has-row #altaj-rc-filters {
	justify-content: flex-end;
}

/* ---------- Categories page ---------- */
.altaj-cats {
	max-width: 1200px;
	margin: 0 auto;
}
.altaj-cats-nav {
	display: none;
}
.altaj-cats-panel {
	margin: 0 0 40px;
}
.altaj-cats-h {
	margin: 0 0 18px !important;
	font-size: 22px !important;
	line-height: 1.3 !important;
}
.altaj-cats-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
	gap: 24px 12px;
	justify-items: center;
}

@media (max-width: 800px) {
	.altaj-ci-icon {
		flex: 0 0 80px;
		width: 80px;
	}
	.altaj-ci-pic {
		width: 72px;
		height: 72px;
	}
	.altaj-ci-name {
		margin-top: 6px;
		font-size: 12px;
	}
	.altaj-ci-row .altaj-ci-title {
		font-size: 17px !important;
		margin-bottom: 10px !important;
	}
	/* phones: one line, scroll sideways */
	.altaj-ci-track {
		flex-wrap: nowrap;
		justify-content: flex-start;
		gap: 10px;
		overflow-x: auto;
		overscroll-behavior-x: contain;
		scroll-snap-type: x proximity;
		scrollbar-width: none;
		-webkit-overflow-scrolling: touch;
		padding: 2px 2px 6px;
	}
	.altaj-ci-track::-webkit-scrollbar {
		display: none;
	}
	.altaj-ci-track .altaj-ci-icon {
		scroll-snap-align: start;
	}

	/* Categories page: groups on the left, icons on the right (3 per row). */
	.altaj-cats {
		display: grid;
		grid-template-columns: 104px minmax(0, 1fr);
		min-height: 70vh;
		border-top: 1px solid #eee;
	}
	.altaj-cats-nav {
		display: flex;
		flex-direction: column;
		position: sticky;
		top: 0;
		align-self: start;
		max-height: 100vh;
		overflow-y: auto;
		background: #f5f5f5;
	}
	.altaj-cats-nav button {
		appearance: none;
		-webkit-appearance: none;
		margin: 0 !important;
		padding: 15px 8px !important;
		border: 0 !important;
		border-inline-start: 3px solid transparent !important;
		border-radius: 0 !important;
		background: transparent !important;
		box-shadow: none !important;
		color: #555 !important;
		font: inherit;
		font-size: 13px !important;
		line-height: 1.3 !important;
		text-align: start;
		text-transform: none !important;
		letter-spacing: normal !important;
		cursor: pointer;
	}
	.altaj-cats-nav button[aria-selected="true"] {
		background: #fff !important;
		color: #111 !important;
		font-weight: 600;
		border-inline-start-color: var(--altaj-ci-accent) !important;
	}
	.altaj-cats-panels {
		min-width: 0;
		padding: 14px 8px 20px 12px;
	}
	.rtl .altaj-cats-panels {
		padding: 14px 12px 20px 8px;
	}
	.altaj-cats-panel {
		display: none;
		margin: 0;
	}
	.altaj-cats-panel.is-active {
		display: block;
	}
	.altaj-cats-h {
		margin: 0 0 14px !important;
		font-size: 15px !important;
	}
	.altaj-cats-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 18px 4px;
	}
	.altaj-cats .altaj-ci-icon {
		flex: none;
		width: 100%;
	}
}
