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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}

header nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
}

header nav a {
    text-decoration: none;
    color: #333;
}

header nav a:hover {
    color: #0066cc;
}

.hero {
    text-align: center;
    padding: 60px 0;
}

.hero .tagline {
    font-size: 2rem;
    font-style: italic;
    color: #555;
}

.posts {
    padding: 40px 0;
}

.posts h3 {
    margin-bottom: 20px;
    border-bottom: 2px solid #333;
    padding-bottom: 10px;
}

article {
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}

article h4 a {
    color: #333;
    text-decoration: none;
}

article h4 a:hover {
    color: #0066cc;
}

article time {
    color: #666;
    font-size: 0.9rem;
}

article p {
    margin-top: 10px;
}

footer {
    text-align: center;
    padding: 40px 0;
    color: #666;
    border-top: 1px solid #eee;
    margin-top: 40px;
}

/* Post Content */
.post-content {
    padding: 40px 0;
}

.post-cover {
    margin: 30px 0;
}

.post-cover img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 4px;
}

.post-cover figcaption {
    text-align: center;
    color: #666;
    font-size: 0.85rem;
    margin-top: 10px;
    font-style: italic;
}

.post-content h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.post-content time {
    color: #666;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 30px;
}

.post-content p {
    margin-bottom: 20px;
}

.post-content h3 {
    margin-top: 40px;
    margin-bottom: 20px;
    font-size: 1.3rem;
}

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

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

/* Career Page */
.career-page h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.career-intro {
    color: #666;
    margin-bottom: 40px;
}

.timeline {
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #eee;
}

.timeline-item {
    position: relative;
    padding-bottom: 30px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -34px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #333;
}

.timeline-date {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 5px;
}

.timeline-content h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.timeline-role {
    color: #666;
    margin-bottom: 5px;
}

/* Series Navigation */
.series-nav {
    background: #f9f9f9;
    border: 1px solid #e1e4e8;
    border-radius: 4px;
    padding: 12px 20px;
    margin: 20px 0;
    font-size: 0.9rem;
    line-height: 1.8;
}

.series-nav strong {
    font-size: 0.85rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.series-nav a {
    color: #0066cc;
    text-decoration: none;
}

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

.series-nav .current {
    color: #333;
    font-weight: 600;
}

/* Value Proposition */
.post-content .value-prop {
    background: #f0f7ff;
    border-left: 4px solid #0066cc;
    padding: 16px 20px;
    margin: 20px 0 30px;
    font-size: 0.95rem;
    line-height: 1.7;
    color: #2c3e50;
}

.post-content .value-prop strong {
    color: #0066cc;
}

/* Code Blocks */
.post-content pre {
    background: #f6f8fa;
    border: 1px solid #e1e4e8;
    border-radius: 4px;
    padding: 16px;
    overflow-x: auto;
    margin-bottom: 20px;
    line-height: 1.5;
}

.post-content pre code {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.875rem;
    color: #24292e;
    background: none;
    padding: 0;
}

.post-content code {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.875rem;
    background: #f6f8fa;
    padding: 2px 6px;
    border-radius: 3px;
}

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

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

.post-content th {
    background: #f6f8fa;
    font-weight: 600;
}

.post-content tr:nth-child(even) {
    background: #f9f9f9;
}

/* ASCII diagrams */
.post-content pre.diagram {
    background: #fff;
    border: 1px solid #e1e4e8;
    font-size: 0.8rem;
    line-height: 1.4;
}

/* Sidebar TOC */
.toc {
    position: fixed;
    top: 80px;
    right: calc((100vw - 800px) / 2 - 260px);
    width: 220px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    font-size: 0.8rem;
    line-height: 1.5;
    border-left: 2px solid #eee;
    padding-left: 12px;
}

.toc-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.toc a {
    display: block;
    color: #999;
    text-decoration: none;
    padding: 3px 0;
    transition: color 0.15s;
}

.toc a:hover {
    color: #333;
}

.toc a.active {
    color: #333;
    font-weight: 500;
    border-left: 2px solid #333;
    margin-left: -13px;
    padding-left: 11px;
}

/* Hide TOC on narrow screens */
@media (max-width: 1100px) {
    .toc {
        display: none;
    }
}

/* Language Switcher */
.lang-switch {
    font-size: 0.85rem;
    text-align: right;
    padding: 8px 0 0;
    white-space: nowrap;
}

.lang-switch a {
    color: #999;
    text-decoration: none;
}

.lang-switch a:hover {
    color: #0066cc;
}

.lang-switch .lang-current {
    color: #333;
    font-weight: 600;
}
