/* Format Objekte Styles */

.format-objekte-single {
    margin: 0 auto;
}

.single-format_objekte aside {
    display: none !important;
}

.single-format_objekte main > .uk-container {
    max-width: 1360px;
}

.format-objekte-single .entry-header {
    display: block;
}

.format-objekte-main-row {
    display: flex;
    gap: 3rem;
}

.format-objekte-main-info {
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    flex-direction: column;
}

h1.format-objekte-main-info-title {
    margin: 0;
}

.format-objekte-main-info p {
    margin: 0;
}

.format-objekte-main-row > * {
    flex-basis: 50%
        
}

.format-objekte-detailzeichnung {
    margin-top: 2rem;
}

.format-objekte-detailzeichnung img {
    max-width: 600px;
}

span.format-objekte-variant-selector-item-label {
    font-weight: bold;
}

/* Details Table */

.format-objekte-details-table table {
    table-layout: auto;
    border-collapse: collapse;
    width: 100%;
}

.search picture img {
    max-height: 11rem;
    object-fit: contain;
    margin: auto;
}

/* .format-objekte-details-table table tr td:first-child {
    font-weight: bold;
} */

.format-objekte-table-footer {
    margin-top: 2rem;
}

.variant-selector {
    border: 1px solid black;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    padding: .5rem 1rem;
    width: fit-content;
    min-width: 100%;
}

.format-objekte-variant-selector-item {
    display: flex;
    flex-direction: column;
    /* flex-basis: 33.3%; */
    flex-basis: calc(100% / var(--cols) - var(--gap) / var(--cols) * (var(--cols) - 1));
}

.format-objekte-variant-selector {
    display: flex;
    gap: 0rem;
    width: 100%;
    margin-top: 2rem;
    flex-wrap: wrap;
    --cols: 3;
    --gap: 1rem;
    gap: var(--gap);
}

.format-objekte-main-info-content {
    width: 100%;
    margin-top: .5rem;
}

.format-objekte-details-table table tr {
    border-bottom: 1px solid #eaeaea;
}

.format-objekte-details-table table tr.current-article {
    background-color: lightgray;
}

.format-objekte-details-table table tr.current-article:hover {
    background-color: lightgray;
}

.format-objekte-details-table table tr:last-child {
    border-bottom: none;
}

.format-objekte-details-table table td {
    padding: 1rem;
}

.format-objekte-details-table table th {
    padding: 1rem;
    text-align: left;
}

.format-objekte-details-table table tr:hover {
    background-color: aliceblue;
}

/* Images */

.format-objekte-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.image-wrapper img {
    width: 100%;
    height: auto;
    max-height: 28rem;
    min-height: 28rem;
    object-fit: contain;
}

.format-objekte-details {
    display: grid;
    gap: 2rem;
}

.basic-info,
.group-info,
.description,
.produkteigenschaften {
    background: #f5f5f5;
    padding: 1.5rem;
    border-radius: 4px;
}

.format-objekte-details h3 {
    margin-top: 0;
    margin-bottom: 1rem;
}

.format-objekte-details p {
    margin: 0.5rem 0;
} 

/* Kategorie */

.format-objekte-kategorie {
    margin: 0 0 1rem;
    font-size: 1rem;
    margin-bottom: 6rem;
}

.category-item + .category-separator {
    margin: 0 0.5rem;
}


.category-item:last-of-type {
    font-weight: bold;
}

@media (max-width: 950px) {
    
    .format-objekte-main-row {
        gap: 1rem;
        flex-direction: column;
        margin-bottom: 2rem;
    }
    
    .format-objekte-kategorie {
        margin-bottom: 2rem;
    }
}



ul.format-objekte-variants-list {
    margin: 0;
}

