// variables
$thy-animation-duration-slow: 0.3s;
$thy-animation-duration-base: 0.2s;
$thy-animation-duration-fast: 0.1s;

$thy-animation-duration-collapse: 0.15s;

$thy-animation-curve-ease-base-out: cubic-bezier(0.7, 0.3, 0.1, 1);
$thy-animation-curve-ease-base-in: cubic-bezier(0.9, 0, 0.3, 0.7);
$thy-animation-curve-ease-out: cubic-bezier(0.215, 0.61, 0.355, 1);
$thy-animation-curve-ease-in: cubic-bezier(0.55, 0.055, 0.675, 0.19);
$thy-animation-curve-ease-in-out: cubic-bezier(0.645, 0.045, 0.355, 1);
$thy-animation-curve-ease-out-back: cubic-bezier(0.12, 0.4, 0.29, 1.46);
$thy-animation-curve-ease-in-back: cubic-bezier(0.71, -0.46, 0.88, 0.6);
$thy-animation-curve-ease-in-out-back: cubic-bezier(0.71, -0.46, 0.29, 1.46);
$thy-animation-curve-ease-out-circ: cubic-bezier(0.08, 0.82, 0.17, 1);
$thy-animation-curve-ease-in-circ: cubic-bezier(0.6, 0.04, 0.98, 0.34);
$thy-animation-curve-ease-in-out-circ: cubic-bezier(0.78, 0.14, 0.15, 0.86);
$thy-animation-curve-ease-out-quint: cubic-bezier(0.23, 1, 0.32, 1);
$thy-animation-curve-ease-in-quint: cubic-bezier(0.755, 0.05, 0.855, 0.06);
$thy-animation-curve-ease-in-out-quint: cubic-bezier(0.86, 0, 0.07, 1);
$thy-animation-curve-ease-in-out-standard: cubic-bezier(0.34, 0.69, 0.1, 1);

// zoom animations
@keyframes thy-scale-x-fade {
    from {
        opacity: 0;
        transform: scaleX(0.9);
    }
    to {
        opacity: 1;
        transform: scaleX(1);
    }
}
.thy-scale-x-enter {
    animation: thy-scale-x-fade $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}
.thy-scale-x-leave {
    opacity: 0;
    transform: scaleX(0.9);
    transition:
        opacity $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard,
        transform $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}

@keyframes thy-scale-y-fade {
    from {
        opacity: 0;
        transform: scaleY(0.9);
    }
    to {
        opacity: 1;
        transform: scaleY(1);
    }
}
.thy-scale-y-enter {
    animation: thy-scale-y-fade $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}
.thy-scale-y-leave {
    opacity: 0;
    transform: scaleY(0.9);
    transition:
        opacity $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard,
        transform $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}

@keyframes thy-scale-fade {
    from {
        opacity: 0;
        transform: scale(0.9, 0.9);
    }
    to {
        opacity: 1;
        transform: scale(1, 1);
    }
}
.thy-scale-enter {
    animation: thy-scale-fade $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}
.thy-scale-leave {
    opacity: 0;
    transform: scale(0.9, 0.9);
    transition:
        opacity $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard,
        transform $thy-animation-duration-base $thy-animation-curve-ease-in-out-standard;
}

// fade animations
.thy-fade-enter {
    opacity: 1;
    transition: opacity $thy-animation-duration-base;
}

.thy-fade-leave {
    opacity: 0;
    transition: opacity $thy-animation-duration-base;
}

// collapse animations
// Note: Class name should be the same as THY_ANIMATION_COLLAPSE_CLASS value.
.thy-animation-collapse {
    overflow: hidden;
    transition:
        height $thy-animation-duration-collapse $thy-animation-curve-ease-in-out,
        opacity $thy-animation-duration-collapse $thy-animation-curve-ease-in-out;
}
