/* ==========================================================================
   J. Gresham Machen Bibliography - Scholarly Archive Design
   ========================================================================== */

/* --- CSS Variables --- */
:root {
    /* Color palette - aged paper with strong contrast */
    --cream: #f5f2ec;
    --cream-dark: #e8e3d9;
    --parchment: #faf8f5;
    --ink: #1a1612;
    --ink-light: #3d362e;
    --ink-faded: #5c554b;
    --burgundy: #6b2830;
    --burgundy-dark: #4d1c22;
    --burgundy-light: #8b3d47;
    --gold: #9a7209;
    --gold-muted: #a8864a;
    --rule-color: #cdc6b8;
    --rule-dark: #a69e8e;

    /* Typography */
    --font-display: 'Playfair Display', 'Georgia', serif;
    --font-body: 'Source Serif 4', 'Georgia', serif;
    --font-ui: 'Libre Franklin', 'Helvetica Neue', sans-serif;

    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 5rem;
}

/* --- Base Styles --- */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    font-size: 20px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    color: var(--ink);
    line-height: 1.7;
    background: var(--cream);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--ink);
    line-height: 1.25;
    margin: 0 0 var(--space-md) 0;
    letter-spacing: -0.01em;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 1.875rem; }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }
h5 { font-size: 1rem; font-weight: 700; }
h6 { font-size: 0.875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }

p {
    font-size: 1rem;
    line-height: 1.8;
    margin: 0 0 var(--space-md) 0;
}

/* --- Links --- */
a {
    color: var(--burgundy);
    text-decoration: none;
    transition: color 0.2s ease, border-color 0.2s ease;
}

a:hover {
    color: var(--burgundy-dark);
}

/* Underline effect for body text links */
.markdown a,
.post a:not(.title) {
    border-bottom: 1px solid var(--gold-muted);
    padding-bottom: 1px;
}

.markdown a:hover,
.post a:not(.title):hover {
    border-bottom-color: var(--burgundy);
}

/* --- Selection --- */
::selection {
    background: var(--gold-muted);
    color: var(--ink);
}

::-moz-selection {
    background: var(--gold-muted);
    color: var(--ink);
}

/* --- Layout --- */
.wrapper {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.container {
    margin-top: var(--space-xl);
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Header --- */
.header {
    padding: var(--space-lg) 0;
    border-bottom: 1px solid var(--rule-color);
    margin-bottom: var(--space-lg);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-sm);
}

.site-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--ink);
    margin: 0;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.site-title a {
    color: inherit;
    border: none;
}

.site-title a:hover {
    color: var(--burgundy);
}

.site-subtitle {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--ink-faded);
    margin: 0 0 var(--space-md) 0;
    line-height: 1.5;
    font-style: italic;
}

/* Social icons in header */
.header nav.social {
    margin: 0;
    padding: 0;
    border: none;
}

.header nav.social ul {
    display: flex;
    gap: var(--space-sm);
    margin: 0;
    padding: 0;
}

.header nav.social svg {
    width: 18px;
    height: 18px;
    stroke: var(--ink-faded);
    transition: stroke 0.2s ease;
}

.header nav.social a:hover svg {
    stroke: var(--burgundy);
}

/* --- Main Navigation --- */
.nav-main {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: var(--space-sm) var(--space-xl);
    padding-top: var(--space-md);
    border-top: 1px solid var(--rule-color);
}

.nav-group {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.nav-label {
    font-family: var(--font-ui);
    font-size: 0.55rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink-faded);
    padding: 0.2rem 0.5rem;
    background: var(--cream-dark);
    border-radius: 2px;
    white-space: nowrap;
}

.nav-main a {
    font-family: var(--font-ui);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--ink-light);
    padding: 0.15rem 0;
    border-bottom: 1px solid transparent;
    transition: all 0.15s ease;
}

.nav-main a:hover {
    color: var(--burgundy);
}

.nav-main a.active {
    color: var(--burgundy);
    font-weight: 500;
    border-bottom-color: var(--burgundy);
}

.nav-group-secondary .nav-label {
    background: transparent;
    border: 1px solid var(--rule-color);
    color: var(--ink-faded);
}

/* --- Lists --- */
ul {
    padding-left: var(--space-lg);
    margin: 0 0 var(--space-md) 0;
}

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

ul.flat li {
    display: inline-block;
    list-style: none;
    margin-left: 0;
}

