/* --- Modern UI Design System --- */
:root {
    --bg-surface: #F9FAFB;
    --bg-light: #F3F4F6;
    --text-main: #111827;
    --text-muted: #6B7280;
    
    /* Logo Farben */
    --color-red: #E2231A;
    --color-blue: #1C7FC1;
    --color-green: #1E8E4E;
    --color-yellow: #F4C300;
    
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --shadow-bento: 0 10px 40px -10px rgba(0,0,0,0.06);
    --shadow-hover: 0 20px 40px -10px rgba(0,0,0,0.12);
    --radius-bento: 24px;
    --radius-img: 16px;
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-surface);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* Container & Sections */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section { padding: 100px 0; }
.bg-light { background-color: var(--bg-light); }

.section-header { text-align: center; margin-bottom: 60px; }
.section-header h2 { font-size: 2.5rem; font-weight: 800; letter-spacing: -0.03em; margin-bottom: 8px; }
.section-header p { color: var(--text-muted); font-size: 1.1rem; }

/* --- Glassmorphism Navbar --- */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%; z-index: 1000;
    background: rgba(249, 250, 251, 0.7);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}
.navbar.scrolled { background: rgba(249, 250, 251, 0.9); box-shadow: 0 4px 20px rgba(0,0,0,0.05); }

.nav-container { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; }
.logo-link { display: flex; align-items: center; }

/* HIER IST DIE LOGO-KORREKTUR */
.nav-logo {
    height: 60px; /* Erzwingt feste Höhe, verhindert Layout-Bruch */
    width: auto;
    border-radius: 4px;
    transition: transform 0.3s ease;
}
.logo-link:hover .nav-logo { transform: scale(1.05); }
.logo-fallback { font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }

.nav-menu { display: none; gap: 32px; font-weight: 600; font-size: 0.95rem; color: var(--text-muted); }
.nav-menu a { transition: color 0.2s; }
.nav-menu a:hover { color: var(--text-main); }
@media (min-width: 768px) { .nav-menu { display: flex; } }

.nav-actions { display: flex; align-items: center; gap: 16px; }
.mobile-menu-btn { display: block; font-size: 1.5rem; background: none; border: none; cursor: pointer; }
@media (min-width: 768px) { .mobile-menu-btn { display: none; } }

