

/* Header Section */
.dashboard-header {
    background: linear-gradient(135deg, var(--primary) 0%, #2a5cdb 100%);
    color: white;
    padding: 40px 20px;
    margin: -20px -15px 30px -15px;
    border-radius: 0 0 20px 20px;
}

.dashboard-title {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
}

.dashboard-subtitle {
    font-size: 16px;
    opacity: 0.9;
    margin: 5px 0 0 0;
}

/* Header Stats */
.header-stats {
    display: flex;
    gap: 20px;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.stats-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.stat-mini {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,0.1);
    padding: 10px 15px;
    border-radius: 8px;
}

.stat-mini .stat-icon {
    font-size: 20px;
    opacity: 0.9;
}

.stat-mini .stat-content {
    text-align: left;
}

.stat-mini .stat-value {
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
}

.stat-mini .stat-label {
    font-size: 11px;
    text-transform: uppercase;
    opacity: 0.9;
    margin-top: 3px;
}

/* Scanner Section */
.scanner-section {
    margin-bottom: 30px;
}

.scanner-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.scanner-card .card-title {
    color: var(--primary);
    font-size: 20px;
    margin-bottom: 20px;
}

/* Scan Results */
.scan-results-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stat Cards */
.stat-card {
    background: var(--bg);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid var(--line);
}

.stat-card .stat-label {
    color: var(--text);
    font-size: 12px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.stat-card .stat-value {
    color: var(--onsurface);
    font-size: 24px;
    font-weight: 700;
}

.stat-card .stat-usd {
    color: var(--text);
    font-size: 14px;
    margin-top: 5px;
}

/* Wallet Cards */
.wallet-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 20px;
    height: 100%;
    transition: transform 0.2s, box-shadow 0.2s;
}

.wallet-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.wallet-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--line);
}

.wallet-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--onsurface);
    margin: 0;
}

.wallet-address {
    margin-top: 5px;
}

.wallet-address a {
    font-family: monospace;
    font-size: 12px;
}

.wallet-actions {
    display: flex;
    gap: 5px;
}

.wallet-stats .stat {
    margin-bottom: 10px;
}

.wallet-stats .stat-label {
    font-size: 11px;
    color: var(--text);
    text-transform: uppercase;
    margin-bottom: 3px;
}

.wallet-stats .stat-value {
    font-size: 18px;
    font-weight: 600;
    color: var(--onsurface);
}

.wallet-footer {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--line);
}

/* Section Headers */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-title {
    color: var(--onsurface);
    font-size: 22px;
    font-weight: 600;
    margin: 0;
}

/* Tables */
.table {
    background: var(--surface);
    color: var(--onsurface);
    margin-bottom: 0;
}

.table thead th {
    background: var(--bg);
    color: var(--text);
    font-size: 12px;
    text-transform: uppercase;
    border-color: var(--line);
    font-weight: 600;
}

.table tbody td {
    border-color: var(--line);
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background: rgba(55, 114, 255, 0.05);
}

/* Buttons */
.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: #2a5cdb;
    border-color: #2a5cdb;
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.btn-outline-secondary {
    color: var(--text);
    border-color: var(--line);
    background: transparent;
}

.btn-outline-secondary:hover,
.btn-outline-secondary.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* Badges */
.badge {
    font-weight: 500;
    padding: 4px 8px;
    font-size: 11px;
}

/* Form Controls */
.form-control,
.form-select {
    background: var(--bg);
    border: 1px solid var(--line);
    color: var(--onsurface);
    transition: all 0.2s;
}

.form-control:focus,
.form-select:focus {
    background: var(--bg);
    border-color: var(--primary);
    color: var(--onsurface);
    box-shadow: 0 0 0 0.2rem rgba(55, 114, 255, 0.25);
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text);
    font-size: 14px;
}

/* Cards */
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--line);
    padding: 20px;
}

.card-body {
    padding: 20px;
}

/* Alerts */
.alert {
    border-radius: 8px;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    border: 1px solid rgba(33, 150, 243, 0.3);
    color: var(--onsurface);
}

.alert-warning {
    background: rgba(255, 152, 0, 0.1);
    border: 1px solid rgba(255, 152, 0, 0.3);
    color: var(--onsurface);
}

/* Dark Theme Support */
.is_dark .scanner-card,
.is_dark .scan-results-card,
.is_dark .wallet-card,
.is_dark .card {
    background: var(--surface);
}

.is_dark .stat-card {
    background: var(--bg1);
}

.is_dark .table {
    background: var(--surface);
}

.is_dark .table thead th {
    background: var(--bg1);
}

.is_dark .form-control,
.is_dark .form-select {
    background: var(--bg1);
    color: var(--onsurface);
}

.is_dark .form-control:focus,
.is_dark .form-select:focus {
    background: var(--bg1);
}

/* Loading States */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--line);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-header {
        text-align: center;
        padding: 30px 15px;
    }

    .header-stats {
        justify-content: center;
        margin-top: 20px;
    }

    .dashboard-title {
        font-size: 24px;
    }

    .wallet-card {
        margin-bottom: 15px;
    }

    .section-header {
        flex-direction: column;
        align-items: start;
    }

    .stat-mini {
        flex: 1 1 calc(50% - 10px);
        min-width: 140px;
    }
}