/**
 * ==========================================================
 * Shop Styles
 * ==========================================================
 *
 * Styles für WooCommerce-Shopseiten.
 *
 * Enthält:
 * - Shop-Grundlayout
 * - Shop-Kopfbereich
 * - Sortierung
 * - Produktübersicht
 * - Produktkarten
 * - Produktbilder
 * - Preise
 * - Buttons
 * - Pagination
 *
 * Diese Datei wird auf der Shopseite sowie auf
 * Produktarchiven geladen.
 */


/* ==========================================================
   Shop-Grundlayout
========================================================== */

.shop-archive {
    width: 100%;

    background-color: #faf7f0;
}

.shop-archive__container {
    width: 100%;
    max-width: 1200px;

    margin: 0 auto;
    padding: 12px 24px 36px;
}

.shop-archive__container::before,
.shop-archive__container::after {
    display: none;
}


/* ==========================================================
   Shop-Kopfbereich
========================================================== */

.shop-archive .woocommerce-products-header {
    margin-bottom: 26px;
}

/*
 * Ein leerer WooCommerce-Produkte-Header soll keinen
 * zusätzlichen Abstand oberhalb der Shop-Toolbar erzeugen.
 */
.shop-archive
.woocommerce-products-header:not(:has(*)) {
    display: none;
}

.shop-archive
.woocommerce-products-header__title {
    margin: 0;

    color: #222222;

    font-family: "Cormorant Garamond", serif;
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 500;
    line-height: 1.05;
}

.shop-archive
.term-description {
    display: none;
}


/* ==========================================================
   Shop-Werkzeugleiste
========================================================== */

.shop-toolbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;

    width: 100%;

    margin: 0 0 30px;
    padding-bottom: 14px;

    border-bottom: 1px solid rgba(139, 107, 71, 0.14);
}

.shop-toolbar::before,
.shop-toolbar::after {
    display: none;

    content: none;
}


/* ==========================================================
   Kategorienavigation
========================================================== */

.shop-categories {
    min-width: 0;

    margin: 0;
    padding: 0;

    border: 0;
}

.shop-categories__list {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 28px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.shop-categories__item {
    margin: 0;
    padding: 0;
}

.shop-categories__link {
    position: relative;

    display: inline-block;

    padding: 6px 0;

    color: rgba(34, 34, 34, 0.68);

    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
    text-decoration: none;

    transition: color 0.2s ease;
}

.shop-categories__link::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;

    height: 2px;

    background-color: #8b6b47;
    border-radius: 2px;

    content: "";

    transform: scaleX(0);
    transform-origin: center;

    transition: transform 0.2s ease;
}

.shop-categories__link:hover,
.shop-categories__link:focus-visible,
.shop-categories__link--active {
    color: #8b6b47;
}

.shop-categories__link:hover::after,
.shop-categories__link:focus-visible::after,
.shop-categories__link--active::after {
    transform: scaleX(1);
}


/* ==========================================================
   Sortierung
========================================================== */

.shop-toolbar .woocommerce-ordering {
    flex: 0 0 auto;

    float: none;

    margin: 0;
}

