/**
 * Laravel Product Integration Styles - Zonenscherm.nl Style
 */

/* Container */
.laravel-products-container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0;
    background: #fff;
}

/* Back Navigation */
.product-back-navigation {
    margin-bottom: 25px;
}

.back-to-category {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #007ac2;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95em;
    padding: 10px 15px;
    border: 2px solid #007ac2;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.back-to-category:hover {
    background: #007ac2;
    color: #fff;
    text-decoration: none;
    transform: translateX(-4px);
}

/* Category Overview */
.category-overview .category-title {
    display: none;
}

.category-overview .category-description {
    display: none;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.product-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
}

.product-card-image {
    width: 100%;
    overflow: hidden;
    background: #f8f9fa;
    min-height: 250px;
    max-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    max-height: 250px;
    min-height: 250px;
}

/* Placeholder when no image is available */
.product-card-image--placeholder {
    background: #f0f2f4;
}

.product-card-placeholder-icon {
    font-size: 52px !important;
    width: 52px !important;
    height: 52px !important;
    color: #c8cdd2 !important;
}

.product-card:hover .product-card-image img {
    transform: scale(1.05);
}

.product-card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-card-type {
    display: inline-block;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #76b82a;
    margin-bottom: 6px;
}

.laravel-products-container .product-card-content .product-card-title {
    font-size: 1.3em;
    color: #007ac2;
    margin: 0 0 10px;
    font-weight: 600;
    min-height: 85px;
    max-height: 85px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.product-card-subtitle {
    font-size: 0.95em;
    color: #666;
    margin: 0 0 12px;
    font-style: italic;
    min-height: 55px;
    max-height: 55px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.laravel-products-container .product-card-content .product-card-specs {
    list-style: none;
    margin: 0 0 14px;
    padding: 0;
    flex-grow: 1;
    font-size: 0.88em;
    color: #444;
}

.laravel-products-container .product-card-content .product-card-specs li {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 5px;
    line-height: 1.3;
}

.laravel-products-container .product-card-content .product-card-specs .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #007ac2;
}

.laravel-products-container .product-card-content .product-card-specs .spec-feature .dashicons {
    color: #76b82a;
}

.laravel-products-container .product-card-content .product-card-price {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 1em;
    font-weight: 700;
    color: #007ac2;
    margin-bottom: 12px;
}

.laravel-products-container .product-card-content .product-card-price .price-label {
    font-weight: 400;
    font-size: 0.85em;
    color: #666;
    margin-bottom: 0;
}

.laravel-products-container .product-card-content .product-card-price .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

.product-card-link {
    position: absolute;
    inset: 0;
    z-index: 1;
    font-size: 0;
    color: transparent;
}

/* Visual button rendered via pseudo-element */
.product-card-content::after {
    content: 'Bekijk details →';
    display: inline-block;
    margin-top: auto;
    padding: 10px 20px;
    background: #007ac2;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    border-radius: 4px;
    transition: background 0.2s ease;
    align-self: flex-start;
}

.product-card:hover .product-card-content::after {
    background: #005f99;
}

/* Product Item */
.product-item {
    background: #fff;
    overflow: visible;
}

.product-inner {
    display: grid;
    gap: 50px;
    align-items: start;
}

.product-inner.two-column-layout {
    grid-template-columns: 1fr 1fr;
}

.product-column-left {
    display: flex;
    flex-direction: column;
}

.product-column-right {
    display: flex;
    flex-direction: column;
}

/* === IMAGE SLIDER SECTION === */
.product-images {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #fff;
}

/* Main Image Slider */
.product-image-main {
    position: relative;
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: #f5f5f5;
    margin-bottom: 15px;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.product-image-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: opacity 0.15s ease;
}

.product-image-main img.loading {
    opacity: 0.5;
}

/* Slider Navigation Arrows */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 122, 194, 0.95);
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #fff;
    transition: all 0.3s ease;
    z-index: 10;
    font-weight: 300;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.slider-nav:hover {
    background: #005a8c;
    transform: translateY(-50%) scale(1.1);
}

