:root {
    --color-white: #ffffff;
    --color-bg: #fafafa;
    --color-gray: #f5f5f5;
    --color-anthracite: #121619;
    --color-text: #333333;
    --color-accent: #2c57d2; /* ARKN Blau */
    --header-height: 80px;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.4;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease, background-color 0.3s ease;
}

a:hover { 
    color: var(--color-accent); 
}

/* --- Header & Navigation --- */
header {
    background: rgba(255, 255, 255, 1);
    position: fixed;
    width: 100%;
    height: var(--header-height);
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid #eaeaea;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.nav-container {
    max-width: 1400px;
    height: 100%;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 40px;
    width: auto;
    display: block;
}

/* Zentrierte Navigation */
ul.main-nav {
    display: flex;
    justify-content: center;
    flex: 1;
    list-style: none;
    gap: 1.5rem;
    height: 100%;
    margin: 0 1rem;
}

ul.main-nav > li {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
}

ul.main-nav > li > a {
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    height: 100%;
}

/* Dropdown Setup Desktop */
ul.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--color-white);
    min-width: 240px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    list-style: none;
    padding: 1rem 0;
    border-top: 2px solid var(--color-accent);
}

ul.main-nav > li:hover ul.dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

ul.dropdown li a {
    display: block;
    padding: 0.6rem 1.5rem;
    font-size: 0.9rem;
    text-transform: none;
    color: var(--color-text);
}

ul.dropdown li a:hover {
    background-color: var(--color-gray);
    color: var(--color-accent);
}

/* --- Mobile Hamburger Button --- */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1002;
}

.mobile-menu-btn svg {
    width: 30px;
    height: 30px;
    fill: var(--color-anthracite);
}

/* --- Floating Contact Bar --- */
.side-contact-bar {
    position: fixed;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 1001;
}

.side-contact-bar a {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 1px solid #d1d1d1;
    background: var(--color-white);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-anthracite);
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

.side-contact-bar a:hover {
    border-color: var(--color-anthracite);
    transform: scale(1.05);
}

.side-contact-bar a svg { 
    width: 20px; 
    height: 20px; 
    fill: currentColor; 
}

