/* ============================================================
   rio-desktop.css — طبقة تخطيط الكمبيوتر/اللابتوب فقط
   كل شيء هنا داخل @media (min-width:1024px) — نسخة الموبايل لا تتأثر إطلاقًا.
   الهوية: نفس ألوان Rio Vast (#192E85 أساسي، خلفية داكنة).
   ============================================================ */

/* ════════════════════════════════════════════════════════════
   الشريط العلوي الاحترافي (#rvTopNav) — مرئي فوق 1024px فقط
   ════════════════════════════════════════════════════════════ */

/* مخفي افتراضيًا على الموبايل — CSS فقط، بلا JS */
#rvTopNav { display: none; }

@media (min-width: 1024px) {

/* ─── الشريط العلوي ─── */
#rvTopNav,
.rvtn-bar {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 60px;
    z-index: 1100;
    background: rgba(5, 8, 22, .96);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255,255,255,.07);
    padding: 0 20px;
    gap: 12px;
}

/* ─── الجانب الأيمن: شعار + أسواق ─── */
.rvtn-start {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 0 0 auto;
}
.rvtn-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    padding: 6px 10px;
    border-radius: 10px;
    transition: background .15s;
}
.rvtn-logo:hover { background: rgba(255,255,255,.06); color: #fff; text-decoration: none; }
.rvtn-logo img { width: 28px; height: 28px; object-fit: contain; }
.rvtn-logo-name { color: #fff; letter-spacing: .3px; }

.rvtn-markets {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-right: 8px;
}
.rvtn-mkt {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 13px;
    border-radius: 10px;
    color: rgba(255,255,255,.72);
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    transition: background .14s, color .14s;
    white-space: nowrap;
}
.rvtn-mkt:hover,
.rvtn-mkt.rvtn-active {
    background: rgba(25,46,133,.38);
    color: #fff;
    text-decoration: none;
}
.rvtn-mkt i { font-size: 12px; opacity: .8; }

/* ─── الوسط: بحث ─── */
.rvtn-mid {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 360px;
    margin: 0 auto;
}
.rvtn-search {
    position: relative;
    width: 100%;
}
.rvtn-search-ic {
    position: absolute;
    top: 50%; right: 12px;
    transform: translateY(-50%);
    color: rgba(255,255,255,.35);
    font-size: 13px;
    pointer-events: none;
}
#rvTnSearchInput {
    width: 100%;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 10px;
    color: #fff;
    font-size: 13.5px;
    padding: 8px 36px 8px 14px;
    outline: none;
    transition: border-color .15s, background .15s;
    box-sizing: border-box;
}
#rvTnSearchInput::placeholder { color: rgba(255,255,255,.3); }
#rvTnSearchInput:focus {
    border-color: rgba(25,46,133,.7);
    background: rgba(255,255,255,.10);
}
.rvtn-search-drop {
    position: absolute;
    top: calc(100% + 6px);
    right: 0; left: 0;
    background: #0d1128;
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,.6);
    overflow: hidden;
    z-index: 1200;
    max-height: 340px;
    overflow-y: auto;
}
.rvtn-search-loading {
    padding: 18px;
    text-align: center;
    color: rgba(255,255,255,.35);
    font-size: 18px;
}
.rvtn-search-none {
    padding: 18px;
    text-align: center;
    color: rgba(255,255,255,.35);
    font-size: 13px;
}
.rvtn-srow {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: #fff;
    text-decoration: none;
    transition: background .12s;
    cursor: pointer;
}
.rvtn-srow:hover { background: rgba(255,255,255,.06); color: #fff; text-decoration: none; }
.rvtn-srow-logo { width: 24px; height: 24px; flex-shrink: 0; display: flex; align-items: center; }
.rvtn-srow-sym { flex: 1 1 auto; min-width: 0; }
.rvtn-srow-sym b { display: block; font-size: 13.5px; font-weight: 700; }
.rvtn-srow-sym small { display: block; font-size: 11.5px; color: rgba(255,255,255,.45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rvtn-srow-chg { font-size: 12.5px; font-weight: 600; flex-shrink: 0; }
.rvtn-srow-chg.up { color: #0ecb81; }
.rvtn-srow-chg.dn { color: #f6465d; }

/* ─── الجانب الأيسر: أدوات + حساب ─── */
.rvtn-end {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 0 0 auto;
}

/* أزرار الإيداع والسحب */
.rvtn-btn-dep,
.rvtn-btn-wd {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: opacity .15s, filter .15s;
    white-space: nowrap;
}
.rvtn-btn-dep {
    background: #192E85;
    color: #fff;
}
.rvtn-btn-dep:hover { filter: brightness(1.15); color: #fff; text-decoration: none; }
.rvtn-btn-dep.rvtn-active { filter: brightness(1.2); }

.rvtn-btn-wd {
    background: rgba(255,255,255,.08);
    color: rgba(255,255,255,.85);
    border: 1px solid rgba(255,255,255,.10);
}
.rvtn-btn-wd:hover { background: rgba(255,255,255,.13); color: #fff; text-decoration: none; }
.rvtn-btn-wd.rvtn-active { background: rgba(255,255,255,.14); color: #fff; }

/* أزرار أيقونة */
.rvtn-icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px; height: 38px;
    border-radius: 10px;
    background: none;
    border: none;
    color: rgba(255,255,255,.65);
    font-size: 16px;
    text-decoration: none;
    cursor: pointer;
    transition: background .14s, color .14s;
    position: relative;
    flex-shrink: 0;
}
.rvtn-icon-btn:hover,
.rvtn-icon-btn.rvtn-active {
    background: rgba(255,255,255,.08);
    color: #fff;
    text-decoration: none;
}

/* قائمة الإشعارات */
.rvtn-notif { position: relative; }
.rvtn-notif-drop {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%; transform: translateX(-50%);
    width: 300px;
    background: #0d1128;
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 14px;
    box-shadow: 0 14px 44px rgba(0,0,0,.6);
    z-index: 1200;
    overflow: hidden;
}
.rvtn-notif-empty {
    padding: 32px 20px;
    text-align: center;
    color: rgba(255,255,255,.4);
}
.rvtn-notif-empty i { font-size: 28px; margin-bottom: 10px; display: block; }
.rvtn-notif-empty p { margin: 0 0 4px; font-size: 13.5px; color: rgba(255,255,255,.55); }
.rvtn-notif-empty small { font-size: 12px; }

/* قائمة الحساب */
.rvtn-acct { position: relative; }
.rvtn-acct-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 10px;
    padding: 5px 10px;
    cursor: pointer;
    transition: background .14s;
}
.rvtn-acct-btn:hover { background: rgba(255,255,255,.12); }
.rvtn-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}
.rvtn-caret { color: rgba(255,255,255,.5); font-size: 12px; transition: transform .2s; }
.rvtn-acct-btn[aria-expanded="true"] .rvtn-caret { transform: rotate(180deg); }

.rvtn-acct-drop {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 220px;
    background: #0d1128;
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 14px;
    box-shadow: 0 14px 44px rgba(0,0,0,.6);
    z-index: 1200;
    overflow: hidden;
}
.rvtn-acct-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px 12px;
}
.rvtn-acct-head .rvtn-avatar { width: 40px; height: 40px; }
.rvtn-acct-name { display: block; font-size: 14px; font-weight: 700; color: #fff; }
.rvtn-acct-id { display: block; font-size: 11.5px; color: rgba(255,255,255,.4); margin-top: 2px; }
.rvtn-acct-sep { height: 1px; background: rgba(255,255,255,.07); margin: 2px 0; }
.rvtn-acct-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: rgba(255,255,255,.75);
    font-size: 13.5px;
    text-decoration: none;
    transition: background .12s, color .12s;
}
.rvtn-acct-item:hover { background: rgba(255,255,255,.06); color: #fff; text-decoration: none; }
.rvtn-acct-item i { width: 16px; text-align: center; opacity: .7; }
.rvtn-logout { color: #f6465d !important; }
.rvtn-logout i { opacity: 1 !important; }

/* ---------- 1) الشريط السفلي ⟶ مُخفى تمامًا على الكمبيوتر لصالح #rvTopNav ---------- */
.rv-tabbar { display: none !important; }

body.rv-has-tabbar {
    padding-bottom: 0 !important;
    padding-top: 76px;
}
/* صفحات تحتوي هيدر خاص لاصق — تبقى تحت الشريط العلوي */
body.rv-has-tabbar .rv-h2-head,
body.rv-has-tabbar .rvPageHead { top: 60px; }

/* ---------- 2) الشيتات السفلية ⟶ نوافذ مركزية (مودال) ---------- */
#rs-root { align-items: center !important; justify-content: center !important; }
#rs-sheet {
    width: min(560px, 92vw) !important;
    max-width: 560px !important;
    min-height: 0 !important;
    max-height: 84vh !important;
    border-radius: 20px !important;
    border: 1px solid rgba(255, 255, 255, .09) !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .6) !important;
}
#rs-sheet .rs-handle { display: none !important; }

/* ---------- 3) الرئيسية (home v2): عمودان — المحفظة يمين + السوق يسار ---------- */
.rv-home.rv-home2 { max-width: 1240px; padding-left: 28px; padding-right: 28px; }
.rv-h2-head { max-width: none; }
.rv-h2-mkt {
    display: grid;
    grid-template-columns: 400px minmax(0, 1fr);
    gap: 0 26px;
    align-items: start;
}
.rv-h2-mkt > .rv-h2-search { grid-column: 2; grid-row: 1; align-self: start; }
.rv-h2-mkt > .rv-h2-list   { grid-column: 2; grid-row: 2 / span 8; }
.rv-h2-mkt > .rv-h2-wallet { grid-column: 1; grid-row: 1 / span 2; position: sticky; top: 84px; }
.rv-h2-mkt > .rv-h2-promo  { grid-column: 1; grid-row: 3; position: sticky; top: 84px; }
/* أي عنصر آخر داخل القسم يذهب للعمود الرئيسي */
.rv-h2-mkt > *:not(.rv-h2-search):not(.rv-h2-list):not(.rv-h2-wallet):not(.rv-h2-promo) { grid-column: 2; }
.rv-h2-wal-val { font-size: 40px !important; }

/* مشهد الفوركس الترويجي 3D: يشغل العمود الرئيسي بارتفاع أكبر على الشاشات الواسعة */
.rv-h2-mkt > .rv-fx3d { height: 480px; }

/* ---------- 4) الأسواق: جدول عريض بعمودين ---------- */
.rv-mkts { max-width: 1240px; padding-left: 28px; padding-right: 28px; }
.rv-mkts .rv-mkt-list,
.rv-mkts #rvMktList {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 40px;
    align-items: start;
}

/* ══════════════════════════════════════════════════════════════
   5) منصة السبوت (≥1024px): تخطيط كمبيوتر احترافي
   ══════════════════════════════════════════════════════════════

   ┌─────────────────────────────────────────────────────────┐
   │ .tfx-top (شريط الزوج + رصيد)   col 1/-1               │
   ├──────────┬──────────────────────────┬───────────────────┤
   │ قائمة   │  الشارت (#tspVChart)     │  التنفيذ          │
   │ الأسواق │  الشارت + فريمات +أدوات  │  (#tspVTrade)     │
   │ جانبية  │                          │  نموذج + دفتر     │
   │ #tspSide│                          │                   │
   ├──────────┴──────────────────────────┴───────────────────┤
   │ الأوامر المفتوحة والسجل  col 1/-1                       │
   └─────────────────────────────────────────────────────────┘
   ════════════════════════════════════════════════════════════ */

/* الجذر: تخطيط شبكة ثلاثة أعمدة */
.tsp#tspRoot {
    display: grid !important;
    grid-template-columns: 220px minmax(0, 1fr) 320px;
    grid-template-rows: auto 1fr auto;
    gap: 0;
    max-width: none !important;
    padding: 0 !important;
    width: 100%;
    box-sizing: border-box;
    min-height: calc(100vh - 76px);
    align-items: start;
}

/* شريط الزوج العلوي: يمتد عبر كل الأعمدة */
.tsp#tspRoot > .tfx-top {
    grid-column: 1 / -1;
    grid-row: 1;
    border-bottom: 1px solid rgba(255,255,255,.07);
    padding: 10px 16px;
    display: flex !important;   /* يبقى ظاهرًا دائمًا على الكمبيوتر */
}

/* القائمة الجانبية للأسواق */
.tsp#tspRoot > #tspDkSide {
    grid-column: 1;
    grid-row: 2 / span 2;
    border-left: 1px solid rgba(255,255,255,.07);  /* RTL: الفاصل على اليسار (بين القائمة والشارت) */
    /* لا min-height ثابت — الارتفاع يُحدّد بصف الشبكة تلقائيًا */
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* الشارت (#tspVChart): يظهر دائمًا على الكمبيوتر بـ !important */
.tsp#tspRoot > #tspVChart {
    grid-column: 2;
    grid-row: 2;
    display: block !important;  /* يتجاوز style.display='none' من JS */
    min-height: 480px;
    border-left: 1px solid rgba(255,255,255,.07);
    border-right: 1px solid rgba(255,255,255,.07);
    position: relative;
    overflow: hidden;
}

/* نموذج التنفيذ (#tspVTrade): يظهر دائمًا على الكمبيوتر بـ !important */
.tsp#tspRoot > #tspVTrade {
    grid-column: 3;
    grid-row: 2;
    display: flex !important;   /* يتجاوز style.display='none' من JS */
    flex-direction: column;
    overflow-y: auto;
    max-height: calc(100vh - 130px);
    padding-bottom: 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.12) transparent;
}

