@import '../core/variables.less';
@import '../theme/index.less';

@ant-select: ant-select;

.@{ant-select} {
    color: var(--mi-font, @mi-font);

    &-selection-item {
        .properties(font-size, 14);
    }

    &:not(.@{ant-select}-customize-input) .@{ant-select}-selector {
        .linear-gradient-background();
        border-color: var(--mi-border, @mi-border);
        .border-radius(8);
    }

    &:not(.@{ant-select}-disabled):hover .@{ant-select}-selector {
        border-color: var(--mi-theme, @mi-theme);
    }

    &-arrow {
        color: var(--mi-font, @mi-font);
    }

    &-focused:not(.@{ant-select}-disabled)&:not(.@{ant-select}-customize-input) .@{ant-select}-selector {
        border-color: var(--mi-theme, @mi-theme);
        box-shadow: 0 0 0 2px fade(@mi-theme, 20%);
    }

    &-dropdown {
        background-color: var(--mi-dropdown-bg, @mi-dropdown-bg);
        color: var(--mi-font, @mi-font);
    }

    &-item {
        color: var(--mi-font, @mi-font);

        &-option-disabled {
            color: var(--mi-dropdown-select-item, @mi-dropdown-select-item);
        }

        &-option-selected:not(.@{ant-select}-item-option-disabled) {
            .linear-gradient-background();
            color: var(--mi-theme, @mi-theme);
        }

        &-option-active:not(.@{ant-select}-item-option-disabled) {
            .linear-gradient-background();
        }
    }

    &-disabled&:not(.@{ant-select}-customize-input) .@{ant-select}-selector {
        .linear-gradient-background();
        color: fade(@mi-font, 50%);
    }

    &-item-empty {
        .flex();
        .properties(padding-top, 16);
        .properties(padding-bottom, 8);

        .ant-empty-description {
            color: var(--mi-font, @mi-font);
        }
    }

    &-dropdown {
        z-index: var(--mi-z-index-peak, @mi-z-index-peak);
    }

    &-clear {
        .border-radius-circle();
        .flex();
    }
}