/* --- Premium Preloader & Animations --- */
#mergen-preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, #1e293b 0%, #0f172a 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.8s;
}

#mergen-preloader.fade-out {
    opacity: 0;
    visibility: hidden;
}

.loader-logo {
    width: 120px;
    height: 120px;
    max-width: 100%;
    position: relative;
    margin-bottom: 2rem;
}

.loader-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 2px solid transparent;
    border-top-color: var(--neon-blue);
    border-radius: 50%;
    animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.loader-ring:nth-child(2) {
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    border-top-color: var(--neon-purple);
    animation-delay: -0.3s;
}

.loader-ring:nth-child(3) {
    width: 60%;
    height: 60%;
    top: 20%;
    left: 20%;
    border-top-color: var(--ametist);
    animation-delay: -0.6s;
}

.loader-text {
    font-family: 'Outfit', sans-serif;
    color: white;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 0 0 10px rgba(0, 210, 255, 0.5);
    animation: text-pulse 2s infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes text-pulse {
    0%, 100% { opacity: 0.5; transform: scale(0.98); }
    50% { opacity: 1; transform: scale(1.02); }
}

/* Staggered Entry Animation */
.premium-entry {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
}

.premium-entry.show {
    opacity: 1;
    transform: translateY(0);
}


    :root {
        --glass: rgba(15, 23, 42, 0.4);
        --neon-blue: #00d2ff;
        --neon-purple: #9d50bb;
        --text-bright: #f8fafc;
        --theme-text-muted: #94a3b8;
        --ametist: #a855f7;
    }

    .border-purple-glow {
        border-color: rgba(168, 85, 247, 0.5) !important;
        box-shadow: 0 0 15px rgba(168, 85, 247, 0.2);
    }
    .bg-purple { background-color: var(--ametist) !important; }

    /* --- Premium Glass & Layout --- */
    .glass-card {
        background: var(--glass) !important;
        backdrop-filter: blur(15px) saturate(120%) !important;
        border: 1px solid var(--border-subtle);!important;
        border-radius: 12px;
        transition: all 0.3s ease;
        box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    }

    .glass-card:hover {
        border-color: rgba(0, 210, 255, 0.3) !important;
        box-shadow: 0 0 25px rgba(0, 210, 255, 0.1);
    }

    .sys-telemetry {
        font-family: 'JetBrains Mono', monospace;
        font-size: 0.65rem;
        color: var(--theme-text-muted);
        letter-spacing: 2px;
        text-transform: uppercase;
    }

    .dashboard-header {
        font-family: 'Outfit', sans-serif;
        letter-spacing: 2px;
        text-transform: uppercase;
        font-weight: 800;
        font-size: 0.75rem;
        color: var(--neon-blue);
        opacity: 0.8;
        display: flex;
        align-items: center;
    }

    .telemetry-pulse-node {
        width: 10px;
        height: 10px;
        background: var(--neon-blue);
        border-radius: 50%;
        box-shadow: 0 0 10px var(--neon-blue);
        animation: pulse-ring 2s infinite;
        display: inline-block;
        margin-right: 8px;
    }

    @keyframes pulse-ring {
        0% { opacity: 0.5; box-shadow: 0 0 5px rgba(0, 210, 255, 0.4); }
        70% { opacity: 1; box-shadow: 0 0 15px rgba(0, 210, 255, 0.6); }
        100% { opacity: 0.5; box-shadow: 0 0 5px rgba(0, 210, 255, 0.4); }
    }

    /* --- Stage 1: Institutional Node Map CSS --- */
    .execution-hub {
        position: relative;
        padding: 1.5rem;
        background: var(--surface-card);
        border-radius: 15px;
        border: 1px solid rgba(0, 210, 255, 0.1);
        overflow: hidden;
    }

    .node-track {
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: relative;
        padding: 20px 0;
    }

    .node-track::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, var(--neon-blue), transparent);
        z-index: 0;
        opacity: 0.3;
    }

    .node-item {
        position: relative;
        z-index: 1;
        width: 40px;
        height: 40px;
        background: var(--glass);
        border: 1px solid var(--border-subtle);
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--theme-text-muted);
        transition: all 0.3s ease;
    }

    .node-item.active {
        border-color: var(--neon-blue);
        color: var(--neon-blue);
        box-shadow: 0 0 15px rgba(0, 210, 255, 0.2);
    }

    .node-label {
        position: absolute;
        bottom: -25px;
        font-size: 0.5rem;
        text-transform: uppercase;
        letter-spacing: 1px;
        white-space: nowrap;
        color: var(--theme-text-muted);
    }

    /* Live Data Animations */
    @keyframes flashSuccess {
        0% { background-color: rgba(40, 167, 69, 0.4); transform: scale(1.02); }
        100% { background-color: transparent; transform: scale(1); }
    }
    @keyframes flashDanger {
        0% { background-color: rgba(220, 53, 69, 0.4); transform: scale(1.02); }
        100% { background-color: transparent; transform: scale(1); }
    }
    .animate-flash-success { animation: flashSuccess 1s ease-out; }
    .animate-flash-danger { animation: flashDanger 1s ease-out; }

    /* --- Temel Kart ve Bileşen Yapıları --- */
    .glass-card {
        background: var(--glass);
        backdrop-filter: blur(10px);
        border: 1px solid var(--border-subtle);
        border-radius: 20px;
        transition: 0.3s;
        display: flow-root;
    }

        .glass-card:hover {
            border-color: var(--neon-blue);
            box-shadow: 0 0 15px rgba(0, 210, 255, 0.2);
            transform: translateY(-5px);
        }

    .btn-icon-action {
        background: transparent;
        border: none;
        color: var(--neon-blue);
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.1rem;
    }

        .btn-icon-action:hover {
            color: var(--text-bright);
            text-shadow: 0 0 8px var(--neon-blue);
            transform: scale(1.1);
        }

    /* --- PNL Analitiği ve Modern Segmented Control --- */
    .pnl-period-switcher, .custom-tab-switcher {
        background: var(--surface-card);
        padding: 4px;
        border-radius: 12px;
        border: 1px solid var(--border-subtle);
        display: flex;
        gap: 2px;
    }

        .pnl-period-switcher .btn, .custom-tab-switcher .btn {
            border: none !important;
            border-radius: 8px !important;
            font-size: 0.75rem !important;
            font-weight: 700 !important;
            padding: 6px 12px !important;
            color: #94a3b8 !important;
            background: transparent !important;
            transition: all 0.3s ease;
            min-width: 40px;
        }

            .pnl-period-switcher .btn.active, .custom-tab-switcher .btn.active {
                background: rgba(0, 210, 255, 0.15) !important;
                color: var(--neon-blue) !important;
                box-shadow: 0 0 12px rgba(0, 210, 255, 0.2);
                border: 1px solid rgba(0, 210, 255, 0.4) !important;
            }
            
    .hide-tab {
        position: absolute;
        visibility: hidden;
        opacity: 0;
        pointer-events: none;
        z-index: -1;
    }

    #pnlStartDate {
        background: var(--surface-card);
        border: 1px solid var(--border-subtle);
        color: #f8fafc;
        font-size: 0.8rem;
        padding: 6px 15px;
        border-radius: 50px;
        outline: none;
    }

        #pnlStartDate::-webkit-calendar-picker-indicator {
            filter: invert(1);
            cursor: pointer;
        }

    /* --- PNL Stat Kartları ve Glow Efektleri --- */
    .pnl-stat-card {
        position: relative;
        overflow: hidden;
        z-index: 1;
        padding: 1.25rem !important;
        border: 1px solid var(--border-subtle);!important;
        border-radius: 16px !important;
        background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%) !important;
        backdrop-filter: blur(10px);
        transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        min-height: 90px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .pnl-stat-card::before {
        content: '';
        position: absolute;
        top: 0; left: 0; right: 0; bottom: 0;
        border-radius: 16px;
        padding: 2px;
        background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0));
        -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
        pointer-events: none;
    }

    .pnl-stat-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    }

    .glow-success {
        background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(255,255,255,0.01) 100%) !important;
        box-shadow: inset 0 0 20px rgba(16, 185, 129, 0.03);
    }

    .glow-info {
        background: linear-gradient(135deg, rgba(0, 210, 255, 0.08) 0%, rgba(255,255,255,0.01) 100%) !important;
        box-shadow: inset 0 0 20px rgba(0, 210, 255, 0.03);
    }

    .glow-warning {
        background: linear-gradient(135deg, rgba(245, 158, 11, 0.08) 0%, rgba(255,255,255,0.01) 100%) !important;
        box-shadow: inset 0 0 20px rgba(245, 158, 11, 0.03);
    }

    .glow-primary {
        background: linear-gradient(135deg, rgba(168, 85, 247, 0.08) 0%, rgba(255,255,255,0.01) 100%) !important;
        box-shadow: inset 0 0 20px rgba(168, 85, 247, 0.03);
    }

    .stat-value {
        font-size: clamp(1.2rem, 2.5vw, 1.6rem);
        font-weight: 900;
        background: linear-gradient(to right, #fff, #e2e8f0);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        margin-top: 5px;
    }

    .text-success-neon {
        color: #10b981 !important;
        background: none;
        -webkit-text-fill-color: initial;
        text-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
    }
    
    .text-warning-neon {
        color: #f59e0b !important;
        background: none;
        -webkit-text-fill-color: initial;
        text-shadow: 0 0 15px rgba(245, 158, 11, 0.4);
    }

    /* --- Tablo ve Satır Tasarımları --- */
    .pnl-table-header {
        background: var(--surface-card);!important;
        text-transform: uppercase;
        letter-spacing: 1px;
        font-size: 0.65rem !important;
    }

    .pnl-row-success {
        background: linear-gradient(90deg, rgba(16, 185, 129, 0.15) 0%, rgba(16, 185, 129, 0.02) 50%, transparent 100%) !important;
        box-shadow: inset 4px 0 0 0 #10b981;
    }

    .pnl-row-danger {
        background: linear-gradient(90deg, rgba(244, 63, 94, 0.15) 0%, rgba(244, 63, 94, 0.02) 50%, transparent 100%) !important;
        box-shadow: inset 4px 0 0 0 #f43f5e;
    }

    /* --- Ortak Hesap ve Diğer Yardımcılar --- */
    .partner-glass-card {
        background: rgba(245, 158, 11, 0.08);
        border: 1px solid rgba(245, 158, 11, 0.2);
        border-radius: 20px;
    }

    .icon-shape {
        width: 45px;
        height: 45px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 12px;
        background: var(--surface-card);
        border: 1px solid var(--border-subtle);
    }

    /* --- Mobil Düzenlemeler --- */
    @media (max-width: 1400px) {
        .glass-card { padding: 1rem !important; }
        .stat-value { font-size: 1.4rem !important; }
        .dashboard-header { font-size: 0.65rem !important; }
    }

    @media (max-width: 991.98px) {
        .glass-card {
            height: auto;
            margin-bottom: 1.5rem;
            padding: 1rem !important;
        }

        .stat-value {
            font-size: 1.3rem !important;
        }

    }

    /* Animasyonlar */
    @keyframes rotateIcon {
        from

    {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }

    }

    .btn-refresh-inline:hover i {
        animation: rotateIcon 0.8s linear infinite;
    }

    .wallet-section {
        margin-bottom: 2rem;
    }

    .border-warning-glow {
        border: 1px dashed #f59e0b !important;
        background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
        box-shadow: 0 0 15px rgba(245, 158, 11, 0.1);
    }

    .warning-text-pulse {
        color: #f59e0b;
        animation: pulse-orange 2s infinite;
    }

    @keyframes pulse-orange {
        0%

    {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }

    100% {
        opacity: 1;
    }

    }

    .border-glow-intel {
        border: 1px solid rgba(0, 210, 255, 0.3) !important;
        box-shadow: inset 0 0 20px rgba(0, 210, 255, 0.05);
    }

    .text-neon-blue {
        color: #00d2ff;
        text-shadow: 0 0 8px rgba(0, 210, 255, 0.5);
    }
    
    [data-theme="light"] .text-neon-blue, [data-bs-theme="light"] .text-neon-blue {
        color: #0077b6; /* Stronger contrast for light theme */
        text-shadow: none;
    }

    .fw-900 {
        font-weight: 900;
    }

    .intel-row {
        border-bottom: 1px solid  var(--border-subtle);
        transition: 0.2s;
    }

        .intel-row:hover {
            background: var(--surface-card);
        }

    .trend-dot {
        width: 14px;
        height: 14px;
        border-radius: 50%; /* yuvarlak tasarım */
        display: inline-block;
        transition: all 0.3s ease;
    }

    /* Highlight class for green transition */
    .trend-pulse-green {
        box-shadow: 0 0 0 3px rgba(46, 189, 133, 0.5); /* 2ebd85 */
        border: 2px solid #2ebd85;
        animation: pulse-green 2s infinite;
    }

    /* Highlight class for red transition */
    .trend-pulse-red {
        box-shadow: 0 0 0 3px rgba(246, 70, 93, 0.5); /* f6465d */
        border: 2px solid #f6465d;
        animation: pulse-red 2s infinite;
    }

    @keyframes pulse-green {
        0% { box-shadow: 0 0 0 0 rgba(46, 189, 133, 0.7); }
        70% { box-shadow: 0 0 0 6px rgba(46, 189, 133, 0); }
        100% { box-shadow: 0 0 0 0 rgba(46, 189, 133, 0); }
    }

    @keyframes pulse-red {
        0% { box-shadow: 0 0 0 0 rgba(246, 70, 93, 0.7); }
        70% { box-shadow: 0 0 0 6px rgba(246, 70, 93, 0); }
        100% { box-shadow: 0 0 0 0 rgba(246, 70, 93, 0); }
    }

    .intel-badge {
        font-size: 0.6rem;
        letter-spacing: 1px;
        padding: 5px 10px;
    }

    /* Flow Meter Gradient Animation */
    #dominancePercent {
        background: linear-gradient(to bottom, #fff, #00d2ff);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
    }

    .action-badge {
        padding: 6px 14px;
        border-radius: 8px;
        font-weight: 800;
        font-size: 0.65rem;
        letter-spacing: 1.5px;
        text-transform: uppercase;
        position: relative;
        overflow: hidden;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
        border: 1px solid var(--border-subtle);
        background: var(--surface-card);
    }

        .action-badge.strong-bull {
            color: #00ffcc;
            border-color: #00ffcc;
            box-shadow: inset 0 0 10px rgba(0, 255, 204, 0.2), 0 0 15px rgba(0, 255, 204, 0.2);
            text-shadow: 0 0 5px #00ffcc;
        }

        .action-badge.strong-bear {
            color: #ff0066;
            border-color: #ff0066;
            box-shadow: inset 0 0 10px rgba(255, 0, 102, 0.2), 0 0 15px rgba(255, 0, 102, 0.2);
            text-shadow: 0 0 5px #ff0066;
        }

        .action-badge.bull {
            color: #2ebd85;
            border-color: #2ebd85;
        }

        .action-badge.bear {
            color: #f6465d;
            border-color: #f6465d;
        }

    /* Satır Hover olduğunda badge parlasın */
    .intel-row:hover .action-badge.strong-bull {
        animation: neon-pulse-green 1.5s infinite;
    }

    @keyframes neon-pulse-green {
        0%

    {
        box-shadow: 0 0 5px #00ffcc;
    }

    50% {
        box-shadow: 0 0 20px #00ffcc;
    }

    100% {
        box-shadow: 0 0 5px #00ffcc;
    }

    }

    .intel-table {
        background-color: transparent !important;
        border-collapse: separate !important;
        border-spacing: 0 8px !important; /* Satırlar arası boşluk daraltıldı */
    }

        /* Tablo başlıkları (Thead) */
        .intel-table thead tr {
            background: transparent !important;
        }

        .intel-table thead th {
            border: none !important;
            color: var(--text-muted);!important;
            font-size: 0.65rem;
            text-transform: uppercase;
            letter-spacing: 2px;
            padding-bottom: 15px;
        }

    /* Satırların arka planını koyulaştır ve cam efekti ver */
    .intel-row {
        background: var(--surface-card);!important; /* Çok hafif beyazımsı şeffaflık */
        backdrop-filter: blur(10px); /* Arkadaki grafiği veya rengi hafifçe bulanıklaştırır */
        transition: all 0.3s ease;
        border: none !important;
    }

        .intel-row:hover {
            background: rgba(0, 210, 255, 0.08) !important; /* Üzerine gelince neon mavisi parıltı */
            transform: translateY(-2px);
            box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
        }

        .intel-row td {
            background: transparent !important; /* TD'lerin kendi beyazlığını sıfırla */
            border-top: 1px solid  var(--border-subtle);!important;
            border-bottom: 1px solid  var(--border-subtle);!important;
            padding: 16px 12px !important;
            color: var(--text-muted) !important;
        }

            /* Kenarları yuvarlat ve Cyber kenarlık ekle */
            .intel-row td:first-child {
                border-left: 1px solid rgba(0, 210, 255, 0.2) !important;
                border-radius: 12px 0 0 12px;
            }

            .intel-row td:last-child {
                border-right: 1px solid  var(--border-subtle);!important;
                border-radius: 0 12px 12px 0;
            }



    /* DASHBOARD SORTABLE GRID */
    .dashboard-grid { 
        display: flex; 
        flex-wrap: wrap; 
        margin: 0; 
        padding: 0;
    }
    .dashboard-item { 
        padding: 12px; 
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    /* Layout Shift Prevention */
    .dashboard-item[data-id="panel-pnl"]> .glass-card { min-height: 520px; }
    .dashboard-item[data-id="panel-execution"]> .glass-card { min-height: 200px; }
    .dashboard-item[data-id="panel-announcements"]> .glass-card,
    .dashboard-item[data-id="panel-decisions"]> .glass-card { min-height: 400px; }
    .dashboard-item[data-id="panel-orders"]> .glass-card { min-height: 350px; }

.pnl-stat-grid {
    align-items: stretch;
}

.pnl-stat-card {
    min-height: 92px;
    height: 100%;
    padding: 1rem !important;
    border-radius: 8px !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.35rem;
    overflow: hidden;
}

.pnl-stat-label {
    color: var(--text-muted);
    font-size: 0.74rem;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: 0;
    opacity: 1 !important;
    text-wrap: balance;
}

.pnl-stat-value {
    display: block;
    color: var(--text-strong);
    font-size: clamp(1.05rem, 1.4vw, 1.28rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (min-width: 1400px) and (max-width: 1599.98px) {
    .dashboard-item[data-id="panel-pnl"] .pnl-stat-grid > [class*="col-"] {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

@media (max-width: 575.98px) {
    .pnl-stat-card {
        min-height: 86px;
        padding: 0.85rem !important;
    }

    .pnl-stat-label {
        font-size: 0.68rem;
    }

    .pnl-stat-value {
        font-size: 1.05rem;
    }
}


    .dashboard-item:hover {
        /* No jump per user request */
    }
    .dashboard-item:hover> .glass-card {
        border-color: rgba(var(--neon-blue-rgb), 0.3);
        /* Subtle glow only, no scale */
    }

    .sortable-ghost { 
        opacity: 0.2; 
        filter: blur(5px);
        transform: scale(0.95); 
    }
    .sortable-drag { 
        cursor: grabbing !important; 
        z-index: 9999;
    }
    
    .drag-handle { 
        cursor: grab; 
        padding: 8px; 
        opacity: 0.2; 
        transition: 0.3s;
        color: var(--text-strong);
    }
    .dashboard-item:hover .drag-handle { opacity: 0.6; }
    .drag-handle:hover { 
        opacity: 1 !important; 
        color: var(--neon-blue);
        transform: scale(1.1);
    }
    
    /* Responsive Column Classes for Items */
    .w-33 { width: 33.333%; flex: 0 0 33.333%; }
    .w-50 { width: 50%; flex: 0 0 50%; }
    .w-66 { width: 66.666%; flex: 0 0 66.666%; }
    .w-100 { width: 100%; flex: 0 0 100%; }

    @media (max-width: 1400px) { 
        .w-33 { width: 40%; flex: 0 0 40%; }
        .w-66 { width: 60%; flex: 0 0 60%; }
    }
    @media (max-width: 1100px) { 
        .w-33, .w-66 { width: 50%; flex: 0 0 50%; } 
    }
    @media (max-width: 880px) { 
        .w-33, .w-50, .w-66, .w-100 { 
            width: 100% !important; 
            flex: 0 0 100% !important; 
            max-width: 100% !important; 
        }
        .dashboard-grid { margin: 0; }
        .dashboard-item { padding: 10px 0; }
    }

    /* Duraklatma: Üzerine gelince yazı dursun */
    .ticker-content:hover .ticker-track {
        animation-play-state: paused;
    }
    @media (max-width: 768px) {
        .ticker-label {
            padding: 0 8px;
            font-size: 0.6rem;
            letter-spacing: 0px;
        }

        .ticker-track {
            animation-duration: 10s; /* Mobilde daha hızlı akış */
        }
    }

    .ticker-item {
        padding: 0 20px;
        font-size: 0.75rem;
    }

    }
    .wallet-card-compact {
        background: var(--surface-card);!important;
        backdrop-filter: blur(15px) saturate(120%) !important;
        border: 1px solid var(--border-subtle);!important;
        border-radius: 14px !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 4px 20px 0 rgba(0, 0, 0, 0.25) !important;
        position: relative;
    }

    .wallet-card-compact:hover {
        border-color: rgba(0, 210, 255, 0.25) !important;
        box-shadow: 0 8px 30px rgba(0, 210, 255, 0.12) !important;
        transform: translateY(-3px);
    }

    /* Profit Card styling */
    .wallet-card-compact.card-profit {
        border-left: 3px solid #10b981 !important;
    }
    .wallet-card-compact.card-profit:hover {
        border-color: rgba(16, 185, 129, 0.3) !important;
        box-shadow: 0 8px 30px rgba(16, 185, 129, 0.12) !important;
    }

    /* Loss Card styling */
    .wallet-card-compact.card-loss {
        border-left: 3px solid #ef4444 !important;
    }
    .wallet-card-compact.card-loss:hover {
        border-color: rgba(239, 68, 68, 0.3) !important;
        box-shadow: 0 8px 30px rgba(239, 68, 68, 0.12) !important;
    }

    /* Shared Card styling with an elegant purple gradient edge */
    .wallet-card-compact.border-purple-glow {
        border-color: rgba(168, 85, 247, 0.3) !important;
        border-left: 3px solid #a855f7 !important;
        background: linear-gradient(165deg, rgba(168, 85, 247, 0.08) 0%, rgba(15, 23, 42, 0.65) 100%) !important;
    }
    .wallet-card-compact.border-purple-glow:hover {
        border-color: rgba(168, 85, 247, 0.5) !important;
        box-shadow: 0 8px 30px rgba(168, 85, 247, 0.15) !important;
    }

    /* Unset Connection styling */
    .wallet-card-compact.border-warning-glow {
        border: 1px dashed rgba(245, 158, 11, 0.4) !important;
        background: rgba(245, 158, 11, 0.03) !important;
    }
    .wallet-card-compact.border-warning-glow:hover {
        border-color: rgba(245, 158, 11, 0.6) !important;
        box-shadow: 0 8px 30px rgba(245, 158, 11, 0.08) !important;
    }

    .btn-icon-action {
        background: transparent;
        border: none;
        color: var(--neon-blue);
        cursor: pointer;
        transition: all 0.2s ease;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        opacity: 0.65;
        padding: 4px;
        border-radius: 6px;
    }

    .btn-icon-action:hover {
        color: var(--text-strong);
        background: var(--surface-card);
        opacity: 1;
        transform: scale(1.05);
    }

/* PREMIUM OVERRIDES FOR WALLET CARDS */
.wallet-card-compact {
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.9)) !important;
    backdrop-filter: blur(20px) saturate(150%) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 20px !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    position: relative;
    overflow: hidden;
}

.wallet-card-compact::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 100%;
    background: radial-gradient(circle at top right, rgba(0, 210, 255, 0.15), transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.wallet-card-compact > * {
    position: relative;
    z-index: 1;
}

.wallet-card-compact:hover {
    transform: translateY(-8px) scale(1.02) !important;
    box-shadow: 0 20px 40px -10px rgba(0, 210, 255, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(0, 210, 255, 0.3) !important;
}

.wallet-card-compact.card-profit {
    border-left: 4px solid #10b981 !important;
}
.wallet-card-compact.card-profit::before {
    background: radial-gradient(circle at top right, rgba(16, 185, 129, 0.15), transparent 60%);
}

.wallet-card-compact.card-loss {
    border-left: 4px solid #ef4444 !important;
}
.wallet-card-compact.card-loss::before {
    background: radial-gradient(circle at top right, rgba(239, 68, 68, 0.15), transparent 60%);
}

.val-nakit {
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 1.75rem !important;
    letter-spacing: -0.5px;
}

.total-balance {
    font-family: 'Inter', sans-serif !important;
    font-weight: 900 !important;
}

.borsa-card {
    padding: 1.5rem !important;
}

        opacity: 0.2; 
        transition: 0.3s;
        color: var(--text-strong);
    }
    .dashboard-item:hover .drag-handle { opacity: 0.6; }
    .drag-handle:hover { 
        opacity: 1 !important; 
        color: var(--neon-blue);
    }
    
    /* Responsive Column Classes for Items */
    .w-33 { width: 33.333%; flex: 0 0 33.333%; }
    .w-50 { width: 50%; flex: 0 0 50%; }
    .w-66 { width: 66.666%; flex: 0 0 66.666%; }
    .w-100 { width: 100%; flex: 0 0 100%; }

    @media (max-width: 1400px) { 
        .w-33 { width: 40%; flex: 0 0 40%; }
        .w-66 { width: 60%; flex: 0 0 60%; }
    }
    @media (max-width: 1100px) { 
        .w-33, .w-66 { width: 50%; flex: 0 0 50%; } 
    }
    @media (max-width: 880px) { 
        .w-33, .w-50, .w-66, .w-100 { 
            width: 100% !important; 
            flex: 0 0 100% !important; 
            max-width: 100% !important; 
        }
        .dashboard-grid { margin: 0; }
        .dashboard-item { padding: 10px 0; }
    }

    /* Duraklatma: Üzerine gelince yazı dursun */
    .ticker-content:hover .ticker-track {
        animation-play-state: paused;
    }
    @media (max-width: 768px) {
        .ticker-label {
            padding: 0 8px;
            font-size: 0.6rem;
            letter-spacing: 0px;
        }

        .ticker-track {
            animation-duration: 10s; /* Mobilde daha hızlı akış */
        }
    }

    .ticker-item {
        padding: 0 20px;
        font-size: 0.75rem;
    }

    }
    .wallet-card-compact {
        background: var(--surface-card);!important;
        backdrop-filter: blur(15px) saturate(120%) !important;
        border: 1px solid var(--border-subtle);!important;
        border-radius: 14px !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 4px 20px 0 rgba(0, 0, 0, 0.25) !important;
        position: relative;
    }

    .wallet-card-compact:hover {
        border-color: rgba(0, 210, 255, 0.25) !important;
        box-shadow: 0 8px 30px rgba(0, 210, 255, 0.12) !important;
        transform: translateY(-3px);
    }

    /* Profit Card styling */
    .wallet-card-compact.card-profit {
        border-left: 3px solid #10b981 !important;
    }
    .wallet-card-compact.card-profit:hover {
        border-color: rgba(16, 185, 129, 0.3) !important;
        box-shadow: 0 8px 30px rgba(16, 185, 129, 0.12) !important;
    }

    /* Loss Card styling */
    .wallet-card-compact.card-loss {
        border-left: 3px solid #ef4444 !important;
    }
    .wallet-card-compact.card-loss:hover {
        border-color: rgba(239, 68, 68, 0.3) !important;
        box-shadow: 0 8px 30px rgba(239, 68, 68, 0.12) !important;
    }

    /* Shared Card styling with an elegant purple gradient edge */
    .wallet-card-compact.border-purple-glow {
        border-color: rgba(168, 85, 247, 0.3) !important;
        border-left: 3px solid #a855f7 !important;
        background: linear-gradient(165deg, rgba(168, 85, 247, 0.08) 0%, rgba(15, 23, 42, 0.65) 100%) !important;
    }
    .wallet-card-compact.border-purple-glow:hover {
        border-color: rgba(168, 85, 247, 0.5) !important;
        box-shadow: 0 8px 30px rgba(168, 85, 247, 0.15) !important;
    }

    /* Unset Connection styling */
    .wallet-card-compact.border-warning-glow {
        border: 1px dashed rgba(245, 158, 11, 0.4) !important;
        background: rgba(245, 158, 11, 0.03) !important;
    }
    .wallet-card-compact.border-warning-glow:hover {
        border-color: rgba(245, 158, 11, 0.6) !important;
        box-shadow: 0 8px 30px rgba(245, 158, 11, 0.08) !important;
    }

    .btn-icon-action {
        background: transparent;
        border: none;
        color: var(--neon-blue);
        cursor: pointer;
        transition: all 0.2s ease;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        opacity: 0.65;
        padding: 4px;
        border-radius: 6px;
    }

    .btn-icon-action:hover {
        color: var(--text-strong);
        background: var(--surface-card);
        opacity: 1;
        transform: scale(1.05);
    }

/* PREMIUM OVERRIDES FOR WALLET CARDS */
.wallet-card-compact {
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.9)) !important;
    backdrop-filter: blur(20px) saturate(150%) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 20px !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    position: relative;
    overflow: hidden;
}

.wallet-card-compact::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 100%;
    background: radial-gradient(circle at top right, rgba(0, 210, 255, 0.15), transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.wallet-card-compact > * {
    position: relative;
    z-index: 1;
}

.wallet-card-compact:hover {
    transform: translateY(-8px) scale(1.02) !important;
    box-shadow: 0 20px 40px -10px rgba(0, 210, 255, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(0, 210, 255, 0.3) !important;
}

.wallet-card-compact.card-profit {
    border-left: 4px solid #10b981 !important;
}
.wallet-card-compact.card-profit::before {
    background: radial-gradient(circle at top right, rgba(16, 185, 129, 0.15), transparent 60%);
}

.wallet-card-compact.card-loss {
    border-left: 4px solid #ef4444 !important;
}
.wallet-card-compact.card-loss::before {
    background: radial-gradient(circle at top right, rgba(239, 68, 68, 0.15), transparent 60%);
}

.val-nakit {
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 1.75rem !important;
    letter-spacing: -0.5px;
}

.total-balance {
    font-family: 'Inter', sans-serif !important;
    font-weight: 900 !important;
}

.borsa-card {
    padding: 1.5rem !important;
}

/* Dashboard Grid Overrides */
.dashboard-grid {
    /* Removed gap because it breaks Bootstrap col-lg-6 widths */
}

.glass-card {
    background: linear-gradient(145deg, rgba(20, 30, 48, 0.8), rgba(36, 59, 85, 0.8)) !important;
    border-radius: 24px !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2) !important;
}

.glass-card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    border-color: rgba(255, 255, 255, 0.15);
}

/* ==========================================================================
   PREMIUM SKELETON LOADERS
   ========================================================================== */
.mergen-skeleton {
    background: linear-gradient(90deg, 
        rgba(148, 163, 184, 0.1) 25%, 
        rgba(148, 163, 184, 0.2) 50%, 
        rgba(148, 163, 184, 0.1) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite linear;
    border-radius: 4px;
    height: 1rem;
    width: 100%;
    display: inline-block;
}

[data-theme="light"] .mergen-skeleton, [data-bs-theme="light"] .mergen-skeleton {
    background: linear-gradient(90deg, 
        rgba(0, 0, 0, 0.05) 25%, 
        rgba(0, 0, 0, 0.1) 50%, 
        rgba(0, 0, 0, 0.05) 75%
    );
    background-size: 200% 100%;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.mergen-skeleton-text { height: 12px; margin-bottom: 6px; border-radius: 3px; }
.mergen-skeleton-title { height: 16px; margin-bottom: 12px; width: 60%; border-radius: 4px; }
.mergen-skeleton-avatar { width: 40px; height: 40px; border-radius: 50%; }

/* ==========================================================================
   GLOBAL EMPTY STATES
   ========================================================================== */
.mergen-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    text-align: center;
    width: 100%;
    opacity: 0;
    animation: fadeIn 0.4s ease forwards;
}

.mergen-empty-icon {
    font-size: 3.5rem;
    color: var(--text-muted);
    opacity: 0.3;
    margin-bottom: 1.2rem;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.1));
}