/* الأوامر المفتوحة والسجل: أسفل الشارت، ممتدة عبر عمود الشارت فقط */
.tsp#tspRoot > #tspVChart ~ * {
    /* ليست الشارت ولا التنفيذ — قد تكون عناصر أخرى */
}

/* الشيت (بحث الأزواج): يظهر فوق كل شيء */
.tsp#tspRoot > .tsp-sheet {
    grid-column: 1 / -1;
    grid-row: 1 / -1;
    z-index: 200;
    position: relative;
}

/* ── داخل #tspVTrade على الكمبيوتر ── */

/* صف الزوج العلوي: مخفي (الزوج يظهر في .tfx-top العام) */
.tsp#tspRoot .tsp2-pairrow-top {
    display: none !important;
}
/* رابط "رسم البياني" + زر الشارت: مخفيان (الشارت دائم الظهور) */
.tsp#tspRoot .tsp2-chartlink,
.tsp#tspRoot #tspToChart,
.tsp#tspRoot .tsp2-candle-ic {
    display: none !important;
}

/* نموذج الشراء/البيع: عمود واحد */
.tsp#tspRoot .tsp2-main {
    flex-direction: column !important;
    gap: 0;
}
.tsp#tspRoot .tsp2-form {
    flex: 0 0 auto;
    padding: 12px 14px 0;
}
/* دفتر الأوامر أسفل النموذج */
.tsp#tspRoot .tsp2-ob {
    flex: 1 1 auto;
    max-height: 340px;
    overflow-y: auto;
    margin-top: 10px;
    padding: 0 14px 10px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.10) transparent;
}

