/*
Theme Name:   Schreiber &amp; Ebert GmbH 2026 Child
Template:     SchreiberEbert2026
Version:      1.0.0
Description:  Child-Theme fuer lokale Entwicklung der Startseite.
Text Domain:  SchreiberEbert2026-child
*/

.kompass-container {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75em;
    width: 100%;
    margin: 1rem 0;
}

@media (max-width: 640px) {
    .kompass-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 360px) {
    .kompass-container {
        grid-template-columns: 1fr;
    }
}

.kompass {
    background-color: #f4f7fa !important;
    border: 1px solid #d0d9e3 !important;
    border-radius: 8px !important;
    font-size: 1em !important;
    font-weight: normal !important;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.kompass:hover {
    background-color: #e6edf5 !important;
    box-shadow: 0 3px 10px rgba(0,0,0,0.10);
}

.kompass a {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5em;
    color: #333 !important;
    padding: 1.4em 0.8em !important;
    text-decoration: none;
    height: 100%;
    box-sizing: border-box;
}

.kompass__icon {
    font-size: 2.4em;
    color: #006dab;
    line-height: 1;
}

.kompass__text {
    font-size: 1.05em;
    font-weight: 600;
    line-height: 1.3;
    text-align: center;
}

/* ============================================================
   BARRIEREFREIHEIT
   ============================================================ */

/* Skip-Navigation-Link (nur sichtbar wenn fokussiert) */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    z-index: 99999;
    background: #006dab;
    color: #fff;
    padding: 0.75rem 1.5rem;
    font-weight: 700;
    text-decoration: none;
    border-radius: 0 0 4px 0;
}
.skip-link:focus {
    top: 0;
}

/* H2-Sektions-Titel: visuelle Größe des h1 beibehalten */
.se-videos__titel,
.se-zertifikate__titel,
.se-referenzen__titel,
.se-slider__titel {
    font-size: 2.8em;
}

.filialen_start h2,
.contact_start h2 {
    font-size: 2.8em;
    font-weight: 200;
    font-family: 'Titillium Web', sans-serif;
    color: #006dab;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 20px 0;
    padding: 0 0 5px 0;
    border-bottom: 1px solid #ddd;
}

@media only screen and (max-width: 767px) {
    .se-videos__titel,
    .se-zertifikate__titel,
    .se-referenzen__titel,
    .se-slider__titel,
    .filialen_start h2,
    .contact_start h2 {
        font-size: 1.9em;
    }
}

/* Focus-Styles (nur bei Tastaturnavigation, nicht bei Mausklick) */
.kompass a:focus-visible,
.se-petition__btn:focus-visible,
.se-videos__link:focus-visible,
.se-referenzen__buehne-link:focus-visible,
.se-zertifikate__lightbox-schliessen:focus-visible,
.se-zertifikate__karte:focus-visible {
    outline: 3px solid #006dab;
    outline-offset: 2px;
}

