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

body {
    font-family: Georgia, 'Times New Roman', serif;
    line-height: 1.7;
    color: #333;
    background: #fafafa;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

a { color: #2a5da8; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Header / Nav */
header {
    padding: 1.5rem 0;
    border-bottom: 1px solid #ddd;
    margin-bottom: 2rem;
}

nav {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.5rem 1.5rem;
}

.site-title {
    font-size: 1.4rem;
    font-weight: bold;
    color: #222;
}
.site-title:hover { text-decoration: none; }

.site-subtitle {
    font-size: 0.9rem;
    color: #777;
    flex: 1;
}

.nav-links {
    display: flex;
    gap: 1rem;
    font-size: 0.9rem;
}

/* Article List (Homepage) */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.article-card {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.teaser-image {
    width: 200px;
    height: 130px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.article-info h2 {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}

.article-info h2 a { color: #222; }
.article-info h2 a:hover { color: #2a5da8; }

.article-info time {
    font-size: 0.85rem;
    color: #888;
}

.article-info .summary {
    margin-top: 0.5rem;
    font-size: 0.95rem;
    color: #555;
}

/* Full Article */
.article-full h1 {
    font-size: 1.8rem;
    margin-bottom: 0.25rem;
}

.article-full time {
    font-size: 0.85rem;
    color: #888;
    display: block;
    margin-bottom: 0.75rem;
}

.article-header-image {
    width: 100%;
    height: auto;
    border-radius: 4px;
    margin-bottom: 1.25rem;
}

.tags {
    margin-bottom: 1.5rem;
}

.tag {
    font-size: 0.8rem;
    background: #eee;
    padding: 0.15rem 0.5rem;
    border-radius: 3px;
    margin-right: 0.4rem;
    color: #555;
}

.article-content {
    margin-top: 1.5rem;
}

.article-content p {
    margin-bottom: 1rem;
}

/* Page */
.page h1 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.page-content p {
    margin-bottom: 1rem;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

th, td {
    padding: 0.4rem 0.6rem;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
    vertical-align: top;
}

th {
    font-weight: bold;
    border-bottom: 2px solid #ccc;
}

/* Code blocks (for the ASCII header) */
pre {
    background: #f5f5f5;
    padding: 1rem;
    border-radius: 4px;
    overflow-x: auto;
    font-size: 0.8rem;
    line-height: 1.4;
    margin-bottom: 1.5rem;
}

code {
    font-size: 0.85em;
}

/* Blockquotes */
blockquote {
    border-left: 3px solid #ccc;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #555;
    font-style: italic;
}

/* Lists in page content */
.page-content ul, .page-content ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.page-content li {
    margin-bottom: 0.3rem;
}

/* Headings in page content */
.page-content h2 {
    font-size: 1.4rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.3rem;
}

.page-content h3 {
    font-size: 1.1rem;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

/* Horizontal rules */
.page-content hr {
    border: none;
    border-top: 1px solid #ddd;
    margin: 2rem 0;
}

/* Pagination */
.pagination {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
}

/* Footer */
footer {
    margin-top: 3rem;
    padding: 1.5rem 0;
    border-top: 1px solid #ddd;
    font-size: 0.85rem;
    color: #999;
    text-align: center;
}

/* Responsive */
@media (max-width: 600px) {
    .article-card {
        flex-direction: column;
    }
    .teaser-image {
        width: 100%;
        height: 200px;
    }
}
