/* ==========================================================================
   Brandschutz Berndl — Theme
   Nachbau des bisherigen WordPress-Designs (Neve + Elementor) als Flat-File-Theme.
   Breakpoints wie im Original:
     Neve (Kopfzeile, Schriftgrößen):  < 576px | 576–959px | >= 960px
     Elementor (Spalten/Container):    <= 767px | <= 1024px | > 1024px
   ========================================================================== */

:root {
    --red: #ff0000;
    --text: #000000;
    --nv-text: #14171c;
    --nv-primary: #2b2b2b;
    --nv-secondary: #fcaf3b;
    --el-secondary: #54595f;
    --el-accent: #61ce70;

    --bodyfs: 15px;  --bodylh: 1.6;
    --h1fs: 39px;    --h1lh: 1.2;
    --h2fs: 30px;    --h2lh: 1.3;
    --h3fs: 20px;
    --h4fs: 16px;
    --h5fs: 14px;
    --container: 748px;
    --el-container: 767px;
    --logo-w: 160px;
}
@media (min-width: 576px) {
    :root { --bodyfs: 16px; --h1fs: 55px; --h1lh: 1.3; --h2fs: 35px; --container: 992px; --logo-w: 200px; }
}
@media (min-width: 768px) { :root { --el-container: 1024px; } }
@media (min-width: 960px) {
    :root { --bodyfs: 17px; --bodylh: 1.7; --h1fs: 70px; --h2fs: 50px; --h3fs: 24px; --h4fs: 20px; --h5fs: 16px; --container: 1170px; --logo-w: 238px; }
}
@media (min-width: 1025px) { :root { --el-container: 1140px; } }

/* ── Base ─────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    background: #fff;
    color: var(--nv-text);
    font-family: Poppins, Arial, Helvetica, sans-serif;
    font-size: var(--bodyfs);
    line-height: calc(var(--bodylh) * 1em);
    font-weight: 400;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: inline-block; vertical-align: middle; }
a { color: var(--nv-primary); text-decoration: none; }
a:hover, a:focus { color: var(--nv-secondary); }
p { margin: 0 0 30px; }
h1, h2, h3, h4, h5, h6 { font-family: Poppins, Arial, Helvetica, sans-serif; font-weight: 600; margin: 0 0 30px; color: inherit; }
h1 { font-size: var(--h1fs); line-height: var(--h1lh); }
h2 { font-size: var(--h2fs); line-height: var(--h2lh); }
h3 { font-size: var(--h3fs); line-height: 1.3; }
h4 { font-size: var(--h4fs); line-height: 1.3; }
h5, h6 { font-size: var(--h5fs); line-height: 1.3; }
ul, ol { margin: 0; padding-left: 0; }
strong, b { font-weight: 700; }
figure { margin: 0; }

.screen-reader-text, .skip-link:not(:focus) {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 100000; background: #fff; padding: 10px 16px; box-shadow: 0 0 6px rgba(0,0,0,.3); }

.nv-container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 15px; }
.el-container { width: 100%; max-width: var(--el-container); margin: 0 auto; }

/* ── Header ───────────────────────────────────────────────────────────── */
.site-header {
    position: relative;
    z-index: 100;
    background: #fff;
    box-shadow: 0 0 10px rgba(255, 0, 0, 1);
}
.header-row { padding: 4px 0; }
@media (min-width: 960px) { .header-row { padding: 8px 0; } }
.header-inner { display: flex; align-items: center; justify-content: space-between; }
.site-logo { display: block; padding: 10px 0; line-height: 0; }
.site-logo img { width: var(--logo-w); max-width: var(--logo-w); height: auto; display: block; }

