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

body {
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    background: #0a0e1a;
    color: #e2e8f0;
    overflow-x: hidden;
    line-height: 1.5;
    font-size: 14px;
}

/* 仪表板容器 */
.dashboard-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: linear-gradient(135deg, #0a0e1a 0%, #1e293b 50%, #0f172a 100%);
}

/* 顶部导航栏 */
.dashboard-header {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(30, 41, 59, 0.5);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    font-size: 1.8rem;
    animation: logoGlow 3s ease-in-out infinite;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: #00d4ff;
}

.logo-version {
    font-size: 0.7rem;
    color: rgba(226, 232, 240, 0.6);
    font-weight: 400;
}

.nav-tabs {
    display: flex;
    gap: 5px;
}

.nav-tab {
    padding: 8px 16px;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(30, 41, 59, 0.8);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.85rem;
    font-weight: 500;
}

.nav-tab.active {
    background: rgba(0, 212, 255, 0.2);
    border-color: rgba(0, 212, 255, 0.5);
    color: #00d4ff;
}

.nav-tab:hover:not(.active) {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(30, 41, 59, 1);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* 快速分析工具 */
.quick-analysis {
    position: relative;
}

.header-form {
    display: flex;
    align-items: center;
}

.header-input-group {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 8px;
    padding: 2px;
    transition: all 0.3s ease;
}

.header-input-group:focus-within {
    border-color: #00d4ff;
    box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.1);
}

.header-input-group input {
    background: transparent;
    border: none;
    padding: 8px 12px;
    font-size: 0.85rem;
    color: #e2e8f0;
    outline: none;
    font-family: 'JetBrains Mono', monospace;
    width: 200px;
    transition: width 0.3s ease;
}

.header-input-group input:focus {
    width: 220px;
}

.header-input-group input::placeholder {
    color: rgba(226, 232, 240, 0.5);
    font-size: 0.8rem;
}

.header-analyze-btn {
    background: linear-gradient(135deg, #00d4ff, #0ea5e9);
    color: #000000;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'JetBrains Mono', monospace;
    white-space: nowrap;
}

.header-analyze-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 16px rgba(0, 212, 255, 0.3);
}

.header-analyze-btn .btn-icon {
    font-size: 0.8rem;
}

.market-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    animation: statusBlink 2s ease-in-out infinite;
}

.status-indicator.online {
    background: #10b981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

.account-balance {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(30, 41, 59, 0.8);
    padding: 8px 16px;
    border-radius: 8px;
}

.balance-label {
    font-size: 0.8rem;
    color: rgba(226, 232, 240, 0.7);
}

.balance-value {
    font-size: 0.9rem;
    font-weight: 700;
    color: #10b981;
    font-family: 'JetBrains Mono', monospace;
}

/* 主要仪表板内容 */
.dashboard-main {
    flex: 1;
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 20px;
    padding: 20px;
    overflow: hidden;
}

/* 面板基础样式 */
.left-panel,
.right-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    height: 200px;
}

.center-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* 小部件基础样式 */
.widget {
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(30, 41, 59, 0.5);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.widget:hover {
    border-color: rgba(0, 212, 255, 0.3);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.widget-header {
    padding: 16px 20px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(30, 41, 59, 0.3);
}

.widget-header h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: #e2e8f0;
}

/* 市场数据小部件 */
.market-data {
    min-height: 250px;
}

.refresh-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: rgba(226, 232, 240, 0.6);
}

.refresh-dot {
    width: 6px;
    height: 6px;
    background: #10b981;
    border-radius: 50%;
    animation: refreshPulse 1.5s ease-in-out infinite;
}

.market-list {
    padding: 0;
}

.market-item {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
    transition: background 0.2s ease;
    align-items: center;
}

.market-item:hover {
    background: rgba(30, 41, 59, 0.3);
}

.market-item:last-child {
    border-bottom: none;
}

.symbol {
    font-weight: 700;
    color: #e2e8f0;
    font-size: 0.85rem;
}

.price {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 0.85rem;
    color: #e2e8f0;
}

.change {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 0.8rem;
    padding: 2px 6px;
    border-radius: 4px;
}

