/**
 * Consignment Slide — full-viewport lightbox that slides up from the bottom.
 * Used to present /consignments/form.php in its own iframe (like Strip's
 * upward reveal but with arbitrary HTML content).
 */

.consignment-slide-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 20, 20, 0.55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 100000;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility .35s ease;
    pointer-events: none;
}
.consignment-slide-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* Panel — full-screen, slides up */
.consignment-slide-panel {
    position: fixed;
    left: 0; right: 0;
    bottom: 0;
    top: 0;                                 /* fallback */
    top: max(40px, env(safe-area-inset-top));
    width: 100%;
    background: #ffffff;
    box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.25);
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    z-index: 100001;
    transform: translateY(100%);
    transition: transform .45s cubic-bezier(0.22, 0.61, 0.36, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.consignment-slide-overlay.active .consignment-slide-panel {
    transform: translateY(0);
}

/* Drag indicator at the top (visual affordance) */
.consignment-slide-grab {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 44px;
    height: 4px;
    border-radius: 2px;
    background: rgba(0, 0, 0, 0.18);
    pointer-events: none;
}

/* Close button — top-right, same red-X pattern as enquiry-slide */
.consignment-slide-close {
    position: absolute;
    top: 16px;
    right: 18px;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    transition: transform .3s ease, background .2s ease;
    font-size: 0;
    color: transparent;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}
.consignment-slide-close::before,
.consignment-slide-close::after {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    width: 16px; height: 2px;
    background-color: #e74c3c;
    transition: background-color .2s ease;
}
.consignment-slide-close::before { transform: translate(-50%, -50%) rotate(45deg); }
.consignment-slide-close::after  { transform: translate(-50%, -50%) rotate(-45deg); }
.consignment-slide-close:hover {
    background: #fff;
    transform: rotate(90deg);
}
.consignment-slide-close:hover::before,
.consignment-slide-close:hover::after { background-color: #c0392b; }
.consignment-slide-close:focus { outline: none; }

/* Content area — iframe fills it */
.consignment-slide-content {
    flex: 1 1 auto;
    overflow: hidden;
    background: #f5f2ec;   /* warm off-white behind the frosted form, in case of gaps */
}
.consignment-slide-iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Body-locked scroll while the panel is open */
body.consignment-slide-open {
    overflow: hidden;
}

/* Mobile — panel covers everything, reduce rounded corners */
@media (max-width: 640px) {
    .consignment-slide-panel {
        top: 0;
        border-top-left-radius: 0;
        border-top-right-radius: 0;
    }
    .consignment-slide-grab { display: none; }
    .consignment-slide-close {
        top: 10px;
        right: 10px;
        width: 30px;
        height: 30px;
    }
}