/* --- Sektionen & Typografie --- */
section {
    padding: 3rem 2rem;
    position: relative;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

.section-title {
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: 1.5rem;
    color: var(--color-anthracite);
    border-bottom: 2px solid var(--color-accent);
    display: inline-block;
    padding-bottom: 5px;
}

/* --- Full Width Hero Sektion --- */
.hero-section {
    margin-top: var(--header-height);
    width: 100vw;
    max-width: 100%;
    background-color: var(--color-anthracite); 
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    padding: 4rem 2rem;
    color: var(--color-white);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1400px;
    margin: 0 auto;
    text-align: center;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}

.hero-contact-bar {
    font-size: 0.95rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    margin-bottom: 0.8rem;
    color: #ffffff;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    align-items: center;
}

.hero-contact-bar .separator { 
    color: var(--color-accent); 
    text-shadow: none; 
}

.hero-section h1 {
    font-size: 3.5rem;
    font-weight: 300;
    line-height: 1.1;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
    color: var(--color-white);
}

.hero-subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    line-height: 1.4;
    margin-bottom: 1.5rem;
    color: #ffffff;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Buttons --- */
.btn-group { 
    display: flex; 
    justify-content: center; 
    gap: 15px; 
    flex-wrap: wrap; 
    margin-top: 1.5rem; 
    margin-bottom: 1.5rem; 
}

.btn {
    display: inline-block;
    padding: 0.8rem 2.5rem;
    background-color: transparent;
    color: var(--color-anthracite);
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    border: 1px solid var(--color-anthracite);
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:hover { 
    background-color: var(--color-anthracite); 
    color: var(--color-white); 
}

.hero-section .btn { 
    border-color: var(--color-white); 
    color: var(--color-white); 
    text-shadow: none;
}

.hero-section .btn:hover { 
    background-color: var(--color-white); 
    color: var(--color-anthracite); 
}

/* --- Leistungskacheln (Text-Kacheln oben) --- */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2px;
    background-color: #eaeaea;
    border: 1px solid #eaeaea;
}

.service-card {
    background-color: var(--color-white);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 3rem 2rem;
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.service-card:hover { 
    transform: translateY(-2px); 
}

.service-card > * {
    position: relative;
    z-index: 2;
}

.service-card .icon-plus { 
    font-size: 1.5rem; 
    font-weight: 300; 
    margin-bottom: 1rem; 
    color: var(--color-accent); 
}

.service-card h3 { 
    font-size: 1.4rem; 
    font-weight: 400; 
    margin-bottom: 0.8rem; 
    color: var(--color-anthracite); 
}

.service-card p { 
    color: #4a4a4a; 
    font-size: 1rem; 
    line-height: 1.6; 
    margin: 0; 
}

/* SEO Bild-Optimierung für die 2026 Wide Card */
.wide-card {
    grid-column: 1 / -1;
    margin-bottom: 2px;
    padding: 4rem 2rem;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-image: none !important; 
    z-index: 1;
}

.wide-card .card-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; 
    z-index: -1; 
}

.wide-card > div,
.wide-card > h3,
.wide-card > p {
    position: relative;
    z-index: 2;
}

/* --- Archiv Karten (Glassmorphism & SEO Images - Homogen zu Text-Kacheln) --- */
.archive-card {
    background-color: var(--color-white);
    position: relative;
    overflow: hidden;
    display: block;
    aspect-ratio: 4/3;
    transition: all 0.4s ease; 
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.archive-card:hover {
    transform: translateY(-2px);
}

.archive-card .card-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.archive-card:hover .card-bg-img {
    transform: scale(1.05);
}

/* Der Glassmorphismus (Heller Text-Container, Ausrichtung und Padding exakt wie Leistungskacheln) */
.archive-content-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    box-sizing: border-box; 
    padding: 2rem; 
    background: rgba(255, 255, 255, 0.85); 
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    text-align: left; 
    z-index: 1;
    transform: translateY(0); 
    border-top: 1px solid rgba(255,255,255,0.8);
}

.archive-content-overlay h3 {
    margin: 0 0 5px 0;
    font-size: 1.4rem; 
    font-weight: 400; 
    color: var(--color-anthracite);
}

.archive-content-overlay p {
    margin: 0;
    font-size: 1rem; 
    color: #4a4a4a;
    line-height: 1.6;
}

/* --- SEO Akkordeon --- */
.seo-accordion {
    background-color: #e9ecef;
    border-radius: 1px;
    margin-top: 2px;
    transition: all 0.3s ease;
}

.seo-accordion:first-of-type { 
    margin-top: 2rem; 
}

.seo-accordion summary {
    padding: 1.5rem 2rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
}

.seo-accordion summary::-webkit-details-marker { 
    display: none; 
}

.seo-accordion summary h3 { 
    font-size: 1.2rem; 
    color: #334; 
    text-transform: uppercase; 
    font-weight: 400; 
    margin: 0; 
}

.seo-accordion .icon-plus {
    font-size: 2rem;
    font-weight: 300;
    color: var(--color-accent);
    transition: transform 0.3s ease;
    line-height: 1;
}

.seo-accordion[open] .icon-plus { 
    transform: rotate(45deg); 
}

.seo-content {
    padding: 0 2rem 2rem 2rem;
    border-top: 1px solid #d1d1d1;
    margin-top: 1px;
    padding-top: 1.5rem;
    line-height: 1.6;
}

/* --- Historischer Scroll-Slider --- */
.historien-filmstreifen {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 2px; 
    margin: 1.5rem 0;
    background-color: #eaeaea; 
    border: 1px solid #eaeaea;
    scrollbar-width: thin; 
    scrollbar-color: var(--color-accent) #f1f1f1;
}

.historien-filmstreifen::-webkit-scrollbar { 
    height: 8px; 
}

.historien-filmstreifen::-webkit-scrollbar-track { 
    background: #f1f1f1; 
}

.historien-filmstreifen::-webkit-scrollbar-thumb { 
    background: var(--color-accent); 
}

.historien-karte {
    flex: 0 0 320px; 
    scroll-snap-align: start; 
    background: var(--color-white);
    padding: 2rem; 
    display: flex;
    flex-direction: column;
    justify-content: flex-start; 
    height: auto; 
    transition: background-color 0.4s ease;
}

.historien-karte:hover { 
    background: #fdfdfd; 
}

.karte-jahr { 
    font-size: 1.3rem; 
    color: var(--color-accent); 
    font-weight: 300; 
    margin-bottom: 1rem; 
}

.karte-bild { 
    width: 100%; 
    height: 180px; 
    overflow: hidden; 
    margin-bottom: 1.5rem; 
    background: #fff; 
}

.karte-bild img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    object-position: center top; 
    transition: transform 0.5s ease; 
}

