
    .custom-popup-modal .modal-dialog {
        max-width: 440px;
        margin: 16px auto;
        padding: 0 12px;
    }

    .custom-popup-modal .modal-content {
        background: #ffffff;
        border-radius: 20px;
        overflow: hidden;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
        border: 1px solid rgba(255, 255, 255, 0.2);
        position: relative;
        padding: 0;
        animation: popup-zoom-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    }

    .dark-mode .custom-popup-modal .modal-content {
        background: #1e1b4b;
        color: #ffffff;
        border-color: rgba(255, 255, 255, 0.1);
    }

    @keyframes popup-zoom-in {
        from { transform: scale(0.9); opacity: 0; }
        to { transform: scale(1); opacity: 1; }
    }

    /* Floating Close Button Overlay */
    .custom-popup-modal .popup-close-btn {
        position: absolute;
        top: 12px; right: 12px;
        z-index: 100;
        width: 34px; height: 34px;
        border-radius: 50%;
        background: rgba(15, 23, 42, 0.75);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        color: #ffffff;
        border: 2px solid rgba(255, 255, 255, 0.8);
        display: flex; align-items: center; justify-content: center;
        cursor: pointer;
        font-size: 14px;
        transition: all 0.2s ease;
        box-shadow: 0 4px 14px rgba(0,0,0,0.35);
        padding: 0;
        line-height: 1;
    }

    .custom-popup-modal .popup-close-btn:hover {
        transform: scale(1.1) rotate(90deg);
        background: #ef4444;
        border-color: #ffffff;
    }

    .custom-popup-modal .modal-body {
        padding: 0 0 20px 0;
    }

    /* Image Styling — Responsive & Constrained Height */
    .popup-img-wrap {
        width: 100%;
        max-height: 55vh;
        overflow: hidden;
        background: #0f172a;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .popup-img {
        width: 100%;
        max-height: 55vh;
        object-fit: contain;
        display: block;
        transition: transform 0.3s ease;
    }

    .popup-img:hover {
        transform: scale(1.02);
    }

    /* Content Styling */
    .popup-text {
        padding: 16px 20px 8px;
        font-size: 0.92rem;
        line-height: 1.6;
        color: #334155;
        font-weight: 600;
        text-align: center;
    }

    .dark-mode .popup-text {
        color: #cbd5e1;
    }

    .popup-text p {
        margin-bottom: 8px;
    }

    .popup-text p:last-child {
        margin-bottom: 0;
    }

    .popup-text img {
        max-width: 100%;
        height: auto;
        border-radius: 10px;
        margin: 10px 0;
    }

    /* Action Button Wrap */
    .popup-btn-wrap {
        padding: 8px 20px 0;
    }

    .popup-action-btn {
        width: 100%;
        height: 46px;
        border-radius: 12px;
        font-weight: 800;
        font-size: 0.85rem;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        display: flex;
        align-items: center;
        justify-content: center;
        background: linear-gradient(135deg, var(--theme-color, #6366f1), #a855f7);
        color: #ffffff !important;
        text-decoration: none !important;
        border: none;
        box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
        transition: all 0.2s;
    }

    .popup-action-btn:hover {
        transform: translateY(-2px);
        filter: brightness(1.1);
    }
