/* Blog styles matching sunchangsheng.com */
:root {
    /* --NUSBLUE: #003D7C; */
    /* --NUSBLUE: #000000; */
    --NUSBLUE: #003366;
}

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

body {
    /* font-family: Arial, Helvetica, sans-serif; */
    font-family: -apple-system, Helvetica, 'TeX Gyre Heros', Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    background: #fff;
    padding: 20px;
    max-width: 750px;
    margin: 0 auto;
}

/* Navigation */
.blog-nav {
    margin-bottom: 15px;
    padding-bottom: 15px;
    /* border-bottom: 2px solid var(--NUSBLUE); */
}

.blog-nav a {
    color: var(--NUSBLUE);
    text-decoration: none;
    margin-right: 20px;
    font-size: 14px;
}

.blog-nav a:hover {
    text-decoration: underline;
}

/* Post header */
.post-header {
    margin-bottom: 30px;
}

.post-header h1 {
    font-size: 24px;
    color: var(--NUSBLUE);
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.3;
}

.post-header time {
    color: #666;
    font-size: 13px;
}

/* Post content */
.post-content {
    line-height: 1.7;
}

.post-content h2 {
    font-size: 18px;
    color: var(--NUSBLUE);
    margin-top: 30px;
    margin-bottom: 15px;
    border-bottom: 1px solid #ccc;
    padding-bottom: 5px;
}

.post-content h3 {
    font-size: 16px;
    color: var(--NUSBLUE);
    margin-top: 25px;
    margin-bottom: 10px;
}

.post-content p {
    margin-bottom: 15px;
    text-align: justify;
}

.post-content a {
    color: var(--NUSBLUE);
    text-decoration: underline;
}

.post-content ul,
.post-content ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

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

/* Code blocks - simple CSS styling */
.post-content code {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 13px;
    background: #f5f5f5;
    padding: 2px 5px;
    border-radius: 3px;
}

.post-content pre {
    background: #f8f8f8;
    border: 1px solid #ddd;
    border-left: 3px solid var(--NUSBLUE);
    padding: 15px;
    margin-bottom: 20px;
    overflow-x: auto;
    line-height: 1.5;
}

.post-content pre code {
    background: none;
    padding: 0;
    font-size: 13px;
}

/* Math blocks */
.katex-display {
    margin: 20px 0;
    padding: 10px 20px;
    overflow-x: auto;
}

/* Block quotes */
.post-content blockquote {
    border-left: 3px solid var(--NUSBLUE);
    margin: 20px 0;
    padding: 10px 20px;
    background: #f9f9f9;
    color: #555;
}

/* Images */
.post-content img {
    max-width: 100%;
    height: auto;
    margin: 20px 0;
}

/* Tables */
.post-content table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 20px;
}

.post-content th,
.post-content td {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
}

.post-content th {
    background: #f5f5f5;
    color: var(--NUSBLUE);
}

/* Post footer */
.post-footer {
    margin-top: 20px;
    padding-top: 20px;
    /* border-top: 1px solid #ccc; */
}

.post-footer a {
    color: var(--NUSBLUE);
    text-decoration: none;
}

.post-footer a:hover {
    text-decoration: underline;
}

/* Site footer */
.site-footer {
    margin-top: 10px;
    padding-top: 10px;
    /* border-top: 1px solid #ccc; */
    text-align: center;
    font-size: 12px;
    color: #666;
}

/* Blog index page */
.blog-index {
    margin-top: 0;
}

.post-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.post-item {
    margin-bottom: 10px;
    padding-bottom: 10px;
    /* border-bottom: 1px solid #eee; */
}

.post-item time {
    display: block;
    color: rgba(0, 0, 0, 0.7);
    font-size: 13px;
    margin-bottom: 5px;
    margin-top: 5px;
}

.post-item a {
    color: var(--NUSBLUE);
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
}

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

.post-description {
    color: #000000;
    font-size: 13px;
    /* margin-top: 5px; */
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 15px;
    }

    .post-header h1 {
        font-size: 20px;
    }
}