/* News Daily — style.css */
/* Design Ref: §5 — 모바일 퍼스트, 시스템 폰트, 뉴스레터 스타일 */

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #fafafa;
    padding: 16px;
}

/* Layout */
header, main, footer {
    max-width: 720px;
    margin: 0 auto;
}

/* Header */
header {
    padding: 24px 0 16px;
    border-bottom: 2px solid #333;
    margin-bottom: 24px;
}

header h1 {
    font-size: 1.8em;
    font-weight: 700;
    letter-spacing: -0.02em;
}

header .date {
    color: #666;
    font-size: 0.95em;
    margin-top: 4px;
}

header .summary {
    color: #888;
    font-size: 0.85em;
    margin-top: 2px;
}

header nav {
    margin-top: 8px;
}

header nav a {
    color: #0066cc;
    text-decoration: none;
    font-size: 0.85em;
}

header nav a:hover {
    text-decoration: underline;
}

/* Category Section */
.category {
    margin-bottom: 32px;
}

.category h2 {
    font-size: 1.1em;
    font-weight: 600;
    color: #555;
    padding: 8px 0;
    border-top: 2px solid #eee;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* News Item */
.news-item {
    padding: 12px 16px;
    margin-bottom: 12px;
    background: #fff;
    border-radius: 4px;
}

/* Rating-based left border — Design Ref: §5.2 */
.news-item.rating-3 {
    border-left: 4px solid #e74c3c;
}

.news-item.rating-2 {
    border-left: 4px solid #f39c12;
}

.news-item.rating-1 {
    border-left: 4px solid #95a5a6;
}

.news-item .rating {
    font-size: 0.8em;
    margin-bottom: 4px;
}

.news-item h3 {
    font-size: 1em;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 4px;
}

.news-item h3 a {
    color: #1a1a1a;
    text-decoration: none;
}

.news-item h3 a:hover {
    color: #0066cc;
    text-decoration: underline;
}

/* Copy Button */
.copy-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    background: none;
    color: #aaa;
    cursor: pointer;
    border-radius: 4px;
    vertical-align: middle;
    margin-left: 4px;
    transition: color 0.2s, background 0.2s;
}

.copy-btn:hover {
    color: #0066cc;
    background: #f0f0f0;
}

.copy-btn.copied {
    color: #27ae60;
}

.copy-btn.copied svg {
    display: none;
}

.copy-btn.copied::after {
    content: "\2713";
    font-size: 14px;
    font-weight: 700;
}

.news-item .original-title {
    color: #888;
    font-size: 0.85em;
    margin-bottom: 6px;
    font-style: italic;
}

.news-item .summary {
    font-size: 0.9em;
    color: #444;
    margin-bottom: 8px;
}

.news-item .meta {
    font-size: 0.8em;
    color: #999;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.news-item .meta a {
    color: #0066cc;
    text-decoration: none;
}

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

/* Archive List */
.archive-list {
    list-style: none;
}

.archive-list li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.archive-list a {
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.archive-list a:hover {
    text-decoration: underline;
}

.archive-list .count {
    color: #999;
    font-size: 0.85em;
}

/* Footer */
footer {
    margin-top: 48px;
    padding: 16px 0;
    border-top: 1px solid #eee;
    font-size: 0.8em;
    color: #aaa;
    text-align: center;
}

footer .disclaimer {
    margin-top: 4px;
    font-style: italic;
}

/* Topic Tabs — Home page navigation */
.topic-tabs {
    max-width: 720px;
    margin: 0 auto 24px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.topic-tabs .tab {
    display: inline-block;
    padding: 8px 20px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 500;
    transition: background 0.2s, border-color 0.2s;
}

.topic-tabs .tab:hover {
    background: #0066cc;
    border-color: #0066cc;
    color: #fff;
}

/* Topic Card — Home page summary */
.topic-card {
    max-width: 720px;
    margin: 0 auto 16px;
    padding: 20px;
    background: #fff;
    border-radius: 4px;
    border-left: 4px solid #0066cc;
}

.topic-card h2 {
    font-size: 1.2em;
    margin-bottom: 4px;
}

.topic-card h2 a {
    color: #1a1a1a;
    text-decoration: none;
}

.topic-card h2 a:hover {
    color: #0066cc;
}

.topic-card .date {
    color: #888;
    font-size: 0.85em;
}

.topic-card .count {
    color: #666;
    font-size: 0.9em;
    margin-top: 4px;
}

.topic-card .read-more {
    display: inline-block;
    margin-top: 8px;
    color: #0066cc;
    text-decoration: none;
    font-size: 0.85em;
}

.topic-card .read-more:hover {
    text-decoration: underline;
}

/* Header nav spacing for multiple links */
header nav a + a {
    margin-left: 12px;
}

/* Desktop — Design Ref: §5.1 모바일 퍼스트 */
@media (min-width: 768px) {
    body {
        padding: 32px;
    }

    header h1 {
        font-size: 2.2em;
    }

    .news-item {
        padding: 16px 20px;
    }
}
