/* استایل‌های header دسته‌بندی برای ژاکت */

.page-header {
	padding-top: 40px !important;
	padding-bottom: 50px !important;
	margin-bottom: 0;
	position: relative;
	z-index: 1;
}

/* فاصله از header فیکس - اضافه کردن margin-top به page-header */
/* 
 * برای تنظیم فاصله: مقدار margin-top زیر را تغییر دهید
 * - مقدار کمتر = header نزدیک‌تر به header فیکس (مثلاً 120px یا 140px)
 * - مقدار بیشتر = header پایین‌تر از header فیکس (مثلاً 180px یا 200px)
 * پیشنهاد: بین 120px تا 160px
 */
.page-header {
	margin-top: 90px !important; /* <-- این مقدار را تغییر دهید برای تنظیم فاصله */
}

/* فاصله بین page-header و محتوا */
.category-page-spacing {
	margin-top: 0 !important;
}

/* Override برای اطمینان */
section#primary.content-area.category-page-spacing,
#primary.content-area.category-page-spacing {
	margin-top: 0 !important;
}

#app-main-content.site-main {
	margin-top: 0 !important;
	padding-top: 0;
}

@media (min-width: 992px) {
	.page-header {
		padding-top: 50px !important;
		padding-bottom: 60px !important;
	}
}

.page-header .container {
	position: relative;
}

/* Breadcrumb */
.page-header-breadcrumb {
	margin-bottom: 20px;
}

.page-header-breadcrumb .breadcrumb {
	background: transparent;
	padding: 0;
	margin: 0;
	font-size: 14px;
}

.page-header-breadcrumb .breadcrumb-item {
	color: #FFA726; /* نارنجی برای breadcrumb */
}

.page-header-breadcrumb .breadcrumb-item a {
	color: #FFA726 !important; /* نارنجی برای لینک‌های breadcrumb */
	text-decoration: none;
	transition: color 0.3s ease;
}

.page-header-breadcrumb .breadcrumb-item a:hover {
	color: #fb8c00 !important; /* نارنجی تیره‌تر در hover */
}

.page-header-breadcrumb .breadcrumb-item.active {
	color: #333; /* مشکی برای آیتم فعال */
}

/* جداکننده "/" نارنجی */
.page-header-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
	color: #FFA726 !important;
}

/* عنوان */
.page-header-title {
	margin: 0;
	padding: 0;
	font-size: 32px;
	font-weight: 700;
	color: #333;
	line-height: 1.3;
}

/* توضیحات */
.page-header-description {
	color: #666;
	font-size: 14px;
	line-height: 1.8;
	margin-top: 15px;
}

.page-header-description p {
	margin-bottom: 10px;
}

.page-header-description p:last-child {
	margin-bottom: 0;
}

/* Grid کارت‌های دسته - یک ردیف افقی */
.category-cards-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 50px;
	margin-top: 10px;
}

/* کارت مربعی - کوچکتر شده */
.category-card-square {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	background: white;
	border-radius: 8px;
	padding: 15px 8px;
	text-decoration: none;
	transition: all 0.3s ease;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
	aspect-ratio: 1;
	min-height: 100px;
	position: relative;
	overflow: hidden;
	border: 1px solid #f0f0f0;
}

.category-card-square:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
	text-decoration: none;
}

/* آیکون - کوچکتر */
.category-card-icon {
	width: 40px;
	height: 40px;
	margin-bottom: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.category-card-icon img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 5px;
}

.category-card-icon-image {
	width: 28px;
	height: 28px;
	object-fit: cover;
	border-radius: 5px;
	margin-left: 5px; /* فاصله از آیکون Feather */
}

.category-card-icon svg {
	width: 40px;
	height: 40px;
	stroke: #FFA726;
}

/* آیکون Feather - در کنار تصویر */
.category-card-feather-icon {
	width: 20px;
	height: 20px;
	stroke: #FFA726;
	flex-shrink: 0;
}

/* اگر هم تصویر و هم آیکون Feather وجود داشت - در کنار هم */
.category-card-icon:has(.category-card-icon-image):has(.category-card-feather-icon) {
	width: auto;
	gap: 5px;
	justify-content: flex-start;
}

.category-card-icon:has(.category-card-icon-image):has(.category-card-feather-icon) .category-card-icon-image {
	width: 28px;
	height: 28px;
	margin-left: 0;
}

.category-card-icon:has(.category-card-icon-image):has(.category-card-feather-icon) .category-card-feather-icon {
	width: 20px;
	height: 20px;
}

