/* 市场盘前晨报样式 - 共用CSS (参考 market_morning_report_20260916.html) */
@page {
    size: A4;
    margin: 12mm 12mm;
    @bottom-right {
        content: "第 " counter(page) " 页 / 共 " counter(pages) " 页";
        font-size: 8pt;
        color: #94a3b8;
        font-family: system-ui, -apple-system, sans-serif;
    }
}
*, *::before, *::after { box-sizing: border-box; }
.mr-body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-size: 9.5pt;
    line-height: 1.5;
    color: #1e293b;
    background-color: #f8fafc;
    margin: 0;
    padding: 0;
}
.mr-container {
    /* max-width: 850px; */
    margin: 0 auto;
    padding: 15px 30px;
    background-color: #ffffff;
}

/* Header */
.mr-header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: #ffffff;
    padding: 18px 20px;
    border-radius: 8px;
    margin-bottom: 16px;
}
.mr-header-top {
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    padding-bottom: 8px;
    margin-bottom: 8px;
}
.mr-header-title {
    font-size: 20pt;
    font-weight: 700;
    margin: 0;
    letter-spacing: 1px;
    color: #ffffff;
    display: inline-block;
}
.mr-header-badge {
    float: right;
    background-color: #dc2626;
    color: #ffffff;
    font-size: 8.5pt;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    margin-top: 4px;
}
.mr-header-date {
    font-size: 9.5pt;
    color: #cbd5e1;
    margin: 0;
}

/* Section Titles */
.mr-section-title {
    font-size: 12pt;
    font-weight: 700;
    color: #0f172a;
    border-left: 4px solid #dc2626;
    padding-left: 10px;
    margin: 18px 0 10px 0;
    page-break-after: avoid;
}

/* Core Summary */
.mr-summary-card {
    background-color: #fef2f2;
    border: 1px solid #fee2e2;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 16px;
}
.mr-summary-list {
    margin: 0;
    padding-left: 18px;
}
.mr-summary-list li {
    margin-bottom: 5px;
    color: #991b1b;
    font-weight: 600;
    font-size: 9.5pt;
    line-height: 1.6;
}
.mr-summary-list li:last-child { margin-bottom: 0; }

/* Yesterday Recap Table */
.mr-recap-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
}
.mr-recap-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
    font-size: 9pt;
}
.mr-recap-table tr:last-child td { border-bottom: none; }
.mr-source-tag {
    display: inline-block;
    background-color: #e2e8f0;
    color: #334155;
    font-weight: 600;
    font-size: 8pt;
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
}

/* Theme Box (core_themes & other_themes_brief 共用) */
.mr-theme-box {
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    margin-bottom: 14px;
    background: #ffffff;
    overflow: hidden;
    page-break-inside: avoid;
}
.mr-theme-header {
    background-color: #f1f5f9;
    border-bottom: 1px solid #cbd5e1;
    padding: 8px 14px;
    font-weight: 700;
    font-size: 10.5pt;
    color: #0f172a;
}
.mr-sub-item {
    padding: 10px 14px;
    border-bottom: 1px dashed #e2e8f0;
}
.mr-sub-item:last-child { border-bottom: none; }
.mr-sub-title {
    font-weight: 700;
    color: #b91c1c;
    font-size: 10pt;
    margin-bottom: 6px;
}
.mr-sub-title a {
    color: inherit;
    text-decoration: none;
}
.mr-sub-title a:hover { text-decoration: underline; }
.mr-detail-row {
    margin-bottom: 4px;
    font-size: 9pt;
    line-height: 1.5;
}
.mr-detail-label {
    font-weight: 600;
    color: #475569;
}
.mr-watch-box {
    background-color: #fffbeb;
    border: 1px solid #fef3c7;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 8.5pt;
    color: #92400e;
    margin-top: 6px;
}

/* Stock Pills */
.mr-stock-container { margin-top: 6px; }
.mr-stock-pill {
    display: inline-block;
    background-color: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 8.5pt;
    color: #1e293b;
    margin-right: 5px;
    margin-bottom: 4px;
}
.mr-stock-name { font-weight: 600; }
.mr-stock-code {
    font-size: 7.5pt;
    color: #64748b;
    margin-left: 3px;
}

