/* پنل خرید — /buy/ ، /buy/my/ ، /buy/done/ ، /buy/watch/
   رنگ‌ها همان قالب: زمینه‌ی تیره‌ی قرمز و قرمزِ دکمه‌ی دانلود (#de0404). */
:root {
	--nmp-bg: #110303;
	--nmp-side: #170505;
	--nmp-card: #1f0808;
	--nmp-card-2: #280b0b;
	--nmp-line: rgba(255, 255, 255, .07);
	--nmp-line-2: rgba(255, 255, 255, .12);
	--nmp-text: #f5ecec;
	--nmp-muted: #b59d9d;
	--nmp-red: #de0404;
	--nmp-red-2: #ff3b3b;
	--nmp-green: #1fbf6a;
	--nmp-radius: 16px;
	--nmp-side-w: 272px;
}

body.nmp-body { background: var(--nmp-bg); color: var(--nmp-text); margin: 0; }
.nmp-ico { width: 20px; height: 20px; flex: none; }

.nmp { display: flex; min-height: 100vh; }

/* ───────── منوی کناری (راست) ───────── */
.nmp-side {
	position: sticky;
	top: 0;
	height: 100vh;
	width: var(--nmp-side-w);
	flex: none;
	display: flex;
	flex-direction: column;
	gap: 18px;
	padding: 22px 16px;
	box-sizing: border-box;
	background:
		radial-gradient(120% 60% at 100% 0%, rgba(222, 4, 4, .18), transparent 60%),
		var(--nmp-side);
	border-inline-start: 0;
	border-inline-end: 1px solid var(--nmp-line);
	overflow-y: auto;
}
.nmp-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--nmp-text); padding: 4px 6px 14px; border-bottom: 1px solid var(--nmp-line); }
.nmp-brand img { border-radius: 12px; box-shadow: 0 6px 18px rgba(222, 4, 4, .35); }
.nmp-brand b { display: block; font-size: 18px; font-weight: 800; line-height: 1.4; color: var(--nmp-text); }
.nmp-brand small { display: block; font-size: 12.5px; color: var(--nmp-muted); }

.nmp-user { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: rgba(255, 255, 255, .035); border: 1px solid var(--nmp-line); }
.nmp-avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, var(--nmp-red), #8a0000); color: #fff; }
.nmp-user b { display: block; font-size: 14px; }
.nmp-user small { display: block; font-size: 13px; color: var(--nmp-muted); letter-spacing: .5px; text-align: right; }

.nmp-nav { display: flex; flex-direction: column; gap: 4px; }
.nmp-nav a, .nmp-logout button {
	display: flex; align-items: center; gap: 12px;
	padding: 11px 14px; border-radius: 12px;
	color: var(--nmp-muted) !important; text-decoration: none; font: inherit; font-size: 14.5px; font-weight: 600;
	transition: background .15s, color .15s;
}
.nmp-nav a:hover { background: rgba(255, 255, 255, .05); color: var(--nmp-text) !important; }
.nmp-nav a.is-active {
	color: #fff !important;
	background: linear-gradient(90deg, rgba(222, 4, 4, .08), rgba(222, 4, 4, .28));
	box-shadow: inset -3px 0 0 var(--nmp-red);
}
.nmp-nav a.is-active .nmp-ico { color: var(--nmp-red-2); }
/* یادداشتِ شاپرک و دکمه‌ی خروج هر دو ته منو: یادداشت فضای خالی را می‌گیرد، خروج آخرین آیتم است */
.nmp-logout { margin: 0; order: 99; }
.nmp-logout button { width: 100%; background: none; border: 1px solid var(--nmp-line); cursor: pointer; }
.nmp-logout button:hover { color: #fff !important; border-color: rgba(222, 4, 4, .5); background: rgba(222, 4, 4, .1); }
.nmp-side-note { margin: auto 0 0; font-size: 12px; color: var(--nmp-muted); text-align: center; opacity: .8; }

/* ───────── ناحیه‌ی اصلی ───────── */
.nmp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.nmp-top {
	position: sticky; top: 0; z-index: 5;
	display: flex; align-items: center; gap: 12px;
	padding: 16px 32px;
	background: rgba(17, 3, 3, .82);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--nmp-line);
}
.nmp-top h1 { margin: 0; font-size: 19px; font-weight: 800; flex: 1; }
.nmp-burger, .nmp-top-logo { display: none; }
/* تمام عرضِ کنارِ منو، در هر اندازه‌ی مانیتور */
.nmp-content { padding: 28px clamp(16px, 2.5vw, 48px) 48px; width: 100%; box-sizing: border-box; }
.nmp-hero p { max-width: 900px; }