.mergen-empty-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-bright);
    margin-bottom: 0.5rem;
    font-family: 'Outfit', sans-serif;
}

.mergen-empty-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    max-width: 250px;
    margin-bottom: 1.5rem;
}

.mergen-empty-btn {
    background: rgba(0, 210, 255, 0.1);
    color: var(--neon-cyan);
    border: 1px solid rgba(0, 210, 255, 0.3);
    padding: 0.5rem 1.2rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.mergen-empty-btn:hover {
    background: rgba(0, 210, 255, 0.2);
    color: #fff;
    box-shadow: 0 0 15px rgba(0, 210, 255, 0.3);
}

[data-theme] .mergen-empty-icon, [data-bs-theme] .mergen-empty-icon {
    opacity: 0.75;
    color: var(--text-muted);
    filter: none;
}
[data-theme] .mergen-empty-title, [data-bs-theme] .mergen-empty-title {
    color: var(--text-strong);
}
[data-theme] .mergen-empty-desc, [data-bs-theme] .mergen-empty-desc {
    color: var(--text-muted);
}
[data-theme] .mergen-empty-btn, [data-bs-theme] .mergen-empty-btn {
    background: rgba(var(--theme-color-rgb), 0.08);
    color: var(--text-strong);
    border: 1px solid rgba(var(--theme-color-rgb), 0.25);
}
[data-theme] .mergen-empty-btn:hover, [data-bs-theme] .mergen-empty-btn:hover {
    background: rgba(var(--theme-color-rgb), 0.14);
    color: var(--text-strong);
    box-shadow: 0 0 10px rgba(var(--theme-color-rgb), 0.18);
}

/* ==========================================================================
   GLOBAL COMMAND PALETTE (CMD + K)
   ========================================================================== */
.cmd-palette-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 15vh;
}

