/* =====================================
   BLOOMSERVE POPUP (ENHANCED FLUENT UI)
===================================== */

.popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    display: none;          /* Default hidden */
    justify-content: center;
    align-items: center;

    padding: 20px;
    overflow-y: auto;

    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 99999;
}

.popup-overlay.active {
    display: flex;
    opacity: 1;
    visibility: visible;
}

.popup-box {
    width: 100%;
    max-width: 540px;
    max-height: 92vh;
    overflow-y: auto;

    background: #ffffff;
    border-radius: 22px;
    padding: 34px 30px 28px;
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);

    position: relative;
    animation: popup 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-sizing: border-box;
}

@keyframes popup {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Custom Modal Scrollbar */
.popup-box::-webkit-scrollbar {
    width: 5px;
}
.popup-box::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.popup-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.25s ease;
}

.popup-close:hover {
    color: #0f172a;
    background: #e2e8f0;
    transform: rotate(90deg);
}

.popup-box h2 {
    margin: 0 0 6px;
    font-size: 26px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.5px;
}

.popup-box p {
    margin-bottom: 20px;
    color: #64748b;
    font-size: 14px;
    line-height: 1.5;
}

.popup-form .form-group {
    margin-bottom: 12px;
}

.popup-form input,
.popup-form select,
.popup-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    background: #f8fafc;
    font-size: 14.5px;
    font-family: inherit;
    color: #0f172a;
    outline: none;
    transition: all 0.25s ease;
    box-sizing: border-box;
}

.popup-form input::placeholder,
.popup-form textarea::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.popup-form select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: calc(100% - 16px) center;
    cursor: pointer;
}

.popup-form input:focus,
.popup-form select:focus,
.popup-form textarea:focus {
    background: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
}

.popup-form textarea {
    resize: vertical;
    min-height: 85px;
}

/* Matching Radiant Gradient Button */
.popup-submit {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, #38bdf8 0%, #3b82f6 50%, #6366f1 100%);
    color: #ffffff;
    font-size: 15.5px;
    font-weight: 700;
    letter-spacing: -0.2px;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(99, 102, 241, 0.35);
    transition: all 0.25s ease;
    margin-top: 6px;
    font-family: inherit;
}

.popup-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(99, 102, 241, 0.48);
}

.popup-submit:active {
    transform: translateY(0);
}

.popup-success {
    display: none;
    text-align: center;
    padding: 30px 10px;
}

.popup-success h3 {
    font-size: 26px;
    font-weight: 800;
    color: #0b86d5;
    margin-bottom: 10px;
}

.popup-success p {
    color: #64748b;
    font-size: 15px;
    line-height: 1.5;
}

/* Mobile Friendly */
@media (max-width: 480px) {
    .popup-box {
        padding: 26px 18px 22px;
        border-radius: 18px;
    }

    .popup-box h2 {
        font-size: 22px;
    }

    .popup-box p {
        font-size: 13.5px;
        margin-bottom: 16px;
    }

    .popup-form input,
    .popup-form select,
    .popup-form textarea {
        padding: 11px 14px;
        font-size: 14px;
    }
}