.feedback__card {
    display: flex;
    flex-direction: column-reverse;
    align-items: start;
    position: fixed;
    z-index: 999;

    overflow: hidden;

    opacity: 0;
    pointer-events: none;

    gap: 10px;

    width: min(340px, calc(100vw - 32px));
    padding: 16px 18px;

    top: 30%;
    left: 50%;

    background-color: #fff;

    transform: translate(-50%, calc(-50% - 100vh));
    transition: transform .5s ease, opacity .3s ease;

    border: solid 1px rgba(0, 0, 0, 0.08);
    border-radius: 14px;
    box-shadow: 0px 16px 32px -8px rgba(0, 0, 0, 0.2);

    & h2 {
        align-self: center;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
        font-size: 14px;
        font-weight: 700;
        line-height: 1.2;
        color: #16241d;
    }

    & p {
        line-height: 1.4;
        color: rgba(0, 0, 0, 0.6);
    }

    & h2>svg {
        color: rgba(0, 0, 0, 0.35);
        width: 18px;
        min-width: 18px;
        height: auto;
        cursor: pointer;
        transition: color .2s ease;

        &:hover {
            color: rgba(0, 0, 0, 0.7);
        }
    }

}

.feedback__card__content {
    display: flex;
    align-items: center;
    gap: 14px;
}

.feedback__card__icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 100%;
    background-color: rgba(39, 153, 99, 0.12);

    &>svg {
        width: 20px;
        height: auto;
        color: #279963;
    }
}

.feedback__card__description {
    font-size: 12px;
}

@media (min-width: 1024px) {

    .feedback__card {
        width: min(400px, calc(100vw - 48px));
        padding: 20px 22px;

        & h2 {
            font-size: 16px;
        }

        & h2>svg {
            width: 20px;
            min-width: 20px;
        }
    }

    .feedback__card__icon {
        width: 52px;
        height: 52px;

        &>svg {
            width: 26px;
        }
    }

    .feedback__card__description {
        font-size: 14px;
    }

}

.error svg {
    color: #ff0000;
}

.feedback__card__icon.error {
    background-color: rgba(255, 0, 0, 0.1);
}

.feedback__card--actvie {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%);
}

.feedback__card::before {
    content: '';

    position: absolute;
    bottom: 0;
    left: 0;

    height: 4px;
    width: 0%;
    background-color: #279963;
}

.error::before {
    background-color: #ff0000;
}

/* Added via JS right as the card becomes active, timed to match the
   auto-hide delay, so the bar visually counts down until it dismisses. */
.feedback__card--timer::before {
    width: 100%;
    transition: width 5s linear;
}