.cmd-palette-container {
    width: 100%;
    max-width: 650px;
    background: var(--glass);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 210, 255, 0.1);
    display: flex;
    flex-direction: column;
}

[data-theme="light"] .cmd-palette-container, [data-bs-theme="light"] .cmd-palette-container {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 210, 255, 0.1);
}

.cmd-palette-header {
    display: flex;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.cmd-palette-header i {
    font-size: 1.2rem;
    margin-right: 1rem;
}

.cmd-palette-input {
    flex-grow: 1;
    background: transparent;
    border: none;
    color: var(--text-bright);
    font-size: 1.1rem;
    outline: none;
    font-family: 'Outfit', sans-serif;
}

.cmd-palette-input::placeholder {
    color: var(--text-muted);
}

.cmd-palette-badge {
    background: rgba(148, 163, 184, 0.1);
    border: 1px solid var(--border-color);
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.cmd-palette-results {
    max-height: 400px;
    overflow-y: auto;
    padding: 0.5rem;
}

/* Custom Scrollbar for results */
.cmd-palette-results::-webkit-scrollbar { width: 6px; }
.cmd-palette-results::-webkit-scrollbar-track { background: transparent; }
.cmd-palette-results::-webkit-scrollbar-thumb { background: rgba(148, 163, 184, 0.2); border-radius: 10px; }
.cmd-palette-results::-webkit-scrollbar-thumb:hover { background: rgba(148, 163, 184, 0.4); }

/* ==========================================================================
   FLOATING HELP WIDGET & COPY INTERACTION
   ========================================================================== */
.floating-help-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.help-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-blue));
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 210, 255, 0.4);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.help-btn:hover {
    transform: scale(1.1) rotate(15deg);
    box-shadow: 0 6px 20px rgba(0, 210, 255, 0.6);
}

