/* ================================================================
   Product catalog styles - listing
   ================================================================ */
/* ═══════════════════════════════════════════════════════════
                                                                                                                                                            PROMEDICAL KATALOG-LISTING — Design
                                                                                                                                                            ═══════════════════════════════════════════════════════════ */
/* ── Layout ── */
.pm-catalog-container {
    padding-top: 0;
    padding-bottom: 1rem;
}

/* ══════════════════════════════════════════════════════════
                                                                                                                                                            FILTER-BAR — Ein-/ausklappbar, Mehrfach-Dropdowns
                                                                                                                                                            ══════════════════════════════════════════════════════════ */
.pm-filter-bar {
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    margin-bottom: 0.75rem;
    overflow: visible;
}

/* Header */
.pm-filter-bar-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.85rem;
    flex-wrap: wrap;
}

.pm-filter-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: none;
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    padding: 0.4rem 0.85rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--pm-text);
    cursor: pointer;
    white-space: nowrap;
    transition: border-color var(--pm-transition), background var(--pm-transition);
}

.pm-filter-toggle-btn:hover {
    border-color: var(--pm-blue);
    background: var(--pm-light);
}

.pm-filter-toggle-chevron {
    font-size: 0.6rem;
    color: var(--pm-muted);
    transition: transform 0.25s;
}

.pm-filter-bar.open .pm-filter-toggle-chevron {
    transform: rotate(180deg);
}

.pm-filter-badge {
    background: var(--pm-blue);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
}

/* Chips */
.pm-filter-chips {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.pm-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: var(--pm-light);
    border: 1px solid var(--pm-border);
    border-radius: 20px;
    padding: 0.2rem 0.55rem;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--pm-dark);
    white-space: nowrap;
}

.pm-chip-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--pm-muted);
    color: #fff;
    font-size: 0.75rem;
    line-height: 1;
    text-decoration: none;
    transition: background 0.15s;
}

.pm-chip-remove:hover {
    background: #dc3545;
    color: #fff;
}

.pm-filter-clear-all {
    font-size: 0.78rem;
    color: var(--pm-muted);
    text-decoration: none;
    white-space: nowrap;
}

.pm-filter-clear-all:hover {
    color: var(--pm-blue);
    text-decoration: underline;
}

/* Ausklappbarer Body */
.pm-filter-bar-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 0.85rem;
    border-top: 0 solid transparent;
}

.pm-filter-bar-body.open {
    max-height: 300px;
    overflow: visible;
    padding: 0.75rem 0.85rem;
    border-top: 1px solid var(--pm-border);
}

/* Dropdown-Reihe */
.pm-filter-dd-row {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Einzelner Dropdown */
.pm-filter-dd {
    position: relative;
}

.pm-filter-dd-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    padding: 0.45rem 0.75rem;
    font-size: 0.85rem;
    color: var(--pm-text);
    cursor: pointer;
    white-space: nowrap;
    transition: border-color var(--pm-transition), box-shadow var(--pm-transition);
}

.pm-filter-dd-btn:hover,
.pm-filter-dd.open .pm-filter-dd-btn {
    border-color: var(--pm-blue);
    box-shadow: 0 0 0 2px rgba(33, 83, 149, .08);
}

.pm-filter-dd-btn.has-value {
    border-color: var(--pm-blue);
    background: rgba(33, 83, 149, .04);
}

.pm-filter-dd-label {
    font-weight: 600;
    color: var(--pm-dark);
}

.pm-filter-dd-value {
    color: var(--pm-blue);
    font-weight: 500;
}

.pm-filter-dd-value::before {
    content: ':';
    margin-right: 0.2rem;
    color: var(--pm-muted);
}

.pm-filter-dd-chevron {
    font-size: 0.6rem;
    color: var(--pm-muted);
    transition: transform 0.2s;
    margin-left: 0.1rem;
}

.pm-filter-dd.open .pm-filter-dd-chevron {
    transform: rotate(180deg);
}

/* Dropdown-Menü */
.pm-filter-dd-menu {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 220px;
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    box-shadow: 0 8px 24px rgba(16, 39, 70, .12);
    z-index: 120;
    padding: 0;
}

.pm-filter-dd.open .pm-filter-dd-menu {
    display: block;
}

/* Aktionen: Alle auswählen / Zurücksetzen */
.pm-filter-dd-actions {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0.75rem;
}

.pm-filter-dd-action {
    background: none;
    border: none;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pm-blue);
    cursor: pointer;
    padding: 0;
    transition: color 0.15s;
}

.pm-filter-dd-action:hover {
    color: var(--pm-dark);
}

/* Trennlinie */
.pm-filter-dd-divider {
    height: 1px;
    background: var(--pm-border);
}

/* Checkbox-Einträge */
.pm-filter-dd-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.75rem;
    font-size: 0.85rem;
    color: var(--pm-text);
    cursor: pointer;
    transition: background 0.12s;
    user-select: none;
}

.pm-filter-dd-checkbox:hover {
    background: var(--pm-light);
}

.pm-filter-dd-checkbox input[type="checkbox"] {
    display: none;
}

/* Custom Checkbox-Icon */
.pm-filter-dd-check-icon {
    width: 18px;
    height: 18px;
    border: 2px solid var(--pm-border);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.15s;
}

.pm-filter-dd-checkbox input:checked+.pm-filter-dd-check-icon {
    background: var(--pm-blue);
    border-color: var(--pm-blue);
}

