/*
 Theme Name:   GeneratePress Child
 Theme URI:    https://generatepress.com
 Description:  Child Theme für GeneratePress
 Author:       Frank Giehring
 Author URI:   https://deine-website.de
 Template:     generatepress
 Version:      1.0
*/

/* Eigene Styles ab hier */

/* Einsatz Galerie */
.einsatz-gallery{margin-top:2em;}
.einsatz-gallery-title{font-size:1.4em;margin-bottom:1em;display:inline-block;}
.einsatz-gallery-grid{display:flex;flex-wrap:wrap;gap:10px;}
.einsatz-gallery-item img{border-radius:6px;transition:transform .3s ease;}
.einsatz-gallery-item img:hover{transform:scale(1.05);}

/* Search */

/* 🔍 Gestaltung der gruppierten Suchergebnisse */
.search-group {
    margin-bottom: 2em;
    padding-bottom: 1em;
    border-bottom: 1px solid #ddd;
}

.search-group-title {
    font-size: 1.3em;
    font-weight: 600;
    color: #000000; /* Schwarze Gruppenüberschrift */
    margin-bottom: 0.8em;
}

.search-group-list {
    list-style: none;
    padding: 0;
}

.search-group-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.search-thumb {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 6px;
    background-color: #f0f0f0;
    flex-shrink: 0;
}

.search-text {
    flex: 1;
}

.search-link {
    font-weight: 600;
    color: #8f1a1a; /* 🔴 Standard-Linkfarbe */
    text-decoration: none;
    transition: color 0.2s ease;
}

.search-link:hover {
    color: #f08d0c; /* 🟠 Hover-Farbe */
}

.search-excerpt {
    font-size: 0.9em;
    color: #555;
    margin: 4px 0 0 0;
}

/* ==========================================================
   🌍 Globale Linkfarben (GeneratePress Child)
   ========================================================== */
