/* =====================================================
   Haustür Styles - Modern Design
   ===================================================== */

/* === Container & Layout === */
.haustuer-container {
        /* Flexibel - Breite wird vom Parent oder inline-style bestimmt */
        width: 100%;
        margin: 0;
        padding: 1rem;
        /* Nutze Eyecatcher Theme Variablen */
        background: var(--white, #ffffff);
        color: var(--dark-gray, #212529);
        /* Standard Box-Model */
        box-sizing: border-box;
        position: relative;
}

/* Wenn in einem Grid/Flex Container mit Aside */
.content-with-sidebar .haustuer-container,
.has-sidebar .haustuer-container,
main .haustuer-container {
        /* Respektiere das Layout mit Sidebar */
        width: 100%;
}

/* === Tab Navigation with Radio Buttons === */
.haustuer-container.tabs {
        /* Spezifischer Selektor um nicht allgemeine .tabs zu überschreiben */
        position: relative;
        display: block; /* Sicherstellen dass es ein Block ist */
}

.haustuer-container.tabs input[type="radio"] {
        display: none;
}

.haustuer-container.tabs label.haustuer-tab-button {
        display: inline-flex;
        margin-right: 2px; /* Kleiner Abstand zwischen Tabs */
        margin-bottom: 0; /* Kein Abstand nach unten */
}

.haustuer-tab-button {
        background: var(--light-gray, #f8f9fa);
        border: 1px solid var(--light-gray, #e5e7eb);
        border-bottom: none;
        padding: 0.75rem 1.5rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        /* Nutze Eyecatcher Theme Farben */
        color: var(--gray, #6c757d);
        font-weight: 500;
        font-size: 0.95rem;
        transition: all 0.3s ease;
        margin-bottom: -1px; /* Überlappung mit Panel Border */
        border-radius: 0.5rem 0.5rem 0 0;
        position: relative;
        z-index: 1;
}

.haustuer-tab-button::before {
        content: '';
        position: absolute;
        inset: 0;
        /* Nutze MMT Theme Primärfarbe */
        background: linear-gradient(135deg, transparent 0%, rgba(25, 155, 202, 0.05) 100%);
        opacity: 0;
        transition: opacity 0.3s ease;
        border-radius: inherit;
}

.haustuer-tab-button:hover {
        /* Nutze MMT Primärfarbe */
        color: var(--mmt-primary, rgb(25, 155, 202));
        background: var(--light-gray, #f8f9fa);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(25, 155, 202, 0.15);
}

.haustuer-tab-button:hover::before {
        opacity: 1;
}

/* Active state for radio button tabs */
.haustuer-container.tabs input[type="radio"]:checked + label.haustuer-tab-button {
        /* Nutze MMT Theme Farben */
        color: var(--mmt-primary, rgb(25, 155, 202));
        background: var(--white, #ffffff);
        border: 1px solid #ddd;
        border-bottom: 1px solid var(--white, #ffffff); /* Verbindung zum Panel */
        font-weight: 600;
        z-index: 10; /* Über dem Panel */
        box-shadow: 0 -2px 8px rgba(25, 155, 202, 0.1);
}

.haustuer-tab-icon {
        font-size: 1.25rem;
        filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.haustuer-tab-label {
        letter-spacing: 0.025em;
}

/* === Tab Content / Panels === */
.panels {
        position: relative;
        margin-top: -1px; /* Direkt an Tabs anschließen */
        border: 1px solid #ddd;
        border-radius: 0 0.5rem 0.5rem 0.5rem;
        background: var(--white, #ffffff);
}

.panel {
        display: none;
        opacity: 0;
        animation: fadeIn 0.4s ease-out;
        /* Nutze Theme Variablen */
        background: var(--white, #ffffff);
        padding: 2rem;
}

/* Panel display with radio buttons */
#tab-adoro-radio:checked ~ .panels #tab-adoro,
#tab-inotherm-radio:checked ~ .panels #tab-inotherm {
    display: block;
    opacity: 1;
    animation: fadeIn 0.4s ease-out;
}

/* === Hero Section === */
.haustuer-hero-section {
        margin-bottom: 2.5rem;
        text-align: center;
        position: relative;
        overflow: hidden;
        border-radius: 0.75rem;
}

.haustuer-hero-image {
        max-width: 100%;
        height: auto;
        border-radius: 0.75rem;
        box-shadow:
                0 10px 25px -5px rgba(0, 0, 0, 0.1),
                0 10px 10px -5px rgba(0, 0, 0, 0.04);
        transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.haustuer-hero-image:hover {
        transform: scale(1.02);
        box-shadow:
                0 20px 40px -10px rgba(0, 0, 0, 0.15),
                0 10px 20px -5px rgba(0, 0, 0, 0.08);
}

/* === Content Grid === */
.haustuer-content-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 2rem;
        margin-bottom: 3rem;
}

/* === Feature Cards === */
.haustuer-feature-card {
        /* Nutze Theme Card Background */
        background: var(--card-bg, #fafbfc);
        border-radius: 0.75rem;
        padding: 1.75rem;
        box-shadow:
                0 1px 3px 0 rgba(0, 0, 0, 0.1),
                0 1px 2px 0 rgba(0, 0, 0, 0.06);
        border: 1px solid var(--light-gray, #f8f9fa);
        transition: all 0.3s ease;
        position: relative;
        overflow: hidden;
}

.haustuer-feature-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 4px;
        /* Nutze MMT Theme Farben */
        background: linear-gradient(90deg,
                var(--mmt-primary, rgb(25, 155, 202)) 0%,
                var(--mmt-primary-light, rgb(77, 185, 222)) 50%,
                var(--mmt-primary-light, rgb(77, 185, 222)) 100%
        );
        transform: scaleX(0);
        transition: transform 0.3s ease;
        transform-origin: left;
}

.haustuer-feature-card:hover {
        transform: translateY(-4px);
        box-shadow:
                0 10px 25px -5px rgba(0, 0, 0, 0.1),
                0 10px 10px -5px rgba(0, 0, 0, 0.04);
        /* Nutze MMT Primärfarbe */
        border-color: var(--mmt-primary, rgb(25, 155, 202));
}

.haustuer-feature-card:hover::before {
        transform: scaleX(1);
}

/* === Typography === */
.haustuer-title {
        font-size: 1.35rem;
        font-weight: 600;
        margin-bottom: 1.25rem;
        display: flex;
        align-items: center;
        gap: 0.75rem;
        /* Nutze Theme Textfarbe */
        color: var(--dark-gray, #212529);
        line-height: 1.4;
}

.haustuer-icon {
        font-size: 1.5rem;
        padding: 0.5rem;
        /* Nutze MMT Theme Farben */
        background: linear-gradient(135deg, var(--mmt-primary, rgb(25, 155, 202)), var(--mmt-primary-light, rgb(77, 185, 222)));
        color: white;
        border-radius: 0.5rem;
        box-shadow: 0 2px 4px rgba(25, 155, 202, 0.3);
        filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

/* === Feature Lists === */
.haustuer-feature-list {
        list-style: none;
        padding: 0;
        margin: 0;
}

.haustuer-feature-list li {
        padding: 0.75rem 0;
        padding-left: 2rem;
        position: relative;
        /* Nutze Theme Grau */
        color: var(--gray, #6c757d);
        line-height: 1.6;
        transition: color 0.2s ease;
        border-left: 2px solid transparent;
        padding-left: 2.5rem;
}

.haustuer-feature-list li::before {
        content: "✓";
        position: absolute;
        left: 0;
        top: 0.75rem;
        /* Nutze MMT Success Farbe */
        color: var(--mmt-success, #28a745);
        font-weight: bold;
        font-size: 1.1rem;
        background: linear-gradient(135deg, var(--mmt-success, #28a745), #34d399);
        color: white;
        width: 1.5rem;
        height: 1.5rem;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.75rem;
        box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
}

.haustuer-feature-list li:hover {
        /* Nutze Theme Farben */
        color: var(--dark-gray, #212529);
        border-left-color: var(--mmt-primary, rgb(25, 155, 202));
        transform: translateX(4px);
}

/* === Sections === */
.haustuer-section {
        margin-top: 3rem;
        padding-top: 2rem;
        /* Nutze Theme Border */
        border-top: 1px solid var(--light-gray, #f8f9fa);
        width: 100%;
        max-width: 100%;
        position: relative;
}

.haustuer-section .haustuer-title {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
        text-align: center;
}

/* === Carousel Integration === */
.carousel {
        /* Carousel scrollt horizontal */
        position: relative;
        width: 100%;
        max-width: 100%;
        overflow-x: scroll !important; /* Immer Scrollbar zeigen */
        overflow-y: hidden;
        padding: 1rem 0;
        scroll-snap-type: x mandatory;
        scrollbar-width: thin;
        /* Nutze MMT Theme Farben */
        scrollbar-color: var(--mmt-primary, rgb(25, 155, 202)) var(--light-gray, #f8f9fa);
        box-sizing: border-box;
        /* Stelle sicher dass Scrollbar funktioniert */
        -webkit-overflow-scrolling: touch;
        /* Display block wichtig für overflow */
        display: block;
}

/* Carousel UL - die eigentliche Liste */
.carousel ul {
        display: inline-flex; /* inline-flex damit es so breit wird wie nötig */
        gap: 1rem;
        margin: 0;
        padding: 0;
        list-style: none;
        /* Kein wrap - immer horizontal */
        flex-wrap: nowrap;
        /* Keine explizite Breite - wird durch Inhalt bestimmt */
}

.carousel::-webkit-scrollbar {
        height: 6px;
}

.carousel::-webkit-scrollbar-track {
        /* Nutze Theme Background */
        background: var(--light-gray, #f8f9fa);
        border-radius: 3px;
}

.carousel::-webkit-scrollbar-thumb {
        /* Nutze MMT Primärfarbe */
        background: var(--mmt-primary, rgb(25, 155, 202));
        border-radius: 3px;
}

.carousel li {
        flex: 0 0 auto; /* Keine Flex-Anpassung */
        scroll-snap-align: start;
        list-style: none;
        display: inline-block;
}

.carousel img {
        border-radius: 0.5rem;
        transition: transform 0.3s ease, box-shadow 0.3s ease;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        /* Bilder Größe */
        height: 200px;
        width: auto;
        display: block;
        object-fit: contain;
}

.carousel img:hover {
        transform: scale(1.05);
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* === Animations === */
@keyframes fadeIn {
        from {
                opacity: 0;
                transform: translateY(20px);
        }
        to {
                opacity: 1;
                transform: translateY(0);
        }
}

@keyframes slideInUp {
        from {
                opacity: 0;
                transform: translateY(30px);
        }
        to {
                opacity: 1;
                transform: translateY(0);
        }
}

/* === Responsive Design === */
@media (max-width: 768px) {
        .haustuer-container {
                padding: 0.75rem;
                /* Auf Mobile volle Breite */
                width: 100%;
        }

        .haustuer-content-grid {
                grid-template-columns: 1fr;
                gap: 1.5rem;
        }

        .haustuer-tab-button {
                flex: 1;
                justify-content: center;
                padding: 0.75rem 1rem;
        }

        .haustuer-tab-label {
                display: none;
        }

        .haustuer-tab-icon {
                font-size: 1.5rem;
        }

        .haustuer-feature-card {
                padding: 1.25rem;
        }

        .haustuer-title {
                font-size: 1.2rem;
                flex-direction: column;
                text-align: center;
                gap: 0.5rem;
        }

        .haustuer-tab-panel {
                padding: 1.25rem;
        }
}

@media (max-width: 480px) {
        .haustuer-tabs-nav {
                gap: 0.25rem;
                margin-bottom: 1.5rem;
        }

        .haustuer-tab-button {
                padding: 0.5rem 0.75rem;
        }

        .haustuer-content-grid {
                gap: 1rem;
        }

        .haustuer-feature-list li {
                padding-left: 2rem;
                font-size: 0.9rem;
        }
}

/* === Dark Mode Support === */
@media (prefers-color-scheme: dark) {
        /* Dark Mode nutzt automatisch die Theme-Variablen */
        .haustuer-feature-card {
                /* Theme sollte bereits dark mode variablen haben */
                background: var(--card-bg);
                border-color: var(--gray);
        }

        .haustuer-hero-image {
                box-shadow:
                        0 10px 25px -5px rgba(0, 0, 0, 0.3),
                        0 10px 10px -5px rgba(0, 0, 0, 0.1);
        }
}

/* === Print Styles === */
@media print {
        .haustuer-container {
                background: white !important;
                color: black !important;
                box-shadow: none !important;
        }

        .haustuer-tab-button,
        .haustuer-tabs-nav {
                display: none !important;
        }

        .haustuer-tab-panel {
                display: block !important;
                box-shadow: none !important;
                page-break-inside: avoid;
        }

        .haustuer-feature-card {
                box-shadow: none !important;
                border: 1px solid #ccc !important;
                page-break-inside: avoid;
        }
}