.pm-filter-dd-checkbox input:checked+.pm-filter-dd-check-icon::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Pro', 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 0.6rem;
    color: #fff;
}

/* Footer mit Anwenden-Button */
.pm-filter-dd-footer {
    padding: 0.5rem 0.75rem;
}

.pm-filter-dd-apply {
    width: 100%;
    background: var(--pm-blue);
    color: #fff;
    border: none;
    border-radius: var(--pm-radius);
    padding: 0.45rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--pm-transition);
}

.pm-filter-dd-apply:hover {
    background: var(--pm-dark);
}

/* Responsive */
@media (max-width: 575.98px) {
    .pm-filter-dd-row {
        flex-direction: column;
    }

    .pm-filter-dd-btn {
        width: 100%;
        justify-content: space-between;
    }

    .pm-filter-dd-menu {
        width: 100%;
        min-width: unset;
    }
}

/* ══════════════════════════════════════════════════════════
                                                                                                                                                            HAUPTBEREICH
                                                                                                                                                            ══════════════════════════════════════════════════════════ */
.pm-main-content {
    padding: 1.5rem 1.5rem;
    background: var(--pm-light);
    min-height: calc(100vh - 80px);
}

/* ── Card Carousel ── */
.pm-card-carousel {
    position: relative;
    overflow: hidden;
}

.pm-carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.pm-carousel-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

.pm-carousel-slide.active {
    opacity: 1;
    position: relative;
    pointer-events: auto;
}

.pm-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .85);
    color: var(--pm-dark);
    font-size: 0.7rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .15);
    opacity: 0;
    transition: opacity 0.2s;
    z-index: 2;
}

.pm-card-carousel:hover .pm-carousel-btn {
    opacity: 1;
}

.pm-carousel-prev {
    left: 6px;
}

.pm-carousel-next {
    right: 6px;
}

.pm-carousel-btn:hover {
    background: var(--pm-blue);
    color: #fff;
}

.pm-carousel-dots {
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
    z-index: 2;
}

.pm-carousel-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .5);
    border: 1px solid rgba(0, 0, 0, .15);
    cursor: pointer;
    transition: background 0.2s;
}

.pm-carousel-dot.active {
    background: var(--pm-blue);
    border-color: var(--pm-blue);
}

/* Kein-Bild Placeholder */
.pm-gallery-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--pm-border);
    font-size: 0.875rem;
    padding: 6px;
}

.pm-gallery-placeholder i {
    font-size: 3rem;
}

/* ── Suchleiste ── */
.pm-search-bar {
    margin-bottom: 1rem;
    margin-top: -1rem;
}

.pm-search-form {
    margin-bottom: 0.75rem;
}

.pm-search-wrap {
    display: flex;
    align-items: center;
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    padding: 0 0.75rem;
    box-shadow: var(--pm-shadow);
    transition: box-shadow var(--pm-transition), border-color var(--pm-transition);
}

.pm-search-wrap:focus-within {
    border-color: var(--pm-blue);
    box-shadow: 0 0 0 3px rgba(33, 83, 149, .1);
}

.pm-search-icon {
    color: var(--pm-muted);
    font-size: 1rem;
    margin-right: 0.5rem;
}

.pm-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 0.75rem 0;
    font-size: 0.95rem;
    background: transparent;
    color: var(--pm-text);
}

.pm-search-input::placeholder {
    color: var(--pm-muted);
}

.pm-search-btn {
    background: var(--pm-blue);
    color: #fff;
    border: none;
    border-radius: calc(var(--pm-radius) - 1px);
    padding: 0.4rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--pm-transition);
    margin: 0.25rem 0;
}

.pm-search-btn:hover {
    background: var(--pm-dark);
}

.pm-results-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.875rem;
}

.pm-count {
    color: var(--pm-muted);
    margin-left: auto;
}

.pm-active-category-badge,
.pm-search-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--pm-blue);
    color: #fff;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.pm-badge-remove {
    color: rgba(255, 255, 255, .8);
    text-decoration: none;
    font-size: 1rem;
    line-height: 1;
}

.pm-badge-remove:hover {
    color: #fff;
}

/* ── Produkt-Grid ── */
.pm-product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
}

.pm-product-card {
    background: var(--pm-white);
    border-radius: var(--pm-radius);
    box-shadow: var(--pm-shadow);
    overflow: hidden;
    transition: box-shadow var(--pm-transition), transform var(--pm-transition);
}

.pm-product-card:hover {
    box-shadow: var(--pm-shadow-hover);
    transform: translateY(-2px);
}

.pm-product-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.pm-product-image {
    position: relative;
    height: 200px;
    background: var(--pm-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.pm-product-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 0.75rem;
    transition: transform 0.3s ease;
}

.pm-product-card:hover .pm-product-img {
    transform: scale(1.03);
}

.pm-product-no-image {
    color: var(--pm-border);
    font-size: 3rem;
}

.pm-badge-steril {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: var(--pm-blue);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.pm-product-body {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.pm-product-category {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--pm-dark);
    margin-bottom: 0.35rem;
    display: block;
}

.pm-product-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--pm-dark);
    margin: 0 0 0.4rem;
    line-height: 1.35;
}

.pm-product-desc {
    font-size: 0.825rem;
    color: var(--pm-muted);
    line-height: 1.45;
    flex: 1;
    margin-bottom: 0.75rem;
}

.pm-product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--pm-border);
    padding-top: 0.6rem;
    margin-top: auto;
}

.pm-product-nr {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pm-text);
    font-variant-numeric: tabular-nums;
}

