/* ==========================================================================
   CSS Variablen & Core-Setup
   ========================================================================== */
:root {
    /* Color Palette */
    --color-bg: #fbfbfd;
    --color-bg-alt: #f5f5f7;
    --color-text-main: #1d1d1f;
    --color-text-muted: #6e6e73;
    
    /* Branding Gold Accent */
    --color-gold: #c5a880;
    --color-gold-light: rgba(197, 168, 128, 0.15);
    
    /* System Accents */
    --color-silver: #a1a1aa;
    --color-silver-light: rgba(161, 161, 170, 0.15);
    --color-purple: #a855f7;
    --color-purple-light: rgba(168, 85, 247, 0.15);

    /* Glassmorphism Configuration */
    --glass-bg: rgba(255, 255, 255, 0.65);
    --glass-border: rgba(255, 255, 255, 0.8);
    --glass-shadow: 0 20px 50px rgba(0, 0, 0, 0.04);
    
    /* Animation & Type Defaults */
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --font-stack: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", Arial, sans-serif;
}

/* Base Reset & Mobile Tap Protection */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    -webkit-tap-highlight-color: transparent !important; 
}

html { 
    scroll-behavior: smooth; 
    overflow-x: hidden; 
}

body {
    font-family: var(--font-stack);
    background-color: var(--color-bg);
    color: var(--color-text-main);
    line-height: 1.6;
    letter-spacing: -0.015em;
    overflow-x: hidden;
}

/* Background animated wave canvas */
#bg-canvas {
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100vw; 
    height: 100vh;
    z-index: -1; 
    pointer-events: none; 
    opacity: 0.8;
}

/* ==========================================================================
   Typografie & Utilities
   ========================================================================== */
h1, h2, h3, h4 { 
    font-weight: 800; 
    line-height: 1.2; 
    letter-spacing: -0.03em; 
}

/* Prevents overflow, handles responsive breaks cleanly */
.two-lines {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
}

/* Responsive Font-Sizes */
h1 { font-size: 3.5rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.1rem; }

a { 
    text-decoration: none; 
    color: inherit; 
}

ul { list-style: none; }
button { 
    cursor: pointer; 
    border: none; 
    background: none; 
    font-family: inherit; 
    outline: none; 
}

/* Colors Utilities */
.text-gold { color: var(--color-gold) !important; }
/* Gold-Akzent im hellen Footer-Logo abgedunkelt: erfuellt WCAG-Kontrast (>=3:1) */
.logo-text-footer .text-gold { color: #9c7b46 !important; }
.text-silver { color: var(--color-silver) !important; }
.text-purple { color: var(--color-purple) !important; }
.text-muted { color: var(--color-text-muted) !important; }
.text-main { color: var(--color-text-main) !important; }

/* Font Utilities */
.text-small { font-size: 0.875rem; }
.text-xsmall { font-size: 0.75rem; }
.text-large { font-size: 1.1rem; }
.text-center { text-align: center; }
.text-left { text-align: left; }
.font-bold { font-weight: 700; }
.uppercase { text-transform: uppercase; }
.tracking-wide { letter-spacing: 0.05em; }

/* Background Utilities */
.bg-gold { background-color: var(--color-gold); }
.bg-silver { background-color: var(--color-silver); }
.bg-purple { background-color: var(--color-purple); }
.bg-gold-light { background-color: var(--color-gold-light); }
.bg-silver-light { background-color: var(--color-silver-light); }
.bg-purple-light { background-color: var(--color-purple-light); }
.bg-alt { background-color: rgba(245, 245, 247, 0.85); }
.bg-opaque { background-color: var(--color-bg-alt); }

.subtitle {
    font-size: 0.75rem; 
    font-weight: 700; 
    text-transform: uppercase;
    letter-spacing: 0.12em; 
    display: block; 
    margin-bottom: 0.5rem;
}

/* Gold Divider Rules */
.divider {
    height: 3px;
    width: 120px;
    border-radius: 3px;
    margin-top: 2.5rem;
    margin-bottom: 2.5rem;
}
/* Partnership intro: bring the grey subheading closer to the divider (it sat too far down) */
#partnership .reveal > .divider { margin-bottom: 1.75rem; }
#partnership .reveal > p { margin-top: 0; }
/* Partnership intro: more breathing room before the two cards below */
#partnership .reveal.max-w-center { margin-bottom: 2rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.text-right { text-align: right; }

/* Spacing Utilities */
.space-y > * + * { margin-top: 1rem; }
.mb-xsmall { margin-bottom: 0.5rem; }
.mb-small { margin-bottom: 1rem; }
.mb-medium { margin-bottom: 1.5rem; }
.mb-large { margin-bottom: 2.5rem; }
.mb-xlarge { margin-bottom: 4rem; }
.mb-xxlarge { margin-bottom: 6rem; }
.mt-xsmall { margin-top: 0.5rem; }
.mt-small { margin-top: 1rem; }
.mt-medium { margin-top: 1.5rem; }
.mt-large { margin-top: 2.5rem; }
.hidden { display: none !important; }
/* Accessible visually-hidden (keeps content in the a11y tree & for crawlers) */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Misc text + staggered reveal helpers (replaces former inline styles) */
.lh-relaxed { line-height: 1.8; }
.delay-1 { transition-delay: 100ms; }
.delay-2 { transition-delay: 200ms; }

/* ==========================================================================
   Layouts & Flexbox Grid System
   ========================================================================== */
.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 2.5rem; 
    width: 100%; 
}
.max-w-center { max-width: 800px; margin: 0 auto; }
.max-w-large { max-width: 1000px; margin: 0 auto; }

