.hh-vtp-modal[hidden] {
    display: none !important;
}

.hh-vtp-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    box-sizing: border-box;
}

.hh-vtp-modal *,
.hh-vtp-modal *::before,
.hh-vtp-modal *::after {
    box-sizing: border-box;
}

.hh-vtp-modal-open {
    overflow: hidden;
}

.hh-vtp-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.72);
}

.hh-vtp-modal__dialog {
    position: relative;
    width: min(94vw, 680px);
    max-height: min(86vh, 760px);
    overflow: auto;
    background: #ffffff;
    color: #111827;
    border-radius: 8px;
    border: 1px solid rgba(17, 24, 39, 0.14);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
    padding: 22px;
}

.hh-vtp-modal__close {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    float: right;
    width: 34px;
    height: 34px;
    margin: -10px -10px 8px 12px;
    border: 0;
    border-radius: 999px;
    background: #111827;
    color: #ffffff;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
}

.hh-vtp-modal__close:hover,
.hh-vtp-modal__close:focus {
    background: #374151;
    outline: 2px solid #f59e0b;
    outline-offset: 2px;
}

.hh-vtp-modal__body {
    clear: both;
}

.hh-vtp-modal__body img {
    max-width: 100%;
    height: auto;
}

.hh-vtp-loading,
.hh-vtp-fallback {
    min-height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
    font-family: Arial, sans-serif;
}

@media (max-width: 480px) {
    .hh-vtp-modal {
        padding: 10px;
        align-items: flex-start;
        padding-top: 28px;
    }

    .hh-vtp-modal__dialog {
        width: 100%;
        max-height: calc(100vh - 56px);
        padding: 16px;
    }
}
