* { margin: 0; padding: 0; box-sizing: border-box; }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
            background: #1a1a2e;
            min-height: 100vh;
            color: #e0e0e0;
            line-height: 1.5;
        }

        header {
            background: linear-gradient(135deg, #16213e 0%, #0f3460 100%);
            padding: 0;
            position: sticky;
            top: 0;
            z-index: 100;
            border-bottom: 1px solid rgba(255,255,255,0.08);
        }

        .header-content {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 10px 16px;
        }

        .app-name {
            font-size: 17px;
            font-weight: 600;
            color: white;
        }

        .header-nav {
            display: flex;
            gap: 16px;
        }

        .header-nav .nav-link {
            color: rgba(255,255,255,0.75);
            text-decoration: none;
            font-size: 14px;
            padding: 4px 8px;
            border-radius: 6px;
            transition: all 0.2s;
        }

        .header-nav .nav-link:hover,
        .header-nav .nav-link.active {
            color: white;
            background: rgba(255,255,255,0.15);
        }

        .refresh-info {
            text-align: center;
            font-size: 11px;
            color: rgba(255,255,255,0.45);
            padding: 0 16px 8px;
        }

        .main-content {
            padding: 16px;
            max-width: 960px;
            margin: 0 auto;
        }

        .card {
            background: rgba(255,255,255,0.05);
            border-radius: 12px;
            padding: 16px;
            margin-bottom: 16px;
            border: 1px solid rgba(255,255,255,0.06);
        }

        .card-title {
            font-size: 14px;
            color: rgba(255,255,255,0.5);
            margin-bottom: 12px;
            font-weight: 500;
        }

        .assets-grid {
            display: grid;
            grid-template-columns: repeat(5, 1fr);
            gap: 12px;
        }

        .asset-card {
            background: rgba(255,255,255,0.04);
            border-radius: 12px;
            padding: 16px 8px;
            text-align: center;
            cursor: pointer;
            transition: all 0.25s ease;
            border: 1px solid rgba(255,255,255,0.06);
        }

        .asset-card:hover {
            background: rgba(255,255,255,0.08);
            transform: translateY(-2px);
            border-color: rgba(255,255,255,0.12);
        }

        .asset-card:active {
            transform: translateY(0);
        }

        .asset-name {
            font-size: 13px;
            font-weight: 600;
            color: rgba(255,255,255,0.8);
            margin-bottom: 8px;
        }

        .asset-gauge-canvas {
            display: block;
            margin: 0 auto;
        }

        .asset-value {
            font-size: 22px;
            font-weight: 700;
            margin-top: 4px;
        }

        .asset-level {
            font-size: 11px;
            margin-top: 2px;
            font-weight: 500;
        }

        .chart-section {
            margin-top: 4px;
        }

        .chart-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;
        }

        .chart-tabs {
            display: flex;
            gap: 6px;
        }

        .chart-tab {
            padding: 4px 12px;
            border-radius: 14px;
            background: rgba(255,255,255,0.06);
            color: rgba(255,255,255,0.5);
            font-size: 12px;
            border: none;
            cursor: pointer;
            transition: all 0.2s;
        }

        .chart-tab.active {
            background: rgba(255,255,255,0.15);
            color: #fff;
        }

        .chart-canvas-wrapper {
            position: relative;
            width: 100%;
            height: 220px;
        }

        .chart-canvas-wrapper canvas {
            width: 100%;
            height: 220px;
        }

        .signals-list, .alerts-list {
            list-style: none;
        }

        .signals-list li, .alerts-list li {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 10px 0;
            border-bottom: 1px solid rgba(255,255,255,0.04);
            font-size: 13px;
        }

        .signals-list li:last-child, .alerts-list li:last-child {
            border-bottom: none;
        }

        .signal-asset {
            color: rgba(255,255,255,0.7);
            min-width: 60px;
        }

        .signal-text {
            flex: 1;
            margin: 0 12px;
            color: rgba(255,255,255,0.9);
        }

        .signal-time {
            color: rgba(255,255,255,0.35);
            font-size: 11px;
            min-width: 50px;
            text-align: right;
        }

        .alert-item {
            display: flex;
            gap: 10px;
            align-items: flex-start;
        }

        .alert-icon {
            font-size: 16px;
            flex-shrink: 0;
            margin-top: 1px;
        }

        .alert-content {
            flex: 1;
        }

        .alert-title {
            color: rgba(255,255,255,0.85);
            font-size: 13px;
        }

        .alert-desc {
            color: rgba(255,255,255,0.45);
            font-size: 11px;
            margin-top: 2px;
        }

        .badge {
            display: inline-block;
            padding: 2px 8px;
            border-radius: 10px;
            font-size: 11px;
            font-weight: 500;
        }

        .badge-extreme-fear {
            background: rgba(76, 175, 80, 0.2);
            color: #4CAF50;
        }

        .badge-fear {
            background: rgba(139, 195, 74, 0.2);
            color: #8BC34A;
        }

        .badge-neutral {
            background: rgba(255, 193, 7, 0.2);
            color: #FFC107;
        }

        .badge-greed {
            background: rgba(255, 152, 0, 0.2);
            color: #FF9800;
        }

        .badge-extreme-greed {
            background: rgba(244, 67, 54, 0.2);
            color: #F44336;
        }

        .bottom-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 12px;
        }

        .loading {
            text-align: center;
            padding: 40px;
            color: rgba(255,255,255,0.35);
        }

        .loading-spinner {
            display: inline-block;
            width: 24px;
            height: 24px;
            border: 2px solid rgba(255,255,255,0.1);
            border-top-color: rgba(255,255,255,0.5);
            border-radius: 50%;
            animation: spin 0.8s linear infinite;
            margin-bottom: 8px;
        }

        @keyframes spin {
            to { transform: rotate(360deg); }
        }

        .error-msg {
            text-align: center;
            padding: 20px;
            color: #F44336;
            background: rgba(244, 67, 54, 0.1);
            border-radius: 8px;
            margin-bottom: 16px;
            font-size: 14px;
        }

        .empty-state {
            text-align: center;
            padding: 24px;
            color: rgba(255,255,255,0.3);
            font-size: 13px;
        }

        #detailView {
            display: none;
        }

        .detail-back {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            color: rgba(255,255,255,0.6);
            font-size: 14px;
            cursor: pointer;
            padding: 8px 0;
            margin-bottom: 12px;
            transition: color 0.2s;
            background: none;
            border: none;
        }

        .detail-back:hover {
            color: #fff;
        }

        .detail-header {
            text-align: center;
            padding: 20px 0;
        }

        .detail-asset-name {
            font-size: 18px;
            font-weight: 600;
            color: rgba(255,255,255,0.9);
            margin-bottom: 8px;
        }

        .detail-big-value {
            font-size: 56px;
            font-weight: 800;
            line-height: 1;
            margin: 8px 0;
        }

        .detail-level {
            font-size: 16px;
            font-weight: 500;
        }

        .detail-update-time {
            font-size: 11px;
            color: rgba(255,255,255,0.35);
            margin-top: 8px;
        }

        .factors-list {
            display: flex;
            flex-direction: column;
            gap: 14px;
        }

        .factor-item {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }

        .factor-header {
            display: flex;
            justify-content: space-between;
            font-size: 12px;
        }

        .factor-name {
            color: rgba(255,255,255,0.7);
        }

        .factor-value {
            color: rgba(255,255,255,0.9);
            font-weight: 600;
        }

        .factor-bar-bg {
            height: 6px;
            border-radius: 3px;
            background: rgba(255,255,255,0.06);
            overflow: hidden;
        }

        .factor-bar-fill {
            height: 100%;
            border-radius: 3px;
            transition: width 0.6s ease;
        }

        .detail-chart-canvas {
            width: 100%;
            height: 200px;
        }

        @media (max-width: 768px) {
            .assets-grid {
                grid-template-columns: repeat(3, 1fr);
            }

            .bottom-grid {
                grid-template-columns: 1fr;
            }

            .asset-card {
                padding: 12px 6px;
            }

            .asset-value {
                font-size: 18px;
            }

            .chart-canvas-wrapper {
                height: 180px;
            }

            .chart-canvas-wrapper canvas {
                height: 180px;
            }
        }

        @media (max-width: 480px) {
            .assets-grid {
                grid-template-columns: repeat(2, 1fr);
                gap: 8px;
            }

            .asset-name {
                font-size: 12px;
            }

            .asset-value {
                font-size: 16px;
            }

            .main-content {
                padding: 12px;
            }
        }