a {
    color: #8f1a1a; /* 🔴 Standard-Linkfarbe */
    text-decoration: none;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

a:hover,
a:focus,
a:active {
    color: #f08d0c; /* 🟠 Hover-/Fokus-Farbe */
    text-decoration: none;
}

/* Optional: Navigation, Footer, Widgets usw. leicht anpassen */
.main-navigation a {
    color: #fff; /* Menü bleibt weiß */
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a {
    color: #f08d0c; /* Hover in Menü */
}

.site-footer a {
    color: #8f1a1a;
}

.site-footer a:hover {
    color: #f08d0c;
}
/* ==========================================================
   🔘 Einheitliches Button-Design (Feuerwehr-Stil)
   ========================================================== */
button,
input[type="button"],
input[type="submit"],
.wp-block-button__link,
.button,
a.button {
    background-color: #8f1a1a; /* 🔴 Grundfarbe */
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 10px 18px;
    font-weight: 600;
    text-transform: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
    cursor: pointer;
}

button:hover,
input[type="button"]:hover,
input[type="submit"]:hover,
.wp-block-button__link:hover,
.button:hover,
a.button:hover {
    background-color: #f08d0c; /* 🟠 Hover-Farbe */
    color: #ffffff;
    transform: translateY(-1px);
}

button:active,
input[type="button"]:active,
input[type="submit"]:active,
.wp-block-button__link:active,
.button:active,
a.button:active {
    transform: translateY(0);
    background-color: #d77a0b; /* Etwas dunkler bei Klick */
}

/* Optional: Fokus-Ring für Barrierefreiheit */
button:focus,
input[type="button"]:focus,
input[type="submit"]:focus,
.wp-block-button__link:focus,
.button:focus,
a.button:focus {
    outline: 2px solid #f08d0c;
    outline-offset: 2px;
}

/* ===============================================================
   ℹ️ Hinweistext unter Einsatzberichten
   =============================================================== */
.einsatz-hinweis {
    margin-top: 2em;
    padding: 0.8em 1em;
    background-color: #f9f9f9;
/*  border-left: 4px solid #8f1a1a;*/
    font-size: 0.9em;
    color: #333;
    display: flex;
    align-items: flex-start;
    gap: 0.5em;
    border-radius: 4px;
}

.einsatz-hinweis-icon {
    font-size: 1.4em;
    line-height: 1;
    flex-shrink: 0;
}

.einsatz-hinweis-text {
    display: inline-block;
    max-width: 95%;
    line-height: 1.4;
}

/* ===============================================================
   ℹ️ Eingebettete PDF Files
   =============================================================== */

.pdf-embed-container object {
    border: 1px solid #ccc;
    border-radius: 4px;
}
.pdf-download-link a:hover {
    color: #f08d0c;
}

/* ==========================================================
   📄 Responsive PDF-Container
   ========================================================== */
.responsive-pdf-wrapper {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin: 1em 0;
}

.responsive-pdf-wrapper iframe {
    width: 100%;
    height: 80vh; /* 80% der verfügbaren Höhe */
    border: 1px solid #ddd;
    border-radius: 4px;
}

@media (max-width: 768px) {
    .responsive-pdf-wrapper iframe {
        height: 60vh; /* kleinere Höhe auf Smartphones */
    }
}

.pdf-download-hint {
    font-size: 0.9em;
    color: #555;
    margin-top: 0.5em;
}
.pdf-download-hint a {
    color: #8f1a1a;
    text-decoration: none;
}
.pdf-download-hint a:hover {
    color: #f08d0c;
    text-decoration: underline;
}

/* 🔧 Standard-"current"-Färbung von GeneratePress neutralisieren */
.main-navigation .main-nav ul li[class*="current-menu-"] > a,
.main-navigation .main-nav ul li.current_page_item > a,
.main-navigation .main-nav ul li.current_page_ancestor > a {
    color: inherit;
    font-weight: inherit;
}

/* 🌐 Standard-Menülinks */
.main-navigation .main-nav ul li a {
    color: #000000; /* Initialfarbe */
    text-decoration: none;
    transition: color 0.2s ease;
}

/* 🖱️ Hover-Effekt */
.main-navigation .main-nav ul li a:hover {
    color: #fefa00; /* Hoverfarbe */
}

/* 🔥 Aktive und übergeordnete Menüpunkte (eigene JS-Klassen) */
.main-navigation .main-nav ul li.fw-nav-active > a,
.main-navigation .main-nav ul li.fw-nav-ancestor > a {
    color: #fefa00; /* Aktivfarbe */
    font-weight: 600;
}

/* 🖱️ Hover auf aktiven Links (gleiches Gelb beibehalten) */
.main-navigation .main-nav ul li.fw-nav-active > a:hover,
.main-navigation .main-nav ul li.fw-nav-ancestor > a:hover {
    color: #fefa00;
}

/* 🧹 Entfernt NUR die Navigation unter EINZELNEN Beiträgen */
.single-post .post-navigation {
    display: none !important;
}

/* 🧹 Entfernt NUR die Meta-Zeilen (Kategorien etc.) unter EINZELNEN Beiträgen */
.single-post .entry-meta {
    display: none !important;
}

/* 🎨 Stil für "Zurück zur Übersicht"-Button */
.fw-back-button-wrapper {
    text-align: center;
    margin-top: 2em;
}

.fw-back-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #8f1a1a;
    color: #fff;
    padding: 8px 18px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: background-color 0.3s ease, transform 0.2s ease;
    white-space: nowrap;
}

.fw-back-button:hover {
    background-color: #f08d0c;
    color: #fff;
}

/* 🧭 Pfeil-Icon Styling + Animation */
.fw-back-button .fw-arrow {
    display: inline-block;
    font-family: Arial, sans-serif; /* neutralisiert farbige Emojis */
    font-weight: bold;
    color: #fff;
    margin-right: 8px;
    transition: transform 0.3s ease;
    font-size: 1.1em;
}

/* 💨 Pfeil gleitet bei Hover leicht nach links */
.fw-back-button:hover .fw-arrow {
    transform: translateX(-4px);
}

/* 📱 Mobile Optimierung */
@media (max-width: 768px) {
    .fw-back-button-wrapper {
        margin-top: 1.5em;
        text-align: center;
    }

    .fw-back-button {
        font-size: 1rem;          /* etwas größer auf Mobilgeräten */
        padding: 10px 20px;       /* mehr "Tap"-Fläche */
        border-radius: 8px;
    }

    .fw-back-button .fw-arrow {
        margin-right: 6px;
        font-size: 1.2em;
    }
}

/* ==========================================================
   🧭 Breadcrumb-Navigation – finale SVG-Version (GeneratePress Child)
   ========================================================== */

.fw-breadcrumb {
    font-size: 0.9rem;
    color: #555;
    margin: 0 0 1.2em 0;
    padding: 0.4em 0;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.fw-breadcrumb-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35em;
}

/* Links */
.fw-breadcrumb a {
    color: #8f1a1a;
    text-decoration: none;
}

.fw-breadcrumb a:hover {
    color: #f08d0c;
    text-decoration: underline;
}

/* Aktuelle Seite */
.fw-breadcrumb-current {
    font-weight: normal;
    color: #000;
}

/* Deaktivierte (nicht klickbare) Container-Seiten */
.breadcrumb-inactive {
    color: #666;
    cursor: default;
    text-decoration: none;
}

/* SVG-Trenner */
.fw-breadcrumb-separator {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    line-height: 1;
    width: auto;
    overflow: visible !important;
}

.fw-breadcrumb-separator svg {
    display: inline-block !important;
    width: 8px;
    height: 8px;
    overflow: visible !important;
    vertical-align: middle !important;
}

.fw-breadcrumb-separator svg path {
    stroke: #8f1a1a;
    stroke-width: 1.4;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 1;
    vector-effect: non-scaling-stroke;
}

/* Hover-Effekt: SVG färbt sich orange, wenn man über den vorherigen Link fährt */
.fw-breadcrumb a:hover + .fw-breadcrumb-separator svg path {
    stroke: #f08d0c;
}

/* ==========================================================
   🩶 Breadcrumb-Navigation – Endgültige Version mit grauen Pfeilen
   ========================================================== */

.fw-breadcrumb {
    font-size: 0.9rem;
    color: #555;
    margin: 0 0 1.2em 0;
    padding: 0.4em 0;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.fw-breadcrumb-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4em;
}

.fw-breadcrumb a {
    color: #8f1a1a;
    text-decoration: none;
}

.fw-breadcrumb a:hover {
    color: #f08d0c;
    text-decoration: underline;
}

.fw-breadcrumb-current {
    font-weight: normal;
    color: #000;
}

/* Inaktive (nicht klickbare) Containerseiten */
.breadcrumb-inactive {
    color: #666;
    cursor: default;
    text-decoration: none;
    font-weight: 500;
}

/* Pfeile in Grau */
.fw-breadcrumb-separator {
    color: #888;
    margin: 0 0.3em;
    font-size: 0.9em;
    font-weight: 400;
}

/* ================================================
   🌟 Aktiver Menüpunkt & Ahnen – visuelle Hervorhebung
   ================================================ */
.main-navigation .main-nav ul li.fw-nav-active > a,
.main-navigation .main-nav ul li.fw-nav-ancestor > a {
    color: #fefa00 !important;   /* Deine Aktiv-/Hover-Farbe */
    font-weight: 600;            /* Fetterer Text */
}

/* ===== Footer-Menü ===== */
.footer-nav {
    text-align: center;
    margin: 1.2em 0 0.6em 0;
}

.footer-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: inline-flex;
    gap: 1em;
}

