@custom-selector :--opened-menu [data-menu]:checked;

.product-card, .market-card {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    border: solid 1px rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    &::before

{
    content: '';
    position: absolute;
    top: 0px;
    left: 0;
    width: 100%;
    height: 0;
    border-width: 1px;
    border-style: solid;
    border-image-source: linear-gradient(90deg, rgba(232, 111, 58, 0) 0%, rgba(250, 255, 255, 0.5) 53.5%, rgba(232, 111, 58, 0) 100%);
    border-image-slice: 1;
    z-index: 2;
    padding: 0;
    margin: 0;
}

&::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    border-width: 1px;
    border-style: solid;
    border-image-source: linear-gradient(90deg, rgba(232, 111, 58, 0) 0%, rgba(250, 255, 255, 0.5) 53.5%, rgba(232, 111, 58, 0) 100%);
    border-image-slice: 1;
    z-index: 2;
}
}

    .product-card figure,
    .market-card figure {
        position: relative;
        overflow: clip;
        font-weight: normal;
        /*display: inline-block;*/
        margin-block: 0 !important;
    }


        .product-card figure img,
        .market-card figure img {
            aspect-ratio: 4/3;
            transition: all 0.5s ease;
            filter: brightness(50%);
        }

    .product-card:hover img,
    .market-card:hover img {
        transform: scale(1.05);
        filter: brightness(90%);
    }

    .product-card:hover svg,
    .market-card:hover svg {
        transform: translateX(5px);
    }

    .product-card .tag-grid {
        align-items: end;
        grid-template-columns: 1fr;
        grid-template-rows: 1fr;
        gap: var(--s1);
        position: absolute;
        z-index: 99;
        margin-block: unset !important;
        max-width: 100%;
        /* background-image: linear-gradient(to bottom, var(--color-motion-grey), transparent 30%); */
    }

    .product-card .tag-grid > * {
        padding:1rem;
        align-self: start;
    }

    .product-card figcaption {
        margin-top: -0.5rem;
        padding: var(--s2);
        background: light-dark(var(--color-motion-grey), var(--color-light));
        color: light-dark(var(--color-light), var(--color-motion-grey));
        font-style: normal;
        min-height: 175px;
    }

    .market-card figcaption {
        position: absolute;
        left: 0;
        bottom: 5%;
        padding: var(--s1);
        background: light-dark(var(--color-motion-grey), var(--color-light));
        color: light-dark(var(--color-light), var(--color-motion-grey));
        font-style: normal;
        min-width: 50%;
        border-top-right-radius: 10px;
        border-bottom-right-radius: 10px;

/*        background: rgba(255, 255, 255, 0.2);
        box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
        border: 1px solid rgba(255, 255, 255, 0.3);*/   
    }

        .product-card figcaption h3,
        .market-card figcaption h3 {
            color: light-dark(var(--color-light), var(--color-motion-grey));
            font-style: normal;
        }

        .product-card figcaption p,
        .market-card figcaption p {
            color: light-dark(var(--color-light), var(--color-motion-grey));
            font-size: var(--s1);
            font-style: normal;
            margin-block: 1rem;
        }

        .product-card figcaption p.orderCodes {
            font-size: var(--s-1);
            line-height: 20px;
        }

        .product-card figcaption hr {
            width: 100%;
            border: none;
            border-bottom: 1px solid light-dark(var(--color-light), var(--color-motion-grey));
        }

    .product-card figcaption .read-btn-inverse svg,
    .market-card figcaption .read-btn-inverse svg {
        transition: all 0.5s ease;
        stroke: light-dark(var(--color-light), var(--color-motion-grey));
    }

        .product-card figcaption .read-btn-inverse span,
        .market-card figcaption .read-btn-inverse span {
            font-size: var(--s-1);
            color: light-dark(var(--color-light), var(--color-motion-grey));
            font-weight: 500;
        }

        .product-card figcaption .read-btn-inverse:hover span {
            /*    color: var(--color-motion-orange);*/
        }

        .product-card figcaption .read-btn-inverse:hover svg,
        .market-card figcaption .read-btn-inverse:hover svg {
            transform: translateX(5px);
        }


    .product-card figcaption p:has(a) {
        margin-top: 3rem;
    }

/* Product page */
    figure .product img {
    object-fit: cover;
}



figure.product figcaption h2 {
    font-style: normal;
    text-align: center;
}

figure.product figcaption ul {
    font-size: var(--s0);
}


/* Solutions */
.solutions .center {
    background: var(--color-motion-grey);
    color: var(--color-light);
    display: flex;
    max-height: calc(100% - (2 * var(--radius-padding)));
    max-width: calc(100% - (2 * var(--radius-padding)));
    align-self: stretch;
    align-items: center;
    justify-items: center;
    padding: var(--radius-padding);
    border-radius: var(--radius-outer);
}

    .solutions .center > * {
        margin: auto;
        text-align: center;
    }