.section { 
    padding: 4.5rem 0; 
    position: relative; 
} 
.view-section { 
    min-height: 100vh; 
    animation: fadeIn 0.5s ease; 
}
.pt-xlarge { padding-top: 10rem; } 
.border-y { 
    border-top: 1px solid rgba(0,0,0,0.03); 
    border-bottom: 1px solid rgba(0,0,0,0.03); 
}

/* Page Flex Layout Flow Order */
.main-flex-container { 
    display: flex; 
    flex-direction: column; 
}
.flex-order-1 { order: 1; }
.flex-order-2 { order: 2; }
.flex-order-3 { order: 3; }
.flex-order-4 { order: 4; }
.flex-order-5 { order: 5; }
.flex-order-6 { order: 6; }
.flex-order-kontakt { order: 7; }
.flex-order-about { order: 8; }
.flex-order-referenzen { order: 9; }

/* Standard CSS Grids */
.grid-12 { display: grid; grid-template-columns: repeat(12, 1fr); gap: 3rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 3rem; }

/* Grid Spanning */
.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; }
.col-8 { grid-column: span 8; }

.align-center { align-items: center; }
.align-start { align-items: flex-start; }
.align-stretch { align-items: stretch; }
.flex-col-between { display: flex; flex-direction: column; justify-content: space-between; height: 100%; }
.flex-center { display: flex; align-items: center; justify-content: center; gap: 0.5rem; }
.flex-right { display: flex; justify-content: flex-end; gap: 1.5rem; align-items: center; }

/* ==========================================================================
   Komponenten (Liquid Glass, Buttons, Navigation, Menus)
   ========================================================================== */
.liquid-glass {
    background: var(--glass-bg);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: 2rem;
}

.liquid-glass.interactive { transition: var(--transition-smooth); }
.liquid-glass.hover-gold:hover { border-color: var(--color-gold); transform: translateY(-4px); }
.liquid-glass.hover-silver:hover { border-color: var(--color-silver); transform: translateY(-4px); }
.liquid-glass.hover-purple:hover { border-color: var(--color-purple); transform: translateY(-4px); }

.card { padding: 2.5rem; }
.card-compact { padding: 2rem; } 
.card .number { font-size: 2.5rem; font-weight: 800; margin-bottom: 1.5rem; }