/* عنوان کارت - کوچکتر */
.category-card-title {
	font-size: 11px;
	font-weight: 600;
	color: #000 !important; /* مشکی برای زیردسته‌ها */
	text-align: center;
	line-height: 1.3;
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	-webkit-box-orient: vertical;
	padding: 0 4px;
}

.category-card-square:hover .category-card-title {
	color: #FFA726;
}

/* Responsive */
@media (max-width: 1199px) {
	.category-cards-grid {
		grid-template-columns: repeat(4, 1fr);
		gap: 18px;
	}
	
	.category-card-square {
		padding: 12px 6px;
		min-height: 90px;
	}
	
	.category-card-icon {
		width: 36px;
		height: 36px;
		margin-bottom: 6px;
	}
	
	.category-card-icon svg {
		width: 36px;
		height: 36px;
	}
	
	.category-card-title {
		font-size: 10px;
	}
}

@media (max-width: 991px) {
	.page-header {
		padding-top: 40px !important;
		padding-bottom: 40px !important;
	}
	
	.category-cards-grid {
		margin-top: 30px;
		grid-template-columns: repeat(4, 1fr);
		gap: 15px;
	}
	
	.category-card-square {
		padding: 12px 5px;
		min-height: 85px;
	}
	
	.category-card-icon {
		width: 32px;
		height: 32px;
		margin-bottom: 6px;
	}
	
	.category-card-icon svg {
		width: 32px;
		height: 32px;
	}
	
	.category-card-title {
		font-size: 9px;
		padding: 0 2px;
	}
	
	.page-header-title {
		font-size: 26px;
	}
}

@media (max-width: 991px) {
	/* موبایل: کارت‌ها در یک ردیف افقی قابل اسکرول */
	.category-cards-mobile-scroll {
		display: flex !important;
		flex-direction: row !important;
		grid-template-columns: none !important;
		gap: 12px;
		margin-top: 25px;
		overflow-x: auto;
		overflow-y: hidden;
		-webkit-overflow-scrolling: touch;
		scroll-snap-type: x proximity;
		padding-bottom: 10px;
		scrollbar-width: thin;
		scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
	}
	
	.category-cards-mobile-scroll::-webkit-scrollbar {
		height: 4px;
	}
	
	.category-cards-mobile-scroll::-webkit-scrollbar-track {
		background: transparent;
	}
	
	.category-cards-mobile-scroll::-webkit-scrollbar-thumb {
		background: rgba(0, 0, 0, 0.2);
		border-radius: 2px;
	}
	
	/* موبایل: کارت‌ها افقی - آیکون و متن در یک خط */
	.category-cards-mobile-scroll .category-card-square {
		flex: 0 0 auto;
		display: flex !important;
		flex-direction: row !important;
		align-items: center !important;
		justify-content: flex-start !important;
		gap: 10px;
		width: auto;
		min-width: auto;
		max-width: none;
		padding: 12px 16px !important;
		min-height: auto;
		height: auto;
		aspect-ratio: auto !important;
		scroll-snap-align: start;
	}
	
	.category-cards-mobile-scroll .category-card-icon {
		width: 36px !important;
		height: 36px !important;
		margin-bottom: 0 !important;
		flex-shrink: 0;
	}
	
	.category-cards-mobile-scroll .category-card-icon svg {
		width: 36px !important;
		height: 36px !important;
	}
	
	.category-cards-mobile-scroll .category-card-title {
		font-size: 13px !important;
		padding: 0 !important;
		text-align: right !important;
		white-space: nowrap;
		overflow: visible;
		display: -webkit-box;
		-webkit-line-clamp: 1;
		-webkit-box-orient: horizontal;
		line-clamp: 1;
		color: #000 !important; /* مشکی برای زیردسته‌ها در موبایل */
	}
}

@media (max-width: 767px) {
	.category-cards-mobile-scroll {
		gap: 10px;
	}
	
	.category-cards-mobile-scroll .category-card-square {
		padding: 10px 14px !important;
		gap: 8px;
	}
	
	.category-cards-mobile-scroll .category-card-icon {
		width: 32px !important;
		height: 32px !important;
	}
	
	.category-cards-mobile-scroll .category-card-icon svg {
		width: 32px !important;
		height: 32px !important;
	}
	
	.category-cards-mobile-scroll .category-card-title {
		font-size: 12px !important;
		color: #000 !important; /* مشکی برای زیردسته‌ها در موبایل کوچک */
	}
}

