/**
 * Esdar Section Styles
 * قسم الإصدارات - تنسيقات كاملة
 *
 * @package Nadiim
 * @since 1.0.0
 */

/* ═══════════════════════════════════════════════════════════════
   متغيرات CSS
   ═══════════════════════════════════════════════════════════════ */

:root {
	/* الألوان */
	--color-primary: #339063;
	--color-primary-hover: #2a7851;
	--color-white: #FFFFFF;
	--color-bg-light: #F6F9F7;
	--esdar-bg-surface: #F6F9F7;
	--text-main: #1C2D27;
	--text-muted: #6B7A72;

	/* القياسات */
	--card-radius: 14px;
	--container-max: 1200px;
	--section-vertical-padding: 48px;
	--card-gap: 28px;

	/* الانتقالات */
	--transition-default: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);

	/* الظلال */
	--card-shadow: 0 10px 30px rgba(18, 30, 26, 0.06);
	--card-shadow-hover: 0 15px 45px rgba(18, 30, 26, 0.12);
}

/* ═══════════════════════════════════════════════════════════════
   قسم الإصدارات - الأساسيات
   ═══════════════════════════════════════════════════════════════ */

.esdar-section {
	position: relative;
	padding: var(--section-vertical-padding) 0;
	overflow: hidden;
	background-color: transparent;
}

/* الخلفية و Overlay */
.esdar-section.section-with-bg {
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
}

.esdar-section .section-bg-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: #000000;
	opacity: var(--esdar-overlay-opacity, 0.30);
	z-index: 1;
	pointer-events: none;
}

.esdar-section .container,
.esdar-section .section-container {
	position: relative;
	z-index: 2;
	max-width: var(--container-max);
	margin: 0 auto;
	padding: 0 20px;
}

/* ═══════════════════════════════════════════════════════════════
   رأس القسم (Section Header)
   ═══════════════════════════════════════════════════════════════ */

.esdar-section .section-header {
	text-align: center;
	margin-bottom: 48px;
	max-width: 800px;
	margin-left: auto;
	margin-right: auto;
}

