@import "shared/mixins-and-vars";

.text-resize {
    &__hero {
        position: relative;
        color: #fff;

        &--image {
            width: 100%;

            .text-zoom & {
                clip-path: inset(66vw 0 0 0);
                margin-top: -66vw;
            }
        }

        &--text {
            position: absolute;

            top: 6vw;
            left: 10px;
            width: calc(100% - 20px);
            max-width: initial;
            transform: none;
            background: rgba(0, 0, 0, 0.7);
            padding: 10px;
            text-align: center;

            .text-zoom & {
                position: static;
                transform: none;
                width: 100%;
                max-width: initial;
                background: #000;
            }
        }

        &--main-text {
            line-height: 1;
            font-size: (20 / @px);
            font-weight: bold;
        }

        &--sub-text {
            margin-bottom: 0;
            font-size: (12 / @px);
        }

        @media only screen and (min-width: 455px) {
            &--text {
                top: 37vw;
                transform: translateY(-50%);
            }

            &--main-text {
                font-size: (60 / @px);
            }

            &--sub-text {
                font-size: (15 / @px);
            }
        }

        @media @tablet-up {
            &--text {
                left: 30px;
                top: 50%;
                width: 40vw;
                transform: translateY(-50%);
                max-width: 395px;
            }

            &--image {
                .text-zoom & {
                    clip-path: none;
                    margin-top: 0;
                }
            }
        }
    }
}
