/* ========================================
   Poppins Font Family - Lokal gehostet
   ======================================== */

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-Italic.ttf') format('truetype');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Poppins';
    src: url('../fonts/Poppins-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ========================================
   Poppins global anwenden
   ======================================== */

body {
    font-family: 'Poppins', 'Open Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif !important;
}

/* ========================================
   Produkt-Beschreibungen mit Icons
   ======================================== */
.header-left a.logo img {
    object-fit: contain !important;
}


.product.attribute.description .value ul {
    padding-left: 0px !important;
    padding-inline-start: 0px !important;
    list-style: none;
}

.product.attribute.description .value ul li {
    position: relative;
    padding-left: 35px;
    margin-bottom: 12px;
    line-height: 1.6;
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
}

.product.attribute.description .value ul li:before {
    content: '✓';
    position: absolute;
    left: 0;
    font-size: 20px;
    font-weight: 600;
    color: #4CAF50;
}

/* ========================================
   Quelle Input
   ======================================== */

#quelle_dv {
    display: flex;
    align-items: center;
    gap: 10px;
}

#quelle_dv input#quelle {
    width: 3em;
    text-align: center;
}

/* ========================================
   Helper Classes
   ======================================== */

.a-center {
    text-align: center;
}

.a-left {
    text-align: left;
}

.a-right {
    text-align: right;
}

/* ========================================
   Grouped Product Table
   3 Spalten: Name à | Preis | Grundpreis
   Radio-Button versteckt, Zeile klickbar
   ======================================== */

#super-product-table {
    width: 100%;
    table-layout: auto;
    border-collapse: collapse;
}

#super-product-table td,
#super-product-table th {
    padding: 12px 10px;
    vertical-align: middle;
}

#super-product-table th {
    background: #f5f5f5;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Versteckte Inputs (Radio + Number) */
#super-product-table .hidden-radio,
#super-product-table input[type="number"] {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Spalte 1: Name à */
#super-product-table .col-name,
#super-product-table td.col-name {
    width: 45%;
    text-align: right;
    white-space: nowrap;
}

#super-product-table td.col-name .item-name {
    font-weight: 500;
}

#super-product-table td.col-name .stock-unavailable {
    font-size: 0.8rem;
    color: #c00;
    margin-right: 8px;
}

/* Spalte 2: Preis */
#super-product-table .col-price,
#super-product-table td.col-price {
    width: 25%;
    white-space: nowrap;
    text-align: center;
}

/* Spalte 3: Grundpreis */
#super-product-table .col-baseprice,
#super-product-table td.col-grundpreis {
    width: 30%;
    white-space: nowrap;
    text-align: right;
    font-size: 0.88rem;
    color: #555;
}

/* Zeilen-Interaktion */
#super-product-table tbody tr {
    cursor: pointer;
    transition: all 0.15s ease;
    border-left: 3px solid transparent;
}

#super-product-table tbody tr:hover {
    background-color: #f5f8fb;
}

/* Ausgewählte Zeile - deutlich erkennbar */
#super-product-table tr.selected {
    background-color: #eaf3fb;
    border-left: 4px solid var(--theme-color, #2196F3);
    box-shadow: inset 0 1px 0 rgba(0,0,0,0.04), inset 0 -1px 0 rgba(0,0,0,0.04);
}

#super-product-table tr.selected td.col-name .item-name {
    font-weight: 700;
    color: var(--theme-color, #2196F3);
}

#super-product-table tr.selected:hover {
    background-color: #ddedf8;
}

/* Price Styling */
.table.grouped .price-box .price {
    font-size: 1rem;
    font-weight: 600;
}

.table.grouped .price-box {
    margin: 0;
}

/* ========================================
   Versandtabelle
   ======================================== */

.versand {
    border-collapse: collapse;
    border-spacing: 0;
    width: 100%;
    display: block;
    overflow-x: auto;
}

.versand .kopf {
    vertical-align: middle;
    text-align: center;
    border: 1px solid;
    padding: 3px 10px;
}

