/* UP Catalog - Product Widgets Styles */
/* Product Search, Product Grid, Single Product, Product Properties */

/* Product Search - Nur Layout */
.up-catalog-search-wrapper {
    display: block;
}

.up-catalog-search-form {
    display: block;
}

.up-catalog-search-fields {
    display: flex;
}

.up-catalog-search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    position: relative;
}

.up-catalog-search-input-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.up-catalog-search-input {
    flex: 1;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.up-catalog-search-input:focus {
    outline: none;
}

.up-catalog-search-button {
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.up-catalog-search-results {
    display: block;
}

.up-catalog-search-info {
    display: block;
}

.up-catalog-search-info p {
    margin: 0;
}

.up-catalog-no-results {
    text-align: center;
}


/* Product Grid - Nur Layout */
.up-catalog-grid {
    display: grid;
}

.up-catalog-product {
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.up-catalog-product-image {
    width: 100%;
    text-align: center;
    overflow: hidden;
}

.up-catalog-product-image img {
    max-width: 100%;
    height: auto;
    display: block;
}

.up-catalog-product-image-link {
    display: block;
    text-decoration: none;
}

.up-catalog-product-title {
    margin: 0;
}

.up-catalog-product-title-link {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

.up-catalog-product-title-link:hover {
    text-decoration: none;
}

.up-catalog-product-manufacturer-sku,
.up-catalog-product-puid,
.up-catalog-product-sku {
    margin-top: 0.25rem;
    opacity: 0.7;
}

.up-catalog-product-manufacturer-sku small,
.up-catalog-product-puid small,
.up-catalog-product-sku small {
    font-size: 0.875em;
}

.up-catalog-product-description {
    flex-grow: 1;
}

.up-catalog-product-bullet-points {
    list-style: disc;
    padding-left: 1.5em;
    margin: 0.5rem 0;
}

.up-catalog-product-bullet-points li {
    margin-bottom: 0.25rem;
}

.up-catalog-product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-top: auto;
}

/* Pagination */
.up-catalog-pagination {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.up-catalog-pagination a,
.up-catalog-pagination span {
    display: inline-block;
    text-decoration: none;
    transition: all 0.3s ease;
}

.up-catalog-pagination a:hover {
    opacity: 0.8;
}

.up-catalog-pagination-current {
    font-weight: bold;
}

.up-catalog-pagination-dots {
    pointer-events: none;
}

.up-catalog-btn-view {
    display: inline-block;
    text-decoration: none;
    transition: all 0.2s;
}

.up-catalog-btn-view:hover {
    text-decoration: none;
}


/* Single Product - Nur Layout */
.up-catalog-single-product {
    display: block;
}

.up-catalog-product-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
}

@media (max-width: 768px) {
    .up-catalog-product-content {
        grid-template-columns: 1fr;
    }
}

.up-catalog-single-product .up-catalog-product-image {
    width: 100%;
    overflow: hidden;
}

.up-catalog-single-product .up-catalog-product-image img {
    width: 100%;
    height: auto;
    display: block;
}

.up-catalog-product-details {
    display: flex;
    flex-direction: column;
}

.up-catalog-product-actions {
    display: flex;
    flex-wrap: wrap;
}

.up-catalog-btn-cta {
    display: inline-block;
    text-decoration: none;
    transition: all 0.2s;
}

.up-catalog-btn-cta:hover {
    text-decoration: none;
}


/* Product Properties - Nur Layout */
.up-catalog-properties-wrapper {
    display: block;
}

/*
 * KORREKTUR: Masonry-artig mit unterschiedlichen Höhen via CSS Columns.
 * Hinweis: Die Reihenfolge fließt spaltenweise (oben->unten), nicht zeilenweise wie CSS Grid.
 */
.up-catalog-properties-wrapper.layout-grid {
    display: block;         /* wichtig: nicht grid */
    column-count: 2;        /* Fallback; wird per Elementor überschrieben */
    column-gap: 20px;       /* Fallback; wird per Elementor überschrieben */
    /* KEIN grid-auto-rows / align-items nötig */
}

/* Property Group Card */
.up-catalog-properties-group {
    display: block;
    height: auto;
    /* Alle visuellen Styles über Elementor */
}

/* Für Columns: Cards müssen inline-block sein und dürfen nicht umbrechen */
.up-catalog-properties-wrapper.layout-grid .up-catalog-properties-group {
    display: inline-block;      /* wichtig für Columns */
    width: 100%;
    break-inside: avoid;
    page-break-inside: avoid;
    /* margin-bottom wird per Elementor Selector gesetzt (grid_gap) */
}

/* Stacked Layout */
.up-catalog-properties-wrapper.layout-stacked {
    display: block;
}

/* Section Header */
.up-catalog-properties-section-header {
    display: block;
    /* Alle visuellen Styles über Elementor */
}

/* Table */
.up-catalog-properties-table {
    width: 100%;
    border-collapse: collapse;
}

.up-catalog-properties-table td {
    vertical-align: top;
}

/* HTML Fallback */
.up-catalog-properties-html {
    display: block;
}

/* No Properties Message */
.up-catalog-no-properties {
    text-align: center;
}