/* Global Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 1.2rem 2.5rem;
    border-radius: 50px; 
    font-size: 0.8rem; 
    font-weight: 700;
    text-transform: uppercase; 
    letter-spacing: 0.1em; 
    transition: var(--transition-smooth);
}
.btn svg {
    width: 1.15rem;
    height: 1.15rem;
}
.btn-gold {
    background-color: var(--color-gold);
    color: #1d1d1f; 
    box-shadow: 0 4px 14px rgba(197, 168, 128, 0.25); 
}
.btn-gold:hover { 
    background-color: #b89b72; 
    transform: scale(1.02); 
}
.btn-outline { 
    background: rgba(255,255,255,0.5); 
    border: 1px solid rgba(0,0,0,0.1); 
    color: var(--color-text-main); 
}
.btn-outline:hover { 
    background: #fff; 
    border-color: var(--color-gold); 
}
.btn-full { 
    width: 100%; 
    padding: 1.4rem; 
}

/* Header & Menu links */
.nav-container { 
    position: fixed; 
    top: 2.75rem; 
    left: 0; 
    width: 100%; 
    z-index: 50; 
    padding: 0 2rem; 
    pointer-events: none; 
    transition: top 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.nav-container.scrolled-header { top: 0.75rem; }
.header { 
    position: relative; 
    max-width: 1200px; 
    margin: 0 auto; 
    height: 5rem; 
    padding: 0 2.5rem; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    pointer-events: auto; 
}
.desktop-nav a { 
    font-size: 0.75rem; 
    font-weight: 700; 
    text-transform: uppercase; 
    letter-spacing: 0.1em; 
    color: var(--color-text-main); 
    padding: 0.5rem 1rem; 
    border-radius: 50px; 
    transition: var(--transition-smooth); 
}
.desktop-nav a:hover {
    color: var(--color-text-main);
    background: rgba(0,0,0,0.04);
}
/* Referenzen dropdown (desktop nav) — opens on hover or keyboard focus */
.nav-dropdown { position: relative; display: inline-flex; align-items: center; vertical-align: middle; }
.nav-dropdown-toggle { display: inline-flex; align-items: center; gap: 0.25rem; }
.nav-dropdown-caret { width: 14px; height: 14px; transition: transform 0.3s ease; }
.nav-dropdown:hover .nav-dropdown-caret,
.nav-dropdown:focus-within .nav-dropdown-caret { transform: rotate(180deg); }
.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    margin-top: 0.5rem;
    padding: 0.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 1rem;
    box-shadow: var(--glass-shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: var(--transition-smooth);
    z-index: 50;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-dropdown-menu a { display: block; }

/* Referenzen section */
.reference-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 2.5rem; }
.reference-card { max-width: 420px; flex: 1 1 320px; }
.reference-logo { display: inline-block; margin-bottom: 1rem; }
.reference-logo-img { height: 2.2rem; width: auto; display: block; }
.reference-logo:hover { opacity: 0.75; }
.reference-link {
    display: inline-block;
    margin-top: 1.25rem;
    font-weight: 700;
    color: var(--color-gold);
}
.reference-link:hover { opacity: 0.75; }
.logo { cursor: pointer; }
.logo img { height: 1.5rem; filter: contrast(0%) brightness(10%); }
.logo-text-header { font-size: 1.5rem; font-weight: 800; color: var(--color-text-main); }
.logo-text-footer { font-size: 1.5rem; font-weight: 800; }
.mobile-menu-btn { display: none; color: var(--color-text-main); }

/* ==========================================================================
   Leistungen Section (System intro spacing + Service spectrum)
   ========================================================================== */
/* Tighten the gap divider -> intro paragraph (same treatment as #partnership) */
#system .reveal > .divider,
#leistungen .reveal > .divider { margin-bottom: 1.5rem; }
#system .reveal > p,
#leistungen .reveal > p { margin-top: 0; line-height: 1.8; }
/* .max-w-center's `margin:0 auto` cancels mb-large on the header block, so the
   intro paragraph sat directly on the content. Restore a proper gap (like #partnership). */
#system .reveal.max-w-center,
#leistungen .reveal.max-w-center { margin-bottom: 2rem; }

/* Service spectrum: one cohesive grid of all deliverables */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}
.service-tile {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    padding: 1.6rem;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 1.2rem;
    transition: var(--transition-smooth);
}
.service-tile:hover { transform: translateY(-4px); border-color: var(--color-gold); }
.service-tile .icon-box { width: 46px; height: 46px; border-radius: 13px; }
.service-tile h4 { font-size: 1.02rem; }
.service-tile > p { font-size: 0.85rem; color: var(--color-text-muted); line-height: 1.55; }

