/* ==========================================================================
   1. RESETS & VARIABLEN (Sanfte, warme Farbpalette)
   ========================================================================== */
:root {
    /* Primärtöne (Klassisches Kirchrot + warme Akzente) */
    --primary-red: #b82332;
    --primary-red-hover: #921825;
    
    /* Sekundäre Akzente für mehr Leben */
    --accent-gold: #d97724;
    --accent-sage: #2d6a4f;
    --accent-blue-soft: #eaf2f8;
    
    /* Neutrale & Hintergrund-Farben */
    --bg-page: #f6f8fa;
    --card-bg: #ffffff;
    --card-border: #e2e8f0;
    
    --text-dark: #2b2d42;
    --text-muted: #5c677d;
    --border-color: #e2e8f0;
    
    --font-heading: 'Century Gothic', CenturyGothic, AppleGothic, sans-serif;
    --font-body: Arial, Helvetica, sans-serif;
    
    --shadow-soft: 0 4px 15px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 8px 25px rgba(0, 0, 0, 0.09);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    /* Dezent farbiger Verlauf statt kühlem Grau */
    background: linear-gradient(180deg, #f0f4f8 0%, #f7f9fb 300px, #f4f6f8 100%);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: bold;
    color: var(--text-dark);
}

a {
    color: var(--primary-red);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-red-hover);
    text-decoration: underline;
}

/* ==========================================================================
   2. LAYOUT CONTAINER
   ========================================================================== */
.content-container {
    max-width: 1000px;
    width: 90%;
    margin: 40px auto;
    flex: 1;
}

/* ==========================================================================
   3. HEADER & NAVIGATION (Frischer roter Akzentstreifen)
   ========================================================================== */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    border-top: 20px solid var(--primary-red); /* Dezent farbiger oberer Abschluss */
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.header-container {
    max-width: 1000px;
    width: 90%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    position: relative;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-dark);
    text-decoration: none !important;
}

.logo-red {
    color: var(--primary-red);
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 15px;
}

.main-nav a {
    color: var(--text-dark);
    font-weight: bold;
    font-size: 0.95rem;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.main-nav a:hover {
    color: var(--primary-red);
    background-color: #fdf2f4; /* Sanfter roter Hauch beim Drüberfahren */
    text-decoration: none;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--text-dark);
}

/* ==========================================================================
   4. BILDERSLIDER
   ========================================================================== */
.carousel-container {
    max-width: 1000px;
    width: 90%;
    margin: 25px auto 0 auto;
    height: 350px;
    overflow: hidden;
    border-radius: 12px;
    position: relative;
    box-shadow: var(--shadow-soft);
    background-color: #e9ecef;
}

.carousel-fade {
    width: 100%;
    height: 100%;
    position: relative;
}

.fade-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}

.fade-slide.active {
    opacity: 1;
}

/* ==========================================================================
   5. KARTEN-LAYOUT (Zentrales 80:20 mit dezentem Farbakzent)
   ========================================================================== */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 20px;
}

.event-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-left: 5px solid var(--primary-red); /* Roter Farbakzent am linken Kartenrand */
    border-radius: 10px;
    box-shadow: var(--shadow-soft);
    display: grid;
    grid-template-columns: 8fr 2fr; /* Globales 80:20 Layout */
    overflow: hidden;
    min-height: 180px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.event-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.event-content {
    padding: 22px 25px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
}

.event-header h2, .event-content h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    line-height: 1.3;
    color: var(--text-dark);
}

.event-meta {
    font-size: 0.85rem;
    color: #000000;         /* Text auf Schwarz gesetzt */
    font-weight: bold;
    margin-bottom: 12px;
    background-color: transparent; /* Orangenen Hintergrund entfernt */
    padding: 0;              /* Einrückung/Innenabstand entfernt */
    display: inline-block;
}

.event-body {
    font-size: 0.95rem;
    color: var(--text-dark);
    margin-bottom: 15px;
}

