/* ============================================
   NEXFORM SINGLE PRODUCT — CUSTOM STYLES
   Compatible with Bootstrap 5 CSS only.
   ============================================ */

/* ---------- Thumbnails ---------- */
.nexform-thumb-btn {
    transition: opacity .2s ease, border-color .2s ease;
}
.nexform-thumb-btn:hover {
    opacity: .8;
}
.nexform-thumb-btn.border-warning {
    border-color: #f97316 !important;
}

/* Hide scrollbar but keep functionality */
#nexform-thumb-list {
    scrollbar-width: thin;
    scrollbar-color: #ddd transparent;
}
#nexform-thumb-list::-webkit-scrollbar {
    width: 4px;
}
#nexform-thumb-list::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 4px;
}

/* ---------- Main image cursor ---------- */
#nexform-main-img-wrap {
    cursor: zoom-in;
}

/* ---------- Custom Modal (no Bootstrap JS) ---------- */
.nexform-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1050;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.nexform-modal.active {
    display: flex;
}

/* Backdrop overlay */
.nexform-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.55);
    opacity: 0;
    transition: opacity .3s ease;
}
.nexform-modal.active .nexform-modal-backdrop {
    opacity: 1;
}

/* Dialog box */
.nexform-modal-dialog {
    position: relative;
    width: 100%;
    max-width: 500px;
    z-index: 2;
    transform: translateY(-20px);
    opacity: 0;
    transition: transform .3s ease, opacity .3s ease;
}
.nexform-modal.active .nexform-modal-dialog {
    transform: translateY(0);
    opacity: 1;
}

/* Modal content card */
.nexform-modal-content {
    background: #fff;
    box-shadow: 0 20px 60px rgba(0,0,0,.2);
}

/* Close button */
.nexform-modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    width: 36px;
    height: 36px;
    border: none;
    background: #f3f4f6;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s, color .2s;
}
.nexform-modal-close:hover {
    background: #e5e7eb;
    color: #000;
}

/* ---------- Contact Form 7 inside modal ---------- */
#nexform-cf7-wrap .wpcf7-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
#nexform-cf7-wrap .wpcf7-form label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    display: block;
}
#nexform-cf7-wrap .wpcf7-form input:not([type="submit"]),
#nexform-cf7-wrap .wpcf7-form textarea,
#nexform-cf7-wrap .wpcf7-form select {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    background: #fafafa;
    transition: border-color .2s, background .2s;
}
#nexform-cf7-wrap .wpcf7-form input:focus,
#nexform-cf7-wrap .wpcf7-form textarea:focus {
    outline: none;
    border-color: #f97316;
    background: #fff;
}
#nexform-cf7-wrap .wpcf7-submit {
    width: 100%;
    padding: 12px;
    background: #f97316;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    transition: background .2s;
}
#nexform-cf7-wrap .wpcf7-submit:hover {
    background: #ea580c;
}

/* ---------- Lightbox ---------- */
.nexform-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1100;
    background: rgba(0,0,0,0.9);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    cursor: zoom-out;
}
.nexform-lightbox.active {
    display: flex;
}
.nexform-lightbox img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
    animation: lightboxZoom .3s ease;
}
@keyframes lightboxZoom {
    from { transform: scale(.9); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}
.nexform-lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    background: none;
    border: none;
    color: #fff;
    font-size: 40px;
    line-height: 1;
    cursor: pointer;
    opacity: .8;
    transition: opacity .2s;
}
.nexform-lightbox-close:hover {
    opacity: 1;
}

/* ---------- Responsive thumbnails ---------- */
@media (max-width: 991px) {
    #nexform-thumb-list {
        flex-direction: row !important;
        width: 100% !important;
        max-height: none !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
    }
}