.shop-toolbar
.woocommerce-ordering
select {
    width: auto;
    min-width: 180px;
    height: 38px;

    padding: 0 34px 0 12px;

    color: rgba(34, 34, 34, 0.72);
    background-color: transparent;

    border: 1px solid rgba(139, 107, 71, 0.2);
    border-radius: 6px;

    font-family: "Inter", sans-serif;
    font-size: 0.82rem;

    cursor: pointer;

    transition:
        color 0.2s ease,
        background-color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.shop-toolbar
.woocommerce-ordering
select:hover {
    color: #222222;
    background-color: rgba(245, 241, 232, 0.55);

    border-color: rgba(139, 107, 71, 0.5);
}

.shop-toolbar
.woocommerce-ordering
select:focus {
    color: #222222;

    border-color: #8b6b47;
    outline: none;

    box-shadow:
        0 0 0 3px rgba(139, 107, 71, 0.1);
}


/* ==========================================================
   Produktübersicht
========================================================== */

.shop-archive
ul.products {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 34px 26px;

    width: 100%;

    margin: 0 !important;
    padding: 0 !important;

    list-style: none;
}

.shop-archive
ul.products::before,
.shop-archive
ul.products::after {
    display: none !important;

    content: none !important;
}


/* ==========================================================
   Produktkarten
========================================================== */

.shop-archive
ul.products
li.product {
    position: relative;

    display: flex;
    flex-direction: column;

    float: none !important;

    width: auto !important;
    min-width: 0;

    margin: 0 !important;
    padding: 12px 12px 16px;

    overflow: hidden;

    background-color: #f5f1e8;

    border: 1px solid rgba(139, 107, 71, 0.28);
    border-radius: 12px;

    box-shadow:
        0 6px 20px rgba(34, 34, 34, 0.07);

    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease,
        transform 0.25s ease;
}

.shop-archive
ul.products
li.product:hover {
    border-color: rgba(139, 107, 71, 0.48);

    box-shadow:
        0 16px 36px rgba(34, 34, 34, 0.12);

    transform: translateY(-4px);
}

.shop-archive
ul.products
li.product
.woocommerce-LoopProduct-link {
    display: flex;
    flex: 1;
    flex-direction: column;

    color: inherit;

    text-decoration: none;
}


/* ==========================================================
   Produktbilder
========================================================== */

.shop-archive
ul.products
li.product
.woocommerce-LoopProduct-link
img {
    display: block;

    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;

    margin: 0 0 20px !important;

    background-color: #f7f4ed;

    border-radius: 8px;

    object-fit: cover;

    transition:
        opacity 0.25s ease,
        transform 0.35s ease;
}

.shop-archive
ul.products
li.product:hover
.woocommerce-LoopProduct-link
img {
    transform: scale(1.025);
}


/* ==========================================================
   Produktinformationen
========================================================== */

.shop-archive
ul.products
li.product
.woocommerce-loop-product__title {
    margin: 0;
    padding: 0 4px 8px !important;

    color: #222222;

    font-family: "Cormorant Garamond", serif;
    font-size: 1.4rem !important;
    font-weight: 600;
    line-height: 1.25;

    transition: color 0.2s ease;
}

.shop-archive
ul.products
li.product
.woocommerce-LoopProduct-link:hover
.woocommerce-loop-product__title {
    color: #8b6b47;
}


/* ==========================================================
   Preise
========================================================== */

.shop-archive
ul.products
li.product
.price {
    display: block;

    margin: auto 0 16px !important;
    padding: 0 4px;

    color: #8b6b47 !important;

    font-family: "Inter", sans-serif;
    font-size: 1rem !important;
    font-weight: 600;
    line-height: 1.4;
}

.shop-archive
ul.products
li.product
.price del {
    margin-right: 6px;

    color: rgba(34, 34, 34, 0.48);

    font-size: 0.85rem;

    opacity: 1;
}

.shop-archive
ul.products
li.product
.price ins {
    color: #8b6b47;

    font-weight: 600;
    text-decoration: none;
}


/* ==========================================================
   Produktkennzeichnungen
========================================================== */

.shop-archive
ul.products
li.product
.onsale {
    top: 22px;
    right: 22px;
    left: auto;

    min-width: 0;
    min-height: 0;

    margin: 0;
    padding: 6px 10px;

    color: #ffffff;
    background-color: #8b6b47;

    border-radius: 999px;

    font-family: "Inter", sans-serif;
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1;
}


/* ==========================================================
   Produkt-Buttons
========================================================== */

.shop-archive
ul.products
li.product
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    min-height: 46px;

    margin: 0 !important;
    padding: 12px 18px !important;

    color: #ffffff !important;
    background-color: #8b6b47 !important;

    border: 1px solid #8b6b47 !important;
    border-radius: 7px !important;

    font-family: "Inter", sans-serif;
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    line-height: 1.3 !important;
    text-align: center;
    text-decoration: none !important;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.shop-archive
ul.products
li.product
.button:hover,
.shop-archive
ul.products
li.product
.button:focus-visible {
    color: #ffffff !important;
    background-color: #725538 !important;

    border-color: #725538 !important;

    box-shadow:
        0 6px 16px rgba(139, 107, 71, 0.22);

    transform: translateY(-1px);
}

.shop-archive
ul.products
li.product
.button:focus-visible {
    outline: 3px solid rgba(139, 107, 71, 0.2);
    outline-offset: 2px;
}

.shop-archive
ul.products
li.product
.added_to_cart {
    display: block;

    margin-top: 10px;

    color: #8b6b47;

    font-size: 0.85rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
}


/* ==========================================================
   Leere Produktübersicht
========================================================== */

.shop-archive
.woocommerce-info {
    margin: 0;
    padding: 20px 22px;

    color: #222222;
    background-color: #f5f1e8;

    border: 1px solid rgba(139, 107, 71, 0.16);
    border-top: 3px solid #8b6b47;
    border-radius: 8px;
}


/* ==========================================================
   Pagination
========================================================== */

.shop-archive
.woocommerce-pagination {
    margin-top: 48px;
}

.shop-archive
.woocommerce-pagination
ul.page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    margin: 0 !important;
    padding: 0 !important;

    border: 0 !important;

    list-style: none;
}

