:root {
    /* هوية باور مول — القيم الافتراضية (تتجاوزها السمة المطبّقة عند رسم الصفحة).
       تُحقن قيم السمة المختارة في <style> داخل <head> فتَسبق هذه الافتراضيات. */
    --pm-primary: #ff6a00;      /* اللون الأساسي — الأزرار والروابط والأسعار */
    --pm-primary-rgb: 255, 106, 0;
    --pm-accent: #ff8a33;       /* التمييز الثانوي */
    --pm-accent-rgb: 255, 138, 51;
    --pm-price: #ff6a00;        /* لون عرض الأسعار */
    --pm-dark: #1a1a1d;         /* الأطر الداكنة — الشريط العلوي والتذييل واللوحة */
    --pm-bg: #1a1a1d;           /* خلفية الصفحة */
    --pm-surface: #2e2e33;      /* البطاقات واللوحات والحقول */
    --pm-surface-2: #26262b;    /* أسطح غائرة (صور مصغّرة، رؤوس الجداول) */
    --pm-ink: #111114;          /* أغمق درجة */
    --pm-line: #3a3a40;         /* حدود رفيعة */
    --pm-text: #e6e6e6;         /* نص أساسي */
    --pm-heading: #ffffff;      /* عناوين */
    --pm-steel: #9a9aa2;        /* نص ثانوي/باهت */

    /* ارتفاع شريط التنقّل السفلي (بلا المساحة الآمنة) — مصدر واحد للحقيقة
       يُستخدم لإفساح المجال أسفل الصفحة وللأزرار العائمة على الجوال. */
    --pm-bottom-nav-h: 68px;
}

/* جسر ألوان Bootstrap: يتبع متغيّرات ‎--pm-*‎ مهما كانت السمة (فاتحة أو داكنة).
   المُحدِّد ‎html[data-bs-theme]‎ يتفوّق على قواعد Bootstrap للوضعين معاً. */
html[data-bs-theme] {
    --bs-body-bg: var(--pm-bg);
    --bs-body-color: var(--pm-text);
    --bs-emphasis-color: var(--pm-heading);
    --bs-secondary-bg: var(--pm-surface);
    --bs-tertiary-bg: var(--pm-surface-2);
    --bs-border-color: var(--pm-line);
    --bs-primary: var(--pm-primary);
    --bs-primary-rgb: var(--pm-primary-rgb);
    --bs-link-color: var(--pm-accent);
    --bs-link-color-rgb: var(--pm-accent-rgb);
    --bs-link-hover-color: var(--pm-primary);
    --bs-warning: var(--pm-accent);
    --bs-warning-rgb: var(--pm-accent-rgb);
}