/* Featured testimonial tile spans the full row and sits on top */
.service-tile.is-feature {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: flex-start;
    gap: 1.5rem;
    background: var(--color-gold-light);
    border-color: var(--color-gold);
}
.service-tile.is-feature .icon-box { width: 58px; height: 58px; border-radius: 16px; flex-shrink: 0; }
.service-feature-body { display: flex; flex-direction: column; gap: 0.6rem; }
.service-feature-head { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.service-feature-head h4 { font-size: 1.25rem; }
.service-feature-body p { font-size: 0.92rem; color: var(--color-text-muted); line-height: 1.6; }
.service-result { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; }
.badge.border-gold { border-color: var(--color-gold); color: var(--color-gold); }

/* "Für wen wir arbeiten" — smaller, compact cards */
.audience-grid { gap: 1.25rem; }
.audience-card { padding: 1.75rem; }
.audience-card .number { font-size: 1.75rem; margin-bottom: 0.6rem; }
.audience-card h3 { font-size: 1.15rem; }
.audience-card p { font-size: 0.88rem; color: var(--color-text-muted); line-height: 1.6; }

@media (max-width: 1023px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    /* Compact 2-up tiles so the spectrum doesn't become a long scroll on phones */
    .services-grid { grid-template-columns: repeat(2, 1fr); gap: 0.7rem; }
    .service-tile { padding: 1.05rem; gap: 0.45rem; }
    .service-tile .icon-box { width: 38px; height: 38px; border-radius: 11px; }
    .service-tile h4 { font-size: 0.84rem; }
    .service-tile > p { display: none; }
    .service-tile.is-feature { grid-column: 1 / -1; flex-direction: column; padding: 1.3rem; }
    .service-tile.is-feature .icon-box { width: 48px; height: 48px; }
    .service-feature-head h4 { font-size: 1.1rem; }
}

/* Top Bar (Kopfzeile) & Language Switcher — visible on all breakpoints,
   switcher always top-right inside the bar, collapses on scroll */
.top-bar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 2.5rem;
    padding: 0 1rem;
    background: rgba(251, 251, 253, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    pointer-events: auto;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    z-index: 1002;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease, visibility 0.4s;
}
@media (min-width: 1280px) {
    .top-bar { padding: 0 4rem; }
}
.top-bar.hidden-top-bar {
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
}
.language-switcher {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    background: transparent;
    border: none;
    padding: 0;
    pointer-events: auto;
}
.lang-btn {
    background: none;
    border: none;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-text-muted);
    cursor: pointer;
    padding: 0.25rem 0.6rem;
    border-radius: 9999px;
    transition: var(--transition-smooth);
}
.lang-btn:hover { color: var(--color-text-main); }
.lang-btn.active { color: #1d1d1f; background: var(--color-gold); }
.lang-separator { font-size: 0.75rem; color: var(--color-text-muted); opacity: 0.5; user-select: none; }

/* Mobile Menu Panel */
.mobile-menu {
    position: fixed;
    top: 8.25rem;
    left: 1rem;
    right: 1rem;
    padding: 2.5rem;
    z-index: 49;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
    visibility: hidden;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.3s, top 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.nav-container.scrolled-header ~ .mobile-menu { top: 6.25rem; }
.mobile-menu.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    visibility: visible;
}
.mobile-menu a { 
    font-weight: 700; 
    text-transform: uppercase; 
    font-size: 1rem; 
    color: var(--color-text-main); 
}
.mobile-menu .mobile-btn-black { 
    color: #1d1d1f !important; 
    white-space: nowrap; 
    width: 100%; 
    display: flex; 
    justify-content: center; 
    padding: 1.2rem; 
}

/* ==========================================================================
   Hero Redesign Layout Rules
   ========================================================================== */
.hero-section {
    padding-top: 14rem; 
    padding-bottom: 6rem;
}
.hero-container-redesigned {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    width: 100%;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
}
.hero-image-wrapper {
    width: 100%;
    display: flex;
    justify-content: flex-end;
}
.hero-img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
    border-radius: 2rem;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: var(--transition-smooth);
}
.hero-text-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.5rem;
}
.hero-word {
    font-size: 4rem;
    font-weight: 900;
    color: var(--color-text-main);
    line-height: 1.05;
    letter-spacing: -0.04em;
    text-transform: uppercase;
}
.hero-btn-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 1rem;
}

/* UI Badges */
.badge { 
    display: inline-flex; 
    align-items: center; 
    gap: 0.5rem; 
    padding: 0.5rem 1.2rem; 
    background: rgba(255,255,255,0.7); 
    border: 1px solid transparent; 
    border-radius: 50px; 
    font-size: 0.75rem; 
    font-weight: 700; 
    text-transform: uppercase; 
}
.badge.border-purple { 
    border-color: var(--color-purple-light); 
    color: var(--color-purple); 
}
.pulse-dot { 
    width: 8px; 
    height: 8px; 
    background: var(--color-purple); 
    border-radius: 50%; 
    animation: pulse 2s infinite; 
}

/* Feature Checklists */
.check-list { 
    display: flex; 
    flex-direction: column; 
    gap: 1.5rem; 
}
.check-list li { 
    display: flex; 
    align-items: center; 
    gap: 1rem; 
    font-weight: 600; 
    font-size: 1rem; 
}
.icon-box { 
    width: 50px; 
    height: 50px; 
    border-radius: 14px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-shrink: 0; 
}
.icon-box.large { 
    width: 65px; 
    height: 65px; 
    border-radius: 18px; 
}
.small-icon { 
    width: 20px; 
    height: 20px; 
}