/* Calendar Table */
.mr-calendar-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
}
.mr-calendar-table th {
    background-color: #1e293b;
    color: #ffffff;
    font-size: 8.5pt;
    font-weight: 600;
    text-align: left;
    padding: 6px 10px;
}
.mr-calendar-table td {
    padding: 6px 10px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 8.5pt;
    vertical-align: top;
}
.mr-calendar-table tr:last-child td { border-bottom: none; }
.mr-calendar-time {
    font-weight: 600;
    color: #2563eb;
    width: 32%;
}

/* Risk & Disclaimer */
.mr-risk-card {
    background-color: #fff1f2;
    border: 1px solid #fecdd3;
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 12px;
    page-break-inside: avoid;
}
.mr-risk-title {
    font-weight: 700;
    color: #9f1239;
    font-size: 9pt;
    margin-bottom: 4px;
}
.mr-risk-text {
    font-size: 8.5pt;
    color: #881337;
    line-height: 1.5;
}
.mr-disclaimer {
    text-align: center;
    font-size: 8pt;
    color: #94a3b8;
    margin-top: 10px;
}

/* Back Bar */
.mr-back-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #0f172a, #1e293b);
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity .2s;
}
.mr-back-bar:hover { opacity: .9; }
.mr-back-bar .mr-back-icon { font-size: 18px; }

/* 浮动目录菜单 */
.mr-toc {
    position: fixed;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    background: rgba(15, 23, 42, 0.95);
    border-radius: 10px 0 0 10px;
    padding: 8px 0;
    box-shadow: -2px 2px 12px rgba(0,0,0,0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.3s ease;
    overflow: hidden;
    width: 32px;
    max-height: 400px;
}
.mr-toc:hover {
    width: 180px;
    border-radius: 10px;
    padding: 10px 0;
}
.mr-toc-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #fff;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    height: 60px;
    margin: 0 auto;
    font-weight: 600;
    letter-spacing: 2px;
}
.mr-toc:hover .mr-toc-trigger { display: none; }
.mr-toc-list {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0 12px;
}
.mr-toc:hover .mr-toc-list { display: block; }
.mr-toc-list li {
    margin-bottom: 6px;
}
.mr-toc-list li:last-child { margin-bottom: 0; }
.mr-toc-list a {
    display: block;
    padding: 5px 10px;
    color: #cbd5e1;
    text-decoration: none;
    font-size: 10pt;
    border-radius: 4px;
    transition: all 0.2s;
    white-space: nowrap;
}
.mr-toc-list a:hover {
    background: rgba(220, 38, 38, 0.3);
    color: #fff;
}
.mr-toc-list li.mr-toc-share-item {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}
.mr-toc-share {
    display: block;
    width: 100%;
    padding: 6px 10px;
    background: rgba(220, 38, 38, 0.25);
    border: 1px solid rgba(220, 38, 38, 0.55);
    color: #fff;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-family: inherit;
    transition: all 0.2s;
    white-space: nowrap;
}
.mr-toc-share:hover {
    background: rgba(220, 38, 38, 0.55);
    border-color: rgba(255, 255, 255, 0.4);
}
.mr-toc-share:active {
    transform: scale(0.96);
}

/* Responsive */
@media(max-width:480px) {
    .mr-body { padding: 8px; }
    .mr-container { padding: 10px; }
    .mr-toc { display: none; }
}
@media(prefers-color-scheme:dark) {
    .mr-body { background: #121418; color: #e0e0e0; }
    .mr-container { background: #1a1d24; }
    .mr-theme-box { background: #1e2025; border-color: #3a3d44; }
    .mr-theme-header { background: #2a2d34; color: #e8e8e8; border-bottom-color: #3a3d44; }
    .mr-sub-title { color: #f87171; }
    .mr-sub-title a { color: #f87171; }
    .mr-detail-label { color: #a0a0a0; }
    .mr-recap-table { background: #1e2025; border-color: #3a3d44; }
    .mr-recap-table td { border-bottom-color: #2a2d34; }
    .mr-source-tag { background: #2a2d34; color: #cbd5e1; }
    .mr-calendar-table { border-color: #3a3d44; }
    .mr-calendar-table th { background: #2a2d34; }
    .mr-calendar-table td { border-bottom-color: #2a2d34; }
    .mr-summary-card { background: #2a1d1d; border-color: #3a2a2a; }
    .mr-summary-list li { color: #f87171; }
    .mr-risk-card { background: #2a1d22; border-color: #3a2a2f; }
}
