/*******************************************************************************************
*   ___  _          ______                     _ _                _                        *
*  / _ \| |         | ___ \                   | (_)              | |              © 2025   *
* / /_\ | | _____  _| |_/ /_ __ __ _ _ __   __| |_ _ __   __ _   | |_ ___  __ _ _ __ ___   *
* |  _  | |/ _ \ \/ / ___ \ '__/ _` | '_ \ / _` | | '_ \ / _` |  | __/ _ \/ _` | '_ ` _ \  *
* | | | | |  __/>  <| |_/ / | | (_| | | | | (_| | | | | | (_| |  | ||  __/ (_| | | | | | | *
* \_| |_/_|\___/_/\_\____/|_|  \__,_|_| |_|\__,_|_|_| |_|\__, |  \___\___|\__,_|_| |_| |_| *
*                                                         __/ |                            *
*                                                        |___/                             *
* ---------------------------------------------------------------------------------------- *
* This is commercial software, only users who have purchased a valid license and accept    *
* to the terms of the License Agreement can install and use this program.                  *
* ---------------------------------------------------------------------------------------- *
* website: https://cs-cart.alexbranding.com                                                *
*   email: info@alexbranding.com                                                           *
*******************************************************************************************/

@mb-item-color: var(--ab-mb-bg-color,@content_bg);
@mb_item_icon_size: 32px;
@mb_item_icon_color: var(--ab-mb-items-color,@font);
@mb_item_title_color: var(--ab-mb-items-color,@font);
@mb_item_link_color: var(--ab-mb-items-color,@links);
@mb_desc_item_color: color-mix(in srgb, var(--ab-mb-items-color,@lighten-font) 100%, var(--ab-mb-bg-color, @lighten-font)20%);

.ab__motivation_block {
	margin-bottom: var(--gap-s);
}

.ab__mb_items {

    .ab__mb_item-name {
        .uppercase() when (@abt__ut2_general_use_titles_uppercase = true) {
            text-transform: uppercase;
        }
        .uppercase();
    }

    &.ab-mb-live-editor {
        .cm-tooltip {
            display: none;
        }
    }
    &.fill {
        overflow: hidden;
    }
}
.ab__mb_item-description {
    padding-inline: var(--gap-sm);
    padding-block-end: var(--gap-s);

    .desktop-hidden {
        display: none;
    }
    &.padding-left {
        padding-left: @mb_item_icon_size + 10px;
    }
}

.ab-mb-style-presets {
    color: @mb_desc_item_color;

    div {
        color: @mb_desc_item_color;
    }

    &.ty-wysiwyg-content {
        position: relative;

        p, div, ul, li {
            line-height: 1.2;
        }

        ul {
            padding: 0;
            padding-inline-start: 0;
            padding-inline-end: var(--gap-sm);
            margin: 0;

            li {
                padding: 2px 0;
                list-style-position: inside;
                list-style-type: none;
                color: @mb_desc_item_color;
            }
        }
        p {
            display: flex;
            align-items: center;
            color: @mb_desc_item_color;
        }
        i {
            font-size: 18px;
            margin-right: 7px;
            color: @mb_desc_item_color;
        }
        .ab-mb-prod-categories-list {
            li {
                color: @lighten-max-font;
            }
            a {
                &:last-child {
                    font-weight: bold;
                }
            }
        }
    }
    span.cm-tooltip {
        &.right {
            right: 0;
            margin-right: 0;
        }
        &.left {
            left: 0;
            margin-left: 0;
        }
        i {
            color: @mb_item_link_color;
            font-size: 14px;
            line-height: 0;
            margin: 0;
        }
        @media (hover: none) {
            display: none;
        }
    }
}
.ab-mb-style-presets {
    * {
        .lighten & {

        }
        .darken & {
            color: white;

            a[href] {
                text-decoration: underline;

                &:hover {
                    text-decoration: none;
                }
            }
        }
    }
    .with_color {
        color: @in_stock;
    }
}
.ab__mb_items.darken {
    * {
        color: white;

        &[class*="icon"] {
            color: white !important;
        }
    }
}

.ab__mb_delivery_type-list {
    display: flex;
    flex-flow: column;
    gap: var(--gap-sm) var(--gap-s);

    span[class*="icon"].cm-tooltip {
        font-size: 16px;
    }

    .ab__mb_delivery_type {
        display: flex;
        flex-wrap: wrap;
        gap: 3px var(--gap-xs);

        > img {
            max-width: 32px;
            max-height: 32px;
        }

        &.with_logo ~ .ab__mb_delivery_type:not(.with_logo) {
            padding-inline-start: 42px;
        }
    }
    .ab__mb_delivery_type_description {
        flex: 1;
        display: flex;
        flex-flow: column;
        gap: 3px;
    }
    .ab__mb_delivery_type_description-header {
        display: flex;
        gap: var(--gap-xs);
    }
    .ab__mb_delivery_type_name {
        display: flex;
        flex-wrap: wrap;
        column-gap: var(--gap-xs);

        .ab-mb-style-presets & {
            color: @mb_item_title_color;
        }
    }
    .ab__mb_delivery_type_time {
        a {
            .ajx-link();
        }
    }
    .ab__mb_delivery_type_price {
        display: flex;
        flex-shrink: 0;
        height: fit-content;
        column-gap: var(--gap-xxs);
        text-align: right;
    }
}
.ab__mb_motivation_type-list {
    display: flex;
    flex-flow: column;
    gap: var(--gap-sm) var(--gap-s);

    span[class*="icon"].cm-tooltip {
        font-size: 16px;
        color: @mb_desc_item_color;
    }

    a {
        .ajx-link();
    }

    .ab__mb_motivation_type {
        display: flex;
        flex-wrap: wrap;
        justify-content: space-between;
        gap: var(--gap-xxs) var(--gap-s);

        div:empty {
            display: none;
        }
    }
    .ab__mb_motivation_type_description {
        flex: 1;
        display: flex;
        flex-flow: column;
        gap: var(--gap-xs);
    }
    .ab__mb_motivation_type_name {
        display: flex;
        flex-wrap: wrap;
        gap: var(--gap-xxs) var(--gap-s);

        .ab-mb-style-presets & {
            color: @mb_item_title_color;
        }

        > img {
            position: absolute;
            max-width: 32px;
            margin-inline-start: calc(~'(32px + var(--gap-xs)) * -1');
        }
    }
    .ab__mb_motivation_type_icons {
        display: flex;
        flex-wrap: wrap;
        gap: var(--gap-xs);

        img {
            max-height: 24px;
            max-width: 80px;
        }
    }
    .ab__mb_motivation_type_desc {}
    .ab__mb_motivation_type_more {
        display: flex;
        align-items: center;
        flex-shrink: 0;
        height: fit-content;
        column-gap: var(--gap-xxs);
        text-align: right;

        a {
            color: @mb_desc_item_color;
            text-decoration-color: @mb_desc_item_color;
        }
    }
}