/* ==========================================================================
   Before-After Slider Section
   ========================================================================== */
.staging-wrapper { 
    padding: 1rem; 
    border-radius: 2.5rem; 
    position: relative; 
}
.ba-slider { 
    position: relative; 
    width: 100%; 
    height: 500px; 
    border-radius: 1.5rem; 
    overflow: hidden; 
    background: #eee; 
}

/* Float Badges over Slider Image */
.ba-badge {
    position: absolute;
    top: 1.5rem;
    z-index: 20; 
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    font-weight: 800;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #1d1d1f;
    letter-spacing: 0.1em;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    border: 2px solid rgba(255,255,255,0.4);
    backdrop-filter: blur(10px);
    white-space: nowrap;
}
.ba-badge-left { left: 1.5rem; background-color: var(--color-gold); } 
.ba-badge-right { right: 1.5rem; background-color: var(--color-silver); }

.ba-image { 
    position: absolute; 
    top:0; 
    left:0; 
    width: 100%; 
    height: 100%; 
    background-size: cover; 
    background-position: center; 
}

/* Masking overlays static layers */
.ba-base { 
    background-image: url('assets/loft_before.webp');
    filter: grayscale(100%) brightness(0.8); 
    z-index: 1; 
}
.ba-overlay { 
    background-image: url('assets/loft_after.webp');
    z-index: 2; 
    -webkit-clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%); 
    clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%); 
}

/* Slider center dividing line */
.ba-slider-line { 
    position: absolute; 
    top: 0; 
    left: 50%; 
    width: 3px; 
    height: 100%; 
    background-color: var(--color-gold); 
    transform: translateX(-50%); 
    z-index: 4; 
    pointer-events: none; 
}
.ba-slider-range { 
    position: absolute; 
    top:0; 
    left:0; 
    width: 100%; 
    height: 100%; 
    opacity: 0; 
    cursor: ew-resize; 
    z-index: 10; 
}
.ba-slider-handle { 
    position: absolute; 
    top: 50%; 
    left: 50%; 
    transform: translate(-50%, -50%); 
    width: 22px; 
    height: 44px; 
    background: rgba(255, 255, 255, 0.7); 
    backdrop-filter: blur(10px); 
    -webkit-backdrop-filter: blur(10px); 
    border-radius: 30px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    box-shadow: 0 4px 20px rgba(0,0,0,0.15); 
    border: 1px solid rgba(255, 255, 255, 0.8); 
    z-index: 5; 
    pointer-events: none; 
}
.ba-slider-handle::after { 
    content: ''; 
    width: 2px; 
    height: 14px; 
    background: rgba(0,0,0,0.2); 
    border-radius: 2px; 
}

/* Feature Boxes */
.feature-box {
    display: flex; 
    align-items: center; 
    gap: 1.2rem; 
    padding: 1.2rem;
    background: rgba(255,255,255,0.6); 
    border-radius: 1.2rem;
    border: 1px solid rgba(0,0,0,0.03); 
    transition: var(--transition-smooth);
}
.compact-box { padding: 1rem; gap: 1rem; }
.feature-box p { font-size: 0.85rem; color: var(--color-text-muted); }

/* Absolute layout tags */
.corner-badge { 
    position: absolute; 
    top: 0; 
    right: 0; 
    padding: 0.75rem 1.5rem; 
    border-bottom-left-radius: 1.5rem; 
    border-top-right-radius: 2rem; 
    font-size: 0.7rem; 
    font-weight: bold; 
    text-transform: uppercase; 
    letter-spacing: 0.1em; 
}

.card-footer { 
    border-top: 1px solid rgba(0,0,0,0.05); 
    padding-top: 1.5rem; 
    display: flex; 
    justify-content: space-between; 
    font-size: 0.85rem; 
    font-weight: 600; 
    text-transform: uppercase; 
    color: var(--color-text-muted); 
}

/* Configurator Grid Elements */
.config-row {
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 1.2rem 1.5rem; 
    background: rgba(255,255,255,0.6);
    border: 1px solid rgba(0,0,0,0.03); 
    border-radius: 1.2rem;
    transition: var(--transition-smooth);
}
.compact-row { padding: 1rem 1.2rem; }
.counter { display: flex; align-items: center; gap: 1rem; }
.counter button { 
    width: 32px; 
    height: 32px; 
    border-radius: 50%; 
    background: #fff; 
    border: 1px solid rgba(0,0,0,0.1); 
    font-weight: bold; 
    transition: var(--transition-smooth); 
    font-size: 1rem; 
    outline: none; 
}
.counter button:hover { border-color: var(--color-gold); }
.counter span { font-size: 1.2rem; font-weight: bold; min-width: 25px; text-align: center; }

