/* ==========================================================================
   Abtin Related Articles - استایل فرانت‌اند
   رنگ‌بندی هماهنگ با سایت آبتین (سرمه‌ای/آبی)
   ========================================================================== */

.abtin-ra-wrapper {
	width: 100%;
	font-family: inherit;
}

.abtin-ra-section-title {
	text-align: center;
	margin: 0 0 24px;
	font-weight: 800;
	color: #00003c;
}

/* --------------------------------------------------------------------------
   صحنه دسکتاپ: پس‌زمینه‌ای که با hover تغییر می‌کند
   -------------------------------------------------------------------------- */
.abtin-ra-stage {
	position: relative;
	width: 100%;
	/* ارتفاع همیشه ثابت است، صرف‌نظر از سایز صفحه */
	height: 500px;
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
	overflow: hidden;
	/* انتقال نرم هنگام تعویض تصویر پس‌زمینه */
	transition: background-image 0.6s ease-in-out;
	/* border-radius اکنون از پنل استایل المنتور قابل تنظیم است (پیش‌فرض 6px) */
}

.abtin-ra-overlay {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 60, 0.55);
	z-index: 1;
	pointer-events: none;
	transition: background-color 0.4s ease;
}

/* لایه‌ی pre-load برای انتقال نرم‌تر بین تصاویر */
.abtin-ra-stage::after {
	content: "";
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	opacity: 0;
	z-index: 0;
	transition: opacity 0.5s ease;
	pointer-events: none;
}

.abtin-ra-cols {
	position: relative;
	z-index: 2;
	display: flex;
	width: 100%;
	min-height: inherit;
	height: 100%;
	align-items: stretch;
}

/* هر ستون = یک مقاله */
.abtin-ra-col {
	position: relative;
	flex: 1 1 25%;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	height: 100%;
	padding: 40px 26px 56px;
	text-decoration: none;
	transition: background-color 0.35s ease;
	cursor: pointer;
}

.abtin-ra-col:not(:last-child) {
	border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.abtin-ra-card {
	text-align: center;
	max-width: 100%;
}

.abtin-ra-card-title {
	margin: 0 0 14px;
	font-size: 22px;
	font-weight: 800;
	line-height: 1.5;
	color: #ffffff;
	text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
	transition: transform 0.35s ease;
}

.abtin-ra-card-desc {
	margin: 0 0 20px;
	font-size: 15px;
	line-height: 1.9;
	color: rgba(255, 255, 255, 0.85);
	text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}

.abtin-ra-card-btn {
	display: inline-block;
	font-size: 15px;
	font-weight: 700;
	color: #7ab4e2;
	position: relative;
	padding-bottom: 4px;
	transition: color 0.3s ease;
}

.abtin-ra-card-btn::after {
	content: "";
	position: absolute;
	right: 0;
	bottom: 0;
	width: 0;
	height: 2px;
	background: currentColor;
	transition: width 0.35s ease;
}

/* حالت hover ستون */
.abtin-ra-col:hover {
	background-color: rgba(122, 180, 226, 0.15);
}

.abtin-ra-col:hover .abtin-ra-card-title {
	transform: translateY(-6px);
}

.abtin-ra-col:hover .abtin-ra-card-btn::after {
	width: 100%;
}

/* وقتی روی یک ستون hover می‌شود، بقیه کمی محو شوند */
.abtin-ra-cols:hover .abtin-ra-col:not(:hover) .abtin-ra-card {
	opacity: 0.55;
	transition: opacity 0.35s ease;
}

.abtin-ra-card {
	opacity: 1;
	transition: opacity 0.35s ease;
}

/* --------------------------------------------------------------------------
   کاروسل موبایل (به‌صورت پیش‌فرض مخفی؛ فقط در موبایل نمایش)
   -------------------------------------------------------------------------- */
.abtin-ra-carousel {
	display: none;
	width: 100%;
	padding-bottom: 40px;
}

.abtin-ra-carousel .swiper-slide {
	height: auto;
}

.abtin-ra-slide {
	position: relative;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	min-height: 420px;
	padding: 30px 22px 44px;
	background-size: cover;
	background-position: center;
	border-radius: 12px;
	overflow: hidden;
	text-decoration: none;
}

.abtin-ra-slide-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(
		to top,
		rgba(0, 0, 60, 0.85) 0%,
		rgba(0, 0, 60, 0.35) 60%,
		rgba(0, 0, 60, 0.15) 100%
	);
	z-index: 1;
}

.abtin-ra-slide .abtin-ra-card {
	position: relative;
	z-index: 2;
}

/* صفحه‌بندی کاروسل */
.abtin-ra-carousel .swiper-pagination {
	bottom: 8px;
}

.abtin-ra-carousel .swiper-pagination-bullet {
	background: #00003c;
	opacity: 0.35;
}

.abtin-ra-carousel .swiper-pagination-bullet-active {
	opacity: 1;
	background: #7ab4e2;
}

/* --------------------------------------------------------------------------
   پیام خالی در ادیتور
   -------------------------------------------------------------------------- */
.abtin-ra-empty {
	padding: 40px;
	text-align: center;
	background: #f5f7fa;
	border: 1px dashed #c3ccd8;
	border-radius: 8px;
	color: #5b6472;
}

/* --------------------------------------------------------------------------
   نقاط شکست ریسپانسیو
   -------------------------------------------------------------------------- */

/* تبلت: ۲ ستونه */
@media (max-width: 1024px) and (min-width: 768px) {
	.abtin-ra-cols {
		flex-wrap: wrap;
	}
	.abtin-ra-col {
		flex: 1 1 50%;
		height: 50%;
	}
	.abtin-ra-col:nth-child(2) {
		border-left: none;
	}
	.abtin-ra-col:nth-child(1),
	.abtin-ra-col:nth-child(2) {
		border-bottom: 1px solid rgba(255, 255, 255, 0.2);
	}
	/* ارتفاع صحنه در تبلت هم ثابت (500px) باقی می‌ماند */
}

/* موبایل: نمایش کاروسل، مخفی کردن صحنه دسکتاپ */
@media (max-width: 767px) {
	.abtin-ra-stage {
		display: none;
	}
	.abtin-ra-carousel {
		display: block;
	}
	.abtin-ra-card-title {
		font-size: 19px;
	}
	.abtin-ra-card-desc {
		font-size: 14px;
		line-height: 1.8;
	}
}