.pm-product-arrow {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--pm-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pm-dark);
    font-size: 0.8rem;
    transition: background var(--pm-transition), color var(--pm-transition);
}

.pm-product-card:hover .pm-product-arrow {
    background: var(--pm-dark);
    color: #fff;
}

/* ── Verkaufbar-Badge ── */
.pm-badge-verkaufbar {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 3;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    color: #fff;
    line-height: 1.3;
    letter-spacing: 0.02em;
    pointer-events: none;
}

.pm-badge-verkaufbar--ja {
    background: #22c55e;
}

.pm-badge-verkaufbar--nein {
    background: #ef4444;
}

.pm-badge-liquidation {
    background-color: #e74c3c;
    color: #fff;
    top: 2.0rem !important;
}

/* Listenansicht: Bild-Container als vertikaler Flex (Badge oben, Bild unten) */
.pm-list-view .pm-product-image.pm-card-carousel {
    position: relative;
    overflow: hidden;
}

/* Badges oben links als Overlay */
.pm-list-view .pm-product-image.pm-card-carousel .pm-badge-verkaufbar,
.pm-list-view .pm-product-image.pm-card-carousel .pm-badge-liquidation {
    position: absolute;
    left: 8px;
    z-index: 5;
}

/* 1. Badge */
.pm-list-view .pm-product-image.pm-card-carousel .pm-badge-verkaufbar {
    top: 8px;
}

/* 2. Badge darunter */
.pm-list-view .pm-product-image.pm-card-carousel .pm-badge-liquidation {
    top: 34px;
    /* falls Badge höher/kleiner ist: anpassen */
}

/* ── Empty State ── */
.pm-empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--pm-muted);
}

.pm-empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.pm-empty-state p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

/* ── Pagination ── */
.pm-pagination {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
}

.pm-pagination-list {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.pm-page-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 0.5rem;
    border-radius: var(--pm-radius);
    background: var(--pm-white);
    color: var(--pm-text);
    text-decoration: none;
    font-size: 0.875rem;
    border: 1px solid var(--pm-border);
    transition: all var(--pm-transition);
}

.pm-page-btn:hover,
.pm-page-btn.active {
    background: var(--pm-dark);
    color: #fff;
    border-color: var(--pm-dark);
}

.pm-page-ellipsis {
    color: var(--pm-muted);
    padding: 0 0.25rem;
}

/* ══════════════════════════════════════════════════════════
                                                                                                                                                            TOOLBAR: Sort + View Toggle
                                                                                                                                                            ══════════════════════════════════════════════════════════ */
.pm-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 0;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--pm-border);
}

.pm-toolbar-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.pm-toolbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* ── Sort Dropdown ── */
.pm-sort-dropdown {
    position: relative;
}

.pm-sort-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--pm-text);
    cursor: pointer;
    transition: border-color var(--pm-transition), box-shadow var(--pm-transition);
    white-space: nowrap;
}

.pm-sort-btn:hover {
    border-color: var(--pm-blue);
}

.pm-sort-chevron {
    font-size: 0.65rem;
    margin-left: 0.15rem;
    transition: transform 0.2s;
}

.pm-sort-dropdown.open .pm-sort-chevron {
    transform: rotate(180deg);
}

.pm-sort-menu {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 220px;
    background: var(--pm-white);
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    box-shadow: 0 8px 24px rgba(16, 39, 70, .12);
    list-style: none;
    margin: 0;
    padding: 0.35rem 0;
    z-index: 100;
}

.pm-sort-dropdown.open .pm-sort-menu {
    display: block;
}

.pm-sort-option {
    display: block;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    color: var(--pm-text);
    text-decoration: none;
    transition: background 0.15s;
}

.pm-sort-option:hover {
    background: var(--pm-light);
    color: var(--pm-blue);
}

.pm-sort-option.active {
    color: var(--pm-blue);
    font-weight: 600;
    background: var(--pm-light);
}

/* ── View Toggle Buttons ── */
.pm-view-toggle {
    display: flex;
    border: 1px solid var(--pm-border);
    border-radius: var(--pm-radius);
    overflow: hidden;
}

.pm-view-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    background: var(--pm-white);
    color: var(--pm-muted);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    font-size: 0.95rem;
}

.pm-view-btn+.pm-view-btn {
    border-left: 1px solid var(--pm-border);
}

.pm-view-btn:hover {
    background: var(--pm-light);
    color: var(--pm-blue);
}

.pm-view-btn.active {
    background: var(--pm-dark);
    color: #fff;
}

/* ══════════════════════════════════════════════════════════
                                                                                                                                                            LISTENANSICHT
                                                                                                                                                            ══════════════════════════════════════════════════════════ */
.pm-product-grid.pm-list-view {
    grid-template-columns: 1fr !important;
    gap: 0.5rem;
}

.pm-list-view .pm-product-card {
    display: flex;
    flex-direction: row;
    overflow: hidden;
}

.pm-list-view .pm-product-card-link {
    flex-direction: row;
    width: 100%;
}

.pm-list-view .pm-product-image,
.pm-list-view .pm-card-carousel {
    width: 120px;
    min-width: 120px;
    height: 90px;
    border-radius: var(--pm-radius) 0 0 var(--pm-radius);
}

.pm-list-view .pm-product-img {
    padding: 0.4rem;
}

.pm-list-view .pm-product-body {
    flex: 1;
    padding: 0.75rem 1rem;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
}