.versand .mitte {
    vertical-align: middle;
    text-align: center;
    border: 1px solid;
    padding: 3px;
}

.versand .links {
    vertical-align: middle;
    text-align: left;
    border: 1px solid;
    padding: 3px;
}

.v-box {
    font-size: 0.9rem;
}

.lieferung-uebersicht h2 {
    margin: 0px;
}

/* ========================================
   Kategorie- und Produktansicht
   ======================================== */

.breadcrumbs {
    height: 30px;
}

.page-wrapper > .breadcrumbs .items {
    padding: 0px !important;
}

.product-item-name a {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.minimal-price {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin: 0;
}

.minimal-price .price-label,
.minimal-price .price-container {
    display: inline;
}

.catalog-category-view .product-item .price-box .price-label {
    font-size: 1.0rem;
}

.catalog-category-view .price-box .price {
    font-size: 1.0rem;
}

info.type6 .product.name {
    padding-right: 0px;
}

/* ========================================
   Footer
   ======================================== */

.zahlungsarten {
    display: flex;
    flex-wrap: wrap;
    max-height: 40px;
    max-width: 100%;
}

.footer ul {
    display: flex;
    gap: 15px;
}

/* ========================================
   Grouped Product Table - Responsive
   ======================================== */

.table-wrapper.grouped {
    overflow-x: hidden;
    container-type: inline-size;
    container-name: grouped-table;
}

/* Magento mobile override: Tabelle als Tabelle behalten */
@media (max-width: 767px) {
    #super-product-table,
    #super-product-table thead,
    #super-product-table thead tr,
    #super-product-table thead th,
    #super-product-table tbody,
    #super-product-table tbody tr,
    #super-product-table tbody td {
        display: revert !important;
    }

    #super-product-table tbody td:before {
        content: none !important;
        display: none !important;
    }
}

/* Container < 400px: kompakter */
@container grouped-table (max-width: 400px) {
    #super-product-table {
        font-size: 0.85rem;
    }

    #super-product-table td,
    #super-product-table th {
        padding: 10px 6px;
    }

    .table.grouped .price-box .price {
        font-size: 0.92rem;
    }

    #super-product-table .col-baseprice,
    #super-product-table td.col-grundpreis {
        font-size: 0.8rem;
    }
}

/* Container < 300px: Grundpreis darf umbrechen */
@container grouped-table (max-width: 300px) {
    #super-product-table {
        font-size: 0.8rem;
    }

    #super-product-table td,
    #super-product-table th {
        padding: 8px 4px;
    }

    #super-product-table .col-name,
    #super-product-table td.col-name {
        white-space: normal;
    }

    #super-product-table .col-baseprice,
    #super-product-table td.col-grundpreis {
        white-space: normal;
        font-size: 0.75rem;
    }

    .table.grouped .price-box .price {
        font-size: 0.85rem;
    }
}

/* =============================================
   HEADER ACCOUNT LINKS - Horizontal mit Pipe
   ============================================= */