/* ═══════════════════════════════════════════════════════════
   حاوية الأوامر المفتوحة والسجل (#tspDkOrders)
   تُنشأ بـ JS في dkLiftOrders() وتمتد أسفل الشارت+التنفيذ
   ═══════════════════════════════════════════════════════════ */
.tsp#tspRoot > #tspDkOrders {
    grid-column: 2 / -1;    /* عمود الشارت + عمود التنفيذ */
    grid-row: 3;
    border-top: 1px solid rgba(255,255,255,.07);
    overflow-y: auto;
    max-height: 320px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.12) transparent;
}

/* ── شارت السبوت على الكمبيوتر: ارتفاع محدود لإبقاء #tspDkOrders داخل المنظور ──
   المعادلة: يُطرح من الشاشة: شريط التنقل (76) + شريط الزوج (52) + رأس الشارت (82)
   + شارت فرعي (110) + أزرار المؤشرات (40) + إحصاءات الأداء (48) + #tspDkOrders (280)
   المجموع المطروح ≈ 688px — نضيف 12px هامش → 700px.
   max-height يحمي الشاشات الكبيرة من شارت عملاق. ── */
.tsp#tspRoot #tspChart {
    height: calc(100vh - 700px) !important;
    min-height: 280px !important;
    max-height: 520px !important;
}
/* الشارت الفرعي (VOL/MACD/RSI…) */
.tsp#tspRoot #tscSub {
    height: 90px;
}

/* ── تابات الكتاب/التداولات/العمق السفلية داخل عمود الشارت: مخفية على الكمبيوتر ──
   هذه البيانات موجودة في #tspDkOrders أسفله + دفتر الأوامر في #tspVTrade ── */