.pm-list-view .pm-product-info {
    flex: 1;
    min-width: 0;
}

.pm-list-view .pm-product-name {
    font-size: 0.9rem;
    margin: 0;
}

.pm-list-view .pm-product-desc {
    display: block;
    margin: 0.15rem 0 0 0;
    font-size: 0.8rem;
}

.pm-list-view .pm-product-category {
    margin-bottom: 0;
    min-width: 120px;
}

.pm-list-view .pm-product-footer {
    border-top: none;
    padding-top: 0;
    margin-top: 0;
    min-width: 140px;
    justify-content: flex-end;
    gap: 0.75rem;
}

.pm-list-view .pm-product-nr {
    font-size: 0.82rem;
}

.pm-product-info {
    flex: 1;
    min-width: 0;
}

/* Carousel-Buttons in Listenansicht ausblenden */
.pm-list-view .pm-carousel-btn,
.pm-list-view .pm-carousel-dots {
    display: none;
}

/* Badge Steril in Listenansicht */
.pm-list-view .pm-badge-steril {
    position: static;
    font-size: 0.65rem;
    padding: 0.1rem 0.4rem;
}

/* ── Responsive ── */
@media (max-width: 991.98px) {
    .pm-sidebar {
        border-right: none;
        border-bottom: 1px solid var(--pm-border);
        min-height: auto;
    }

    .pm-sidebar-inner {
        position: static;
    }

    .pm-category-list {
        display: flex;
        flex-wrap: wrap;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
    }

    .pm-category-item {
        border-bottom: none;
    }

    .pm-category-link {
        border: 1px solid var(--pm-border);
        border-radius: 20px;
        padding: 0.3rem 0.75rem;
        font-size: 0.8rem;
    }

    .pm-category-item.active .pm-category-link::before {
        display: none;
    }

    .pm-main-content {
        padding: 1rem;
    }

    .pm-product-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

/* Verhindert Flackern beim Laden gespeicherter Einstellungen */
.pm-main-content {
    opacity: 0;
    transition: opacity 0.15s ease;
}

.pm-main-content.pm-ready {
    opacity: 1;
}


/* ================================================================
   Product catalog styles - detail
   ================================================================ */
/* ═══════════════════════════════════════════════════════════
                                            PROMEDICAL KATALOG-DETAIL - Design
                                            ═══════════════════════════════════════════════════════════ */
.pm-detail-container {
    /* padding-top: 1rem; */
    padding-bottom: 1rem;
    font-size: var(--bs-catalog-body-font-size);
}

/* ── Hero: 2-Spalten ── */
.pm-detail-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2.5rem;
    align-items: start;
    /* ← NEU: damit beide Spalten oben bündig beginnen */
}

@media (max-width: 767.98px) {
    .pm-detail-hero {
        grid-template-columns: 1fr;
    }
}

/* ── Galerie / Carousel ── */
.pm-detail-gallery {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* ── Verkaufbar-Badge (Detail) ── */
.pm-detail-verkaufbar-wrap {
    display: flex;
}

.pm-badge-verkaufbar {
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.25rem 0.7rem;
    border-radius: 4px;
    color: #fff;
    letter-spacing: 0.02em;
    line-height: 1.3;
    display: inline-block;
}

.pm-badge-verkaufbar-inline {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 3;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    color: #fff;
    line-height: 1.3;
    letter-spacing: 0.02em;
    pointer-events: none;
    opacity: 1;
    visibility: visible;
}

.pm-badge-verkaufbar--ja {
    background: #22c55e;
}

.pm-badge-verkaufbar--nein {
    background: #ef4444;
}

.pm-badge-liquidation {
    background-color: #e74c3c;
    color: #fff;
    top: 2.4rem !important;
}

.pm-badge-liquidation-related {
    background-color: #e74c3c;
    color: #fff;
    top: 2.4rem !important;
    position: absolute;
    left: 8px;
    z-index: 3;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    line-height: 1.3;
    letter-spacing: 0.02em;
    pointer-events: none;
    opacity: 1;
    visibility: visible;
}

.pm-badge-teal {
    background-color: #0d9488;
    color: #fff;
}

/* ── Detail-Carousel ── */
.pm-detail-carousel {
    position: relative;
    background: var(--pm-light);
    border-radius: var(--pm-radius);
    border: 1px solid var(--pm-border);
    aspect-ratio: 4/3;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Carousel Track & Slides */
.pm-carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.pm-carousel-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

.pm-carousel-slide.active {
    opacity: 1;

    pointer-events: auto;
}

/* Wenn nur 1 Bild: kein absolute positioning nötig */
.pm-carousel-track:only-child .pm-carousel-slide {
    position: relative;
    opacity: 1;
    pointer-events: auto;
}

/* Haupt-Galeriebild im Carousel */
.pm-gallery-main-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 1rem;
}

/* Pfeil-Buttons */
.pm-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--pm-border);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .15);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s, background 0.15s;
    z-index: 2;
    color: var(--pm-blue);
    font-size: 0.9rem;
}

.pm-detail-carousel:hover .pm-carousel-btn {
    opacity: 1;
}

.pm-carousel-prev {
    left: 8px;
}

.pm-carousel-next {
    right: 8px;
}

.pm-carousel-btn:hover {
    background: var(--pm-blue);
    color: #fff;
}

/* Dot-Indikatoren */
.pm-carousel-dots {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
    z-index: 2;
}

.pm-carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .55);
    border: 1px solid rgba(0, 0, 0, .15);
    cursor: pointer;
    transition: background 0.2s;
}

