:root{
    --platform-accent:#22c55e;
    --platform-accent-strong:#10b981;
    --platform-danger:#ef4444;
    --platform-panel:rgba(8,12,23,.92);
    --platform-border:rgba(255,255,255,.08);
    --platform-surface:rgba(15,23,42,.82);
    --platform-shadow:0 28px 60px rgba(2,6,23,.46);
}

html,body{overflow-x:hidden;}
img,svg,video,canvas{max-width:100%;height:auto;}

body{
    padding-bottom:max(110px,calc(92px + env(safe-area-inset-bottom,0px)));
}

.logo-icon,
.footer-logo-icon,
.loader-logo-icon{
    background:#ffffff url("/images/logo.jpg") center/82% no-repeat !important;
    color:transparent !important;
    font-size:0 !important;
    text-shadow:none !important;
    border:1px solid rgba(255,255,255,.12) !important;
    border-radius:50% !important;
    box-shadow:0 18px 34px rgba(2,6,23,.28),0 0 0 1px rgba(34,197,94,.12),0 0 32px rgba(34,197,94,.2) !important;
}

.loader-logo-icon{background-size:86% !important;}

.logo-icon::before,
.footer-logo-icon::before,
.loader-logo-icon::before{
    display:none !important;
}

.logo-text,
.footer-logo-text{
    background:linear-gradient(135deg,#f8fafc,#bbf7d0) !important;
    -webkit-background-clip:text !important;
    -webkit-text-fill-color:transparent !important;
    letter-spacing:.02em !important;
}

.bottom-nav{
    position:fixed !important;
    left:50% !important;
    right:auto !important;
    bottom:10px !important;
    transform:translateX(-50%) !important;
    width:min(calc(100% - clamp(12px,3vw,34px)),1280px) !important;
    height:92px !important;
    padding:0 14px calc(env(safe-area-inset-bottom,0px) + 10px) !important;
    background:
        linear-gradient(180deg,rgba(16,23,38,.96),rgba(2,6,18,.98)) !important;
    border:1px solid var(--platform-border) !important;
    border-radius:30px !important;
    box-shadow:var(--platform-shadow),inset 0 1px 0 rgba(255,255,255,.04) !important;
    overflow:visible !important;
    isolation:isolate;
}

.bottom-nav::before{
    content:"" !important;
    position:absolute !important;
    top:0 !important;
    left:28px !important;
    right:28px !important;
    height:1px !important;
    background:linear-gradient(90deg,transparent,rgba(110,231,183,.96),rgba(34,197,94,.24),transparent) !important;
    opacity:1 !important;
}

.bottom-nav::after{
    content:"";
    position:absolute;
    inset:auto 22px -1px;
    height:46px;
    border-radius:999px;
    background:radial-gradient(circle at center,rgba(34,197,94,.18),transparent 72%);
    z-index:-1;
    pointer-events:none;
}

.bottom-nav .nav-item{
    position:relative;
    z-index:2;
    color:#dce8f7 !important;
    transition:transform .28s ease,color .28s ease,opacity .28s ease !important;
}

.bottom-nav .nav-icon,
.bottom-nav .icon{
    width:50px !important;
    height:50px !important;
    border-radius:18px !important;
    background:linear-gradient(180deg,rgba(255,255,255,.09),rgba(255,255,255,.03)) !important;
    border:1px solid rgba(255,255,255,.06);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.04) !important;
    color:#d9e5f5 !important;
    transition:transform .28s ease,box-shadow .28s ease,background .28s ease,color .28s ease !important;
}

.bottom-nav .nav-label,
.bottom-nav .label{
    margin-top:5px !important;
    font-size:10px !important;
    letter-spacing:.08em !important;
    text-transform:uppercase;
    color:#94a3b8 !important;
}

.bottom-nav .nav-item:hover .nav-icon,
.bottom-nav .nav-item:hover .icon{
    transform:translateY(-4px) scale(1.04) !important;
    background:linear-gradient(180deg,rgba(34,197,94,.22),rgba(16,185,129,.08)) !important;
    color:#f8fafc !important;
    box-shadow:0 18px 28px rgba(16,185,129,.22),0 0 0 1px rgba(34,197,94,.18) !important;
}