.toggle-btn {
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 1rem 1.2rem; 
    background: rgba(255,255,255,0.6); 
    border-radius: 1.2rem;
    border: 1px solid rgba(0,0,0,0.03); 
    transition: var(--transition-smooth); 
    outline: none;
}
.switch { 
    width: 42px; 
    height: 24px; 
    background: #e5e5ea; 
    border-radius: 20px; 
    position: relative; 
    transition: var(--transition-smooth); 
}
.switch .handle { 
    width: 18px; 
    height: 18px; 
    background: #fff; 
    border-radius: 50%; 
    position: absolute; 
    top: 3px; 
    left: 3px; 
    transition: var(--transition-smooth); 
    box-shadow: 0 2px 4px rgba(0,0,0,0.2); 
}
.toggle-btn.active .switch { background: var(--color-gold); }
.toggle-btn.active .switch .handle { transform: translateX(18px); }

.estimate-box { 
    background: rgba(255,255,255,0.8); 
    padding: 1.2rem; 
    border-radius: 1.2rem; 
    text-align: center; 
}

/* System Pillars & Accordions */
.pillar-tabs { 
    display: flex; 
    flex-direction: column; 
    gap: 1rem; 
}
.pillar-tab { 
    padding: 1.5rem 2rem; 
    border-radius: 1.5rem; 
    background: rgba(255,255,255,0.4); 
    border: 1px solid rgba(0,0,0,0.04); 
    cursor: pointer; 
    transition: var(--transition-smooth); 
    outline: none; 
}
.pillar-tab.active { 
    background: var(--glass-bg); 
    backdrop-filter: blur(20px); 
    border-color: rgba(255,255,255,0.8); 
    box-shadow: 0 10px 30px rgba(0,0,0,0.03); 
}
.tab-header { 
    display: flex; 
    align-items: center; 
    gap: 1.5rem; 
    position: relative; 
}
.tab-num { 
    font-size: 1.4rem; 
    font-weight: 800; 
}
.tab-icon { 
    position: absolute; 
    right: 0; 
    transition: transform 0.3s; 
}
.tab-icon.rotate { transform: rotate(180deg); }
.tab-content {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.05);
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Forms Setup */
.form-group { 
    display: flex; 
    flex-direction: column; 
    gap: 0.5rem; 
}
.form-group label { 
    font-size: 0.8rem; 
    font-weight: 700; 
    text-transform: uppercase; 
    color: var(--color-text-main); 
}
.form-group input, 
.form-group textarea { 
    width: 100%; 
    padding: 1.2rem 1.5rem; 
    border-radius: 1rem; 
    border: 1px solid rgba(0,0,0,0.08); 
    background: rgba(255,255,255,0.8); 
    font-family: inherit; 
    font-size: 1rem; 
    transition: var(--transition-smooth); 
    outline: none; 
}
.form-group input:focus, 
.form-group textarea:focus { 
    outline: none; 
    border-color: var(--color-purple); 
    box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.1); 
    background: #fff; 
}

/* ==========================================================================
   Footer Section Styling
   ========================================================================== */
.footer { padding: 4rem 0 2rem 0; }
.footer-links a,
.footer-links button {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--color-text-muted);
    transition: var(--transition-smooth);
}
/* Cookie-Einstellungen ist semantisch ein Button: Default-Optik zuruecksetzen,
   damit er sich nahtlos in die Footer-Links einreiht. */
.footer-links button {
    background: none;
    border: 0;
    padding: 0;
    font-family: inherit;
    cursor: pointer;
}
.footer-links a:hover,
.footer-links button:hover { color: var(--color-gold); }
.footer-bottom { 
    margin-top: 3rem; 
    padding-top: 2rem; 
    border-top: 1px solid rgba(0,0,0,0.05); 
    font-size: 0.8rem; 
    color: var(--color-text-muted); 
    text-transform: uppercase; 
    text-align: center; 
}

/* ==========================================================================
   Hilfsklassen & Animationen
   ========================================================================== */
.back-link { 
    display: inline-flex; 
    align-items: center; 
    gap: 0.5rem; 
    font-size: 0.9rem; 
    font-weight: 700; 
    text-transform: uppercase; 
    color: var(--color-gold); 
}
.back-link:hover { color: var(--color-text-main); }