.pm-carousel-dot.active {
    background: var(--pm-blue);
    border-color: var(--pm-blue);
}

/* Kein-Bild Placeholder */
.pm-gallery-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--pm-border);
    font-size: 0.875rem;
}

.pm-gallery-placeholder i {
    font-size: 3rem;
}

/* Thumbnails */
.pm-gallery-thumbs {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: flex-start;
}

.pm-thumb-btn {
    border: 2px solid var(--pm-border);
    border-radius: 6px;
    padding: 2px;
    background: var(--pm-white);
    cursor: pointer;
    transition: border-color 0.15s;
    width: 72px;
    height: 72px;
    overflow: hidden;
}

/* active gesetzt durch Carousel-JS (Thumbnails) */
.pm-thumb-btn.active,
.pm-thumb-btn:hover {
    border-color: var(--pm-blue);
}

.pm-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* ── Produkt-Infos ── */
.pm-detail-category {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--pm-dark);
    display: block;
    margin-bottom: 0.5rem;
}

.pm-detail-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--pm-dark);
    line-height: 1.25;
    margin: 0 0 0.5rem;
}

.pm-detail-subtitle {
    color: var(--pm-muted);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.pm-detail-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1.25rem;
}

.pm-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.7rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
}

.pm-badge-blue {
    background: rgba(33, 83, 149, .1);
    color: var(--pm-blue);
}

.pm-badge-green {
    background: rgba(25, 135, 84, .1);
    color: #198754;
}

.pm-badge-orange {
    background: rgba(253, 126, 20, .1);
    color: #fd7e14;
}

.pm-badge-purple {
    background: rgba(99, 106, 232, .1);
    color: #636ae8;
}

a.pm-badge-link {
    text-decoration: none;
    cursor: pointer;
}

a.pm-badge-link:hover {
    opacity: 0.85;
    text-decoration: none;
}

.pm-detail-table {
    width: 100%;
    font-size: 0.875rem;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.pm-detail-table th,
.pm-detail-table td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--pm-border);
    text-align: left;
}

.pm-detail-table th {
    color: var(--pm-muted);
    font-weight: 600;
    width: 40%;
    background: var(--pm-light);
}

.pm-detail-table td {
    color: var(--pm-text);
}

.pm-detail-downloads {
    margin-top: 1.5rem;
}

.pm-section-subtitle {
    font-size: var(--bs-catalog-body-font-size);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--pm-muted);
    margin-bottom: 0.75rem;
}

.pm-download-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.pm-download-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--pm-blue);
    font-size: 0.875rem;
    text-decoration: none;
}

.pm-download-link:hover {
    text-decoration: underline;
}

.pm-downloads-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.pm-downloads-col {
    min-width: 0;
}

@media (max-width: 900px) {
    .pm-downloads-2col {
        grid-template-columns: 1fr;
    }
}

/* ── Tabs ── */
.pm-detail-tabs {
    background: var(--pm-white);
    border-radius: var(--pm-radius);
    box-shadow: var(--pm-shadow);
    overflow: visible;
    margin-bottom: 2.5rem;
}

.pm-tab-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.25rem 0.5rem;
    padding: 0.35rem 0.75rem 0;
    border-bottom: 2px solid var(--pm-border);
    border-radius: var(--pm-radius) var(--pm-radius) 0 0;
    overflow: visible;
}

.pm-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    flex: 0 0 auto;
    padding: 0.7rem 0.85rem;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 6px 6px 0 0;
    margin-bottom: -2px;
    background: transparent;
    color: var(--pm-muted);
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.25;
    white-space: nowrap;
    cursor: pointer;
    transition:
        color 0.15s ease,
        background 0.15s ease,
        border-color 0.15s ease;
}

.pm-tab-btn i {
    margin-right: 0;
}

.pm-tab-btn:hover {
    color: var(--pm-blue);
    background: var(--pm-light);
}

.pm-tab-btn.active {
    color: var(--pm-blue);
    background: var(--pm-white);
    border-bottom-color: var(--pm-blue);
}

@media (max-width: 575.98px) {
    .pm-tab-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.35rem;
        padding: 0.5rem;
        border-bottom: none;
    }

    .pm-tab-btn {
        justify-content: flex-start;
        width: 100%;
        min-height: 42px;
        padding: 0.55rem 0.65rem;
        border: 1px solid var(--pm-border);
        border-radius: 6px;
        font-size: 0.78rem;
        text-align: left;
        white-space: normal;
    }

    .pm-tab-btn.active {
        border-color: var(--pm-blue);
        background: rgba(33, 83, 149, 0.08);
    }
}

.pm-tab-content {
    display: none;
    padding: 1.5rem;
}

/* active gesetzt durch Tab-JS */
.pm-tab-content.active {
    display: block;
}

.pm-description {
    font-size: var(--bs-catalog-body-font-size);
    line-height: 1.7;
    color: var(--pm-text);
}

.pm-no-data {
    color: var(--pm-muted);
    font-size: 0.9rem;
}

.pm-merkmale-grid,
.pm-data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 0.75rem;
}

.pm-merkmal,
.pm-data-item {
    background: var(--pm-light);
    border-radius: 6px;
    padding: 0.75rem;
}

.pm-data-item--full {
    grid-column: 1 / -1;
}

.pm-merkmal-label,
.pm-data-label {
    display: block;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--pm-muted);
    margin-bottom: 0.25rem;
}

