/* ---- WRITING PAGES (shared across writing.html + blog/*.html) ---- */

/* Page container — used on writing.html and blog posts */
.writing-page {
    max-width: 680px;
    margin: 0 auto;
    padding: 3rem 2rem 4rem;
    line-height: 1.8;
}

/* ---- WRITING INDEX (writing.html) ---- */

.writing-page h1 {
    margin-bottom: 0.3rem;
}

.page-intro {
    font-size: 0.88rem;
    color: var(--muted);
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--light);
    line-height: 1.7;
}

.post-list {
    list-style: none;
}

.post-entry {
    display: flex;
    align-items: baseline;
    gap: 0.8rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

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

.post-entry::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 2px;
    background: var(--zone-writing);
    flex-shrink: 0;
    vertical-align: middle;
    opacity: 0.7;
}

.post-date {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.7rem;
    color: var(--muted);
    letter-spacing: 0.02em;
    flex-shrink: 0;
    white-space: nowrap;
}

.post-title {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
    flex-shrink: 0;
}

.post-title:hover {
    color: var(--muted);
}

.post-desc {
    font-size: 0.78rem;
    color: var(--muted);
    line-height: 1.5;
    display: none;
}

.post-tag {
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 0.6rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    margin-left: auto;
}

@media (max-width: 600px) {
    .post-entry {
        flex-wrap: wrap;
    }
    .post-tag {
        margin-left: 0;
        flex-basis: 100%;
        padding-left: 1.6rem;
    }
}

.upcoming {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--light);
}

.upcoming h2 {
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

.upcoming-item {
    font-size: 0.82rem;
    color: var(--muted);
    padding: 0.4rem 0;
}

/* ---- BLOG POST ---- */

.post-meta {
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 0.72rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.5rem;
}

.writing-page .post-header h1 {
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.post-subtitle {
    font-size: 0.88rem;
    color: var(--muted);
    font-weight: 400;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--light);
    line-height: 1.7;
}

.writing-page article h2 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-top: 2.5rem;
    margin-bottom: 0.8rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--light);
}

.writing-page article h2:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.writing-page article p {
    margin-bottom: 1rem;
    font-size: 0.92rem;
}

.label {
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.4rem;
}

.writing-page .callout {
    border-left: 3px solid var(--zone-writing);
    padding: 0.8rem 1.2rem;
    margin: 1.5rem 0;
    background: var(--bg-light);
    font-size: 0.88rem;
}

.callout p {
    margin-bottom: 0;
}

/* Post navigation (prev/next) */
.post-nav {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--light);
    font-size: 0.78rem;
}

.post-nav a {
    color: var(--muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.post-nav a:hover {
    color: var(--text);
}

.post-nav .nav-prev::before {
    content: '\2190  ';
}

.post-nav .nav-next::after {
    content: '  \2192';
}

.post-nav .nav-disabled {
    color: #ccc;
}

/* Post footer */
.post-footer {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--light);
    font-size: 0.8rem;
    color: var(--muted);
}

.post-footer a {
    color: var(--text);
    text-decoration: none;
    border-bottom: 1px solid #ccc;
}

.post-footer a:hover {
    border-color: var(--text);
}

/* Writing featured title accent */
.writing-featured-title::before {
    color: var(--zone-writing);
}

/* ---- RESPONSIVE ---- */
@media (max-width: 600px) {
    .writing-page {
        padding: 2rem 1.2rem 3rem;
    }
}