ul {
    list-style: none;
}

/* Custom bullet for markdown content lists only */
.markdown ul > li::before {
    content: '◆';
    color: var(--gold-muted);
    font-size: 0.5em;
    display: inline-block;
    width: 1.5em;
    margin-left: -1.5em;
    vertical-align: middle;
}

.markdown ul {
    padding-left: var(--space-lg);
}

.prevent-collapse {
    min-height: 0.1rem;
}

/* --- Page Titles --- */
.page-title {
    font-family: var(--font-display);
    font-size: 2rem;
    margin: 0 0 var(--space-lg) 0;
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--rule-color);
}

/* --- Posts List --- */
.list .posts,
.recent-posts .posts {
    list-style: none;
    padding: 0;
    margin: 0;
}

.list .posts .post,
.recent-posts .posts .post {
    margin-bottom: 0;
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--rule-color);
    display: flex;
    flex-wrap: nowrap;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-md);
    animation: slideIn 0.3s ease-out;
    animation-fill-mode: both;
}

/* --- Post Indicators (icons + meta grouped on right) --- */
.post-indicators {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}

.post-indicators svg {
    width: 14px;
    height: 14px;
    stroke: var(--ink-faded);
    stroke-width: 2;
    flex-shrink: 0;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.list .posts .post:nth-child(1) { animation-delay: 0.05s; }
.list .posts .post:nth-child(2) { animation-delay: 0.1s; }
.list .posts .post:nth-child(3) { animation-delay: 0.15s; }
.list .posts .post:nth-child(4) { animation-delay: 0.2s; }
.list .posts .post:nth-child(5) { animation-delay: 0.25s; }
.list .posts .post:nth-child(6) { animation-delay: 0.3s; }
.list .posts .post:nth-child(7) { animation-delay: 0.35s; }
.list .posts .post:nth-child(8) { animation-delay: 0.4s; }
.list .posts .post:nth-child(9) { animation-delay: 0.45s; }
.list .posts .post:nth-child(10) { animation-delay: 0.5s; }

.list .posts .post:last-child,
.recent-posts .posts .post:last-child {
    border-bottom: none;
}

.list .posts .post a.title,
.recent-posts .posts .post a.title {
    flex: 1;
    min-width: 200px;
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--ink);
    line-height: 1.4;
}

.list .posts .post a.title:hover,
.recent-posts .posts .post a.title:hover {
    color: var(--burgundy);
}

.list .posts .post .meta,
.recent-posts .posts .post .meta {
    font-family: var(--font-ui);
    font-size: 0.8rem;
    color: var(--ink-faded);
    margin: 0;
    white-space: nowrap;
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.list .posts .post .meta a {
    color: var(--ink-faded);
}

.list .posts .post .meta a:hover {
    color: var(--burgundy);
}

/* --- Single Post --- */
.post .post-header {
    margin-bottom: var(--space-xl);
    padding-bottom: var(--space-lg);
    border-bottom: 1px solid var(--rule-color);
}

.post .post-header .title,
.item-title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 600;
    margin: 0 0 var(--space-md) 0;
    line-height: 1.3;
    color: var(--ink);
}

/* Remove the triangle marker */
.item-title::before,
h2.item-title::before {
    content: none;
}

/* Linked item titles */
.item-title a {
    color: inherit;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.item-title a:hover {
    color: var(--burgundy);
    border-bottom-color: var(--burgundy);
}

.post .post-header .meta {
    font-family: var(--font-ui);
    font-size: 0.85rem;
    color: var(--ink-faded);
    padding-left: 0;
    margin-top: var(--space-sm);
    line-height: 1.8;
}

/* Styled metadata labels */
.post .post-header .meta-label {
    color: var(--ink-light);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    margin-right: var(--space-xs);
}

.post .post-header .meta-value {
    color: var(--ink);
}

.post .post-header .meta a {
    color: var(--ink-light);
    border-bottom: 1px dotted var(--rule-dark);
}

.post .post-header .meta a:hover {
    color: var(--burgundy);
    border-bottom-color: var(--burgundy);
}

/* --- Markdown Content --- */
.markdown {
    font-size: 1rem;
    line-height: 1.85;
}

.markdown h3,
.markdown h4,
.markdown h5 {
    margin-top: var(--space-xl);
    margin-bottom: var(--space-md);
    color: var(--burgundy-dark);
}

.markdown h3 {
    font-size: 1.375rem;
    padding-bottom: var(--space-sm);
    border-bottom: 1px solid var(--rule-color);
}

.markdown h5 {
    font-family: var(--font-ui);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink-light);
}

