/* =============================================================
   WC Enquiry Popup  –  popup.css
   ============================================================= */

body.wcep-no-scroll { overflow: hidden !important; }

:root {
    --wcep-accent:     #00a99d;
    --wcep-btn-text:   #ffffff;
    --wcep-hover-bg:   #008f84;
    --wcep-hover-text: #ffffff;
}

/* ── Overlay ── */
.wcep-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.58);
    z-index: 999990;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

/* ── Popup card ── */
.wcep-popup {
    position: relative;
    background: #fff;
    border-radius: 12px;
    display: flex;
    flex-direction: row;
    width: 100%;
    max-width: 860px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 16px 56px rgba(0,0,0,.28);
    animation: wcep-rise .22s ease;
}
@keyframes wcep-rise {
    from { transform: translateY(18px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

/* ── Close ── */
.wcep-close {
    position: absolute;
    top: 10px; right: 12px;
    z-index: 20;
    background: rgba(0,0,0,.07);
    border: none;
    width: 30px; height: 30px;
    border-radius: 50%;
    font-size: 15px;
    color: #444;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background .15s;
    line-height: 1;
}
.wcep-close:hover { background: rgba(0,0,0,.16); color: #111; }

/* ══════════════════════════════════════
   LEFT PANEL  –  desktop product details
   ══════════════════════════════════════ */
.wcep-left {
    width: 40%;
    flex-shrink: 0;
    background: #f6f7f9;
    border-right: 1px solid #e5e7eb;
    padding: 26px 20px 24px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Image */
.wcep-thumb-wrap {
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #e0e3e8;
    line-height: 0;
}
.wcep-thumb-img {
    width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: contain;
    display: block;
    padding: 8px;
    box-sizing: border-box;
}

/* Product name */
.wcep-product-name {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    margin: 4px 0 0 !important;
    padding: 0 !important;
    line-height: 1.35 !important;
    display: block !important;
    visibility: visible !important;
}

/* Price */
.wcep-price {
    font-size: 22px !important;
    font-weight: 700 !important;
    color: var(--wcep-accent) !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.25 !important;
    display: block !important;
    visibility: visible !important;
}
.wcep-price ins  { text-decoration: none; }
.wcep-price del  { font-size: 13px; color: #bbb; font-weight: 400; margin-left: 5px; }
/* WooCommerce wraps prices in <bdi> – ensure it's inline */
.wcep-price bdi  { font-style: normal; }
.wcep-price .woocommerce-Price-amount { color: var(--wcep-accent) !important; }

/* Attributes list */
.wcep-meta { list-style: none; margin: 2px 0 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
.wcep-meta li        { font-size: 12.5px; color: #555; line-height: 1.45; }
.wcep-meta li strong { color: #222; font-weight: 600; margin-right: 3px; }

/* Short description */
.wcep-desc       { font-size: 12.5px; color: #666; line-height: 1.65; }
.wcep-desc p     { margin: 0 0 5px; }

/* ══════════════════════════════════════
   RIGHT PANEL  –  heading + form
   ══════════════════════════════════════ */
.wcep-right {
    flex: 1;
    min-width: 0;
    padding: 28px 24px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.wcep-popup-heading {
    font-size: 17px;
    font-weight: 700;
    color: #111;
    margin: 0 0 4px;
    padding-right: 32px;
    line-height: 1.35;
}

/* Mobile strip – shown only on mobile via media query */
.wcep-mobile-strip {
    display: none; /* hidden on desktop */
    background: #f6f7f9;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 14px;
    flex-direction: column;
    gap: 4px;
}
.wcep-mobile-name  {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}
.wcep-mobile-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--wcep-accent);
    line-height: 1.2;
}
.wcep-mobile-price ins { text-decoration: none; }
.wcep-mobile-price del { font-size: 12px; color: #bbb; font-weight: 400; margin-left: 4px; }
.wcep-mobile-price .woocommerce-Price-amount { color: var(--wcep-accent) !important; }

.wcep-form-wrap  { flex: 1; margin-top: 12px; }
.wcep-loading    { display: block; text-align: center; color: #999; padding: 40px 0; font-size: 14px; }
.wcep-error      { color: #c00; font-size: 14px; padding: 6px 0; }
.wcep-no-form    { background: #fff8e1; border: 1px solid #ffe082; border-radius: 6px; padding: 14px 16px; font-size: 13.5px; color: #555; }

/* ══════════════════════════════════════
   ENQUIRE NOW BUTTON (product page / loop)
   ══════════════════════════════════════ */
.wcep-btn-wrap { margin-top: 10px; }

.wcep-enquire-btn.button,
.wcep-enquire-btn.button.alt {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    background-color: var(--wcep-accent) !important;
    color: var(--wcep-btn-text) !important;
    border: 2px solid var(--wcep-accent) !important;
    border-radius: 6px;
    padding: 13px 26px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .18s, color .18s, border-color .18s;
    text-decoration: none !important;
    box-shadow: none !important;
    width: auto;
}
.wcep-enquire-btn.button:hover,
.wcep-enquire-btn.button.alt:hover {
    background-color: var(--wcep-hover-bg) !important;
    color: var(--wcep-hover-text) !important;
    border-color: var(--wcep-hover-bg) !important;
}

/* ══════════════════════════════════════
   ELEMENTOR FORM OVERRIDES
   ══════════════════════════════════════ */
.wcep-form-wrap .elementor-widget-container  { padding: 0 !important; }
.wcep-form-wrap .elementor-field-group       { margin-bottom: 12px !important; }
.wcep-form-wrap .elementor-field-label       { font-size: 13px !important; font-weight: 600 !important; color: #333 !important; }

.wcep-form-wrap .elementor-field-textual,
.wcep-form-wrap .elementor-field-select,
.wcep-form-wrap textarea.elementor-field {
    border: 1px solid #d5d8dc !important;
    border-radius: 6px !important;
    padding: 10px 13px !important;
    font-size: 13.5px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    background: #fff !important;
    transition: border-color .15s, box-shadow .15s !important;
}
.wcep-form-wrap .elementor-field-textual:focus,
.wcep-form-wrap textarea.elementor-field:focus {
    border-color: var(--wcep-accent) !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(0,169,157,.15) !important;
}
.wcep-form-wrap .elementor-button {
    background-color: var(--wcep-accent) !important;
    color: var(--wcep-btn-text) !important;
    border: none !important;
    border-radius: 6px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    padding: 12px 22px !important;
    width: 100% !important;
    cursor: pointer !important;
    transition: filter .18s !important;
}
.wcep-form-wrap .elementor-button:hover { filter: brightness(1.1) !important; }
/* Hide Elementor hidden fields from layout */
.wcep-form-wrap .elementor-field-type-hidden { display: none !important; }

/* ══════════════════════════════════════
   RESPONSIVE – ≤ 660px: mobile bottom sheet
   Left panel hidden; mobile strip visible
   ══════════════════════════════════════ */
@media (max-width: 660px) {

    .wcep-overlay {
        padding: 0;
        align-items: flex-end;
    }

    .wcep-popup {
        flex-direction: column;
        max-width: 100%;
        width: 100%;
        max-height: 92vh;
        border-radius: 16px 16px 0 0;
        animation: wcep-slide-up .24s ease;
    }
    @keyframes wcep-slide-up {
        from { transform: translateY(100%); }
        to   { transform: translateY(0); }
    }

    /* Hide entire left panel on mobile */
    .wcep-left { display: none !important; }

    /* Show mobile name+price strip */
    .wcep-mobile-strip { display: flex !important; }

    .wcep-right {
        padding: 20px 18px 30px;
        max-height: 92vh;
        overflow-y: auto;
    }

    .wcep-popup-heading { font-size: 15px; padding-right: 36px; }

    .wcep-form-wrap { margin-top: 0; }
}

/* Medium – tighten padding */
@media (max-width: 860px) and (min-width: 661px) {
    .wcep-popup  { max-width: 96vw; }
    .wcep-left   { width: 38%; padding: 20px 16px 20px 18px; }
    .wcep-right  { padding: 22px 18px 20px; }
}