.esdar-section .section-title {
	font-size: clamp(28px, 4vw, 42px);
	font-weight: 800;
	color: var(--text-main);
	margin: 0 0 16px;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.esdar-section .section-subtitle {
	font-size: clamp(16px, 2vw, 18px);
	color: var(--text-muted);
	margin: 0;
	line-height: 1.6;
}

/* التكيف مع الخلفية */
.esdar-section.section-with-bg .section-title,
.esdar-section.section-with-bg .section-subtitle {
	color: rgba(255, 255, 255, 0.95);
	text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* ═══════════════════════════════════════════════════════════════
   Grid Layout
   ═══════════════════════════════════════════════════════════════ */

.esdar-section .esdar-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
	gap: var(--card-gap);
	margin-bottom: 24px;
}

/* 3 أعمدة في الشاشات الكبيرة */
@media screen and (min-width: 1200px) {
	.esdar-section .esdar-grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

/* عمودين في الشاشات المتوسطة */
@media screen and (min-width: 900px) and (max-width: 1199px) {
	.esdar-section .esdar-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* عمود واحد في الشاشات الصغيرة */
@media screen and (max-width: 899px) {
	.esdar-section .esdar-grid {
		grid-template-columns: 1fr;
		gap: 20px;
	}
}

/* ═══════════════════════════════════════════════════════════════
   بطاقة الإصدار (Esdar Card)
   ═══════════════════════════════════════════════════════════════ */

.esdar-card {
	display: flex;
	flex-direction: column;
	background-color: #ffffff;
	border-radius: var(--card-radius);
	box-shadow: var(--card-shadow);
	overflow: hidden;
	transition: var(--transition-default);
	cursor: pointer;
	height: 100%;
	position: relative;
	border: 1px solid rgba(51, 144, 99, 0.08);
}

.esdar-card::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, var(--color-primary) 0%, #10B981 100%);
	opacity: 0;
	transition: opacity 0.3s ease;
	z-index: 10;
}

.esdar-card:hover::before {
	opacity: 1;
}

.esdar-card:hover {
	transform: translateY(-8px) scale(1.02);
	box-shadow: var(--card-shadow-hover);
	border-color: rgba(51, 144, 99, 0.15);
}

.esdar-card:focus {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

/* ─────────────────────────────────────
   صورة الغلاف
   ───────────────────────────────────── */

.esdar-card-image {
	position: relative;
	width: 100%;
	aspect-ratio: 2 / 3; /* نسبة العرض للارتفاع */
	overflow: hidden;
	background: linear-gradient(135deg, #f0f4f2 0%, #e8ede8 100%);
}

.esdar-card-image::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 50%;
	background: linear-gradient(to top, rgba(28, 45, 39, 0.4) 0%, transparent 100%);
	opacity: 0;
	transition: opacity 0.4s ease;
	z-index: 1;
	pointer-events: none;
}

.esdar-card:hover .esdar-card-image::after {
	opacity: 1;
}

.esdar-card-image .cover-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
	filter: brightness(0.98) contrast(1.02);
}

.esdar-card:hover .cover-image {
	transform: scale(1.08) rotate(1deg);
	filter: brightness(1) contrast(1.05);
}

/* ─────────────────────────────────────
   شارة نوع الإصدار (Badge)
   ───────────────────────────────────── */

.esdar-card-image .esdar-type-badge {
	position: absolute;
	top: 16px;
	right: 16px;
	padding: 8px 16px;
	background: linear-gradient(135deg, var(--color-primary) 0%, #2a7a52 100%);
	color: #ffffff;
	font-size: 12px;
	font-weight: 700;
	border-radius: 8px;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	box-shadow: 0 4px 16px rgba(51, 144, 99, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
	z-index: 2;
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border: 1px solid rgba(255, 255, 255, 0.2);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.esdar-card:hover .esdar-type-badge {
	transform: translateY(-2px) scale(1.05);
	box-shadow: 0 6px 20px rgba(51, 144, 99, 0.5), 0 3px 6px rgba(0, 0, 0, 0.15);
}

/* ألوان حسب النوع */
.esdar-type-badge.type-novel {
	background: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
	box-shadow: 0 4px 16px rgba(139, 92, 246, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.esdar-type-badge.type-report {
	background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
	box-shadow: 0 4px 16px rgba(245, 158, 11, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.esdar-type-badge.type-magazine {
	background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
	box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.esdar-type-badge.type-research {
	background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
	box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.esdar-type-badge.type-guide {
	background: linear-gradient(135deg, #10B981 0%, #059669 100%);
	box-shadow: 0 4px 16px rgba(16, 185, 129, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.esdar-type-badge.type-anthology {
	background: linear-gradient(135deg, #EC4899 0%, #DB2777 100%);
	box-shadow: 0 4px 16px rgba(236, 72, 153, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* ─────────────────────────────────────
   محتوى البطاقة
   ───────────────────────────────────── */

.esdar-card-content {
	display: flex;
	flex-direction: column;
	flex-grow: 1;
	padding: 28px;
}

/* ─────────────────────────────────────
   عنوان الإصدار
   ───────────────────────────────────── */

.esdar-card-title {
	font-size: 20px;
	font-weight: 700;
	color: var(--text-main);
	margin: 0 0 16px;
	line-height: 1.35;
	letter-spacing: -0.02em;
	min-height: 54px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.esdar-card-title .card-title-link {
	color: inherit;
	text-decoration: none;
	transition: all 0.3s ease;
	background: linear-gradient(to right, var(--color-primary) 0%, var(--color-primary) 100%);
	background-size: 0 2px;
	background-repeat: no-repeat;
	background-position: left bottom;
	padding-bottom: 2px;
}

.esdar-card-title .card-title-link:hover {
	color: var(--color-primary);
	background-size: 100% 2px;
}

.esdar-card-title .card-title-link:focus {
	outline: 2px solid var(--color-primary);
	outline-offset: 3px;
	border-radius: 3px;
}

/* ─────────────────────────────────────
   الوصف
   ───────────────────────────────────── */

.esdar-card-excerpt {
	font-size: 15px;
	color: var(--text-muted);
	line-height: 1.6;
	margin: 0 0 16px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* ─────────────────────────────────────
   معلومات إضافية (Meta)
   ───────────────────────────────────── */

.esdar-card-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	margin: 0 0 20px;
	padding-top: 12px;
	border-top: 1px solid rgba(107, 122, 114, 0.15);
}

.esdar-card-meta .meta-item {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	color: var(--text-muted);
	font-weight: 500;
}

.esdar-card-meta .meta-item svg {
	width: 16px;
	height: 16px;
	opacity: 0.7;
	flex-shrink: 0;
}

/* ─────────────────────────────────────
   أزرار الإجراء
   ───────────────────────────────────── */

.esdar-card-actions {
	display: flex;
	gap: 12px;
	margin-top: auto;
}

.esdar-card-actions .action-button {
	flex: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 13px 18px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 10px;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	cursor: pointer;
	border: 2px solid transparent;
	position: relative;
	overflow: hidden;
}

.esdar-card-actions .action-button::before {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 0;
	height: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.3);
	transform: translate(-50%, -50%);
	transition: width 0.6s, height 0.6s;
}

.esdar-card-actions .action-button:hover::before {
	width: 300px;
	height: 300px;
}

.esdar-card-actions .action-button svg {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
	transition: transform 0.3s ease;
	position: relative;
	z-index: 1;
}

.esdar-card-actions .action-button span {
	position: relative;
	z-index: 1;
}

/* زر العرض */
.action-button.button-view {
	background: linear-gradient(135deg, var(--color-primary) 0%, #2a7a52 100%);
	color: #ffffff;
	border-color: var(--color-primary);
	box-shadow: 0 2px 8px rgba(51, 144, 99, 0.2);
}

.action-button.button-view:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 20px rgba(51, 144, 99, 0.35);
}

.action-button.button-view:hover svg {
	transform: scale(1.1);
}

.action-button.button-view:focus {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

.action-button.button-view:active {
	transform: translateY(-1px);
}

/* زر التحميل */
.action-button.button-download {
	background-color: rgba(51, 144, 99, 0.08);
	color: var(--color-primary);
	border-color: rgba(51, 144, 99, 0.25);
	box-shadow: 0 2px 6px rgba(51, 144, 99, 0.1);
}

.action-button.button-download::before {
	background: var(--color-primary);
}

.action-button.button-download:hover {
	background-color: var(--color-primary);
	color: #ffffff;
	border-color: var(--color-primary);
	transform: translateY(-3px);
	box-shadow: 0 8px 20px rgba(51, 144, 99, 0.3);
}

.action-button.button-download:hover svg {
	transform: translateY(2px);
}

.action-button.button-download:focus {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

.action-button.button-download:active {
	transform: translateY(-1px);
}

/* ═══════════════════════════════════════════════════════════════
   Carousel Layout (Swiper)
   ═══════════════════════════════════════════════════════════════ */

.esdar-section.layout-carousel .esdar-swiper {
	position: relative;
	padding: 0 50px 60px;
	margin: 0 -20px;
}

.esdar-section .swiper-slide {
	height: auto;
}

.esdar-section .swiper-slide .esdar-card {
	height: 100%;
}

/* أزرار التنقل */
.esdar-section .swiper-button-prev,
.esdar-section .swiper-button-next {
	width: 48px;
	height: 48px;
	background-color: #ffffff;
	border-radius: 50%;
	box-shadow: 0 4px 12px rgba(18, 30, 26, 0.15);
	color: var(--color-primary);
	transition: var(--transition-default);
	border: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
}

.esdar-section .swiper-button-prev {
	left: 0;
}

.esdar-section .swiper-button-next {
	right: 0;
}

.esdar-section .swiper-button-prev:hover,
.esdar-section .swiper-button-next:hover {
	background-color: var(--color-primary);
	color: #ffffff;
	transform: translateY(-50%) scale(1.1);
	box-shadow: 0 6px 20px rgba(51, 144, 99, 0.3);
}

.esdar-section .swiper-button-prev:focus,
.esdar-section .swiper-button-next:focus {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

.esdar-section .swiper-button-prev.swiper-button-disabled,
.esdar-section .swiper-button-next.swiper-button-disabled {
	opacity: 0.3;
	cursor: not-allowed;
}

/* Pagination */
.esdar-section .swiper-pagination {
	bottom: 20px;
	display: flex;
	justify-content: center;
	gap: 8px;
}

.esdar-section .swiper-pagination-bullet {
	width: 10px;
	height: 10px;
	background-color: rgba(51, 144, 99, 0.3);
	border-radius: 50%;
	opacity: 1;
	transition: var(--transition-default);
	cursor: pointer;
}

.esdar-section .swiper-pagination-bullet-active {
	background-color: var(--color-primary);
	width: 28px;
	border-radius: 5px;
}

/* ═══════════════════════════════════════════════════════════════
   زر "اطلع على المزيد"
   ═══════════════════════════════════════════════════════════════ */

.esdar-section .section-more-button {
	margin-top: 48px;
	text-align: center;
}

.esdar-section .more-button {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 16px 36px;
	background-color: var(--color-primary);
	color: #ffffff;
	font-size: 17px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 50px;
	transition: var(--transition-default);
	border: 2px solid var(--color-primary);
	box-shadow: 0 4px 12px rgba(51, 144, 99, 0.2);
}

.esdar-section .more-button:hover {
	background-color: var(--color-primary-hover);
	border-color: var(--color-primary-hover);
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(51, 144, 99, 0.3);
}

.esdar-section .more-button:focus {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

.esdar-section .more-button svg {
	width: 20px;
	height: 20px;
	transition: transform 0.25s ease;
}

.esdar-section .more-button:hover svg {
	transform: translateX(4px);
}

/* RTL: حركة السهم لليسار */
[dir="rtl"] .esdar-section .more-button:hover svg {
	transform: translateX(-4px);
}

/* ═══════════════════════════════════════════════════════════════
   Responsive Breakpoints
   ═══════════════════════════════════════════════════════════════ */

/* ≥ 1200px (Desktop Large) */
@media screen and (min-width: 1200px) {
	.esdar-section {
		padding: 64px 0;
	}

	.esdar-section .section-header {
		margin-bottom: 56px;
	}
}

/* 900px - 1199px (Desktop/Tablet) */
@media screen and (min-width: 900px) and (max-width: 1199px) {
	.esdar-section {
		padding: 56px 0;
	}

	.esdar-card-title {
		font-size: 17px;
	}

	.esdar-card-excerpt {
		font-size: 14px;
	}

	.esdar-card-content {
		padding: 20px;
	}
}

/* ≤ 899px (Mobile) */
@media screen and (max-width: 899px) {
	.esdar-section {
		padding: 40px 0;
	}

	.esdar-section .container,
	.esdar-section .section-container {
		padding: 0 20px;
	}

	.esdar-section .section-header {
		margin-bottom: 32px;
	}

	.esdar-section .section-title {
		font-size: 28px;
		margin-bottom: 12px;
	}

	.esdar-section .section-subtitle {
		font-size: 16px;
	}

	.esdar-card-title {
		font-size: 16px;
	}

	.esdar-card-excerpt {
		font-size: 14px;
	}

	.esdar-card-content {
		padding: 18px;
	}

	.esdar-card-meta {
		gap: 12px;
	}

	.esdar-card-actions {
		flex-direction: column;
	}

	.esdar-card-actions .action-button {
		width: 100%;
	}

	/* Carousel adjustments */
	.esdar-section.layout-carousel .esdar-swiper {
		padding: 0 10px 50px;
		margin: 0;
	}

	.esdar-section .swiper-button-prev,
	.esdar-section .swiper-button-next {
		width: 40px;
		height: 40px;
	}

	.esdar-section .more-button {
		padding: 14px 28px;
		font-size: 15px;
	}
}

/* ≤ 600px (Mobile Small) */
@media screen and (max-width: 600px) {
	.esdar-section {
		padding: 32px 0;
	}

	.esdar-card-image {
		aspect-ratio: 2 / 3;
	}

	.esdar-card-content {
		padding: 16px;
	}

	.esdar-card-title {
		font-size: 15px;
	}

	.esdar-card-actions .action-button {
		padding: 10px 14px;
		font-size: 13px;
	}

	.esdar-type-badge {
		font-size: 11px;
		padding: 5px 12px;
	}
}

/* ═══════════════════════════════════════════════════════════════
   Accessibility & Motion Preferences
   ═══════════════════════════════════════════════════════════════ */

/* تقليل الحركة للمستخدمين الذين يفضلون ذلك */
@media (prefers-reduced-motion: reduce) {
	.esdar-card,
	.esdar-card-image .cover-image,
	.action-button,
	.more-button,
	.swiper-button-prev,
	.swiper-button-next {
		transition: none;
	}

	.esdar-card:hover,
	.action-button:hover,
	.more-button:hover {
		transform: none;
	}
}

/* Focus visible للوصول عبر الكيبورد */
.esdar-card:focus-visible,
.action-button:focus-visible,
.more-button:focus-visible,
.swiper-button-prev:focus-visible,
.swiper-button-next:focus-visible {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

/* ═══════════════════════════════════════════════════════════════
   Print Styles
   ═══════════════════════════════════════════════════════════════ */

@media print {
	.esdar-section {
		background: none !important;
		padding: 20px 0;
	}

	.esdar-section .section-bg-overlay,
	.esdar-section .swiper-button-prev,
	.esdar-section .swiper-button-next,
	.esdar-section .swiper-pagination,
	.esdar-section .more-button {
		display: none !important;
	}

	.esdar-card {
		box-shadow: none;
		border: 1px solid #ddd;
		break-inside: avoid;
		page-break-inside: avoid;
	}

	.esdar-card:hover {
		transform: none;
	}
}

/* ═══════════════════════════════════════════════════════════════
   التصميم العصري الجديد - Modern Design 2.1
   ═══════════════════════════════════════════════════════════════ */

/* قسم الإصدارات العصري */
.esdar-section-modern {
	position: relative;
	padding: 80px 0;
	background: linear-gradient(135deg, #F6FFF9 0%, #E8F5EC 100%);
	overflow: hidden;
}

/* الخلفية المتحركة */
.esdar-bg-pattern {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	overflow: hidden;
	z-index: 0;
	opacity: 0.4;
}

/* إخفاء الخلفية المتحركة عند وجود خلفية مخصصة */
.esdar-section.section-with-bg .esdar-bg-pattern {
	display: none;
}

.pattern-circle {
	position: absolute;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(51, 144, 99, 0.15) 0%, transparent 70%);
	animation: float 20s ease-in-out infinite;
}

.pattern-circle-1 {
	width: 400px;
	height: 400px;
	top: -100px;
	right: -100px;
	animation-delay: 0s;
}

.pattern-circle-2 {
	width: 300px;
	height: 300px;
	bottom: -80px;
	left: 10%;
	animation-delay: 5s;
}

.pattern-circle-3 {
	width: 250px;
	height: 250px;
	top: 50%;
	right: 15%;
	animation-delay: 10s;
}

@keyframes float {
	0%, 100% {
		transform: translate(0, 0) scale(1);
	}
	33% {
		transform: translate(30px, -30px) scale(1.1);
	}
	66% {
		transform: translate(-20px, 20px) scale(0.9);
	}
}

/* رأس القسم */
.esdar-section-modern .section-header {
	position: relative;
	z-index: 2;
	text-align: center;
	margin-bottom: 60px;
}

.esdar-section-modern .section-badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 20px;
	background: linear-gradient(135deg, rgba(51, 144, 99, 0.1) 0%, rgba(51, 144, 99, 0.05) 100%);
	border: 2px solid rgba(51, 144, 99, 0.2);
	border-radius: 50px;
	color: var(--color-primary);
	font-size: 14px;
	font-weight: 600;
	margin-bottom: 20px;
}

.esdar-section-modern .section-badge svg {
	width: 20px;
	height: 20px;
}

.esdar-section-modern .section-title {
	font-size: clamp(32px, 5vw, 48px);
	font-weight: 800;
	color: var(--text-main);
	margin: 0 0 16px;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.esdar-section-modern .section-description {
	font-size: clamp(16px, 2vw, 19px);
	color: var(--text-muted);
	max-width: 700px;
	margin: 0 auto;
	line-height: 1.7;
}

/* Grid Layout العصري */
.esdar-modern-grid {
	position: relative;
	z-index: 2;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 32px;
	margin-bottom: 48px;
}

@media (min-width: 1024px) {
	.esdar-modern-grid {
		grid-template-columns: repeat(4, 1fr);
	}
}

@media (min-width: 768px) and (max-width: 1023px) {
	.esdar-modern-grid {
		grid-template-columns: repeat(3, 1fr);
		gap: 24px;
	}
}

@media (max-width: 767px) {
	.esdar-modern-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 16px;
	}
}

@media (max-width: 480px) {
	.esdar-modern-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 12px;
	}
}

/* بطاقة الإصدار العصرية */
.esdar-card-modern {
	background: #ffffff;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 4px 20px rgba(28, 45, 39, 0.08);
	transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
	cursor: pointer;
	position: relative;
}

.esdar-card-modern::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 3px;
	background: linear-gradient(90deg, var(--color-primary) 0%, #10B981 100%);
	transform: scaleX(0);
	transform-origin: left;
	transition: transform 0.4s ease;
	z-index: 10;
}

.esdar-card-modern:hover::before {
	transform: scaleX(1);
}

.esdar-card-modern:hover {
	transform: translateY(-12px);
	box-shadow: 0 20px 40px rgba(28, 45, 39, 0.15);
}

/* غلاف الإصدار */
.esdar-card-cover {
	position: relative;
	width: 100%;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	background: linear-gradient(135deg, #f0f4f2 0%, #e8ede8 100%);
}

.cover-link {
	display: block;
	width: 100%;
	height: 100%;
	position: relative;
}

.cover-image-wrapper {
	width: 100%;
	height: 100%;
	position: relative;
	overflow: hidden;
}

.cover-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.esdar-card-modern:hover .cover-image {
	transform: scale(1.1);
}

/* Overlay عند التمرير */
.cover-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: linear-gradient(to bottom, transparent 0%, rgba(28, 45, 39, 0.9) 100%);
	opacity: 0;
	transition: opacity 0.4s ease;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	padding: 24px;
	z-index: 2;
}

.esdar-card-modern:hover .cover-overlay {
	opacity: 1;
}

.overlay-content {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	color: #ffffff;
	transform: translateY(20px);
	transition: transform 0.4s ease;
}

.esdar-card-modern:hover .overlay-content {
	transform: translateY(0);
}

.overlay-content svg {
	width: 48px;
	height: 48px;
	opacity: 0.9;
}

.overlay-content span {
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.02em;
}

/* شارة نوع الإصدار */
.type-badge {
	position: absolute;
	top: 12px;
	right: 12px;
	padding: 6px 12px;
	background: linear-gradient(135deg, var(--color-primary) 0%, #2a7a52 100%);
	color: #ffffff;
	font-size: 11px;
	font-weight: 700;
	border-radius: 20px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	box-shadow: 0 4px 12px rgba(51, 144, 99, 0.4);
	z-index: 3;
	backdrop-filter: blur(10px);
	transition: transform 0.3s ease;
}

.esdar-card-modern:hover .type-badge {
	transform: scale(1.1);
}

/* شارة الصيغة */
.format-badge {
	position: absolute;
	bottom: 12px;
	left: 12px;
	display: flex;
	align-items: center;
	gap: 4px;
	padding: 5px 10px;
	background: rgba(255, 255, 255, 0.95);
	color: var(--text-main);
	font-size: 10px;
	font-weight: 700;
	border-radius: 12px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
	z-index: 3;
	backdrop-filter: blur(10px);
}

.format-badge svg {
	width: 14px;
	height: 14px;
}

/* محتوى البطاقة */
.esdar-card-body {
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.card-title {
	font-size: 15px;
	font-weight: 700;
	color: var(--text-main);
	line-height: 1.3;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: 39px;
}

.title-link {
	color: inherit;
	text-decoration: none;
	transition: color 0.3s ease;
}

.title-link:hover {
	color: var(--color-primary);
}

/* Meta المعلومات */
.card-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	padding: 8px 0;
	border-top: 1px solid rgba(107, 122, 114, 0.15);
	border-bottom: 1px solid rgba(107, 122, 114, 0.15);
}

.meta-item {
	display: flex;
	align-items: center;
	gap: 4px;
	font-size: 12px;
	color: var(--text-muted);
	font-weight: 500;
}

.meta-item svg {
	width: 14px;
	height: 14px;
	opacity: 0.7;
}

/* أزرار الإجراء */
.card-actions {
	display: flex;
	gap: 8px;
	margin-top: auto;
}

.btn-action {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 10px 12px;
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 10px;
	transition: all 0.3s ease;
	position: relative;
	overflow: hidden;
}

.btn-action svg {
	width: 16px;
	height: 16px;
	transition: transform 0.3s ease;
}

.btn-view {
	background: var(--color-primary);
	color: #ffffff;
	box-shadow: 0 2px 8px rgba(51, 144, 99, 0.25);
}

.btn-view:hover {
	background: var(--color-primary-hover);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(51, 144, 99, 0.35);
}

.btn-view:hover svg {
	transform: translateX(-3px);
}

[dir="rtl"] .btn-view:hover svg {
	transform: translateX(3px);
}

.btn-download {
	background: rgba(51, 144, 99, 0.1);
	color: var(--color-primary);
	border: 2px solid rgba(51, 144, 99, 0.2);
}

.btn-download:hover {
	background: var(--color-primary);
	color: #ffffff;
	border-color: var(--color-primary);
	transform: translateY(-2px);
}

.btn-download:hover svg {
	transform: translateY(2px);
}

/* زر المزيد */
.section-cta {
	position: relative;
	z-index: 2;
	text-align: center;
	margin-top: 48px;
}

.btn-modern {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	padding: 16px 32px;
	font-size: 16px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 50px;
	transition: all 0.3s ease;
	position: relative;
	overflow: hidden;
}

.btn-modern::before {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 0;
	height: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.2);
	transform: translate(-50%, -50%);
	transition: width 0.6s, height 0.6s;
}

.btn-modern:hover::before {
	width: 300px;
	height: 300px;
}

.btn-modern span,
.btn-modern svg {
	position: relative;
	z-index: 1;
}

.btn-modern svg {
	width: 20px;
	height: 20px;
	transition: transform 0.3s ease;
}

.btn-modern:hover svg {
	transform: translateX(-4px);
}

[dir="rtl"] .btn-modern:hover svg {
	transform: translateX(4px);
}

.btn-primary {
	background: linear-gradient(135deg, var(--color-primary) 0%, #2a7a52 100%);
	color: #ffffff;
	box-shadow: 0 4px 20px rgba(51, 144, 99, 0.3);
}

.btn-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 30px rgba(51, 144, 99, 0.4);
}

/* Swiper Carousel */
.esdar-modern-swiper {
	position: relative;
	padding: 0 50px 60px;
	margin: 0 -20px;
}

.swiper-nav-buttons {
	position: absolute;
	top: 50%;
	left: 0;
	right: 0;
	transform: translateY(-50%);
	z-index: 10;
	pointer-events: none;
	display: flex;
	justify-content: space-between;
	padding: 0 10px;
}

.swiper-btn-prev,
.swiper-btn-next {
	width: 44px;
	height: 44px;
	background: #ffffff;
	border: 2px solid rgba(51, 144, 99, 0.2);
	border-radius: 50%;
	color: var(--color-primary);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.3s ease;
	pointer-events: all;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.swiper-btn-prev:hover,
.swiper-btn-next:hover {
	background: var(--color-primary);
	color: #ffffff;
	border-color: var(--color-primary);
	transform: scale(1.1);
	box-shadow: 0 6px 20px rgba(51, 144, 99, 0.3);
}

.swiper-pagination-modern {
	bottom: 20px;
	display: flex;
	justify-content: center;
	gap: 8px;
}

/* Responsive */
@media (max-width: 768px) {
	.esdar-section-modern {
		padding: 50px 0;
	}

	.esdar-modern-swiper {
		padding: 0 0 50px;
		margin: 0;
	}

	.swiper-nav-buttons {
		display: none;
	}

	.card-actions {
		flex-direction: column;
	}

	.btn-action {
		width: 100%;
	}
}

@media (max-width: 480px) {
	.esdar-section-modern {
		padding: 40px 0;
	}

	.esdar-card-body {
		padding: 12px;
	}

	.card-title {
		font-size: 13px;
		min-height: 34px;
	}

	.meta-item {
		font-size: 11px;
	}

	.btn-action {
		padding: 8px 10px;
		font-size: 12px;
	}

	.type-badge {
		font-size: 9px;
		padding: 4px 8px;
	}

	.format-badge {
		font-size: 9px;
		padding: 3px 8px;
	}
}

/* تقليل الحركة */
@media (prefers-reduced-motion: reduce) {
	.esdar-card-modern,
	.cover-image,
	.btn-action,
	.btn-modern,
	.pattern-circle {
		transition: none;
		animation: none;
	}

	.esdar-card-modern:hover {
		transform: none;
	}
}

/* ============================================
   لمسات الأكسنت الذهبي - Accent Color Touches
   ============================================ */

/* 1. إطار ذهبي حول غلاف الكتاب */
.esdar-card .book-cover,
.esdar-card-modern .book-cover {
	border: 1px solid var(--color-accent);
}

/* 2. Badge نوع الإصدار بخلفية ذهبية */
.esdar-card .book-badge,
.esdar-card-modern .book-badge,
.esdar-card .type-badge {
	background: var(--color-accent);
	color: var(--color-accent-text);
}

/* 3. أيقونات التحميل والصفحات بلون ذهبي */
.esdar-card .book-meta svg,
.esdar-card-modern .book-meta svg,
.esdar-download-btn svg,
.book-pages-icon {
	color: var(--color-accent);
}

/* 4. Hover effect مع ظل ذهبي */
.esdar-card:hover,
.esdar-card-modern:hover {
	box-shadow: var(--shadow-accent);
}

/* 5. Active filter في الأرشيف */
.esdar-filters .filter-button.active,
.esdar-filters .filter-link.active {
	color: var(--color-accent);
	border-color: var(--color-accent);
}

/* 6. Pagination الصفحة الحالية */
.pagination .page-numbers.current {
	background: var(--color-accent);
	color: var(--color-accent-text);
	border-color: var(--color-accent);
}

/* 7. نقطة الفصل في الميتا */
.esdar-card .book-meta::after,
.book-meta-separator::after {
	content: '•';
	color: var(--color-accent);
	margin: 0 8px;
}