.markdown img {
    max-width: 100%;
    height: auto;
    margin: var(--space-lg) 0;
    border: 1px solid var(--rule-color);
    box-shadow: 4px 4px 0 var(--cream-dark);
}

.markdown img[style*="float: right"] {
    margin: 0 0 var(--space-md) var(--space-lg);
    max-width: 200px;
}

.post ul li {
    margin-bottom: var(--space-xs);
}

.post ul li p {
    display: inline;
}

/* --- Blockquotes --- */
blockquote {
    margin: var(--space-lg) 0;
    padding: var(--space-md) var(--space-lg);
    font-style: italic;
    font-size: 1rem;
    font-family: var(--font-body);
    color: var(--ink-light);
    border-left: 4px solid var(--burgundy);
    background: linear-gradient(135deg, var(--parchment) 0%, var(--cream) 100%);
    position: relative;
}

blockquote::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 15px;
    font-family: var(--font-display);
    font-size: 4rem;
    color: var(--gold-muted);
    opacity: 0.3;
    line-height: 1;
}

blockquote p {
    margin: 0;
}

blockquote p + p {
    margin-top: var(--space-md);
}

blockquote cite {
    font-size: 0.85rem;
    opacity: 0.8;
    display: block;
    margin-top: var(--space-sm);
    font-style: normal;
}

/* --- Horizontal Rules --- */
hr {
    display: block;
    height: auto;
    border: 0;
    margin: var(--space-xl) auto;
    padding: 0;
    text-align: center;
}

hr::before {
    content: '◆ ◆ ◆';
    color: var(--gold-muted);
    font-size: 0.6rem;
    letter-spacing: 1em;
}

/* --- Code & Highlights --- */
.highlight pre {
    margin: var(--space-md) 0;
    padding: var(--space-lg);
    background-color: var(--parchment) !important;
    border: 1px solid var(--rule-color);
    overflow-x: auto;
    font-size: 0.875rem;
}

.highlight {
    background: none;
}

code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 0.875em;
    background: var(--cream-dark);
    padding: 0.1em 0.3em;
    border-radius: 2px;
}

/* --- Footer --- */
.footer {
    text-align: center;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: var(--ink-faded);
    border-top: 2px solid var(--ink);
    padding: var(--space-lg) 0 var(--space-xl);
    margin-top: var(--space-2xl);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--rule-color);
}

.footer a {
    color: var(--ink-faded);
}

.footer a:hover {
    color: var(--burgundy);
}

/* --- Tag Cloud --- */
.tag-cloud {
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--rule-color);
}

.tag-cloud a {
    display: inline-block;
    margin: var(--space-xs) var(--space-sm) var(--space-xs) 0;
    padding: var(--space-xs) var(--space-sm);
    font-family: var(--font-ui);
    font-size: 0.8rem;
    color: var(--ink-light);
    background: var(--cream-dark);
    border: 1px solid var(--rule-color);
    transition: all 0.2s ease;
}

.tag-cloud a:hover {
    background: var(--burgundy);
    color: var(--cream);
    border-color: var(--burgundy);
}

/* --- Section Headers --- */
.section .section-header {
    font-family: var(--font-ui);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--ink-faded);
    margin-bottom: var(--space-lg);
    letter-spacing: 0.15em;
    padding-bottom: var(--space-sm);
    border-bottom: 1px solid var(--rule-color);
}

/* --- Terms List (Years, Sources, etc.) --- */
.container > ul:not(.flat):not(.posts) {
    columns: 2;
    column-gap: var(--space-xl);
    list-style: none;
    padding-left: 0;
}

.container > ul:not(.flat):not(.posts) li {
    break-inside: avoid;
    margin-bottom: var(--space-sm);
    padding: var(--space-xs) 0;
    border-bottom: 1px solid var(--rule-color);
}

.container > ul:not(.flat):not(.posts) li:last-child {
    border-bottom: none;
}

.container > ul:not(.flat):not(.posts) li a {
    font-family: var(--font-display);
    font-weight: 500;
}

.container > ul:not(.flat):not(.posts) li small {
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: var(--ink-faded);
}