.shop-archive
.woocommerce-pagination
ul.page-numbers
li {
    float: none;

    margin: 0;

    border: 0;
}

.shop-archive
.woocommerce-pagination
.page-numbers
a,
.shop-archive
.woocommerce-pagination
.page-numbers
span {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 42px;
    height: 42px;

    padding: 0 12px;

    color: #222222;
    background-color: #ffffff;

    border: 1px solid rgba(139, 107, 71, 0.18);
    border-radius: 7px;

    font-size: 0.9rem;
    text-decoration: none;

    transition:
        color 0.2s ease,
        background-color 0.2s ease,
        border-color 0.2s ease;
}

.shop-archive
.woocommerce-pagination
.page-numbers
a:hover,
.shop-archive
.woocommerce-pagination
.page-numbers
a:focus-visible,
.shop-archive
.woocommerce-pagination
.page-numbers
.current {
    color: #ffffff;
    background-color: #8b6b47;

    border-color: #8b6b47;
}


/* ==========================================================
   Tablets
========================================================== */

@media (max-width: 1024px) {

    .shop-archive__container {
        padding-right: 20px;
        padding-left: 20px;
    }

    .shop-archive
    ul.products {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}


/* ==========================================================
   Mobile Geräte
========================================================== */

@media (max-width: 768px) {

    .shop-archive__container {
        padding: 8px 16px 28px;
    }

    .shop-archive
    .woocommerce-products-header {
        margin-bottom: 22px;
    }

    .shop-toolbar {
        align-items: stretch;
        flex-direction: column;
        gap: 16px;

        margin-bottom: 24px;
        padding-bottom: 16px;
    }

    .shop-categories {
        width: 100%;

        overflow-x: auto;

        scrollbar-width: thin;
    }

    .shop-categories__list {
        flex-wrap: nowrap;
        gap: 24px;

        width: max-content;
        min-width: 100%;
    }

    .shop-categories__link {
        white-space: nowrap;
    }

    .shop-toolbar
    .woocommerce-ordering {
        align-self: flex-end;
    }

    .shop-toolbar
    .woocommerce-ordering
    select {
        min-width: 165px;
    }

    .shop-archive
    ul.products {
        gap: 24px;
    }

}


/* ==========================================================
   Kleine Smartphones
========================================================== */

@media (max-width: 560px) {

    .shop-toolbar
    .woocommerce-ordering {
        align-self: flex-start;
    }

    .shop-archive
    ul.products {
        grid-template-columns: 1fr;
    }

    .shop-archive
    ul.products
    li.product {
        padding: 10px 10px 14px;
    }

    .shop-archive
    ul.products
    li.product
    .woocommerce-loop-product__title {
        font-size: 1.3rem !important;
    }

}