.primary-nav { display: none; align-items: center; }
@media (min-width: 960px) { .primary-nav { display: flex; } .menu-toggle { display: none !important; } }
.primary-nav ul { display: flex; list-style: none; margin: 0; padding: 0; gap: 28px; }
.primary-nav a,
.sidebar-nav a {
    font-family: Poppins, Arial, Helvetica, sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--nv-text);
    line-height: 1.6;
}
.primary-nav a { font-size: 0.8em; display: block; padding-top: 1px; min-height: 25px; }
.primary-nav a:hover, .primary-nav a:focus, .sidebar-nav a:hover { color: var(--red); }
.primary-nav .is-active > a { color: var(--nv-text); }
.search-toggle { display: flex; align-items: center; margin-left: 4px; padding: 0 10px; color: var(--nv-primary); line-height: 0; }
.search-toggle svg { width: 15px; height: 15px; fill: currentColor; }
.search-toggle:hover { color: var(--nv-text); }

.menu-toggle {
    display: flex; align-items: center; gap: 0;
    font-family: Poppins, Arial, Helvetica, sans-serif; font-weight: 700; font-size: 14px; line-height: 1;
    color: var(--nv-text); background: #fff; border: 0; border-radius: 3px; padding: 10px 15px; cursor: pointer;
}
.menu-toggle .label { margin-right: 5px; }
.menu-toggle .bars { display: inline-flex; flex-direction: column; gap: 3px; width: 15px; }
.menu-toggle .bars span { display: block; height: 2px; background: currentColor; border-radius: 2px; }

/* Mobile sidebar menu (slide from left) */
.menu-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .5); opacity: 0; visibility: hidden; transition: opacity .3s; z-index: 998; }
.header-menu-sidebar {
    position: fixed; top: 0; bottom: 0; left: 0; width: 360px; max-width: 100%;
    background: #fff; z-index: 999; overflow-y: auto;
    transform: translateX(-100%); visibility: hidden; transition: transform .3s ease, visibility .3s;
    box-shadow: 0 0 10px rgba(0,0,0,.2);
}
body.menu-open .header-menu-sidebar { transform: translateX(0); visibility: visible; }
body.menu-open .menu-overlay { opacity: 1; visibility: visible; }
.sidebar-close { display: flex; justify-content: flex-end; padding: 7px 9px 0; }
.sidebar-close button {
    background: #fff; border: 1px solid var(--nv-text); border-radius: 3px; width: 47px; height: 34px;
    display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--nv-text); padding: 0;
}
.sidebar-close svg { width: 24px; height: 24px; }
.sidebar-nav ul { list-style: none; margin: 0; padding: 30px 19px; }
.sidebar-nav li { margin: 0; }
.sidebar-nav a { display: block; font-size: 15px; padding: 15px 0; line-height: 24px; }

