/* پنجره مشترک — یک پیاده‌سازی برای همه ماژول‌ها */

.brz-modal {
	position: fixed;
	inset: 0;
	z-index: 99998;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	direction: rtl;
}

.brz-modal[hidden] { display: none; }

.brz-modal__back {
	position: absolute;
	inset: 0;
	background: rgba(8, 12, 18, .72);
	backdrop-filter: blur(4px);
	animation: brz-m-fade .25s ease both;
}

@keyframes brz-m-fade { from { opacity: 0 } to { opacity: 1 } }

.brz-modal__box {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 560px;
	max-height: 88vh;
	overflow: hidden auto;
	border-radius: 24px;
	/* شیشه‌ای: پشت پنجره تار می‌شود و رنگ شاخص شرکت به‌صورت هاله دیده می‌شود */
	background: rgba(255, 255, 255, .62);
	backdrop-filter: blur(26px) saturate(180%);
	-webkit-backdrop-filter: blur(26px) saturate(180%);
	border: 1px solid rgba(255, 255, 255, .7);
	box-shadow: 0 30px 70px rgba(0, 0, 0, .38), inset 0 1px 0 rgba(255, 255, 255, .65);
	animation: brz-m-rise .34s cubic-bezier(.2, .8, .3, 1) both;
}

