.homepage-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.homepage-popup[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}

.homepage-popup__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    cursor: pointer;
}

.homepage-popup__content {
    position: relative;
    z-index: 10000;
    max-width: 600px; /* Reduced from 90vw */
    max-height: 80vh; /* Reduced from 90vh */
    width: 90vw; /* Responsive width up to 600px */
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.homepage-popup[aria-hidden="false"] .homepage-popup__content {
    transform: scale(1);
}

.homepage-popup__content img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 8px;
    display: block;
    object-fit: contain;
}

.homepage-popup__close {
    position: absolute;
    top: -15px;
    right: -15px;
    width: 34px;
    height: 34px;
    background: #fff;
    color: #333;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    padding-bottom: 2px;
    transition: background 0.2s, color 0.2s;
    z-index: 10001;
}

.homepage-popup__close:hover {
    background: #dc2626;
    color: #fff;
}

@media (max-width: 768px) {
    .homepage-popup__close {
        top: 10px;
        right: 10px;
    }
}