.slider-nav.prev {
    left: 10px;
}

.slider-nav.next {
    right: 10px;
}

/* Hide arrows if only one image */
.product-images[data-image-count="1"] .slider-nav {
    display: none;
}

/* Thumbnail Gallery */
.product-image-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 15px;
}

/* Image Caption */
.product-image-caption {
    margin-top: 0;
    padding: 15px 18px;
    background: #f8f9fa;
    border-left: 4px solid #007ac2;
    font-size: 0.95em;
    color: #555;
    line-height: 1.6;
    border-radius: 0 4px 4px 0;
}

.product-image-caption p {
    margin: 0;
}

.gallery-thumb {
    position: relative;
    aspect-ratio: 4/3;
    border: 2px solid #ddd;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.25s ease;
    background: #f5f5f5;
    border-radius: 4px;
}

.gallery-thumb:hover {
    border-color: #007ac2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 194, 0.2);
}

.gallery-thumb.active {
    border-color: #007ac2;
    border-width: 3px;
    box-shadow: 0 2px 8px rgba(0, 122, 194, 0.25);
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    padding: 4px;
}

/* === CONTENT SECTION === */
.product-content {
    padding: 0;
    display: flex;
    flex-direction: column;
}

/* Typography */
.product-title {
    margin: 0 0 12px 0;
    font-size: 2em;
    font-weight: 600;
    color: #007ac2;
    line-height: 1.2;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.product-subtitle {
    margin: 0 0 20px 0;
    font-size: 1.05em;
    color: #666;
    font-weight: 400;
    line-height: 1.5;
    font-style: italic;
}

.product-seo-description {
    margin: 0 0 25px 0;
    padding: 0;
    background: transparent;
    border: none;
    font-size: 0.95em;
    color: #444;
    line-height: 1.7;
}

/* Specifications Box */
.product-specifications {
    background: #007ac2;
    color: #fff;
    padding: 22px 28px;
    margin: 0 0 30px 0;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 122, 194, 0.15);
}

.product-specifications h3 {
    margin: 0 0 15px 0;
    font-size: 1.25em;
    font-weight: 600;
    color: #fff;
}

.product-specifications ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-specifications li {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: flex-start;
    font-size: 0.95em;
    line-height: 1.5;
}

.product-specifications li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.product-specifications li::before {
    content: "✓";
    margin-right: 12px;
    font-weight: bold;
    color: #fff;
    flex-shrink: 0;
}

/* Content Sections */
.product-description,
.product-attributes,
.product-advantages,
.product-disadvantages {
    margin: 0 0 30px 0;
    padding: 0;
    border: none;
}

.product-description h2,
.product-description h3 {
    font-size: 1.5em;
    margin: 0 0 15px 0;
    color: #007ac2;
    font-weight: 600;
}

.product-attributes h3,
.product-advantages h3,
.product-disadvantages h3 {
    font-size: 1.35em;
    margin: 0 0 12px 0;
    color: #333;
    font-weight: 600;
}

.description-content,
.attributes-content,
.advantages-content,
.disadvantages-content {
    font-size: 0.95em;
    color: #444;
    line-height: 1.8;
}

.description-content p {
    margin: 0 0 15px 0;
}

.description-content ul,
.description-content ol {
    margin: 0 0 15px 20px;
    padding-left: 20px;
}

.description-content li {
    margin-bottom: 10px;
}

/* List styling for advantages/disadvantages */

/* Product Price */
.product-price-block {
    margin: 0;
    padding: 25px 30px;
    background: #f8f9fa;
    border-left: 4px solid #007ac2;
    border-radius: 4px;
}

