/*==================================================
  1. Base and Reset Styles
==================================================*/
:root {
    --color-primary: #004d99; /* Deeper Blue (More serious/trustworthy) */
    --color-secondary: #f4f4f4; /* Light Gray for subtle background */
    --color-text: #333;
    --color-subtle: #666;
    --color-white: #fff;
    --color-border: #ccc;
    --font-headline: 'Georgia', serif; 
    --font-body: 'Merriweather', Georgia, serif; /* Serifs for better readability */
    --font-sans: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

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

body {
    background-color: var(--color-secondary); /* Very light gray */
    color: var(--color-text);
    font-family: var(--font-body);
    line-height: 1.6;
}

a {
    color: var(--color-primary);
    text-decoration: none;
}
a:hover {
    text-decoration: underline;
}

/*==================================================
  2. Header and Navigation
==================================================*/
header {
    background: var(--color-white);
    border-bottom: 2px solid var(--color-primary);
    padding: 10px 0;
}

.site-header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

header h1 {
    font-family: var(--font-headline);
    font-size: 2.5em;
    color: var(--color-primary); /* Blue Sky Journal title in blue */
}

header h1 a {
    color: inherit;
}

.tagline {
    font-size: 1.1em;
    color: var(--color-subtle);
    margin-bottom: 10px;
}

.utility-nav, .town-switcher {
    max-width: 1200px;
    margin: 10px auto;
    padding: 0 20px;
    text-align: center;
}

.utility-nav h2, .town-switcher h2 {
    display: none; /* Hide secondary headers for a cleaner look */
}

.utility-nav ul, .town-switcher ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 15px;
    padding: 10px 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    background: var(--color-white);
}

.utility-nav a, .town-switcher a {
    text-transform: uppercase;
    font-weight: bold;
    font-size: 0.9em;
    padding: 5px 0;
    white-space: nowrap;
}

/*==================================================
  3. Main Layout (Homepage Columns)
==================================================*/
.container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}

.main-content {
    display: grid;
    grid-template-columns: 2fr 1fr; /* Two columns: Main Content (2 parts) and Sidebar (1 part) */
    gap: 30px;
}

.feature-col {
    padding-right: 20px;
    border-right: 1px solid var(--color-border);
}

.sidebar-col {
    background-color: var(--color-white);
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

/* Titles */
h2, h3 {
    font-family: var(--font-headline);
    margin-bottom: 15px;
    color: var(--color-primary);
}
h2 { font-size: 1.8em; }
h3 { font-size: 1.4em; border-bottom: 2px solid var(--color-border); padding-bottom: 5px; }

/* Feature Story */
.feature-col article {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--color-border);
}
.feature-col article h2 {
    font-size: 2.2em;
    color: var(--color-text);
    margin-bottom: 10px;
}
.feature-col article a:hover { color: var(--color-primary); }

/* Recent News List */
.feature-col ul {
    list-style: none;
}
.feature-col ul li {
    padding: 8px 0;
    border-bottom: 1px dashed var(--color-border);
}
.feature-col ul li:last-child {
    border-bottom: none;
}
.feature-col ul li p {
    font-size: 1em;
}

/* Events List Styling (Sidebar) */
.event-list-item {
    border-bottom: 1px dashed var(--color-border);
    padding: 10px 0;
}
.event-list-item h4 {
    margin: 0;
    font-size: 1.1em;
    border-bottom: none;
    padding-bottom: 0;
}
.event-list-item p {
    margin: 0;
    font-size: 0.9em;
    color: var(--color-subtle);
}

/* Liturgy Box (Sidebar) */
.liturgy-box {
    margin-top: 30px;
    padding-top: 15px;
    border-top: 1px solid var(--color-border);
}
.liturgy-box h3 {
    color: var(--color-text);
}

/*==================================================
  4. Footer
==================================================*/
footer {
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
    background: var(--color-white);
    border-top: 1px solid var(--color-border);
    font-size: 0.9em;
    color: var(--color-subtle);
}

/*==================================================
  5. Responsiveness (Mobile First)
==================================================*/

/* On screens smaller than 768px, stack the columns */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    .feature-col {
        border-right: none;
        padding-right: 0;
        padding-bottom: 20px;
        border-bottom: 1px solid var(--color-border);
    }
    .utility-nav ul, .town-switcher ul {
        flex-wrap: wrap; /* Allow navigation items to wrap */
        gap: 10px;
    }
}
