/**
 * Donation Modal Popup
 * Всплывающее окно для пожертвований
 */

/* Modal Base Styles */
.modal-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-popup.active {
    opacity: 1;
    visibility: visible;
}

.modal-popup__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.modal-popup__container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 592px;
    height: 494px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.modal-popup.active .modal-popup__container {
    transform: translate(-50%, -50%) scale(1);
}

.modal-popup__content {
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Close Button */
.modal-popup__close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    color: #6b7280;
    transition: all 0.2s ease;
    z-index: 10;
}

.modal-popup__close:hover {
    background: #f3f4f6;
    color: #374151;
}

.modal-popup__close svg {
    width: 20px;
    height: 20px;
}

/* First Container */
.modal-popup__first-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px;
    padding-bottom: 32px;
}

.modal-popup__image {
    width: 154px;
    height: 160px;
    margin-bottom: 12px;
}

.modal-popup__title {
    color: #303030;
    margin: 0 0 16px 0;
    font-family: 'Source Sans 3';
}

.modal-popup__subtitle {
    color: #4D4D4D;
    margin: 0;
    line-height: 20px;
}

/* Second Container */
.modal-popup__second-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.modal-popup__donate-button {
    width: 100%;
    max-width: 400px;
    padding: 16px;
    background: #8FB56C;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 16px;
    color: white;
}

.modal-popup__donate-button:hover {
    background: #7a9f5a;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(143, 181, 108, 0.3);
}

.modal-popup__footer-text {
    font-size: 12px;
    color: #4D4D4D;
    margin: 0 0 24px 0;
    text-align: center;
}

/* Responsive Design */
@media (max-width: 640px) {
    .modal-popup__container {
        width: 95%;
        height: auto;
        max-height: 90vh;
        margin: 16px;
    }
    
    .modal-popup__first-container {
        padding: 24px 20px;
    }
    
    .modal-popup__image {
        width: 120px;
        height: 124px;
        margin-bottom: 16px;
    }
    
    .modal-popup__title {
        font-size: 20px;
    }
    
    .modal-popup__subtitle {
        font-size: 14px;
    }
    
    .modal-popup__second-container {
        padding: 24px 20px 32px;
    }
    
    .modal-popup__donate-button {
        max-width: 100%;
    }
}

/* Animation for modal appearance */
@keyframes modalSlideIn {
    from {
        transform: translate(-50%, -50%) scale(0.9);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}
