/*
 * SimonsVoss.Website – Content.ProductTabs
 * Public/Styles/LoveableFortLox/tabs.css
 *
 * Drop-in: passt auf das gerenderte Markup ohne Template-Änderung.
 * Alles ist unter der Section .py-20.bg-muted\/40 gescoped, damit die
 * Utility-Namen nicht mit dem Bootstrap-4-Grid der Website kollidieren.
 *
 * Farben aus styles.css übernommen:
 *   #002D55 Blau | #477ABD Azure | #F18C72 Peach | #F5F5F5 Grau
 */

.py-20.bg-muted\/40 {
    --pt-blue: #002D55;
    --pt-azure: #477ABD;
    --pt-peach: #F18C72;
    --pt-bg: #ffffff;
    --pt-muted: #F5F5F5;
    --pt-border: #DDE3EA;
    --pt-text: #3E4656;
    --pt-heading: #292D2F;

    display: block;
    background-color: var(--pt-muted);
    padding: 80px 0;
    font-family: "Roboto", Arial, Helvetica, sans-serif;
}

/* ---------------------------------------------------------------
   Container + Intro
   --------------------------------------------------------------- */

.py-20.bg-muted\/40 .max-w-7xl {
    max-width: 1280px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 24px;
    padding-right: 24px;
}

.py-20.bg-muted\/40 .max-w-4xl {
    max-width: 896px;
    margin: 0 auto 48px;
    text-align: center;
    font-size: 30px;
    font-weight: 300;
    line-height: 1.2;
    color: var(--pt-heading);
}

.py-20.bg-muted\/40 .max-w-4xl p {
    margin: 16px 0 0;
    font-size: 18px;
    font-weight: 400;
    line-height: 1.6;
    color: var(--pt-text);
}

/* .fade-up existiert in styles.css nicht – hier neutralisiert,
   falls später eine Animation ergänzt wird */
.py-20.bg-muted\/40 .fade-up {
    opacity: 1;
    transform: none;
}

.py-20.bg-muted\/40 .w-full {
    width: 100%;
}

/* ---------------------------------------------------------------
   Tab-Leiste
   --------------------------------------------------------------- */

.py-20.bg-muted\/40 [role="tablist"] {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px;
    height: auto;
    margin: 0 0 40px;
    padding: 0 !important;
    background: transparent;
    list-style: none;
}

.py-20.bg-muted\/40 .lov-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    margin: 0;
    padding: 12px 20px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--pt-heading);
    background-color: var(--pt-bg);
    border: 1px solid var(--pt-border);
    border-radius: 6px;
    cursor: pointer;
    appearance: none;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.py-20.bg-muted\/40 .lov-tab:hover {
    border-color: var(--pt-blue);
    color: var(--pt-blue);
}

.py-20.bg-muted\/40 .lov-tab[data-state="active"],
.py-20.bg-muted\/40 .lov-tab[aria-selected="true"] {
    background-color: var(--pt-blue);
    border-color: var(--pt-blue);
    color: #ffffff;
}

.py-20.bg-muted\/40 .lov-tab:focus-visible {
    outline: 2px solid var(--pt-azure);
    outline-offset: 2px;
}

.py-20.bg-muted\/40 .lov-tab:disabled {
    pointer-events: none;
    opacity: .5;
}

/* ---------------------------------------------------------------
   Panels
   Wichtig: !important, weil tabs.js display inline setzt
   --------------------------------------------------------------- */

.py-20.bg-muted\/40 [role="tabpanel"] {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}

.py-20.bg-muted\/40 [role="tabpanel"][hidden],
.py-20.bg-muted\/40 [role="tabpanel"][data-state="inactive"] {
    display: none !important;
}

/* ---------------------------------------------------------------
   Produktkacheln (direkte Kinder der Panels)
   --------------------------------------------------------------- */

.py-20.bg-muted\/40 [role="tabpanel"] > div {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    padding: 20px;
    background-color: var(--pt-bg);
    border: 1px solid var(--pt-border);
    border-radius: 8px;
    text-decoration: none;
    transition: box-shadow .2s ease, border-color .2s ease;
}

.py-20.bg-muted\/40 [role="tabpanel"] > div:hover {
    border-color: var(--pt-azure);
    box-shadow: 0 8px 20px rgba(0, 45, 85, .10);
}

/* Bildbereich */
.py-20.bg-muted\/40 .aspect-square {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: 1 / 1;
    margin-bottom: 12px;
}

.py-20.bg-muted\/40 .aspect-square img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* Platzhalter, wenn kein Bild gepflegt ist */
.py-20.bg-muted\/40 .aspect-square .bg-muted {
    width: 100%;
    height: 100%;
    background-color: var(--pt-muted);
    border-radius: 4px;
}

/* Produktname */
.py-20.bg-muted\/40 [role="tabpanel"] > div > p {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.25;
    color: var(--pt-blue);
}

/* ---------------------------------------------------------------
   Responsive
   --------------------------------------------------------------- */

@media (max-width: 1199px) {
    .py-20.bg-muted\/40 [role="tabpanel"] {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .py-20.bg-muted\/40 {
        padding: 48px 0;
    }

    .py-20.bg-muted\/40 .max-w-4xl {
        font-size: 24px;
        margin-bottom: 32px;
    }

    .py-20.bg-muted\/40 .max-w-4xl p {
        font-size: 16px;
    }

    .py-20.bg-muted\/40 [role="tabpanel"] {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .py-20.bg-muted\/40 .lov-tab {
        padding: 10px 16px;
        font-size: 13px;
    }
}