.pm-merkmal-value,
.pm-data-value {
    font-size: 0.9rem;
    color: var(--pm-dark);
    font-weight: 500;
}

.pm-merkmal-list {
    margin: 0;
    padding-left: 1.1rem;
    font-size: 0.875rem;
    color: var(--pm-dark);
}

/* ── Verwandte Produkte (wie Listing-Cards) ── */
.pm-related {
    margin-bottom: 2.5rem;
}

.pm-related-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--pm-dark);
    margin-bottom: 1rem;
}

/* .pm-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
} */

.pm-related-card {
    background: var(--pm-white);
    border-radius: var(--pm-radius);
    box-shadow: var(--pm-shadow);
    overflow: hidden;
    text-decoration: none;
    transition: box-shadow var(--pm-transition), transform var(--pm-transition);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.pm-related-card:hover {
    box-shadow: var(--pm-shadow-hover, 0 6px 20px rgba(16, 39, 70, .13));
    transform: translateY(-2px);
}

.pm-related-image {
    position: relative;
    /* ← NEU: damit das absolute Badge relativ zum Bild sitzt */
    aspect-ratio: 4/3;
    background: var(--pm-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.pm-related-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 0.75rem;
    transition: transform 0.3s ease;
}

.pm-related-card:hover .pm-related-img {
    transform: scale(1.03);
}

.pm-related-no-image {
    color: var(--pm-border);
    font-size: 3rem;
}

/* Badge */
.pm-badge-verkaufbar-inline {
    position: absolute;
    top: 14px;
    left: 8px;
    z-index: 3;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    color: #fff;
    line-height: 1.3;
    letter-spacing: 0.02em;
    pointer-events: none;
}

/* Body */
.pm-related-body {
    padding: 0.75rem 1rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.pm-related-category {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--pm-dark);
    display: block;
    margin-bottom: 0.25rem;
}

.pm-related-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--pm-dark);
    margin: 0 0 0.4rem;
    line-height: 1.35;
}

.pm-related-desc {
    font-size: 0.825rem;
    color: var(--pm-muted);
    line-height: 1.45;
    flex: 1;
    margin-bottom: 0.75rem;
}

.pm-related-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--pm-border);
    padding-top: 0.6rem;
    margin-top: auto;
}

.pm-related-nr {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pm-text);
    font-variant-numeric: tabular-nums;
}

.pm-related-arrow {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--pm-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pm-dark);
    font-size: 0.8rem;
    transition: background var(--pm-transition), color var(--pm-transition);
}

.pm-related-card:hover .pm-related-arrow {
    background: var(--pm-dark);
    color: #fff;
}

/* ── Info-Icon / Tooltip ── */
.pm-info-icon {
    display: inline-flex;
    align-items: center;
    margin-left: 0.3rem;
    cursor: pointer;
    color: var(--pm-muted);
    position: relative;
    vertical-align: middle;
}

/* ── Tooltip wird per JS als eigenes Element am body eingefügt ── */
.pm-info-icon::after {
    display: none !important;
    /* CSS-Tooltip komplett deaktivieren */
}

/* ── JS-Tooltip-Element ── */
.pm-tooltip-popup {
    position: fixed;
    background: var(--pm-dark, #102746);
    color: #fff;
    font-size: 0.78rem;
    padding: 0.4rem 0.7rem;
    border-radius: 5px;
    white-space: pre-wrap;
    min-width: 260px;
    max-width: 500px;
    z-index: 99999;
    pointer-events: none;
    line-height: 1.4;
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .25);
}



/* Falls Tooltip am rechten Rand abgeschnitten wird: rechts ausrichten */
.pm-table td:last-child .pm-info-icon::after,
.pm-preise-tabelle td:last-child .pm-info-icon::after {
    left: auto;
    right: 0;
}

/* ── Video im Carousel ── */
.pm-video-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.pm-video-poster {
    position: relative;
    cursor: pointer;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pm-video-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    pointer-events: none;
}

.pm-video-poster:hover .pm-video-play-btn {
    background: rgba(220, 38, 38, 0.85);
    transform: translate(-50%, -50%) scale(1.1);
}

.pm-video-iframe-wrap {
    width: 100%;
    height: 100%;
}

.pm-video-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.pm-thumb-video-wrap {
    position: relative;
    width: 100%;
    height: 100%;
}

.pm-thumb-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.7rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

/* ── Kunden-Gruppen ── */
.pm-kunden-gruppe {
    margin-bottom: 0.75rem;
}

.pm-kunden-gruppe-header {
    display: block;
    font-size: 0.88rem;
    color: var(--pm-dark);
    margin-bottom: 0.25rem;
}

.pm-kunden-liste {
    margin: 0;
    padding-left: 1.5rem;
    list-style: none;
    font-size: var(--bs-catalog-body-font-size);
    color: var(--pm-text);
}

.pm-kunden-liste li::before {
    content: "–  ";
    color: var(--pm-muted);
}

.pm-komponenten-table {
    width: auto !important;
    /* min-width: 400px; */
}

.pm-komponenten-table tbody td,
.pm-komponenten-table thead th {
    text-align: left !important;
    vertical-align: top !important;
}

.pm-komponenten-table tbody tr[onclick]:hover {
    background-color: #f0f4f8;
    /* oder deine Hover-Farbe */
    cursor: pointer;
}

/*.pm-komponenten-table tbody td.pm-komponenten-icon-cell {
                                                text-align: center;
                                                vertical-align: top;
                                            } */