.change.positive {
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.change.negative {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

/* AI 推荐小部件 */
.ai-recommendations {
    min-height: 200px;
}

.ai-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: #00d4ff;
    font-weight: 600;
}

.ai-pulse {
    width: 6px;
    height: 6px;
    background: #00d4ff;
    border-radius: 50%;
    animation: aiPulse 2s ease-in-out infinite;
}

.recommendations-list {
    padding: 0;
}

.recommendation {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
    align-items: center;
}

.recommendation:last-child {
    border-bottom: none;
}

.rec-action {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    text-align: center;
    min-width: 60px;
}

.recommendation.buy .rec-action {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.recommendation.sell .rec-action {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.recommendation.hold .rec-action {
    background: rgba(251, 191, 36, 0.2);
    color: #fbbf24;
}

.rec-symbol {
    font-weight: 700;
    color: #e2e8f0;
    font-size: 0.85rem;
}

.rec-confidence {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 0.8rem;
    color: #00d4ff;
}

/* 主图表小部件 */
.main-chart {
    flex: 1;
    min-height: 400px;
}

.chart-controls {
    display: flex;
    gap: 5px;
}

.chart-btn {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(30, 41, 59, 0.8);
    color: rgba(226, 232, 240, 0.8);
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.75rem;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
}

.chart-btn.active {
    background: rgba(0, 212, 255, 0.2);
    border-color: rgba(0, 212, 255, 0.5);
    color: #00d4ff;
}

.chart-btn:hover:not(.active) {
    background: rgba(30, 41, 59, 0.8);
}

.chart-container {
    position: relative;
    padding: 20px;
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#trading-chart {
    width: 100%;
    height: 100%;
    background: rgba(30, 41, 59, 0.2);
    border-radius: 8px;
}

.chart-overlay {
    position: absolute;
    top: 30px;
    left: 30px;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(30, 41, 59, 0.5);
    border-radius: 8px;
    padding: 12px 16px;
}

.current-price {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.2rem;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 4px;
}

.price-change {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 600;
}

.price-change.positive {
    color: #10b981;
}

.price-change.negative {
    color: #ef4444;
}

/* AI特征展示小部件 */
.ai-features {
    background: rgba(0, 212, 255, 0.05);
    border-color: rgba(0, 212, 255, 0.2);
    min-height: 280px;
}

.ai-features .widget-header {
    background: rgba(0, 212, 255, 0.1);
    border-bottom-color: rgba(0, 212, 255, 0.2);
}

.ai-features .widget-header h3 {
    color: #00d4ff;
}

.features-grid {
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.feature-card {
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(30, 41, 59, 0.5);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    background: rgba(30, 41, 59, 0.5);
    border-color: rgba(0, 212, 255, 0.3);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.feature-card .feature-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 15px;
    animation: featureIconFloat 4s ease-in-out infinite;
}

.gradient-blue {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    box-shadow: 0 8px 16px rgba(59, 130, 246, 0.3);
}

.gradient-green {
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 8px 16px rgba(16, 185, 129, 0.3);
}

.gradient-purple {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    box-shadow: 0 8px 16px rgba(139, 92, 246, 0.3);
}

.gradient-orange {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 8px 16px rgba(245, 158, 11, 0.3);
}

.feature-card h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.8rem;
    color: rgba(226, 232, 240, 0.7);
    margin-bottom: 12px;
    line-height: 1.4;
}

.feature-metric {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.2rem;
    font-weight: 800;
    color: #00d4ff;
}

/* 性能指标小部件 */
.performance-metrics {
    min-height: 220px;
}

.time-selector select {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(30, 41, 59, 0.8);
    color: #e2e8f0;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-family: 'JetBrains Mono', monospace;
    outline: none;
}

.metrics-grid {
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
}

.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
}

.metric-item:last-child {
    border-bottom: none;
}

.metric-label {
    font-size: 0.8rem;
    color: rgba(226, 232, 240, 0.7);
    font-weight: 500;
}

.metric-value {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 0.85rem;
    color: #e2e8f0;
}

.metric-value.positive {
    color: #10b981;
}

.metric-value.negative {
    color: #ef4444;
}

/* 最近交易小部件 */
.recent-trades {
    min-height: 200px;
}

.view-all {
    font-size: 0.75rem;
    color: #00d4ff;
    cursor: pointer;
    font-weight: 500;
}

.view-all:hover {
    text-decoration: underline;
}

.trades-list {
    padding: 0;
}

.trade-item {
    display: grid;
    grid-template-columns: auto auto auto 1fr;
    gap: 12px;
    padding: 10px 20px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
    align-items: center;
    font-size: 0.8rem;
}

.trade-item:last-child {
    border-bottom: none;
}

.trade-symbol {
    font-weight: 700;
    color: #e2e8f0;
}

.trade-action {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    min-width: 50px;
    text-align: center;
}

.trade-action.buy {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.trade-action.sell {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.trade-amount {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    color: rgba(226, 232, 240, 0.8);
}

.trade-price {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    color: #e2e8f0;
    text-align: right;
}

/* 新闻和警报小部件 */
.news-alerts {
    min-height: 180px;
}

.alert-count {
    background: #ef4444;
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 50%;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-list {
    padding: 0;
}

.news-item {
    display: flex;
    gap: 12px;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
    align-items: flex-start;
}

.news-item:last-child {
    border-bottom: none;
}

.news-item.alert {
    background: rgba(239, 68, 68, 0.05);
    border-left: 3px solid #ef4444;
}

.news-time {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: rgba(226, 232, 240, 0.6);
    font-weight: 600;
    min-width: 40px;
}

.news-content {
    font-size: 0.8rem;
    color: rgba(226, 232, 240, 0.8);
    line-height: 1.4;
}

/* 底部状态栏 */
.dashboard-footer {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(30, 41, 59, 0.5);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.connection-status {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(226, 232, 240, 0.7);
}

.connection-dot {
    width: 6px;
    height: 6px;
    background: #10b981;
    border-radius: 50%;
    animation: connectionPulse 2s ease-in-out infinite;
}

.last-update {
    color: rgba(226, 232, 240, 0.6);
}

.footer-right {
    max-width: 60%;
}

.disclaimer-text {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(226, 232, 240, 0.6);
    font-size: 0.7rem;
}

.disclaimer-icon {
    color: #fbbf24;
    font-size: 0.8rem;
}

/* 模态框 */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(15px);
    z-index: 3000;
}

.modal-overlay.show {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: modalFadeIn 0.4s ease-out;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.1), transparent);
}

.modal-container {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 16px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    position: relative;
    animation: modalSlideUp 0.6s ease-out;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.5);
    color: #e2e8f0;
}

.modal-header {
    text-align: center;
    margin-bottom: 30px;
}

.modal-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    position: relative;
    animation: modalIconBounce 1s ease-out;
}

.icon-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #00d4ff, #0ea5e9);
    border-radius: 50%;
    animation: iconBgRotate 3s ease-in-out infinite;
}

