/* CATARC 汽车早报样式 - 紧凑版 */

:root {
    --primary-color: #1e40af;
    --primary-light: #3b82f6;
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-color: #f5f7fa;
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
    --success-color: #059669;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans SC', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    font-size: 15px;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 16px;
}

/* 头部 */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: white;
    padding: 24px 0;
    margin-bottom: 16px;
}

.logo {
    text-align: center;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.tagline {
    font-size: 0.9rem;
    opacity: 0.9;
}

.nav {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 6px 16px;
    border-radius: 16px;
    font-size: 0.9rem;
    transition: background-color 0.2s;
}

.nav-link:hover,
.nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
}

/* 主要内容 */
.main {
    background: var(--card-bg);
    padding: 20px 24px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.section {
    animation: fadeIn 0.3s ease;
}

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

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.section-header h2 {
    font-size: 1.3rem;
    font-weight: 600;
}

.update-time {
    color: var(--text-light);
    font-size: 0.85rem;
}

/* 简报标题 */
.brief-title {
    text-align: center;
    color: var(--primary-color);
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

/* 分类标题 */
.category-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 20px 0 12px;
    padding: 8px 12px;
    background: #f0f4f8;
    border-radius: 6px;
    border-left: 3px solid var(--primary-color);
}

.category-title h3 {
    font-size: 1rem;
    color: var(--primary-color);
    font-weight: 600;
    margin: 0;
}

.category-title span {
    color: var(--text-light);
    font-size: 0.85rem;
}

/* 新闻卡片 */
.news-item {
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

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

.news-title {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-color);
    margin-bottom: 6px;
    line-height: 1.5;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.news-title .index {
    color: var(--text-light);
    font-weight: 500;
    min-width: 20px;
}

.news-title .location {
    background: var(--bg-color);
    color: var(--text-light);
    font-size: 0.75rem;
    padding: 1px 6px;
    border-radius: 3px;
    font-weight: 500;
}

.news-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.news-title a:hover {
    text-decoration: underline;
}

.news-meta {
    display: flex;
    gap: 12px;
    margin-top: 4px;
}

.news-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-light);
    font-size: 0.8rem;
}

.news-summary {
    color: var(--text-color);
    margin: 8px 0;
    padding-left: 26px;
    line-height: 1.6;
    font-size: 0.9rem;
    color: var(--text-light);
}

.news-source {
    padding-left: 26px;
    color: var(--text-light);
    font-size: 0.8rem;
}

.news-source a {
    color: var(--primary-light);
    text-decoration: none;
}

.news-source a:hover {
    text-decoration: underline;
}

/* 统计信息 */
.stats-box {
    text-align: center;
    padding: 12px;
    margin-top: 20px;
    background: #f0fdf4;
    border-radius: 6px;
    border: 1px solid #bbf7d0;
}

.stats-box .stats-text {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--success-color);
}

/* 历史列表 */
.history-list {
    display: grid;
    gap: 8px;
}

.history-item {
    background: var(--card-bg);
    padding: 12px 16px;
    border-radius: 6px;
    cursor: pointer;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
}

.history-item:hover {
    border-color: var(--primary-light);
}

.history-item .date {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 4px;
    font-size: 0.95rem;
}

.history-item .preview {
    color: var(--text-light);
    font-size: 0.85rem;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 40px 20px;
}

.empty-state .icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.empty-state .title {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.empty-state .desc {
    color: var(--text-light);
    font-size: 0.85rem;
}

/* 页脚 */
.footer {
    text-align: center;
    padding: 20px;
    color: var(--text-light);
    font-size: 0.85rem;
}

/* 响应式 */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    
    .container {
        padding: 0 12px;
    }
    
    .header {
        padding: 20px 0;
    }
    
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .main {
        padding: 16px;
    }
    
    .news-summary {
        padding-left: 0;
    }
    
    .news-source {
        padding-left: 0;
    }
}
