/* ================================================================
   AvaPay · Modern UI layer for Exchange / Transfer / Settlement
   ----------------------------------------------------------------
   طراحی مدرن، رسپانسیو و اپلیکیشنی برای سه بخش:
   تبادل ارزی (arad.php)، حواله ارزی (money_transfer.php)،
   تسویه حساب (withdrawal_modal_system.php)

   نکته: پس‌زمینه‌ی گرادیانت رفت‌وبرگشتی (animated gradient)
   دست‌نخورده باقی می‌ماند؛ این لایه فقط اجزای روی صفحه را
   بازطراحی می‌کند و منطق/آی‌دی‌ها/APIها را تغییر نمی‌دهد.
   ================================================================ */

:root {
    --av-gold: #FFD700;
    --av-gold-2: #FFA500;
    --av-purple: #6C40C5;
    --av-pink: #FF4D8D;
    --av-green: #35d07f;
    --av-green-2: #2ecc71;
    --av-red: #ff5a6e;
    --av-blue: #38bdf8;

    --av-ink: #ffffff;
    --av-muted: rgba(255, 255, 255, 0.62);
    --av-faint: rgba(255, 255, 255, 0.42);

    --av-glass: rgba(255, 255, 255, 0.055);
    --av-glass-2: rgba(255, 255, 255, 0.09);
    --av-stroke: rgba(255, 255, 255, 0.12);
    --av-stroke-gold: rgba(255, 215, 0, 0.28);

    --av-radius: 22px;
    --av-radius-lg: 30px;
    --av-radius-sm: 14px;

    --av-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.65);
    --av-shadow-gold: 0 12px 30px -8px rgba(255, 175, 0, 0.45);

    --av-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- بستر امن: پس‌زمینه‌ی متحرک را لمس نمی‌کنیم ---------- */
.av-scope * { -webkit-tap-highlight-color: transparent; }

/* عرض اپلیکیشنی و یکدست */
.av-shell {
    max-width: 520px;
    margin: 0 auto;
    padding: 0 2px 96px;
}