/* ───────── اجزا ───────── */
.nmp-card { background: var(--nmp-card); border: 1px solid var(--nmp-line); border-radius: var(--nmp-radius); padding: 20px; margin-bottom: 20px; }
.nmp-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.nmp-card-head h2 { margin: 0; font-size: 16px; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.nmp-card-head a { font-size: 13.5px; color: var(--nmp-red-2); text-decoration: none; }

.nmp-hero {
	position: relative; overflow: hidden;
	border-radius: var(--nmp-radius);
	padding: 26px 28px;
	margin-bottom: 20px;
	background:
		radial-gradient(90% 140% at 0% 0%, rgba(255, 59, 59, .35), transparent 55%),
		linear-gradient(135deg, #3a0a0a, #1d0606);
	border: 1px solid rgba(222, 4, 4, .3);
}
.nmp-hero h2 { margin: 0 0 6px; font-size: 22px; font-weight: 800; }
.nmp-hero p { margin: 0; color: #e7cfcf; max-width: 560px; }
.nmp-hero .nmp-hero-ico { position: absolute; left: 22px; top: 50%; transform: translateY(-50%); opacity: .14; }
.nmp-hero .nmp-hero-ico .nmp-ico { width: 110px; height: 110px; }

.nmp-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.nmp-stat { background: var(--nmp-card); border: 1px solid var(--nmp-line); border-radius: var(--nmp-radius); padding: 16px 18px; display: flex; gap: 14px; align-items: center; }
.nmp-stat .nmp-stat-ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: rgba(222, 4, 4, .14); color: var(--nmp-red-2); flex: none; }
.nmp-stat small { display: block; color: var(--nmp-muted); font-size: 12.5px; }
.nmp-stat b { display: block; font-size: 18px; font-weight: 800; }

.nmp-orders { display: flex; flex-direction: column; gap: 10px; }
.nmp-order {
	display: flex; align-items: center; gap: 14px;
	padding: 12px; border-radius: 14px;
	background: var(--nmp-card-2); border: 1px solid var(--nmp-line);
	transition: border-color .15s, transform .15s;
}
.nmp-order:hover { border-color: var(--nmp-line-2); }
.nmp-poster { width: 64px; height: 92px; border-radius: 10px; object-fit: cover; background: #000; flex: none; }
.nmp-poster-empty { display: grid; place-items: center; color: var(--nmp-muted); }
.nmp-order-info { flex: 1; min-width: 0; }
.nmp-order-info h3 { margin: 0 0 6px; font-size: 15.5px; font-weight: 800; line-height: 1.6; overflow-wrap: anywhere; }
.nmp-meta { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; color: var(--nmp-muted); font-size: 13px; }
.nmp-chip { display: inline-flex; align-items: center; padding: 1px 9px; border-radius: 999px; font-size: 12px; font-weight: 800; background: rgba(255, 255, 255, .07); color: var(--nmp-text); direction: ltr; }
.nmp-chip-ok { background: rgba(31, 191, 106, .15); color: #7ee2ab; direction: rtl; }
.nmp-order-actions { display: flex; gap: 8px; flex: none; }
.nmp-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 7px;
	padding: 10px 16px; border-radius: 11px; border: 0;
	font: inherit; font-size: 14px; font-weight: 800; text-decoration: none; cursor: pointer;
	color: #fff !important; background: linear-gradient(135deg, var(--nmp-red), #9b0000);
	box-shadow: 0 6px 16px rgba(222, 4, 4, .3);
}
.nmp-btn:hover { filter: brightness(1.1); }
.nmp-btn .nmp-ico { width: 18px; height: 18px; }
.nmp-btn-ghost { background: transparent; box-shadow: none; border: 1px solid var(--nmp-line-2); color: var(--nmp-text) !important; }
.nmp-btn-ghost:hover { background: rgba(255, 255, 255, .05); }

.nmp-empty { text-align: center; padding: 34px 16px; color: var(--nmp-muted); }
.nmp-empty .nmp-ico { width: 54px; height: 54px; color: rgba(222, 4, 4, .6); margin-bottom: 8px; }
.nmp-empty b { display: block; color: var(--nmp-text); font-size: 16px; margin-bottom: 4px; }

.nmp-tips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.nmp-tip { display: flex; gap: 12px; align-items: flex-start; background: var(--nmp-card); border: 1px solid var(--nmp-line); border-radius: var(--nmp-radius); padding: 16px; text-decoration: none; color: var(--nmp-text); }
.nmp-tip:hover { border-color: var(--nmp-line-2); }
.nmp-tip .nmp-ico { color: var(--nmp-red-2); margin-top: 3px; }
.nmp-tip b { display: block; font-size: 14.5px; }
.nmp-tip small { display: block; color: var(--nmp-muted); font-size: 13px; line-height: 1.8; }

/* ورود */
.nmp-auth { max-width: 440px; margin: 20px auto; }
.nmp-auth .nmp-card { padding: 28px 24px; }
.nmp-auth-head { text-align: center; margin-bottom: 18px; }
.nmp-auth-head .nmp-auth-ico { width: 64px; height: 64px; margin: 0 auto 10px; border-radius: 18px; display: grid; place-items: center; background: linear-gradient(135deg, var(--nmp-red), #8a0000); color: #fff; box-shadow: 0 10px 24px rgba(222, 4, 4, .35); }
.nmp-auth-head .nmp-auth-ico .nmp-ico { width: 30px; height: 30px; }
.nmp-auth-head h2 { margin: 0 0 4px; font-size: 20px; font-weight: 800; }
.nmp-auth-head p { margin: 0; color: var(--nmp-muted); font-size: 14px; }
.nmp-steps { display: flex; justify-content: center; gap: 6px; margin-bottom: 18px; }
.nmp-steps span { width: 28px; height: 5px; border-radius: 5px; background: var(--nmp-line-2); }
.nmp-steps span.on { background: var(--nmp-red); }
.nmp-code input { text-align: center !important; letter-spacing: 10px !important; font-size: 24px !important; font-weight: 800; }

/* پخش و صفحه‌ی دانلود داخل پنل */
.nmp-content .nmb-player { margin: 0 0 16px; border-radius: var(--nmp-radius); overflow: hidden; border: 1px solid var(--nmp-line); }
.nmp-content .nmb-player video { max-height: 72vh; }
.nmp-success { display: flex; gap: 14px; align-items: center; padding: 16px 18px; border-radius: var(--nmp-radius); margin-bottom: 20px; background: rgba(31, 191, 106, .1); border: 1px solid rgba(31, 191, 106, .35); }
.nmp-success .nmp-ico { width: 34px; height: 34px; color: var(--nmp-green); }
.nmp-success b { display: block; font-size: 16px; }
.nmp-success small { color: #bfe8cf; }
.nmp-content .nmb-alert { border-radius: 12px; }
.nmp-content .nmb-note { color: var(--nmp-muted); }

/* ادامه‌ی تماشا */
.nmp-resume { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: -6px 0 14px; padding: 9px 14px; border-radius: 12px; background: rgba(255, 255, 255, .05); border: 1px solid var(--nmp-line); font-size: 14px; }
.nmp-resume[hidden] { display: none; }
.nmp-resume b { direction: ltr; unicode-bidi: isolate; }
.nmp-progress { height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .1); overflow: hidden; margin-top: 8px; max-width: 260px; }
.nmp-progress > i { display: block; height: 100%; background: linear-gradient(90deg, var(--nmp-red), var(--nmp-red-2)); border-radius: 5px; }
.nmp-order .nmp-progress-note { font-size: 12.5px; color: var(--nmp-muted); }

/* راهنمای خرید (متنِ برگه‌ی /refund/) */
.nmp-prose { line-height: 2; }
.nmp-prose h2 { margin: 0 0 12px; font-size: 20px; font-weight: 800; }
.nmp-prose h2:not(:first-child) { font-size: 16.5px; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--nmp-line); }
.nmp-prose p, .nmp-prose li { color: #e3d2d2; font-size: 14.5px; }
.nmp-prose ul { padding-inline-start: 20px; }
.nmp-prose a { color: var(--nmp-red-2) !important; }
.nmp-p { margin: 0; color: #e3d2d2; line-height: 2; }

/* پشتیبانی */
.nmp-refs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.nmp-ref { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--nmp-card-2); border: 1px solid var(--nmp-line); min-width: 0; }
.nmp-ref b { color: var(--nmp-red-2); font-size: 15px; }
.nmp-ref span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; }
.nmp-tips-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 14px; }
@media (max-width: 900px) { .nmp-tips-3 { grid-template-columns: 1fr; } }

/* ───────── صفحه‌ی ورودِ مستقل (بدون منو) ───────── */
.nmp-login {
	min-height: 100vh;
	display: grid;
	place-items: center;
	padding: 32px 16px;
	box-sizing: border-box;
	background:
		radial-gradient(60% 50% at 85% 10%, rgba(222, 4, 4, .22), transparent 70%),
		radial-gradient(50% 45% at 10% 95%, rgba(222, 4, 4, .12), transparent 70%),
		var(--nmp-bg);
}
.nmp-login-grid {
	width: 100%;
	max-width: 980px;
	display: grid;
	grid-template-columns: minmax(0, 440px) minmax(0, 1fr);
	border-radius: 24px;
	overflow: hidden;
	border: 1px solid var(--nmp-line);
	background: rgba(23, 5, 5, .85);
	box-shadow: 0 30px 80px rgba(0, 0, 0, .55);
}
.nmp-login-form { padding: 34px 32px 26px; }
.nmp-login-brand { display: flex; align-items: center; justify-content: center; gap: 12px; text-decoration: none; margin-bottom: 18px; }
.nmp-login-brand img { border-radius: 14px; box-shadow: 0 8px 22px rgba(222, 4, 4, .4); }
.nmp-login-brand b { display: block; font-size: 20px; font-weight: 800; color: var(--nmp-text); line-height: 1.4; }
.nmp-login-brand small { display: block; font-size: 12.5px; color: var(--nmp-muted); }
.nmp-login .nmp-auth { max-width: none; margin: 0; }
.nmp-login .nmp-auth .nmp-card { background: transparent; border: 0; padding: 0; margin: 0; }
.nmp-login-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 18px; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--nmp-line); font-size: 13px; }
.nmp-login-links a { color: var(--nmp-muted) !important; text-decoration: none; }
.nmp-login-links a:hover { color: var(--nmp-text) !important; }

.nmp-login-art {
	position: relative;
	display: flex;
	align-items: center;
	padding: 40px;
	background:
		radial-gradient(90% 70% at 20% 20%, rgba(255, 59, 59, .38), transparent 60%),
		linear-gradient(160deg, #4a0b0b 0%, #200606 60%, #150404 100%);
	border-inline-start: 1px solid rgba(222, 4, 4, .25);
}
.nmp-login-art::after {
	content: "";
	position: absolute;
	inset: auto -60px -60px auto;
	width: 240px; height: 240px;
	border-radius: 50%;
	border: 30px solid rgba(255, 255, 255, .03);
}
.nmp-login-art-in { position: relative; z-index: 1; }
.nmp-login-art h2 { margin: 0 0 8px; font-size: 26px; font-weight: 800; line-height: 1.6; }
.nmp-login-art p { margin: 0 0 24px; color: #ecd3d3; }
.nmp-login-art ul { list-style: none; margin: 0 0 26px; padding: 0; display: grid; gap: 16px; }
.nmp-login-art li { display: flex; gap: 14px; align-items: flex-start; }
.nmp-login-art li .nmp-ico { width: 40px; height: 40px; padding: 9px; box-sizing: border-box; border-radius: 12px; background: rgba(255, 255, 255, .08); color: #fff; }
.nmp-login-art li b { display: block; font-size: 15px; }
.nmp-login-art li small { display: block; color: #d9bcbc; font-size: 13px; }
.nmp-login-art-foot { color: #cfa9a9; font-size: 12.5px; }

/* ───────── صفحه‌ی خرید/پخش بدون ورود ───────── */
.nmp-guest { min-height: 100vh; }
.nmp-guest-top {
	position: sticky; top: 0; z-index: 5;
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	padding: 12px 24px;
	background: rgba(17, 3, 3, .85); backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--nmp-line);
}
.nmp-guest-brand { border-bottom: 0; padding: 0; }
.nmp-guest-content { margin: 0 auto; max-width: 900px; }
.nmp-guest-title { margin: 0 0 18px; font-size: 20px; font-weight: 800; }

/* ───────── موبایل و تبلت ───────── */
@media (max-width: 860px) {
	.nmp-login-grid { grid-template-columns: 1fr; max-width: 460px; }
	.nmp-login-art { display: none; }
}
@media (max-width: 560px) {
	.nmp-login { padding: 16px 12px; place-items: start center; }
	.nmp-login-form { padding: 26px 18px 20px; }
	.nmp-guest-top { padding: 10px 14px; }
	.nmp-guest-top .nmp-btn { padding: 8px 12px; font-size: 13px; }
	.nmp-guest-brand small { display: none; }
}
@media (max-width: 900px) {
	.nmp-stats { grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
	.nmp-stat { flex-direction: column; align-items: flex-start; gap: 8px; padding: 14px; }
	.nmp-tips { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
	.nmp-side {
		position: fixed; right: 0; top: 0; z-index: 30;
		transform: translateX(105%); transition: transform .25s ease;
		box-shadow: -20px 0 40px rgba(0, 0, 0, .5);
	}
	.nmp.is-open .nmp-side { transform: none; }
	.nmp-scrim { position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0, .55); opacity: 0; pointer-events: none; transition: opacity .2s; }
	.nmp.is-open .nmp-scrim { opacity: 1; pointer-events: auto; }
	.nmp-burger { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--nmp-line-2); background: rgba(255, 255, 255, .04); color: var(--nmp-text); cursor: pointer; }
	.nmp-top-logo { display: block; }
	.nmp-top-logo img { display: block; border-radius: 10px; }
	.nmp-top { padding: 12px 16px; }
	.nmp-top h1 { font-size: 17px; }
	.nmp-content { padding: 18px 16px 40px; }
	.nmp-hero { padding: 20px; }
	.nmp-hero h2 { font-size: 19px; }
}
@media (max-width: 560px) {
	.nmp-stats { grid-template-columns: 1fr; }
	.nmp-stat { flex-direction: row; align-items: center; }
	.nmp-order { flex-wrap: wrap; }
	.nmp-order-actions { width: 100%; }
	.nmp-order-actions .nmp-btn { flex: 1; }
	.nmp-poster { width: 56px; height: 80px; }
}
@media (prefers-reduced-motion: reduce) {
	.nmp-side, .nmp-scrim { transition: none; }
}

/* مانیتورِ پهن: خریدها دوستونه (آخرِ فایل، تا .nmp-orders { display:flex } بالاتر رویش ننشیند) */
@media (min-width: 1400px) {
	.nmp-orders { display: grid; grid-template-columns: repeat(auto-fill, minmax(560px, 1fr)); }
}

/* لیست تماشا: فرمِ «حذف» کنارِ دکمه‌ها (1.14.0) */
.nmp-order-actions form { margin: 0; display: flex; }
.nmp-order-info h3 a { color: inherit; text-decoration: none; }
.nmp-order-info h3 a:hover { color: #ff8a8a; }
@media (max-width: 767px) {
	.nmp-order-actions form { flex: 1; }
	.nmp-order-actions form .nmp-btn { width: 100%; }
}

/* «پیشنهاد برای شما» (1.15.0) */
.nmp-sim { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.nmp-sim-item { display: flex; flex-direction: column; gap: 4px; min-width: 0; color: var(--nmp-text) !important; text-decoration: none !important; }
.nmp-sim-item img, .nmp-sim-noimg { width: 100%; aspect-ratio: 2 / 3; height: auto; object-fit: cover; border-radius: 10px; background: #000; display: flex; align-items: center; justify-content: center; }
.nmp-sim-noimg .nmp-ico { width: 34px; height: 34px; color: var(--nmp-muted); }
.nmp-sim-item b { font-size: 13px; line-height: 1.6; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.nmp-sim-item small { color: #ffd666; font-weight: 800; font-size: 12px; }
.nmp-sim-item:hover img { filter: brightness(1.1); }
@media (max-width: 1100px) { .nmp-sim { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 520px) { .nmp-sim { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