/* ── Verpackungseinheiten-Tabelle ── */
.pm-table-wrap {
    overflow-x: auto;
    overflow-y: visible;
    margin-bottom: 1.25rem;
}

.pm-table {
    /* width: 100%; */
    border-collapse: collapse;
    font-size: var(--bs-catalog-body-font-size);
    min-width: 400px;
}

.pm-table thead th,
.pm-table tbody th {
    background: var(--pm-light);
    color: var(--pm-muted);
    font-weight: 600;
    padding: 0.6rem 0.75rem;
    text-align: center;

    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--pm-border);
}

.pm-table thead th:first-child {
    text-align: left;
    border-radius: 6px 0 0 0;
}

.pm-table thead th:last-child {
    border-radius: 0 6px 0 0;
}

.pm-table tbody td {
    padding: 0.55rem 0.75rem;
    text-align: center;
    border-bottom: 1px solid var(--pm-border);
    color: var(--pm-dark);
}

.pm-table tbody tr:nth-child(even) {
    background: var(--pm-light);
}

.pm-table tbody tr:hover {
    background: rgba(33, 83, 149, .05);
}

.pm-label {
    text-align: left !important;
    font-weight: 600;
    color: var(--pm-muted);
    white-space: nowrap;
}

/* ── Preise Tab ── */
.pm-preise-header {
    margin-bottom: 1.5rem;
}

.pm-preise-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.pm-preise-row .pm-preise-cell:first-child {
    min-width: 180px;
}

.pm-preis-wert,
.pm-endpreis-wert {
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.pm-endpreis-wert {
    font-weight: 700;
    color: var(--pm-blue);
}

.pm-select {
    padding: 0.4rem 0.6rem;
    border: 1px solid var(--pm-border);
    border-radius: 6px;
    font-size: 0.875rem;
    background: var(--pm-white);
}

.pm-input-number {
    width: 5rem;
    padding: 0.4rem 0.6rem;
    border: 1px solid var(--pm-border);
    border-radius: 6px;
    font-size: 0.875rem;
    text-align: right;
}

.pm-preise-table-wrap {
    overflow-x: auto;
    overflow-y: visible;
    margin-bottom: 1.25rem;
}

.pm-preise-tabelle {
    /* width: 100%; */
    border-collapse: collapse;
    font-size: var(--bs-catalog-body-font-size);
    min-width: 400px;
}

.pm-preise-tabelle thead th {
    background: var(--pm-bluelighter);
    color: var(--pm-blue, #1e40af);
    font-weight: 700;
    padding: 0.6rem 0.75rem;
    text-align: center;
    font-size: var(--bs-catalog-body-font-size);

    letter-spacing: 0.05em;
}

.pm-preise-tabelle thead th:first-child {
    text-align: left;
    border-radius: 6px 0 0 0;
}

.pm-preise-tabelle thead th:last-child {
    border-radius: 0 6px 0 0;
}

.pm-preise-tabelle tbody td {
    padding: 0.55rem 0.75rem;
    text-align: center;
    border-bottom: 1px solid var(--pm-border);
    color: var(--pm-dark);
}

.pm-preise-tabelle tbody tr:nth-child(even) {
    background: var(--pm-light);
}

.pm-preise-tabelle tbody tr:hover {
    background: rgba(33, 83, 149, .05);
}

.pm-preise-tabelle tbody td:first-child {
    text-align: left;
    font-weight: 600;
    color: var(--pm-muted);
    white-space: nowrap;
}

/* ── Link-Stil in Status-Tab ── */
.pm-link {
    color: var(--pm-blue);
    text-decoration: none;
    font-size: 0.9rem;
}

.pm-link:hover {
    text-decoration: underline;
}

/* ── Katalog-Tabelle ── */
.pm-katalog-table tbody td {
    text-align: left;
    vertical-align: top;
}

/* Ist Veröffentlicht / Sichtbar für alle: oben-zentriert */
.pm-katalog-table tbody td.pm-katalog-icon-cell {
    text-align: center;
    vertical-align: top;
}

/* Datumsspalten breiter, kein Umbruch */
.pm-katalog-table tbody td.pm-katalog-date-cell,
.pm-katalog-table thead th.pm-katalog-date-col {
    white-space: nowrap;
    min-width: 150px;
}

/* ── Vorgänger/Nachfolger ── */
.pm-related-compare {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* immer 2 Spalten */
    gap: 1.5rem;
    align-items: start;
}

.pm-related-col {
    min-width: 0;
    /* verhindert Überlaufen bei Grid */
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.pm-related-col--right {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    /* Kinder rechtsbündig */
}

/* Überschrift in der rechten Spalte: Text rechtsbündig */
.pm-related-col--right .pm-section-subtitle {
    text-align: right;
    width: 100%;
}

/* Grid in der rechten Spalte: keine auto-fill Ausdehnung */
.pm-related-col--right .pm-related-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 1.25rem;
}

/* Karten in der rechten Spalte: feste Breite statt 1fr */
.pm-related-col--right .pm-related-card {
    width: 240px;
    max-width: 100%;
}

/* optional: auf kleinen Screens 1 Spalte */
@media (max-width: 900px) {
    .pm-related-compare {
        grid-template-columns: 1fr;
    }
}

/* ── Regulatorische Daten: Sektionen ── */
.pm-ra-section {
    /* margin-bottom: 2rem; */
    /* border: 1px solid var(--pm-border, #e5e7eb);
    border-radius: 8px; */
    overflow: hidden;
}

.pm-ra-section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--bs-catalog-body-font-size);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--pm-blue, #1e40af);
    background: var(--pm-bluelighter);
    padding: 0.65rem 1rem;
    margin: 0;
    border-bottom: 1px solid var(--pm-border, #e5e7eb);
}

.pm-ra-section .pm-data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0;
}

