@import (reference) '~stremio-colors/dist/less/stremio-colors.less';

.addon-container {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    padding: 1.5rem;
    background-color: @color-background;
    cursor: inherit;

    .logo-container {
        flex: none;
        width: 6rem;
        height: 6rem;
        background-color: @color-surface-light5;

        .logo {
            display: block;
            width: 100%;
            height: 100%;
            padding: 0.5rem;
            object-fit: contain;
            object-position: center;
        }

        .icon {
            display: block;
            width: 100%;
            height: 100%;
            padding: 1rem;
            fill: @color-secondaryvariant1-light3;
        }
    }

    .info-container {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: 0;
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: baseline;
        padding: 0 0.5rem;

        .name-container {
            flex-grow: 0;
            flex-shrink: 1;
            flex-basis: auto;
            padding: 0 0.5rem;
            max-height: 3.6em;
            font-size: 1.6rem;
            color: @color-surface-light5-90;
        }

        .version-container {
            flex-grow: 1;
            flex-shrink: 1;
            flex-basis: auto;
            margin-top: 0.5rem;
            padding: 0 0.5rem;
            max-height: 2.4em;
            color: @color-surface-light5-60;
        }

        .types-container {
            flex-grow: 0;
            flex-shrink: 0;
            flex-basis: 100%;
            margin-top: 0.5rem;
            padding: 0 0.5rem;
            max-height: 2.4em;
            color: @color-surface-light5-40;
            text-transform: capitalize;
        }

        .description-container {
            flex-grow: 0;
            flex-shrink: 0;
            flex-basis: 100%;
            margin-top: 0.5rem;
            padding: 0 0.5rem;
            max-height: 4.8em;
            color: @color-surface-light5-90;
        }
    }

    .buttons-container {
        flex: none;
        width: 17rem;

        .install-button-container, .uninstall-button-container, .share-button-container {
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: center;
            height: 4rem;
            padding: 0 1rem;

            &:not(:first-child) {
                margin-top: 1rem;
            }

            .icon {
                flex: none;
                width: 2rem;
                height: 2rem;
                margin-right: 1rem;
            }

            .label {
                flex-grow: 0;
                flex-shrink: 1;
                flex-basis: auto;
                max-height: 2.4em;
                font-size: 1.2rem;
                font-weight: 500;
                text-align: center;
            }
        }

        .install-button-container {
            background-color: @color-accent3;

            &:hover {
                background-color: @color-accent3-light2;
            }

            .label {
                color: @color-surface-light5;
            }
        }

        .uninstall-button-container {
            outline-color: @color-background-light3;
            outline-style: solid;

            &:hover {
                background-color: @color-background-light2;
            }

            .label {
                color: @color-surface-light5-90;
            }
        }

        .share-button-container {
            &:hover {
                .icon {
                    fill: @color-secondaryvariant1-light1;
                }

                .label {
                    text-decoration: underline;
                    color: @color-secondaryvariant1-light2;
                }
            }

            .icon {
                fill: @color-secondaryvariant1-dark1-60;
            }

            .label {
                color: @color-secondaryvariant1-90;
            }
        }
    }
}