/* Äußere Liste horizontal - korrigierter Selektor */
.header-right .panel.header.show-icon-tablet > ul.header.links {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Äußere li Elemente */
.header-right .panel.header.show-icon-tablet > ul.header.links > li {
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Innere verschachtelte ul (Mein Konto, Abmelden) */
.header-right .panel.header.show-icon-tablet > ul.header.links > ul.header.links {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Innere li Elemente */
.header-right .panel.header.show-icon-tablet > ul.header.links > ul.header.links > li {
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Pipe-Trennung zwischen Willkommen und Mein Konto */
.header-right .panel.header.show-icon-tablet > ul.header.links > li.greet.welcome::after {
    content: "|" !important;
    margin: 0 10px !important;
}

/* Pipe-Trennung zwischen Mein Konto und Abmelden */
.header-right .panel.header.show-icon-tablet > ul.header.links > ul.header.links > li:first-child::after {
    content: "|" !important;
    margin: 0 10px !important;
    color: #999 !important;
}

/* Desktop: top-links-icon ausblenden */
@media (min-width: 768px) {
    .header-right .panel.header.show-icon-tablet .top-links-icon {
        display: none !important;
    }
}

@media (max-width: 991px) {
    .logo {
        max-width: 80px;
    }
}

.section-item-content[id="store.links"] > ul.header.links ~ ul.header.links {
    display: none !important;
}

.minicart-items .product-item-name {
    white-space: normal !important;
}

/* Mobile: Order Summary immer sichtbar statt als Modal */
@media (max-width: 767px) {
    /* Toggle-Button und kompakte Ansicht ausblenden */
    .opc-estimated-wrapper {
        display: none !important;
    }
    
    /* Sidebar als normales Element statt Modal anzeigen */
    .checkout-container .opc-sidebar.opc-summary-wrapper {
        position: static !important;
        transform: none !important;
        visibility: visible !important;
        opacity: 1 !important;
        display: block !important;
        width: 100% !important;
        left: auto !important;
        right: auto !important;
        z-index: auto !important;
        box-shadow: none !important;
        margin-bottom: 20px;
    }
    
    /* Modal-Header (Schließen-Button) ausblenden */
    .opc-sidebar .modal-header {
        display: none !important;
    }
    
    /* Modal-Content ohne Modal-Styles */
    .opc-sidebar .modal-inner-wrap {
        position: static !important;
        transform: none !important;
        height: auto !important;
    }
    
    /* Overlay verhindern */
    .modal-custom-overlay {
        display: none !important;
    }
    
    /* Sidebar vor dem Zahlungs-Formular positionieren */
    .checkout-container {
        display: flex;
        flex-direction: column;
    }
    
    .checkout-container .opc-sidebar {
        order: -1; /* Vor den anderen Elementen */
    }
}

/* Doppelpunkt nach Labels in Checkout und Mini Cart */
.block-minicart .subtotal .label:after,
.minicart-items .details-qty .label:after,
.minicart-items .price-minicart .label:after,
.order-details-items .order-gift-message .label:after,
.order-details-items .block-order-details-gift-message .label:after,
.block-wishlist-management .wishlist-select .wishlist-name-label:after {
    content: ":\00a0";
}

/* Checkout: Breitere Sidebar und schmalerer Inhalt ab Tablet */
@media screen and (min-width: 768px) {
    .checkout-container .opc-sidebar {
        width: 50%;
    }
    
    .checkout-container .opc-wrapper {
        width: 47%; /* 100% - 50% - etwas Abstand */
    }
}


/* Doppeltes Rechnungsadresse-Label im Dropdown ausblenden */
.checkout-billing-address .field-select-billing > .label {
    display: none;
}

/* Legend-Stil an step-title angleichen */
#co-payment-form > .fieldset > .legend {
    border-bottom: 1px solid #ccc;
    margin-bottom: 15px;
    padding-bottom: 10px;
    width: 100%;
    font-size: 18px;
    font-weight: 600;
}

/* Doppelte Zahlungsmethode-Überschrift aus payment-methods-list ausblenden */
.payment-group > .step-title {
    display: none;
}

.minicart-items .product-item-details {
    max-width: 100% !important;
    padding: 0 !important;
}

.opc-block-shipping-information {
    padding: 22px 1.5em;
}

.opc-wrapper .shipping-address-item {
    width: 100%;
    line-height: normal;
    margin: 0;
}

.opc-wrapper .shipping-address-item.not-selected-item {
    border-bottom: 1px solid #e7e7e7;
    border-top: 1px solid #e7e7e7;

}
.opc-wrapper .action-select-shipping-item {
    float: left;
}

.table-checkout-shipping-method .col-carrier {
    white-space: nowrap;
}

.opc-wrapper .action-show-popup {
    margin: 2em 1em 0em;
}

.opc-wrapper .step-content .actions-toolbar {
    padding: 0 0 1em;
}

.minicart-items .product-item-details .product-item-name {
    line-height: 1;
    font-size: 0.9em;
    font-weight: 400;
    overflow: visible;
}

.minicart-wrapper .block-minicart .subtotal {
    text-transform: none !important;
    line-height: 1.2 !important;
}

.checkout-payment-method ._active .payment-method-title {
    padding: 1em 0;
}

@media only screen and (max-width: 767px) {
    .checkout-payment-method .payment-method-title {
        padding: 1em 0 0 1em !important;
    }
}

#checkout-step-payment .step-title {
    margin: 30px 0 0;
}

.checkout-payment-method .billing-address-same-as-shipping-block {
    margin: 1em 0 0.5em;
}

.opc-wrapper .step-title {
    border-bottom: 2px solid #e7e7e7;
}

.payment-method-ppcp_card .fieldset .field .label > span {
    font-size: 1rem;
}

/* ==============================================
   Zahlungsarten-Logos im Checkout
   ============================================== */

/* Container für Radio-Button + Label vertikal zentrieren */
.payment-method-title.field.choice {
    display: flex;
    align-items: center;
}

/* Grundlegende Ausrichtung für alle Payment Labels */
.payment-method-title .label {
    display: inline-flex;
    align-items: center;
}

/* Rechnung (Check/Money Order) */
#checkmo + .label::before {
    content: '';
    display: inline-block;
    width: 60px;
    height: 40px;
    margin-right: 8px;
    background: url('../images/payment/invoice.svg') no-repeat center;
    background-size: contain;
    flex-shrink: 0;
}

/* Vorkasse (Bank Transfer) */
#banktransfer + .label::before {
    content: '';
    display: inline-block;
    width: 60px;
    height: 40px;
    margin-right: 8px;
    background: url('../images/payment/bank-transfer.svg') no-repeat center;
    background-size: contain;
    flex-shrink: 0;
}

