/*
Theme Name: Catholic Modern
Author: Bractwo
Description: Nowoczesny motyw katolicki. Logo, Hero z cytatem, Grid, Zdjęcia 16:9, Strona 404.
Version: 1.3
*/

/* --- 1. Zmienne i Reset --- */
:root {
    --primary-color: #1a2c42; /* Ciemny granat */
    --accent-color: #c5a059;  /* Złoty/Beżowy */
    --text-color: #333333;
    --light-bg: #f8f9fa;
    --white: #ffffff;
    --border-radius: 8px;
    --font-main: 'Open Sans', sans-serif;
    --container-width: 1200px;
    --content-width: 900px; /* Szerokość tekstu wpisu */
}

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

body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--light-bg);
    line-height: 1.6;
    font-size: 16px;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
a:hover { color: var(--accent-color); }
img { max-width: 100%; height: auto; display: block; }

/* --- 2. Layout --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.content-container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* --- 3. Header & Logo --- */
header.site-header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    max-height: 60px; /* Dostosuj wysokość logo */
    width: auto;
    display: block;
}

.main-navigation ul { list-style: none; display: flex; gap: 20px; }
.main-navigation a { font-weight: 600; color: var(--primary-color); font-size: 0.95rem; text-transform: uppercase; }

/* --- 4. HERO SECTION (Strona Główna - Cytat) --- */
.hero-section {
    background-color: #f9f7f2; /* Kolor starego papieru/pergaminu */
    border-bottom: 1px solid #e0dcd3;
    padding: 80px 20px;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

/* Ozdobna linia nad cytatem */
.hero-section::before {
    content: "";
    display: block;
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
    margin: 0 auto 30px auto;
}

.hero-quote-text {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 2.2rem;
    line-height: 1.4;
    color: var(--primary-color);
    font-style: italic;
    max-width: 900px;
    margin: 0 auto 20px auto;
}

.hero-quote-author {
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* --- 5. Grid System (Archiwa i Home) --- */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.post-card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.post-card:hover { transform: translateY(-5px); }

.post-card-img {
    height: 200px;
    object-fit: cover;
    width: 100%;
}

.post-card-content { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }
.post-card-cat { color: var(--accent-color); font-size: 0.8rem; text-transform: uppercase; font-weight: 700; margin-bottom: 8px; }
.post-card-title { font-size: 1.2rem; margin-bottom: 10px; color: var(--primary-color); font-weight: 700; line-height: 1.3; }
.post-card-excerpt { font-size: 0.9rem; color: #666; margin-bottom: 15px; flex-grow: 1; }
.read-more { font-size: 0.85rem; font-weight: 700; color: var(--primary-color); margin-top: auto; }

/* --- 6. Single Post (Wpis) --- */
.single-post-header { margin-top: 40px; margin-bottom: 30px; text-align: center;}
.breadcrumbs { font-size: 0.85rem; color: #777; margin-bottom: 15px; }
.breadcrumbs a { color: #555; }
.breadcrumbs span { margin: 0 5px; }

.single-title { font-size: 2.5rem; color: var(--primary-color); margin-bottom: 20px; line-height: 1.2; }

/* Kontener na zdjęcie "wychodzące" poza szerokość tekstu (Breakout) */
.featured-image-wide {
    position: relative;
    width: 120%;       /* 120% szerokości kontenera (czyli po 10% więcej na stronę) */
    left: -10%;        /* Przesunięcie w lewo o 10%, aby wyśrodkować */
    margin-bottom: 40px;
}

.featured-image-wide img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9; /* Wymuszenie proporcji 16:9 */
    object-fit: cover;    /* Obrazek wypełni obszar, przycinając nadmiar */
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08); /* Lekki cień dla głębi */
    display: block;
}

.entry-content { font-size: 1.1rem; color: #222; }
.entry-content p { margin-bottom: 1.5em; }
.entry-content h2, .entry-content h3 { color: var(--primary-color); margin-top: 1.5em; margin-bottom: 0.5em; }
.entry-content blockquote { border-left: 4px solid var(--accent-color); padding-left: 20px; font-style: italic; color: #555; margin: 20px 0; }

/* --- 7. Related Posts --- */
.related-posts-section { margin-top: 60px; padding-top: 40px; border-top: 1px solid #eee; }
.section-title { font-size: 1.5rem; color: var(--primary-color); margin-bottom: 30px; text-align: center; }

/* --- 8. Sekcja Dolna (Strona Główna) --- */
.prayer-section {
    background-color: #fff;
    border-top: 1px solid #eee;
    padding: 80px 0;
    margin-top: 80px;
}

.prayer-content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.prayer-intro {
    text-align: center;
    margin-bottom: 50px;
}

.prayer-intro h2 {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.prayer-intro .lead {
    font-size: 1.2rem;
    color: #555;
    line-height: 1.8;
}

.prayer-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

.prayer-block h3 {
    color: var(--accent-color);
    font-size: 1.4rem;
    margin-bottom: 15px;
    border-left: 4px solid var(--primary-color);
    padding-left: 15px;
}

.prayer-block p {
    font-size: 1.05rem;
    color: #444;
    line-height: 1.7;
    margin-bottom: 15px;
    text-align: justify;
}

/* --- 9. Strona 404 --- */
.error-404 {
    text-align: center;
    padding: 100px 0;
}
.error-404 h1 { font-size: 6rem; color: var(--accent-color); line-height: 1; margin-bottom: 20px; }
.error-404 h2 { font-size: 2rem; color: var(--primary-color); margin-bottom: 20px; }
.error-404 p { font-size: 1.2rem; margin-bottom: 30px; color: #666; }
.btn-home {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    transition: 0.3s;
}
.btn-home:hover { background: var(--accent-color); color: #fff; }

/* --- 10. Footer --- */
footer.site-footer { background: var(--primary-color); color: var(--white); padding: 40px 0; margin-top: 0; text-align: center; }
footer p { opacity: 0.8; font-size: 0.9rem; }

/* --- 11. Responsywność --- */
@media (max-width: 1000px) {
    /* Na mniejszych ekranach zdjęcie wraca do normalnej szerokości */
    .featured-image-wide {
        width: 100%;
        left: 0;
    }
}

@media (max-width: 768px) {
    .posts-grid { grid-template-columns: 1fr; }
    .single-title { font-size: 2rem; }
    .header-inner { flex-direction: column; gap: 15px; }
    .hero-quote-text { font-size: 1.6rem; }
    .prayer-section { padding: 40px 0; }
}