/* style.css */
:root {
    --bg: #fafafa;
    --text: #111;
    --text-secondary: #555;
    --accent: #000;
    --border: #ddd;
    --font-heading: 'Playfair Display', serif;
    --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg);
    color: var(--text);
    max-width: 750px; 
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    line-height: 1.6; /* Matches standard website line-height */
    background-image: repeating-linear-gradient(45deg, #f4f4f4 25%, transparent 25%, transparent 75%, #f4f4f4 75%, #f4f4f4),
                      repeating-linear-gradient(45deg, #f4f4f4 25%, transparent 25%, transparent 75%, #f4f4f4 75%, #f4f4f4);
    background-position: 0 0, 4px 4px;
    background-size: 8px 8px;
}

/* Navigation */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 40px 0 20px 0;
    border-bottom: 1px solid var(--border);
    margin-bottom: 50px;
}

.nav-link {
    font-size: 0.95rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

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

.chapter-meta {
    font-family: var(--font-heading);
    font-style: italic;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Typography & Content */
main {
    flex-grow: 1;
    padding-bottom: 60px;
}

h1 {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 400;
    line-height: 1.2;
    margin-bottom: 40px;
    letter-spacing: -0.02em;
    color: var(--text);
}

/* Reverted Paragraph Styling */
article p {
    font-size: 1rem; /* Standard font size */
    color: var(--text-secondary); /* Matches secondary text color used elsewhere */
    margin-bottom: 25px;
}

article p:first-of-type {
    color: var(--text); /* Keeps the leading paragraph slightly darker, but same size */
}

/* Footer / Pagination */
.chapter-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 60px 0 40px 0;
    border-top: 1px solid var(--border);
    margin-top: 40px;
}

.next-chapter-link {
    display: block;
    text-align: right;
    text-decoration: none;
    color: var(--text);
    transition: opacity 0.2s;
}

.next-chapter-link:hover {
    opacity: 0.6;
}

.next-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    margin-bottom: 5px;
    display: block;
}

.next-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-style: italic;
    font-weight: 600;
}

@media (max-width: 600px) {
    h1 { font-size: 2.5rem; }
    .next-title { font-size: 1.5rem; }
}