.footer-menu a {
    color: #8f1a1a; /* deine Linkfarbe */
    text-decoration: none;
    font-weight: 500;
}

.footer-menu a:hover {
    color: #f08d0c; /* Hoverfarbe */
    text-decoration: underline;
}

/* ============================================
   Footer-Menü + Copyright (GeneratePress)
   ============================================ */

/* Container im Copyright-Bereich */
.site-footer .inside-site-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

/* Footer-Menü-Block */
.footer-nav {
    margin-top: 0.8em;
    margin-bottom: 0.4em;
    width: 100%;
}

.footer-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.2em;
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-menu a {
    color: #8f1a1a;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.footer-menu a:hover {
    color: #f08d0c;
    text-decoration: underline;
}

/* Copyright-Zeile */
.copyright-bar {
    margin-top: 0.8em;
    text-align: center;
    width: 100%;
    font-size: 0.9em;
    opacity: 0.9;
}
/* ============================================
   Footer-Menü (Farben und Effekte wie Hauptmenü)
   ============================================ */

.footer-menu a {
    color: #000000; /* Grundfarbe wie Hauptmenü */
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease, font-weight 0.2s ease;
}

.footer-menu a:hover,
.footer-menu a:focus {
    color: #fefa00; /* Hoverfarbe */
    text-decoration: none; /* keine Unterstreichung */
}

