/* everyday_lianghua - Daily Stock Report Styles */
:root {
    --red: #e74c3c;
    --green: #27ae60;
    --bg: #f5f6fa;
    --card-bg: #ffffff;
    --text: #2c3e50;
    --text-secondary: #7f8c8d;
    --border: #ecf0f1;
    --highlight: #3498db;
    --warn: #e67e22;
    --danger: #e74c3c;
    --success: #27ae60;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.12);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    padding: 0;
}

/* Header */
.header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    padding: 32px 40px;
    text-align: center;
}
.header h1 { font-size: 28px; font-weight: 700; margin-bottom: 8px; }
.header .subtitle { font-size: 14px; opacity: 0.8; }
.header .date-badge {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    border-radius: 20px;
    padding: 4px 16px;
    margin-top: 10px;
    font-size: 14px;
}

/* Container */
.container { max-width: 1200px; margin: 0 auto; padding: 24px 20px; }

/* Market Overview */
.market-overview {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.market-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
    text-align: center;
}
.market-card .label { font-size: 13px; color: var(--text-secondary); margin-bottom: 6px; }
.market-card .value { font-size: 24px; font-weight: 700; }
.market-card .change { font-size: 14px; margin-top: 4px; }

.up { color: var(--red); }
.down { color: var(--green); }

/* Section */
.section {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}
.section h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
}
.section h2 .icon { font-size: 22px; }

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
thead th {
    background: #f8f9fa;
    padding: 12px 10px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
    white-space: nowrap;
}
tbody td {
    padding: 10px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
tbody tr:hover { background: #f8f9fa; }

/* Badges */
.badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}
.badge-focus { background: #fde8e8; color: var(--red); }
.badge-watch { background: #fef3c7; color: var(--warn); }
.badge-pass { background: #e8f5e9; color: var(--green); }
.badge-remove { background: #f5f5f5; color: #999; }
.badge-yizi { background: #ffe0b2; color: #e65100; }
.badge-band { background: #e3f2fd; color: #1565c0; }

/* Trader list */
.trader-section {
    margin-top: 16px;
    padding: 16px;
    background: #fafafa;
    border-radius: 8px;
    border-left: 4px solid var(--highlight);
}
.trader-section h3 { font-size: 16px; margin-bottom: 10px; }
.trader-list { list-style: none; }
.trader-list li {
    padding: 8px 0;
    border-bottom: 1px dashed var(--border);
    font-size: 14px;
}
.trader-list li:last-child { border-bottom: none; }
.trader-list .name { font-weight: 600; color: var(--highlight); }
.trader-list .seat { color: var(--text-secondary); font-size: 12px; }
.trader-list .style { font-size: 12px; }

/* Stock detail card */
.stock-detail {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 16px;
}
.stock-detail h3 { font-size: 18px; margin-bottom: 8px; }
.stock-detail .meta { font-size: 13px; color: var(--text-secondary); margin-bottom: 10px; }
.stock-detail .dragon-info {
    background: #fff8e1;
    padding: 12px;
    border-radius: 8px;
    margin: 10px 0;
    font-size: 14px;
}
.stock-detail .dragon-info table { font-size: 13px; }
.stock-detail .dragon-info table th { background: #fff3cd; }

/* Progress bar */
.progress-bar {
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 6px;
}
.progress-bar .fill { height: 100%; border-radius: 4px; }
.progress-bar .fill.buy { background: var(--red); }
.progress-bar .fill.sell { background: var(--green); }

/* Filter tabs */
.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.tab {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    border: 1px solid var(--border);
    background: var(--card-bg);
    transition: all 0.2s;
}
.tab:hover { background: #f0f0f0; }
.tab.active { background: var(--highlight); color: #fff; border-color: var(--highlight); }

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 12px;
}

/* Print */
@media print {
    body { background: #fff; }
    .section { box-shadow: none; border: 1px solid #ddd; }
    .header { background: #1a1a2e !important; -webkit-print-color-adjust: exact; }
}

/* Responsive */
@media (max-width: 768px) {
    .header { padding: 20px; }
    .header h1 { font-size: 22px; }
    .container { padding: 12px; }
    .section { padding: 16px; }
    table { font-size: 12px; }
    thead th, tbody td { padding: 8px 6px; }
}
/* ===== 2026-08-28 报告补充: 套用现有浅色主题所需的 class(仅补全,不改既有) ===== */
:root {
    --up: #e74c3c;      /* 涨=红(中国习惯) */
    --down: #27ae60;    /* 跌=绿 */
    --muted: #7f8c8d;
    --gold: #b8860b;
    --accent: #3498db;
    --card: #ffffff;
    --purple: #8b5cf6;
}

h1 { font-size: 24px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
h2 { font-size: 20px; font-weight: 700; color: var(--text); margin: 28px 0 14px; padding-bottom: 8px; border-bottom: 2px solid var(--border); }
h3 { font-size: 17px; font-weight: 600; color: var(--text); margin: 14px 0 8px; }
h4 { font-size: 15px; font-weight: 600; color: var(--text); margin: 10px 0 6px; }

.card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 20px; margin: 14px 0; box-shadow: var(--shadow); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px,1fr)); gap: 16px; }
.stock-header { margin-bottom: 8px; }
.backtest-summary { font-size: 14px; }

/* 表格: 兼容无 <thead>/<tbody> 的裸表(龙虎榜席位表等) */
th, td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--border); }
th { background: #f8f9fa; font-weight: 600; white-space: nowrap; }
tr:hover { background: #f8f9fa; }

.env-tag { display: inline-block; padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.env-tag.up { background: #fde8e8; color: var(--red); }
.env-tag.down { background: #e8f5e9; color: var(--green); }
.env-tag.neutral { background: #f0f0f0; color: var(--text-secondary); }
.env-tag.warn { background: #fef3c7; color: #b8860b; }
.env-tag.defense { background: #fde8e8; color: var(--red); border: 1px solid #f5c6cb; }

.badge-short { background: #fff3e0; color: #d35400; }
.badge-neutral { background: #f0f0f0; color: #6b7280; }
.badge-sell { background: #fde8e8; color: #c0392b; }
.badge-day { background: #fde8e8; color: #e74c3c; }
.badge-drop { background: #e8f5e9; color: #27ae60; }

.score-box { background: #f8f9fa; border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; margin: 10px 0; font-size: 13px; line-height: 1.7; }
.score-box .total { font-size: 14px; font-weight: 700; color: #b8860b; }
.total { font-weight: 700; }

.stock-detail.focus { border-left: 4px solid var(--red); }
.stock-detail.watch { border-left: 4px solid var(--warn); }
.stock-detail.observe { border-left: 4px solid #95a5a6; }

.warn-box { background: #fde8e8; border: 1px solid #f5c6cb; border-radius: 8px; padding: 12px; margin: 10px 0; font-size: 13px; color: #7f1d1d; }
.info-box { background: #e8f0fe; border: 1px solid #c3d9f7; border-radius: 8px; padding: 12px; margin: 10px 0; font-size: 13px; color: #1e3a8a; }
.defense-banner { background: linear-gradient(135deg, #fde8e8, #fef3f3); border: 1px solid #f5c6cb; border-radius: 10px; padding: 16px; margin: 12px 0; text-align: center; }
.defense-banner h3 { color: var(--red); margin: 0 0 6px; }
.defense-banner p { font-size: 14px; color: var(--text-secondary); }