/* Pause-Button für Karusselle */
.se-karussell-pause {
    display: inline-block;
    background: none;
    border: 1px solid #ccc;
    border-radius: 4px;
    color: #666;
    font-size: 0.75rem;
    line-height: 1;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
    margin-bottom: 0.75rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

/* Sichtbar bei Hover auf dem Elternelement oder bei Fokus */
.se-referenzen:hover .se-karussell-pause,
.se-videos:hover .se-karussell-pause,
.se-zertifikate:hover .se-karussell-pause,
.se-karussell-pause:focus {
    opacity: 1;
}

.se-karussell-pause:hover {
    background: #f0f0f0;
    color: #333;
}

/* Petition – Alarmstufe Rot */
.se-petition {
    clear: both;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 1rem;
    background: linear-gradient(135deg, #fef5f5 0%, #fff8f8 100%);
    border-left: 5px solid #c41e3a;
    border-radius: 6px;
    padding: 0.5rem 1rem;
    margin: 0.75rem 0;
    box-shadow: 0 2px 8px rgba(196, 30, 58, 0.10);
}

/* Titel und Button in einer Zeile, Text darunter */
.se-petition__titel {
    order: 1;
    flex: 1;
    min-width: 160px;
    color: #c41e3a;
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0;
    line-height: 1.2;
    letter-spacing: -0.3px;
}

.se-petition__aktion {
    order: 2;
    flex-shrink: 0;
    margin: 0;
}

.se-petition__text {
    order: 3;
    width: 100%;
    font-size: 0.82rem;
    line-height: 1.45;
    color: #3a3a3a;
    margin: 0.1rem 0 0;
}

.se-petition__text p {
    margin: 0;
}

.se-petition__cta-text {
    color: #c41e3a;
    font-weight: 700;
}

.se-petition__fuss {
    order: 4;
    width: 100%;
    color: #888;
    font-size: 0.75rem;
    margin-top: 0.3rem;
    padding-top: 0.3rem;
    border-top: 1px solid #f0d0d5;
}

.se-petition__btn {
    display: inline-block;
    background: #c41e3a;
    color: #fff;
    padding: 0.35rem 1rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.82rem;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(196, 30, 58, 0.22);
    transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.se-petition__btn:hover {
    background: #a01830;
    box-shadow: 0 4px 12px rgba(196, 30, 58, 0.35);
    transform: translateY(-1px);
    color: #fff;
    text-decoration: none;
}

/* Termin-Button im Header ausgeblendet */
.termin {
    display: none;
}

/* Zertifikate-Karussell */
.se-zertifikate {
    clear: both;
    margin: 2rem 0;
}

.se-zertifikate__titel {
    margin: 0 0 20px 0;
    padding: 0 0 5px 0;
    border-bottom: 1px solid #ddd;
}

.se-zertifikate__karussell {
    overflow: hidden;
    width: 100%;
}

.se-zertifikate__spur {
    display: flex;
    will-change: transform;
}

.se-zertifikate__karte {
    /* Breite wird dynamisch per inline-style in section-zertifikate.php gesetzt */
    padding: 0 0.75rem;
    cursor: pointer;
    box-sizing: border-box;
}

.se-zertifikate__rahmen {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
    transition: box-shadow 0.2s ease;
}

.se-zertifikate__rahmen:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

/* A4-Seitenverhältnis: 1:√2 ≈ 1:1.4142 */
/* Feste Pixelhöhe (kein %-padding-Trick) – verhindert Rundungsfehler bei Flex-Layouts */
.se-zertifikate__bild-container {
    position: relative;
    width: 100%;
    height: 260px;
    background: #f5f5f5;
    overflow: hidden;
}

.se-zertifikate__bild {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: contain;
}

/* Platzhalterbild wenn Datei fehlt oder nicht ladbar */
.se-zertifikate__platzhalter {
    display: none;
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #f0f4f8;
    border: 2px dashed #aab;
    text-align: center;
    padding: 1rem;
    box-sizing: border-box;
}

.se-zertifikate__bild-container--fehler .se-zertifikate__platzhalter,
.se-zertifikate__bild-container:not(:has(img[src])) .se-zertifikate__platzhalter {
    display: flex;
}

.se-zertifikate__platzhalter-innen {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

/* Dekoratives Siegel-Symbol im Platzhalter */
.se-zertifikate__platzhalter-siegel {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 50%;
    border: 3px solid #8899aa;
    position: relative;
    margin-bottom: 0.5rem;
}

.se-zertifikate__platzhalter-siegel::after {
    content: '✓';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.6rem;
    color: #8899aa;
}

.se-zertifikate__platzhalter-text {
    font-weight: bold;
    font-size: 0.85em;
    color: #556;
    margin: 0;
}

.se-zertifikate__platzhalter-hinweis {
    font-size: 0.75em;
    color: #889;
    margin: 0;
    line-height: 1.4;
}

.se-zertifikate__label {
    text-align: center;
    font-size: 0.85em;
    padding: 0.4rem 0.5rem;
    margin: 0;
    color: #444;
    border-top: 1px solid #eee;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Lightbox */
.se-zertifikate__lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.se-zertifikate__lightbox--aktiv {
    display: flex;
}

.se-zertifikate__lightbox-inhalt {
    position: relative;
    max-width: min(90vw, 600px);
    width: 100%;
    text-align: center;
}

.se-zertifikate__lightbox-bild {
    width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
}

.se-zertifikate__lightbox-titel {
    color: #fff;
    margin: 0.75rem 0 0;
    font-size: 1em;
}

.se-zertifikate__lightbox-schliessen {
    position: absolute;
    top: -2.5rem;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

/* Videos-Karussell */
.se-videos {
    clear: both;
    padding-top: 3.5rem;
    margin: 0 0 2rem;
}

.se-videos__titel {
    margin: 0 0 20px 0;
    padding: 0 0 5px 0;
    border-bottom: 1px solid #ddd;
}

.se-videos__karussell {
    overflow: hidden;
    width: 100%;
}

.se-videos__spur {
    display: flex;
    will-change: transform;
}

.se-videos__karte {
    /* Breite wird dynamisch per inline-style in section-videos.php gesetzt */
    padding: 0 0.75rem;
    box-sizing: border-box;
}

.se-videos__rahmen {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    background: #000;
    transition: box-shadow 0.2s ease;
}

.se-videos__rahmen:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
}

.se-videos__link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* 16:9-Seitenverhältnis */
.se-videos__bild-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #111;
    overflow: hidden;
}

.se-videos__bild {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
}

/* Platzhalterbild wenn kein Thumbnail verfügbar */
.se-videos__platzhalter {
    display: none;
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #1a1a2e;
    border: 2px dashed #445;
    text-align: center;
    padding: 1rem;
    box-sizing: border-box;
}

.se-videos__platzhalter--sichtbar,
.se-videos__bild-container--fehler .se-videos__platzhalter {
    display: flex;
}

.se-videos__platzhalter-innen {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

/* Dreieck-Play im Platzhalter */
.se-videos__platzhalter-play {
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 1.2rem 0 1.2rem 2rem;
    border-color: transparent transparent transparent #556;
    margin-bottom: 0.5rem;
}

.se-videos__platzhalter-hinweis {
    font-size: 0.75em;
    color: #889;
    margin: 0;
    line-height: 1.4;
}

/* Play-Overlay auf dem Thumbnail */
.se-videos__play-overlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 3.5rem;
    height: 3.5rem;
    background: rgba(0,0,0,0.40);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    pointer-events: none;
}

.se-videos__link:hover .se-videos__play-overlay {
    background: rgba(255,0,0,0.85);
    transform: translate(-50%, -50%) scale(1.1);
}

.se-videos__play-icon {
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0.6rem 0 0.6rem 1.1rem;
    border-color: transparent transparent transparent #fff;
    margin-left: 0.15rem;
}

/* Referenzen-Karussell */
.se-referenzen {
    clear: both;
    margin: 1.5rem 0;
}

.se-referenzen__titel {
    margin: 0 0 20px 0;
    padding: 0 0 5px 0;
    border-bottom: 1px solid #ddd;
}

.se-referenzen__intro {
    margin: 0 0 1.5rem;
    font-size: 0.95em;
    color: #444;
    line-height: 1.65;
}

.se-referenzen__intro p {
    margin: 0;
}

.se-referenzen__buehne-link,
.se-referenzen__buehne-link:hover {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 4px;
}

.se-referenzen__buehne-link:hover .se-referenzen__buehne {
    background: #eaf0f8;
}

.se-referenzen__buehne {
    display: grid;
    min-height: 6em;
    background: #f4f7fa;
    border-radius: 4px;
    padding: 2rem;
}

.se-referenzen__karte {
    grid-area: 1 / 1;
    opacity: 0;
    transition: opacity 0.6s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.se-referenzen__karte--aktiv {
    opacity: 1;
}

.se-referenzen__name {
    font-size: 3em;
    font-weight: 200;
    font-family: 'Titillium Web', sans-serif;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
    line-height: 1.2;
}

.se-referenzen__ort {
    font-size: 1.2em;
    font-weight: 200;
    color: #595959;
    margin: 0.3em 0 0;
}

@media (max-width: 767px) {
    .se-referenzen__name {
        font-size: 1.8em;
    }
}

/* Presse-Slider */
.se-slider {
    clear: both;
    margin: 1.5rem 0;
}

.se-slider__titel {
    margin: 0 0 20px 0;
    padding: 0 0 5px 0;
    border-bottom: 1px solid #ddd;
}

/* Mehr Abstand vor den Leistungsboxen */
.se-leistungen {
    margin-top: 3rem;
}

/* Platzhalter fuer noch nicht befuellte Seitenbereiche */
.se-placeholder {
    clear: both;
    border: 2px dashed #aaa;
    background: #f5f5f5;
    border-radius: 6px;
    padding: 2rem;
    text-align: center;
    margin: 1.5rem 0;
    color: #888;
}
.se-placeholder__label {
    font-size: 1.4em;
    font-weight: bold;
    margin: 0 0 0.4em;
}
.se-placeholder__note {
    margin: 0;
    font-style: italic;
}