.karte-bild img:hover { 
    transform: scale(1.03); 
}

.karte-titel { 
    font-weight: 400; 
    font-size: 1.3rem; 
    margin: 0 0 0.8rem 0; 
    color: var(--color-anthracite); 
}

.karte-text { 
    font-size: 0.95rem; 
    color: #666; 
    line-height: 1.6; 
    margin: 0; 
}

/* --- Kontakt Final Banner --- */
.final-contact-banner {
    text-align: center;
    padding: 3rem 2rem;
    background-color: var(--color-white);
    border-top: 1px solid #eaeaea;
}

.final-contact-banner h2 { 
    font-size: 1.8rem; 
    font-weight: 300; 
    margin-bottom: 1rem; 
    color: var(--color-anthracite); 
}

.experience-text {
    max-width: 900px;
    margin: 0 auto;
    color: #555;
    font-size: 1rem;
    line-height: 1.7;
}

/* --- Footer --- */
footer {
    background-color: var(--color-anthracite);
    color: #999;
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
}

footer a { 
    color: #ccc; 
    margin: 0 15px; 
}

footer a:hover { 
    color: var(--color-accent); 
}

/* --- Mobile Breakpoints --- */
@media (max-width: 1024px) {
    .nav-container { padding: 0 1rem; }
    ul.main-nav { gap: 1rem; }
}

@media (max-width: 900px) {
    .side-contact-bar { display: none; }
    .hero-section h1 { font-size: 2.5rem; }
    .mobile-menu-btn { display: block; }
    
    ul.main-nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background: var(--color-white);
        height: auto;
        padding: 1rem 0;
        box-shadow: 0 10px 15px rgba(0,0,0,0.05);
        gap: 0;
        margin: 0;
    }

    ul.main-nav.mobile-active { 
        display: flex; 
        max-height: calc(100vh - var(--header-height)); 
        overflow-y: auto; 
    }
    
    ul.main-nav > li {
        height: auto;
        width: 100%;
        border-bottom: 1px solid #f0f0f0;
        flex-direction: column; 
        align-items: flex-start;
    }

    ul.main-nav > li > a { 
        padding: 1rem 1.5rem; 
        width: 100%; 
        justify-content: flex-start; 
    }

    ul.dropdown {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        border-top: none;
        background: #fcfcfc;
        padding: 0;
        display: none; 
        width: 100%;
        border-left: 4px solid var(--color-accent);
    }

    ul.dropdown li a { 
        padding: 0.8rem 1.5rem 0.8rem 2.5rem; 
        border-bottom: 1px solid #eaeaea; 
    }
    
    ul.dropdown li:last-child a { 
        border-bottom: none; 
    }
    
    .seo-accordion summary { 
        padding: 1.5rem; 
    }
    
    .seo-content { 
        padding: 0 1.5rem 2rem 1.5rem; 
    }
}


/* ==========================================================================
   NEUE ERGÄNZUNGEN: Hero-Höhe & Vorher-Nachher-Slider
   ========================================================================== */

/* Fixierte, einheitliche Höhe für den Hero-Bereich unabhängig vom Textvolumen */
.hero-uniform-height {
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Mobile Menu Fix - Verschiebt den Burger-Button nach rechts */
@media (max-width: 959px) {
    .nav-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    #mobileMenuToggle {
        margin-left: auto; 
    }
}

/* Vorher-Nachher Slider CSS */
.comparison-slider {
    position: relative;
    width: 100%;
    max-width: 1400px;
    margin: 2rem auto;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.comparison-slider > img {
    width: 100%;
    height: auto;
    display: block;
}

.comparison-slider .overlay-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%);
}

.comparison-slider .overlay-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
}

.comparison-range {
    position: absolute;
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: transparent;
    outline: none;
    margin: 0;
    cursor: ew-resize;
    z-index: 10;
}