/*.solutions > figure a {
    border: none;
    outline: 2px solid light-dark(var(--color-light), var(--color-dark));
    outline-offset: 1px;
    padding: var(--radius-padding);
    display: block;
    border-radius: var(--radius-outer);*/
    /*clip-path: polygon( 4rem 0, 0 0, 0 4rem, 4rem 4rem, 4rem calc(100% - 4rem), 0 calc(100% - 4rem), 0 100%, 4rem 100%, 4rem calc(100% - 4rem), calc(100% - 4rem) calc(100% - 4rem), calc(100% - 4rem) 100%, 100% 100%, 100% calc(100% - 4rem), calc(100% - 4rem) calc(100% - 4rem), calc(100% - 4rem) 4rem, 100% 4rem, 100% 0, calc(100% - 4rem) 0, calc(100% - 4rem) 4rem, 4rem 4rem*/
/*}*/

.solutions > figure a {
    position: relative;
    background: radial-gradient(circle at 50% 0%, light-dark(var(--color-light), var(--color-motion-grey)) 0%, light-dark(var(--color-table-light),var(--color-motion-dark-grey)) 64%);
    box-shadow: inset 0 1.01rem 0.2rem -1rem #fff0, inset 0 -1.01rem 0.2rem -1rem #0000, 0 -1.02rem 0.2rem -1rem #fff0, 0 1rem 0.2rem -1rem #0000, 0 0 0 1px #fff3, 0 4px 4px 0 #0004, 0 0 0 1px #333;
    border-radius: 1.8rem;
    color: #fff;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: end;
    transition: all 0.4s ease-in-out, translate 0.4s ease-out;
}

    .solutions > figure a::before {
        content: "";
        display: block;
        --offset: 1rem;
        width: calc(100% + 2 * var(--offset));
        height: calc(100% + 2 * var(--offset));
        position: absolute;
        left: calc(-1 * var(--offset));
        right: calc(-1 * var(--offset));
        top: calc(-1 * var(--offset));
        bottom: calc(-1 * var(--offset));
        margin: auto;
        box-shadow: inset 0 0 0px 0.06rem light-dark(var(--color-motion-hardly-grey), var(--color-motion-grey));
        border-radius: 2.6rem;
        --ax: 5rem;
        clip-path: polygon( var(--ax) 0, 0 0, 0 var(--ax), var(--ax) var(--ax), var(--ax) calc(100% - var(--ax)), 0 calc(100% - var(--ax)), 0 100%, var(--ax) 100%, var(--ax) calc(100% - var(--ax)), calc(100% - var(--ax)) calc(100% - var(--ax)), calc(100% - var(--ax)) 100%, 100% 100%, 100% calc(100% - var(--ax)), calc(100% - var(--ax)) calc(100% - var(--ax)), calc(100% - var(--ax)) var(--ax), 100% var(--ax), 100% 0, calc(100% - var(--ax)) 0, calc(100% - var(--ax)) var(--ax), var(--ax) var(--ax) );
        transition: all 0.4s ease-in-out;
    }

    .solutions > figure a:hover {
        translate: 0 ;
    }

    .solutions > figure a:hover::before {
        --ax: 10rem;
        border-radius: 2.2rem;
        box-shadow: inset 0 0 0 0.08rem var(--color-motion-orange);
    }

.solutions > figure img {
    aspect-ratio: 5/4;
    border: 1px solid var(--color-motion-grey);
    border-bottom: none;
    border-top-left-radius: 1.5rem;
    border-top-right-radius: 1.5rem;
}

.solutions > figure figcaption {
    aspect-ratio: 5/1;
    background: light-dark(var(--color-motion-grey), var(--color-light));
    font-style: normal;
    display: flex;
    align-items: center;
    justify-items: center;
    border: 1px solid var(--color-motion-grey);
    border-top: none;
    border-bottom-left-radius: 1.5rem;
    border-bottom-right-radius: 1.5rem;
    /*border-bottom-right-radius: var(--radius-inner);*/
    min-width: 100%;
}

    .solutions > figure figcaption h3 {
        color: light-dark(var(--color-light), var(--color-dark));
        margin: 0 auto;
        font-size: var(--s1);
    }

.solutions > figure a:hover {
    outline-color: var(--color-motion-orange);
    }

    .solutions > figure a:hover figcaption h3 {
        color: light-dark(var(--color-light), var(--color-motion-orange));
    }

@media (prefers-color-scheme: light) {
    .solutions > figure a:hover figcaption {
        background: var(--color-motion-orange);
        border-color: var(--color-motion-orange);
    }
}

.filters {
    display: block;
}

.filterButton {
    cursor: pointer;
    display: none;
}