/* ================= هدر شیشه‌ای ================= */
.av-topbar {
    position: sticky;
    top: 8px;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    margin: 10px 0 16px;
    border-radius: var(--av-radius-lg);
    background: linear-gradient(135deg, rgba(20, 12, 40, 0.72), rgba(10, 8, 24, 0.55));
    backdrop-filter: blur(22px) saturate(140%);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    border: 1px solid var(--av-stroke-gold);
    box-shadow: var(--av-shadow);
    animation: avRise 0.5s var(--av-ease) both;
}
.av-brand { display: flex; align-items: center; gap: 12px; }
.av-brand-badge {
    width: 46px; height: 46px; flex: none;
    border-radius: 16px;
    display: grid; place-items: center;
    background: linear-gradient(135deg, var(--av-gold), var(--av-gold-2));
    box-shadow: var(--av-shadow-gold);
    position: relative; overflow: hidden;
}
.av-brand-badge::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.55) 50%, transparent 70%);
    transform: translateX(-120%);
    animation: avSheen 3.2s var(--av-ease) infinite;
}
.av-brand-badge i { font-size: 1.35rem; color: #1a1030; z-index: 1; }
.av-brand-title { line-height: 1.15; }
.av-brand-title h1 {
    font-size: 1.15rem; margin: 0; font-weight: 800; letter-spacing: .3px;
    background: linear-gradient(120deg, var(--av-gold), #fff 55%, var(--av-gold-2));
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.av-brand-title span { font-size: .64rem; color: var(--av-faint); }

.av-topbar-actions { display: flex; align-items: center; gap: 8px; }
.av-icon-btn {
    width: 44px; height: 44px; border-radius: 50%;
    display: grid; place-items: center;
    color: #fff; text-decoration: none; cursor: pointer;
    background: var(--av-glass); border: 1px solid var(--av-stroke);
    transition: transform .2s var(--av-ease), background .2s;
}
.av-icon-btn:hover { transform: translateY(-2px); background: rgba(255,215,0,.14); }

/* ================= ناوبری سه‌گانه (Segmented) ================= */
.av-nav {
    display: flex; gap: 6px; padding: 6px;
    margin-bottom: 18px;
    border-radius: 60px;
    background: linear-gradient(135deg, rgba(255,255,255,.07), rgba(108,64,197,.10));
    border: 1px solid var(--av-stroke);
    backdrop-filter: blur(16px);
    animation: avRise 0.55s var(--av-ease) both;
}
.av-nav a {
    flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 8px; border-radius: 50px;
    color: var(--av-muted); text-decoration: none;
    font-weight: 700; font-size: .82rem;
    transition: all .3s var(--av-ease);
    position: relative;
}
.av-nav a i { font-size: .92rem; }
.av-nav a.active {
    color: #1a1030;
    background: linear-gradient(135deg, var(--av-gold), var(--av-gold-2));
    box-shadow: 0 8px 18px -6px rgba(255,175,0,.6);
}
.av-nav a:not(.active):active { transform: scale(.97); }
@media (max-width: 430px){
    .av-nav a { font-size: .72rem; gap: 5px; padding: 11px 4px; }
    .av-nav a span { font-size: .72rem; }
}

/* ================= کارت آمار + نمودار زنده ================= */
.av-insights {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 12px;
    margin-bottom: 18px;
}
@media (max-width: 480px){ .av-insights { grid-template-columns: 1fr; } }

.av-card {
    background: linear-gradient(160deg, var(--av-glass-2), rgba(255,255,255,.02));
    border: 1px solid var(--av-stroke);
    border-radius: var(--av-radius);
    padding: 16px;
    box-shadow: var(--av-shadow);
    animation: avRise 0.6s var(--av-ease) both;
}
.av-card-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 12px;
}
.av-card-head h3 {
    display: flex; align-items: center; gap: 8px;
    font-size: .9rem; font-weight: 800; color: #fff; margin: 0;
}
.av-card-head h3 i { color: var(--av-gold); }
.av-chip {
    font-size: .62rem; font-weight: 800; padding: 4px 10px; border-radius: 50px;
    background: rgba(255,215,0,.14); color: var(--av-gold);
    border: 1px solid var(--av-stroke-gold);
}
.exc-chip {
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(255,255,255,.05);
    color: rgba(255,255,255,.7);
    font-family: inherit; font-weight: 800; font-size: .66rem;
    padding: 6px 12px; border-radius: 50px; cursor: pointer;
    direction: ltr;
    transition: all .2s var(--av-ease);
}
.exc-chip:active { transform: scale(.95); }
.exc-chip.active {
    background: linear-gradient(135deg, var(--av-gold), #FFA500);
    border-color: transparent;
    color: #1a1030;
    box-shadow: 0 6px 14px -6px rgba(255,175,0,.7);
}

/* --- نمودار دونات (SVG) --- */
.av-donut-wrap { display: flex; align-items: center; gap: 14px; }
.av-donut { position: relative; width: 108px; height: 108px; flex: none; }
.av-donut svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.av-donut .track { fill: none; stroke: rgba(255,255,255,.08); stroke-width: 12; }
.av-donut .ring {
    fill: none; stroke-width: 12; stroke-linecap: round;
    transition: stroke-dasharray 1.1s var(--av-ease);
}
.av-donut-center {
    position: absolute; inset: 0; display: grid; place-items: center; text-align: center;
}
.av-donut-center b { font-size: 1.35rem; font-weight: 800; color: #fff; display: block; line-height: 1; }
.av-donut-center small { font-size: .6rem; color: var(--av-faint); }

.av-legend { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.av-legend .row {
    display: flex; align-items: center; gap: 8px; font-size: .74rem; color: var(--av-muted);
}
.av-legend .dot { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.av-legend .row b { color: #fff; margin-inline-start: auto; font-weight: 800; }

/* --- نمودار میله‌ای مینی (روند) --- */
.av-spark { display: flex; align-items: flex-end; gap: 6px; height: 92px; padding-top: 8px; }
.av-spark .bar {
    flex: 1; border-radius: 8px 8px 4px 4px; min-height: 6px;
    background: linear-gradient(180deg, var(--av-gold), rgba(255,165,0,.35));
    transform-origin: bottom; transform: scaleY(0);
    animation: avGrow .7s var(--av-ease) forwards;
}
.av-spark .bar.alt { background: linear-gradient(180deg, var(--av-purple), rgba(255,77,141,.4)); }
.av-spark-labels { display: flex; justify-content: space-between; margin-top: 8px; }
.av-spark-labels span { font-size: .58rem; color: var(--av-faint); flex: 1; text-align: center; }

/* ================= ردیف آمار جمع‌وجور ================= */
.av-stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 18px; }
.av-stat {
    text-align: center; padding: 14px 8px; border-radius: var(--av-radius-sm);
    background: var(--av-glass); border: 1px solid var(--av-stroke);
    animation: avRise .6s var(--av-ease) both;
}
.av-stat i { font-size: 1.05rem; }
.av-stat .num { font-size: 1.1rem; font-weight: 800; color: #fff; margin: 6px 0 2px;
    font-variant-numeric: tabular-nums; }
.av-stat .lbl { font-size: .58rem; color: var(--av-faint); }

/* ================= دکمه اصلی (CTA) ================= */
.av-cta {
    width: 100%; border: none; cursor: pointer;
    display: flex; align-items: center; justify-content: center; gap: 12px;
    padding: 16px 22px; margin-bottom: 20px;
    border-radius: 60px; font-weight: 800; font-size: 1rem; color: #1a1030;
    background: linear-gradient(120deg, var(--av-gold), var(--av-gold-2));
    box-shadow: var(--av-shadow-gold);
    transition: transform .25s var(--av-ease), box-shadow .25s;
    position: relative; overflow: hidden;
    font-family: inherit;
}
.av-cta::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(120deg, transparent 35%, rgba(255,255,255,.5) 50%, transparent 65%);
    transform: translateX(-120%);
    animation: avSheen 3.6s var(--av-ease) infinite;
}
.av-cta:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -8px rgba(255,175,0,.55); }
.av-cta:active { transform: translateY(1px); }

/* ================= هدر بخش ================= */
.av-section-title {
    display: flex; align-items: center; justify-content: space-between;
    margin: 6px 2px 14px;
}
.av-section-title h3 {
    display: flex; align-items: center; gap: 8px;
    font-size: .95rem; font-weight: 800; color: #fff; margin: 0;
}
.av-section-title h3 i { color: var(--av-gold); }
.av-refresh {
    background: var(--av-glass); border: 1px solid var(--av-stroke);
    color: var(--av-muted); border-radius: 50px; padding: 7px 14px;
    font-size: .72rem; cursor: pointer; font-family: inherit;
    display: inline-flex; align-items: center; gap: 6px; transition: all .2s;
}
.av-refresh:hover { color: #fff; background: rgba(255,215,0,.12); }
.av-refresh:active i { animation: avSpin .6s linear; }

/* ================= کارت درخواست/حواله مدرن ================= */
.av-req {
    background: linear-gradient(160deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
    border: 1px solid var(--av-stroke);
    border-radius: var(--av-radius);
    padding: 15px; margin-bottom: 14px;
    box-shadow: var(--av-shadow);
    animation: avRise .5s var(--av-ease) both;
    position: relative; overflow: hidden;
}
.av-req::before {
    content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
    background: linear-gradient(180deg, var(--av-gold), var(--av-purple), var(--av-pink));
}
.av-req-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.av-track {
    font-size: .72rem; color: var(--av-muted); direction: ltr;
    background: rgba(0,0,0,.25); padding: 5px 10px; border-radius: 40px;
    display: inline-flex; align-items: center; gap: 6px;
}
.av-badge {
    font-size: .66rem; font-weight: 800; padding: 5px 12px; border-radius: 40px;
    display: inline-flex; align-items: center; gap: 6px;
}
.av-badge.pending { background: rgba(255,193,7,.16); color: #ffce54; }
.av-badge.approved,
.av-badge.awaiting_payment { background: rgba(56,189,248,.16); color: var(--av-blue); }
.av-badge.payment_submitted { background: rgba(108,64,197,.2); color: #b79cf5; }
.av-badge.completed { background: rgba(53,208,127,.18); color: var(--av-green); }
.av-badge.rejected { background: rgba(255,90,110,.16); color: var(--av-red); }

.av-req-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 4px; }
.av-req-cell {
    background: rgba(0,0,0,.2); border-radius: 12px; padding: 10px 8px; text-align: center;
}
.av-req-cell .k { font-size: .58rem; color: var(--av-faint); margin-bottom: 4px; }
.av-req-cell .v { font-size: .82rem; font-weight: 700; color: #fff; }
.av-req-cell .v.gold { color: var(--av-gold); }

/* نوار پیشرفت گام‌ها روی هر کارت */
.av-steps-mini { display: flex; align-items: center; gap: 4px; margin: 12px 0; }
.av-steps-mini .seg { flex: 1; height: 5px; border-radius: 4px; background: rgba(255,255,255,.1); overflow: hidden; }
.av-steps-mini .seg.on { background: linear-gradient(90deg, var(--av-gold), var(--av-green)); }
.av-steps-mini .seg.cur::after {
    content: ""; display: block; height: 100%; width: 50%;
    background: linear-gradient(90deg, var(--av-gold), var(--av-gold-2));
    animation: avPulseBar 1.4s var(--av-ease) infinite;
}

/* ================= استپ‌های پروسه (هرو) ================= */
.av-process {
    background: linear-gradient(160deg, rgba(255,255,255,.05), rgba(255,255,255,.015));
    border: 1px solid var(--av-stroke); border-radius: var(--av-radius);
    padding: 18px 14px; margin-bottom: 20px;
    animation: avRise .6s var(--av-ease) both;
}
.av-process .track { display: flex; align-items: flex-start; justify-content: space-between; }
.av-pstep { flex: 1; text-align: center; position: relative; }
.av-pcircle {
    width: 46px; height: 46px; margin: 0 auto 8px; border-radius: 50%;
    display: grid; place-items: center;
    background: rgba(255,255,255,.05); border: 2px solid var(--av-stroke-gold);
    color: #fff; transition: all .35s var(--av-ease);
}
.av-pstep.active .av-pcircle {
    background: linear-gradient(135deg, var(--av-gold), var(--av-gold-2));
    color: #1a1030; border-color: transparent;
    box-shadow: 0 0 0 6px rgba(255,215,0,.14), 0 8px 18px -6px rgba(255,175,0,.6);
    transform: scale(1.06);
}
.av-pstep.done .av-pcircle { background: var(--av-green); border-color: transparent; color: #04210f; }
.av-pstep .lbl { font-size: .58rem; color: var(--av-faint); font-weight: 700; }
.av-pstep.active .lbl { color: var(--av-gold); }
.av-pstep.done .lbl { color: var(--av-green); }

/* ================= حالت خالی ================= */
.av-empty {
    text-align: center; padding: 40px 20px; color: var(--av-faint);
    border: 1px dashed var(--av-stroke); border-radius: var(--av-radius);
    background: rgba(255,255,255,.02);
}
.av-empty i { font-size: 2.2rem; color: rgba(255,215,0,.4); margin-bottom: 12px; }
.av-empty p { font-size: .9rem; color: var(--av-muted); margin: 0 0 4px; }
.av-empty small { font-size: .72rem; }

/* ================= جداکننده براق ================= */
.av-divider { height: 2px; margin: 22px 0; border-radius: 10px;
    background: linear-gradient(90deg, transparent, var(--av-gold), var(--av-purple), var(--av-pink), var(--av-purple), var(--av-gold), transparent);
    background-size: 200% 100%; animation: avFlow 6s linear infinite;
}

/* ================= کیبورد/دسترسی‌پذیری ================= */
.av-scope a:focus-visible,
.av-scope button:focus-visible,
.av-scope input:focus-visible,
.av-scope select:focus-visible {
    outline: 2px solid var(--av-gold); outline-offset: 2px;
}

/* ================= انیمیشن‌ها ================= */
@keyframes avRise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes avGrow { to { transform: scaleY(1); } }
@keyframes avSheen { 0% { transform: translateX(-120%); } 60%,100% { transform: translateX(120%); } }
@keyframes avSpin { to { transform: rotate(360deg); } }
@keyframes avFlow { to { background-position: 200% 0; } }
@keyframes avPulseBar { 0%,100% { transform: translateX(-20%); opacity:.6;} 50% { transform: translateX(120%); opacity:1;} }
@keyframes avCount { from { opacity: .4; } to { opacity: 1; } }

/* احترام به کاهش حرکت */
@media (prefers-reduced-motion: reduce) {
    .av-scope *,
    .av-brand-badge::after,
    .av-cta::after,
    .av-divider { animation: none !important; transition: none !important; }
    .av-donut .ring { transition: none; }
    .av-spark .bar { transform: scaleY(1); }
}

/* ================================================================
   ارتقای اجزای موجود (بدون تغییر مارک‌آپ صفحات)
   این بخش ظاهر ناوبری، کارت‌ها و مودال‌های موجود را مدرن می‌کند.
   ================================================================ */

/* --- ناوبری سه‌گانه‌ی موجود --- */
.nav-buttons-large {
    gap: 6px !important;
    padding: 6px !important;
    border-radius: 60px !important;
    background: linear-gradient(135deg, rgba(255,255,255,.07), rgba(108,64,197,.10)) !important;
    border: 1px solid rgba(255,255,255,.12) !important;
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 26px -14px rgba(0,0,0,.6);
}
.nav-large-btn {
    border-radius: 50px !important;
    font-weight: 700 !important;
    transition: all .3s cubic-bezier(0.22,1,0.36,1) !important;
}
.nav-large-btn.active {
    background: linear-gradient(135deg, #FFD700, #FFA500) !important;
    color: #1a1030 !important;
    box-shadow: 0 8px 18px -6px rgba(255,175,0,.6) !important;
}
.nav-large-btn:not(.active):active { transform: scale(.97); }

/* --- کارت‌های درخواست حواله‌ی موجود --- */
.request-card-modern {
    border-radius: 22px !important;
    background: linear-gradient(160deg, rgba(255,255,255,.06), rgba(255,255,255,.02)) !important;
    border: 1px solid rgba(255,255,255,.12) !important;
    box-shadow: 0 18px 40px -18px rgba(0,0,0,.65) !important;
    transition: transform .25s cubic-bezier(0.22,1,0.36,1), box-shadow .25s !important;
}
.request-card-modern:hover { transform: translateY(-3px); }

/* نوار گام مینی که با JS داخل کارت‌ها درج می‌شود */
.request-card-modern .av-steps-mini { margin: 12px 0 4px; }

/* --- استپ‌های پروسه‌ی موجود: هاله‌ی نرم دور استپ فعال --- */
.process-step.active .step-icon-circle {
    box-shadow: 0 0 0 6px rgba(255,215,0,.14), 0 8px 18px -6px rgba(255,175,0,.6) !important;
}

/* --- مودال‌های موجود: گوشه‌ها و شیشه‌ای‌تر --- */
.step-modal .modal-container,
.modal-overlay .modal-content {
    backdrop-filter: blur(22px) saturate(140%);
}

/* --- دکمه‌ی شناور پشتیبانی: کمی درخشان‌تر (بدون تغییر رفتار) --- */
.floating-sphere { box-shadow: 0 8px 26px -6px rgba(108,64,197,.6) !important; }

/* --- ریسپانسیو: در موبایل عرض کارت‌های نمودار تک‌ستونه --- */
@media (max-width: 480px) {
    .av-insights { grid-template-columns: 1fr; }
    .av-donut { width: 96px; height: 96px; }
}
.tab-btn {
    flex: 1 !important; display: flex; align-items: center; justify-content: center; gap: 6px;
    padding: 11px 8px !important; border: none !important;
    background: transparent !important; color: rgba(255,255,255,.62) !important;
    font-family: inherit !important; font-weight: 700 !important; font-size: .8rem !important;
    border-radius: 44px !important; cursor: pointer;
    transition: all .3s var(--av-ease) !important; position: relative;
}
.tab-btn i { font-size: .85rem; }
.tab-btn.active {
    background: linear-gradient(135deg, #FFD700, #FFA500) !important;
    color: #1a1030 !important;
    box-shadow: 0 8px 16px -6px rgba(255,175,0,.55) !important;
}
.tab-badge {
    min-width: 18px; height: 18px; padding: 0 5px; border-radius: 20px;
    background: #ff5a6e !important; color: #fff !important;
    font-size: .62rem !important; font-weight: 800;
    display: inline-flex !important; align-items: center; justify-content: center;
    box-shadow: 0 2px 6px rgba(255,90,110,.5);
}
.tab-btn.active .tab-badge { background: #1a1030 !important; color: #FFD700 !important; }

/* ---------- کارت پیشنهاد ---------- */
#offersContainer { display: grid; gap: 12px; }
.offer-card {
    background: linear-gradient(160deg, rgba(255,255,255,.06), rgba(255,255,255,.02)) !important;
    border: 1px solid rgba(255,255,255,.1) !important;
    border-radius: 20px !important;
    padding: 14px !important; margin: 0 !important;
    box-shadow: var(--av-shadow) !important;
    position: relative; overflow: hidden;
    transition: transform .22s var(--av-ease), border-color .22s !important;
}
.offer-card::before {
    content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
    background: #FFD700;
}
.offer-card.accepted::before { background: var(--av-green); }
.offer-card.rejected::before { background: var(--av-red); }
.offer-card.pending::before  { background: #ffce54; }
.offer-card:hover { transform: translateY(-2px); border-color: rgba(255,215,0,.3) !important; }

.offer-header {
    display: flex !important; align-items: center; justify-content: space-between;
    margin-bottom: 12px !important; padding-inline-start: 6px;
}
.offer-user { display: flex !important; align-items: center; gap: 10px; }
.offer-avatar {
    width: 40px; height: 40px; border-radius: 50%;
    display: grid; place-items: center; flex: none;
    background: linear-gradient(135deg, var(--av-purple), var(--av-pink)) !important;
    color: #fff !important; font-weight: 800; font-size: .82rem;
    box-shadow: 0 4px 12px -4px rgba(108,64,197,.6);
}
.offer-user-name { color: #fff !important; font-weight: 700; font-size: .85rem; }
.offer-user-telegram { color: rgba(255,255,255,.4) !important; font-size: .68rem; direction: ltr; text-align: start; }
.offer-status {
    font-size: .66rem !important; font-weight: 800; padding: 5px 12px; border-radius: 40px;
    white-space: nowrap;
}
.offer-status.pending  { background: rgba(255,193,7,.16) !important; color: #ffce54 !important; }
.offer-status.accepted { background: rgba(53,208,127,.18) !important; color: var(--av-green) !important; }
.offer-status.rejected { background: rgba(255,90,110,.16) !important; color: var(--av-red) !important; }

.offer-details {
    display: grid !important; grid-template-columns: repeat(2, 1fr) !important; gap: 8px !important;
    margin-bottom: 0 !important;
}
.offer-detail {
    background: rgba(0,0,0,.2) !important; border-radius: 12px; padding: 10px !important;
    text-align: start !important; border: none !important;
}
.offer-detail-label { color: rgba(255,255,255,.5) !important; font-size: .64rem !important; margin-bottom: 4px; }
.offer-detail-value { color: #fff !important; font-size: .82rem !important; font-weight: 700; }
.offer-message {
    margin-top: 10px !important; padding: 10px 12px !important;
    background: rgba(108,64,197,.12) !important; border: 1px solid rgba(108,64,197,.25);
    border-radius: 12px !important; color: rgba(255,255,255,.75) !important; font-size: .75rem !important;
}
.offer-actions { display: flex !important; gap: 8px; margin-top: 12px !important; }
.btn-accept, .btn-reject {
    flex: 1; padding: 11px !important; border: none !important; cursor: pointer;
    border-radius: 12px !important; font-family: inherit !important;
    font-weight: 800 !important; font-size: .8rem !important;
    transition: transform .18s var(--av-ease), filter .18s !important;
}
.btn-accept { background: linear-gradient(135deg, var(--av-green), var(--av-green-2)) !important; color: #04210f !important; }
.btn-reject { background: rgba(255,90,110,.15) !important; color: var(--av-red) !important; border: 1px solid rgba(255,90,110,.35) !important; }
.btn-accept:active, .btn-reject:active { transform: scale(.96); }
.btn-accept:hover { filter: brightness(1.08); }

/* ---------- معاملات در انتظار تسویه ---------- */
.deals-section, .completed-deals-section { margin-top: 4px; }
.deal-card-active {
    background: linear-gradient(160deg, rgba(255,206,84,.08), rgba(255,255,255,.02)) !important;
    border: 1px solid rgba(255,206,84,.22) !important;
    border-radius: 20px !important; padding: 14px !important; margin-bottom: 12px !important;
    box-shadow: var(--av-shadow) !important;
}
.deal-card-active .deal-header {
    display: flex !important; align-items: center; justify-content: space-between;
    margin-bottom: 12px !important; padding: 0 !important; background: none !important;
}
.deal-code-badge {
    display: inline-flex; align-items: center; gap: 6px; direction: ltr;
    background: rgba(0,0,0,.25); padding: 5px 10px; border-radius: 40px;
    color: #FFD700; font-size: .72rem; font-weight: 700;
}
.status-badge.waiting {
    background: rgba(255,193,7,.16) !important; color: #ffce54 !important;
    padding: 5px 12px; border-radius: 40px; font-size: .66rem; font-weight: 800;
    display: inline-flex; align-items: center; gap: 6px;
}
.deal-timeline .timeline-step.completed .step-icon { background: var(--av-green); border-color: transparent; color: #04210f; }
.deal-timeline .timeline-step.active .step-icon {
    background: linear-gradient(135deg, #FFD700, #FFA500); border-color: transparent; color: #1a1030;
    box-shadow: 0 0 0 5px rgba(255,215,0,.14);
}
.deal-timeline .timeline-step .step-label { font-size: .56rem; color: rgba(255,255,255,.5); font-weight: 600; }
.deal-timeline .timeline-step.active .step-label { color: #FFD700; }
.deal-timeline .timeline-step.completed .step-label { color: var(--av-green); }

.deal-info-grid {
    display: grid !important; grid-template-columns: repeat(3, 1fr) !important; gap: 8px !important;
    margin-bottom: 12px !important;
}
.info-card {
    background: rgba(0,0,0,.22) !important; border-radius: 12px !important; padding: 10px 8px !important;
    text-align: center !important; border: none !important;
}
.info-card .info-icon { font-size: 1rem; margin-bottom: 4px; }
.info-card .info-label { color: rgba(255,255,255,.5) !important; font-size: .58rem !important; }
.info-card .info-value { color: #fff !important; font-size: .8rem !important; font-weight: 700; margin-top: 2px; }
.info-card .info-value.highlight { color: #FFD700 !important; }

.deal-parties {
    display: flex !important; align-items: center; justify-content: space-between; gap: 8px;
    background: rgba(0,0,0,.18); border-radius: 14px; padding: 10px !important;
}
.party-card {
    flex: 1 !important; text-align: center; background: none !important; padding: 0 !important; border: none !important;
}
.party-avatar {
    width: 38px !important; height: 38px !important; margin: 0 auto 5px; border-radius: 50%;
    display: grid; place-items: center; font-weight: 800; font-size: .74rem; color: #fff;
    background: linear-gradient(135deg, var(--av-purple), var(--av-pink)) !important;
}
.party-card:first-child .party-avatar { background: linear-gradient(135deg, #38bdf8, var(--av-purple)) !important; }
.party-card:last-child .party-avatar  { background: linear-gradient(135deg, #FFD700, #FFA500) !important; color: #1a1030 !important; }
.party-name { color: #fff !important; font-size: .72rem; font-weight: 700; }
.party-role { color: rgba(255,255,255,.45) !important; font-size: .6rem; }
.party-vs {
    flex: none !important; width: 32px; height: 32px; border-radius: 50%;
    display: grid; place-items: center; color: #FFD700;
    background: rgba(255,215,0,.12); border: 1px solid rgba(255,215,0,.25);
}
.completed-badge {
    background: rgba(53,208,127,.16) !important; color: var(--av-green) !important;
    padding: 4px 11px; border-radius: 40px; font-size: .64rem; font-weight: 800;
    display: inline-flex; align-items: center; gap: 5px;
}

/* ---------- سرِ بخش‌ها ---------- */
.section-header {
    display: flex !important; align-items: center; justify-content: space-between;
    margin: 4px 2px 14px !important;
}
.section-header h3 {
    display: flex; align-items: center; gap: 8px;
    color: #fff !important; font-size: .95rem !important; font-weight: 800 !important; margin: 0;
}
.section-header h3 i { color: #FFD700; }
.refresh-btn {
    background: rgba(255,255,255,.06) !important; border: 1px solid rgba(255,255,255,.12) !important;
    color: rgba(255,255,255,.65) !important; border-radius: 40px !important;
    padding: 7px 13px !important; font-size: .7rem !important; font-family: inherit !important;
    cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: all .2s;
}
.refresh-btn:hover { color: #fff !important; background: rgba(255,215,0,.12) !important; }

/* ---------- حالت خالی یکدست ---------- */
.empty-state, .empty-deals {
    text-align: center !important; padding: 36px 20px !important;
    border: 1px dashed rgba(255,255,255,.12) !important; border-radius: 20px !important;
    background: rgba(255,255,255,.02) !important; color: rgba(255,255,255,.5) !important;
    grid-column: 1 / -1;
}
.empty-state i, .empty-deals i { font-size: 2rem !important; color: rgba(255,215,0,.4) !important; margin-bottom: 10px; }
.empty-state p, .empty-deals p { color: rgba(255,255,255,.6) !important; font-size: .88rem !important; margin: 0; }

/* ---------- رسپانسیو ریز ---------- */
@media (max-width: 380px) {
    .offer-details { grid-template-columns: 1fr 1fr !important; }
    .deal-info-grid { grid-template-columns: 1fr !important; }
    .deal-timeline .timeline-step .step-label { font-size: .5rem; }
    .tab-btn { font-size: .72rem !important; }
}

/* ================================================================
   ردیف‌های فشرده (پیشنهاد/معامله قبلی) + مدال جزئیات
   ================================================================ */

/* برچسب «جدید» روی کارت پیشنهاد در انتظار */
.offer-card.pending .offer-new-flag {
    position: absolute; top: 0; inset-inline-end: 0;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #1a1030; font-size: .6rem; font-weight: 800;
    padding: 4px 12px; border-bottom-inline-start-radius: 12px;
    border-end-start-radius: 12px;
    display: inline-flex; align-items: center; gap: 4px;
    box-shadow: 0 4px 10px -3px rgba(255,175,0,.6);
}

/* سرِ لیست فشرده */
.compact-list-head {
    display: flex; align-items: center; gap: 8px;
    margin: 14px 4px 8px; color: rgba(255,255,255,.55);
    font-size: .78rem; font-weight: 700;
}
.compact-list-head i { color: #FFD700; }
.compact-list-head span {
    margin-inline-start: auto; background: rgba(255,255,255,.08);
    color: rgba(255,255,255,.7); font-size: .64rem; font-weight: 800;
    padding: 2px 9px; border-radius: 20px;
}

/* ردیف فشرده قابل‌کلیک */
.compact-row {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 14px; margin-bottom: 8px; cursor: pointer;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 14px;
    transition: transform .18s var(--av-ease), background .18s, border-color .18s;
}
.compact-row:hover { background: rgba(255,255,255,.07); border-color: rgba(255,215,0,.25); transform: translateX(-3px); }
.compact-row:active { transform: scale(.99); }
.compact-row .cr-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: #888; }
.compact-row.accepted .cr-dot, .compact-row.completed .cr-dot { background: var(--av-green); box-shadow: 0 0 8px rgba(53,208,127,.6); }
.compact-row.rejected .cr-dot { background: var(--av-red); }
.compact-row .cr-main { flex: 1; min-width: 0; }
.compact-row .cr-title { color: #fff; font-size: .82rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.compact-row .cr-sub { color: rgba(255,255,255,.45); font-size: .66rem; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.compact-row .cr-status {
    font-size: .6rem; font-weight: 800; padding: 4px 10px; border-radius: 40px; flex: none;
}
.compact-row .cr-status.accepted { background: rgba(53,208,127,.16); color: var(--av-green); }
.compact-row .cr-status.rejected { background: rgba(255,90,110,.16); color: var(--av-red); }
.compact-row .cr-date { font-size: .64rem; color: rgba(255,255,255,.4); flex: none; }
.compact-row .cr-arrow { color: rgba(255,255,255,.3); font-size: .7rem; flex: none; }

/* مدال جزئیات */
.dm-content { max-width: 440px; }
.dm-person { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.dm-avatar {
    width: 46px; height: 46px; border-radius: 50%; flex: none;
    display: grid; place-items: center; color: #fff; font-weight: 800; font-size: .9rem;
    background: linear-gradient(135deg, var(--av-purple), var(--av-pink));
}
.dm-name { color: #fff; font-weight: 700; font-size: .92rem; }
.dm-tg { color: rgba(255,255,255,.4); font-size: .7rem; direction: ltr; text-align: start; }
.dm-hero {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 16px; margin-bottom: 14px;
    background: rgba(53,208,127,.1); border: 1px solid rgba(53,208,127,.25); border-radius: 16px;
}
.dm-hero-amount { color: #FFD700; font-size: 1.15rem; font-weight: 800; }
.dm-rows { display: flex; flex-direction: column; gap: 2px; }
.dm-r {
    display: flex; align-items: center; justify-content: space-between;
    padding: 11px 4px; border-bottom: 1px solid rgba(255,255,255,.07);
}
.dm-r:last-child { border-bottom: none; }
.dm-r span { color: rgba(255,255,255,.5); font-size: .78rem; }
.dm-r b { color: #fff; font-size: .82rem; font-weight: 700; }
.dm-reject {
    margin-top: 12px; padding: 10px 12px; border-radius: 12px;
    background: rgba(255,90,110,.1); border: 1px solid rgba(255,90,110,.25);
    color: #ff8b98; font-size: .75rem;
}

/* ================================================================
   دکمه و مدال پرداخت/تسویه‌ی معامله (سمت کاربر)
   ================================================================ */
.deal-manage-btn {
    width: 100%; margin-top: 12px; border: none; cursor: pointer;
    padding: 12px; border-radius: 14px; font-family: inherit;
    font-weight: 800; font-size: .85rem; color: #1a1030;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    box-shadow: 0 8px 18px -6px rgba(255,175,0,.5);
    display: flex; align-items: center; justify-content: center; gap: 8px;
    transition: transform .18s var(--av-ease);
}
.deal-manage-btn:active { transform: scale(.98); }

.ud-summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; color: rgba(255,255,255,.7); font-size: .8rem; }
.ud-code { background: rgba(255,215,0,.14); color: #FFD700; padding: 5px 12px; border-radius: 40px; font-weight: 800; direction: ltr; }

.ud-steps { display: flex; align-items: flex-start; justify-content: space-between; gap: 4px; margin-bottom: 16px; }
.ud-step { flex: 1; text-align: center; }
.ud-step span {
    width: 30px; height: 30px; margin: 0 auto 5px; border-radius: 50%;
    display: grid; place-items: center; font-size: .78rem; font-weight: 800;
    background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.12); color: rgba(255,255,255,.5);
}
.ud-step small { font-size: .56rem; color: rgba(255,255,255,.45); display: block; }
.ud-step.done span { background: var(--av-green); border-color: transparent; color: #04210f; }
.ud-step.active span { background: linear-gradient(135deg,#FFD700,#FFA500); border-color: transparent; color: #1a1030; box-shadow: 0 0 0 5px rgba(255,215,0,.14); }
.ud-step.active small { color: #FFD700; }
.ud-step.done small { color: var(--av-green); }

.ud-block { padding: 14px 0; border-top: 1px solid rgba(255,255,255,.08); }
.ud-title { color: #fff; font-size: .82rem; font-weight: 700; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.ud-title i { color: #FFD700; }
.ud-muted { color: rgba(255,255,255,.45); font-size: .72rem; margin-top: 6px; }

.ud-acc { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: rgba(0,0,0,.25); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
.ud-acc-name { color: #ccc; font-size: .7rem; margin-bottom: 3px; }
.ud-acc code { color: #fff; font-size: .88rem; direction: ltr; letter-spacing: 1px; }
.ud-copy { width: 34px; height: 34px; border-radius: 10px; border: none; cursor: pointer; background: rgba(255,215,0,.14); color: #FFD700; flex: none; }

.ud-upload { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 20px; border: 2px dashed rgba(255,215,0,.3); border-radius: 14px; cursor: pointer; color: rgba(255,255,255,.6); transition: all .2s; }
.ud-upload:hover { border-color: #FFD700; background: rgba(255,215,0,.05); }
.ud-upload i { font-size: 1.6rem; color: #FFD700; }
.ud-upload span { font-size: .78rem; }

.ud-thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.ud-thumb { width: 64px; height: 64px; border-radius: 12px; overflow: hidden; border: 1px solid rgba(255,255,255,.15); cursor: pointer; display: grid; place-items: center; background: rgba(0,0,0,.3); color: #ff6b6b; font-size: 1.6rem; }
.ud-thumb img { width: 100%; height: 100%; object-fit: cover; }

.ud-note { padding: 14px; border-radius: 14px; background: rgba(255,193,7,.1); border: 1px solid rgba(255,193,7,.25); color: #ffce54; font-size: .8rem; text-align: center; }
.ud-note.ok { background: rgba(53,208,127,.1); border-color: rgba(53,208,127,.3); color: var(--av-green); }
.ud-adminnote { margin-top: 10px; padding: 12px; border-radius: 12px; background: rgba(108,64,197,.12); border: 1px solid rgba(108,64,197,.25); color: rgba(255,255,255,.8); font-size: .78rem; }

/* ================================================================
   بلوک تسویه‌ی درون‌کارتی (شماره‌حساب + کپی + آپلود مستقیم)
   در «معاملات در انتظار تسویه»
   ================================================================ */
.deal-card-active .status-badge.submitted { background: rgba(108,64,197,.2) !important; color: #b79cf5 !important; }
.deal-card-active .status-badge.done { background: rgba(53,208,127,.18) !important; color: var(--av-green) !important; }
.deal-card-active .status-badge.waiting { background: rgba(255,193,7,.16) !important; color: #ffce54 !important; }

.dc-settle {
    margin-top: 12px; padding: 14px;
    background: rgba(0,0,0,.22);
    border: 1px solid rgba(255,215,0,.2);
    border-radius: 16px;
}
.dc-settle-title { color: #FFD700; font-size: .8rem; font-weight: 700; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }

.dc-acc {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1);
    border-radius: 12px; padding: 10px 12px; margin-bottom: 8px;
}
.dc-acc-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dc-acc-name { color: rgba(255,255,255,.55); font-size: .68rem; }
.dc-acc code { color: #fff; font-size: .92rem; direction: ltr; letter-spacing: 1.5px; font-weight: 700; }
.dc-copy {
    flex: none; border: none; cursor: pointer;
    background: linear-gradient(135deg, #FFD700, #FFA500); color: #1a1030;
    font-family: inherit; font-weight: 800; font-size: .72rem;
    padding: 8px 14px; border-radius: 10px;
    display: inline-flex; align-items: center; gap: 5px;
    transition: transform .15s var(--av-ease);
}
.dc-copy:active { transform: scale(.94); }

.dc-recs { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }

.dc-actions { display: flex; gap: 8px; margin-top: 10px; }
.dc-upload-btn, .dc-send-btn {
    flex: 1; border: none; cursor: pointer; font-family: inherit;
    font-weight: 800; font-size: .78rem; padding: 11px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    transition: transform .15s var(--av-ease), filter .15s;
}
.dc-upload-btn { background: rgba(255,255,255,.08); color: #fff; border: 1px solid rgba(255,255,255,.15); }
.dc-send-btn { background: linear-gradient(135deg, var(--av-green), var(--av-green-2)); color: #04210f; }
.dc-upload-btn:active, .dc-send-btn:active { transform: scale(.97); }
.dc-send-btn:disabled { opacity: .6; }
.dc-picked { display: block; margin-top: 8px; color: rgba(255,255,255,.55); font-size: .7rem; text-align: center; }

.dc-note {
    margin-top: 12px; padding: 12px 14px; border-radius: 14px;
    background: rgba(255,193,7,.1); border: 1px solid rgba(255,193,7,.25);
    color: #ffce54; font-size: .78rem; text-align: center;
}
.dc-note.ok { background: rgba(53,208,127,.1); border-color: rgba(53,208,127,.3); color: var(--av-green); }

/* یادداشت پشتیبانی روی کارت معامله (در انتظار تسویه + تاریخچه) */
.dc-adminnote {
    margin-top: 10px; padding: 12px 14px; border-radius: 12px;
    background: rgba(108,64,197,.12); border: 1px solid rgba(108,64,197,.28);
    color: rgba(255,255,255,.82); font-size: .76rem; line-height: 1.8;
    display: flex; align-items: flex-start; gap: 7px;
}
.dc-adminnote i { color: #b79cf5; margin-top: 3px; }

/* فیش‌های تسویه داخل تاریخچه معاملات */
.deal-card-completed .dc-recs { margin-top: 10px; }
.deal-card-completed .completed-badge { white-space: nowrap; }
.db-cur-tab.active { background: linear-gradient(135deg,#FFD700,#FFA500); color: #1a1030; }
.db-chat-list { max-height: 260px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 6px 2px; margin-bottom: 10px; }
.db-chat-empty { text-align: center; color: rgba(255,255,255,.4); font-size: .78rem; padding: 24px 0; }
.db-msg { display: flex; }
.db-msg.user { justify-content: flex-start; }
.db-msg.admin { justify-content: flex-end; }
.db-msg-b {
    max-width: 78%; padding: 9px 13px; border-radius: 16px; font-size: .8rem; line-height: 1.5;
    word-break: break-word;
}
.db-msg.user .db-msg-b { background: rgba(255,255,255,.08); color: #fff; border-bottom-right-radius: 4px; }
.db-msg.admin .db-msg-b { background: linear-gradient(135deg, rgba(255,215,0,.9), rgba(255,165,0,.85)); color: #1a1030; border-bottom-left-radius: 4px; font-weight: 600; }
.db-msg-file { display: inline-flex; align-items: center; gap: 5px; margin-top: 5px; font-size: .72rem; color: inherit; text-decoration: underline; }

.db-chat-input { display: flex; align-items: center; gap: 8px; }
.db-chat-input input[type=text] {
    flex: 1; min-width: 0; background: rgba(0,0,0,.3); border: 1px solid rgba(255,255,255,.14);
    border-radius: 30px; padding: 11px 16px; color: #fff; font-family: inherit; font-size: .82rem;
}
.db-chat-input input[type=text]:focus { outline: none; border-color: #FFD700; }
.db-chat-file { width: 42px; height: 42px; flex: none; border-radius: 50%; display: grid; place-items: center; cursor: pointer; background: rgba(255,255,255,.08); color: rgba(255,255,255,.7); }
.db-chat-input button { width: 42px; height: 42px; flex: none; border: none; cursor: pointer; border-radius: 50%; background: linear-gradient(135deg,#FFD700,#FFA500); color: #1a1030; font-size: .9rem; }
.db-chat-fileinfo { display: block; margin-top: 6px; font-size: .68rem; color: rgba(255,255,255,.5); text-align: center; }

/* ================================================================
   نمودار روند بالانس داخل کارت WALLET (رفع باگ بزرگ‌شدن بی‌نهایت)
   کلید رفع باگ: کانتینر با ارتفاع ثابت + position:relative
   ================================================================ */
.wallet-chart-wrap {
    position: relative;      /* لازم برای responsive بدون رشد */
    width: 100%;
    height: 120px;           /* ارتفاع ثابت؛ canvas داخلش کشیده می‌شود */
    margin-bottom: 10px;
}
.wallet-chart-wrap canvas {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    display: block;
}

/* ================================================================
   پولیش مدرن کل داشبورد (UI/UX) — روی کلاس‌های موجود، بدون تغییر منطق
   ================================================================ */
/* کارت اصلی ولت */
.wallet-hero {
    background: linear-gradient(160deg, rgba(108,64,197,.28), rgba(20,12,40,.55)) !important;
    border: 1px solid rgba(255,215,0,.22) !important;
    border-radius: 26px !important;
    box-shadow: 0 22px 50px -22px rgba(0,0,0,.7) !important;
    backdrop-filter: blur(18px);
    position: relative; overflow: hidden;
}
.wallet-hero::before {
    content:""; position:absolute; top:-40%; inset-inline-end:-20%;
    width: 240px; height: 240px; border-radius:50%;
    background: radial-gradient(circle, rgba(255,215,0,.14), transparent 70%);
    pointer-events:none;
}
.wallet-hero-amount { letter-spacing: .5px; }
.wallet-hero-switch button {
    border-radius: 40px !important; font-weight: 700 !important;
    transition: all .25s var(--av-ease) !important;
}
.wallet-hero-switch button.active {
    background: linear-gradient(135deg,#FFD700,#FFA500) !important; color:#1a1030 !important;
    box-shadow: 0 8px 16px -6px rgba(255,175,0,.55) !important;
}

/* بخش‌های اصلی: تبدیل به کارت شیشه‌ای یکدست */
.topup-panel,
.invoice-section,
.news-section,
.currency-rate-card,
.quick-actions,
.qa-section {
    border-radius: 24px !important;
}

/* دکمه‌های اکشن سریع */
.qa-item { transition: transform .2s var(--av-ease); }
.qa-item:active { transform: scale(.96); }
.qa-circle {
    box-shadow: 0 10px 22px -10px rgba(108,64,197,.6) !important;
    transition: transform .2s var(--av-ease);
}
.qa-item:hover .qa-circle { transform: translateY(-3px); }

/* تب‌های ارز تاپ‌آپ */
.tp-cur-tab { border-radius: 40px !important; transition: all .2s var(--av-ease) !important; }

/* استپ‌های تاپ‌آپ */
.tp-step-circle { transition: all .3s var(--av-ease); }

/* دکمه‌های اصلی */
.btn, .tp-btn-send {
    border-radius: 40px !important;
    transition: transform .2s var(--av-ease), filter .2s !important;
}
.btn:active, .tp-btn-send:active { transform: scale(.98); }

/* ردیف نرخ ارز */
.currency-rate-title { font-weight: 800 !important; }

/* اسکرول‌بار ظریف در چت */
.db-chat-list::-webkit-scrollbar { width: 5px; }
.db-chat-list::-webkit-scrollbar-thumb { background: rgba(255,215,0,.3); border-radius: 10px; }

/* فاصله‌گذاری یکدست بین سکشن‌ها */
.wallet-display-section,
.topup-section,
.db-extra { margin-bottom: 18px; }

/* ================================================================
   کارت هاب تب‌دار داشبورد (اخبار / نرخ ارز / تراکنش‌ها)
   ================================================================ */
.hub-card {
    background: linear-gradient(160deg, rgba(255,255,255,.07), rgba(255,255,255,.02));
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 24px; padding: 8px;
    margin: 0 0 22px 0;
    box-shadow: 0 18px 40px -18px rgba(0,0,0,.65);
    direction: rtl;
}
.hub-tabs {
    display: flex; gap: 4px; padding: 5px;
    background: rgba(0,0,0,.25); border-radius: 40px; margin-bottom: 12px;
}
.hub-tab {
    flex: 1; border: none; cursor: pointer; background: transparent;
    color: rgba(255,255,255,.6); font-family: inherit; font-weight: 700; font-size: .78rem;
    padding: 10px 6px; border-radius: 30px;
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    transition: all .25s var(--av-ease);
    position: relative;
}

/* دایره‌ی قرمز پیام‌های خوانده‌نشده‌ی پشتیبانی */
.hub-tab-badge {
    min-width: 18px; height: 18px; padding: 0 5px;
    border-radius: 999px;
    background: #FF3B30; color: #fff;
    font-size: .58rem; font-weight: 800; line-height: 1;
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: 0 0 0 2px rgba(26,16,48,.85), 0 2px 8px rgba(255,59,48,.6);
    animation: hubBadgePulse 1.8s ease-in-out infinite;
}
.hub-tab.active .hub-tab-badge {
    box-shadow: 0 0 0 2px rgba(255,215,0,.9), 0 2px 8px rgba(255,59,48,.6);
}
@keyframes hubBadgePulse {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.15); }
}
.hub-tab i { font-size: .82rem; }
.hub-tab.active {
    background: linear-gradient(135deg, #FFD700, #FFA500); color: #1a1030;
    box-shadow: 0 8px 16px -6px rgba(255,175,0,.55);
}
.hub-panel { display: none; padding: 6px; animation: avRise .35s var(--av-ease) both; }
.hub-panel.active { display: block; }

/* بخش «شارژ حساب» که به داخل تب «شارژ» منتقل شد:
   کارت‌درکارت نشود — قاب و پس‌زمینه‌ی داخلی حذف می‌شود. */
#hub-topup .topup-section { margin: 0; }
#hub-topup .topup-panel {
    background: none;
    border: none;
    border-radius: 0;
    padding: 0;
}
#hub-topup .topup-panel::before { display: none; }
.hub-rate-iframe { width: 100%; height: 420px; border: none; border-radius: 16px; background: #fff; }

.hub-tx-list { display: flex; flex-direction: column; gap: 8px; }
.hub-tx { display: flex; align-items: center; gap: 10px; padding: 11px 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); border-radius: 14px; }
.hub-tx-ic { width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: .82rem; }
.hub-tx-main { flex: 1; min-width: 0; }
.hub-tx-desc { color: #fff; font-size: .8rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hub-tx-date { color: rgba(255,255,255,.4); font-size: .64rem; margin-top: 2px; }
.hub-tx-amt { font-weight: 800; font-size: .82rem; direction: ltr; flex: none; }
.hub-empty { text-align: center; padding: 34px 10px; color: rgba(255,255,255,.4); }
.hub-empty i { font-size: 1.8rem; color: rgba(255,215,0,.4); margin-bottom: 8px; }
.hub-empty p { font-size: .82rem; margin: 0; }

/* ================================================================
   هاب تب‌دار: رنگ و آیکون متفاوت برای هر تب + تب شارژ
   ================================================================ */
.hub-tab { flex-direction: column; gap: 3px; }
.hub-tab span { font-size: .68rem; }
.hub-tab i { font-size: .95rem; color: var(--tc, #FFD700); transition: color .2s; }
.hub-tab.active {
    background: var(--tc, #FFA500);
    color: #0e0a1e;
    box-shadow: 0 8px 16px -8px rgba(0,0,0,.6);
}
.hub-tab.active i { color: #0e0a1e; }

/* تب شارژ */
.hub-topup-cta {
    display: flex; align-items: center; gap: 12px;
    padding: 16px; border-radius: 18px;
    background: linear-gradient(135deg, rgba(53,208,127,.16), rgba(46,204,113,.06));
    border: 1px solid rgba(53,208,127,.3);
    margin-bottom: 12px;
}
.hub-topup-ic {
    width: 48px; height: 48px; flex: none; border-radius: 14px;
    display: grid; place-items: center; font-size: 1.2rem; color: #04210f;
    background: linear-gradient(135deg, #35d07f, #2ecc71);
    box-shadow: 0 8px 18px -6px rgba(53,208,127,.6);
}
.hub-topup-txt { flex: 1; min-width: 0; }
.hub-topup-txt b { display: block; color: #fff; font-size: .9rem; }
.hub-topup-txt span { font-size: .72rem; color: rgba(255,255,255,.55); }
.hub-topup-btn {
    border: none; cursor: pointer; white-space: nowrap;
    background: linear-gradient(135deg, #35d07f, #2ecc71); color: #04210f;
    font-family: inherit; font-weight: 800; font-size: .76rem;
    padding: 10px 14px; border-radius: 30px;
    display: inline-flex; align-items: center; gap: 5px;
}
.hub-topup-note {
    font-size: .74rem; color: rgba(255,255,255,.55);
    background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
    border-radius: 12px; padding: 10px 12px;
    display: flex; align-items: center; gap: 7px;
}
.hub-topup-note i { color: #38bdf8; }

/* چت داخل هاب: ارتفاع مناسب */
#hub-chat .db-chat-list { max-height: 300px; }
