:root {
    --bg-color: #f9fafe;
    --card-bg: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #666;
    --accent: #2563eb;
    --border: #e5e7eb;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    margin: 0;
    color: var(--text-primary);
}

.app-header {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--accent);
}

.search-bar input {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    width: 300px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.article-card {
    background: var(--card-bg);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.2s;
    cursor: pointer;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.article-image {
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: #eee;
}

.article-content {
    padding: 1.5rem;
}

.article-meta {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    gap: 0.5rem;
}

.source-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
}

.article-card h3 {
    margin: 0.5rem 0;
    font-size: 1.25rem;
    line-height: 1.4;
}

.article-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.hidden {
    display: none;
}

.modal-content {
    background: var(--card-bg);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem;
    border-radius: 1rem;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    cursor: pointer;
}

.read-more-btn {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    margin-top: 1rem;
}

.loading-state {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}
