/* --- Global Styles & Variables --- */
:root {
    --bg-primary: #F8F8F2; /* Off-white */
    --bg-secondary: #E8E4D8; /* Light Beige */
    --text-main: #36454F; /* Charcoal */
    --text-muted: #4A4A4A; /* Dark Gray */
    --accent-primary: #A3B899; /* Muted Sage Green */
    --accent-secondary: #8CACA9; /* Dusty Blue */
    --border-color: #D3D3D3; /* Soft Gray */

    --font-heading: 'Playfair Display', serif;
    --font-body: 'Lato', sans-serif;
    --font-poems: 'PT Serif', serif; /* Or keep Lato if preferred, ensure legibility */
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-main);
    line-height: 1.7;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    width: 90%;
    max-width: 900px;
    margin: 2rem auto; /* Provides spacing top/bottom */
    flex-grow: 1; /* Pushes footer down */
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--text-main);
    margin-bottom: 1rem;
    line-height: 1.3;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }

p {
    margin-bottom: 1.2rem;
    color: var(--text-muted);
}

a {
    color: var(--accent-secondary);
    text-decoration: none;
}

a:hover, a:focus {
    color: var(--accent-primary);
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: auto;
    display: block; /* Prevents bottom space */
}

/* --- Header & Navigation --- */
.site-header {
    background-color: var(--bg-secondary);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0; /* Override default container margin */
    margin-bottom: 0;
}

.logo a {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-main);
    text-decoration: none;
}
.logo a:hover {
    color: var(--accent-primary);
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem; /* Space between nav items */
}

.main-nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: bold;
    padding-bottom: 5px; /* Space for potential border */
    border-bottom: 2px solid transparent; /* Prepare for active/hover state */
    transition: color 0.3s ease, border-color 0.3s ease;
}

.main-nav a:hover,
.main-nav a:focus {
    color: var(--text-main);
    border-bottom-color: var(--accent-primary);
    text-decoration: none; /* Override default hover */
}

/* Style for the currently active page link - add manually or via JS */
/* .main-nav .active a {
    color: var(--text-main);
    border-bottom-color: var(--accent-primary);
} */


/* --- Footer --- */
.site-footer {
    background-color: var(--bg-secondary);
    color: var(--text-muted);
    text-align: center;
    padding: 1.5rem 0;
    margin-top: 2rem; /* Space above footer */
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
}

/* --- Homepage Specific --- */
.hero-banner {
    background-color: var(--accent-primary); /* Placeholder color */
    /* background-image: url('images/banner.jpg'); */ /* Uncomment and use real image */
    background-size: cover;
    background-position: center;
    height: 250px; /* Adjust as needed */
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white; /* Example if using text over image */
    text-align: center;
}

.homepage-intro h1 {
    text-align: center;
    margin-bottom: 0.5rem;
}

.tagline {
    text-align: center;
    font-size: 1.2rem;
    font-style: italic;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.featured-snippet {
    background-color: var(--bg-secondary);
    padding: 1.5rem;
    margin: 2rem 0;
    border-left: 5px solid var(--accent-primary);
    font-style: italic;
}

.cta-buttons {
    text-align: center;
    margin-top: 2rem;
}

.button {
    display: inline-block;
    background-color: var(--accent-secondary);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    margin: 0 0.5rem;
    transition: background-color 0.3s ease;
}

.button:hover, .button:focus {
    background-color: var(--accent-primary);
    color: white;
    text-decoration: none;
}

/* --- About Page Specific --- */
.about-content {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.about-photo {
    flex-basis: 30%; /* Adjust size */
    min-width: 150px; /* Ensure photo doesn't get too small */
}

.about-photo img {
    border-radius: 50%; /* Circular photo - optional */
    border: 3px solid var(--border-color);
}

.about-text {
    flex-basis: 70%;
}

/* --- Poems Page Specific --- */
.poem {
    margin-bottom: 3rem; /* Space between poems */
    border-bottom: 1px dashed var(--border-color); /* Separator */
    padding-bottom: 1rem;
}
.poem:last-child {
    border-bottom: none; /* No border after last poem */
}

.poem h3 {
    margin-bottom: 1rem;
    color: var(--accent-secondary);
}

.poem pre {
    font-family: var(--font-poems); /* Specific poem font */
    font-size: 1.1rem; /* Slightly larger for readability */
    line-height: 1.8; /* Generous line spacing */
    color: var(--text-main);
    white-space: pre-wrap; /* Preserves whitespace and wraps lines */
    word-wrap: break-word; /* Breaks long words if needed */
    background-color: transparent; /* Ensure no conflicting background */
    padding: 0; /* Remove default padding if any */
    margin: 0; /* Remove default margin if any */
    overflow-x: hidden; /* Prevent horizontal scroll unless absolutely needed */
}

.poems-intro {
    margin-bottom: 2rem;
    font-style: italic;
}

.poems-copyright {
    margin-top: 2rem;
    font-size: 0.9rem;
    text-align: center;
    color: var(--text-muted);
}


/* --- Books Page Specific --- */
.book-entry {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    align-items: flex-start;
}
.book-entry:last-child {
    border-bottom: none;
}

.book-cover {
    flex-basis: 150px; /* Fixed width for cover */
    flex-shrink: 0; /* Prevent shrinking */
}

.book-cover img {
    border: 1px solid var(--border-color);
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
}

.book-details {
    flex-grow: 1;
}

.book-details h3 {
    margin-bottom: 0.5rem;
}

.book-description {
    margin-bottom: 1rem;
}

/* --- Contact Page Specific --- */
.contact-methods p {
    margin-bottom: 0.8rem; /* Less space between contact lines */
}
/* Basic obfuscation hint */
.email-address [data-at]::after { content: attr(data-at); }
.email-address [data-dot]::after { content: attr(data-dot); }

/* --- Responsiveness --- */
@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }

    .container {
        width: 95%;
    }

    /* Basic mobile nav stacking */
    .site-header .container {
        flex-direction: column;
        gap: 1rem;
    }
    .main-nav ul {
        justify-content: center;
        flex-wrap: wrap; /* Allow wrapping if too many items */
        gap: 1rem;
    }

    .about-content {
        flex-direction: column;
        align-items: center; /* Center photo when stacked */
    }
    .about-photo {
        max-width: 200px; /* Control photo size */
        margin-bottom: 1rem;
    }

    .book-entry {
        flex-direction: column;
        align-items: center; /* Center cover image */
    }
    .book-cover {
        margin-bottom: 1rem;
        max-width: 200px; /* Control cover size */
    }
    .book-details {
        text-align: center; /* Center text below cover */
    }
    .button { /* Make buttons full-width potentially */
         /* display: block;
         width: 80%;
         margin: 0.5rem auto; */
    }
}

/* Add Google Fonts Import (Place this at the very top of your CSS file) */
@import url('https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,400;0,700;1,400&family=Playfair+Display:wght@700&family=PT+Serif:ital,wght@0,400;0,700;1,400&display=swap');