/* تابات الكتاب/التداولات/العمق السفلية: مخفية (محتواها في #tspDkOrders ودفتر الطلبات) */
#tscBTabs, #tscBBody, .tsc-div,
#tscPricePane .tsc-btabs, #tscPricePane .tsc-bbody {
    display: none !important;
    height: 0 !important;
    overflow: hidden !important;
}
/* .tsc-periods (إحصاءات الأداء) تبقى ظاهرة — بيانات مفيدة للمتداول */

/* ── ترتيب الشارت داخليًا ── */
.tsp#tspRoot #tspVChart .tsc-head { padding: 6px 12px; }
.tsp#tspRoot #tspVChart .tsc-tfs  { padding: 4px 12px; }

/* ── إخفاء زر الرجوع في رأس الشارت (لا معنى له على الكمبيوتر) ── */
.tsp#tspRoot #tscBack { display: none !important; }

/* ── أزرار شراء/بيع داخل صفحة الشارت: مخفية (الشراء في اللوحة اليمنى) ── */
.tsp#tspRoot #tscBuy,
.tsp#tspRoot #tscSell { display: none !important; }

/* ══════════════════════════════════════════════════════════════
   5b) قائمة الأسواق الجانبية (#tspDkSide)
   ══════════════════════════════════════════════════════════════ */
.tsp-dk-side {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}
.tsp-dk-side-head {
    padding: 10px 12px 8px;
    border-bottom: 1px solid rgba(255,255,255,.06);
    flex-shrink: 0;
}
.tsp-dk-side-search {
    position: relative;
    margin-bottom: 8px;
}
.tsp-dk-side-search i {
    position: absolute;
    top: 50%; right: 10px;
    transform: translateY(-50%);
    color: rgba(255,255,255,.3);
    font-size: 12px;
    pointer-events: none;
}
.tsp-dk-side-search input {
    width: 100%;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 8px;
    color: #fff;
    font-size: 12.5px;
    padding: 7px 30px 7px 10px;
    outline: none;
    box-sizing: border-box;
    transition: border-color .14s;
}
.tsp-dk-side-search input:focus { border-color: rgba(25,46,133,.6); }
.tsp-dk-side-search input::placeholder { color: rgba(255,255,255,.25); }

.tsp-dk-side-tabs {
    display: flex;
    gap: 4px;
}
.tsp-dk-side-tabs button {
    flex: 1;
    background: none;
    border: none;
    color: rgba(255,255,255,.45);
    font-size: 11.5px;
    font-weight: 600;
    padding: 4px 0;
    border-radius: 6px;
    cursor: pointer;
    transition: background .12s, color .12s;
}
.tsp-dk-side-tabs button.on,
.tsp-dk-side-tabs button:hover {
    background: rgba(25,46,133,.3);
    color: #fff;
}

/* رأس الجدول */
.tsp-dk-side-cols {
    display: flex;
    padding: 6px 12px;
    color: rgba(255,255,255,.3);
    font-size: 10.5px;
    font-weight: 600;
    border-bottom: 1px solid rgba(255,255,255,.05);
    flex-shrink: 0;
}
.tsp-dk-side-cols span:first-child { flex: 1; }
.tsp-dk-side-cols span:last-child  { text-align: left; }

