@import '/UI/Style.scss';

KillFeedEntry {
    position: relative;
    flex-direction: row;
    gap: 15px;
    padding: 4px 60px;
    font-size: 24px;
    font-family: $font-main;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s ease-in-out;
    height: 42px;

	&.relevant {
		background-color: $white;
		color: $gray;

		* img:not(.headshot) {
			filter: brightness(0);
		}
	}

	&:not(.relevant) {
		background-color: $gray-darker;
	}

    p {
        &:not(.no-max) {
            max-width: 150px;
            text-overflow: ellipsis;
        }

        &.gray {
            color: $chat-default;
        }
    }

    >.self-death {
        gap: 5px;

        * {
            align-items: center;
        }

        >img {
            height: 28px;
            max-width: 60px;
            background-size: contain;
            background-position: center;
            background-repeat: no-repeat;
        }
    }

    &:intro {
        transform: translateX(200%);
    }

    &:outro {
        transform: translateX(200%);
    }

    >.killstreak {
        position: absolute;
        right: 100%;
        color: $red;
        background-color: $white;
        box-shadow: 0px 0px 2px $white;
        padding: 4px;
        height: 26px;
        justify-content: center;
        align-items: center;
        transform: translateX(40px) rotateZ(-2deg);
        width: 80px;
        flex-direction: row;
        gap: 4px;
        transition: transform 0.2s 0.3s ease-in-out;

        &:intro {
            animation: Killstreak 0.2s bounce-in;
        }

        >img {
            height: 100%;
            aspect-ratio: 1;
            background-size: contain;
            background-position: center;
            background-repeat: no-repeat;
        }
    }

    >.gear {
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 5px;

        >img {
            height: 32px;
            max-width: 100px;
            background-size: contain;
            background-position: center;
            background-repeat: no-repeat;
        }

        >.headshot {
            height: 32px;
            aspect-ratio: 2;
            background-size: contain;
            background-position: center;
            background-repeat: no-repeat;
        }
    }
}

@keyframes Killstreak {
    0% {
        transform: translateX(40px) rotateZ(-2deg) scaleY(0);
    }

    100% {
        transform: translateX(40px) rotateZ(-2deg) scaleY(1);
    }
}