.upgrade-popup-opened {
    overflow: hidden!important;
}

.upgrade-popup {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgb(40 35 25 / 90%);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease;
}

.upgrade-popup.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.upgrade-popup__modal {
    background: #fffcf6;
    width: calc(100% - 30px);
    max-height: calc(100% - 30px);
    padding-left: 15px;
    padding-right: 15px;
    border-radius: 5px;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity .3s ease, transform .3s ease;
}

.upgrade-popup__modal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.upgrade-popup__modal-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: auto;
    gap: clamp(0.3125rem, 0.2404rem + 0.3205vw, 0.625rem);
    max-height: 100%;
    padding: clamp(2.5rem, 1.9231rem + 2.5641vw, 5rem) 15px;
    position: relative;
}

.upgrade-popup__reward {
    width: 70px;
    fill: #cfb57b;
    flex-shrink: 0;
}

.upgrade-popup__modal-body p {
    margin: 0;
}

.upgrade-popup__title {
    font-size: clamp(1.5625rem, 1.4904rem + 0.3205vw, 1.875rem);
    line-height: normal;
    color: #282319;
    font-weight: 600;
    text-align: center;
}

.upgrade-popup__tagline {
    font-size: clamp(0.938rem, 0.192vw + 0.894rem, 1.125rem);
    line-height: normal;
    color: #726e65;
    text-align: center;
}

.upgrade-popup__level {
    font-size: clamp(0.938rem, 0.192vw + 0.894rem, 1.125rem);
    padding: 15px 30px;
    border-radius: 5px;
    font-weight: 600;
    line-height: normal;
    color: #fff;
    margin-top: clamp(0.625rem, 0.4808rem + 0.641vw, 1.25rem);
    text-align: center;
}

.upgrade-popup__link {
    font-size: 0.938rem;
    color: #282319;
    font-weight: 600;
    text-decoration: underline;
    transition: color .3s ease-in-out;
    text-align: center;
}

.upgrade-popup__link:hover {
    color: #cfb57b;
}

.upgrade-popup__close {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    position: absolute;
    top: 15px;
    right: 0;
    padding: 0;
    border-radius: 5px;
    background: #282319;
    transition: background .3s ease-in-out;
}

.upgrade-popup__close:hover {
    background: #cfb57b;
}

.upgrade-popup__close:focus {
    outline: none;
}

.upgrade-popup__close svg {
    fill: #fff;
    width: 15px;
}

@media screen and (min-width: 768px) {
    .upgrade-popup__modal {
        width: clamp(30rem, 27.6923rem + 10.2564vw, 40rem);
    }
}