/* Aktiver Menüpunkt */
.footer-menu .current-menu-item > a,
.footer-menu .current_page_item > a {
    color: #fefa00;
    font-weight: 600; /* etwas fetter */
}

/* Optional für mobile Geräte */
.footer-menu a:active {
    color: #fefa00;
    text-decoration: none;
}

/* ============================================
   📱 Responsive Footer-Menü (2 Spalten bei kleinen Bildschirmen)
   ============================================ */
@media (max-width: 480px) {
    .footer-menu {
        justify-content: center;
        gap: 0.8em 1.5em; /* vertikal | horizontaler Abstand */
    }

    .footer-menu li {
        flex: 1 1 45%; /* zwei Spalten */
        text-align: center;
    }
}

/* ============================================
   Zweites Logo direkt rechts neben dem Titel
   ============================================ */

/* --------------------------------------------
   DESKTOP
   -------------------------------------------- */

/* Hauptlogo proportional skalieren */
.site-logo img {
    height: auto !important;
    width: auto !important;
    max-height: 110px;
}

/* Zweites Logo (Wappen) direkt hinter dem Titel */
.fw-title-logo {
    height: 110px;
    width: auto;
    margin-left: 12px;
    vertical-align: middle;
}

/* Titelgröße Desktop */
.main-title {
    font-size: 48px;
    line-height: 1.2;
}

/* Logos + Titel auf einer Reihe */
.site-branding-container {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 12px; /* etwas Abstand */
}

/* --------------------------------------------
   TABLET
   -------------------------------------------- */

@media (max-width: 1024px) {
    /* Erstes Logo */
    .site-logo img {
        max-height: 80px !important;
    }

    /* Zweites Logo (minimal kleiner als vorher) */
    .fw-title-logo {
        height: 73px !important; /* statt 80px */
        margin-left: 20px; 
    }

    /* Titel leicht verkleinern (bleibt hinter beiden proportional) */
    .main-title {
        font-size: 30px !important;
    }
}

/* --------------------------------------------
   HANDY
   -------------------------------------------- */
@media (max-width: 600px) {

    /* Erstes Logo – zu klein -> größer machen */
    .site-logo img {
        max-height: 75px !important;
    }

    /* Zweites Logo – bereits ok */
    .fw-title-logo {
        height: 38px !important;
        margin-left: 17px;  /* Abstand zwischen Titel & Logo 2 */
    }

    /* Titel leicht kleiner, um alles sauber auszurichten */
    .main-title {
        font-size: 22px !important;
        margin-left: 13px; 
    }
}

/* --------------------------------------------
   Autorenlink und Erstelldatum von Einzelbeiträgen
   -------------------------------------------- */

.fw-post-meta{
    font-size:1.05rem;
    font-weight:600;
    margin-bottom:25px;
    color:#800000; /* Feuerwehrrot - harmonisch zu deinem Design */
}

.fw-post-meta span{
    margin-right:22px;
}

.fw-meta-icons{
    display:flex;
    gap:28px;
    margin:18px 0 28px;
    font-size:1.05rem;
    font-weight:600;
    color:#777777; /* Dunkelgrau */
}

.fw-meta-icons svg{
    margin-right:8px;
    position:relative;
    top:2px;
}

.fw-meta-item{
    display:flex;
    align-items:center;
    transition:.25s;
}

