/* Splash Screen */
.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0f172a;
    animation: fadeOut 3s ease-out forwards;
    pointer-events: none;
}

.splash-banner {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

@keyframes fadeOut {
    0% { opacity: 1; }
    70% { opacity: 1; }
    100% { opacity: 0; visibility: hidden; }
}

/* Position Type Toggle */
.position-type-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.position-btn {
    padding: 16px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.position-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.position-btn:hover::before {
    width: 300px;
    height: 300px;
}

.long-btn {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(34, 197, 94, 0.1));
    color: rgba(34, 197, 94, 0.7);
    border: 2px solid rgba(34, 197, 94, 0.3);
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.1);
}

.long-btn.active {
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: #fff;
    border: 2px solid #22c55e;
    box-shadow: 0 8px 30px rgba(34, 197, 94, 0.5), 0 0 40px rgba(34, 197, 94, 0.2);
}

.short-btn {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(239, 68, 68, 0.1));
    color: rgba(239, 68, 68, 0.7);
    border: 2px solid rgba(239, 68, 68, 0.3);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.1);
}

.short-btn.active {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    border: 2px solid #ef4444;
    box-shadow: 0 8px 30px rgba(239, 68, 68, 0.5), 0 0 40px rgba(239, 68, 68, 0.2);
}

/* Leverage Section */
.leverage-section {
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.leverage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.leverage-value {
    font-size: 14px;
    font-weight: 700;
    color: #3b82f6;
}

.leverage-slider {
    width: 100%;
    height: 6px;
    background: rgba(30, 41, 59, 0.8);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.leverage-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    cursor: pointer;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
}

.leverage-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    cursor: pointer;
    border: none;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
}

.leverage-marks {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: rgba(148, 163, 184, 0.5);
    margin-top: 6px;
}

/* Position Info */
.position-info {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 18px;
    position: relative;
    z-index: 1;
}

/* Positions Panel */
.positions-panel {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 12px;
    overflow: hidden;
    margin-top: 16px;
    position: relative;
    z-index: 1;
}

.positions-header {
    width: 100%;
    padding: 14px 16px;
    background: transparent;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s;
}

.positions-header:hover {
    background: rgba(30, 41, 59, 0.4);
}

.positions-title {
    font-size: 14px;
    font-weight: 700;
    color: #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.chevron-icon {
    stroke: #94a3b8;
    transition: transform 0.3s;
}

.positions-header.active .chevron-icon {
    transform: rotate(180deg);
}

.positions-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.positions-content.open {
    max-height: 500px;
    padding: 16px;
    padding-top: 0;
}

.positions-empty {
    text-align: center;
    padding: 30px;
    color: rgba(148, 163, 184, 0.5);
    font-size: 13px;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(59, 130, 246, 0.2);
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.settings-row {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}

.settings-btn {
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
    padding: 8px 14px;
    color: rgba(226, 232, 240, 0.7);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.settings-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.4);
    color: #3b82f6;
}

.settings-btn svg {
    stroke: currentColor;
}

.settings-content {
    padding: 24px 28px;
}

.settings-subtitle {
    font-size: 14px;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.slippage-presets {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

.slippage-preset {
    padding: 12px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(30, 41, 59, 0.6));
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
    color: rgba(226, 232, 240, 0.7);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
}

.slippage-preset:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.1));
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateY(-2px);
}

.slippage-preset.active {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: #3b82f6;
    color: #fff;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

.custom-slippage {
    margin-bottom: 20px;
}

.custom-slippage label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: rgba(226, 232, 240, 0.6);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.custom-slippage input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
    color: #e2e8f0;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.custom-slippage input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

.settings-info {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 8px;
}

.settings-info svg {
    flex-shrink: 0;
    margin-top: 2px;
    stroke: rgba(59, 130, 246, 0.6);
}

.settings-info span {
    font-size: 12px;
    color: rgba(226, 232, 240, 0.6);
    line-height: 1.5;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #0f172a;
    color: #e2e8f0;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* Subtle gradient overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 20%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(96, 165, 250, 0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* Animated grid */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(59, 130, 246, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59, 130, 246, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.5;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 48px;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(59, 130, 246, 0.15);
    position: relative;
    z-index: 10;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 40px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #fff;
}

.logo-img {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #fff;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
}

.nav-links-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 48px;
    align-items: center;
}