.icon-symbol {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.5rem;
    z-index: 2;
}

.modal-title {
    font-size: 2rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 10px;
}

.modal-subtitle {
    font-size: 1rem;
    color: rgba(226, 232, 240, 0.8);
}

.modal-content {
    margin-bottom: 30px;
}

.analysis-summary {
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(30, 41, 59, 0.5);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(30, 41, 59, 0.3);
}

.summary-item:last-child {
    border-bottom: none;
}

.summary-label {
    font-size: 0.9rem;
    color: rgba(226, 232, 240, 0.7);
}

.summary-value {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 0.9rem;
    color: #00d4ff;
}

.report-preview {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.preview-section {
    background: rgba(0, 212, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 8px;
    padding: 15px;
}

.preview-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #00d4ff;
    margin-bottom: 8px;
}

.preview-section p {
    font-size: 0.85rem;
    color: rgba(226, 232, 240, 0.8);
    line-height: 1.4;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.primary-action-btn {
    background: linear-gradient(135deg, #00d4ff, #0ea5e9);
    color: #000000;
    border: none;
    padding: 16px 24px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'JetBrains Mono', monospace;
}

.primary-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(0, 212, 255, 0.4);
}

.secondary-action-btn {
    background: transparent;
    color: rgba(226, 232, 240, 0.7);
    border: 1px solid rgba(226, 232, 240, 0.2);
    padding: 14px 24px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'JetBrains Mono', monospace;
}

.secondary-action-btn:hover {
    background: rgba(226, 232, 240, 0.05);
    border-color: rgba(226, 232, 240, 0.3);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: rgba(226, 232, 240, 0.6);
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-modal:hover {
    color: #00d4ff;
    background: rgba(0, 212, 255, 0.1);
    transform: scale(1.1);
}

/* 动画 */
@keyframes logoGlow {
    0%, 100% {
        filter: drop-shadow(0 0 5px rgba(0, 212, 255, 0.3));
    }
    50% {
        filter: drop-shadow(0 0 15px rgba(0, 212, 255, 0.6));
    }
}

@keyframes statusBlink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

@keyframes refreshPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.2);
    }
}