.pm-ra-section .pm-data-item {
    padding: 0.6rem 1rem;
    border-bottom: 1px solid var(--pm-border, #f3f4f6);
    border-right: 1px solid var(--pm-border, #f3f4f6);
}

.pm-ra-section .pm-data-label {
    font-size: 0.65rem;
    font-weight: 550;
    color: var(--pm-muted, #6b7280);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    display: block;
    margin-bottom: 0.15rem;
}

.pm-ra-section .pm-data-value {
    font-size: 0.9rem;
    color: var(--pm-dark, #111827);
}

.pm-data-value--mono {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    background: #f3f4f6;
    padding: 0.1rem 0.3rem;
    border-radius: 3px;
}

.pm-ra-section .pm-description {
    padding: 0.75rem 1rem;
}

/* ── Bild-Download-Buttons ── */
.pm-img-download-btns {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    align-self: flex-start;
}

.pm-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.65rem;
    border-radius: 4px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    width: fit-content;
}

.pm-btn--original {
    background: var(--pm-blue, #1e40af);
    color: #fff;
}

.pm-btn--original:hover {
    background: var(--pm-dark, #111827);
    color: #fff;
}

.pm-btn--web {
    background: var(--pm-accent, #1e40af);
    color: #fff;
}

.pm-btn--web:hover {
    background: var(--pm-dark, #111827);
    color: #fff;
}

.pm-view-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border: none;
    background: var(--pm-white);
    color: var(--pm-muted);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    font-size: 1.4rem;
}

.pm-view-btn:hover {
    background: var(--pm-dark, #111827);
    color: #fff;
}


/* Keep listing content visible if JavaScript is disabled. */
.pm-main-content {
    opacity: 1 !important;
}

/* ================================================================
   Carousel: Aehnliche Produkte
   ================================================================ */

.pm-related-carousel {
    position: relative;
    width: 100%;
}

.pm-related-viewport {
    overflow: hidden;
    width: 100%;
}

.pm-related-track {
    display: flex;
    gap: 1.25rem;
    overflow-x: auto;
    padding: 0.25rem 0.2rem 0.75rem;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.pm-related-track::-webkit-scrollbar {
    display: none;
}

.pm-related-slide {
    display: flex;
    flex: 0 0 calc((100% - 2.5rem) / 3);
    min-width: 0;
    scroll-snap-align: start;
}

.pm-related-slide .pm-related-card {
    width: 100%;
}

.pm-related-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;

    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;

    appearance: none;
    border: 1px solid var(--pm-border, #d9e0e8);
    border-radius: 50%;
    background: var(--pm-white, #fff);
    color: var(--pm-blue, #215395);
    box-shadow: 0 2px 8px rgba(16, 39, 70, 0.18);

    font: inherit;
    font-size: 0.9rem;
    line-height: 1;
    cursor: pointer;

    opacity: 0;
    pointer-events: none;
    transition:
        opacity 0.2s ease,
        background 0.2s ease,
        color 0.2s ease,
        box-shadow 0.2s ease;
}

/* Das hidden-Attribut aus JavaScript muss immer Vorrang haben. */
.pm-related-carousel-btn[hidden] {
    display: none !important;
}

.pm-related-carousel:hover .pm-related-carousel-btn:not([hidden]),
.pm-related-carousel:focus-within .pm-related-carousel-btn:not([hidden]) {
    opacity: 1;
    pointer-events: auto;
}

.pm-related-carousel-btn:hover:not(:disabled) {
    background: var(--pm-blue);
    color: #fff;
}

.pm-related-carousel-btn:disabled {
    opacity: 0.35;
    cursor: default;
}

.pm-related-carousel-prev {
    left: -19px;
}

.pm-related-carousel-next {
    right: -19px;
}

.pm-related-carousel-btn:focus-visible {
    outline: 3px solid rgba(33, 83, 149, 0.35);
    outline-offset: 2px;
}

@media (max-width: 991.98px) {
    .pm-related-slide {
        flex-basis: calc((100% - 1.25rem) / 2);
    }
}

@media (max-width: 575.98px) {
    .pm-related-slide {
        flex-basis: 100%;
    }

    .pm-related-carousel-prev {
        left: 6px;
    }

    .pm-related-carousel-next {
        right: 6px;
    }

    .pm-related-carousel-btn {
        width: 34px;
        height: 34px;
    }

    .pm-related-track {
        padding-left: 0;
        padding-right: 0;
    }
}

@media (hover: none) {
    .pm-related-carousel-btn:not([hidden]) {
        opacity: 1;
        pointer-events: auto;
    }
}

/* Filter-Container auf kleinen Bildschirmen vollständig wachsen lassen */
@media screen and (max-width: 767.98px) {
    .pm-filter-bar-body.open {
        max-height: 2500px;
        overflow: visible;
    }
}

@media screen and (max-width: 575.98px) {
    .pm-filter-bar-body.open {
        max-height: 2500px;
    }

    .pm-filter-dd-row {
        flex-direction: column;
        gap: 0.5rem;
    }

    .pm-filter-dd,
    .pm-filter-dd-btn {
        width: 100%;
    }

    .pm-filter-dd-btn {
        justify-content: space-between;
    }
}