/* Blog pages */
.nav-links a.is-active {
    color: var(--color-accent);
}

.blog-page {
    padding: 7rem 1.5rem 4rem;
    min-height: 100vh;
}

.blog-header {
    max-width: var(--max-width);
    margin: 0 auto 3rem;
    position: relative;
}

.blog-header::before {
    content: '';
    position: absolute;
    top: -6rem;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--color-accent-dim) 0%, transparent 70%);
    pointer-events: none;
}

.posts-grid {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    gap: 1.25rem;
}

.post-card {
    display: block;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
}

.post-card-body {
    padding: 2rem;
}

.post-card-image {
    width: 100%;
    aspect-ratio: 32 / 9;
    object-fit: cover;
    object-position: top center;
    display: block;
    border-bottom: 1px solid var(--color-border);
    transition: aspect-ratio 0.35s ease;
}

.post-card:hover .post-card-image {
    aspect-ratio: 80 / 27;
}

.post-card--has-image .post-card-body {
    padding-top: 1.5rem;
}

.post-card:hover {
    border-color: rgba(201, 169, 110, 0.3);
    transform: translateY(-2px);
}

.post-card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
}

.post-card-date {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.post-card-topic {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    padding: 0.25rem 0.65rem;
    border: 1px solid var(--color-border);
    border-radius: 100px;
}

.post-card h2 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
    line-height: 1.3;
    transition: color 0.2s;
}

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

.post-card-excerpt {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    line-height: 1.8;
}

.post-card-read {
    display: inline-block;
    margin-top: 1.25rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-accent);
}

.load-sentinel {
    height: 1px;
}

.load-status {
    max-width: var(--max-width);
    margin: 2rem auto 0;
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.load-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-top-color: var(--color-accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 0.5rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Single post */
.post-single {
    padding: 7rem 1.5rem 4rem;
}

.post-single-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

.post-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 2.5rem;
    transition: color 0.2s;
}

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

.post-back svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.post-single-header {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--color-border);
}

.post-single-featured {
    width: 100%;
    border-radius: 12px;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    margin-bottom: 2rem;
    border: 1px solid var(--color-border);
}

.post-single-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
}

.post-listen-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.5rem 0.9rem;
    border: 1px solid rgba(201, 169, 110, 0.35);
    border-radius: 100px;
    background: rgba(201, 169, 110, 0.08);
    color: var(--color-accent);
    font: inherit;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.post-listen-btn:hover {
    border-color: var(--color-accent);
    background: rgba(201, 169, 110, 0.16);
}

.post-listen-btn.is-playing,
.post-listen-btn.is-paused {
    border-color: var(--color-accent);
    background: rgba(201, 169, 110, 0.18);
}

.post-listen-icon {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

.post-listen-btn.is-playing .post-listen-icon {
    animation: post-listen-pulse 1.2s ease-in-out infinite;
}

@keyframes post-listen-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}

.post-single-date {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.post-single-topic {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
}

.post-single h1 {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin-bottom: 1rem;
}

.post-single-lead {
    color: var(--color-text-muted);
    font-size: 1.1rem;
    line-height: 1.8;
}

.post-content {
    color: var(--color-text-muted);
    font-size: 1.05rem;
    line-height: 1.85;
}

.post-content p {
    margin-bottom: 1.25rem;
}

.post-content h2 {
    font-family: var(--font-serif);
    color: var(--color-text);
    font-size: 1.5rem;
    font-weight: 700;
    margin: 2.5rem 0 1rem;
    letter-spacing: -0.02em;
}

.post-content h3 {
    color: var(--color-text);
    font-size: 1.15rem;
    font-weight: 600;
    margin: 2rem 0 0.75rem;
}

.post-content ul,
.post-content ol {
    margin: 0 0 1.25rem 1.5rem;
}

.post-content li {
    margin-bottom: 0.5rem;
}

.post-content strong {
    color: var(--color-text);
    font-weight: 600;
}

.post-content blockquote {
    margin: 2rem 0;
    padding: 1.5rem 2rem;
    background: var(--color-surface);
    border-left: 3px solid var(--color-accent);
    border-radius: 0 12px 12px 0;
    font-style: italic;
}

.post-content a {
    color: var(--color-accent);
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.post-content a:hover {
    text-decoration: none;
}

.post-content::after {
    content: '';
    display: table;
    clear: both;
}

.post-content .post-image {
    margin: 0 0 1.5rem;
    max-width: 100%;
}

.post-content .post-image img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.post-content .post-image--small {
    width: 25%;
    min-width: 140px;
}

.post-content .post-image--medium {
    width: 50%;
    min-width: 220px;
}

.post-content .post-image--large {
    width: 75%;
}

.post-content .post-image--full {
    width: 100%;
}

.post-content .post-image--left {
    float: left;
    margin-right: 1.5rem;
}

.post-content .post-image--right {
    float: right;
    margin-left: 1.5rem;
}

.post-content .post-image--center {
    margin-left: auto;
    margin-right: auto;
    clear: both;
}

@media (max-width: 768px) {
    .post-content .post-image--small,
    .post-content .post-image--medium,
    .post-content .post-image--large {
        width: 100%;
        min-width: 0;
        float: none;
        margin-left: 0;
        margin-right: 0;
    }

    .blog-page,
    .post-single {
        padding-top: 6rem;
    }
}
