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

:root {
    --text-color: #2c2c2c;
    --bg-color: #ffffff;
    --accent-color: #666;
    --border-color: #e0e0e0;
    --link-color: #2c2c2c;
    --link-hover: #000;
}

@media (prefers-color-scheme: dark) {
    :root {
        --text-color: #e0e0e0;
        --bg-color: #1a1a1a;
        --accent-color: #999;
        --border-color: #333;
        --link-color: #e0e0e0;
        --link-hover: #fff;
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    border-bottom: 1px solid var(--border-color);
    padding: 2rem 0;
}

nav {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--text-color);
}

nav a:not(.logo) {
    text-decoration: none;
    color: var(--text-color);
    font-size: 0.95rem;
    transition: color 0.2s;
}

nav a:not(.logo):hover {
    color: var(--link-hover);
}

main {
    flex: 1;
    padding: 4rem 0;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

h1 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 3rem;
    color: var(--text-color);
}

.posts {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.post-card {
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.post-card:last-child {
    border-bottom: none;
}

.post-card time {
    display: block;
    font-size: 0.9rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
}

.post-card h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.post-card h2 a {
    text-decoration: none;
    color: var(--link-color);
    transition: color 0.2s;
}

.post-card h2 a:hover {
    color: var(--link-hover);
}

.post-card p {
    color: var(--accent-color);
    line-height: 1.7;
}

/* Post page styles */
.post-header {
    margin-bottom: 3rem;
}

.post-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.post-header time {
    color: var(--accent-color);
    font-size: 1rem;
}

.post-content {
    max-width: 700px;
}

.post-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.post-content h2 {
    font-size: 1.75rem;
    margin-top: 3rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.post-content h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

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

.post-content a:hover {
    color: var(--link-hover);
}

.post-content code {
    background-color: var(--border-color);
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-size: 0.9em;
}

.post-content pre {
    background-color: var(--border-color);
    padding: 1rem;
    border-radius: 5px;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.post-content pre code {
    background: none;
    padding: 0;
}

.back-link {
    display: inline-block;
    margin-bottom: 2rem;
    color: var(--accent-color);
    text-decoration: none;
    font-size: 0.9rem;
}

.back-link:hover {
    color: var(--link-color);
}

footer {
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    margin-top: 4rem;
    text-align: center;
    color: var(--accent-color);
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    .container {
        padding: 0 1.5rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    .post-card h2 {
        font-size: 1.25rem;
    }
    
    .post-header h1 {
        font-size: 2rem;
    }
}