.nav-links-center a {
    color: rgba(226, 232, 240, 0.6);
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
    position: relative;
    padding: 8px 0;
}

.nav-links-center a.active {
    color: #3b82f6;
}

.nav-links-center a:hover {
    color: #3b82f6;
}

.nav-links-center a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    transition: width 0.3s;
}

.nav-links-center a.active::after {
    width: 100%;
}

.nav-links-center a:hover::after {
    width: 100%;
}

.social-links {
    display: flex;
    gap: 10px;
}

.social-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.social-btn svg {
    fill: rgba(226, 232, 240, 0.6);
    transition: fill 0.3s;
}

.social-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
    transform: translateY(-2px);
}

.social-btn:hover svg {
    fill: #3b82f6;
}

.wallet-btn {
    padding: 11px 26px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border: 2px solid rgba(59, 130, 246, 0.5);
    border-radius: 12px;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wallet-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(59, 130, 246, 0.5);
    border-color: #60a5fa;
}

.wallet-btn.connected {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(37, 99, 235, 0.3));
    border: 2px solid #3b82f6;
    color: #60a5fa;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.2);
}

.container {
    display: grid;
    grid-template-columns: 280px 1fr 400px;
    gap: 20px;
    padding: 24px 48px;
    height: calc(100vh - 100px);
    position: relative;
    z-index: 1;
}

/* Left Sidebar */
.left-sidebar {
    background: rgba(15, 23, 42, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.15);
    padding: 20px;
    overflow-y: auto;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.left-sidebar::-webkit-scrollbar {
    width: 6px;
}

.left-sidebar::-webkit-scrollbar-track {
    background: rgba(30, 41, 59, 0.4);
    border-radius: 3px;
}

.left-sidebar::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.3);
    border-radius: 3px;
}

.left-sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.5);
}

.sidebar-header {
    border-bottom: 1px solid rgba(59, 130, 246, 0.15);
    padding-bottom: 12px;
}

.sidebar-title {
    font-size: 15px;
    font-weight: 700;
    color: #e2e8f0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.category-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.category-btn {
    padding: 10px 14px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(30, 41, 59, 0.6));
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
    color: rgba(226, 232, 240, 0.6);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.category-btn:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.1));
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.category-btn.active {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: #3b82f6;
    color: #fff;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
}

.top-pairs-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pair-item {
    padding: 12px;
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pair-item:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateX(4px);
}

.pair-token-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.pair-content {
    flex: 1;
    min-width: 0;
}