.bg-glow { 
    position: absolute; 
    width: 600px; 
    height: 600px; 
    background: var(--color-gold-light); 
    border-radius: 50%; 
    filter: blur(100px); 
    z-index: -1; 
}
.bottom-fade { 
    position: fixed; 
    bottom: 0; 
    left: 0; 
    width: 100%; 
    height: 100px; 
    pointer-events: none; 
    background: linear-gradient(to top, var(--color-bg), transparent); 
    z-index: 40; 
    transition: opacity 0.5s; 
}

/* Toast Alerts */
.toast-container { 
    position: fixed; 
    top: 7rem; 
    right: 2rem; 
    z-index: 100; 
    display: flex; 
    flex-direction: column; 
    gap: 1rem; 
}
.toast { 
    background: #fff; 
    padding: 1.2rem 2rem; 
    border-radius: 1rem; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.1); 
    display: flex; 
    align-items: center; 
    gap: 1rem; 
    font-size: 0.9rem; 
    font-weight: 600; 
    border-left: 4px solid var(--color-gold); 
    animation: slideIn 0.3s ease forwards; 
}
.toast.success { border-color: #34c759; }
.toast.error { border-color: #ff3b30; }

/* Profile images formatting */
.profile-img {
    width: 65px;
    height: 65px;
    border-radius: 18px;
    object-fit: cover;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    display: block;
}
.profile-img.border-gold { border: 2px solid var(--color-gold); }
.profile-img.border-silver { border: 2px solid var(--color-silver); }

.desktop-nav a.active-nav {
    color: var(--color-text-main) !important;
    background: rgba(197, 168, 128, 0.08);
}

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(29, 29, 31, 0.2);
    border-radius: 50%;
    border-top-color: #1d1d1f;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

/* Keyframe Animations */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0.4); } 70% { box-shadow: 0 0 0 8px rgba(168, 85, 247, 0); } 100% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* Scroll reveal triggers */
.word-span { 
    display: inline-block; 
    opacity: 0; 
    transform: translateY(15px); 
    transition: opacity 0.6s ease, transform 0.6s ease; 
}
.reveal.active .word-span { 
    opacity: 1; 
    transform: translateY(0); 
}
.reveal { 
    opacity: 0; 
    transform: translateY(25px); 
    transition: opacity 0.8s ease, transform 0.8s ease; 
}
.reveal.active { 
    opacity: 1; 
    transform: translateY(0); 
}