/* قائمة العملات */
.tsp-dk-side-list {
    flex: 1 1 auto;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.10) transparent;
}
.tsp-dk-side-row {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 8px;
    margin: 1px 4px;
    transition: background .12s;
    text-decoration: none;
}
.tsp-dk-side-row:hover,
.tsp-dk-side-row.on { background: rgba(25,46,133,.28); }
.tsp-dk-side-row-logo { width: 22px; height: 22px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; margin-left: 8px; overflow: hidden; border-radius: 50%; }
.tsp-dk-side-row-logo img, .tsp-dk-side-row-logo svg { width: 22px !important; height: 22px !important; max-width: 22px; max-height: 22px; object-fit: cover; border-radius: 50%; }
.tsp-dk-side-row-info { flex: 1; min-width: 0; }
.tsp-dk-side-row-sym { display: block; font-size: 12.5px; font-weight: 700; color: #fff; }
.tsp-dk-side-row-name { display: block; font-size: 10.5px; color: rgba(255,255,255,.4); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tsp-dk-side-row-px { text-align: left; }
.tsp-dk-side-row-price { display: block; font-size: 12px; color: #fff; font-weight: 600; direction: ltr; }
.tsp-dk-side-row-chg { display: block; font-size: 10.5px; font-weight: 600; }
.tsp-dk-side-row-chg.up { color: #0ecb81; }
.tsp-dk-side-row-chg.dn { color: #f6465d; }

/* هيكل تحميل القائمة */
.tsp-dk-sk-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
}

/* ---------- 6) الفوركس: قائمة الأسواق + الشارت + تذكرة التنفيذ ---------- */
.tfx { max-width: 1420px !important; padding-left: 28px; padding-right: 28px; }
.tfx .tfx-chart { min-height: 480px; }
/* تبويب التداول MT5: قائمة الأسواق (يمين) + الشارت (وسط كبير) + التذكرة (يسار) */
.tfx #tfxPaneTrade {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr) 340px;
    gap: 0 18px;
    align-items: start;
}
.tfx #tfxPaneTrade > .tfx-watch-head { grid-column: 1; grid-row: 1; }
.tfx #tfxPaneTrade > .tfx-watch      { grid-column: 1; grid-row: 2; max-height: 560px; overflow-y: auto; }
.tfx #tfxPaneTrade > .tfx-chart-wrap { grid-column: 2; grid-row: 1 / span 2; }
.tfx #tfxPaneTrade > .tfx-ticket     { grid-column: 3; grid-row: 1 / span 2; position: sticky; top: 84px; }
.tfx #tfxPaneTrade > *:not(.tfx-watch-head):not(.tfx-watch):not(.tfx-chart-wrap):not(.tfx-ticket) { grid-column: 1 / -1; }
.tfx .tfx-exec button { font-size: 16px; padding: 14px 0; }

/* ---------- 7) الخيارات الثنائية + الفوركس: شارت + لوحة تنفيذ جانبية ----------
   هيكل DOM الفعلي:
     .tbn (root) → .tbn-scroll (شارت+شريط) | .tbn-bottom (تنفيذ+شريط نشط)
   لذا نستهدف الأبناء المباشرين الفعليين لا العناصر الداخلية. */
.tbn {
    max-width: 1420px !important;
    padding-left: 28px; padding-right: 28px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 0 22px;
    align-items: start;
}
/* .tbn-scroll يأخذ العمود الأول (شارت + شريط أدوات) */
.tbn > .tbn-scroll {
    grid-column: 1; grid-row: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}
/* .tbn-bottom يأخذ العمود الثاني (لوحة التنفيذ) ويبقى sticky */
.tbn > .tbn-bottom {
    grid-column: 2; grid-row: 1;
    position: sticky !important;
    top: 84px !important;
    bottom: auto !important;
    height: fit-content;
    max-height: calc(100vh - 90px);
    overflow-y: auto;
    border-top: none !important;
    padding-bottom: 0 !important;
    /* تأكد من أن الـsafe-area لا تضيف مسافة على desktop */
    padding-bottom: env(safe-area-inset-bottom, 0) !important;
}
/* شبكة الثنائية مع شريط الأصول الجانبي (تُفعَّل من JS بإضافة .tbn-has-dk-side) */
.tbn.tbn-has-dk-side {
    grid-template-columns: 200px minmax(0, 1fr) 340px !important;
    max-width: 1600px !important;
    gap: 0 18px;
}
.tbn.tbn-has-dk-side > .tbn-dk-assets {
    grid-column: 1; grid-row: 1;
    position: sticky;
    top: 84px;
    height: fit-content;
    max-height: calc(100vh - 90px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.tbn.tbn-has-dk-side > .tbn-scroll {
    grid-column: 2 !important; grid-row: 1;
}
.tbn.tbn-has-dk-side > .tbn-bottom {
    grid-column: 3 !important; grid-row: 1 / span 2;
    display: flex; flex-direction: column;
}
/* سجل النتائج: مرئي أسفل الشارت على الكمبيوتر (يُلغي hidden من الـHTML) */
.tbn.tbn-has-dk-side > .tbn-hist-wrap {
    display: flex !important;
    flex-direction: column;
    grid-column: 2; grid-row: 2;
    border-top: 1px solid rgba(255,255,255,.07);
    overflow-y: auto;
    max-height: 260px;
    background: rgba(255,255,255,.02);
    border-radius: 0 0 12px 12px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.12) transparent;
}
.tbn.tbn-has-dk-side > .tbn-hist-wrap h6 {
    padding: 10px 14px 6px;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,.45);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: .04em;
}
/* الصفقات الجارية: تبقى داخل عمود التنفيذ (column 3) وظاهرة بالكامل */
.tbn.tbn-has-dk-side > .tbn-bottom > .tbn-active-strip {
    flex: 0 0 auto;
    border-bottom: 1px solid rgba(255,255,255,.07);
}
/* الشريط النشط داخل الجزء السفلي (FX): يُخفى لأنه يظهر في #tfxDkOrders */
.tfx.tbn > .tbn-bottom > .tbn-active-strip { display: none !important; }
/* أوفرلاي اسم الأصل داخل الشارت (FX): تكبير طفيف على الكمبيوتر مع الحفاظ على نسب MT5 */
.tfx2-sym-ovl b { font-size: 16px; }
.tfx2-sym-ovl span { font-size: 12px; }

/* لوحة الصفقات المضمّنة (FX desktop) — flex-item داخل #tfx2Scroll مباشرةً أسفل الشارت */
#tfx2Scroll > #tfxDkOrders {
    flex: 0 0 auto;
    border-top: 1px solid rgba(255,255,255,.07);
    overflow-y: auto;
    max-height: 340px;
    border-radius: 0 0 12px 12px;
    background: rgba(255,255,255,.02);
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.12) transparent;
}
/* تفاصيل المركز المضمّنة في #tfxDkBody */
.tfx-dk-det { padding: 12px 14px; }
.tfx-dk-back-btn {
    display: inline-flex; align-items: center; gap: 6px;
    background: none; border: none; padding: 4px 0 10px;
    color: rgba(255,255,255,.55); font-size: 13px; cursor: pointer;
    font-family: inherit; transition: color .15s;
}
.tfx-dk-back-btn:hover { color: #fff; }
.tfx-dk-det .tfxs-wrap { padding: 0; background: none; }
.tfx-dk-det .tfxs-close-btn {
    width: 100%; margin-top: 10px; padding: 10px;
    border: 1px solid rgba(239,68,68,.35); border-radius: 10px;
    background: rgba(239,68,68,.08); color: #ef4444;
    font-size: 14px; cursor: pointer; font-family: inherit;
    transition: background .15s;
}
.tfx-dk-det .tfxs-close-btn:hover { background: rgba(239,68,68,.16); }
.tfx-dk-det .tfxs-sec {
    font-size: 11px; font-weight: 600; color: rgba(255,255,255,.4);
    text-transform: uppercase; letter-spacing: .05em;
    margin: 12px 0 8px;
}
.tfx-dk-det .tfx2-mod { gap: 6px; }
.tfx-dk-det .tfx2-mod-save { padding: 8px 14px; font-size: 13px; }
/* أبعاد الشارت الداخلية */
/* رأس الصفحة حُذف (~44px) — الشارت يأخذ المساحة المحرَّرة */
.tbn .tbn-chart { min-height: 544px !important; height: 544px !important; }
/* width:100% إلزامي بعد أن صار الصف space-between + أدوات مطلقة التموضع —
   align-self:start وحده يقلّص الصف لعرض المحتوى فيتكدّس كل شيء في طرف واحد */
.tbn .tb2-bar { align-self: start; width: 100%; }
.tbn .tb2-assetbtn { flex: 0 0 auto; }
.tbn .tb2-assetbtn img, .tbn .tb2-assetbtn i:first-child { width: 22px; height: 22px; font-size: 15px; }
.tbn .tb2-chartwrap { margin: 0; }
.tbn .tbn-exec button { font-size: 17px; padding: 16px 0; }
.tbn .tb2-panel { overflow-y: auto; }

/* ── شريط أصول الثنائية الجانبي (.tbn-dk-assets) ── */
.tbn-dk-assets {
    background: rgba(255,255,255,.03);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.07);
    overflow: hidden;
}
.tbn-dk-cats {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 4px;
    border-bottom: 1px solid rgba(255,255,255,.07);
}
.tbn-dk-cat {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px; height: 36px;
    border-radius: 8px;
    border: none;
    background: none;
    color: rgba(255,255,255,.4);
    cursor: pointer;
    font-size: 14px;
    transition: background .15s, color .15s;
}
.tbn-dk-cat:hover { background: rgba(255,255,255,.06); color: #f2f2f2; }
.tbn-dk-cat.on    { background: rgba(59,130,246,.18); color: #3b82f6; }
.tbn-dk-list {
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}
.tbn-dk-row {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 7px 8px;
    cursor: pointer;
    transition: background .12s;
    border-bottom: 1px solid rgba(255,255,255,.04);
    border-inline-start: 2px solid transparent;
}
.tbn-dk-row:hover { background: rgba(255,255,255,.05); }
.tbn-dk-row.on    { background: rgba(59,130,246,.09); border-inline-start-color: #3b82f6; }
.tbn-dk-ic { flex-shrink: 0; width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; }
.tbn-dk-ic img { width: 24px; height: 24px; border-radius: 50%; }
.tbn-dk-ic i    { font-size: 18px; color: #f2c94c; }
.tbn-dk-nm { flex: 1; min-width: 0; }
.tbn-dk-nm b    { display: block; font-size: 11px; color: #f2f2f2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tbn-dk-nm small { font-size: 10px; color: #0ecb81; font-weight: 600; }

/* ── تبويبات لوحة الصفقات المضمّنة (FX desktop) ── */
.tfx-dk-tabs {
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(255,255,255,.07);
    padding: 0 6px;
}
.tfx-dk-tab {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 9px 14px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: rgba(255,255,255,.4);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    transition: color .15s, border-color .15s;
    white-space: nowrap;
}
.tfx-dk-tab.on    { color: #f2f2f2; border-bottom-color: #3b82f6; }
.tfx-dk-tab svg   { width: 14px; height: 14px; }
.tfx-dk-cnt       { font-size: 11px; color: #3b82f6; }
.tfx-dk-body      { overflow-y: auto; max-height: 280px; }
/* بطاقات المراكز/التاريخ داخل اللوحة المضمّنة */
.tfx-dk-body .tfxs-card  { margin: 0; border-radius: 0; border-bottom: 1px solid rgba(255,255,255,.05); }
.tfx-dk-body .tfxs-empty { padding: 24px 16px; }
.tfx-dk-body .tfxs-wrap  { padding: 0; }
.tfx-dk-body .tfxs-toolbar { padding: 6px 12px 4px; margin-left: 0; margin-right: 0; }

/* ── Action Sheet → مودال مركزي على الكمبيوتر ── */
body > #tfxAS .tfx-as-box {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    bottom: auto !important;
    transform: translate(-50%, -50%) !important;
    width: min(420px, 90vw) !important;
    border-radius: 18px !important;
    max-height: 80vh !important;
    overflow-y: auto !important;
}
body > #tfxAS.in .tfx-as-box {
    transform: translate(-50%, -50%) !important;
    bottom: auto !important;
}

/* ---------- 8) P2P: شبكة عروض بعمودين + فلاتر بصف واحد ---------- */
.rvp-wrap { max-width: 1240px !important; padding-left: 28px; padding-right: 28px; }
#rvp2pRoot .rvp-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    align-items: start;
}

/* ---------- 9) مركز الأوامر ---------- */
.rvo-wrap { max-width: 1240px !important; margin: 0 auto; padding-left: 28px !important; padding-right: 28px !important; }
.rvo-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    align-items: start;
}
.rvo-list > .rvo-empty { grid-column: 1 / -1; }

/* ---------- 10) المحفظة ---------- */
.wallet-card { max-width: 1100px !important; margin-left: auto !important; margin-right: auto !important; }

/* ---------- 11) صفحات الحساب والأمان والإعدادات والدعم والنماذج ---------- */
.settings-page, .profile-page, .help-center,
.rvsec-page { max-width: 920px !important; }
.verify-card, #profileForm { max-width: 860px; margin-left: auto; margin-right: auto; }
.login-card, .register-card { max-width: 460px; margin-left: auto; margin-right: auto; }

/* ---------- 12) القائمة الجانبية (☰) على الشاشات العريضة ---------- */
#external-sidebar { max-width: 420px; }

/* ---------- 13) صفحة الإعدادات (desktop) ---------- */
.rvsec-page { max-width: 580px !important; padding-top: 24px !important; }
.rvsec-list { border-radius: 12px; }
/* شبكة الاختيارات تُظهر أكثر في الشاشات الواسعة */
.rvset-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }

/* ---------- 14) تحسينات عامة ---------- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .14); border-radius: 6px; }
::-webkit-scrollbar-track { background: transparent; }

} /* نهاية @media (min-width:1024px) */

/* ════════════════════════════════════════════════════════════
   المرحلة أ+ب: صفحات المال والسجلات وبقية الصفحات (≥1024px)
   كل القواعد هنا CSS فقط — بلا تعديل على الموبايل إطلاقًا.
   ════════════════════════════════════════════════════════════ */

@media (min-width: 1024px) {

/* ── 1. صفحة الإيداع (deposite) ──
   الحاوية: .container > .panel.mx-auto (inline max-width:1100px)
   نُقيّد بعرض مريح وتوسيط — الشيتات تعمل كمودال ✓ */
.panel.mx-auto {
    max-width: 680px !important;
    padding: 20px 24px !important;
}

/* ── 2. سجل المعاملات (transferdata: .rv-txlog) ──
   شريط الفلتر أفقي؛ القائمة عمودان */
.rv-txlog {
    max-width: 960px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 0 80px !important;
}
/* الشريط: من العمودي إلى الأفقي */
.rv-txfilter {
    flex-direction: row !important;
    gap: 6px !important;
    position: sticky !important;
    top: 60px !important;          /* أسفل الشريط العلوي */
    z-index: 10 !important;
    padding: 6px !important;
    background: rgba(3, 6, 21, .92) !important;
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
}
.rv-txf-btn {
    flex: 0 0 auto !important;     /* كل زر بعرضه الطبيعي لا 1fr */
}
.rv-txf-btn.rv-txf-all {
    order: -1;                      /* «الكل» أول اليسار */
}
/* قائمة الصفوف: عمودان */
.rv-txlist {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 0 28px !important;
    align-items: start !important;
}
/* كل صف يحتفظ بحدوده الداخلية */
.rv-txrow {
    border-bottom: 1px solid rgba(255,255,255,.07) !important;
}

/* ── 3. المحفظة (wallet) ──
   تحويل .container.py-5 لشبكة: بطاقة رصيد sticky يسار + أصول/عملات يمين */
.container.py-5:has(.wallet-card) {
    max-width: 1100px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    display: grid !important;
    grid-template-columns: 340px minmax(0, 1fr) !important;
    grid-template-rows: auto auto 1fr !important;
    gap: 0 28px !important;
    align-items: start !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
}
/* بطاقة الرصيد: sticky أول العمود الأيمن (RTL) */
.container.py-5:has(.wallet-card) > .wallet-card {
    grid-column: 1 !important;
    grid-row: 1 / span 3 !important;
    position: sticky !important;
    top: 76px !important;
    max-width: none !important;
}
/* قسم الأصول المملوكة */
.container.py-5:has(.wallet-card) > #rwaSec {
    grid-column: 2 !important;
    grid-row: 1 !important;
}
/* قسم أفضل 50 عملة */
.container.py-5:has(.wallet-card) > .rw-section:not(#rwaSec) {
    grid-column: 2 !important;
    grid-row: 2 !important;
}
/* أي عناصر أخرى */
.container.py-5:has(.wallet-card) > *:not(.wallet-card):not(#rwaSec):not(.rw-section) {
    grid-column: 2 !important;
    grid-row: 3 !important;
}
/* قائمة العملات: عمودان داخل عمود الشبكة */
.container.py-5:has(.wallet-card) .rw-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 20px;
}
.container.py-5:has(.wallet-card) .rw-row {
    border-bottom: 1px solid rgba(255,255,255,.06);
}

/* ── 4. مركز الأوامر (deals) ──
   شريط الفلتر أفقي، تبويبات بلا تمرير */
.rvo-wrap {
    max-width: 1100px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-bottom: 40px !important;
}
/* الفلتر: بحث + تاريخ في صف واحد */
.rvo-filter {
    flex-direction: row !important;
    align-items: center !important;
    gap: 12px !important;
    flex-wrap: nowrap !important;
}
.rvo-q { flex: 1 1 auto !important; }
.rvo-dates { flex: 0 0 auto !important; }
/* التبويبات الفرعية: بلا overflow scroll */
.rvo-subs {
    flex-wrap: wrap !important;
    overflow-x: visible !important;
}
/* toast: فوق الشريط السفلي المختفي */
.rvo-toast { bottom: 20px !important; }

/* ── 5. KYC ── */
.rv-kyc-wrap {
    max-width: 680px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ── 6. VIP ──
   نوسّع وتوسيط — الكاروسيل يبقى كما هو (JS يتحكم في transform) */
.cx-page.vip-page {
    max-width: 980px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}
/* البطاقات: scroll أفقي مرئي (Snap) بلا مس transform JS */
.vip-viewport { overflow-x: auto !important; overflow-y: hidden !important; scroll-snap-type: x mandatory !important; }
.vip-track { scroll-snap-type: x mandatory !important; }
.vip-card  { scroll-snap-align: center !important; }
/* نقاط التنقل السفلية تبقى كما هي */

/* ── 7. صفحة المعاملات القديمة (page=transaction) ──
   إصلاح margin-right:250px الضار */
.container.transaction-list {
    max-width: 860px !important;
    margin-right: auto !important;
    margin-left: auto !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* ── 8. صفحة الدردشة (chat) ── */
.chat-dashboard {
    max-width: 860px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ── 9. صفحتا VIP المساعدتان (features/vipfeatures) ── */
.cx-page:not(.vip-page) {
    max-width: 860px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ── 10. صفحة الشروط والخصوصية والمحتوى العام ── */
.content-fd .container { max-width: 800px !important; margin-left: auto !important; margin-right: auto !important; }

} /* نهاية مرحلة أ+ب @media (min-width:1024px) */

/* ════════════════════════════════════════════════════════════
   طبقة التابلت  768–1023px
   ─ الشريط السفلي يبقى ─ الشريط العلوي مخفي ─
   ─ max-widths متزنة + بعض الأعمدة لاستغلال العرض ─
   ════════════════════════════════════════════════════════════ */

@media (min-width: 768px) and (max-width: 1023px) {

/* ── الأساس: حشو أفقي موحّد لكل الحاويات ── */
.rv-home.rv-home2,
.rv-mkts,
.rv-txlog,
.rvo-wrap,
.rvp-wrap,
.rv-kyc-wrap,
.cx-page {
    padding-left: 20px !important;
    padding-right: 20px !important;
}

/* ── الرئيسية: عمودان 300px + 1fr ── */
.rv-h2-mkt {
    display: grid !important;
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 0 20px !important;
    align-items: start !important;
}
.rv-h2-mkt > .rv-h2-search { grid-column: 2 !important; grid-row: 1 !important; }
.rv-h2-mkt > .rv-h2-list   { grid-column: 2 !important; grid-row: 2 / span 8 !important; }
.rv-h2-mkt > .rv-h2-wallet { grid-column: 1 !important; grid-row: 1 / span 2 !important; position: sticky !important; top: 16px !important; }
.rv-h2-mkt > .rv-h2-promo  { grid-column: 1 !important; grid-row: 3 !important; }
.rv-h2-mkt > *:not(.rv-h2-search):not(.rv-h2-list):not(.rv-h2-wallet):not(.rv-h2-promo) { grid-column: 2 !important; }

/* ── الأسواق: عمودان ── */
.rv-mkts .rv-mkt-list,
.rv-mkts #rvMktList {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    column-gap: 28px !important;
    align-items: start !important;
}

/* ── مركز الأوامر ── */
.rvo-wrap { max-width: 100% !important; }
.rvo-filter {
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px !important;
}
.rvo-q { flex: 1 1 auto !important; }
.rvo-dates { flex: 0 0 auto !important; }
/* البطاقات: عمودان */
.rvo-list {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 12px !important;
}
.rvo-list > .rvo-empty { grid-column: 1 / -1 !important; }

/* ── P2P ── */
.rvp-wrap { max-width: 100% !important; }
#rvp2pRoot .rvp-list {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px !important;
}

/* ── سجل المعاملات ── */
.rv-txlog {
    max-width: 700px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ── المحفظة ── */
.wallet-card {
    max-width: 680px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}
/* قائمة العملات: عمودان */
.rw-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 18px;
}

/* ── الإيداع ── */
.panel.mx-auto { max-width: 600px !important; margin-left: auto !important; margin-right: auto !important; }

/* ── VIP/KYC/إعدادات ── */
.cx-page.vip-page { max-width: 680px !important; margin-left: auto !important; margin-right: auto !important; }
.rv-kyc-wrap      { max-width: 600px !important; margin-left: auto !important; margin-right: auto !important; }
.rvsec-page       { max-width: 580px !important; }

/* ── fix margin-right:250px على صفحة transaction ── */
.container.transaction-list {
    max-width: 680px !important;
    margin-right: auto !important;
    margin-left: auto !important;
    margin-top: 0 !important;
}

/* ── شريط أسفل يبقى — التنقل الموبايل محفوظ ── */
body.rv-has-tabbar {
    padding-bottom: 72px !important;
    padding-top: 0 !important;  /* لا شريط علوي على التابلت */
}
/* إخفاء الشريط العلوي (مخفي بـ display:none الأساسي — هذا تأكيد) */
#rvTopNav { display: none !important; }

/* RioSheet: مودال مركزي على التابلت */
#rs-root { align-items: center !important; justify-content: center !important; }
#rs-sheet {
    width: min(520px, 94vw) !important;
    max-width: 520px !important;
    min-height: 0 !important;
    max-height: 86vh !important;
    border-radius: 18px !important;
}
#rs-sheet .rs-handle { display: none !important; }

} /* نهاية طبقة التابلت */

/* ════════════════════════════════════════════════════════════
   شاشات واسعة جدًا (≥1440px): توسعة متزنة
   ════════════════════════════════════════════════════════════ */

@media (min-width: 1440px) {
    /* حاويات الصفحات العامة */
    .rv-home.rv-home2,
    .rv-mkts,
    .rvp-wrap { max-width: 1320px !important; }

    /* حاوية السبوت */
    .tsp#tspRoot {
        grid-template-columns: 240px minmax(0, 1fr) 340px !important;
    }

    /* الفوركس/الثنائية */
    .tfx, .tbn { max-width: 1480px !important; padding-left: 32px !important; padding-right: 32px !important; }

    /* الفوركس: عمود القائمة أعرض */
    .tfx #tfxPaneTrade {
        grid-template-columns: 320px minmax(0, 1fr) 360px !important;
    }

    /* سجل المعاملات */
    .rv-txlog { max-width: 1100px !important; }

    /* المحفظة */
    .container.py-5:has(.wallet-card) {
        max-width: 1200px !important;
        grid-template-columns: 380px minmax(0, 1fr) !important;
    }

    /* مركز الأوامر */
    .rvo-wrap { max-width: 1200px !important; }

    /* صفحات الحساب */
    .rvsec-page, .settings-page, .profile-page { max-width: 740px !important; }
    .panel.mx-auto { max-width: 760px !important; }
}

/* شاشات كبيرة جدًا (1600+): توسعة إضافية لمنصات التداول */
@media (min-width: 1600px) {
    .tfx, .tbn { max-width: 1560px !important; }
    .rv-home.rv-home2, .rv-mkts, .rvp-wrap, .rvo-wrap { max-width: 1380px !important; }
    .tsp#tspRoot {
        grid-template-columns: 240px minmax(0, 1fr) 340px;
    }
}