.pair-symbols {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.pair-symbol {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
}

.pair-separator {
    color: #3b82f6;
    font-weight: 600;
    font-size: 12px;
}

.pair-stats {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.pair-volume {
    font-size: 11px;
    color: rgba(226, 232, 240, 0.5);
    font-weight: 500;
}

.pair-change {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
}

.pair-change.positive {
    color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
}

.pair-change.negative {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.chart-section {
    background: rgba(15, 23, 42, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.15);
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
}

#tradingview_chart {
    width: 100%;
    flex: 1;
    min-height: 400px;
}

/* Positions Table */
.positions-table-container {
    background: rgba(15, 23, 42, 0.95);
    border-top: 1px solid rgba(59, 130, 246, 0.2);
    padding: 16px;
}

.positions-table-header {
    margin-bottom: 12px;
}

.positions-table-header h3 {
    font-size: 14px;
    font-weight: 700;
    color: #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.positions-table {
    width: 100%;
    border-collapse: collapse;
}

.positions-table thead th {
    text-align: left;
    padding: 12px 8px;
    font-size: 11px;
    font-weight: 600;
    color: rgba(148, 163, 184, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(59, 130, 246, 0.15);
}

.positions-table tbody td {
    padding: 12px 8px;
    font-size: 13px;
    color: #e2e8f0;
    border-bottom: 1px solid rgba(30, 41, 59, 0.5);
}

.positions-table tbody tr:hover {
    background: rgba(59, 130, 246, 0.05);
}

.empty-positions {
    text-align: center !important;
    color: rgba(148, 163, 184, 0.5) !important;
    padding: 40px !important;
}

.trading-panel {
    background: rgba(15, 23, 42, 0.9);
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
}

/* Hide scrollbar for trading panel */
.trading-panel::-webkit-scrollbar {
    display: none;
}

.trading-panel {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Hide scrollbar for left sidebar */
.left-sidebar::-webkit-scrollbar {
    display: none;
}

.left-sidebar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.trading-panel::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.08) 0%, transparent 70%);
    animation: rotate 15s linear infinite;
    pointer-events: none;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.panel-decoration {
    position: relative;
    height: 4px;
    margin-bottom: 24px;
    z-index: 1;
    overflow: hidden;
    border-radius: 2px;
}

.decoration-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(59, 130, 246, 0.3) 25%, 
        rgba(96, 165, 250, 0.5) 50%, 
        rgba(59, 130, 246, 0.3) 75%, 
        transparent 100%
    );
    animation: shimmer 3s infinite;
}

.decoration-glow {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 24px;
    background: radial-gradient(ellipse, rgba(59, 130, 246, 0.4) 0%, transparent 70%);
    filter: blur(8px);
    animation: pulse 2s infinite;
}

@keyframes shimmer {
    0%, 100% {
        transform: translateX(-100%);
    }
    50% {
        transform: translateX(100%);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.input-label {
    font-size: 12px;
    color: rgba(226, 232, 240, 0.5);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.token-input {
    display: flex;
    align-items: center;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 12px;
    padding: 16px;
    gap: 12px;
    transition: all 0.3s;
}

.token-input:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

.token-select {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #e2e8f0;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
    white-space: nowrap;
}

.token-select:hover {
    background: rgba(59, 130, 246, 0.2);
    transform: translateY(-1px);
}

.token-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: block !important;
}

.amount-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #e2e8f0;
    font-size: 18px;
    outline: none;
    text-align: right;
    font-weight: 600;
    width: 100%;
    min-width: 0;
}

.balance {
    font-size: 11px;
    color: rgba(59, 130, 246, 0.6);
    text-align: right;
    margin-top: 4px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px;
    background: rgba(30, 41, 59, 0.6);
    border-radius: 8px;
    font-size: 13px;
    border: 1px solid rgba(59, 130, 246, 0.15);
    position: relative;
    z-index: 1;
}

.info-label {
    color: rgba(226, 232, 240, 0.5);
}

.info-value {
    color: #3b82f6;
    font-weight: 700;
}

.swap-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border: none;
    border-radius: 14px;
    color: #fff;
    font-size: 17px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: auto;
    box-shadow: 0 8px 30px rgba(59, 130, 246, 0.4), 0 0 40px rgba(59, 130, 246, 0.2);
    position: relative;
    z-index: 1;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    overflow: hidden;
}

.swap-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.swap-btn:hover:not(:disabled)::before {
    width: 400px;
    height: 400px;
}

.swap-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(59, 130, 246, 0.6), 0 0 60px rgba(59, 130, 246, 0.3);
}

.swap-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: linear-gradient(135deg, rgba(71, 85, 105, 0.6), rgba(51, 65, 85, 0.6));
    box-shadow: none;
}

.portfolio-section {
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 12px;
    padding: 16px;
    position: relative;
    z-index: 1;
}

.portfolio-title {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portfolio-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.portfolio-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    transition: all 0.3s;
}