/* Optional: Kreditkarte (ppcp_card) - falls gewünscht */
#ppcp_card + .label::before {
    content: '';
    display: inline-block;
    width: 60px;
    height: 40px;
    margin-right: 8px;
    background: url('../images/payment/credit-card.svg') no-repeat center;
    background-size: contain;
    flex-shrink: 0;
}

/* PayPal Logo Größe */
.payment-method-ppcp_paypal .payment-method-title .payment-icon {
    width: 60px !important;
    height: 40px !important;
    object-fit: contain;
}

.payment-methods .payment-group .payment-method-title label img {
    width: 60px;
    margin-right: 8px;
}

/* Kreditkarten Inline-Fehlermeldungen */
.payment-method-ppcp_card .fieldset .field .hosted-error {
    height: 0;
    overflow: hidden;
    opacity: 0;
    font-size: 0.9rem;
    transition: height 0.2s ease-in-out, opacity 0.2s ease-in-out;
}

.payment-method-ppcp_card .fieldset .field._error .hosted-error {
    height: auto;
    opacity: 1;
    font-size: 0.9rem;
}

.payment-method-ppcp_card .field._error label {
    color: #e02b27;
}

/* Hinweis für Pflichtfelder  */
.field-required-notice {
    margin-top: 15px;
    font-size: 0.9em;
    color: #666;
}

.field-required-notice .required-marker {
    color: #e02b27;
    font-weight: bold;
}

/* "In den Warenkorb" Button in der Kategorie ausblenden */
.product-item-info .product-type-advanced .product-item-inner .product-item-actions > .actions-primary .tocart {
    display: none !important;
}

.product-add-form .v_box a {
    color: #777;
}

.product-add-form .v_box a:hover {
    color: var(--theme-color) !important;
}

.footer-middle a:hover, .footer .widget .tagcloud a:hover {
    color: var(--theme-color) !important;
}

.page-wrapper > .breadcrumbs .items>li.home a {
    padding-left: 10px;
}

#checkout-step-payment .checkout-billing-address button.action-update {
    background-color: var(--theme-color);
    color: #fff;
}