@use '../../../styles/mat-selectors' as ms;

.adf-pdf-viewer {
    width: 100%;
    height: 100%;
    margin: 0;

    .adf-loader-container {
        display: flex;
        flex-direction: row;
        height: 100%;
    }

    &__thumbnails {
        position: relative;
        height: 100%;
        width: 190px;
        background-color: rgba(0, 0, 0, 0.12);
        display: flex;
        flex-direction: column;
        padding: 0;

        .adf-info-drawer-layout {
            display: flex;
            flex-direction: column;
            flex: 1;
            background: #e6e6e6;
        }

        .adf-info-drawer-layout-header {
            margin-bottom: 0;
        }

        .adf-info-drawer-layout-content {
            padding: 0;
            height: 100%;
            overflow: hidden;
        }

        .adf-info-drawer-content {
            height: 100%;
        }

        .adf-info-drawer-layout-content > *:last-child {
            height: 100%;
            overflow: hidden;
        }
    }

    .adf-thumbnails-template {
        &__container {
            display: flex;
            flex-direction: column;
            height: 100%;
        }

        &__buttons {
            height: 45px;
            justify-content: flex-end;
            align-items: flex-end;
            display: flex;
            color: var(--adf-theme-foreground-text-color-064);
        }
    }

    &__container {
        display: flex;
        height: 100%;
        min-height: 1px;
    }

    &__content {
        flex: 1 1 auto;
        position: relative;
    }

    .adf-loader-item {
        margin: auto;
        max-height: 100px;
        max-width: 300px;

        .adf-loader-item-progress-bar {
            max-width: 300px;
            margin: 0;
            position: absolute;
            top: 50%;
            left: 50%;
            /* stylelint-disable-next-line property-no-vendor-prefix */
            -ms-transform: translate(-50%, -50%);
            transform: translate(-50%, -50%);
        }
    }

    &__toolbar {
        z-index: 100;
        position: absolute;
        bottom: 5px;
        left: 50%;
        transform: translateX(-50%);

        .adf-toolbar #{ms.$mat-toolbar} {
            max-height: 48px;
            background-color: var(--adf-theme-background-card-color);
            border-width: 0;
            border-radius: 2px;
            box-shadow:
                0 2px 2px 0 rgba(0, 0, 0, 20.4),
                0 0 2px 0 rgba(0, 0, 0, 0.12);
        }

        &-page-selector {
            padding-left: 10px;
            padding-right: 10px;
            white-space: nowrap;
            font-size: var(--theme-body-1-font-size);

            & > input {
                border: 1px solid var(--adf-theme-foreground-text-color-007);
                background-color: var(--adf-theme-background-card-color);
                color: inherit;
                font-size: var(--theme-body-1-font-size);
                padding: 5px;
                height: 24px;
                line-height: 24px;
                text-align: right;
                width: 33px;
                margin-right: 4px;
                outline-width: 1px;
                outline-color: gray;
            }
        }

        &-page-scale {
            cursor: default;
            width: 79px;
            height: 24px;
            font-size: var(--theme-body-1-font-size);
            border: 1px solid var(--adf-theme-foreground-text-color-007);
            text-align: center;
            line-height: 24px;
            margin-left: 4px;
            margin-right: 4px;
        }
    }
}