/* Staggered word-by-word reveal for the three hero words (plays on load) */
.hero-word {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active .hero-word { opacity: 1; transform: translateY(0); }
.reveal.active .hero-word:nth-child(1) { transition-delay: 0.1s; }
.reveal.active .hero-word:nth-child(2) { transition-delay: 0.3s; }
.reveal.active .hero-word:nth-child(3) { transition-delay: 0.5s; }

/* ==========================================================================
   Responsive (Computer vs. Handy Media Queries)
   ========================================================================== */
@media (min-width: 1024px) {
    .nowrap-desktop { white-space: nowrap; }
    .tab-content { display: none !important; }
    .pillar-display { padding: 2rem 2.5rem; border-radius: 2rem; }
    .pillar-content-inner .feature-box { margin-bottom: 1rem; padding: 1rem 1.2rem; }
}

@media (max-width: 1023px) {
    /* Extreme Reduzierung der toten Ränder */
    .container { padding: 0 1.2rem; }
    .card, .card-compact { padding: 1.5rem; }
    .nav-container { padding: 0 0.5rem; }
    
    /* Header umgebaucht für zentriertes Logo auf Handy */
    .header { padding: 0 1rem; position: relative; justify-content: center; }
    .logo { position: absolute; left: 50%; transform: translateX(-50%); margin: 0; }
    .mobile-menu-btn {
        position: absolute;
        right: 1.5rem;
        top: 50%;
        transform: translateY(-50%);
        display: flex !important;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
        cursor: pointer;
        z-index: 100;
        transition: var(--transition-smooth);
    }
    .mobile-menu-btn:active {
        background: rgba(255, 255, 255, 0.15);
        border-color: rgba(255, 255, 255, 0.2);
    }
    
    .staging-wrapper { padding: 0.5rem; }
    
    /* Mobilfreundliches Button-Stacking */
    .hero-buttons { flex-direction: column; width: 100%; gap: 1rem; }
    .hero-buttons .btn { width: 100%; text-align: center; }
    
    .grid-12, .grid-3, .grid-2 { grid-template-columns: 1fr; }
    .col-4, .col-5, .col-6, .col-7, .col-8 { grid-column: span 1; }

    /* Anruf-Button bei gestapeltem Layout zentrieren */
    #kontakt .text-right { text-align: center; }
    
    /* Mobile Typography Scaling */
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }
    .section { padding: 3.5rem 0; }
    .hidden-mobile { display: none !important; }
    .desktop-nav { display: none; }
    
    /* Mobile Hero Overlay & Vertically Centered text */
    .hero-section { padding-top: 10rem; padding-bottom: 3rem; }
    .hero-container-redesigned { gap: 2rem; }
    .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
    .hero-image-wrapper { position: relative; width: 100%; display: flex; justify-content: center; }
    .hero-img { filter: brightness(0.88); }
    .hero-text-wrapper { position: absolute; top: 36%; left: 9%; transform: translateY(-50%); z-index: 10; align-items: flex-start; gap: 0.25rem; }
    .hero-word { font-size: 2.2rem; color: #ffffff; text-align: left; text-shadow: 0 4px 15px rgba(0, 0, 0, 0.65), 0 1px 3px rgba(0, 0, 0, 0.5); }
    .hero-btn-wrapper { justify-content: center; width: 100%; margin-top: 0.5rem; }
    .hero-btn-wrapper .btn { width: 100%; max-width: 400px; text-align: center; }
    
    .corner-badge { border-top-right-radius: 1.5rem; font-size: 0.65rem; padding: 0.5rem 1rem;}

    /* Mobile Badges Layout */
    .ba-badge { font-size: 0.55rem; padding: 0.4rem 0.8rem; top: 1rem; }
    .ba-badge-left { left: 1rem; }
    .ba-badge-right { right: 1rem; }
    .ba-slider { height: 350px; }

    /* Footer Centering on Handys */
    .footer .grid-12 { text-align: center; display: flex; flex-direction: column; align-items: center; }
    .footer .col-6 { width: 100%; display: flex; flex-direction: column; align-items: center; text-align: center; }
    .footer-links { display: flex !important; justify-content: center !important; align-items: center; flex-wrap: wrap; gap: 1.5rem; margin-top: 1.5rem; }
}

/* ==========================================================================
   Accessibility: Keyboard focus & Reduced Motion
   ========================================================================== */

/* Visible focus ring for keyboard users (mouse clicks stay clean) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
.pillar-tab:focus-visible,
.toggle-btn:focus-visible {
    outline: 2px solid var(--color-purple);
    outline-offset: 3px;
    border-radius: 4px;
}

/* Respect users who prefer reduced motion: disable non-essential animation,
   make scroll-reveal content visible immediately and stop the wave background. */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }

    .reveal,
    .reveal.active,
    .word-span,
    .reveal.active .word-span,
    .hero-word,
    .reveal.active .hero-word {
        opacity: 1 !important;
        transform: none !important;
    }

    #bg-canvas { display: none; }
}

/* ==========================================================================
   Cookie / Privacy Consent Banner
   ========================================================================== */
.cookie-banner {
    position: fixed;
    left: 2rem;
    right: 2rem;
    bottom: 2rem;
    max-width: 980px;
    margin: 0 auto;
    z-index: 1001;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1rem 1.75rem;
    border-radius: 1.5rem;
    opacity: 0;
    transform: translateY(120%);
    transition: opacity 0.4s ease, transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.cookie-banner.visible {
    opacity: 1;
    transform: translateY(0);
}
.cookie-banner-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-gold-light);
    color: var(--color-gold);
}
.cookie-banner-body { flex: 1; }
.cookie-banner-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
}
.cookie-banner-text {
    font-size: 0.85rem;
    line-height: 1.55;
    color: var(--color-text-muted);
}
.cookie-banner-link {
    display: inline-block;
    margin-top: 0.4rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-gold);
    transition: var(--transition-smooth);
}
.cookie-banner-link:hover { color: #b89b72; }
.cookie-banner-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.cookie-banner-actions .btn {
    padding: 0.9rem 1.6rem;
    font-size: 0.75rem;
    white-space: nowrap;
}

@media (max-width: 600px) {
    .cookie-banner {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
        align-items: flex-start;
        flex-wrap: wrap;
        gap: 0.85rem;
        padding: 1rem 1.25rem;
    }
    .cookie-banner-actions {
        width: 100%;
        flex-direction: row;
        gap: 0.6rem;
    }
    .cookie-banner-actions .btn {
        flex: 1;
        width: auto;
        padding: 0.8rem 0.6rem;
        font-size: 0.72rem;
    }
}