/* ========================================================================
   HomePlus GmbH - Zentrales Stylesheet
   Beinhaltet alle Custom-Styles, die nicht ueber Tailwind-Klassen geloest sind.
   ======================================================================== */

/* Basis-Styling und iOS Fixes */
body {
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
html, body {
    background-color: #F4F7FB !important;
}

/* Navigation - Glassmorphismus und Crossfade-Effekte */
.glass-nav {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Scroll-Progress-Bar: GPU-Hint ohne Transform-Konflikt */
#scroll-progress {
    will-change: width;
}
.glass-nav .glass-nav-logo-white {
    opacity: 0 !important;
    visibility: hidden;
}
.glass-nav .glass-nav-logo-color {
    opacity: 1 !important;
    visibility: visible;
}

/* NEU: Mobile Menu Button Farbwechsel fuer weissen Header (Kugelsicher) */
.glass-nav #mobile-menu-btn {
    color: #321EE6 !important; /* text-brand-blue */
    background-color: rgba(50, 30, 230, 0.05) !important; /* bg-brand-blue/5 */
}

/* Schlanke regionale Landingpage */
#main-header nav[aria-label="Hauptnavigation"] {
    gap: 2rem;
}
#main-header nav[aria-label="Hauptnavigation"] a {
    white-space: nowrap;
}

/* Hero & Hintergruende */
.hero-gradient {
    background: linear-gradient(to right, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.6) 50%, rgba(50, 30, 230, 0.05) 100%);
}

/* Animationen & Reveal-Effekte */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}
/* Nach der Animation will-change freigeben (spart GPU-Speicher) */
.reveal.active {
    will-change: auto;
}
.fade-in {
    animation: fadeIn 0.4s ease-in-out forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Partner-Marquee: GPU-Hint fuer ruckelfreie Animation */
.animate-marquee {
    will-change: transform;
}

/* Scrollbars verbergen (Allgemein) */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Spezifische Scrollbar fuer horizontal scrollbare Slider (z.B. Team / Produkte Mobile) */
.team-slider::-webkit-scrollbar {
    height: 8px;
}
.team-slider::-webkit-scrollbar-track {
    background: #F4F7FB;
    border-radius: 10px;
    margin: 0 20px;
}
.team-slider::-webkit-scrollbar-thumb {
    background: #A0E628;
    border-radius: 10px;
}
.team-slider::-webkit-scrollbar-thumb:hover {
    background: #8BCB20;
}

/* Google Maps Autocomplete Styling-Fix (Ausblenden von Fehlersymbolen & Design) */
input#strasse_hausnummer, .pac-target-input { background-image: none !important; }
.pac-container { border-radius: 1rem; border: 1px solid #f3f4f6; box-shadow: 0 10px 40px -10px rgba(0,0,0,0.1); font-family: 'Montserrat', sans-serif; margin-top: 5px; padding: 8px; }
.pac-item { padding: 10px 15px; cursor: pointer; border-top: none; border-bottom: 1px solid #f9fafb; border-radius: 0.5rem; transition: background-color 0.2s; }
.pac-item:last-child { border-bottom: none; }
.pac-item:hover { background-color: #f3f4f6; }
.pac-item-query { font-weight: 700; color: #1E12A8; font-size: 14px; }
.pac-matched { color: #A0E628; }
.pac-logo::after { display: none; }

/* --- KOMPONENTEN FIXES --- */

/* Team Karten Fix: Verhindert abgeschnittene Zitate auf Zwischengroessen */
.team-card {
    height: auto !important;
    min-height: 480px;
    padding-bottom: 2.5rem !important;
}

/* Kontakt-Rechner: schmale Displays ohne horizontales Ueberlaufen */
@media (max-width: 760px) {
    html,
    body,
    .angebot-hero {
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }

    .angebot-shell {
        width: calc(100vw - 2rem) !important;
        max-width: calc(100vw - 2rem) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .angebot-title,
    .angebot-lead,
    .angebot-grid,
    .angebot-panel,
    .form-panel,
    .choice-row,
    .field-grid,
    .kontakt-mini {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    .angebot-title {
        font-size: clamp(2rem, 9vw, 2.2rem) !important;
        line-height: 1.08 !important;
        overflow-wrap: break-word !important;
    }

    .angebot-lead {
        font-size: 1rem !important;
    }

    .chip-button,
    .tab-button,
    .interest-option span {
        min-width: 0 !important;
    }

    .tab-button {
        font-size: .62rem !important;
        letter-spacing: .035em !important;
    }

    .calc-value {
        font-size: 2.35rem !important;
    }

    .calc-unit {
        font-size: .62rem !important;
        letter-spacing: .04em !important;
    }

    .savings-value {
        font-size: 2.2rem !important;
    }

    .interest-option span {
        font-size: .64rem !important;
    }
}
