/* 密度页：只加宽内容壳；gutter 沿用全局 --sa-topbar-px，与顶栏对齐
   （同 stock_quote / trading_thesis / plate_ranking），减少大屏两侧留白 */
body.ic-body {
    --sa-topbar-max-width: 1600px;
    font-family: 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

@media (min-width: 1680px) {
    body.ic-body {
        --sa-topbar-max-width: 1720px;
    }
}

@media (min-width: 1920px) {
    body.ic-body {
        --sa-topbar-max-width: 1840px;
    }
}

@media (max-width: 720px) {
    body.ic-body {
        --sa-topbar-max-width: 100%;
    }
}

.calendar-page-wrap {
    width: 100%;
    max-width: var(--sa-topbar-max-width, 1600px);
    margin-inline: auto;
    padding: 16px var(--sa-topbar-px, 24px) 24px;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .calendar-page-wrap {
        padding-top: 12px;
        padding-bottom: 16px;
    }
}

.calendar-page-wrap > .container {
    max-width: 100%;
    margin: 0;
    background: white;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
    padding-inline: 0;
}

.container .calendar-toolbar.sa-page-toolbar {
    margin: 0;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
}

/* 页内工具条：筛选控件（Tier 2，品牌行已迁至 _site_topbar） */
.calendar-toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.toolbar-month-jump {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 6px;
    border: 1px solid #e5e7eb;
    border-radius: 3px;
    background: #fff;
}
.toolbar-month-jump select {
    height: 30px;
    border: 1px solid #d1d5db;
    border-radius: 3px;
    background: #fff;
    font-size: 12px;
    color: #374151;
    padding: 0 8px;
}
.toolbar-month-jump button {
    height: 30px;
    border: 1px solid #1a56a7;
    border-radius: 3px;
    background: #1a56a7;
    color: #fff;
    font-size: 12px;
    padding: 0 10px;
    cursor: pointer;
}
.toolbar-month-jump button:hover {
    background: #144785;
    border-color: #144785;
}
.toolbar-search {
    width: 140px;
    padding: 6px 10px;
    border: 1px solid #d1d5db;
    border-radius: 3px;
    background: #fff;
    font-size: 12px;
}
.toolbar-search:focus { outline: none; border-color: #1a56a7; }
.toolbar-switch-wrap {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #6b7280;
}
.toolbar-switch {
    width: 32px;
    height: 18px;
    border-radius: 9px;
    background: #d1d5db;
    position: relative;
    cursor: pointer;
    transition: background 0.2s;
}
.toolbar-switch.on { background: #1a56a7; }
.toolbar-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
    transition: transform 0.2s;
}
.toolbar-switch.on::after { transform: translateX(14px); }
.toolbar-view-group {
    display: inline-flex;
    border: 1px solid #e5e7eb;
    border-radius: 3px;
    overflow: hidden;
}
.toolbar-view-btn {
    width: 36px;
    height: 32px;
    border: none;
    background: #fff;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #e5e7eb;
}
.toolbar-view-btn:last-child { border-right: none; }
.toolbar-view-btn:hover { background: #f1f5f9; color: #1a56a7; }
.toolbar-view-btn.active { background: #eff6ff; color: #1a56a7; }
.toolbar-filter-btn {
    padding: 6px 12px;
    border: 1px solid #d1d5db;
    border-radius: 3px;
    background: #fff;
    font-size: 12px;
    color: #374151;
    cursor: pointer;
}
.toolbar-filter-btn:hover { border-color: #1a56a7; color: #1a56a7; }

/* 筛选抽屉 */
.filter-drawer {
    background: #fafbfc;
    border-bottom: 1px solid #e5e7eb;
    padding: 12px 16px;
    display: none;
}
.filter-drawer.open { display: block; }
.filter-drawer-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 8px;
}
.filter-drawer-row:last-child { margin-bottom: 0; }
.filter-drawer-label { font-size: 11px; color: #6b7280; margin-right: 4px; min-width: 36px; }
.filter-drawer select {
    padding: 5px 8px;
    border: 1px solid #d1d5db;
    border-radius: 3px;
    background: #fff;
    font-size: 12px;
}
.filter-drawer-options {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 4px;
}
.filter-drawer-option {
    padding: 4px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    background: #fff;
    font-size: 12px;
    color: #374151;
    cursor: pointer;
}
.filter-drawer-option:hover { border-color: #1a56a7; color: #1a56a7; }
.filter-drawer-option.active { border-color: #1a56a7; color: #1a56a7; background: #eff6ff; }
.filter-drawer-actions { margin-left: auto; }
.filter-drawer-actions button {
    padding: 5px 12px;
    margin-left: 6px;
    border-radius: 3px;
    font-size: 12px;
    cursor: pointer;
}
.filter-drawer-actions .btn-apply { background: #1a56a7; color: #fff; border: 1px solid #1a56a7; }
.filter-drawer-actions .btn-reset { background: #fff; color: #374151; border: 1px solid #d1d5db; }

.filter-controls {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}
.filter-controls select,
.filter-controls input {
    padding: 6px 10px;
    border: 1px solid #d1d5db;
    border-radius: 3px;
    background: white;
    font-size: 12px;
}
.filter-controls button {
    padding: 6px 12px;
    background: #1a56a7;
    color: white;
    border: 1px solid #1a56a7;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
}
.filter-controls button:hover { background: #144785; }

.view-mode-switcher { display: none; }
.calendar-quick-options { display: none; }

.calendar-container {
    padding: clamp(16px, 2vw, 28px);
}

.calendar-pager {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 0 clamp(16px, 2vw, 28px) 24px;
    color: #6b7280;
    font-size: 0.85rem;
}

.calendar-pager[hidden] {
    display: none;
}

.calendar-pager button {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #1f2937;
    border-radius: 6px;
    padding: 8px 14px;
    cursor: pointer;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.calendar-pager button:hover:not(:disabled) {
    border-color: #1a56a7;
    color: #1a56a7;
}

.calendar-pager button:disabled {
    opacity: 0.55;
    cursor: wait;
}

.month-section {
    margin-bottom: 50px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    scroll-margin-top: 72px;
}

.month-section.collapsed {
    margin-bottom: 15px;
}

/* 月份标题栏：线条+排版隔离，无色块。金融/数据产品风格 */
.month-header {
    background: #fff;
    color: #111827;
    padding: 16px 0 12px;
    border-radius: 0;
    margin-bottom: 0;
    border: none;
    border-bottom: 1px solid #E5E7EB;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background 0.2s;
    box-shadow: none;
}

.month-header:hover {
    background: #fafafa;
}

.month-header.current-month,
.month-header.past-month,
.month-header.future-month {
    background: #fff;
    opacity: 1;
}
.month-header.current-month:hover,
.month-header.past-month:hover,
.month-header.future-month:hover {
    background: #fafafa;
}

/* 主标题：字重与字号撑起结构，极深黑灰镇住全场 */
.month-header h2 {
    margin: 0;
    font-size: 1.125rem;   /* 18px */
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #111827;
    line-height: 1.3;
}

/* 主标题与辅助信息基线对齐，秩序感 */
.month-info {
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

/* 事件数量：去胶囊，浅灰纯文本，明显弱于主标题 */
.month-header .event-count {
    background: none;
    padding: 0;
    border-radius: 0;
    font-size: 0.8125rem;  /* 13px */
    font-weight: 400;
    color: #6B7280;
    line-height: 1.3;
}

.month-header .current-month-indicator {
    font-size: 0.8125rem;
    color: #6B7280;
    font-weight: 400;
    line-height: 1.3;
}

.month-toggle-icon {
    color: #999;
    font-size: 0.9rem;
    transition: transform 0.2s;
    background: none;
    padding: 4px;
    border-radius: 0;
}

.month-toggle-icon:hover {
    color: #1a56a7;
}

.month-toggle-icon.collapsed {
    transform: rotate(-90deg);
}

.month-content {
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    transform-origin: top;
}

.month-content.collapsed {
    max-height: 0;
    opacity: 0;
    margin-bottom: 0;
    transform: scaleY(0.95);
}

.month-content:not(.collapsed) {
    transform: scaleY(1);
    margin-bottom: 28px;
}

.past-month-indicator,
.current-month-indicator {
    padding: 0;
    font-size: 0.75rem;
    font-weight: 400;
}

/* 无情数据风格：无左侧大圆与粗线，时间作锚 */
.day-section {
    margin-bottom: 28px;
    padding-left: 0;
    position: relative;
    transition: all 0.3s ease;
}

.day-section.collapsed {
    margin-bottom: 16px;
}

.day-section.today-day-section {
    background: rgba(248, 250, 252, 0.8);
    border-radius: 8px;
    padding: 12px 16px 16px;
    border-left: 3px solid #1a56a7;
}

.day-section::before {
    display: none;
}

.day-header {
    background: #fafbfc;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: none;
    border-bottom: 1px solid #e5e7eb;
    cursor: pointer;
    transition: background 0.2s;
    box-shadow: none;
    position: relative;
}

.day-header::before {
    display: none;
}

.day-header:hover {
    background: #f1f5f9;
}

.day-header.past-day {
    background: #f8fafc;
    opacity: 0.9;
}

.day-header.past-day:hover {
    background: #f1f5f9;
}

.day-section.past-day-section .events-grid {
    opacity: 0.92;
}

.day-header.future-day {
    background: #fafbfc;
}

.day-header.future-day:hover {
    background: #f1f5f9;
}

.day-header.today-day {
    background: #eff6ff;
    border-bottom-color: #93c5fd;
}

.day-header.today-day:hover {
    background: #dbeafe;
}

.day-header.today-day::before {
    display: none;
}

/* 滚动到今天的动画 */
.scroll-to-today {
    animation: highlightToday 2s ease-in-out;
}

@keyframes highlightToday {
    0% {
        transform: scale(1);
        box-shadow: none;
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 0 20px rgba(255, 193, 7, 0.5);
    }
    100% {
        transform: scale(1);
        box-shadow: none;
    }
}

/* 日历视图：月网格 */
.calendar-grid-wrap { padding: 20px; }
.calendar-grid-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.calendar-grid-nav h3 { margin: 0; font-size: 1.2rem; color: #1a56a7; }
.calendar-grid-nav button { padding: 6px 14px; border: 1px solid #ddd; border-radius: 8px; background: #fff; cursor: pointer; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; background: #e9ecef; border-radius: 10px; overflow: hidden; }
.calendar-grid .weekday-header { padding: 10px; text-align: center; font-size: 0.8rem; font-weight: 600; color: #555; background: #f8f9fa; }
.calendar-cell { min-height: 64px; padding: 6px; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; cursor: pointer; transition: background 0.2s; position: relative; }
.calendar-cell:hover { background: #e3f2fd; }
.calendar-cell.other-month { opacity: 0.5; }
.calendar-cell.today { background: #fff3cd; font-weight: 600; }
.calendar-cell.today:hover { background: #ffeaa7; }
.calendar-cell.has-new-events { box-shadow: inset 0 0 0 2px #fecaca; }
.calendar-cell .day-num { font-size: 0.95rem; color: #333; }
.calendar-cell .day-new-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 3px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 16px;
    text-align: center;
}
.calendar-cell .day-events-dot { width: 6px; height: 6px; border-radius: 50%; background: #d9534f; margin-top: 4px; }
.calendar-cell.has-new-events .day-events-dot { background: #ef4444; }
.calendar-cell .day-events-count { font-size: 0.7rem; color: #1a56a7; margin-top: 2px; font-weight: 500; }
.calendar-cell.empty { cursor: default; }
.calendar-cell.empty:hover { background: #fff; }

/* 日历点击某日的详情侧栏 */
.day-detail-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.3); z-index: 1000; opacity: 0; pointer-events: none; transition: opacity 0.2s; }
.day-detail-overlay.show { opacity: 1; pointer-events: auto; }
.day-detail-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: min(420px, 95vw);
    max-width: 95vw;
    height: 100vh;
    background: #fff;
    box-shadow: -4px 0 20px rgba(0,0,0,0.15);
    z-index: 1001;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.25s ease;
}
@media (min-width: 1600px) {
    .day-detail-panel {
        width: min(460px, 28vw);
    }
}
.day-detail-panel.show { transform: translateX(0); }
.day-detail-panel .panel-header { padding: 16px 20px; border-bottom: 1px solid #e9ecef; display: flex; justify-content: space-between; align-items: center; background: #f8f9fa; }
.day-detail-panel .panel-header h3 { margin: 0; font-size: 1.1rem; color: #1a56a7; }
.day-detail-panel .panel-close { padding: 6px 12px; border: none; background: #e9ecef; border-radius: 8px; cursor: pointer; }
.day-detail-panel .panel-body { padding: 16px; }

/* 时间轴：随内容壳铺满，不再锁 900px 造成白卡内两侧再留白 */
.timeline-wrap {
    padding: 24px clamp(16px, 2.2vw, 36px) 28px clamp(20px, 2.5vw, 40px);
    max-width: none;
    width: 100%;
    margin: 0;
    box-sizing: border-box;
    position: relative;
}
.timeline-date-node { position: relative; margin-bottom: 20px; padding-left: 0; }
/* 细竖线：降噪 */
.timeline-date-node::before { content: ''; position: absolute; left: 4px; top: 18px; bottom: -20px; width: 1px; background: #cbd5e1; }
.timeline-date-node.timeline-node-past::before { background: #e2e8f0; }
.timeline-date-node.timeline-node-today::before { background: #93c5fd; }
.timeline-date-node:last-child::before { display: none; }
.timeline-date-header { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; cursor: pointer; padding: 8px 12px 8px 0; background: transparent; border: none; border-radius: 0; transition: background 0.2s; }
.timeline-date-header:hover { background: rgba(15, 23, 42, 0.03); }
/* 节点：过去=灰线无点/小灰点，今天=小蓝点+呼吸灯，未来=空心小圈 */
.timeline-date-header .date-dot {
    width: 8px; height: 8px; border-radius: 50%;
    flex-shrink: 0; margin-left: 0;
    background: transparent; border: 1px solid #94a3b8;
    box-sizing: border-box;
}
.timeline-date-header.past .date-dot {
    width: 4px; height: 4px; background: #94a3b8; border: none;
}
.timeline-date-header.today .date-dot {
    width: 8px; height: 8px; background: #1a56a7; border: 1px solid #1a56a7;
    box-shadow: 0 0 0 2px rgba(26, 86, 167, 0.2);
    animation: timelineTodayPulse 2s ease-in-out infinite;
}
@keyframes timelineTodayPulse {
    0%, 100% { box-shadow: 0 0 0 2px rgba(26, 86, 167, 0.2); }
    50% { box-shadow: 0 0 0 5px rgba(26, 86, 167, 0.12); }
}
.timeline-date-header .date-text { font-size: 0.98rem; font-weight: 600; color: #334155; }
.timeline-date-header .date-meta { font-size: 0.8rem; color: #64748b; }
.timeline-date-header.past .date-text { color: #64748b; }
.timeline-date-header.past .date-meta { color: #94a3b8; }
.timeline-events { padding-left: 24px; position: relative; }
.timeline-events::before { display: none; }
.timeline-event-item { position: relative; padding: 8px 0 8px 12px; border-left: 1px solid #e2e8f0; margin-left: 4px; }
.timeline-event-item:last-child { padding-bottom: 0; }
.timeline-event-item::before { content: ''; position: absolute; left: -5px; top: 14px; width: 4px; height: 4px; border-radius: 50%; background: #94a3b8; }
.timeline-event-item .event-title { font-weight: 600; color: #334155; margin-bottom: 2px; font-size: 0.9rem; }
.timeline-event-item .event-time { font-size: 0.75rem; color: #64748b; font-variant-numeric: tabular-nums; }
.timeline-date-header .toggle-icon { margin-left: auto; color: #94a3b8; transition: transform 0.2s; }
.timeline-date-node.timeline-node-collapsed .timeline-date-header .toggle-icon { transform: rotate(-90deg); }
.timeline-date-node.timeline-node-collapsed .timeline-events { display: none; }

.timeline-date-node.timeline-node-today {
    background: rgba(248, 250, 252, 0.9);
    border-radius: 8px;
    padding: 8px 10px 12px 0;
    margin-left: -4px;
    padding-left: 4px;
    border-left: 2px solid #1a56a7;
}

.past-indicator {
    color: #999;
    font-size: 0.8rem;
    font-style: italic;
}

.today-indicator {
    color: #1a56a7;
    font-size: 0.75rem;
    font-weight: 600;
}

.toggle-icon {
    color: #1a56a7;
    transition: transform 0.3s ease;
}

.day-header.past-day .toggle-icon {
    color: #999;
}

.day-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.date {
    font-size: 1.05rem;
    font-weight: 600;
    color: #334155;
    font-variant-numeric: tabular-nums;
}

.day-header.past-day .date { color: #64748b; }
.day-header.today-day .date { color: #1a56a7; }

.weekday {
    background: #e2e8f0;
    color: #475569;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.day-event-count {
    background: transparent;
    color: #64748b;
    padding: 0;
    font-size: 0.8rem;
    font-weight: 500;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    transform-origin: top;
    margin-bottom: 10px;
}

.events-grid.collapsed {
    max-height: 0;
    opacity: 0;
    margin-bottom: 0;
    transform: scaleY(0.9);
    padding: 0;
}

.events-grid:not(.collapsed) {
    transform: scaleY(1);
    margin-bottom: 15px;
}

.event-card {
    background: white;
    border: none;
    border-bottom: 1px solid #eee;
    border-radius: 0;
    padding: 14px 16px 14px 12px;
    transition: background 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
}

.event-card:hover {
    background: #fafbfc;
    box-shadow: none;
}

.event-card-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
/* 时间作锚：专业快讯列表风格 */
.event-time-col {
    flex: 0 0 56px;
    width: 56px;
    font-size: 0.8rem;
    color: #64748b;
    font-variant-numeric: tabular-nums;
    font-family: ui-monospace, 'SF Mono', monospace;
    letter-spacing: 0.02em;
}
.event-time-col::after {
    content: '\2588';
    margin-left: 6px;
    color: #cbd5e1;
    font-size: 0.75em;
}
.event-card.event-card-today .event-time-col { color: #1a56a7; }
.event-card.event-card-today .event-time-col::after { color: #93c5fd; }
/* 重磅事件：星标或高亮时间 */
.event-card.event-card-important .event-time-col { color: #c2410c; font-weight: 600; }
.event-card.event-card-important .event-time-col::after { color: #fdba74; }
.event-impact-star { color: #ea580c; font-size: 0.85em; margin-right: 2px; }
.event-body { flex: 1; min-width: 0; }
.event-time {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 6px;
}

.event-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: #333;
    line-height: 1.4;
    margin: 0;
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 0;
}
.event-badge-new {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    margin-right: 6px;
    margin-top: 2px;
    border-radius: 3px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    flex-shrink: 0;
}
.day-new-count {
    font-size: 0.75rem;
    color: #dc2626;
    background: #fef2f2;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
}
.day-section.has-new-events .day-header {
    border-left: 3px solid #ef4444;
    padding-left: 10px;
}
.timeline-event-item.timeline-event-new {
    border-left-color: #ef4444 !important;
    background: #fffbfb;
}

.event-sectors {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}
.event-market-verification {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid #eee;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.4;
}
.event-market-verification-link {
    color: #3b82b6;
    text-decoration: none;
}
.event-market-verification-link:hover { text-decoration: underline; }
.event-market-verification-hint {
    color: #9ca3af;
    font-size: 11px;
    margin-left: 4px;
}

.event-forecast-row {
    margin-top: 10px;
    padding: 8px 10px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 0.85rem;
    color: #555;
}
.event-forecast-row span { margin-right: 12px; }
.event-forecast-row .actual { font-weight: 600; color: #1a56a7; }
.event-related {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.event-related a {
    color: #1a56a7;
    text-decoration: none;
    font-size: 0.85rem;
    padding: 3px 10px;
    border-radius: 12px;
    background: #e3f2fd;
}
.event-related a:hover { text-decoration: underline; background: #bbdefb; }
.event-card-more {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    background: transparent;
    color: #999;
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s, color 0.2s, background 0.2s;
    opacity: 0;
}
.event-card:hover .event-card-more,
.event-card.event-card-actions-visible .event-card-more { opacity: 1; }
.event-card-more:hover { color: #1a56a7; background: #f0f0f0; }
.event-card-actions {
    display: none;
}

.sector-tag {
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.72rem;
    font-weight: 500;
}
.sector-tag-ghost {
    background: #f0f0f0;
    color: #666;
}
.sector-tag-important {
    background: #e3f2fd;
    color: #1a56a7;
}
.sector-tag-overflow {
    background: #e8e8e8;
    color: #999;
    font-size: 0.7rem;
}

.no-events {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

/* 回到今天按钮 */
.today-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, #1a56a7 0%, #144785 100%);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(26, 86, 167, 0.3);
    font-size: 0.9rem;
    font-weight: 500;
}

.today-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 86, 167, 0.4);
}

.today-button:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .calendar-page-wrap > .container {
        border-radius: 12px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    }

    .calendar-toolbar {
        padding: 8px 12px;
        gap: 8px;
    }
    .calendar-toolbar-title { font-size: 1rem; }
    .calendar-toolbar-summary { font-size: 0.72rem; line-height: 1.4; }
    .toolbar-search { width: 100%; max-width: none; }
    .filter-drawer { padding: 10px 12px; }
    .filter-drawer-row { gap: 8px; }

    .filter-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .filter-controls select,
    .filter-controls input {
        width: 100%;
        padding: 12px 15px;
        font-size: 16px; /* 防止iOS自动缩放 */
        border-radius: 3px;
        min-height: 44px; /* 触摸友好的按钮大小 */
        -webkit-appearance: none;
        appearance: none;
    }

    .filter-controls button {
        width: 100%;
        padding: 12px 20px;
        min-height: 44px;
        font-size: 16px;
        border-radius: 3px;
    }

    .event-card-more {
        opacity: 0.35;
    }

    .calendar-container {
        padding: 15px;
    }

    .calendar-pager {
        padding: 0 15px 22px;
        flex-direction: column;
        gap: 10px;
    }

    .month-section {
        margin-bottom: 25px;
    }

    .month-header {
        padding: 12px 0 10px;
        border-radius: 0;
        margin-bottom: 0;
    }

    .month-header h2 {
        font-size: 1.15rem;
    }

    .month-header .event-count {
        font-size: 0.7rem;
    }

    .month-toggle-icon {
        font-size: 0.85rem;
    }

    .day-section {
        margin-bottom: 20px;
        padding-left: 12px;
        border-left-width: 3px;
    }

    .day-section.today-day-section {
        padding: 8px 10px 12px;
    }

    .day-section::before {
        left: -6px;
        width: 10px;
        height: 10px;
        border-width: 2px;
    }

    .day-header {
        padding: 8px 10px;
        border-radius: 8px;
        margin-bottom: 10px;
        border-left-width: 3px;
        flex-wrap: nowrap;
        gap: 6px;
    }

    .day-info {
        flex: 1;
        min-width: 0;
        flex-direction: row;
        align-items: center;
        gap: 4px;
        flex-wrap: nowrap;
        overflow: hidden;
    }

    .date {
        font-size: 0.88rem;
        font-weight: 600;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .weekday,
    .day-event-count,
    .day-new-count,
    .today-indicator {
        padding: 2px 6px;
        font-size: 0.68rem;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .day-event-count {
        padding: 0;
    }

    .toggle-icon {
        flex-shrink: 0;
        margin-left: 2px;
    }

    /* 移动端月份导航按钮 */
    .month-nav-toggle {
        display: flex;
    }

    /* 移动端隐藏桌面端的 sticky 导航，使用浮动按钮 */
    .month-nav {
        display: none !important;
    }

    /* 移动端隐藏月份导航项 */
    .month-nav-items {
        display: none;
    }

    .events-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .event-card {
        padding: 10px 12px;
        border-radius: 8px;
        border-left-width: 3px;
    }

    .event-time-col {
        font-size: 0.75rem;
    }

    .event-title {
        font-size: 0.95rem;
        line-height: 1.4;
        font-weight: 600;
    }

    .event-sectors {
        gap: 4px;
        margin-top: 6px;
    }

    .sector-tag {
        padding: 3px 8px;
        font-size: 0.7rem;
        border-radius: 10px;
    }

    /* 移动端按钮布局优化 - 右侧垂直排列 */
    .export-button {
        top: 10px;
        right: 10px;
        width: 44px;
        height: 44px;
        z-index: 1001;
    }

    .export-button i {
        font-size: 1.1rem;
    }

    .analysis-button {
        top: 64px; /* 44px按钮高度 + 10px间距 + 10px顶部 = 64px */
        right: 10px;
        width: 44px;
        height: 44px;
        z-index: 1001;
    }

    .analysis-button i {
        font-size: 1.1rem;
    }

    .today-button {
        bottom: 20px;
        right: 15px;
        padding: 12px 18px;
        font-size: 0.9rem;
        border-radius: 25px;
        min-height: 44px;
        z-index: 1001;
    }

    /* 月份导航按钮位置调整，避免与底部按钮冲突 */
    .month-nav-toggle {
        bottom: 90px; /* 在"回到今天"按钮上方，留出足够间距 */
        right: 15px;
    }

    /* 优化触摸体验 */
    .month-header,
    .day-header,
    .event-card {
        -webkit-tap-highlight-color: rgba(26, 86, 167, 0.2);
    }

    /* 改善滚动体验 */
    .calendar-container {
        -webkit-overflow-scrolling: touch;
    }
}

@media (max-width: 480px) {
    body {
        padding: 8px;
    }

    .calendar-toolbar {
        padding: 6px 10px;
    }
    .calendar-toolbar-title { font-size: 0.95rem; }

    .calendar-container {
        padding: 12px;
    }

    .month-header {
        padding: 10px 0 10px;
    }

    .month-header h2 {
        font-size: 1.05rem;
    }

    .day-section {
        margin-bottom: 15px;
        padding-left: 12px;
    }

    .day-section::before {
        width: 8px;
        height: 8px;
    }

    .day-header {
        padding: 7px 8px;
        margin-bottom: 8px;
    }

    .day-info {
        gap: 3px;
    }

    .date {
        font-size: 0.82rem;
    }

    .weekday,
    .day-event-count,
    .day-new-count,
    .today-indicator {
        padding: 2px 5px;
        font-size: 0.62rem;
    }

    .month-nav-toggle {
        bottom: 70px;
        right: 12px;
        width: 50px;
        height: 50px;
    }

    .month-nav-toggle i {
        font-size: 1.3rem;
    }

    .month-nav-popup-header {
        padding: 12px 15px;
    }

    .month-nav-popup-header h3 {
        font-size: 1rem;
    }

    .month-nav-popup-content {
        padding: 12px;
    }

    .month-nav-popup-items {
        gap: 8px;
    }

    .month-nav-popup-item {
        padding: 10px 12px;
        font-size: 0.85rem;
    }

    .events-grid {
        gap: 8px;
    }

    .event-card {
        padding: 10px 12px;
    }

    .event-time-col {
        font-size: 0.75rem;
    }

    .event-title {
        font-size: 0.9rem;
        line-height: 1.35;
    }

    .event-sectors {
        gap: 3px;
        margin-top: 4px;
    }

    .sector-tag {
        padding: 2px 6px;
        font-size: 0.65rem;
        border-radius: 8px;
    }
}

/* 导出按钮样式 */
.export-button {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.export-button:hover {
    background: white;
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.export-button i {
    color: #1a56a7;
    font-size: 1.2rem;
}

/* 投资分析按钮样式 */
.analysis-button {
    position: fixed;
    top: 80px;
    right: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.3);
}

.analysis-button:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.5);
}

.analysis-button i {
    font-size: 1.2rem;
}

/* 确保移动端按钮不堆叠 */
@media (max-width: 768px) {
    .export-button,
    .analysis-button {
        position: fixed !important;
    }

    /* 确保按钮之间有足够间距 */
    .export-button {
        top: 10px !important;
        right: 10px !important;
    }

    .analysis-button {
        top: 64px !important; /* 44px按钮高度 + 10px间距 */
        right: 10px !important;
    }
}

.analysis-button.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* 模态框样式 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 15px;
    max-width: 1200px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.modal-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.modal-refresh {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 1rem;
}

.modal-refresh:hover {
    background: rgba(255, 255, 255, 0.32);
    transform: rotate(90deg);
}

.modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 1.2rem;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.modal-body {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
}

.modal-loading {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.modal-loading i {
    font-size: 3rem;
    color: #667eea;
    margin-bottom: 20px;
    animation: spin 1s linear infinite;
}

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

.modal-loading p {
    font-size: 1.1rem;
    margin-top: 15px;
}

/* 投资分析弹层：紧凑加载（替代误接的 SaAiLoading 大骨架） */
.inv-analysis-modal-body .inv-analysis-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 220px;
    padding: 48px 24px;
    color: #64748b;
}

.inv-analysis-modal-body .inv-analysis-loading > i.fa-spinner {
    display: none;
}

.inv-analysis-loading-visual {
    margin-bottom: 4px;
}

.inv-analysis-loading-ring {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #eef2ff 0%, #f5f3ff 100%);
    border: 1px solid #e0e7ff;
    box-shadow: 0 4px 14px rgba(102, 126, 234, 0.12);
}

.inv-analysis-loading-ring i {
    margin: 0 !important;
    font-size: 1.35rem !important;
    color: #667eea !important;
    animation: invAnalysisIconPulse 1.8s ease-in-out infinite;
}

.inv-analysis-loading-ring::after {
    content: '';
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    border: 2px solid rgba(102, 126, 234, 0.22);
    animation: invAnalysisRingPulse 1.8s ease-out infinite;
}

@keyframes invAnalysisIconPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.06); opacity: 0.88; }
}

@keyframes invAnalysisRingPulse {
    0% { transform: scale(0.92); opacity: 0.85; }
    100% { transform: scale(1.28); opacity: 0; }
}

.inv-analysis-modal-body .modal-loading-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 650;
    color: #1e293b;
    letter-spacing: 0.01em;
}

.inv-analysis-modal-body .modal-loading-stage {
    margin: 0;
    font-size: 0.88rem;
    font-weight: 500;
    color: #667eea;
    min-height: 1.35em;
    transition: opacity 0.2s ease;
}

.modal-error {
    text-align: center;
    padding: 40px 20px;
    color: #e74c3c;
}

.modal-error i {
    font-size: 3rem;
    margin-bottom: 15px;
}

.analysis-content {
    line-height: 1.8;
    color: #333;
}

.analysis-content h1,
.analysis-content h2,
.analysis-content h3 {
    color: #1a56a7;
    margin-top: 30px;
    margin-bottom: 15px;
}

.analysis-content h1 {
    font-size: 1.8rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 10px;
}

.analysis-content h2 {
    font-size: 1.5rem;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 8px;
}

.analysis-content h3 {
    font-size: 1.2rem;
}

.analysis-content p {
    margin-bottom: 15px;
}

.analysis-content ul,
.analysis-content ol {
    margin-left: 25px;
    margin-bottom: 15px;
}

.analysis-content li {
    margin-bottom: 8px;
}

.analysis-content strong {
    color: #667eea;
    font-weight: 600;
}

.analysis-content code {
    background: #f8f9fa;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.analysis-content pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 15px;
}

.analysis-content blockquote {
    border-left: 4px solid #667eea;
    padding-left: 15px;
    margin-left: 0;
    color: #666;
    font-style: italic;
}

.analysis-meta {
    background: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.analysis-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    font-size: 0.9rem;
}

.analysis-meta-item i {
    color: #667eea;
}

/* 未来投资分析结果页（对齐 plate_ranking AI 研判样式） */
.inv-analysis-shell {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.inv-analysis-meta-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.inv-analysis-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
    font-size: 0.82rem;
    line-height: 1.2;
}

.inv-analysis-chip i {
    color: #667eea;
    font-size: 0.78rem;
}

.inv-analysis-chip--cache {
    background: #ecfdf5;
    color: #047857;
}

.inv-analysis-chip--cache i {
    color: #059669;
}

.inv-analysis-brief {
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid #c7d2fe;
    background: linear-gradient(135deg, #eef2ff 0%, #f8fafc 100%);
    box-shadow: 0 2px 12px rgba(102, 126, 234, 0.1);
}

.inv-analysis-brief-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #4338ca;
    letter-spacing: 0.02em;
}

.inv-analysis-brief-text {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.65;
    color: #1e293b;
}

.inv-analysis-brief-from {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.75rem;
    color: #64748b;
}

.inv-analysis-content {
    padding: 4px 2px 8px;
}

.inv-analysis-markdown {
    font-size: 0.9rem;
    line-height: 1.7;
    color: #334155;
}

/* 章节标题：浅底 + 左色条（避免色条白字被 SaMarkdown 盖成黑字） */
.inv-analysis-modal-body .inv-analysis-markdown h2.inv-analysis-part,
.inv-analysis-markdown.sa-markdown > h2.inv-analysis-part,
.inv-analysis-markdown > h2.inv-analysis-part {
    position: relative;
    margin: 18px 0 12px;
    padding: 10px 14px 10px 14px;
    font-size: 0.95rem !important;
    font-weight: 700;
    line-height: 1.35;
    color: #0f172a !important;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    border-left-width: 4px;
    background: #f8fafc !important;
    box-shadow: none;
    letter-spacing: 0.01em;
}

.inv-analysis-markdown > h2.inv-analysis-part:first-child,
.inv-analysis-markdown.sa-markdown > h2.inv-analysis-part:first-child {
    margin-top: 0;
}

.inv-analysis-part--conclusion {
    border-left-color: #0f766e !important;
    background: linear-gradient(90deg, #f0fdfa 0%, #f8fafc 72%) !important;
    color: #115e59 !important;
}

.inv-analysis-part--theme {
    border-left-color: #6366f1 !important;
    background: linear-gradient(90deg, #eef2ff 0%, #f8fafc 72%) !important;
    color: #3730a3 !important;
}

.inv-analysis-part--catalyst {
    border-left-color: #7c3aed !important;
    background: linear-gradient(90deg, #f5f3ff 0%, #f8fafc 72%) !important;
    color: #5b21b6 !important;
}

.inv-analysis-part--action {
    border-left-color: #0284c7 !important;
    background: linear-gradient(90deg, #f0f9ff 0%, #f8fafc 72%) !important;
    color: #075985 !important;
}

.inv-analysis-part--risk {
    border-left-color: #dc2626 !important;
    background: linear-gradient(90deg, #fef2f2 0%, #f8fafc 72%) !important;
    color: #991b1b !important;
}

.inv-analysis-block {
    margin: 8px 0 12px;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.inv-analysis-block-title {
    margin: 0 0 8px;
    padding: 0;
    font-size: 0.9rem !important;
    font-weight: 700;
    color: #0f766e !important;
    border: none;
    background: transparent !important;
}

.inv-analysis-block--short {
    border-left: 4px solid #0891b2;
}

.inv-analysis-block--swing {
    border-left: 4px solid #6366f1;
}

.inv-analysis-block--risk {
    border-color: #fecaca;
    background: linear-gradient(180deg, #fef2f2 0%, #ffffff 45%);
}

.inv-analysis-markdown p,
.inv-analysis-markdown li {
    margin-bottom: 0.6em;
}

.inv-analysis-markdown ul,
.inv-analysis-markdown ol {
    margin: 0.4em 0 0.8em 1.2em;
    padding: 0;
}

.inv-analysis-markdown strong {
    color: #1e293b;
    font-weight: 650;
}

.inv-analysis-markdown a {
    color: #1a56a7;
    text-decoration: none;
}

.inv-analysis-markdown a:hover {
    text-decoration: underline;
}

.inv-analysis-markdown blockquote {
    margin: 10px 0;
    padding: 8px 12px;
    border-left: 4px solid #667eea;
    background: #f8fafc;
    color: #64748b;
    font-style: normal;
}

.inv-analysis-markdown .table-wrapper {
    overflow-x: auto;
    margin: 12px 0 16px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    box-shadow: none;
}

.inv-analysis-markdown table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    font-size: 0.82rem;
}

.inv-analysis-markdown table th {
    background: #f1f5f9;
    color: #334155;
    padding: 10px 12px;
    text-align: left;
    font-weight: 650;
    white-space: nowrap;
    border-bottom: 1px solid #e2e8f0;
}

.inv-analysis-markdown table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: top;
}

.inv-analysis-markdown table tbody tr:nth-child(even) td {
    background: #f8fafc;
}

.inv-analysis-markdown table tbody tr:hover td {
    background: #eef2ff;
}

.inv-analysis-disclaimer {
    margin-top: 4px;
    padding-top: 12px;
    border-top: 1px dashed #e2e8f0;
    font-size: 0.75rem;
    color: #94a3b8;
    text-align: center;
}

.modal-body.inv-analysis-modal-body {
    padding: 20px 24px 24px;
}

.modal-body.inv-analysis-modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-body.inv-analysis-modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 4px;
}

@media (max-width: 768px) {
    .analysis-button {
        top: 64px !important; /* 确保与上面的设置一致，避免堆叠 */
        right: 10px !important;
    }

    .modal-content {
        max-height: 95vh;
        margin: 10px;
        border-radius: 12px;
    }

    .modal-header {
        padding: 15px;
    }

    .modal-title {
        font-size: 1.2rem;
    }

    .modal-body {
        padding: 15px;
        max-height: calc(95vh - 120px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .analysis-content h1 {
        font-size: 1.4rem;
        margin-top: 1.2em;
        margin-bottom: 0.8em;
    }

    .analysis-content h2 {
        font-size: 1.2rem;
        margin-top: 1em;
        margin-bottom: 0.6em;
    }

    .analysis-content h3 {
        font-size: 1.1rem;
    }

    .analysis-content p {
        font-size: 0.95rem;
        line-height: 1.7;
    }

    .analysis-content ul,
    .analysis-content ol {
        padding-left: 20px;
    }

    .analysis-content li {
        margin-bottom: 0.5em;
        font-size: 0.95rem;
        line-height: 1.6;
    }

    /* 移动端隐藏桌面导航，使用浮动按钮 */
    .month-nav {
        display: none !important;
    }
}

@media (max-width: 480px) {
    .modal-content {
        margin: 5px;
        border-radius: 10px;
    }

    .modal-header {
        padding: 12px;
    }

    .modal-title {
        font-size: 1.1rem;
    }

    .modal-body {
        padding: 12px;
    }

    .analysis-content h1 {
        font-size: 1.25rem;
    }

    .analysis-content h2 {
        font-size: 1.1rem;
    }

    .month-nav-item {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
}

/* 导出预览容器 */
#exportContainer {
    position: fixed;
    left: -10000px;
    top: 0;
    width: 1080px;
    max-width: 1080px;
    z-index: -1;
    opacity: 0;
    pointer-events: none;
    background: #ffffff;
}

#exportContainer.is-exporting {
    opacity: 1;
}

#exportContainer .export-sheet {
    background: #ffffff;
    padding: 28px 32px 36px;
    box-sizing: border-box;
}

#exportContainer .export-sheet-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid #e8edf2;
}

#exportContainer .export-sheet-header h1 {
    margin: 0 0 6px;
    padding-left: 10px;
    border-left: 4px solid #1a56a7;
    font-size: 1.35rem;
    font-weight: 700;
    color: #111827;
}

#exportContainer .export-sheet-meta {
    margin: 0;
    padding-left: 14px;
    font-size: 12px;
    color: #64748b;
    line-height: 1.5;
}

#exportContainer .export-sheet-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

#exportContainer .export-legend-item {
    font-size: 11px;
    color: #64748b;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

#exportContainer .export-legend-item.impact-3 { border-color: #fecaca; color: #c2410c; background: #fff7ed; }
#exportContainer .export-legend-item.impact-2 { border-color: #fde68a; color: #b45309; background: #fffbeb; }
#exportContainer .export-legend-item.impact-1 { border-color: #e2e8f0; color: #64748b; }

#exportContainer .export-calendar-container {
    padding: 0;
}

#exportContainer .month-section {
    margin-bottom: 18px;
    break-inside: avoid;
}

#exportContainer .month-header {
    cursor: default;
    pointer-events: none;
}

#exportContainer .month-toggle-icon,
#exportContainer .toggle-icon,
#exportContainer .event-card-more,
#exportContainer .event-card-actions,
#exportContainer .event-market-verification {
    display: none !important;
}

#exportContainer .month-content,
#exportContainer .events-grid {
    max-height: none !important;
    opacity: 1 !important;
    overflow: visible !important;
    transform: none !important;
    padding: 0 !important;
}

#exportContainer .events-grid.collapsed {
    display: block !important;
}

#exportContainer .event-card {
    break-inside: avoid;
    page-break-inside: avoid;
}

#exportContainer .export-sheet-footer {
    margin-top: 20px;
    padding-top: 14px;
    border-top: 1px solid #e8edf2;
    font-size: 11px;
    color: #94a3b8;
    text-align: center;
}

/* 导出加载提示 */
.export-loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 20px 40px;
    border-radius: 10px;
    display: none;
    z-index: 1001;
}

/* 批量操作按钮样式 */
#batchOperations {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

#batchOperations .btn {
    transition: all 0.3s ease;
    font-size: 0.85rem;
    padding: 6px 12px;
}

#batchOperations .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* 月份快速导航 */
.month-nav {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 100;
    padding: 10px 12px;
    margin-bottom: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: none;
    transition: all 0.3s ease;
}

.month-nav-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
}

.month-nav-scroll-wrap {
    flex: 1;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    mask-image: linear-gradient(to right, transparent 0, #000 12px, #000 calc(100% - 12px), transparent 100%);
}

.month-nav-scroll-wrap::-webkit-scrollbar {
    display: none;
}

.month-nav-items {
    display: inline-flex;
    flex-wrap: nowrap;
    gap: 8px;
    align-items: center;
    padding: 2px 4px;
    min-width: min-content;
}

.month-nav-year-label {
    flex: 0 0 auto;
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748b;
    padding: 0 4px 0 8px;
    white-space: nowrap;
}

.month-nav-scroll-btn {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    background: #fff;
    color: #475569;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.month-nav-scroll-btn:hover:not(:disabled) {
    background: #f1f5f9;
    color: #1a56a7;
    border-color: #cbd5e1;
}

.month-nav-scroll-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.month-nav-today-btn {
    flex: 0 0 auto;
    border: none;
    border-radius: 16px;
    padding: 7px 14px;
    background: linear-gradient(135deg, #1a56a7 0%, #144785 100%);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(26, 86, 167, 0.25);
}

.month-nav-today-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 86, 167, 0.35);
}

.month-nav-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 20px;
    background: #f8f9fa;
    color: #495057;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.25s ease;
    white-space: nowrap;
    border: 2px solid transparent;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.2;
}
.month-nav-item .count {
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    background: rgba(15, 23, 42, 0.08);
    color: #334155;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    font-weight: 600;
    padding: 0 5px;
}

.month-nav-item.past {
    opacity: 0.72;
}

.month-nav-item:hover {
    background: #1a56a7;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 86, 167, 0.3);
}
.month-nav-item:hover .count,
.month-nav-item.current .count {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.month-nav-item.current {
    background: linear-gradient(135deg, #1a56a7 0%, #144785 100%);
    color: white;
    font-weight: 600;
    border-color: #1a56a7;
    box-shadow: 0 4px 12px rgba(26, 86, 167, 0.3);
    opacity: 1;
}

/* 移动端浮动月份导航按钮 */
.month-nav-toggle {
    position: fixed;
    bottom: 80px;
    right: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 50%;
    width: 56px;
    height: 56px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.month-nav-toggle:hover,
.month-nav-toggle.active {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.month-nav-toggle i {
    font-size: 1.5rem;
}

/* 移动端月份导航弹出层 */
.month-nav-popup {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    z-index: 998;
    max-height: 60vh;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: none;
    flex-direction: column;
}

.month-nav-popup.show {
    transform: translateY(0);
}

.month-nav-popup-header {
    padding: 15px 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.month-nav-popup-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: #333;
}

.month-nav-popup-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.month-nav-popup-close:hover {
    background: #f8f9fa;
    color: #1a56a7;
}

.month-nav-popup-content {
    padding: 15px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    flex: 1;
}

.month-nav-popup-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
}

.month-nav-popup-year {
    grid-column: 1 / -1;
    font-size: 0.85rem;
    font-weight: 700;
    color: #64748b;
    padding: 4px 2px 0;
}

.month-nav-popup-item {
    padding: 12px 16px;
    background: #f8f9fa;
    border-radius: 10px;
    text-align: left;
    text-decoration: none;
    color: #495057;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    cursor: pointer;
    font-family: inherit;
    width: 100%;
}
.month-nav-popup-item .count {
    min-width: 22px;
    height: 22px;
    border-radius: 11px;
    background: rgba(15, 23, 42, 0.08);
    color: #334155;
    font-size: 12px;
    line-height: 22px;
    text-align: center;
    font-weight: 600;
    padding: 0 6px;
}

.month-nav-popup-item:hover,
.month-nav-popup-item.current {
    background: #1a56a7;
    color: white;
    border-color: #1a56a7;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(26, 86, 167, 0.3);
}
.month-nav-popup-item:hover .count,
.month-nav-popup-item.current .count {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.month-nav-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 997;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.month-nav-popup-overlay.show {
    display: block;
    opacity: 1;
}

/* 事件卡片悬停增强 */
.event-card:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #1a56a7;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #144785;
}