/* --- Cards --- */
.card {
    min-width: 0;
    word-wrap: break-word;
    background-color: var(--parchment);
    background-clip: border-box;
    border: 1px solid var(--rule-color);
    padding: var(--space-lg);
    margin: var(--space-md) 0;
    box-shadow: 3px 3px 0 var(--cream-dark);
}

/* --- PDF Embed --- */
.pdfembed {
    height: 800px;
    border: 1px solid var(--rule-color);
    background: var(--parchment);
}

/* --- Search --- */
.search {
    margin-bottom: var(--space-lg);
}

.search input {
    width: 100%;
    padding: var(--space-md);
    font-family: var(--font-body);
    font-size: 1rem;
    border: 2px solid var(--rule-color);
    background: var(--parchment);
    color: var(--ink);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search input:focus {
    outline: none;
    border-color: var(--burgundy);
    box-shadow: 0 0 0 3px rgba(114, 47, 55, 0.1);
}

.search input::placeholder {
    color: var(--ink-faded);
}

/* --- Primary Action Button (Visit Resource) --- */
.button,
a.button {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.75rem;
    font-family: var(--font-ui);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--cream);
    background: var(--burgundy);
    border: 2px solid var(--burgundy);
    border-bottom: none;
    text-decoration: none;
    position: relative;
    transition: all 0.2s ease;
    box-shadow:
        0 4px 0 var(--burgundy-dark),
        0 6px 12px rgba(107, 40, 48, 0.2);
}

.button::before,
a.button::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.1) 0%,
        transparent 50%
    );
    pointer-events: none;
}

.button::after,
a.button::after {
    content: '→';
    display: inline-block;
    font-size: 1.1em;
    transition: transform 0.2s ease;
}

.button:hover,
a.button:hover {
    color: var(--cream);
    background: var(--burgundy-dark);
    border-color: var(--burgundy-dark);
    transform: translateY(2px);
    box-shadow:
        0 2px 0 var(--burgundy-dark),
        0 4px 8px rgba(107, 40, 48, 0.25);
}

.button:hover::after,
a.button:hover::after {
    transform: translateX(4px);
}

.button:active,
a.button:active {
    transform: translateY(4px);
    box-shadow:
        0 0 0 var(--burgundy-dark),
        0 2px 4px rgba(107, 40, 48, 0.2);
}

/* Remove default link underline on button */
.post a.button,
.markdown a.button {
    border-bottom: none;
    padding-bottom: 1rem;
}

/* --- Secondary Source Page (Compact Layout) --- */
.secondary-header {
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
}

.secondary-header .item-title {
    margin-bottom: var(--space-xs);
}

.secondary-meta {
    font-family: var(--font-ui);
    font-size: 0.85rem;
    color: var(--ink-faded);
    margin-bottom: var(--space-md);
}

.secondary-meta a {
    color: var(--ink-light);
}

.secondary-meta a:hover {
    color: var(--burgundy);
}

.secondary-header .resource-description {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--ink-light);
    margin-bottom: var(--space-sm);
    font-style: italic;
}

.secondary-header .button {
    margin: var(--space-md) 0 0 0;
}

/* --- Secondary Media Feed --- */
.secondary-feed {
    margin-top: var(--space-xl);
}

.secondary-feed-item {
    margin-bottom: var(--space-xl);
    padding: var(--space-lg);
    background: var(--parchment);
    border: 1px solid var(--rule-color);
    box-shadow: 3px 3px 0 var(--cream-dark);
}

.secondary-feed-item:last-child {
    margin-bottom: 0;
}

.secondary-feed-title {
    margin: 0 0 var(--space-xs) 0;
    font-family: var(--font-display);
    font-size: 1.35rem;
}

.secondary-feed-title a {
    color: var(--ink);
    border-bottom: none;
}

.secondary-feed-title a:hover {
    color: var(--burgundy);
}

.secondary-feed-item .resource-description {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--ink-light);
    margin-bottom: var(--space-md);
    font-style: italic;
}

.media-embed {
    margin: var(--space-md) 0 var(--space-sm);
}

.media-embed iframe {
    width: 100%;
    max-width: 100%;
    border: 1px solid var(--rule-color);
    background: #fff;
}

.secondary-feed-actions {
    margin-top: var(--space-md);
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-md);
    align-items: center;
}

