/* Bastian Bandt – FluentCart Shop-Karten
   Eigene Datei. Plugin-Originale unangetastet. Update-sicher (mu-plugin). */

/* Karte: kein Rahmen, kein Hintergrund, keine Rundung, kein Padding */
.fct-product-card {
    display: flex;
    flex-direction: column;
    border: none !important;
    background: transparent !important;
    border-radius: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
}

/* Bild: quadratisch (1/1), bündig, eigene Rundung an allen Ecken */
.fct-product-card .fct-product-card-image-wrap,
.fct-product-card .fct-dynamic-product-image {
    margin: 0 !important;
    aspect-ratio: 1 / 1;
}
.fct-product-card img,
.fct-product-card .fct-product-card-image {
    border-radius: 8px !important;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

/* Text dicht ans Bild */
.fct-product-card .fct-product-card-title {
    padding-top: 10px;
    margin-top: auto;
}
.fct-product-card .fct-product-card-prices {
    padding-bottom: 10px;
}

/* Button rauf + Textgruppe vertikal zentriert im Restraum */
.fct-product-card > button,
.fct-product-card > a.fct-product-view-button {
    margin-top: 0 !important;
    margin-bottom: auto !important;
}

/* === Produkt-Einzelseite: Galerie === */
/* Hauptbild: kein Rahmen, nur Bild-Rundung, klickbar */
.fct-product-gallery-thumb {
    border: none !important;
}
.fct-product-gallery-thumb img {
    border-radius: 8px !important;
    cursor: zoom-in;
}

/* Eigene Lightbox */
.bb-lb-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, .9);
    opacity: 0;
    transition: opacity .2s ease;
}
.bb-lb-overlay.is-open { opacity: 1; }
.bb-lb-overlay img {
    max-width: 92vw;
    max-height: 92vh;
    border-radius: 6px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, .5);
    -webkit-user-select: none;
    user-select: none;
}
.bb-lb-btn {
    position: absolute;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s ease;
}
.bb-lb-btn:hover { background: rgba(255, 255, 255, .25); }
.bb-lb-close { top: 20px; right: 20px; }
.bb-lb-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.bb-lb-next { right: 20px; top: 50%; transform: translateY(-50%); }
@media (max-width: 600px) {
    .bb-lb-prev, .bb-lb-next { width: 40px; height: 40px; font-size: 22px; }
    .bb-lb-close { top: 12px; right: 12px; }
}

/* Haupt-Kaufbutton (Produktseite): dunkler Hintergrund, weisser Text */
.fct_buy_section .fluent-cart-add-to-cart-button,
.fct-product-buttons-wrap .fluent-cart-add-to-cart-button,
.fct-product-buttons-wrap button.fct-product-view-button {
    background: var(--fct-btn-bg-color, #253241) !important;
    color: #fff !important;
}
.fct_buy_section .fluent-cart-add-to-cart-button *,
.fct-product-buttons-wrap .fluent-cart-add-to-cart-button *,
.fct-product-buttons-wrap button.fct-product-view-button * {
    color: #fff !important;
}

/* 'Jetzt kaufen' (Direct-Checkout-Link): weisser Text statt Enfold-Rot */
.fct-product-buttons-wrap .fluent-cart-direct-checkout-button,
.fct-product-buttons-wrap .fluent-cart-direct-checkout-button:hover,
.fct-product-buttons-wrap .fluent-cart-direct-checkout-button:focus,
.fct-product-buttons-wrap a.fct-product-view-button,
.fct-product-buttons-wrap a.fct-product-view-button:hover {
    color: #fff !important;
}
.fct-product-buttons-wrap .fluent-cart-direct-checkout-button *,
.fct-product-buttons-wrap a.fct-product-view-button * {
    color: #fff !important;
}

/* === [bb_products] Startseiten-Raster === */
.bb-products-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(var(--bb-cols, 4), 1fr);
}
@media (max-width: 990px) { .bb-products-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 768px) { .bb-products-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575px) { .bb-products-grid { grid-template-columns: 1fr; } }

.bb-prod-item,
.bb-prod-item:hover,
.bb-prod-item:focus {
    display: flex;
    flex-direction: column;
    text-decoration: none !important;
    color: #2F3448 !important;
}
.bb-prod-img {
    display: block;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 8px;
}
.bb-prod-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s ease;
}
.bb-prod-item:hover .bb-prod-img img { transform: scale(1.04); }
.bb-prod-title {
    margin-top: 10px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    color: inherit;
}

/* === Produktseite: Quantitaet-Stepper – Feld groesser, Ziffer vertikal zentriert === */
.fct-product-quantity {
    height: 44px !important;
    align-items: stretch !important;
    width: auto !important;
}
.fct-product-quantity-container .fct-quantity-input {
    width: 56px !important;
    height: 44px !important;
    padding: 0 !important;
    margin: 0 !important;
    font-size: 16px !important;
    line-height: 44px !important;
    text-align: center !important;
    box-sizing: border-box !important;
    -moz-appearance: textfield;
    appearance: textfield;
}
.fct-product-quantity-container .fct-quantity-input::-webkit-outer-spin-button,
.fct-product-quantity-container .fct-quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.fct-product-quantity-container .fct-quantity-increase-button,
.fct-product-quantity-container .fct-quantity-decrease-button {
    height: 44px !important;
    width: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
}
.fct-product-quantity-container .quantity-title {
    text-align: left !important;
}

/* max-width:36px aus single-product.css aufheben */
.fct-product-quantity .fct-quantity-input,
.fct-product-quantity-container .fct-quantity-input {
    max-width: 56px !important;
    min-width: 56px !important;
    height: 44px !important;
}

/* max-height:36px aus single-product.css aufheben */
.fct-product-quantity .fct-quantity-input,
.fct-product-quantity-container .fct-quantity-input {
    max-height: 44px !important;
    min-height: 44px !important;
}

/* === Produktpreis als Klebeschild === */
.fct-product-summary .fct-price-range {
    display: inline-block;
    background-image: url('preis-hg.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    padding: 24px 46px;
    transform: rotate(-4deg);
    line-height: 1;
}
.fct-product-summary .fct-price-range .fct-item-price,
.fct-product-summary .fct-price-range .fct-item-price span {
    font-family: typeka, sans-serif !important;
    font-size: 30px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    color: #2F3448 !important;
}

/* Produktseite: Artikel-Ueberschrift etwas groesser */
.fct-product-summary .fct-product-title h1,
#fct-product-summary-title {
    font-size: 38px !important;
}
