@layer components {
    .highlight-list {
        padding-top: var(--size-9);
        padding-bottom: var(--size-9);

        content-block:has(> &) {
            background-color: var(--background_color, none);
        }

        header {
            margin-bottom: var(--size-8);
            text-align: var(--alignment, left);
            color: var(--text_color, var(--heading-color, inherit));

            h2 {
                font-weight: var(--font-weight-5);
            }
        }

        & .highlight-list-container {
            display: grid;
            grid-template-columns: max-content;
            grid-template-rows: repeat(4, min-content);
            justify-content: center;
            column-gap: var(--size-1);
            row-gap: 1rem;
            /* list-style-type: none; */
            padding: 0;
            margin: 0;
            width: 100%;

            & .highlight-item {
                display: grid;
                grid-template-columns: min-content auto;
                grid-template-rows: min-content max-content;
                grid-template-areas: "icon title" "icon description";
                gap: var(--size-2);
                row-gap: var(--size-0);
                margin: 0;
                align-items: center;

                color: var(--highlight_heading_color, inherit);
                background-color: var(--highlight_background_color, none);

                &:is(a):hover {
                    color: color(from currentColor srgb calc(r - .1) calc(g - .1) calc(b - .1));
                    background-color: color(from var(--highlight_background_color) srgb calc(r - .1) calc(g - .1) calc(b - .1));
                }

                :is(picture, img, svg) {
                    grid-area: icon;
                    height: 50px;
                    max-width: 70px;
                    width: auto;
                }

                .highlight-title {
                    grid-area: title;
                    display: grid;
                    grid-template-rows: min-content;
                    gap: var(--size-1);
                    align-content: center;

                    color: var(--highlight_heading_color, inherit);
                    font-size: var(--font-size-1);
                    font-weight: var(--font-weight-7);
                }

                .highlight-description {
                    grid-area: description;
                    max-width: inherit;
                    font-size: var(--font-size-00);
                    color: var(--highlight_body_color, inherit);

                    a {
                        color: inherit;

                        &:hover {
                            color: color(from currentColor srgb calc(r - .1) calc(g - .1) calc(b - .1));
                        }
                    }
                }
            }
        }

        /* tablet and up */
        @media screen and (min-width: 960px) {
            & .highlight-list-container {
                /* grid-template-columns: repeat(3, min-content minmax(var(--size-1), var(--size-12))) min-content; */
                grid-template-columns: repeat(auto-fit, minmax(100px, max-content));
                grid-template-rows: min-content;
                /* row-gap: 0; */

                gap: 0 var(--size-12);

                & .advantage-item {
                    /* grid-template-columns: min-content max-content; */

                    :is(picture, img, svg) {
                        height: clamp(30px, 4vw, 50px);
                        width: auto;
                    }
                }
            }

            &.dense .highlight-list-container {
                grid-template-columns: repeat(4, min-content 0);
                gap: var(--size-1);
            }
        }

        &.dense {

            & .highlight-list-container .highlight-item {
                grid-template-columns: 30px max-content;
                gap: var(--size-1);

                :is(picture, img, svg) {
                    width: 30px;
                    height: 30px;
                }

                :is(.highlight-title) {
                    display: grid;
                    grid-template-rows: min-content;
                    gap: var(--size-1);
                    align-content: center;
                    font-size: var(--font-size-00);
                }

                & .highlight-description {
                    font-size: var(--font-size-000);
                }
            }

        }

        &.full-description .highlight-list-container {
            grid-template-columns: auto;
            grid-template-rows: auto;
            gap: var(--size-6);
            row-gap: var(--size-9);

            & .highlight-item {
                gap: var(--size-3);
                grid-template-columns: min-content minmax(0, 1fr);
                grid-template-areas: ". title" "icon description";
                align-items: start;

                :is(.highlight-title) {
                    font-size: var(--font-size-2);
                }

                :is(picture, img, svg) {
                    height: 25px;
                    max-width: 35px;
                    width: auto;
                }
            }
        }

        &.info-graphic .highlight-list-container .highlight-item {
            grid-template-columns: min-content;
            grid-template-areas: "header" "description";
            justify-content: center;
            gap: var(--size-2);

            :is(header) {
                grid-area: header;
                display: flex;
                justify-content: center;
                align-items: center;
                gap: var(--size-2);
            }

            & .highlight-title {
                font-size: var(--font-size-3);
                font-weight: 400;
                white-space: nowrap;
            }

            & .highlight-description {
                font-size: var(--font-size-7);
                font-weight: 700;
                color: var(--sub-heading-color, var(--highlight_body_color, var(--color-blue)));
                text-align: center;
            }

            :is(picture, img, svg) {
                height: 20px;
                max-width: 28px;
                width: auto;
            }
        }

        /* desktop and up */
        @media screen and (min-width: 960px) {
            &.dense .highlight-list-container {
                gap: var(--size-3);
            }

            &.full-description .highlight-list-container {
                grid-template-columns: repeat(3, 1fr);
                grid-template-rows: auto;
                justify-items: center;
            }

            &.info-graphic .highlight-list-container {
                /* grid-template-columns: repeat(2, min-content minmax(var(--size-1), var(--size-14))) min-content; */
                grid-template-rows: auto;
                gap: 0 min(20%, var(--size-14));
            }
        }

        /* large screens */
        @media screen and (min-width: 1200px) {
            &.dense .highlight-list-container {
                gap: var(--size-8);
            }
        }

        /* Page specific styles */
        .product-page & h2 {
            color: var(--color-blue)
        }
    }
}