.event-location {
    font-size: 0.85rem;
    color: var(--accent-sage);
    font-weight: bold;
}

.event-image {
    width: 100%;
    height: 100%;
    background-color: #ffffff;
}

.event-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Kein Abschneiden/Herangezoome im 80:20 Feld */
    display: block;
}

/* ==========================================================================
   6. FORMULARE & BUTTONS
   ========================================================================== */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 650px;
    margin-top: 20px;
    background: #ffffff;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="password"],
.contact-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    background: #fdfdfd;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-red);
    box-shadow: 0 0 0 3px rgba(184, 35, 50, 0.12);
    background: #ffffff;
}

.btn {
    background: var(--primary-red);
    color: #ffffff !important;
    border: none;
    padding: 10px 22px;
    cursor: pointer;
    border-radius: 6px;
    font-weight: bold;
    font-size: 0.95rem;
    display: inline-block;
    text-align: center;
    transition: background 0.2s ease, transform 0.1s ease;
    text-decoration: none !important;
    box-shadow: 0 2px 5px rgba(184, 35, 50, 0.2);
}

.btn:hover {
    background: var(--primary-red-hover);
    transform: translateY(-1px);
}

/* ==========================================================================
   7. FOOTER
   ========================================================================== */
.site-footer {
    background: #ffffff;
    border-top: 3px solid #e9ecef;
    padding: 35px 0;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: auto;
}

.footer-container p {
    margin-bottom: 8px;
}

.footer-container a {
    color: var(--text-muted);
    font-weight: 500;
}

.footer-container a:hover {
    color: var(--primary-red);
}

/* ==========================================================================
   8. RESPONSIVE DESIGN (MOBILGERÄTE)
   ========================================================================== */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-nav {
        display: none;
        width: 100%;
        position: absolute;
        top: 100%;
        left: 0;
        background: #ffffff;
        border-bottom: 2px solid var(--border-color);
        padding: 20px 0;
        box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    }

    .main-nav.active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .carousel-container {
        height: 220px;
    }

    .event-card {
        grid-template-columns: 1fr;
        border-left: 1px solid var(--card-border);
        border-top: 5px solid var(--primary-red);
    }

    /* NEU: Innenabstand und Ausrichtung für Kartenbilder auf Smartphones */
    .event-image {
        height: auto;
        order: 2;
        padding: 0 20px 20px 20px; /* Luft zum unteren und seitlichen Kartenrand */
    }

    .event-image img {
        max-height: 200px;
        border-radius: 8px;
        margin: 0 auto;
    }

    .event-content {
        order: 1;
    }
}

/* ==========================================================================
   9. TABELLEN (z. B. für Gottesdienste)
   ========================================================================== */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background-color: #ffffff;
    box-shadow: var(--shadow-soft);
    border-radius: 8px;
    overflow: hidden;
}

table th, table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

table th {
    background-color: var(--primary-red);
    color: #ffffff;
    font-weight: bold;
}

/* Jede zweite Zeile deutlich einfärben */
table tr:nth-child(even) {
    background-color: #e2e8f0; /* Gut sichtbares Hellgrau */
}

/* Hover-Effekt beim Drüberfahren */
table tr:hover {
    background-color: #cbd5e1;
}


//////////////// LOGO /////////////////

/* Bild und Text als inline-block NEBENEINANDER zwingen */
.brand-img, 
.brand-sub {
    display: inline-block !important;
    vertical-align: middle !important; /* Richtet beides mittig aneinander aus */
}

/* Logogröße */
.brand-img {
    height: 48px;
    width: auto;
}

/* Der Textblock */
.brand-sub {
    border-left: 2px solid #c8102e;
    padding-left: 10px;
    margin-left: 8px;
    font-size: 0.85rem;
    font-weight: bold;
    line-height: 1.2;
}

/* Die beiden Ortsnamen UNTEREINANDER */
.brand-sub span {
    display: block !important;
    white-space: nowrap; /* Verhindert ungewollten Umbruch im Ortsnamen */
}