/* Mobile Menu Active State */
.nav-menu.active {
    display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; width: 100%;
    background: rgba(249, 250, 251, 0.95); backdrop-filter: blur(20px);
    padding: 30px 24px; border-bottom: 1px solid rgba(0,0,0,0.05); box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

/* Status Badge */
.status-badge { display: none; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 50px; font-size: 0.8rem; font-weight: 700; background: rgba(0,0,0,0.05); }
@media (min-width: 640px) { .status-badge { display: flex; } }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #999; }
.status-badge.open { color: #16a34a; background: rgba(34, 197, 94, 0.1); }
.status-badge.open .status-dot { background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.status-badge.closed { color: #dc2626; background: rgba(239, 68, 68, 0.1); }
.status-badge.closed .status-dot { background: #ef4444; }

/* Buttons */
.lang-btn { background: none; border: none; font-weight: 800; font-size: 0.85rem; padding: 6px 10px; border-radius: 6px; cursor: pointer; transition: background 0.2s; }
.lang-btn:hover { background: rgba(0,0,0,0.05); }

.btn { display: inline-flex; align-items: center; justify-content: center; font-weight: 600; border-radius: 50px; cursor: pointer; transition: var(--transition); border: none; }
.btn-contact { background: var(--text-main); color: #fff; padding: 8px 24px; font-size: 0.9rem; }
.btn-contact:hover { background: #000; transform: scale(1.05); }
.btn-submit { background: var(--text-main); color: #fff; padding: 14px 24px; width: 100%; font-size: 1rem; margin-top: 10px; }
.btn-submit:hover { background: #000; transform: translateY(-2px); }

/* --- Hero Section --- */
.hero {
    min-height: 85vh; display: flex; align-items: center; justify-content: center;
    position: relative; overflow: hidden; padding-top: 120px;
}
.hero-glow { position: absolute; width: 40vw; height: 40vw; border-radius: 50%; filter: blur(120px); opacity: 0.2; mix-blend-mode: multiply; z-index: -1; }
.hero-glow-blue { top: -10%; left: -10%; background-color: var(--color-blue); }
.hero-glow-red { bottom: -10%; right: -10%; background-color: var(--color-red); }

.hero-content { text-align: center; max-width: 900px; padding: 0 20px; }
.hero h1 { font-size: clamp(3rem, 6vw, 4.5rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.04em; margin-bottom: 24px; }
.text-gradient {
    background: linear-gradient(90deg, #111 0%, #666 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.hero p { font-size: clamp(1.1rem, 2vw, 1.3rem); color: var(--text-muted); margin-bottom: 40px; max-width: 700px; margin-left: auto; margin-right: auto; }
.hero-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; font-weight: 600; font-size: 0.9rem; }
.hero-badges span { padding: 10px 20px; border-radius: 50px; border: 1px solid rgba(0,0,0,0.08); background: rgba(255,255,255,0.6); backdrop-filter: blur(8px); }

/* --- Bento Grid System --- */
.bento-grid {
    display: grid; grid-template-columns: 1fr; gap: 24px;
}
@media (min-width: 992px) {
    .bento-grid { grid-template-columns: 1fr 1fr; }
}

.bento-card {
    background: #fff; border-radius: var(--radius-bento); padding: 32px;
    border: 1px solid rgba(0,0,0,0.04); box-shadow: var(--shadow-bento);
    position: relative; overflow: hidden; transition: var(--transition);
}
.bento-card:hover { transform: translateY(-6px) scale(1.01); box-shadow: var(--shadow-hover); }

/* Bento Hover Background Glow */
.bento-hover-glow { position: absolute; inset: 0; opacity: 0; transition: opacity 0.5s ease; z-index: 1; }
.glow-red { background: linear-gradient(to bottom right, rgba(226,35,26,0.05), transparent); }
.glow-blue { background: linear-gradient(to bottom right, rgba(28,127,193,0.05), transparent); }
.glow-green { background: linear-gradient(to bottom right, rgba(30,142,78,0.05), transparent); }
.glow-yellow { background: linear-gradient(to bottom right, rgba(244,195,0,0.05), transparent); }
.bento-card:hover .bento-hover-glow { opacity: 1; }

/* Image Wrappers inside Bento */
.bento-img-wrapper { border-radius: var(--radius-img); overflow: hidden; background: #eee; position: relative; z-index: 2; }
.bento-img-wrapper img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s ease; }
.bento-card:hover .bento-img-wrapper img { transform: scale(1.05); }

.bento-content { position: relative; z-index: 2; margin-top: 24px; }
.bento-content h3 { font-size: 1.5rem; font-weight: 800; display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.bento-content p { color: var(--text-muted); font-size: 1rem; }

/* Arrow Animation */
.bento-arrow { opacity: 0; transform: translateX(-15px); transition: var(--transition); }
.bento-card:hover .bento-arrow { opacity: 1; transform: translateX(0); }
.text-red { color: var(--color-red); } .text-blue { color: var(--color-blue); } .text-green { color: var(--color-green); } .text-yellow { color: var(--color-yellow); }

/* Layout Spezifika für 30/30/20/20 */
.bento-large { display: flex; flex-direction: column; }
.bento-large .bento-img-wrapper { height: 260px; }

.bento-small { display: flex; flex-direction: column; }
.bento-small .bento-img-wrapper { height: 180px; }
@media (min-width: 768px) {
    .bento-small { flex-direction: row; align-items: center; padding: 24px; }
    .bento-small .bento-img-wrapper { width: 40%; height: 140px; margin-top: 0; margin-right: 24px; flex-shrink: 0; }
    .bento-small .bento-content { margin-top: 0; }
}

/* --- Service Bonus Banner --- */
.service-banner {
    background: #111; color: #fff; border-radius: 32px; padding: 40px;
    display: flex; flex-direction: column; gap: 40px; position: relative; overflow: hidden;
}
.service-glow-bg { position: absolute; top: 0; right: 0; width: 500px; height: 500px; background: rgba(255,255,255,0.05); border-radius: 50%; filter: blur(100px); pointer-events: none; }
.service-text { position: relative; z-index: 2; flex: 1; }
.service-text .eyebrow { font-size: 0.8rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.5; display: block; margin-bottom: 16px; }
.service-text h2 { font-size: 2.5rem; font-weight: 800; margin-bottom: 24px; line-height: 1.1; }
.service-text p { color: rgba(255,255,255,0.7); font-size: 1.1rem; margin-bottom: 32px; }
.check-list { display: flex; flex-direction: column; gap: 16px; }
.check-list li { position: relative; padding-left: 32px; color: rgba(255,255,255,0.9); }
.check-list li::before { content: '✓'; position: absolute; left: 0; color: var(--color-green); font-weight: bold; }

.service-img { position: relative; z-index: 2; flex: 1; border-radius: 20px; overflow: hidden; }
.service-img img { width: 100%; height: 350px; object-fit: cover; opacity: 0.8; mix-blend-mode: luminosity; transition: var(--transition); }
.service-banner:hover .service-img img { mix-blend-mode: normal; opacity: 1; transform: scale(1.02); }

@media (min-width: 992px) {
    .service-banner { flex-direction: row; padding: 60px; align-items: center; }
}

/* --- Team --- */
.team-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 40px; }
@media (min-width: 768px) { .team-grid { gap: 80px; } }
.team-card { text-align: center; cursor: pointer; }
.team-img-wrapper {
    width: 160px; height: 160px; margin: 0 auto 20px; border-radius: 50%; overflow: hidden;
    border: 4px solid #fff; box-shadow: 0 10px 30px rgba(0,0,0,0.08); transition: var(--transition);
}
.team-img-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.team-card:hover .team-img-wrapper { transform: translateY(-10px) scale(1.05); box-shadow: 0 20px 40px rgba(0,0,0,0.15); }
.team-card h3 { font-size: 1.25rem; font-weight: 800; }
.team-card p { color: var(--text-muted); font-size: 0.9rem; }

/* --- Kontakt --- */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 992px) {
    .contact-grid { grid-template-columns: 1fr 1fr; }
    .map-card { grid-column: span 2; }
}

.contact-card h2 { font-size: 2rem; font-weight: 800; margin-bottom: 32px; }
.contact-details p { font-size: 1.1rem; margin-bottom: 24px; }
.contact-links { display: flex; flex-direction: column; gap: 12px; margin-bottom: 40px; }
.contact-links a { color: var(--text-muted); font-weight: 500; transition: color 0.2s; display: inline-flex; align-items: center; gap: 8px; }
.contact-links a:hover { color: var(--text-main); }

.hours-box { background: rgba(0,0,0,0.03); padding: 24px; border-radius: 16px; }
.hours-box h3 { font-weight: 800; margin-bottom: 16px; font-size: 1.1rem; }
.hours-row { display: flex; justify-content: space-between; color: var(--text-muted); margin-bottom: 8px; font-size: 0.95rem; }

.form-card h3 { font-size: 1.5rem; font-weight: 800; margin-bottom: 24px; }
.form-input {
    width: 100%; padding: 14px 16px; border-radius: 12px; margin-bottom: 16px;
    background: rgba(0,0,0,0.02); border: 1px solid rgba(0,0,0,0.05); transition: all 0.2s;
}
.form-input:focus { background: #fff; border-color: rgba(0,0,0,0.2); box-shadow: 0 0 0 4px rgba(0,0,0,0.03); }

.map-card { padding: 8px; height: 400px; }
.map-iframe { width: 100%; height: 100%; border-radius: 16px; }

/* --- Footer --- */
.footer { border-top: 1px solid rgba(0,0,0,0.05); padding: 40px 0; margin-top: 60px; font-size: 0.9rem; color: var(--text-muted); }
.footer-container { display: flex; flex-direction: column; align-items: center; gap: 16px; }
@media (min-width: 768px) { .footer-container { flex-direction: row; justify-content: space-between; } }
.footer-links { display: flex; gap: 24px; font-weight: 500; }
.footer-links a:hover { color: var(--text-main); }

/* --- Scroll Animations (High-End Feel) --- */
.reveal-on-scroll { opacity: 0; transform: translateY(40px); transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); }
.reveal-on-scroll.is-visible { opacity: 1; transform: translateY(0); }
/* --- Fix für Unterseiten-Bilder (Produktdarstellung) --- */
.subpage-image-container {
    width: 100%;
    height: 350px;
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 40px;
    background-color: #F3F4F6; /* Sanftes Grau, passend zum Design */
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(0,0,0,0.04);
}

.subpage-image {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Zeigt das GANZE Bild an, ohne abzuschneiden */
    padding: 24px; /* Schöner Abstand zum Rand */
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.subpage-image-container:hover .subpage-image {
    transform: scale(1.03); /* Eleganter, dezenter Zoom beim Drüberfahren */
}

/* ====================================================================
   PATCH für style.css  –  ans ENDE der Datei anhängen
   ==================================================================== */

/* --- 1) FIX: kein "Rausspringen aus der Mitte" beim Laden ---
   Wird von der neuen script.js gesetzt: Elemente, die beim Laden schon
   sichtbar sind, erscheinen sofort OHNE Hereingleiten. */
.reveal-on-scroll.no-anim {
    transition: none !important;
    opacity: 1;
    transform: none;
}

/* Nutzer mit reduzierter Bewegung: alles sofort sichtbar, keine Animation */
@media (prefers-reduced-motion: reduce) {
    .reveal-on-scroll {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* --- 2) Optional: ruhigere Hover-Effekte (kein scale aus der Mitte) --- */
.bento-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}
.team-card:hover .team-img-wrapper {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}
.bento-card:hover .bento-img-wrapper img {
    transform: scale(1.03);
}
.subpage-image-container:hover .subpage-image {
    transform: scale(1.015);
}
/* ====================================================================
   PATCH für style.css  –  ans ENDE der Datei anhängen
   ==================================================================== */

/* --- 1) FIX: kein "Rausspringen aus der Mitte" beim Laden --- */
.reveal-on-scroll.no-anim {
    transition: none !important;
    opacity: 1;
    transform: none;
}
@media (prefers-reduced-motion: reduce) {
    .reveal-on-scroll {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* --- 2) Ruhigere Hover-Effekte (kein scale aus der Mitte) --- */
.bento-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}
.team-card:hover .team-img-wrapper {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}
.bento-card:hover .bento-img-wrapper img {
    transform: scale(1.03);
}
.subpage-image-container:hover .subpage-image {
    transform: scale(1.015);
}

/* --- 3) HERO-HINTERGRUND: Bauplan-Raster + driftende Glows --- */

/* Dezentes technisches Raster, zum Text hin ausgeblendet */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background-image:
        linear-gradient(rgba(17, 24, 39, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(17, 24, 39, 0.045) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at center, transparent 14%, #000 72%);
            mask-image: radial-gradient(ellipse 70% 60% at center, transparent 14%, #000 72%);
    pointer-events: none;
}

/* Farb-Glows etwas kräftiger und sanft driften lassen */
.hero-glow { opacity: 0.28; animation: heroDrift 18s ease-in-out infinite alternate; }
.hero-glow-blue { animation-duration: 18s; }
.hero-glow-red  { animation-duration: 23s; animation-delay: -7s; }

@keyframes heroDrift {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(40px, 30px) scale(1.15); }
}
@media (prefers-reduced-motion: reduce) {
    .hero-glow { animation: none; }
}

/* --- 4) OPTIONAL: Logo dezent als Wasserzeichen ---
   Aktivieren: im HTML im <header class="hero"> diese Zeile ergänzen:
   <div class="hero-logo-watermark"></div>
   Tipp: Für ein perfektes Ergebnis ein transparentes Logo (PNG/SVG)
   verwenden und unten den url(...)-Pfad anpassen. */
.hero-logo-watermark {
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: url('/img/Logo.jpg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: clamp(320px, 50vw, 680px);
    opacity: 0.07;
    mix-blend-mode: multiply;   /* lässt den weißen JPG-Hintergrund verschwinden */
    pointer-events: none;
}
/* ====================================================================
   PATCH für style.css  –  ans ENDE der Datei anhängen
   ==================================================================== */

/* --- 1) FIX: kein "Rausspringen aus der Mitte" beim Laden --- */
.reveal-on-scroll.no-anim {
    transition: none !important;
    opacity: 1;
    transform: none;
}
@media (prefers-reduced-motion: reduce) {
    .reveal-on-scroll {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* --- 2) Ruhigere Hover-Effekte (kein scale aus der Mitte) --- */
.bento-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}
.team-card:hover .team-img-wrapper {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}
.bento-card:hover .bento-img-wrapper img {
    transform: scale(1.03);
}
.subpage-image-container:hover .subpage-image {
    transform: scale(1.015);
}

/* --- 3) HERO-HINTERGRUND: Bauplan-Raster + driftende Glows --- */

/* Dezentes technisches Raster, zum Text hin ausgeblendet */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background-image:
        linear-gradient(rgba(17, 24, 39, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(17, 24, 39, 0.045) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at center, transparent 14%, #000 72%);
            mask-image: radial-gradient(ellipse 70% 60% at center, transparent 14%, #000 72%);
    pointer-events: none;
}

/* Farb-Glows etwas kräftiger und sanft driften lassen */
.hero-glow { opacity: 0.28; animation: heroDrift 18s ease-in-out infinite alternate; }
.hero-glow-blue { animation-duration: 18s; }
.hero-glow-red  { animation-duration: 23s; animation-delay: -7s; }

@keyframes heroDrift {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(40px, 30px) scale(1.15); }
}
@media (prefers-reduced-motion: reduce) {
    .hero-glow { animation: none; }
}

/* --- 4) OPTIONAL: Logo dezent als Wasserzeichen ---
   Aktivieren: im HTML im <header class="hero"> diese Zeile ergänzen:
   <div class="hero-logo-watermark"></div>
   Tipp: Für ein perfektes Ergebnis ein transparentes Logo (PNG/SVG)
   verwenden und unten den url(...)-Pfad anpassen. */
.hero-logo-watermark {
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: url('/img/Logo.jpg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: clamp(320px, 50vw, 680px);
    opacity: 0.07;
    mix-blend-mode: multiply;   /* lässt den weißen JPG-Hintergrund verschwinden */
    pointer-events: none;
}

/* --- 5) HERO: Cursor-Spotlight (Raster leuchtet unter der Maus auf) ---
   Wird von der script.js gesteuert (--mx, --my, --spot).
   Funktioniert ohne HTML-Änderung auf <header class="hero">. */
.hero { --mx: 50%; --my: 50%; --spot: 0; }

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: var(--spot);
    transition: opacity 0.3s ease;
    background-image:
        radial-gradient(circle 240px at var(--mx) var(--my), rgba(255,255,255,0.45), transparent 65%),
        linear-gradient(rgba(28,127,193,0.30) 1px, transparent 1px),
        linear-gradient(90deg, rgba(28,127,193,0.30) 1px, transparent 1px);
    background-size: auto, 44px 44px, 44px 44px;
    -webkit-mask-image: radial-gradient(circle 240px at var(--mx) var(--my), #000 0%, transparent 70%);
            mask-image: radial-gradient(circle 240px at var(--mx) var(--my), #000 0%, transparent 70%);
}

/* Auf Touch-Geräten / bei reduzierter Bewegung kein Spotlight */
@media (hover: none), (prefers-reduced-motion: reduce) {
    .hero::after { display: none; }
}