/* --------------------------------------------
   Buttonstyle scrollTopBtn and scrollBottomBtn
   -------------------------------------------- */
#scrollTopBtn,
#scrollBottomBtn {
    position: fixed;
    right: 25px;   /* <-- Abstand zum rechten Bildschirmrand */
    left: auto;    /* <- linke Seite deaktivieren */
    width: 60px;
    height: 60px;
    background: rgba(0,0,0,0.25); /* Opacity ein */
    border: none;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity .4s ease, transform .25s;
    z-index: 9999;
}

/* SVG Iconfarbe */
#scrollTopBtn svg,
#scrollBottomBtn svg {
    stroke: #fff;
}

/* Buttons sichtbar */
#scrollTopBtn.show,
#scrollBottomBtn.show {
    opacity: 1;
    pointer-events: auto;
}

/* Hover-Effekt */
/* Hover am Desktop */
/* Hover-Effekt nur auf Desktop-Geräten */
@media (hover: hover) and (pointer: fine) {
    #scrollTopBtn:hover,
    #scrollBottomBtn:hover {
        background: rgba(0,0,0,0.75);
        transform: scale(1.05);
    }
}

/* Touch-Aktivierung → nur solange gedrückt 
Fix für Mobilgeräte
Wir ersetzen die reine :hover-Farbänderung und steuern den aktiven Klickzustand logisch per JavaScript, sodass Touchgeräte korrekt zurückschalten.
*/
#scrollTopBtn.active,
#scrollBottomBtn.active {
    background: rgba(0,0,0,0.75);
    transform: scale(1.08);
}
/* Positionierung */
#scrollTopBtn {
    bottom: 95px; /* Abstand zur Bottom-Version */
}

#scrollBottomBtn {
    bottom: 25px;
}

/* Nur auf Mobil: rechts */
@media(max-width: 768px) {
    #scrollTopBtn, #scrollBottomBtn {
        left: auto;
        right: 5px;
    }
}

/* 
Facebook und Instagram Images im Footer
*/

.footer-social {
    text-align: center;
    padding: 10px 0;
    background-color: #ff0000;
    margin-bottom: -40px;
}

.footer-social a.social-link {
    display: inline-flex;
    align-items: center;
    margin: 0 12px;
    color: #000000; /* Schwarz wie Footer-Menü */
    font-size: 14px;
    text-decoration: none;
}

.footer-social a.social-link:hover {
    color: #ffff00; /* Gelb wie Hover im Footer-Menü */
}

.footer-social img {
    width: 32px;
    margin-right: 6px;
    vertical-align: middle;
    transition: filter 0.2s ease, opacity 0.2s ease;
}

.footer-social img:hover {
    filter: brightness(1.2); /* 20% heller */
}


/* 
==========================================
   Sitemap Styling 
==========================================
*/

/* Grundlayout */
ul.html-sitemap-simple {
    padding-left: 20px;
    margin: 0;
}

ul.html-sitemap-simple ul {
    padding-left: 20px;
    margin-top: 4px;
}

.html-sitemap-simple li {
    margin: 6px 0;
}


/* ==========================================
   Container-Ebenen (nicht klickbare Menüs)
========================================== */

.html-sitemap-simple .sitemap-container {
    color: #666;          /* neutral grau */
    font-weight: 600;
}


/* ==========================================
   Allgemeines Link-Design
========================================== */

.html-sitemap-simple a {
    color: #8f1a1a !important;  /* Feuerwehr-Rot (Standard) */
    font-weight: 500;
    text-decoration: none !important;
}

.html-sitemap-simple a:hover {
    color: #f08d0c !important;  /* Hover-Orange */
    text-decoration: none !important;
}


/* ==========================================
   Ordner-SVG-Icon (wird per PHP eingefügt)
========================================== */

.html-sitemap-simple .sitemap-icon {
    display: inline-block;
    margin-right: 8px;
    margin-left: -2px;   /* rückt es optisch sauber ein */
    vertical-align: -1px; /* optische Anpassung zur Textmitte */
}
