.moemen-animated-icon-button-wrap {
    display: flex;
    width: 100%;
}

.moemen-animated-icon-button {
    --meab-height: 48px;
    --meab-icon-size: 40px;
    --meab-bg: #111111;
    --meab-text: #ffffff;
    --meab-icon-bg: #ffffff;
    --meab-icon-color: #111111;
    --meab-hover-text: #ffffff;
    position: relative;
    isolation: isolate;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: var(--meab-height);
    padding: 4px calc(var(--meab-icon-size) + 14px) 4px 24px;
    overflow: hidden;
    border: 0;
    background: var(--meab-bg);
    color: var(--meab-text);
    font-weight: 500;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: padding 500ms cubic-bezier(.22, 1, .36, 1), transform 250ms ease, box-shadow 250ms ease;
    box-shadow: none;
}

.moemen-animated-icon-button:hover,
.moemen-animated-icon-button:focus {
    color: var(--meab-text);
    text-decoration: none;
    padding-left: calc(var(--meab-icon-size) + 14px);
    padding-right: 24px;
}

.moemen-animated-icon-button:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

.moemen-animated-icon-button:active {
    transform: translateY(1px) scale(.99);
}

.moemen-animated-icon-button__text {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    transition: transform 500ms cubic-bezier(.22, 1, .36, 1);
}

.moemen-animated-icon-button__icon {
    position: absolute;
    z-index: 3;
    right: 4px;
    top: 50%;
    display: inline-flex;
    width: var(--meab-icon-size);
    height: var(--meab-icon-size);
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--meab-icon-bg);
    color: var(--meab-icon-color);
    transform: translateY(-50%) rotate(0deg);
    transition: right 500ms cubic-bezier(.22, 1, .36, 1), transform 500ms cubic-bezier(.22, 1, .36, 1);
}

.moemen-animated-icon-button__icon svg {
    display: block;
    width: 40%;
    height: 40%;
}

.moemen-animated-icon-button:hover .moemen-animated-icon-button__icon,
.moemen-animated-icon-button:focus .moemen-animated-icon-button__icon {
    right: calc(100% - var(--meab-icon-size) - 4px);
    transform: translateY(-50%) rotate(45deg);
}

@media (prefers-reduced-motion: reduce) {
    .moemen-animated-icon-button,
    .moemen-animated-icon-button__icon,
    .moemen-animated-icon-button__text {
        transition: none !important;
    }
}


.moemen-animated-icon-button__fill {
    display: none;
}

.moemen-animated-icon-button--style-2 {
    min-width: 200px;
    padding: 4px 26px;
    background: var(--meab-bg);
    color: var(--meab-text);
}

.moemen-animated-icon-button--style-2:hover,
.moemen-animated-icon-button--style-2:focus {
    padding: 4px 26px;
    color: var(--meab-hover-text);
}

.moemen-animated-icon-button--style-2 .moemen-animated-icon-button__fill {
    position: absolute;
    z-index: 1;
    left: 4px;
    top: 50%;
    display: block;
    width: var(--meab-icon-size);
    height: var(--meab-icon-size);
    border-radius: 999px;
    background: var(--meab-icon-bg);
    transform: translateY(-50%);
    transition: width 500ms cubic-bezier(.22, 1, .36, 1);
}

.moemen-animated-icon-button--style-2:hover .moemen-animated-icon-button__fill,
.moemen-animated-icon-button--style-2:focus .moemen-animated-icon-button__fill {
    width: calc(100% - 8px);
}

.moemen-animated-icon-button--style-2 .moemen-animated-icon-button__icon {
    left: 4px;
    right: auto;
    background: transparent;
    color: var(--meab-icon-color);
    transform: translateY(-50%) rotate(0deg);
}

.moemen-animated-icon-button--style-2:hover .moemen-animated-icon-button__icon,
.moemen-animated-icon-button--style-2:focus .moemen-animated-icon-button__icon {
    right: auto;
    transform: translateY(-50%) translateX(.4rem) rotate(0deg);
}

.moemen-animated-icon-button--style-2 .moemen-animated-icon-button__text {
    position: relative;
    z-index: 2;
    margin-left: 28px;
    color: currentColor;
    transition: color 500ms cubic-bezier(.22, 1, .36, 1);
}