.help-menu {
    position: absolute;
    bottom: 60px;
    right: 0;
    width: 250px;
    border-radius: 16px;
    padding: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transform-origin: bottom right;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.help-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.help-menu-header {
    padding: 0.8rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    color: var(--text-bright);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0.5rem;
}

.help-menu-item {
    display: flex;
    align-items: center;
    padding: 0.8rem;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    font-weight: 500;
}

.help-menu-item i {
    width: 24px;
    font-size: 1.1rem;
    margin-right: 10px;
}

.help-menu-item:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text-bright);
    padding-left: 1rem;
}

[data-theme="light"] .help-menu-item:hover, [data-bs-theme="light"] .help-menu-item:hover {
    background: rgba(0,0,0,0.05);
}

/* Micro-Interaction: Copyable Text */
.mergen-copyable {
    cursor: pointer;
    position: relative;
    display: inline-block;
    transition: color 0.2s ease;
    border-bottom: 1px dashed rgba(148, 163, 184, 0.4);
}

.mergen-copyable:hover {
    color: var(--neon-cyan) !important;
    border-bottom-color: var(--neon-cyan);
}

.mergen-copyable::after {
    content: '\f0c5';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 0.8em;
    margin-left: 6px;
    opacity: 0;
    transform: translateY(5px);
    display: inline-block;
    transition: all 0.2s ease;
}