@media (max-width: 925px) {
    .filters {
        background: light-dark(#fff, var(--color-motion-grey));
        color: light-dark(var(--color-dark), var(--color-light));
        padding: 2.5vh;
        height: 70vh;
        width: 60vw;
        margin: -100px 50px;
        z-index: 99;
        opacity: 0;
        overflow-y: auto;
        border-radius: 25px;
        box-shadow: 4.0px 8.0px 8.0px hsl(0deg 0% 0% / 0.38);
    }

        .filters::-webkit-scrollbar {
            display: none;
        }

        .filters ul {
            color: light-dark(var(--color-dark), var(--color-light));
        }

    .filterButton {
        display: block;
        position: absolute;
        z-index: 100;
        top: 15vh;
        left: 5vw;
    }


    .filtersCheckbox:checked ~ .filters {
        animation: showFilters 0.5s forwards;
    }

    .filtersCheckbox:not(:checked) ~ .filters {
        animation: hideFilters 0.5s forwards;
    }

    @keyframes showFilters {
        to {
            opacity: 1;
        }
    }

    @keyframes hideFilters {
        to {
            opacity: 0;
        }
    }
}



/* Product showcase */
.MA_ProductShowcase {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 100%;
    gap: 5rem;
    width: 90vw;
    max-width: var(--grid-max);
    overflow-x: scroll;
    scroll-snap-type: x mandatory;
    scroll-marker-group: after;
    anchor-name: --timeline;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-behavior: smooth;
    margin: 0 auto;
}

    .MA_ProductShowcase > div {
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }

    .MA_ProductShowcase > div * {
        align-self: center;
        justify-self: center;
    }

        .MA_ProductShowcase > div > figure > img
        , .MA_ProductShowcase > div > .video
        , .MA_ProductShowcase > div > figure > picture > source
        , .MA_ProductShowcase > div > figure > picture > img
        {
            border-radius: 25px;
            width: 100%;
            height:100%;
            max-width: calc(var(--grid-max) / 2);
            margin: 0 auto;
          
        }

    .MA_ProductShowcase::scroll-button(*) {
        position: fixed;
        position-anchor: --timeline;
        border: solid 2px CanvasText;
        color: CanvasText;
        border-radius: 50%;
        width: 50px;
        height: 50px;
        background: transparent !important;
    }

    .MA_ProductShowcase::scroll-button(right) {
        content: '>';
        position-area: center right;
    }

    .MA_ProductShowcase::scroll-button(left) {
        content: '<';
        position-area: center left;
    }

/*    .MA_ProductShowcase::scroll-marker-group {
        position: absolute;
        position-anchor: --timeline;
        position-area: end center;
        grid-area: markers;
        display: grid;
        grid-auto-flow: column;
        gap: 2rem;
        padding: 1rem;
        justify-content: center;


      .MA_ProductShowcase > div::scroll-marker {
        content: attr(data-year);
        color: var(--color-motion-orange);
        text-decoration: none;
    }

    .MA_ProductShowcase > div::scroll-marker:hover {
        color: var(--color-light);
    }

    .MA_ProductShowcase > div::scroll-marker:target-current {
        color: var(--color-light);
    }*/

/* NOTE: time-buttons has been hidden below but clsses and code left in place, in case future use case. */
.showcase-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 90vw;
    max-width: var(--grid-max);
    position: relative;
    position-anchor: --timeline;
    /*    display: none;
    visibility: hidden;*/
}

    .showcase-buttons > button {
        border: solid 2px light-dark(var(--color-motion-grey), var(--color-light));
        color: light-dark(var(--color-motion-grey), var(--color-light));
        border-radius: 100%;
        width: 50px;
        height: 50px;
        background: transparent !important;
        padding: 0 !important;
    }

        .showcase-buttons > button:nth-child(1) {
            position-area: center left;
            justify-self: start;
        }

        .showcase-buttons > button:nth-child(2) {
            position-area: center right;
            justify-self: end;
        }

@supports selector(::scroll-button(*)) {
    .showcase-buttons > button {
        display: none;
        visibility: hidden;
    }

    #indicator {
        display: none;
        visibility: hidden;
    }
}

@media screen and (max-width: 767px) {
    .showcase-buttons {
        display: none;
        visibility: hidden;
    }

    .MA_ProductShowcase {
        scrollbar-width: auto;
        -ms-overflow-style: auto;
        scroll-behavior: smooth;
    }

        .MA_ProductShowcase > div > figure {
            margin-block: 0;
        }
}


@media (prefers-color-scheme: light) {
    .product-card figcaption {
        background: var(--color-motion-grey);
        color: var(--color-light);
    }

    .product-card figcaption h3 {
        color: var(--color-light);
    }

    .product-card figcaption p {
        color: var(--color-light);
    }
}

@media (prefers-color-scheme: dark) {
    .product-card figcaption {
        background: var(--color-light);
        color: var(--color-motion-grey);
    }

    .product-card figcaption h3 {
        color: var(--color-motion-grey);
    }

    .product-card figcaption p {
        color: var(--color-motion-grey);
    }
}