.bottom-nav .nav-item.active .nav-icon,
.bottom-nav .nav-item.active .icon{
    transform:translateY(-5px) !important;
    background:linear-gradient(135deg,#10b981,#22c55e) !important;
    color:#ffffff !important;
    box-shadow:0 18px 32px rgba(16,185,129,.34),0 0 0 1px rgba(74,222,128,.28),inset 0 1px 0 rgba(255,255,255,.18) !important;
}

.bottom-nav .nav-item.active .nav-label,
.bottom-nav .nav-item.active .label{
    color:#d1fae5 !important;
}

.bottom-nav .nav-item.center{
    top:-20px !important;
}

.bottom-nav .nav-item.center .nav-icon,
.bottom-nav .nav-item.center .icon{
    width:68px !important;
    height:68px !important;
    border-radius:22px !important;
    background:
        radial-gradient(circle at 30% 25%,rgba(255,255,255,.28),transparent 34%),
        linear-gradient(135deg,#10b981,#22c55e) !important;
    box-shadow:0 22px 38px rgba(16,185,129,.34),0 0 0 1px rgba(110,231,183,.24),0 0 40px rgba(34,197,94,.24) !important;
    animation:platformTradePulse 2.8s ease-in-out infinite !important;
}

@keyframes platformTradePulse{
    0%,100%{box-shadow:0 22px 38px rgba(16,185,129,.34),0 0 0 1px rgba(110,231,183,.24),0 0 32px rgba(34,197,94,.18);}
    50%{box-shadow:0 24px 44px rgba(16,185,129,.42),0 0 0 1px rgba(110,231,183,.32),0 0 52px rgba(34,197,94,.3);}
}

.live-chat-widget{
    position:fixed !important;
    right:18px !important;
    bottom:122px !important;
    z-index:700 !important;
}

.chat-widget-btn{
    position:relative !important;
    width:66px !important;
    height:66px !important;
    border-radius:24px !important;
    border:1px solid rgba(110,231,183,.24);
    background:
        radial-gradient(circle at 30% 25%,rgba(255,255,255,.24),transparent 34%),
        linear-gradient(135deg,#10b981,#22c55e) !important;
    box-shadow:0 24px 42px rgba(16,185,129,.3),0 0 0 1px rgba(255,255,255,.04),inset 0 1px 0 rgba(255,255,255,.18) !important;
    overflow:visible;
    cursor:pointer !important;
    touch-action:manipulation;
    transition:transform .28s ease,box-shadow .28s ease,filter .28s ease !important;
}

.chat-widget-btn:hover{
    transform:translateY(-4px) scale(1.04) !important;
    box-shadow:0 28px 46px rgba(16,185,129,.36),0 0 0 1px rgba(255,255,255,.04),inset 0 1px 0 rgba(255,255,255,.18) !important;
    filter:saturate(1.06);
}

.chat-widget-btn::before{
    content:"";
    position:absolute;
    inset:-8px;
    border:1px solid rgba(110,231,183,.16);
    border-radius:30px;
    opacity:.7;
    animation:chatHalo 2.8s linear infinite;
}

.chat-widget-btn::after{
    content:"";
    position:absolute;
    inset:10px;
    border-radius:18px;
    background:linear-gradient(180deg,rgba(255,255,255,.18),transparent);
    opacity:.6;
    pointer-events:none;
}

.chat-widget-btn i{
    position:relative;
    z-index:2;
    font-size:30px !important;
}

.chat-widget-badge{
    position:absolute;
    top:-8px;
    right:-6px;
    z-index:3;
    min-width:26px;
    height:26px;
    padding:0 7px;
    border-radius:999px;
    background:linear-gradient(160deg,#f97316,#ef4444);
    border:2px solid #04101d;
    color:#fff;
    font-size:11px;
    font-weight:700;
    display:flex;
    align-items:center;
    justify-content:center;
    box-shadow:0 12px 22px rgba(239,68,68,.34);
    transition:opacity .24s ease,transform .24s ease;
}

.chat-widget-badge.is-hidden{
    opacity:0;
    transform:scale(.68);
    pointer-events:none;
}

@keyframes chatHalo{
    0%{transform:scale(.94);opacity:.68;}
    70%{transform:scale(1.1);opacity:.18;}
    100%{transform:scale(1.14);opacity:0;}
}

.chat-modal{
    background:rgba(2,6,23,.78) !important;
    backdrop-filter:blur(18px) saturate(140%) !important;
}

.chat-container{
    width:min(100%,430px) !important;
    max-width:430px !important;
    height:min(82vh,640px) !important;
    max-height:82vh !important;
    background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(2,6,23,.98)) !important;
    border:1px solid rgba(110,231,183,.16) !important;
    box-shadow:0 30px 64px rgba(2,6,23,.5),inset 0 1px 0 rgba(255,255,255,.04) !important;
}

.chat-header{
    background:linear-gradient(180deg,rgba(255,255,255,.04),transparent);
}

.chat-messages{
    background:
        radial-gradient(circle at top right,rgba(34,197,94,.08),transparent 32%),
        linear-gradient(180deg,rgba(255,255,255,.01),transparent);
}

.chat-message.support .message-bubble{
    background:rgba(255,255,255,.06) !important;
    border:1px solid rgba(255,255,255,.04);
}

.chat-message.user .message-bubble{
    background:linear-gradient(135deg,#10b981,#22c55e) !important;
    box-shadow:0 12px 20px rgba(16,185,129,.2);
}

.chat-input-wrapper{
    background:rgba(255,255,255,.04) !important;
    border:1px solid rgba(148,163,184,.12) !important;
}

.chat-send{
    background:linear-gradient(135deg,#10b981,#22c55e) !important;
}

.footer-live-ticker{
    display:flex;
    gap:20px;
    overflow:hidden;
    padding:12px 0;
    border-top:1px solid rgba(255,255,255,.04);
    margin-top:20px;
}

.ticker-content{
    display:flex;
    gap:30px;
    width:max-content;
    white-space:nowrap;
    animation:tickerScroll 20s linear infinite;
}

@keyframes tickerScroll{
    0%{transform:translateX(0);}
    100%{transform:translateX(-50%);}
}

.ticker-item{
    display:flex;
    align-items:center;
    gap:8px;
    color:#94a3b8;
    font-size:12px;
}

.ticker-item i{font-size:14px;}

.featured-img img,
.card-img img,
.modal-header img,
.related-img img{
    transform:translateZ(0);
    backface-visibility:hidden;
    image-rendering:auto;
    filter:contrast(1.05) saturate(1.06) brightness(1.02);
}

.loader-overlay{
    position:fixed;
    inset:0;
    background:#020617;
    z-index:9999;
    display:flex;
    align-items:center;
    justify-content:center;
    transition:opacity .5s ease,visibility .5s ease;
}

.loader-overlay.hidden{
    opacity:0;
    visibility:hidden;
    pointer-events:none;
}

.loader-content{text-align:center;}

.loader-logo{
    width:80px;
    height:80px;
    margin:0 auto;
    position:relative;
}

.loader-ring{
    position:absolute;
    inset:-10px;
    border:2px solid rgba(34,197,94,.28);
    border-radius:30px;
    animation:loaderSpin 2s linear infinite;
}

.loader-ring::before{
    content:"";
    position:absolute;
    width:15px;
    height:15px;
    background:#22c55e;
    border-radius:50%;
    top:-8px;
    left:50%;
    transform:translateX(-50%);
    box-shadow:0 0 20px #22c55e;
}

.loader-text{
    color:#fff;
    font-size:18px;
    font-weight:600;
    margin:30px 0 8px;
}

.loader-subtext{
    color:#64748b;
    font-size:13px;
}

.loader-progress{
    width:200px;
    height:3px;
    background:rgba(255,255,255,.1);
    border-radius:10px;
    margin:24px auto 0;
    overflow:hidden;
}

.loader-progress-bar{
    width:0;
    height:100%;
    background:linear-gradient(90deg,#10b981,#22c55e);
    border-radius:10px;
    animation:progressLoad 2s ease forwards;
}

@keyframes loaderSpin{
    from{transform:rotate(0deg);}
    to{transform:rotate(360deg);}
}

@keyframes progressLoad{
    0%{width:0;}
    50%{width:60%;}
    100%{width:100%;}
}

.loader-ticker{
    width:min(330px,86vw);
    margin:18px auto 0;
    overflow:hidden;
    mask-image:linear-gradient(90deg,transparent,#000 12%,#000 88%,transparent);
}

.loader-ticker-track{
    display:flex;
    gap:12px;
    width:max-content;
    animation:loaderTicker 14s linear infinite;
}

.loader-chip{
    display:flex;
    align-items:center;
    gap:8px;
    padding:9px 12px;
    border-radius:999px;
    background:rgba(15,23,42,.76);
    border:1px solid rgba(148,163,184,.16);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.04);
    color:#cbd5e1;
    font-size:12px;
    white-space:nowrap;
}

.loader-chip i{font-size:14px;color:var(--platform-accent);}

@keyframes loaderTicker{
    from{transform:translateX(0);}
    to{transform:translateX(-50%);}
}

.asset-card,
.crypto-card,
.insight-card,
.stat-card,
.assets-card,
.quick-actions-card,
.help-card,
.priority-card{
    position:relative;
    overflow:hidden;
}

.asset-card::before,
.crypto-card::before,
.insight-card::before,
.stat-card::before,
.assets-card::before,
.quick-actions-card::before,
.help-card::before,
.priority-card::before{
    content:"";
    position:absolute;
    inset:0;
    background:linear-gradient(125deg,transparent 12%,rgba(255,255,255,.08) 50%,transparent 88%);
    transform:translateX(-130%);
    transition:transform .7s ease;
    pointer-events:none;
}

.asset-card:hover::before,
.crypto-card:hover::before,
.insight-card:hover::before,
.stat-card:hover::before,
.assets-card:hover::before,
.quick-actions-card:hover::before,
.help-card:hover::before,
.priority-card:hover::before{
    transform:translateX(130%);
}

.market-page .asset-card{
    min-height:176px;
    border-color:rgba(148,163,184,.14) !important;
    box-shadow:0 18px 34px rgba(2,6,23,.3),inset 0 1px 0 rgba(255,255,255,.03) !important;
}

.market-page .asset-card:hover{
    transform:translateY(-7px) scale(1.015) !important;
}

/* Live Chat Widget - Fixed Bottom Right */
.live-chat-widget{position:fixed;bottom:100px;right:20px;z-index:500;}
.chat-widget-btn{width:60px;height:60px;background:linear-gradient(135deg,#10b981,#22c55e);border-radius:30px;display:flex;align-items:center;justify-content:center;cursor:pointer;box-shadow:0 8px 30px rgba(16,185,129,.5);transition:.3s;animation:widgetPulse 2s infinite;}
@keyframes widgetPulse{0%,100%{transform:scale(1);box-shadow:0 8px 30px rgba(16,185,129,.5);}50%{transform:scale(1.05);box-shadow:0 12px 40px rgba(16,185,129,.7);}}
.chat-widget-btn i{font-size:28px;color:#fff;}
.chat-widget-btn:hover{transform:scale(1.1);}

/* Chat Modal */
.chat-modal{position:fixed;inset:0;background:rgba(2,6,23,.95);backdrop-filter:blur(15px);z-index:1000;display:none;align-items:center;justify-content:center;padding:16px;}
.chat-modal.show{display:flex;}
.chat-container{width:100%;max-width:450px;height:600px;max-height:80vh;background:linear-gradient(160deg,#0f172a,#020617);border:1px solid rgba(34,197,94,.2);border-radius:24px;display:flex;flex-direction:column;overflow:hidden;animation:modalSlideIn .3s ease;}
@keyframes modalSlideIn{from{opacity:0;transform:translateY(20px) scale(.95);}to{opacity:1;transform:translateY(0) scale(1);}}
.chat-header{padding:16px 20px;border-bottom:1px solid rgba(255,255,255,.06);display:flex;align-items:center;justify-content:space-between;}
.chat-header h3{color:#fff;font-size:16px;display:flex;align-items:center;gap:8px;}
.chat-close{width:36px;height:36px;border-radius:10px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.1);color:#94a3b8;cursor:pointer;display:flex;align-items:center;justify-content:center;}
.chat-messages{flex:1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:12px;}
.chat-message{display:flex;gap:10px;max-width:85%;}
.chat-message.support{align-self:flex-start;}
.chat-message.user{align-self:flex-end;flex-direction:row-reverse;}
.message-avatar{width:32px;height:32px;border-radius:10px;background:rgba(34,197,94,.1);display:flex;align-items:center;justify-content:center;flex-shrink:0;}
.message-avatar i{color:#22c55e;font-size:16px;}
.message-bubble{padding:10px 14px;border-radius:16px;font-size:13px;line-height:1.5;}
.chat-message.support .message-bubble{background:rgba(255,255,255,.05);color:#e2e8f0;border-bottom-left-radius:4px;}
.chat-message.user .message-bubble{background:#22c55e;color:#fff;border-bottom-right-radius:4px;}
.message-time{font-size:10px;color:#64748b;margin-top:4px;}
.chat-footer{padding:16px;border-top:1px solid rgba(255,255,255,.06);}
.chat-input-wrapper{display:flex;align-items:center;gap:8px;background:rgba(255,255,255,.03);border:1px solid rgba(148,163,184,.15);border-radius:16px;padding:4px;}
.chat-input{flex:1;background:none;border:none;padding:10px 12px;color:#fff;font-size:14px;outline:none;}
.chat-input::placeholder{color:rgba(148,163,184,.5);}
.chat-attach{width:40px;height:40px;border-radius:12px;background:rgba(255,255,255,.05);border:none;color:#94a3b8;cursor:pointer;display:flex;align-items:center;justify-content:center;}
.chat-send{width:40px;height:40px;border-radius:12px;background:#22c55e;border:none;color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;}

.market-page .card-price,
.market-page .card-change-value{
    font-variant-numeric:tabular-nums;
}

.market-page .scroll-x{
    padding-bottom:14px !important;
}

.green,
.text-emerald-400,
.text-green-400{color:#22c55e !important;}

.red,
.text-red-400{color:#f87171 !important;}

.yellow{color:#fbbf24 !important;}

.text-amber-300{color:#fcd34d !important;}
.text-amber-400{color:#fbbf24 !important;}
.text-blue-400{color:#60a5fa !important;}
.text-sky-400{color:#38bdf8 !important;}
.text-purple-400{color:#c084fc !important;}
.text-indigo-400{color:#818cf8 !important;}
.text-gray-300{color:#d1d5db !important;}
.text-orange-400{color:#fb923c !important;}
.text-slate-400{color:#94a3b8 !important;}
.text-white{color:#fff !important;}
.text-yellow-400{color:#facc15 !important;}
.text-yellow-500{color:#eab308 !important;}

.flex{display:flex !important;}
.items-center{align-items:center !important;}
.gap-2{gap:.5rem !important;}
.font-bold{font-weight:700 !important;}
.text-xs{font-size:.75rem !important;}
.text-sm{font-size:.875rem !important;}
.text-xl{font-size:1.25rem !important;}
.w-7{width:1.75rem !important;}
.h-7{height:1.75rem !important;}
.rounded-full{border-radius:9999px !important;}
.ml-auto{margin-left:auto !important;}
.mr-1{margin-right:.25rem !important;}
.mr-2{margin-right:.5rem !important;}

@media (max-width:640px){
    .bottom-nav{
        width:calc(100% - 14px) !important;
        height:88px !important;
        padding-left:10px !important;
        padding-right:10px !important;
        border-radius:26px !important;
    }

    .bottom-nav .nav-item.center{top:-16px !important;}

    .bottom-nav .nav-icon,
    .bottom-nav .icon{
        width:46px !important;
        height:46px !important;
        border-radius:16px !important;
        font-size:20px !important;
    }

    .bottom-nav .nav-item.center .nav-icon,
    .bottom-nav .nav-item.center .icon{
        width:62px !important;
        height:62px !important;
        border-radius:20px !important;
        font-size:24px !important;
    }

    .live-chat-widget{
        right:14px !important;
        bottom:118px !important;
    }

    .chat-widget-btn{
        width:60px !important;
        height:60px !important;
        border-radius:22px !important;
    }

    .chat-widget-btn i{font-size:28px !important;}

    .hero-buttons{flex-direction:column;}
    .hero-buttons .btn{max-width:none !important;}

    .section-header,
    .chart-container,
    .insights-container,
    .crypto-container,
    .search-container,
    .hero-section,
    .footer{
        padding-left:14px !important;
        padding-right:14px !important;
    }

    .scroll-x{
        padding-left:14px !important;
        padding-right:14px !important;
    }
}

@media (max-width:480px){
    .quick-buttons,
    .help-grid{
        grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    }

    .asset-breakdown{
        flex-wrap:wrap !important;
        row-gap:10px;
    }

    .loader-logo{
        width:74px;
        height:74px;
    }
}