.comparison-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 40px;
    height: 40px;
    background: var(--color-accent, #e14e1a);
    border: 3px solid #fff;
    border-radius: 50%;
    cursor: ew-resize;
    box-shadow: 0 0 15px rgba(0,0,0,0.4);
}

.comparison-range::-moz-range-thumb {
    width: 40px;
    height: 40px;
    background: var(--color-accent, #e14e1a);
    border: 3px solid #fff;
    border-radius: 50%;
    cursor: ew-resize;
    box-shadow: 0 0 15px rgba(0,0,0,0.4);
}

.comparison-label {
    position: absolute;
    bottom: 20px;
    padding: 8px 18px;
    background: rgba(0,0,0,0.7);
    color: white;
    font-size: 0.95rem;
    border-radius: 30px;
    pointer-events: none;
    z-index: 5;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.label-before { left: 20px; }
.label-after { right: 20px; }

/* Regler-Trennlinie */
.slider-divider {
    position: absolute;
    top: 0;
    left: 50%;
    width: 3px;
    height: 100%;
    background: white;
    z-index: 4;
    pointer-events: none;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
    transform: translateX(-50%);
}

/* ==========================================================================
   FINALE ANPASSUNGEN (Kacheln, Blurry Overlay & Mobile aus style.css)
   ========================================================================== */

/* Reduziert die Abstände in den normalen Kacheln */
.service-card {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
}

/* Reduziert die Abstände der breiten Sonderkachel explizit */
.wide-card {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

/* Reduziert die Höhe und Textgröße des Blurry-Overlays im Archiv massiv */
.archive-content-overlay {
    padding: 8px 12px !important;
}
.archive-content-overlay h3 {
    margin-bottom: 2px !important;
    font-size: 1rem !important;
}
.archive-content-overlay p {
    margin-bottom: 0 !important;
    line-height: 1.2 !important;
    font-size: 0.9rem !important;
}

/* Dark Mode Fix für die Archiv-Kacheln */
@media (prefers-color-scheme: dark) {
    .archive-content-overlay {
        background-color: rgba(255, 255, 255, 0.9) !important;
    }
    .archive-content-overlay h3, .archive-content-overlay p {
        color: #1a1a1a !important;
    }
}

/* --- Scroll To Top Button Styles --- */
#scrollToTopBtn {
    display: none;
    position: fixed;
    bottom: 80px; 
    right: 20px;
    z-index: 9999;
    background-color: var(--color-accent, #0056b3);
    color: white;
    border: none;
    outline: none;
    cursor: pointer;
    padding: 12px;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: opacity 0.3s, background-color 0.3s;
}
#scrollToTopBtn:hover {
    background-color: #333;
}
#scrollToTopBtn svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
    display: block;
}

/* --- MOBILE OPTIMIERUNGEN (max-width: 959px) --- */
@media (max-width: 959px) {
    
    /* Spacing massiv reduzieren (Scroll-Marathon beenden) */
    section { 
        padding-top: 1.5rem !important; 
        padding-bottom: 1.5rem !important; 
    }
    .section-title { 
        margin-bottom: 1rem !important; 
        font-size: 1.4rem !important; 
    }
    
    /* Kacheln fugenlos zusammensetzen (2px statt 15px) */
    .grid-3 {
        gap: 2px !important; 
    }
    
    /* Leistungs-Kacheln auf Mobile extrem verdichten */
    .service-card {
        padding: 1.2rem 1rem !important; 
    }
    .service-card .icon-plus {
        margin-bottom: 0.5rem !important;
    }
    .service-card h3 {
        margin-bottom: 0.5rem !important;
        font-size: 1.15rem !important;
    }
    
    /* Archiv-Bilder flacher machen (16:9 Panorama statt 4:3) spart vertikal enorm Platz */
    .archive-card {
        aspect-ratio: 16/9 !important; 
    }
    
    /* Texte ausblenden, um Scrollen zu minimieren (nur mobil) */
    .service-card p, .historien-karte .karte-text {
        display: none !important;
    }
    
    /* Schwebende Desktop-Kontaktleiste wird auf dem Handy ausgeblendet */
    .side-contact-bar {
        display: none !important;
    }
}