.button.button-small,
a.button.button-small {
    padding: 0.7rem 1.2rem;
    font-size: 0.8rem;
    gap: 0.5rem;
}

.secondary-source-link {
    font-family: var(--font-ui);
    font-size: 0.8rem;
    color: var(--ink-light);
    border-bottom: 1px dotted var(--rule-dark);
}

.secondary-source-link:hover {
    color: var(--burgundy);
    border-bottom-color: var(--burgundy);
}

/* --- Collapsible --- */
.collapsible {
    font-family: var(--font-ui);
    background-color: var(--cream-dark);
    color: var(--ink-light);
    cursor: pointer;
    padding: var(--space-md);
    width: 100%;
    border: 1px solid var(--rule-color);
    text-align: left;
    outline: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.collapsible:hover,
.collapsible.active {
    background-color: var(--burgundy);
    color: var(--cream);
    border-color: var(--burgundy);
}

.collapsible-content {
    padding: var(--space-lg);
    display: none;
    overflow: hidden;
    background-color: var(--parchment);
    border: 1px solid var(--rule-color);
    border-top: none;
}

/* --- Utility Classes --- */
.bold {
    font-weight: 600;
}

.title {
    font-size: 1.1rem;
}

.light {
    color: var(--ink-light);
}

.smaller {
    font-size: 0.8rem;
}

.lighter {
    filter: brightness(110%);
}

/* --- Video Embed --- */
.video {
    margin: var(--space-lg) 0;
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border: 1px solid var(--rule-color);
    background: var(--ink);
}

.video > iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* --- Icon indicators --- */
.list .posts .post::before,
.recent-posts .posts .post::before {
    display: none;
}

/* Full text heading icon */
.fulltext-heading svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    vertical-align: -3px;
    stroke-width: 2;
}

/* Meta section link icons */
.meta-icon {
    /* Feather replaces <i> with <svg> */
}

.post .post-header .meta svg {
    width: 14px;
    height: 14px;
    stroke: var(--ink-faded);
    vertical-align: -2px;
    stroke-width: 2;
}

/* --- Responsive --- */
@media (max-width: 767px) {
    html {
        font-size: 18px;
    }

    body {
        padding: var(--space-md);
    }

    .wrapper {
        padding: 0;
    }

    h1, .site-title {
        font-size: 1.3rem;
    }

    h2, .page-title {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    .header {
        padding: var(--space-md) 0;
    }

    .header-top {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-xs);
    }

    .site-subtitle {
        font-size: 0.8rem;
    }

    .nav-main {
        flex-direction: column;
        gap: var(--space-sm);
    }

    .nav-group {
        flex-wrap: wrap;
    }

    .nav-group-secondary {
        margin-left: 0;
        padding-top: var(--space-xs);
        border-top: 1px solid var(--rule-color);
    }

    .nav-main a {
        font-size: 0.75rem;
    }

    .container {
        margin-top: var(--space-lg);
    }

    .container ul:not(.flat):not(.posts) {
        columns: 1;
    }

    .markdown img[style*="float: right"] {
        float: none !important;
        display: block;
        margin: var(--space-md) auto;
        max-width: 100%;
    }

    .list .posts .post,
    .recent-posts .posts .post {
        flex-wrap: wrap;
        gap: 0 var(--space-sm);
    }

    .list .posts .post .post-indicators,
    .recent-posts .posts .post .post-indicators {
        width: 100%;
        white-space: normal;
        overflow: visible;
    }

    .list .posts .post .meta,
    .recent-posts .posts .post .meta {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }

    .secondary-feed-item {
        padding: var(--space-md);
    }

    .secondary-feed-actions {
        gap: var(--space-sm);
    }
}

@media (max-width: 480px) {
    html {
        font-size: 17px;
    }

    .nav-label {
        font-size: 0.55rem;
    }

    .nav-main a {
        font-size: 0.7rem;
    }

    blockquote {
        margin-left: 0;
        margin-right: 0;
        padding: var(--space-md);
    }

    blockquote::before {
        display: none;
    }
}

/* --- Print Styles --- */
@media print {
    body {
        background: white;
        color: black;
    }

    body::before {
        display: none;
    }

    .header nav,
    .footer,
    .search {
        display: none;
    }

    a {
        color: black;
        text-decoration: underline;
    }

    blockquote {
        border-left-color: #666;
        background: #f5f5f5;
    }
}
