.sy-popup {
    width: calc(100% - 2rem);
    max-width: 640px;
    max-height: calc(100% - 2rem);
    padding: 0;
    border: 0;
    background: #fff;
    color: inherit;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    overflow: auto;
}

.sy-popup::backdrop {
    background: rgba(0, 0, 0, 0.6);
}

.sy-popup[open] {
    animation: sy-popup-in 0.25s ease-out;
}

.sy-popup__inner {
    position: relative;
    padding: 2.5rem 2rem 2rem;
}

.sy-popup__close {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
}

.sy-popup__close:hover,
.sy-popup__close:focus-visible {
    opacity: 0.7;
}

.sy-popup__content > :last-child,
.sy-popup__content > :last-child > :last-child {
    margin-bottom: 0;
}

.sy-popup__content img {
    max-width: 100%;
    height: auto;
}

html.sy-popup-open {
    overflow: hidden;
}

@keyframes sy-popup-in {
    from {
        opacity: 0;
        transform: translateY(1rem);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sy-popup[open] {
        animation: none;
    }
}

@media (max-width: 575px) {
    .sy-popup__inner {
        padding: 2.5rem 1.25rem 1.25rem;
    }
}