@keyframes aiPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.3);
    }
}

@keyframes statusLightPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.2);
    }
}

@keyframes featureIconFloat {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-5px);
    }
}

@keyframes connectionPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.6;
    }
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalSlideUp {
    0% {
        transform: translateY(50px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes modalIconBounce {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes iconBgRotate {
    0%, 100% {
        transform: rotate(0deg);
    }
    50% {
        transform: rotate(180deg);
    }
}

@keyframes countUp {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .dashboard-main {
        grid-template-columns: 250px 1fr 250px;
        gap: 15px;
        padding: 15px;
    }
}

@media (max-width: 968px) {
    .dashboard-main {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }
    
    .left-panel,
    .right-panel {
        flex-direction: row;
        overflow-x: auto;
        gap: 15px;
    }
    
    .left-panel .widget,
    .right-panel .widget {
        min-width: 280px;
        flex-shrink: 0;
    }
    
    .header-left {
        gap: 20px;
    }
    
    .nav-tabs {
        display: none;
    }
    
    .header-right {
        gap: 12px;
    }
    
    .account-balance {
        padding: 6px 12px;
    }
    
    /* 移动端快速分析工具优化 */
    .quick-analysis {
        order: -1;
        margin-right: 15px;
    }
    
    .header-input-group input {
        width: 160px;
        font-size: 0.8rem;
    }
    
    .header-input-group input:focus {
        width: 180px;
    }
    
    .header-analyze-btn {
        padding: 8px 12px;
        font-size: 0.7rem;
    }
    
    .header-analyze-btn .btn-text {
        display: none;
    }
    
    .header-analyze-btn .btn-icon {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .dashboard-header {
        padding: 10px 15px;
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .header-left,
    .header-right {
        justify-content: center;
        gap: 15px;
        flex-wrap: wrap;
    }
    
    .dashboard-main {
        padding: 10px;
        gap: 10px;
        overflow-y: auto;
    }
    
    /* 移动端分析工具全宽显示 */
    .quick-analysis {
        order: 0;
        width: 100%;
        margin: 10px 0;
    }
    
    .header-input-group {
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .header-input-group input {
        width: 100%;
        font-size: 0.9rem;
        padding: 10px 12px;
    }
    
    .header-input-group input:focus {
        width: 100%;
    }
    
    .header-analyze-btn {
        padding: 10px 16px;
        font-size: 0.8rem;
    }
    
    .header-analyze-btn .btn-text {
        display: inline;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .modal-container {
        padding: 30px 20px;
        margin: 20px;
    }
    
    .modal-title {
        font-size: 1.6rem;
    }
    
    .dashboard-footer {
        flex-direction: column;
        gap: 10px;
        text-align: center;
        padding: 15px;
    }
    
    .footer-right {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 13px;
    }
    
    .logo-name {
        font-size: 1rem;
    }
    
    .logo-version {
        font-size: 0.65rem;
    }
    
    .widget-header {
        padding: 12px 15px;
    }
    
    .widget-header h3 {
        font-size: 0.85rem;
    }
    
    /* 小屏幕分析工具优化 */
    .header-input-group {
        max-width: 100%;
        padding: 3px;
    }
    
    .header-input-group input {
        padding: 8px 10px;
        font-size: 0.85rem;
    }
    
    .header-analyze-btn {
        padding: 8px 12px;
        font-size: 0.75rem;
    }
    
    .feature-card {
        padding: 15px;
    }
    
    .feature-card .feature-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .feature-card h4 {
        font-size: 0.9rem;
    }
    
    .feature-card p {
        font-size: 0.75rem;
    }
    
    .feature-metric {
        font-size: 1rem;
    }
    
    .modal-icon {
        width: 60px;
        height: 60px;
    }
    
    .icon-symbol {
        font-size: 2rem;
    }
    
    .modal-title {
        font-size: 1.4rem;
    }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .widget:hover,
    .nav-tab:hover,
    .analyze-button:hover,
    .primary-action-btn:hover {
        transform: none;
        box-shadow: none;
    }
    
    .analyze-button:active {
        transform: scale(0.98);
    }
    
    .primary-action-btn:active {
        transform: scale(0.98);
    }
    
    .nav-tab:active {
        transform: scale(0.98);
    }
}