.portfolio-item:hover {
    background: rgba(59, 130, 246, 0.05);
    border-color: rgba(59, 130, 246, 0.2);
}

.portfolio-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(226, 232, 240, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portfolio-value {
    font-size: 14px;
    font-weight: 700;
    color: #3b82f6;
}

.portfolio-empty {
    text-align: center;
    padding: 20px;
    color: rgba(226, 232, 240, 0.4);
    font-size: 13px;
}

.portfolio-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px;
}

.portfolio-loading span {
    color: rgba(226, 232, 240, 0.6);
    font-size: 13px;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.98));
    border-radius: 20px;
    border: 2px solid rgba(59, 130, 246, 0.3);
    width: 90%;
    max-width: 440px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 100px rgba(59, 130, 246, 0.2);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 28px;
    border-bottom: 2px solid rgba(59, 130, 246, 0.2);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), transparent);
}

.modal-header h3 {
    font-size: 19px;
    font-weight: 800;
    color: #e2e8f0;
    letter-spacing: 0.5px;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(226, 232, 240, 0.5);
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    transition: all 0.3s;
}

.modal-close:hover {
    color: #3b82f6;
    transform: rotate(90deg);
}

.token-search {
    margin: 20px 28px;
    padding: 16px 20px;
    background: rgba(30, 41, 59, 0.9);
    border: 2px solid rgba(59, 130, 246, 0.3);
    border-radius: 12px;
    color: #e2e8f0;
    font-size: 15px;
    outline: none;
    transition: all 0.3s;
    font-weight: 500;
}

.token-search::placeholder {
    color: rgba(148, 163, 184, 0.6);
}

.token-search:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3), 0 0 40px rgba(59, 130, 246, 0.1);
    background: rgba(30, 41, 59, 1);
}

.token-list {
    overflow-y: auto;
    padding: 0 28px 28px;
    max-height: 400px;
}

.token-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    cursor: pointer;
    border-radius: 12px;
    transition: all 0.3s;
    border: 2px solid transparent;
    background: rgba(30, 41, 59, 0.3);
    margin-bottom: 8px;
}

.token-item:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.1));
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateX(6px);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.2);
}

.token-item img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.token-info {
    flex: 1;
}

.token-name {
    font-size: 14px;
    font-weight: 700;
    color: #e2e8f0;
}

.token-symbol {
    font-size: 12px;
    color: rgba(226, 232, 240, 0.5);
}

.token-balance {
    text-align: right;
    font-size: 14px;
    font-weight: 700;
    color: #3b82f6;
}

.loading {
    text-align: center;
    padding: 40px;
    color: rgba(226, 232, 240, 0.5);
    font-size: 13px;
}

/* Toast Notifications */
#toastContainer {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 12px;
    padding: 16px 20px;
    min-width: 300px;
    max-width: 400px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    animation: slideIn 0.3s ease-out;
    display: flex;
    align-items: center;
    gap: 12px;
}

.toast.success {
    border-color: rgba(34, 197, 94, 0.4);
}

.toast.error {
    border-color: rgba(239, 68, 68, 0.4);
}

.toast.info {
    border-color: rgba(59, 130, 246, 0.4);
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast.success .toast-icon {
    color: #22c55e;
}

.toast.error .toast-icon {
    color: #ef4444;
}

.toast.info .toast-icon {
    color: #3b82f6;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-size: 14px;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 4px;
}

.toast-message {
    font-size: 13px;
    color: rgba(226, 232, 240, 0.7);
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: rgba(226, 232, 240, 0.5);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    transition: color 0.3s;
}

.toast-close:hover {
    color: #e2e8f0;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

.toast.removing {
    animation: slideOut 0.3s ease-in forwards;
}

@media (max-width: 1024px) {
    .container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .left-sidebar {
        display: none;
    }
    
    .chart-section {
        min-height: 400px;
    }
}