/* هاله رنگی گوشه بالا */
.brz-modal__box::before {
	content: "";
	position: absolute;
	top: -70px;
	inset-inline-start: -70px;
	width: 230px;
	height: 230px;
	border-radius: 50%;
	background: var(--mc, #0d2b4e);
	opacity: .34;
	filter: blur(56px);
	pointer-events: none;
	z-index: 0;
}

/* هاله دوم، گوشه پایین مخالف — عمق بیشتر */
.brz-modal__box::after {
	content: "";
	position: absolute;
	bottom: -90px;
	inset-inline-end: -80px;
	width: 220px;
	height: 220px;
	border-radius: 50%;
	background: var(--mc, #0d2b4e);
	opacity: .18;
	filter: blur(60px);
	pointer-events: none;
	z-index: 0;
}

.brz-modal__head,
.brz-modal__body,
.brz-modal__media { position: relative; z-index: 1; }

/* مرورگرهای بدون backdrop-filter پس‌زمینه مات می‌گیرند */
@supports not (backdrop-filter: blur(4px)) {
	.brz-modal__box { background: #fff; }
}

@keyframes brz-m-rise {
	from { opacity: 0; transform: translateY(22px) scale(.98) }
	to   { opacity: 1; transform: none }
}

.brz-modal__close {
	position: absolute;
	top: 14px;
	inset-inline-start: 14px;
	z-index: 3;
	display: grid;
	place-items: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(14, 15, 17, .72);
	color: #fff;
	cursor: pointer;
	transition: background .2s;
}

.brz-modal__close:hover { background: var(--brz-orange, #e8791a); color: #111; }

.brz-modal__media { position: relative; height: 220px; background: #dfe5ea; }
.brz-modal__media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.brz-modal__status {
	position: absolute;
	bottom: 14px;
	inset-inline-end: 18px;
	padding: 6px 13px;
	border-radius: 999px;
	background: var(--brz-amber, #f5a623);
	color: #111;
	font-size: .75rem;
	font-weight: 700;
}

.brz-modal__head {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 24px 22px 0;
}

.brz-modal__badge {
	display: grid;
	place-items: center;
	width: 62px;
	height: 62px;
	flex: 0 0 62px;
	border-radius: 18px;
	box-shadow: 0 8px 20px rgba(0, 0, 0, .18);
	background: var(--mc, #0d2b4e);
	color: #fff;
	font-size: 1.1rem;
	font-weight: 800;
	direction: ltr;
	overflow: hidden;
}

.brz-modal__badge img { width: 100%; height: 100%; object-fit: contain; background: #fff; }

.brz-modal__title { margin: 0; font-size: 1.2rem; font-weight: 800; color: #1c1c1e; line-height: 1.6; }
.brz-modal__sub   { margin: 2px 0 0; font-size: .8rem; color: #6b6f76; }

.brz-modal__body { padding: 18px 22px 24px; }
.brz-modal__desc { margin: 0 0 16px; font-size: .9rem; line-height: 2; color: #3f4450; }

.brz-modal__group {
	margin-bottom: 12px;
	padding: 14px 16px;
	border-radius: 16px;
	background: rgba(255, 255, 255, .55);
	border: 1px solid rgba(255, 255, 255, .7);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
}

.brz-modal__group-t {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 9px;
	font-size: .82rem;
	font-weight: 700;
	color: #1c1c1e;
}

.brz-modal__group-t::before {
	content: "";
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--mc, #0d2b4e);
}

.brz-modal__tags { display: flex; flex-wrap: wrap; gap: 6px; }

.brz-modal__tag {
	padding: 5px 13px;
	border: 1px solid rgba(0, 0, 0, .06);
	border-radius: 20px;
	background: rgba(255, 255, 255, .8);
	font-size: .78rem;
	color: #1c1c1e;
}

.brz-modal__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 9px 0;
	border-bottom: 1px solid rgba(0, 0, 0, .06);
	font-size: .82rem;
}

.brz-modal__row:last-child { border-bottom: 0; }
.brz-modal__row b { color: #1c1c1e; font-weight: 700; }
.brz-modal__row span { color: #555; direction: ltr; text-align: left; line-height: 1.8; }
/* شماره کارشناسان با رنگ اختصاصی همان شرکت */
.brz-modal__row a { color: var(--mc, var(--brz-orange, #e8791a)); text-decoration: none; font-weight: 700; }
.brz-modal__row a:hover { text-decoration: underline; }

.brz-modal__specs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 16px; }

.brz-modal__spec {
	padding: 11px 14px;
	border-radius: 14px;
	border-inline-start: 3px solid var(--mc, #0d2b4e);
	background: rgba(255, 255, 255, .6);
	border-block: 1px solid rgba(255, 255, 255, .7);
	border-inline-end: 1px solid rgba(255, 255, 255, .7);
}

.brz-modal__spec dt { margin: 0 0 3px; font-size: .7rem; color: #7b8290; }
.brz-modal__spec dd { margin: 0; font-size: .86rem; font-weight: 700; color: #1c1c1e; line-height: 1.6; }

.brz-modal__progress { margin-bottom: 18px; }

.brz-modal__progress-h {
	display: flex;
	justify-content: space-between;
	margin-bottom: 7px;
	font-size: .76rem;
	color: #6b7280;
}

.brz-modal__progress-h b { color: var(--brz-orange, #e8791a); }

.brz-modal__track { height: 8px; border-radius: 999px; background: #eceef1; overflow: hidden; }

.brz-modal__track i {
	display: block;
	width: 0;
	height: 100%;
	border-radius: 999px;
	background: linear-gradient(to left, var(--brz-orange, #e8791a), var(--brz-amber, #f5a623));
	transition: width .8s ease;
}

.brz-modal__cta {
	display: inline-block;
	margin-top: 4px;
	padding: 11px 24px;
	border-radius: 999px;
	background: var(--brz-navy, #0d2b4e);
	color: #fff;
	font-size: .86rem;
	font-weight: 700;
	text-decoration: none;
	transition: background .2s;
}

.brz-modal__cta:hover { background: var(--brz-orange, #e8791a); color: #111; }

@media (max-width: 600px) {
	.brz-modal { padding: 0; }
	.brz-modal__box { max-width: 100%; max-height: 100vh; border-radius: 0; }
	.brz-modal__specs { grid-template-columns: 1fr; }
	.brz-modal__media { height: 180px; }
}

@media (prefers-reduced-motion: reduce) {
	.brz-modal__box, .brz-modal__back { animation: none; }
	.brz-modal__track i { transition: none; }
}

/* در موبایل پنجره تمام‌صفحه می‌شود، پس هاله‌ها را ملایم‌تر می‌کنیم */
@media (max-width: 600px) {
	.brz-modal__box::before { width: 180px; height: 180px; opacity: .28; }
	.brz-modal__box::after { display: none; }
}