.pdf-download {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.pdf-download:hover {
    opacity: 0.8;
}

.pdf-download.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

a.pdf-download {
    position: relative;
}


a.pdf-download.loading .spinner-container {
    display: block !important;
}

.wishlist-button,
.wishlist-remove-button {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.wishlist-button:hover,
.wishlist-remove-button:hover {
    opacity: 0.8;
}

.format-objekte-action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.wishlist-button.on-wishlist {
    background-color: #595959;
    border-color: #000000;
}

.wishlist-remove-button.confirm-remove {
    background-color: #ffebee;
    border-color: #ef9a9a;
    color: #c62828;
}

.wishlist-remove-button.confirm-remove:hover {
    background-color: #ffcdd2;
}

.spinner-container {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 4px;
}

.spinner {
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-left-color: #000;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    animation: button-loading-spinner 1s linear infinite;
}

@keyframes button-loading-spinner {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 850px) {
    .format-objekte-details-table table thead,
    .format-objekte-details-table table th {
      display: none;
    }
    
    .format-objekte-details-table table tr {
      display: block;
      margin-bottom: 1.5rem;
      box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
      border-radius: 4px;
      background-color: #ffffff;
    }
    
    .format-objekte-details-table table tr.current-article {
      border-left: 4px solid #808080;
      background-color: #f5f5f5;
    }
    
    .format-objekte-details-table table td {
      display: flex;
      padding: 0.75rem 1rem;
      border-bottom: 1px solid #eee;
      align-items: center;
    }
    
    .format-objekte-details-table table td:last-child {
      border-bottom: none;
    }
    
    .format-objekte-details-table table td:before {
      content: attr(data-label);
      font-weight: bold;
      width: 40%;
      margin-right: 5%;
      flex-shrink: 0;
    }
    
    .format-objekte-details-table table td > * {
      width: 55%;
    }
    
    .format-objekte-details-table table td:nth-child(2) {
      font-weight: bold;
    }
    
    .format-objekte-details-table table tr[onclick] {
      cursor: pointer;
      transition: transform 0.2s;
    }
    
    .format-objekte-details-table table tr[onclick]:hover,
    .format-objekte-details-table table tr[onclick]:active {
      transform: translateY(-2px);
      box-shadow: 0 4px 6px rgba(0,0,0,0.15), 0 2px 4px rgba(0,0,0,0.12);
    }
  }

/* Wishlist Styles */
.format-objekte-wishlist {
    width: 100%;
    margin-top: 30px;
    border-collapse: collapse;
}

.format-objekte-wishlist tr {
    border-bottom: 1px solid #e0e0e0;
}

.format-objekte-wishlist td {
    padding: 20px;
    vertical-align: top;
}

.format-objekte-wishlist td:first-child {
    width: 200px;
}

.format-objekte-wishlist img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.wishlist-title h2 {
    margin-top: 0;
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.wishlist-description {
    color: #616161;
    margin-bottom: 10px;
}

.wishlist-article-number {
    font-size: 0.9rem;
    color: #757575;
    margin-bottom: 15px;
}

.wishlist-actions {
    display: flex;
    gap: 15px;
}

.wishlist-remove-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    background-color: #f8f8f8;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.wishlist-remove-button:hover {
    background-color: #fee;
    border-color: #fcc;
}

.wishlist-remove-button.confirm-remove {
    background-color: #fee;
    border-color: #fcc;
    color: #d00;
}

/* Notification styling */
.wishlist-notification {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.wishlist-notification-hidden {
    display: none;
}

.wishlist-notification-content {
    background-color: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.wishlist-notification-header {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
}

.wishlist-notification-body {
    margin-bottom: 20px;
    line-height: 1.5;
}

.wishlist-notification-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Notification Buttons */
.wishlist-notification-btn {
    font-size: 14px;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    background-color: #1e87f0;
    color: white;
    border: none;
    transition: background-color 0.3s ease;
    text-decoration: none;
}

.wishlist-notification-btn:hover {
    background-color: #0f7ae5;
    color: white;
    text-decoration: none;
}


/* Responsive  */
@media (max-width: 768px) {
    .format-objekte-wishlist td {
        display: block;
        width: 100%;
    }
    
    .format-objekte-wishlist td:first-child {
        width: 100%;
        text-align: center;
    }
    
    .wishlist-actions {
        flex-direction: column;
    }

    .format-objekte-variant-selector {
        --cols: 2;
    }
}

@media (max-width: 500px) {
    .format-objekte-variant-selector {
        --cols: 1;
    }
}

/* Wishlist PDF Button */
.wishlist-pdf-container {
    margin-top: 30px;
    text-align: right;
}

#download-wishlist-pdf {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    font-size: 14px;
    transition: all 0.3s ease;
}

#download-wishlist-pdf:hover {
    opacity: 0.9;
}

/* Gallery Styles */
.gallery-container {
    max-width: 100%;
    margin: 0 auto;
}

.gallery-main {
    position: relative;
    margin-bottom: 20px;
}

.gallery-slide {
    display: none;
}

.gallery-slide.active {
    display: block;
}

.gallery-slide img {
    width: 100%;
    height: auto;
    display: block;
    max-height: 28rem;
    min-height: 28rem;
    object-fit: contain;
}

.gallery-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.gallery-thumbs {
    display: flex;
    gap: 10px;
    justify-content: center;
    max-width: 80%;
    overflow: hidden;
}

.gallery-thumbs .thumb {
    width: 80px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.gallery-thumbs .thumb.active {
    opacity: 1;
}


.gallery-thumbs .thumb img {
    width: 100%;
    height: auto;
    display: block;
    max-height: 6rem;
    object-fit: contain;
}

.gallery-arrow {
    background: #f0f0f0;
    border: none;
    padding: 0px 10px !important;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.gallery-arrow:hover {
    background: #e0e0e0;
}

select.variant-selector.single-option {
    pointer-events: none; 
    background: none; 
    border: none; 
    padding: 0; 
    -webkit-appearance: none; 
    -moz-appearance: none;
    appearance: none;
    cursor: default; 
    color: inherit; 
    font: inherit; 
    width: auto; 
    margin: 0; 
}

select.variant-selector.single-option::-ms-expand {
    display: none;
}

.format-objekte-variant-selector-item select.variant-selector.single-option {
    display: inline-block;
    vertical-align: baseline;
}

.format-objekte-kategorie .category-link {
    color: #000118;
    text-decoration: none;
    transition: color 0.3s ease;
}

.format-objekte-kategorie .category-link:hover {
    color: #005a87;
    text-decoration: underline;
}

.format-objekte-kategorie .category-item {
    padding: 2px 4px;
}

.format-objekte-kategorie .category-separator {
    color: #666;
    margin: 0 5px;
    font-weight: normal;
}

/* No Image Placeholder */
.format-objekte-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 280px;
    background-color: #f5f5f5;
    color: #666;
    font-size: 14px;
    text-align: center;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
}

.format-objekte-no-image span {
    padding: 10px;
}

/* No Results Message */
.format-objekte-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-size: 16px;
}

.format-objekte-no-results p {
    margin: 0;
}