.price-label {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.product-price {
    font-size: 2.5em;
    font-weight: 700;
    color: #007ac2;
    margin: 0;
}

/* Call to Action */
.product-actions {
    margin-top: 0;
    padding-top: 0;
}

.product-link {
    display: inline-block;
    padding: 16px 40px;
    background: #76b82a;
    color: #fff !important;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 1em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(118, 184, 42, 0.2);
}

.product-link:hover {
    background: #5f9621;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(118, 184, 42, 0.35);
}

/* Error Messages */
.laravel-products-error {
    padding: 20px 25px;
    background: #fee;
    border-left: 4px solid #e74c3c;
    color: #c33;
    margin: 20px 0;
    font-size: 1em;
}

/* Image fade transition */
.product-image-main img {
    transition: opacity 0.25s ease;
}

/* === RESPONSIVE DESIGN === */

/* Tablet & Mobile */
@media (max-width: 768px) {
    .product-inner.two-column-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .product-column-right {
        order: -1;
    }

    .products-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .category-overview .category-title {
        font-size: 2em;
    }

    .laravel-products-container {
        margin: 20px auto;
        padding: 0;
    }

    .product-title {
        font-size: 1.75em;
    }

    .product-subtitle {
        font-size: 1em;
    }

    .product-image-gallery {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }

    .slider-nav {
        width: 38px;
        height: 38px;
        font-size: 20px;
    }

    .slider-nav.prev {
        left: 5px;
    }

    .slider-nav.next {
        right: 5px;
    }

    .product-price {
        font-size: 2em;
    }

    .product-specifications {
        padding: 18px 22px;
    }

    .product-link {
        display: block;
        text-align: center;
        padding: 14px 30px;
        font-size: 0.95em;
    }

    .back-to-category {
        font-size: 0.9em;
        padding: 8px 12px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .product-title {
        font-size: 1.5em;
    }

    .product-image-gallery {
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
    }

    .product-specifications {
        padding: 15px 18px;
    }

    .product-specifications h3 {
        font-size: 1.1em;
    }

    .product-price-block {
        padding: 20px;
    }

    .product-price {
        font-size: 1.8em;
    }

    .slider-nav {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
}

/* Showcase / Featured Product */
.zonscherm-product-showcase {
    margin: 20px 0;
}

.zonscherm-product-showcase .showcase-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.zonscherm-product-showcase .showcase-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.zonscherm-product-showcase .showcase-image {
    width: 100%;
    overflow: hidden;
    background: #f5f5f5;
}

.zonscherm-product-showcase .showcase-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.zonscherm-product-showcase .showcase-card:hover .showcase-image img {
    transform: scale(1.05);
}

.zonscherm-product-showcase .showcase-image a {
    display: block;
    text-decoration: none;
}

.zonscherm-product-showcase .showcase-content {
    padding: 20px;
}

.zonscherm-product-showcase .showcase-title {
    margin: 0 0 10px 0;
    font-size: 1.5em;
    font-weight: 600;
    color: #333;
}

.zonscherm-product-showcase .showcase-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.zonscherm-product-showcase .showcase-title a:hover {
    color: #007ac2;
}

.zonscherm-product-showcase .showcase-subtitle {
    margin: 0 0 12px 0;
    font-size: 0.95em;
    color: #666;
    font-style: italic;
}

.zonscherm-product-showcase .showcase-description {
    margin: 15px 0;
    font-size: 0.95em;
    color: #555;
    line-height: 1.6;
}

.zonscherm-product-showcase .showcase-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 15px 0;
    font-size: 1em;
    color: #666;
}

.zonscherm-product-showcase .price-label {
    font-weight: 600;
    color: #555;
}

.zonscherm-product-showcase .price-amount {
    font-size: 1.4em;
    font-weight: 700;
    color: #007ac2;
}

.zonscherm-product-showcase .showcase-actions {
    margin-top: 20px;
}

.zonscherm-product-showcase .showcase-button {
    display: inline-block;
    padding: 12px 24px;
    background: #007ac2;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: background 0.3s ease, transform 0.2s ease;
    border: 2px solid #007ac2;
    cursor: pointer;
}

.zonscherm-product-showcase .showcase-button:hover {
    background: #005fa3;
    border-color: #005fa3;
    text-decoration: none;
    transform: translateY(-2px);
}

/* Responsive Showcase */
@media (max-width: 600px) {
    .zonscherm-product-showcase .showcase-content {
        padding: 15px;
    }

    .zonscherm-product-showcase .showcase-title {
        font-size: 1.2em;
    }

    .zonscherm-product-showcase .price-amount {
        font-size: 1.2em;
    }

    .zonscherm-product-showcase .showcase-button {
        width: 100%;
        text-align: center;
    }
}


/* === Category card: type label, specs list, price block === */

/* Category label above card title */
.laravel-products-container .product-card-content .product-card-type {
    display: inline-block;
    font-size: 0.72em;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #007ac2;
    margin-bottom: 6px;
}

/* Product card title — high-specificity to beat Elementor (0,3,0) */
.laravel-products-container .product-card-content .product-card-title {
    font-size: 1.3em;
    color: #1a1a1a;
    margin: 0 0 6px;
    font-weight: 700;
    line-height: 1.25;
    min-height: 85px;
    max-height: 85px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* Specs list */
.laravel-products-container .product-card-content .product-card-specs {
    list-style: none;
    margin: 10px 0 14px;
    padding: 0;
    flex-grow: 1;
}

.laravel-products-container .product-card-content .product-card-specs .product-card-spec-row {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 0.88em;
    color: #444;
    padding: 4px 0;
    border-bottom: 1px solid #f0f0f0;
}

.laravel-products-container .product-card-content .product-card-specs .product-card-spec-row:last-child {
    border-bottom: none;
}

.laravel-products-container .product-card-content .product-card-specs .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: #007ac2;
    flex-shrink: 0;
}

.laravel-products-container .product-card-content .product-card-specs .spec-label {
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

/* Vanaf-price block */
.laravel-products-container .product-card-content .product-card-price {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 14px;
    font-size: 0.95em;
    color: #555;
}

.laravel-products-container .product-card-content .product-card-price .price-label {
    font-weight: 600;
    color: #555;
    text-transform: none;
    letter-spacing: 0;
    font-size: 1em;
    margin-bottom: 0;
}

.laravel-products-container .product-card-content .product-card-price .price-amount {
    font-size: 1.25em;
    font-weight: 700;
    color: #007ac2;
}


/* === IMAGE MODAL / LIGHTBOX === */

.product-image-main {
    cursor: zoom-in;
    position: relative;
}
.product-image-main .slider-nav {
    cursor: pointer;
}
.product-image-main::after {
    content: 'Klik om te vergroten';
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.55);
    color: #fff;
    font-size: 0.75em;
    padding: 4px 10px;
    border-radius: 3px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    white-space: nowrap;
    z-index: 5;
}
.product-image-main:hover::after {
    opacity: 1;
}

.zs-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.88);
    z-index: 99999;
    align-items: center;
    justify-content: center;
}
.zs-modal-overlay.is-open {
    display: flex;
}
.zs-modal-inner {
    position: relative;
    max-width: 92vw;
    max-height: 92vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.zs-modal-inner img {
    max-width: 92vw;
    max-height: 88vh;
    object-fit: contain;
    display: block;
    border-radius: 4px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}
.zs-modal-close {
    position: fixed;
    top: 18px;
    right: 22px;
    background: none;
    border: none;
    color: #fff;
    font-size: 2.2em;
    line-height: 1;
    cursor: pointer;
    z-index: 100000;
    padding: 4px 10px;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}
.zs-modal-close:hover {
    opacity: 1;
}
.zs-modal-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    font-size: 2.2em;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100000;
    transition: background 0.2s ease;
}
.zs-modal-nav:hover { background: rgba(255,255,255,0.3); }
.zs-modal-nav.prev  { left: 16px; }
.zs-modal-nav.next  { right: 16px; }