.mergen-copyable:hover::after {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   GLOBAL CONTEXT MENU (RIGHT CLICK)
   ========================================================================== */
#mergen-context-menu {
    position: fixed;
    z-index: 10000;
    width: 200px;
    background: linear-gradient(145deg, rgba(20, 30, 48, 0.95), rgba(36, 59, 85, 0.95));
    backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 210, 255, 0.2);
    border-radius: 12px;
    padding: 0.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.1);
    opacity: 0;
    visibility: hidden;
    transform: scale(0.95);
    transform-origin: top left;
    transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#mergen-context-menu.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.ctx-menu-item {
    display: flex;
    align-items: center;
    padding: 0.6rem 0.8rem;
    color: var(--text-bright);
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.ctx-menu-item i {
    width: 20px;
    margin-right: 8px;
    opacity: 0.8;
}

.ctx-menu-item:hover {
    background: rgba(0, 210, 255, 0.15);
    color: var(--neon-cyan);
    padding-left: 1rem;
}

.ctx-menu-divider {
    height: 1px;
    background: rgba(255,255,255,0.1);
    margin: 0.4rem 0;
}

/* ==========================================================================
   REAL-TIME FLASHING SYSTEM (PHASE 8)
   ========================================================================== */
@keyframes flash-green {
    0% { background-color: transparent; color: inherit; }
    20% { background-color: rgba(16, 185, 129, 0.4); color: #10b981; }
    100% { background-color: transparent; color: inherit; }
}
@keyframes flash-red {
    0% { background-color: transparent; color: inherit; }
    20% { background-color: rgba(239, 68, 68, 0.4); color: #ef4444; }
    100% { background-color: transparent; color: inherit; }
}

.flash-up {
    animation: flash-green 1.5s ease-out !important;
}
.flash-down {
    animation: flash-red 1.5s ease-out !important;
}

.cmd-palette-item {
    display: flex;
    align-items: center;
    padding: 0.8rem 1rem;
    margin: 0.2rem 0;
    border-radius: 8px;
    color: var(--text-bright);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.cmd-palette-item i {
    width: 24px;
    font-size: 1.1rem;
    margin-right: 1rem;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.cmd-palette-item:hover, .cmd-palette-item.active {
    background: rgba(0, 210, 255, 0.1);
    border-color: rgba(0, 210, 255, 0.2);
}

.cmd-palette-item:hover i, .cmd-palette-item.active i {
    color: var(--neon-cyan);
}

.cmd-palette-empty {
    padding: 2rem;
    text-align: center;
    color: var(--text-muted);
    font-style: italic;
}

.cmd-palette-footer {
    padding: 0.8rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
}

[data-theme="light"] .cmd-palette-footer, [data-bs-theme="light"] .cmd-palette-footer {
    background: rgba(255,255,255,0.4);
}

.cmd-palette-key {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    margin: 0 0.2rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    box-shadow: 0 2px 0 rgba(0,0,0,0.2);
}
[data-theme="light"] .cmd-palette-key, [data-bs-theme="light"] .cmd-palette-key {
    box-shadow: 0 2px 0 rgba(0,0,0,0.05);
}


/* ====== BUTTER SMOOTH SCROLLING & SCROLLBARS ====== */
html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.5);
}

::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(148, 163, 184, 0.4);
}

/* ====== SWUP.JS TRANSITIONS ====== */
html.is-animating .transition-fade {
    opacity: 0;
    transform: translateY(10px);
}

.transition-fade {
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 1;
    transform: translateY(0);
}



/* ====== NATIVE PAGE TRANSITIONS ====== */
body {
    animation: nativeFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

body.fade-out {
    animation: nativeFadeOut 0.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes nativeFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes nativeFadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* ====== THEME-AWARE DASHBOARD OVERRIDES ====== */
[data-theme] .glass-card,
[data-bs-theme] .glass-card {
    background: var(--card-bg, var(--surface-card)) !important;
    border: 1px solid var(--border-subtle) !important;
    box-shadow: var(--component-shadow, 0 10px 28px rgba(0, 0, 0, 0.18));
    color: var(--text-body);
}

[data-theme] .glass-card:hover,
[data-bs-theme] .glass-card:hover {
    border-color: rgba(var(--theme-color-rgb), 0.3) !important;
    box-shadow: 0 0 25px rgba(var(--theme-color-rgb), 0.12);
}

[data-theme] .dashboard-header,
[data-bs-theme] .dashboard-header {
    color: var(--text-strong);
    font-weight: 700;
}

[data-theme] .theme-text-strong,
[data-bs-theme] .theme-text-strong {
    color: var(--text-strong) !important;
}

[data-theme] .theme-text-muted,
[data-bs-theme] .theme-text-muted {
    color: var(--text-muted) !important;
}

[data-theme] .sys-telemetry,
[data-bs-theme] .sys-telemetry {
    color: var(--text-muted);
}

[data-theme] .wallet-card-compact,
[data-bs-theme] .wallet-card-compact {
    background: var(--surface-card) !important;
    border-color: var(--border-subtle) !important;
    box-shadow: var(--component-shadow, 0 10px 28px rgba(0, 0, 0, 0.18)) !important;
    color: var(--text-body) !important;
}

[data-theme] .wallet-card-compact.card-profit,
[data-bs-theme] .wallet-card-compact.card-profit {
    border-left-color: #10b981 !important;
}

[data-theme] .wallet-card-compact.card-loss,
[data-bs-theme] .wallet-card-compact.card-loss {
    border-left-color: #ef4444 !important;
}

[data-theme] .wallet-card-compact.border-purple-glow,
[data-bs-theme] .wallet-card-compact.border-purple-glow {
    border-left-color: #7c3aed !important;
}

[data-theme] .wallet-card-compact::before,
[data-bs-theme] .wallet-card-compact::before {
    opacity: 0.35;
}

[data-theme] .wallet-card-compact .theme-text-muted,
[data-bs-theme] .wallet-card-compact .theme-text-muted {
    color: var(--text-muted) !important;
}

[data-theme] .wallet-card-compact .theme-text-strong,
[data-bs-theme] .wallet-card-compact .theme-text-strong {
    color: var(--text-strong) !important;
}

[data-theme] .wallet-card-compact .val-nakit,
[data-bs-theme] .wallet-card-compact .val-nakit {
    background: none !important;
    color: var(--text-strong) !important;
    -webkit-text-fill-color: var(--text-strong) !important;
    letter-spacing: 0 !important;
}

/* ====== MOBILE UI OPTIMIZATIONS ====== */
@media (max-width: 768px) {
    .glass-card {
        padding: 1rem !important; /* Reduce padding on mobile */
    }
    
    .dashboard-header {
        font-size: 0.85rem;
    }
    
    .table-responsive {
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
    }
    
    .table-responsive::-webkit-scrollbar {
        display: none; /* Hide scrollbar for touch swipe */
    }
}

.table-responsive .table th, 
.table-responsive .table td {
    white-space: nowrap; /* Prevent awkward wrapping on small screens */
}

.dashboard-item[data-id="panel-pnl"] .pnl-stat-card {
    min-height: 92px !important;
    padding: 16px !important;
    border-radius: 8px !important;
    justify-content: center !important;
    gap: 6px !important;
}

.dashboard-item[data-id="panel-pnl"] .pnl-stat-card::before {
    border-radius: 8px !important;
}

.dashboard-item[data-id="panel-pnl"] .pnl-stat-label {
    font-size: 12px !important;
    line-height: 1.15 !important;
    letter-spacing: 0 !important;
}

.dashboard-item[data-id="panel-pnl"] .pnl-stat-value {
    font-size: 20px !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
}