/* أزرار Bootstrap مبنيّة على متغيّرات السمة؛ درجات التمرير تُشتقّ عبر color-mix */
.btn-primary {
    --bs-btn-bg: var(--pm-primary); --bs-btn-border-color: var(--pm-primary); --bs-btn-color: #fff;
    --bs-btn-hover-bg: color-mix(in srgb, var(--pm-primary) 88%, #000); --bs-btn-hover-border-color: color-mix(in srgb, var(--pm-primary) 88%, #000); --bs-btn-hover-color: #fff;
    --bs-btn-active-bg: color-mix(in srgb, var(--pm-primary) 78%, #000); --bs-btn-active-border-color: color-mix(in srgb, var(--pm-primary) 78%, #000); --bs-btn-active-color: #fff;
    --bs-btn-disabled-bg: var(--pm-primary); --bs-btn-disabled-border-color: var(--pm-primary); --bs-btn-disabled-color: #fff;
}
.btn-outline-primary {
    --bs-btn-color: var(--pm-accent); --bs-btn-border-color: var(--pm-primary);
    --bs-btn-hover-bg: var(--pm-primary); --bs-btn-hover-border-color: var(--pm-primary); --bs-btn-hover-color: #fff;
    --bs-btn-active-bg: var(--pm-primary); --bs-btn-active-border-color: var(--pm-primary); --bs-btn-active-color: #fff;
}
/* الرمادي الثابت في ‎btn-outline-secondary‎ يبهت على الخلفيات الداكنة — يتبع ألوان السمة */
.btn-outline-secondary {
    --bs-btn-color: var(--pm-text); --bs-btn-border-color: var(--pm-line);
    --bs-btn-hover-bg: var(--pm-surface-2); --bs-btn-hover-border-color: var(--pm-steel); --bs-btn-hover-color: var(--pm-heading);
    --bs-btn-active-bg: var(--pm-surface-2); --bs-btn-active-border-color: var(--pm-steel); --bs-btn-active-color: var(--pm-heading);
    --bs-btn-disabled-color: var(--pm-steel); --bs-btn-disabled-border-color: var(--pm-line);
}
.btn-warning {
    --bs-btn-bg: var(--pm-accent); --bs-btn-border-color: var(--pm-accent); --bs-btn-color: #1a1a1d;
    --bs-btn-hover-bg: color-mix(in srgb, var(--pm-accent) 88%, #fff); --bs-btn-hover-border-color: color-mix(in srgb, var(--pm-accent) 88%, #fff); --bs-btn-hover-color: #1a1a1d;
    --bs-btn-active-bg: color-mix(in srgb, var(--pm-accent) 82%, #000); --bs-btn-active-border-color: color-mix(in srgb, var(--pm-accent) 82%, #000); --bs-btn-active-color: #1a1a1d;
}

html, body {
    font-family: 'Tajawal', 'Segoe UI', Tahoma, sans-serif;
    background-color: var(--pm-bg);
    color: var(--pm-text);
}

h1, h2, h3, h4, h5, h6 { color: var(--pm-heading); }

a {
    color: var(--pm-primary);
    text-decoration: none;
}
a:hover { text-decoration: underline; }

h1:focus { outline: none; }

/* ---------- لمسات عامّة ---------- */
.btn { border-radius: .55rem; }
.card { border-radius: .75rem; border-color: var(--pm-line); background-color: var(--pm-surface); }
.pm-navbar .navbar-brand { letter-spacing: .5px; }
.form-control, .form-select { border-radius: .5rem; }
.pagination .page-link { color: var(--pm-text); border-radius: .4rem; margin: 0 .1rem; }
.pagination .page-item.active .page-link { background: var(--pm-primary); border-color: var(--pm-primary); color: #fff; }
/* تحسينات الجوال */
@media (max-width: 576px) {
    .container { padding-inline: .75rem; }
    .product-thumb { height: 150px; }
    .display-6 { font-size: 1.6rem; }
}

/* ---------- شريط التنقّل ---------- */
.pm-navbar {
    background: var(--pm-dark);
    border-bottom: 1px solid var(--pm-line);
}
.pm-navbar .navbar-brand { font-weight: 700; color: #fff; }
.pm-navbar .nav-link { color: #c7c7cf !important; }
.pm-navbar .nav-link:hover, .pm-navbar .nav-link.active { color: #fff !important; }

/* «تثبيت التطبيق» في قائمة الجوال: زرّ (لا رابط) لأنه يفتح نافذة لا صفحة،
   فنُلبسه هيئة بقيّة روابط القائمة ونُزيل خلفية الزرّ وحدوده. */
.pm-navbar .pm-nav-install {
    display: flex;
    align-items: center;
    gap: .45rem;
    width: 100%;
    background: none;
    border: 0;
    text-align: inherit;
    padding-inline-start: 0;
}
.pm-navbar .pm-nav-install svg { flex: none; }

/* زرّ فتح القائمة: الشريط داكن دائماً في الوضعين، لذا نُثبّت أيقونة بيضاء
   وحدوداً خفيفة بدل bg-light (التي تصبح رمادية داكنة في الوضع الداكن وتختفي). */
.pm-navbar .pm-navbar-toggler {
    border-color: rgba(255, 255, 255, .35);
    background-color: rgba(255, 255, 255, .08);
}
.pm-navbar .pm-navbar-toggler:focus { box-shadow: 0 0 0 .2rem rgba(255, 255, 255, .2); }
.pm-navbar .pm-navbar-toggler .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ---------- علامة/كلمة الشعار ---------- */
/* الارتفاع مفروض هنا لا في ملف الشعار: الشعار صار يُرفع من الإعدادات، وملف SVG
   بلا width/height (وهو الشائع) يُحسب بلا أبعاد فيختفي، والصورة النقطية الكبيرة
   تمطّ الترويسة. القياس نفسه الذي كان يحمله الشعار الافتراضي، فلا يتغيّر المظهر. */
.pm-logo-mark {
    display: inline-block;
    vertical-align: middle;
    height: 30px;
    width: auto;
    max-width: 190px;
    object-fit: contain;
}
.pm-wordmark {
    font-family: 'Tajawal', 'Segoe UI', Tahoma, sans-serif;
    font-weight: 700; letter-spacing: 1.5px; line-height: 1; text-transform: uppercase;
}
.pm-wordmark-accent { color: var(--pm-primary); }

/* زرّ تبديل الوضع الفاتح/الداكن: نُظهر أيقونة الوضع الذي سيُنتقل إليه */
.pm-theme-toggle { line-height: 1; }
html[data-bs-theme="dark"] .pm-theme-toggle .pm-icon-dark { display: none; }
html[data-bs-theme="light"] .pm-theme-toggle .pm-icon-light { display: none; }

/* نقاط عيّنات الألوان في إدارة السمات */
.pm-theme-dot { display: inline-block; width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--pm-line); flex: none; }
.pm-theme-swatches { display: flex; gap: 6px; align-items: center; }
.pm-theme-swatch { width: 26px; height: 26px; border-radius: 6px; border: 1px solid var(--pm-line); flex: none; }

/* معاينة شعارات الهوية البصرية في الإعدادات: نصف فاتح ونصف داكن جنباً إلى جنب،
   لأن شعاراً أبيض يختفي على الفاتح وأسودَ يختفي على الداكن، والمتجر يقدّم الوضعين.
   رقعة الشطرنج في النصف الفاتح تكشف الأجزاء الشفّافة. */
.pm-brand-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 88px;
    border: 1px solid var(--pm-line);
    border-radius: .6rem;
    overflow: hidden;
}

.pm-brand-preview > div {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .45rem;
    min-width: 0;
}

.pm-brand-preview .pm-brand-light {
    background-color: #f2f2f4;
    background-image: linear-gradient(45deg, #d9d9de 25%, transparent 25%, transparent 75%, #d9d9de 75%),
                      linear-gradient(45deg, #d9d9de 25%, transparent 25%, transparent 75%, #d9d9de 75%);
    background-size: 16px 16px;
    background-position: 0 0, 8px 8px;
}

.pm-brand-preview .pm-brand-dark { background-color: #26262b; }

.pm-brand-preview img { max-width: 100%; max-height: 100%; object-fit: contain; }

.pm-cart-badge {
    background: var(--pm-accent);
    color: #1a1a1d;
    font-size: .7rem;
}

/* رابط في التذييل: التذييل داكن في كل السمات، فالنصّ أبيض شبه شفّاف يتّضح عند المرور */
.pm-footer-link {
    color: rgba(255,255,255,.78);
    text-decoration: none;
    font-weight: 600;
}
.pm-footer-link:hover,
.pm-footer-link:focus-visible { color: #fff; text-decoration: underline; }

/* ---------- شريط التنقّل السفلي (الجوال فقط) ---------- */
.pm-bottom-nav {
    position: fixed;
    bottom: 0;
    inset-inline: 0;
    z-index: 1080;
    display: flex;
    align-items: stretch;
    justify-content: space-around;
    gap: .1rem;
    min-height: calc(var(--pm-bottom-nav-h) + env(safe-area-inset-bottom, 0px));
    padding: .3rem .3rem calc(.25rem + env(safe-area-inset-bottom, 0px));
    background: var(--pm-dark); /* البديل للمتصفّحات دون backdrop-filter؛ الزجاج المُعتم في @supports أدناه */
    border-top: 1px solid color-mix(in srgb, var(--pm-line) 75%, transparent);
    border-radius: 1.1rem 1.1rem 0 0;
    box-shadow: 0 -.5rem 1.5rem rgba(0,0,0,.45);
    /* الشريط داكن في كل السمات، لذا نُفتِّح اللون الأساسي قليلاً ليبقى واضحاً عليه
       ونستخدم الأبيض للنص بدل ‎--pm-heading‎ (يكون داكناً في السمات الفاتحة). */
    --pm-bottom-on: color-mix(in srgb, var(--pm-primary) 72%, #fff);
}
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {
    .pm-bottom-nav {
        background: color-mix(in srgb, var(--pm-dark) 85%, transparent);
        -webkit-backdrop-filter: blur(16px) saturate(150%);
        backdrop-filter: blur(16px) saturate(150%);
    }
}
.pm-bottom-item,
.pm-bottom-cart {
    position: relative;
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .2rem;
    padding: .3rem .1rem;
    border-radius: .85rem;
    color: rgba(255,255,255,.66);
    text-decoration: none;
    font-size: .68rem;
    line-height: 1;
    -webkit-tap-highlight-color: transparent;
    transition: color .18s ease, transform .18s ease;
}
.pm-bottom-item:hover,
.pm-bottom-item:focus-visible { text-decoration: none; color: #fff; }
.pm-bottom-item:active { transform: scale(.94); }

/* الأيقونة داخل حاوية دائرية تُظلّل عند التنشيط */
.pm-bottom-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 28px;
    border-radius: .7rem;
    transition: background-color .18s ease, color .18s ease;
}
.pm-bottom-icon svg { width: 21px; height: 21px; }
.pm-bottom-label {
    max-width: 100%;
    font-weight: 600;
    letter-spacing: .2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* العنصر النشط: لون أساسي + هالة خلف الأيقونة + مؤشّر رفيع على حافة الشريط */
.pm-bottom-item.active { color: var(--pm-bottom-on); }
.pm-bottom-item.active .pm-bottom-icon { background: rgba(var(--pm-primary-rgb), .18); }
.pm-bottom-item.active::before {
    content: "";
    position: absolute;
    top: -.3rem;
    inset-inline: 32%;
    height: 3px;
    border-radius: 0 0 3px 3px;
    background: var(--pm-bottom-on);
    box-shadow: 0 0 .5rem rgba(var(--pm-primary-rgb), .85);
}

/* زر السلة البارز في المنتصف (يطفو فوق الشريط مثل الصورة المرجعية) */
.pm-bottom-cart { color: #fff; margin-top: -20px; gap: .28rem; }
.pm-bottom-cart:hover,
.pm-bottom-cart:focus-visible { text-decoration: none; color: #fff; }
.pm-bottom-cart.active { color: var(--pm-bottom-on); }
.pm-bottom-cart-circle {
    position: relative;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    /* تدرّج من درجة أفتح إلى اللون الأساسي — يبقى بنفس الدرجة اللونية في كل السمات */
    background: linear-gradient(145deg, color-mix(in srgb, var(--pm-primary) 72%, #fff), var(--pm-primary));
    /* حلقة بلون الشريط تفصل الزر عن الحافة وتُعطي إحساس الطفو */
    border: 3px solid var(--pm-dark);
    box-shadow: 0 .35rem .9rem rgba(var(--pm-primary-rgb), .45), inset 0 1px 0 rgba(255,255,255,.28);
    transition: transform .18s ease, box-shadow .18s ease;
}
.pm-bottom-cart-circle svg { width: 24px; height: 24px; }
.pm-bottom-cart:active .pm-bottom-cart-circle {
    transform: scale(.93);
    box-shadow: 0 .2rem .6rem rgba(var(--pm-primary-rgb), .4), inset 0 1px 0 rgba(255,255,255,.28);
}
/* شارة العدد على عنصر عادي في الشريط (طلباتي): أصغر قليلاً من شارة السلة لأن
   الأيقونة هنا 36×28 لا دائرة 52px، وبإطار بلون الشريط ليُفصلها عن الأيقونة. */
.pm-bottom-badge {
    min-width: 17px;
    height: 17px;
    padding: 0 .22rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .58rem;
    line-height: 1;
    border: 2px solid var(--pm-dark);
}

/* شارة عدد عناصر السلة على الزر الدائري */
.pm-bottom-cart-circle .pm-cart-badge {
    min-width: 19px;
    height: 19px;
    padding: 0 .25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .62rem;
    line-height: 1;
    border: 2px solid var(--pm-dark);
}

@media (prefers-reduced-motion: reduce) {
    .pm-bottom-item,
    .pm-bottom-cart-circle { transition: none; }
    .pm-bottom-item:active,
    .pm-bottom-cart:active .pm-bottom-cart-circle { transform: none; }
}

/* ---------- بطاقة المنتج ---------- */
.product-card {
    border: 1px solid var(--pm-line);
    border-radius: .75rem;
    background: var(--pm-surface);
    overflow: hidden;
    transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease;
    height: 100%;
}
.product-card:hover { box-shadow: 0 .5rem 1.25rem rgba(0,0,0,.5); border-color: var(--pm-primary); transform: translateY(-2px); }
.product-thumb {
    width: 100%; height: 190px; object-fit: cover; background: var(--pm-surface-2);
    display: flex; align-items: center; justify-content: center; color: var(--pm-steel);
}
.price-now { color: var(--pm-price); font-weight: 700; font-size: 1.15rem; }
.price-old { color: var(--pm-steel); text-decoration: line-through; font-size: .9rem; }
/* عنوان البطاقة (منتج/عرض/حزمة/فئة): يتبع لون العناوين حسب السمة بدل text-dark الثابت */
.pm-card-title { color: var(--pm-heading); text-decoration: none; }
a.pm-card-title:hover { color: var(--pm-primary); }
.discount-badge {
    background: var(--pm-accent); color: #1a1a1d; border-radius: .5rem;
    padding: .1rem .5rem; font-size: .8rem; font-weight: 700;
}

/* ---------- منتج مميّز ---------- */
.product-featured { border-color: var(--pm-primary); box-shadow: 0 0 0 2px var(--pm-primary) inset; }
.product-featured:hover { box-shadow: 0 0 0 2px var(--pm-primary) inset, 0 .5rem 1.25rem rgba(0,0,0,.5); }
.featured-badge {
    position: absolute; top: 10px; inset-inline-end: 10px;
    background: var(--pm-primary); color: #fff;
    font-size: .75rem; font-weight: 700; padding: .15rem .55rem; border-radius: .4rem;
    box-shadow: 0 .1rem .35rem rgba(0,0,0,.4);
}

/* ---------- منتج غير متوفّر ---------- */
.product-unavailable .product-thumb,
.product-unavailable .price-now,
.product-unavailable .price-old { filter: grayscale(1); opacity: .6; }
.unavailable-ribbon {
    position: absolute; top: 10px; inset-inline-start: 10px;
    background: #55555c; color: #fff; font-size: .75rem; font-weight: 600;
    padding: .15rem .5rem; border-radius: .4rem;
}

/* ---------- المفضّلة ---------- */
/* زرّ القلب: شفّاف حتى يُفعَّل، فيمتلئ بلون التمييز. يُستعمل عائماً فوق صورة البطاقة
   (pm-fav-float) أو كزرّ بنصّ في صفحة المنتج (pm-fav-inline). */
.pm-fav-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
    background: none; border: none; padding: 0; line-height: 1;
    color: var(--pm-steel); cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: color .15s ease, transform .15s ease, background-color .15s ease;
}
.pm-fav-btn svg { width: 22px; height: 22px; }
.pm-fav-btn:hover { color: var(--pm-accent); }
.pm-fav-btn:active { transform: scale(.9); }
.pm-fav-btn.is-on { color: var(--pm-accent); }

/* القلب العائم فوق صورة البطاقة — قرص معتم كي يظهر على أي صورة */
.pm-fav-float {
    position: absolute; top: .5rem; inset-inline-start: .5rem;
    width: 34px; height: 34px; border-radius: 50%;
    background: rgba(0,0,0,.42); color: #fff;
    backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px);
    box-shadow: 0 .1rem .35rem rgba(0,0,0,.35);
}
.pm-fav-float svg { width: 19px; height: 19px; }
.pm-fav-float:hover { background: rgba(0,0,0,.55); color: var(--pm-accent); }

/* زرّ المفضّلة بنصّ في صفحة المنتج */
.pm-fav-inline {
    border: 1px solid var(--pm-line); border-radius: .5rem;
    padding: .45rem .9rem; font-weight: 600; color: var(--pm-text);
}
.pm-fav-inline:hover { border-color: var(--pm-accent); color: var(--pm-accent); }
.pm-fav-inline.is-on { border-color: var(--pm-accent); color: var(--pm-accent); }

/* أيقونة في شريط التنقّل العلوي (الجوال): المفضّلة والتواصل — خارج القائمة المطوية
   كي تبقى ظاهرة بلا فتحها. */
.pm-nav-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: .6rem; color: #fff; text-decoration: none;
}
.pm-nav-icon svg { width: 22px; height: 22px; }
.pm-nav-icon:hover { color: var(--pm-accent); }
/* الشارة على الحافة الابتدائية للأيقونة — الجهة المقابلة لزرّ القائمة في الاتجاهين */
.pm-fav-nav-badge {
    position: absolute; top: 0; inset-inline-start: 0;
    min-width: 18px; padding: .1rem .3rem; line-height: 1;
}

@media (prefers-reduced-motion: reduce) {
    .pm-fav-btn { transition: none; }
    .pm-fav-btn:active { transform: none; }
}

/* ---------- فئة ---------- */
.category-grid {
    display: flex; flex-wrap: wrap; gap: 1.5rem 1.75rem;
}
.category-tile {
    display: block; text-align: center; text-decoration: none; width: 6.5rem;
}
.category-tile:hover { text-decoration: none; }
.category-tile:hover .category-icon {
    box-shadow: 0 .4rem 1rem rgba(0,0,0,.45);
    border-color: var(--pm-primary);
    transform: scale(1.07)
}
.category-icon {
    width: 72px; height: 72px; object-fit: cover; border-radius: 50%;
    background: var(--pm-surface-2); border: 1px solid var(--pm-line); margin-inline: auto;
    transition: box-shadow .15s ease, border-color .15s ease;
}

/* ---------- السلايدر الرئيسي ---------- */
.hero-carousel { border-radius: 1rem; overflow: hidden; box-shadow: 0 .5rem 1.5rem rgba(0,0,0,.5); }
.hero-slide {
    min-height: 340px; color: #fff; display: flex; align-items: center;
}
/* هامش جانبي كافٍ حتى لا يتداخل النص مع أزرار التنقّل (الأسهم) */
.hero-slide-body { padding: 2.5rem 4.5rem; max-width: 640px; }
.hero-slide-body h2 { font-size: clamp(1.6rem, 4vw, 2.6rem); color: #fff; }
/* تصغير منطقة أزرار التنقّل وإبرازها على دائرة شبه شفافة */
.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next { width: 3.5rem; }
.hero-carousel .carousel-control-prev-icon,
.hero-carousel .carousel-control-next-icon {
    background-color: rgba(0,0,0,.45); border-radius: 50%; padding: 1rem;
    background-size: 50%;
}
@media (max-width: 576px) {
    .hero-slide { min-height: 240px; }
    .hero-slide-body { padding: 1.5rem 3rem; }
    .hero-carousel .carousel-control-prev,
    .hero-carousel .carousel-control-next { width: 2.5rem; }
}

/* ---------- بانر العروض ---------- */
.offer-banner {
    border-radius: 1rem; color: #fff; padding: 2.5rem 2rem; min-height: 220px;
    display: flex; flex-direction: column; justify-content: center;
    background: linear-gradient(120deg, var(--pm-ink), var(--pm-primary));
    background-size: cover; background-position: center;
}

/* ---------- لوحة التحكم ---------- */
.admin-sidebar { background: var(--pm-dark); min-height: 100vh; border-inline-end: 1px solid var(--pm-line); }
/* تثبيت الشريط الجانبي على الشاشات المتوسطة فأكبر، مع تمرير مستقل عند الحاجة */
@media (min-width: 768px) {
    .admin-sidebar {
        position: sticky;
        top: 0;
        height: 100vh;
        overflow-y: auto;
    }
}
.admin-sidebar .nav-link { color: #c7c7cf; border-radius: .4rem; padding-top: .35rem; padding-bottom: .35rem; }
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active { background: rgba(255,255,255,.10); color: #fff; }
/* تقليص الفراغات لتفادي التمرير في الشريط الجانبي */
.admin-sidebar { padding-top: .85rem !important; padding-bottom: .85rem !important; }
.admin-sidebar hr { margin-top: .6rem; margin-bottom: .6rem; }

/* بطاقة سعر الصرف في الشريط الجانبي */
.admin-rate {
    background: rgba(255,255,255,.06);
    border: 1px solid var(--pm-line);
    border-radius: .5rem;
    padding: .45rem .6rem;
    transition: background .15s ease;
}
.admin-rate:hover { background: rgba(255,255,255,.10); }
.admin-rate-label { color: #c7c7cf; font-size: .82rem; }
.admin-rate-value { color: #fff; font-weight: 700; font-size: .9rem; }
.admin-rate-updated { color: rgba(255,255,255,.5); font-size: .72rem; margin-top: .15rem; }

/* عزل التواريخ/الأوقات (محتوى LTR) عن اتجاه الواجهة العربية RTL كي لا يُعاد ترتيب
   مقاطعها (مثل ظهور «PM 04:13 2026-07-09»)، مع إبقائها على سطر واحد. */
.pm-ltr { direction: ltr; unicode-bidi: isolate; white-space: nowrap; }

/* ---------- جداول Bootstrap — تتبع ألوان السمة ---------- */
/* تستبدل ‎bg-white‎/‎table-light‎ الثابتة لتظهر بشكل صحيح في الأنماط الداكنة والفاتحة.
   ‎pm-admin-table‎ اسم مرادف قديم تستخدمه جداول لوحة التحكم. */
.table.pm-table,
.table.pm-admin-table {
    --bs-table-color: var(--pm-text);
    --bs-table-bg: var(--pm-surface);
    --bs-table-border-color: var(--pm-line);
    --bs-table-striped-color: var(--pm-text);
    --bs-table-hover-color: var(--pm-text);
    border-color: var(--pm-line);
}
/* شرائح الرأس والتذييل على سطح غائر بدل ‎table-light‎ الثابتة */
/* جداول لوحة التحكم تُطابَق على ‎thead‎ نفسه لا على ‎pm-thead‎، لأن ‎QuickGrid‎
   (جدول المنتجات) يُصدر رأسه بنفسه فلا يمكن إعطاؤه صنفاً. */
.table.pm-table > thead.pm-thead,
.table.pm-table > tfoot.pm-tfoot,
.table.pm-admin-table > thead {
    --bs-table-color: var(--pm-heading);
    --bs-table-bg: var(--pm-surface-2);
}

/* ---------- قائمة افتراضية (Virtualize) ---------- */
/* تمرير أفقي فقط للجدول العريض؛ التمرير العمودي يتكفّل به تمرير الصفحة الرئيسي (شريط تمرير واحد). */
.admin-table {
    overflow-x: auto;
    background: var(--pm-surface);
    border: 1px solid var(--pm-line);
    border-radius: .75rem;
    box-shadow: 0 1px 2px rgba(0,0,0,.3);
}
/* الرأس والصفوف بنفس العرض الأدنى ليبقيا متطابقين عند التمرير الأفقي. */
.admin-table-head {
    position: sticky; top: 0; z-index: 2;
    background: var(--pm-surface-2); min-width: 1000px;
    border-bottom: 1px solid var(--pm-line);
    color: var(--pm-steel); font-weight: 600;
    font-size: .72rem; text-transform: uppercase; letter-spacing: .04em;
}
.admin-row { min-width: 1000px; border-bottom: 1px solid var(--pm-line); transition: background .12s ease; }
.admin-row:last-child { border-bottom: 0; }
.admin-row:hover { background: color-mix(in srgb, var(--pm-primary) 8%, transparent); }
.admin-row-hidden { background: color-mix(in srgb, var(--pm-steel) 10%, transparent); opacity: .78; }
.admin-row-hidden:hover { opacity: 1; }

/* صورة مصغّرة للمنتج داخل الجدول */
.admin-thumb {
    width: 48px; height: 48px;
    object-fit: cover; border-radius: .5rem;
    border: 1px solid var(--pm-line);
}
.admin-thumb-empty {
    display: flex; align-items: center; justify-content: center;
    border-style: dashed; border-color: var(--pm-line);
    background: var(--pm-surface-2); color: var(--pm-steel); font-size: 1.1rem;
}
.admin-name { font-weight: 600; color: var(--pm-text); line-height: 1.25; }
.admin-cat-chip {
    display: inline-block; max-width: 100%;
    background: var(--pm-line); color: var(--pm-text);
    border-radius: 1rem; padding: .15rem .6rem;
    font-size: .78rem; white-space: nowrap;
    overflow: hidden; text-overflow: ellipsis;
}
.admin-price { font-weight: 600; color: var(--pm-text); }
.admin-price-off { font-weight: 600; color: #34c759; }

/* شارات الحالة الناعمة (داكنة) */
.admin-badge-avail   { background: rgba(52,199,89,.16); color: #4cd964; }
.admin-badge-unavail { background: color-mix(in srgb, var(--pm-steel) 16%, transparent); color: var(--pm-steel); }
.admin-badge-featured{ background: color-mix(in srgb, var(--pm-primary) 16%, transparent); color: var(--pm-accent); }
.admin-badge-hidden  { background: color-mix(in srgb, var(--pm-steel) 12%, transparent); color: var(--pm-steel); }

.admin-empty-icon { font-size: 2.25rem; opacity: .7; }

/* ---------- جدول المنتجات عبر QuickGrid ---------- */
.admin-quickgrid { min-width: 1000px; margin-bottom: 0; }
.admin-quickgrid > thead > tr > th {
    color: var(--pm-steel); font-weight: 600;
    font-size: .72rem; text-transform: uppercase; letter-spacing: .04em;
    white-space: nowrap; vertical-align: middle;
    /* بلا حشوة أفقية: غلاف عنوان ‎QuickGrid‎ نفسه يضيف 1.4rem من جهة البداية،
       أي نفس حشوة الخلايا، فتصطفّ العناوين مع محتوى أعمدتها. */
    padding: .55rem 0;
    border-bottom: 1px solid var(--pm-line);
}
.admin-quickgrid > tbody > tr { transition: background .12s ease; }
.admin-quickgrid > tbody > tr:hover { background: color-mix(in srgb, var(--pm-primary) 8%, transparent); }
.admin-quickgrid > tbody > tr.admin-row-hidden { background: color-mix(in srgb, var(--pm-steel) 10%, transparent); opacity: .78; }
.admin-quickgrid > tbody > tr.admin-row-hidden:hover { opacity: 1; }
.admin-quickgrid .col-img { width: 64px; }
.admin-quickgrid .col-name { min-width: 170px; }
.admin-quickgrid .col-actions { width: 240px; }

/* ---------- أقسام نماذج لوحة التحكم (نافذة إضافة/تعديل) ---------- */
.pm-form-section {
    padding: 1rem 1.1rem;
    border: 1px solid var(--pm-line);
    border-radius: .65rem;
    background: var(--pm-surface);
}
.pm-form-section + .pm-form-section { margin-top: 1rem; }
.pm-form-section-title {
    font-weight: 700; font-size: .92rem; color: var(--pm-text);
    margin-bottom: .9rem; padding-bottom: .55rem;
    border-bottom: 1px solid var(--pm-line);
    display: flex; align-items: center; gap: .4rem;
}
.pm-form-section .form-switch { padding-top: .1rem; }
.pm-form-section .form-check-label { cursor: pointer; }

/* ---------- تبديل الصورة الرئيسية في صفحات التفاصيل ---------- */
/* عامّة (لا معزولة) لأن الصورة يرسمها مكوّن ImageViewer المشترك. */
.pm-main-img { will-change: transform, opacity; }
.pm-main-img.pm-slide-next { animation: pm-img-slide-next .3s ease-out; }
.pm-main-img.pm-slide-prev { animation: pm-img-slide-prev .3s ease-out; }
/* في التخطيط من اليمين لليسار يتقدّم "التالي" نحو اليسار، فيدخل من اليسار. */
@keyframes pm-img-slide-next {
    from { opacity: 0; transform: translateX(-24px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes pm-img-slide-prev {
    from { opacity: 0; transform: translateX(24px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* ---------- معاينة الرفع وضبط موضع الاقتصاص ---------- */
/* الإطار يعرض تماماً الجزء الذي سيظهر للزبون، والمشرف يسحب الصورة داخله لاختياره. */
.pm-focal {
    position: relative; flex: none;
    border: 1px solid var(--pm-line); border-radius: .5rem;
    background: var(--pm-surface-2); overflow: hidden;
    cursor: grab;
    touch-action: none;           /* السحب للتحريك لا لتمرير الصفحة */
    user-select: none;
}
.pm-focal.is-dragging { cursor: grabbing; }
/* صورة بنسبة الإطار نفسها لا تُقتصّ، فلا شيء يُحرَّك. */
.pm-focal.is-fixed { cursor: default; }

.pm-focal-img {
    display: block; width: 100%; height: 100%; object-fit: cover;
    -webkit-user-drag: none; user-select: none; pointer-events: none;
}

/* شبكة أثلاث خفيفة أثناء السحب تساعد على ضبط الكادر. */
.pm-focal.is-dragging::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background:
        linear-gradient(to right, transparent calc(33.33% - 1px), rgba(255,255,255,.45) calc(33.33% - 1px),
            rgba(255,255,255,.45) 33.33%, transparent 33.33%, transparent calc(66.66% - 1px),
            rgba(255,255,255,.45) calc(66.66% - 1px), rgba(255,255,255,.45) 66.66%, transparent 66.66%),
        linear-gradient(to bottom, transparent calc(33.33% - 1px), rgba(255,255,255,.45) calc(33.33% - 1px),
            rgba(255,255,255,.45) 33.33%, transparent 33.33%, transparent calc(66.66% - 1px),
            rgba(255,255,255,.45) calc(66.66% - 1px), rgba(255,255,255,.45) 66.66%, transparent 66.66%);
    box-shadow: inset 0 0 0 2px var(--pm-primary);
}

/* أيقونة تلميح للسحب تختفي أثناءه. */
.pm-focal-grip {
    position: absolute; inset-block-end: .25rem; inset-inline-end: .25rem;
    width: 1.35rem; height: 1.35rem; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: .75rem; line-height: 1; color: #fff;
    background: rgba(0,0,0,.45); pointer-events: none;
    transition: opacity .15s ease;
}
.pm-focal.is-dragging .pm-focal-grip,
.pm-focal.is-fixed .pm-focal-grip { opacity: 0; }

.pm-focal-empty {
    display: flex; align-items: center; justify-content: center;
    border-style: dashed; color: var(--pm-steel); cursor: default;
}

/* ---------- شريط تصفية المنتجات (سطر واحد) ---------- */
.pm-filter-bar .input-group-text {
    background: var(--pm-surface-2); color: var(--pm-steel);
    font-size: .82rem; font-weight: 600;
    border-color: var(--pm-line);
}
.pm-filter-bar .form-select, .pm-filter-bar .form-control { border-color: var(--pm-line); }

/* ---------- اسم/صورة المنتج القابلان للنقر + نافذة التفاصيل ---------- */
.admin-thumb-clickable { cursor: pointer; transition: transform .12s ease, box-shadow .12s ease; }
.admin-thumb-clickable:hover { transform: scale(1.06); box-shadow: 0 .2rem .5rem rgba(0,0,0,.5); }
.admin-name-link {
    border: 0; background: none; padding: 0; text-align: inherit;
    color: var(--pm-text); font-weight: 600; cursor: pointer;
}
.admin-name-link:hover { color: var(--pm-primary); text-decoration: underline; }

.pm-view-main-img {
    width: 100%; aspect-ratio: 1 / 1; object-fit: cover;
    border-radius: .6rem; border: 1px solid var(--pm-line);
}
.pm-view-img-empty {
    display: flex; align-items: center; justify-content: center;
    font-size: 3rem; background: var(--pm-surface-2); color: var(--pm-steel); border-style: dashed;
}
.pm-view-thumb {
    width: 56px; height: 56px; object-fit: cover;
    border-radius: .45rem; border: 1px solid var(--pm-line);
}
.pm-view-dl dt { color: var(--pm-steel); font-weight: 600; }
.pm-view-dl dd { color: var(--pm-text); margin-bottom: .5rem; }
.pm-view-desc { white-space: pre-wrap; }
/* الباركود يبقى على خلفية بيضاء ليظل قابلاً للمسح الضوئي */
.pm-view-barcode {
    padding: .85rem; border: 1px solid var(--pm-line); border-radius: .6rem;
    background: #fff; text-align: center;
}
.pm-view-barcode-img { max-width: 100%; height: auto; }
.pm-view-code { font-size: 1rem; letter-spacing: .12em; color: #1a1a1d; }

/* ---------- تبويبات صفحة الإعدادات ---------- */
.pm-settings-tabs {
    gap: .35rem;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--pm-line);
}
.pm-settings-tabs .nav-link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    margin-bottom: -1px;
    padding: .55rem 1.05rem;
    font-weight: 600;
    color: var(--pm-steel);
    background: transparent;
    border: 1px solid transparent;
    border-radius: .55rem .55rem 0 0;
    transition: color .15s ease, background .15s ease, border-color .15s ease;
}
.pm-settings-tabs .nav-link:hover {
    color: var(--pm-heading);
    background: var(--pm-surface-2);
}
.pm-settings-tabs .nav-link.active {
    color: var(--pm-primary);
    background: var(--pm-surface);
    border-color: var(--pm-line);
    border-bottom-color: var(--pm-surface);
}
@media (max-width: 575.98px) {
    /* على الشاشات الصغيرة أظهر الأيقونات فقط لتفادي الالتفاف. */
    .pm-settings-tabs .nav-link { padding: .5rem .7rem; }
    .pm-settings-tabs .nav-link span { display: none; }
}

/* ---------- زر حفظ مستقل لكل تبويب إعدادات ---------- */
.pm-settings-actions {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--pm-line);
}
.pm-settings-actions .btn { min-width: 200px; }

/* ---------- زر واتساب العائم ---------- */
.pm-wa-fab {
    position: fixed; bottom: 88px; inset-inline-start: 20px; z-index: 1085;
    width: 56px; height: 56px;
    display: flex; align-items: center; justify-content: center;
    background: #25d366; color: #fff; border-radius: 50%;
    box-shadow: 0 .35rem .9rem rgba(37,211,102,.45);
    transition: transform .15s ease, box-shadow .15s ease;
}
.pm-wa-fab:hover {
    color: #fff; text-decoration: none; transform: scale(1.07);
    box-shadow: 0 .5rem 1.1rem rgba(37,211,102,.55);
}

/* ---------- ودجة الدردشة ---------- */
.pm-chat-fab {
    position: fixed; bottom: 20px; inset-inline-start: 20px; z-index: 1085;
    width: 56px; height: 56px; line-height: 1;
    display: flex; align-items: center; justify-content: center; padding: 0;
}
.pm-chat-header-icon { vertical-align: -3px; margin-inline-end: .35rem; }
/* وميض أيقونة الدردشة لتنبيه الزائر */
.pm-chat-flash { animation: pmFlash 0.6s ease-in-out 5; }
@keyframes pmFlash {
    0%   { transform: scale(1);    box-shadow: 0 0 0 0 rgba(255,106,0,.7); }
    50%  { transform: scale(1.15); box-shadow: 0 0 0 12px rgba(255,106,0,0); }
    100% { transform: scale(1);    box-shadow: 0 0 0 0 rgba(255,106,0,0); }
}
.pm-chat-panel {
    position: fixed; bottom: 88px; inset-inline-start: 20px; z-index: 1085;
    width: 330px; max-width: calc(100vw - 40px); height: 440px; max-height: 70vh;
    background: var(--pm-surface); border: 1px solid var(--pm-line);
    border-radius: .75rem; display: flex; flex-direction: column; overflow: hidden;
}
.pm-chat-header {
    background: var(--pm-dark); color: #fff; padding: .6rem .9rem;
    display: flex; justify-content: space-between; align-items: center; font-weight: 600;
}
.pm-chat-body { flex: 1; overflow-y: auto; padding: .75rem; background: var(--pm-surface-2); }
/* مربّع الكتابة يرتفع مع النصّ ثمّ يمرّر، وزرّ الإرسال يبقى بمحاذاة أسفله */
.pm-chat-input { display: flex; gap: .4rem; padding: .5rem; border-top: 1px solid var(--pm-line); align-items: flex-end; }
.pm-chat-input .btn { flex: none; align-self: flex-end; }
/* محرّر الرسالة: ارتفاعه من محتواه (بلا حساب في JS)، والسطور والمسافات كما كُتبت */
.pm-chat-editor {
    flex: 1 1 auto; min-width: 0; cursor: text;
    white-space: pre-wrap; overflow-wrap: anywhere; text-align: start;
    min-height: 38px; max-height: 140px; height: auto; overflow-y: auto; line-height: 1.4;
}
/* نصّ إرشادي بديل عن placeholder (غير متاح في العناصر القابلة للتحرير) */
.pm-chat-editor:empty::before { content: attr(data-placeholder); color: var(--pm-steel); pointer-events: none; }
.pm-chat-editor[contenteditable="false"] { background: var(--pm-surface-2); cursor: default; }
/* الرابط أثناء الكتابة يأخذ شكل الرابط نفسه في الرسالة المُرسَلة */
.pm-chat-editor .pm-msg-link { color: var(--pm-primary); }
.pm-msg { margin-bottom: .5rem; display: flex; flex-direction: column; }
.pm-msg.from-me { align-items: flex-start; }
.pm-msg.from-admin { align-items: flex-end; }
/* pre-wrap: أسطر الرسالة كما كتبها صاحبها — anywhere: الرابط الطويل يُكسر بدل أن يتجاوز الفقاعة */
.pm-msg-bubble { padding: .4rem .7rem; border-radius: .75rem; max-width: 80%; font-size: .9rem; white-space: pre-wrap; overflow-wrap: anywhere; }
/* رابط داخل الرسالة: يُعزل اتجاهه ليُقرأ صحيحاً وسط نصّ عربي */
.pm-msg-link { text-decoration: underline; unicode-bidi: isolate; }
.pm-msg.from-me .pm-msg-link { color: #fff; }
.pm-msg.from-me .pm-msg-bubble { background: var(--pm-primary); color: #fff; border-bottom-inline-start-radius: .15rem; }
.pm-msg.from-admin .pm-msg-bubble { background: var(--pm-line); color: var(--pm-text); border-bottom-inline-end-radius: .15rem; }
.pm-msg-time { font-size: .65rem; color: var(--pm-steel); margin-top: .1rem; }
/* أيقونات حالة الرسالة (✓ / ✓✓) */
.msg-ticks { font-size: .8rem; letter-spacing: -3px; margin-inline-start: .25rem; }
.msg-ticks.read { color: #4aa3ff; }      /* أزرق: تمت القراءة */
.msg-ticks.delivered { color: var(--pm-steel); } /* رمادي: تم التسليم */
.msg-ticks.sent { color: var(--pm-steel); letter-spacing: normal; } /* رمادي: صحّ واحد */
/* شارة العدّاد على زر الدردشة العائم (الزر ثابت = مرجع للتموضع المطلق) */
.pm-chat-fab .pm-fab-badge {
    position: absolute; top: -8px; inset-inline-end: -14px;
    padding: 0; min-width: 18px; height: 18px;
    display: flex; align-items: center; justify-content: center;
    font-size: .62rem; line-height: 1; border: 2px solid var(--pm-dark);
}
/* صندوق محادثة المشرف بارتفاع محدّد بالنافذة (بلا تمرير للصفحة) */
.admin-chat-body { flex: none !important; height: calc(100vh - 280px); min-height: 240px; }

/* ---------- منزلق نطاق السعر (مؤشّران) ---------- */
.pm-price-range { position: relative; height: 36px; }
.pm-range-track,
.pm-range-fill {
    position: absolute; top: 50%; transform: translateY(-50%);
    height: 5px; border-radius: 5px;
}
.pm-range-track { inset-inline: 0; background: var(--pm-line); }
.pm-range-fill { background: var(--pm-primary); }
/* المؤشّران يتراكبان على كامل العرض؛ المسار لا يلتقط النقر، الإبهام فقط. */
.pm-price-range input[type=range] {
    position: absolute; top: 0; left: 0; width: 100%; height: 36px; margin: 0;
    background: none; pointer-events: none; -webkit-appearance: none; appearance: none;
}
.pm-price-range input[type=range]::-webkit-slider-runnable-track { background: none; border: none; }
.pm-price-range input[type=range]::-moz-range-track { background: none; border: none; }
.pm-price-range input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none; pointer-events: auto;
    width: 20px; height: 20px; border-radius: 50%; background: #fff;
    border: 3px solid var(--pm-primary); cursor: pointer; margin-top: -8px;
    box-shadow: 0 1px 3px rgba(0,0,0,.5);
}
.pm-price-range input[type=range]::-moz-range-thumb {
    pointer-events: auto; width: 20px; height: 20px; border-radius: 50%; background: #fff;
    border: 3px solid var(--pm-primary); cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,.5);
}

/* ---------- عوامل التصفية ---------- */
.pm-filters-toggle { font-weight: 600; }
/* شريط جانبي ثابت (لاصق) للفلاتر على الحاسوب */
@media (min-width: 992px) {
    .pm-filters-panel { position: sticky; top: 1rem; }
}
/* أهداف لمس أكبر وحقول أوضح على الجوال واللوحي (حيث تكون الفلاتر لوحة منبثقة) */
@media (max-width: 991.98px) {
    .pm-filters .form-select,
    .pm-filters .form-control { min-height: 44px; }
    .pm-filters .form-check { padding-block: .35rem; }
    .pm-filters .form-check-input { width: 1.15em; height: 1.15em; }
}

/* ---------- نماذج / تحقّق ---------- */
.valid.modified:not([type=checkbox]) { outline: 1px solid #34c759; }
.invalid { outline: 1px solid #ff5a5a; }
.validation-message { color: #ff6b6b; font-size: .85rem; }

.blazor-error-boundary {
    background: #b32121; padding: 1rem; color: white; border-radius: .5rem;
}
.blazor-error-boundary::after { content: "حدث خطأ ما."; }

/* إفساح مساحة أسفل الصفحة وزر الدردشة حتى لا يحجبهما الشريط السفلي على الجوال.
   يأتي في نهاية الملف ليتجاوز قواعد .pm-chat-fab/.pm-chat-panel الأساسية. */
@media (max-width: 991.98px) {
    /* المسافات تتبع ارتفاع الشريط + المساحة الآمنة، فلا تحتاج تعديلاً عند تغيير تصميمه */
    .pm-footer { margin-bottom: calc(var(--pm-bottom-nav-h) + env(safe-area-inset-bottom, 0px)); }
    .pm-chat-fab { bottom: calc(var(--pm-bottom-nav-h) + 16px + env(safe-area-inset-bottom, 0px)); }
    .pm-chat-panel,
    .pm-wa-fab { bottom: calc(var(--pm-bottom-nav-h) + 84px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- نوافذ SweetAlert2 المنبثقة بألوان السمة ----------
   يُطبَّق على النوافذ الوسطية فقط (:not(.swal2-toast)) حتى يبقى شريط النجاح
   العلوي بمظهره الافتراضي. المنبثق يُلحَق بـ body فترث متغيّرات ‎--pm-*‎. */
.swal2-popup:not(.swal2-toast) {
    background: var(--pm-surface);
    color: var(--pm-text);
    border: 1px solid var(--pm-line);
    border-radius: .75rem;
}
.swal2-popup:not(.swal2-toast) .swal2-title { color: var(--pm-heading); }
.swal2-popup:not(.swal2-toast) .swal2-html-container { color: var(--pm-text); }
.swal2-popup:not(.swal2-toast) .swal2-confirm.swal2-styled {
    background: var(--pm-primary);
    color: #fff;
    box-shadow: none;
}
.swal2-popup:not(.swal2-toast) .swal2-confirm.swal2-styled:hover {
    background: color-mix(in srgb, var(--pm-primary) 88%, #000);
}
.swal2-popup:not(.swal2-toast) .swal2-confirm.swal2-styled:focus {
    box-shadow: 0 0 0 3px rgba(var(--pm-primary-rgb), .4);
}