/* Search overlay (desktop) */
.search-overlay {
    position: fixed; inset: 0; background: #fff; z-index: 1000;
    display: flex; align-items: center; opacity: 0; visibility: hidden; transition: opacity .3s;
}
body.search-open .search-overlay { opacity: 1; visibility: visible; }
.search-overlay .nv-container { padding: 0; }
.search-overlay form { display: flex; width: 100%; border: 4px solid var(--nv-secondary); border-radius: 2px; }
.search-overlay input {
    flex: 1; min-width: 0; height: 50px; border: 0; padding: 10px 12px; outline: none;
    font-family: Poppins, Arial, sans-serif; font-size: 27px; color: var(--nv-text); background: #fff;
}
.search-overlay input::placeholder { color: #999; }
.search-overlay button[type=submit] {
    border: 0; border-left: 1px solid #ddd; background: #fff; width: 54px; cursor: pointer; color: #777; display: flex; align-items: center; justify-content: center;
}
.search-overlay button[type=submit] svg { width: 27px; height: 27px; fill: currentColor; }
.search-close { position: absolute; top: 48px; right: max(15px, calc((100vw - 1140px) / 2 + 25px)); background: none; border: 0; cursor: pointer; padding: 4px; color: var(--nv-text); }
.search-close svg { width: 22px; height: 22px; }

/* ── Main / Elementor-like sections ──────────────────────────────────── */
.site-main { display: block; }
.el-section { position: relative; }
.el-section.mt-40 { margin-top: 40px; }
.el-section.mt-50 { margin-top: 50px; }
.el-col { padding: 10px; }
.el-col.inset-20 { padding: 20px; }

.page-title {
    font-family: Roboto, Arial, sans-serif; font-weight: 600; color: var(--red);
    font-size: var(--h2fs); line-height: 1; margin: 0;
}

/* Text (Elementor text editor) */
.bs-text { font-family: Roboto, Arial, sans-serif; font-weight: 400; color: var(--text); }
.bs-text a { color: var(--nv-primary); }
.bs-text a:hover { color: var(--nv-secondary); }
.bs-text h3, .bs-text h4, .bs-text h2 { color: var(--text); }
.bs-text ul { list-style: disc; padding-left: 15px; margin: 0; }
.bs-text ol { padding-left: 15px; margin: 0; }
.bs-text.lists-20 ul, .bs-text.lists-20 ol { padding-left: 0; margin-left: 20px; }
.bs-text li > p { margin: 0; }
.bs-text p img, .bs-text li img { vertical-align: baseline; }
.bs-text img.alignright { float: right; margin: 20px 0 20px 20px; }
.bs-text img.alignleft { float: left; margin: 20px 20px 20px 0; }
.bs-text img.aligncenter { display: block; margin: 0 auto 1em; }
.bs-text figure { margin: 0; }
.bs-text figure img { display: block; }
.bs-text figcaption { font-size: .9em; color: #555; margin-top: .5em; margin-bottom: 1em; }
.bs-text::after { content: ""; display: table; clear: both; }
.bs-text p.img-only { margin-top: 50px; margin-bottom: 0; line-height: 0; }
.bs-text p.img-only > img { display: block; }
.bs-text p.img-only:first-child { margin-top: 0; }
.bs-acc-content p.img-only { margin-top: 0; margin-bottom: 30px; line-height: inherit; }
.bs-acc-content p.img-only > img { display: inline-block; width: 1000px; max-width: 100%; }
.bs-text .signature { margin-top: 20px; }

/* Sections with side image */
.bs-block + .bs-block { margin-top: 20px; }
.bs-block .anchor { display: block; height: 0; }
.bs-row { display: flex; flex-wrap: wrap; align-items: flex-start; }
.bs-row > .bs-text { flex: 0 0 auto; }
.bs-row.split-60-40 > .bs-text { width: 60%; }
.bs-row.split-60-40 > .bs-media { width: 40%; }
.bs-cols { display: flex; flex-wrap: wrap; }
.bs-cols > .bs-colitem { padding: 10px; }
.bs-cols > .bs-colitem img { max-width: 100%; height: auto; display: block; }
.bs-cols.split-66-34 > .bs-colitem:first-child { width: 65.625%; }
.bs-cols.split-66-34 > .bs-colitem:last-child { width: 34.332%; }
.bs-cols.split-33-33 > .bs-colitem { width: 33.333%; }
@media (max-width: 767px) {
    .bs-cols > .bs-colitem { width: 100% !important; }
    .bs-cols > .bs-colitem:empty { display: none; }
}
.bs-image img { display: block; }

/* Image carousel (wie Elementor-Bilderkarussell: Pfeile mittig, Punkte unten) */
.bs-row.split-60-40 { align-items: stretch; }
.bs-carousel-wrap { position: relative; height: 100%; min-height: 100%; padding-bottom: 34px; }
.bs-carousel { position: static; width: 100%; overflow: hidden; }
.bs-carousel .slides { display: flex; transition: transform .5s ease; }
.bs-carousel .slide { flex: 0 0 100%; min-width: 0; display: flex; justify-content: center; align-items: flex-start; }
.bs-carousel .slide img { max-width: min(300px, 100%); max-height: 300px; width: auto; height: auto; }
.bs-carousel-wrap .nav { position: absolute; top: calc(50% - 27px); background: none; border: 0; cursor: pointer; color: rgba(238,238,238,.9); line-height: 1; padding: 0; z-index: 2; width: 25px; height: 25px; }
.bs-carousel-wrap .nav svg { width: 25px; height: 25px; fill: currentColor; display: block; }
.bs-carousel-wrap .nav.prev { left: 10px; }
.bs-carousel-wrap .nav.next { right: 10px; }
.bs-carousel-wrap .dots-only { position: absolute; left: 0; right: 0; bottom: 5px; height: 29px; overflow: visible; }
.bs-carousel-wrap .dots { display: flex; justify-content: center; align-items: center; gap: 12px; height: 100%; }
.bs-carousel-wrap .dots button { width: 6px; height: 6px; border-radius: 50%; border: 0; padding: 0; background: #000; opacity: .2; cursor: pointer; }
.bs-carousel-wrap .dots button.active { opacity: 1; }

/* ── Home ─────────────────────────────────────────────────────────────── */
.home-hero { background-position: center center; background-repeat: no-repeat; background-size: cover; }
.home-boxes { display: flex; flex-wrap: wrap; padding: 10px; }
.home-box { width: 33.333%; padding: 10px; text-align: center; }
@media (max-width: 767px) { .home-box { width: 100%; } }
.home-box .icon { display: flex; justify-content: center; color: var(--red); font-size: 50px; line-height: 1; height: 50px; margin-bottom: 15px; }
.home-box .icon i { width: 1em; height: 1em; display: block; position: relative; }
.home-box .icon i::before { position: absolute; left: 50%; transform: translateX(-50%); }
.home-box h3 { font-family: Roboto, Arial, sans-serif; font-weight: 600; color: var(--red); margin: 0 0 30px; }
.home-box p { font-family: Roboto, Arial, sans-serif; color: var(--text); margin: 0; }
.home-box .btn-wrap { margin-top: 20px; }
.btn {
    display: inline-block; background: var(--red); color: #fff; font-family: Roboto, Arial, sans-serif; font-weight: 500;
    font-size: 16px; line-height: 1; padding: 15px 30px; border-radius: 3px; min-height: 46px; transition: all .3s;
}
.btn:hover, .btn:focus { color: #fff; }

/* ── Aktuelles (post cards) ──────────────────────────────────────────── */
.post-grid { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: 30px; row-gap: 35px; }
@media (max-width: 767px) { .post-grid { grid-template-columns: 1fr; } }
.post-card { background: #fff; border-radius: 3px; overflow: hidden; box-shadow: 0 0 10px 0 rgba(0,0,0,.15); display: flex; flex-direction: column; transition: box-shadow .25s; }
.post-card:hover { box-shadow: 0 0 30px 0 rgba(0,0,0,.15); }
.post-card .thumb { display: block; position: relative; overflow: hidden; padding-bottom: calc(66% + 1px); margin-bottom: 20px; }
@media (max-width: 767px) { .post-card .thumb { padding-bottom: 50%; } }
.post-card .thumb img { position: absolute; left: 0; top: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; max-width: none; transform: scale(1.01); }
.post-card .text { padding: 0 30px; margin-top: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.post-card h3 { font-family: Roboto, Arial, sans-serif; font-weight: 600; font-size: 21px; line-height: 1.3; margin: 0 0 25px; }
.post-card h3 a { color: var(--el-secondary); }
.post-card .excerpt { margin-bottom: 25px; line-height: 1.7; }
.post-card .excerpt p { font-family: Roboto, Arial, sans-serif; color: #777; font-size: 14px; line-height: 1.5em; margin: 0; }
.post-card .more { font-family: Roboto, Arial, sans-serif; font-weight: 500; font-size: 12px; text-transform: uppercase; color: #ff0d00; margin-bottom: 20px; align-self: flex-start; }

/* ── Beiträge (Neve blog list, alternating) ──────────────────────────── */
.nv-archive { padding-top: 60px; padding-bottom: 96px; }
@media (min-width: 960px) { .nv-archive { padding-bottom: 99px; } }
.nv-archive h1.archive-title { margin-bottom: 30px; }
.nv-post { margin-bottom: 30px; display: grid; grid-template-columns: 1fr; gap: 0 20px; align-items: center; }
@media (min-width: 960px) {
    .nv-post { grid-template-columns: 65fr 35fr; }
    .nv-post:nth-child(odd) .nv-post-thumb { grid-column: 2; grid-row: 1; }
    .nv-post:nth-child(odd) .nv-post-content { grid-column: 1; grid-row: 1; }
    .nv-post:nth-child(even) { grid-template-columns: 35fr 65fr; }
}
.nv-post-thumb img { display: block; width: 100%; height: auto; object-fit: cover; object-position: center; }
.nv-post-content h2 { font-size: var(--h3fs); line-height: 1.3; margin: 0 0 10px; }
.nv-post-content h2 a { color: var(--nv-text); }
.nv-post-content .meta { font-size: .9em; margin: 0 0 20px; display: inline-block; }
.nv-post-content .meta + p { margin-top: 0; }
.nv-post-content .meta a, .nv-post-content .more { color: var(--nv-secondary); }
.nv-post-content p { margin: 0; }
@media (max-width: 959px) { .nv-post-thumb { margin-bottom: 20px; } }

/* ── Accordion ────────────────────────────────────────────────────────── */
.bs-accordion { margin-top: 20px; font-family: Roboto, Arial, sans-serif; }
.bs-acc-item { border: 1px solid #d5d8dc; }
.bs-acc-item + .bs-acc-item { border-top: none; }
.bs-acc-title {
    display: flex; align-items: flex-start; width: 100%; text-align: left; cursor: pointer; background: none; border: 0;
    font-family: Roboto, Arial, sans-serif; font-weight: 700; font-size: var(--bodyfs); line-height: 1; padding: 15px 20px; color: var(--red);
}
.bs-acc-title .ic { display: inline-block; width: 1.5em; flex: 0 0 auto; line-height: 1; }
.bs-acc-title > span { line-height: 1; }
.bs-acc-title .ic { height: 1em; }
.bs-acc-title .ic i { font-size: 1em; line-height: 1; vertical-align: top; }
.bs-acc-title .ic .opened { display: none; }
.bs-acc-item.active .bs-acc-title { color: var(--el-accent); }
.bs-acc-item.active .ic .opened { display: inline; }
.bs-acc-item.active .ic .closed { display: none; }
.bs-acc-content { display: none; border-top: 1px solid #d5d8dc; padding: 15px 20px; color: var(--text); }
.bs-acc-item.active .bs-acc-content { display: block; }
.bs-acc-content p { margin-bottom: 30px; }
.bs-acc-content h3 { color: var(--text); }
.bs-acc-content h3 .hl, .bs-acc-content strong.hl { color: var(--red); }
@media (max-width: 767px) {
    .bs-acc-title { padding: 12px 15px; }
    .bs-acc-title .ic { width: 1.2em; }
    .bs-acc-content { padding: 7px 15px; }
}

/* ── Search results / 404 ─────────────────────────────────────────────── */
.nv-plain { padding-top: 60px; padding-bottom: 30px; }
.search-form-inline { display: flex; max-width: 600px; margin: 0 0 40px; border: 2px solid #ddd; border-radius: 3px; }
.search-form-inline input { flex: 1; border: 0; padding: 10px 12px; font: inherit; outline: none; min-width: 0; }
.search-form-inline button { border: 0; background: #fff; padding: 0 14px; cursor: pointer; color: #555; }
.search-form-inline button svg { width: 15px; height: 15px; fill: currentColor; }
.search-result { margin-bottom: 30px; }
.search-result h2 { font-size: var(--h3fs); margin-bottom: 10px; }
.search-result h2 a { color: var(--nv-text); }
.search-result p { margin: 0; }

/* ── Footer (Impressum) ───────────────────────────────────────────────── */
.site-footer { margin-top: 50px; box-shadow: 0 0 10px rgba(255, 0, 0, 1); background: #fff; }
.hfg-footer { margin-top: 20px; }
.footer-inner { position: relative; padding-top: 24px; padding-bottom: 4px; }
@media (min-width: 960px) { .footer-inner { padding-top: 28px; padding-bottom: 10px; } }
.footer-impressum { position: relative; display: flow-root; font-family: Roboto, Arial, sans-serif; color: var(--text); }
.footer-impressum .ft-title {
    position: absolute; left: -85px; top: 109px; margin: 0; white-space: nowrap;
    font-family: Roboto, Arial, sans-serif; font-weight: 600; color: var(--red); font-size: var(--h2fs); line-height: 1;
    transform: rotate(-90deg); z-index: 1;
}
.footer-impressum .ft-cols { display: flex; padding-left: 80px; }
.footer-impressum .ft-col { width: 50%; }
.footer-impressum h3 { font-family: Poppins, Arial, sans-serif; color: var(--text); }
.footer-impressum h4 { font-family: Poppins, Arial, sans-serif; color: var(--text); text-align: center; }
.footer-impressum p { margin-bottom: 30px; }
.footer-impressum .ft-col > *:last-child { margin-bottom: 0; }
.footer-impressum ul { list-style: disc; padding-left: 0; margin: 0; }
.footer-impressum li { margin-top: 10px; }
.footer-impressum a { color: var(--text); }
.footer-impressum a:hover { color: var(--nv-secondary); }
.footer-impressum .ft-bottom { display: flex; flex-wrap: wrap; align-items: flex-start; }
.footer-impressum .ft-logo { width: 30%; padding: 20px; align-self: center; }
.footer-impressum .ft-logo img { display: block; width: 100%; }
.footer-impressum .ft-note { width: 70%; text-align: center; font-size: 12px; margin-top: 20px; }
.footer-impressum .ft-note p { margin: 0; }
.footer-impressum .ft-note h4 { margin-bottom: 30px; }
@media (max-width: 1024px) {
    .footer-impressum .ft-title { left: 0; top: 9px; transform: none; }
    .footer-impressum .ft-cols { margin-top: 60px; margin-bottom: 60px; padding-left: 0; }
    .footer-impressum .ft-note { margin-top: 0; }
}
@media (max-width: 767px) {
    .footer-impressum .ft-cols { flex-wrap: wrap; }
    .footer-impressum .ft-col { width: 100%; }
    .footer-impressum .ft-col + .ft-col { margin-top: 20px; }
    .footer-impressum .ft-logo, .footer-impressum .ft-note { width: 100%; }
}

/* Scroll to top */
.scroll-to-top {
    position: fixed; right: 20px; bottom: 30px; z-index: 999; display: flex; align-items: center; justify-content: center;
    padding: 8px 10px; border: none; border-radius: 3px; background: var(--nv-primary); color: #fff; cursor: pointer;
    opacity: 0; visibility: hidden; transition: opacity .3s ease-in-out, visibility .3s ease-in-out;
}
.scroll-to-top.visible { opacity: .7; visibility: visible; }
.scroll-to-top:hover { opacity: 1; }
.scroll-to-top svg { width: 16px; height: 16px; fill: currentColor; }

/* Admin bar (only visible to logged-in admins) */
.admin-bar { background: #1f2937; color: #fff; font: 13px/32px -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.admin-bar .inner { display: flex; gap: 18px; padding: 0 16px; align-items: center; flex-wrap: wrap; }
.admin-bar a { color: #e5e7eb; }
.admin-bar a:hover { color: #fde047; }
.admin-bar .edit { color: #fde047; font-weight: 600; }
.admin-bar .spacer { flex: 1; }
.bs-acc-content h3 strong { color: var(--red); font-weight: inherit; }
