/* --- Color Palette & Variables --- */
:root {
    /* Backgrounds */
    --bg-main: #191716;       /* Very dark espresso brown */
    --bg-card: #262321;       /* Slightly lighter brown for containers */
    
    /* Text */
    --text-main: #E8E6D9;     /* Cream White */
    --text-muted: #8F8B85;    /* Dimmed text for dates/footers */
    
    /* Accents */
    --accent-green: #A3B18A;  /* Sage Green */
    --accent-purple: #B5A6C9; /* Muted Lavender */
    --accent-yellow: #E0C077; /* Muted Gold */
    --highlight: #D4A373;     /* Warm highlight for hovers */
}

/* --- Global Reset & Typography --- */
body, h1, h2, ul, p, a { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Courier New', Courier, monospace; /* The requested font */
    line-height: 1.6;
    padding: 20px;
    display: flex;
    justify-content: center; /* Centers the whole layout horizontally */
    min-height: 100vh;
}

/* --- Main Container (The "Card") --- */
main {
    background-color: var(--bg-card);
    width: 100%;
    max-width: 650px; /* Limits width for readability */
    margin-top: 40px;
    padding: 60px 40px;
    border-radius: 24px; /* The "Round Edges" */
    box-shadow: 0 10px 30px rgba(0,0,0,0.5); /* Slick shadow for depth */
    height: fit-content;
}

/* --- Header Styling --- */
header {
    text-align: center;
    margin-bottom: 50px;
    border-bottom: 2px dashed var(--bg-main); /* Stitching effect */
    padding-bottom: 30px;
}

header h1 {
    font-size: 2rem;
    color: var(--accent-yellow);
    margin-bottom: 10px;
}

header p {
    font-style: italic;
    color: var(--accent-purple);
    font-size: 0.9rem;
}

/* --- Poem List Styling --- */
.poem-list {
    list-style: none;
}

.poem-list li {
    margin-bottom: 15px;
}

.poem-list a {
    display: block;
    background-color: var(--bg-main); /* Darker inner pill */
    padding: 15px 25px;
    border-radius: 50px; /* Fully rounded "Pill" shape */
    text-decoration: none;
    color: var(--text-main);
    border: 1px solid transparent; /* Invisible border prevents jumping on hover */
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Hover Effects */
.poem-list a:hover {
    border-color: var(--accent-green);
    transform: translateY(-2px); /* Subtle lift */
    color: var(--accent-green);
}

.date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* --- Poem Content Page --- */
.poem-content {
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 50px;
    white-space: pre-line; /* Preserves your line breaks automatically */
    text-align: center; /* Center the poem text */
}

/* The "Back" Button */
.back-link {
    display: inline-block;
    text-decoration: none;
    color: var(--accent-purple);
    font-size: 0.9rem;
    border: 1px solid var(--accent-purple);
    padding: 10px 20px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.back-link:hover {
    background-color: var(--accent-purple);
    color: var(--bg-main);
}

/* --- Footer --- */
footer {
    margin-top: 50px;
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    border-top: 1px solid var(--bg-main);
    padding-top: 20px;
}