/*
 * Thihasa Product Enquiry - frontend styles.
 * Everything is scoped to .thihasa-product-enquiry. The :where() wrapper keeps specificity at a single class,
 * so Elementor's Style-tab selectors ({{WRAPPER}} ...) always win and the rest of the site is never affected.
 */
.thihasa-product-enquiry [hidden]{display:none!important}
:where(.thihasa-product-enquiry){box-sizing:border-box;position:static}
:where(.thihasa-product-enquiry) *,:where(.thihasa-product-enquiry) *::before,:where(.thihasa-product-enquiry) *::after{box-sizing:border-box}

/* ---------- CTA ---------- */
:where(.thihasa-product-enquiry) .tpe-cta-wrap{display:block}
:where(.thihasa-product-enquiry) .tpe-cta{display:inline-flex;align-items:center;justify-content:center;gap:10px;margin:0;padding:12px 24px;border:1px solid transparent;border-radius:8px;background-color:#1d4ed8;color:#fff;font:inherit;font-weight:600;line-height:1.2;text-decoration:none;cursor:pointer;appearance:none;-webkit-appearance:none;transition-property:color,background-color,border-color,box-shadow;transition-duration:.2s;transition-timing-function:ease}
:where(.thihasa-product-enquiry) .tpe-cta:hover,:where(.thihasa-product-enquiry) .tpe-cta:focus-visible{background-color:#1e40af;color:#fff}
:where(.thihasa-product-enquiry) .tpe-cta--full{display:flex;width:100%}
:where(.thihasa-product-enquiry) .tpe-cta--icon-after{flex-direction:row-reverse}
:where(.thihasa-product-enquiry) .tpe-cta__icon{display:inline-flex;align-items:center;font-size:18px;line-height:1}
:where(.thihasa-product-enquiry) .tpe-cta__icon svg{width:1em;height:1em;fill:currentColor}
:where(.thihasa-product-enquiry) .tpe-cta__count{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;padding:0 6px;border-radius:999px;background:#fff;color:#1d4ed8;font-size:12px;font-weight:700;line-height:1}

/* ---------- Toolbar ---------- */
:where(.thihasa-product-enquiry) .tpe-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;width:100%}
:where(.thihasa-product-enquiry) .tpe-tabs{display:flex;align-items:center;gap:8px;flex:1 1 auto;min-width:0;overflow-x:auto;scrollbar-width:thin;-webkit-overflow-scrolling:touch}
:where(.thihasa-product-enquiry) .tpe-tab{display:inline-block;flex:0 0 auto;padding:8px 18px;border:1px solid transparent;border-radius:999px;background-color:transparent;color:#374151;font:inherit;font-weight:500;line-height:1.3;text-decoration:none;white-space:nowrap;transition:color .2s ease,background-color .2s ease,border-color .2s ease}
:where(.thihasa-product-enquiry) .tpe-tab:hover{background-color:#eef2ff;color:#1d4ed8}
:where(.thihasa-product-enquiry) .tpe-tab.is-active,:where(.thihasa-product-enquiry) .tpe-tab.is-active:hover{background-color:#1d4ed8;color:#fff}
:where(.thihasa-product-enquiry) .tpe-editor-notice{flex:1 0 100%;margin:0;padding:8px 12px;border-left:3px solid #f59e0b;background:#fffbeb;color:#92400e;font-size:12px}
@media (max-width:767px){
	:where(.thihasa-product-enquiry) .tpe-toolbar{flex-direction:column;align-items:stretch}
	:where(.thihasa-product-enquiry) .tpe-toolbar .tpe-cta{width:100%}
}

/* ---------- Drawer shell ---------- */
html.tpe-scroll-lock{overflow:hidden}
:where(.thihasa-product-enquiry) .tpe-drawer{position:fixed;top:0;right:0;bottom:0;left:0;z-index:99999;visibility:hidden;pointer-events:none;transition:visibility 0s linear var(--tpe-anim,300ms)}
:where(.thihasa-product-enquiry) .tpe-drawer.is-open{visibility:visible;pointer-events:auto;transition-delay:0s}
:where(.thihasa-product-enquiry) .tpe-drawer__overlay{position:absolute;top:0;right:0;bottom:0;left:0;background-color:var(--tpe-overlay-color,#000);opacity:0;transition:opacity var(--tpe-anim,300ms) ease}
:where(.thihasa-product-enquiry) .tpe-drawer.is-open .tpe-drawer__overlay{opacity:var(--tpe-overlay-opacity,.55)}
:where(.thihasa-product-enquiry) .tpe-drawer__panel{position:absolute;top:0;right:0;width:480px;max-width:100%;height:100%;padding:28px;overflow-y:auto;overscroll-behavior:contain;background-color:#fff;color:#111827;box-shadow:-8px 0 30px rgba(0,0,0,.18);transform:translateX(100%);transition:transform var(--tpe-anim,300ms) ease;outline:0}
:where(.thihasa-product-enquiry) .tpe-drawer.is-open .tpe-drawer__panel{transform:none}
/* Editor preview: keep the editing UI usable underneath. */
:where(.thihasa-product-enquiry) .tpe-drawer.is-editor-preview{pointer-events:none}
:where(.thihasa-product-enquiry) .tpe-drawer.is-editor-preview .tpe-drawer__overlay{pointer-events:none}
:where(.thihasa-product-enquiry) .tpe-drawer.is-editor-preview .tpe-drawer__panel{pointer-events:auto}
@media (prefers-reduced-motion:reduce){
	:where(.thihasa-product-enquiry) .tpe-drawer,:where(.thihasa-product-enquiry) .tpe-drawer__overlay,:where(.thihasa-product-enquiry) .tpe-drawer__panel{transition:none}
}

:where(.thihasa-product-enquiry) .tpe-drawer__close{position:absolute;top:14px;right:14px;display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;margin:0;padding:0;border:0;border-radius:50%;background:transparent;color:#374151;font-size:20px;line-height:1;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-drawer__close:hover{background-color:rgba(0,0,0,.06)}
:where(.thihasa-product-enquiry) .tpe-drawer__close svg{width:1em;height:1em;fill:currentColor}
:where(.thihasa-product-enquiry) .tpe-drawer__header{margin:0 0 24px;padding-right:36px}
:where(.thihasa-product-enquiry) .tpe-drawer__title{margin:0 0 8px;font-size:24px;line-height:1.25;color:#111827}
:where(.thihasa-product-enquiry) .tpe-drawer__desc{margin:0;font-size:14px;line-height:1.55;color:#4b5563}

/* ---------- Form layout ---------- */
:where(.thihasa-product-enquiry) .tpe-form{display:flex;flex-direction:column;gap:24px;margin:0}
:where(.thihasa-product-enquiry) .tpe-section{display:flex;flex-direction:column;gap:12px}
:where(.thihasa-product-enquiry) .tpe-section__heading{margin:0;font-size:16px;line-height:1.3;color:#111827}
:where(.thihasa-product-enquiry) .tpe-hp{position:absolute!important;left:-9999px;width:1px;height:1px;overflow:hidden}

/* ---------- Selected products ---------- */
:where(.thihasa-product-enquiry) .tpe-chosen-list{display:flex;flex-direction:column;gap:10px}
:where(.thihasa-product-enquiry) .tpe-chosen{display:flex;flex-wrap:wrap;align-items:center;gap:10px 12px;padding:10px;border:1px solid #e5e7eb;border-radius:10px;background:#fff}
:where(.thihasa-product-enquiry) .tpe-chosen__thumb,:where(.thihasa-product-enquiry) .tpe-product__thumb{flex:0 0 auto;width:48px;height:48px;border-radius:8px;object-fit:cover;background:#f3f4f6}
:where(.thihasa-product-enquiry) .tpe-chosen__name{flex:1 1 140px;min-width:0;font-size:14px;font-weight:500;line-height:1.35;color:#111827;word-break:break-word}
:where(.thihasa-product-enquiry) .tpe-chosen__remove{flex:0 0 auto;padding:4px 6px;border:0;background:transparent;color:#6b7280;font-size:18px;line-height:1;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-chosen__remove:hover{color:#b91c1c;background:transparent}
:where(.thihasa-product-enquiry) .tpe-empty{margin:0;padding:14px;border:1px dashed #d1d5db;border-radius:10px;color:#6b7280;font-size:14px;text-align:center}

/* ---------- Quantity ---------- */
:where(.thihasa-product-enquiry) .tpe-qty{display:inline-flex;align-items:center;gap:4px}
:where(.thihasa-product-enquiry) .tpe-qty__btn{display:inline-flex;align-items:center;justify-content:center;width:34px;height:36px;margin:0;padding:0;border:1px solid #d1d5db;border-radius:6px;background:#f9fafb;color:#111827;font-size:18px;line-height:1;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-qty__btn:hover{background:#e5e7eb;color:#111827}
:where(.thihasa-product-enquiry) .tpe-qty__input{width:64px;height:36px;margin:0;padding:0 6px;border:1px solid #d1d5db;border-radius:6px;background:#fff;color:#111827;font:inherit;font-size:14px;text-align:center;appearance:textfield;-moz-appearance:textfield}
:where(.thihasa-product-enquiry) .tpe-qty__input::-webkit-outer-spin-button,:where(.thihasa-product-enquiry) .tpe-qty__input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
:where(.thihasa-product-enquiry) .tpe-qty__error{flex:1 0 100%;margin:0;font-size:12px;line-height:1.4;color:#b91c1c}
:where(.thihasa-product-enquiry) .tpe-qty__input.is-invalid{border-color:#b91c1c}

/* ---------- Add / selector ---------- */
:where(.thihasa-product-enquiry) .tpe-add{display:inline-flex;align-items:center;justify-content:center;gap:8px;align-self:flex-start;margin:0;padding:10px 16px;border:1px dashed currentColor;border-radius:8px;background:transparent;color:#1d4ed8;font:inherit;font-size:14px;font-weight:600;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-add:hover{background-color:rgba(29,78,216,.08);color:#1d4ed8}
:where(.thihasa-product-enquiry) .tpe-add__icon{display:inline-flex;font-size:16px;line-height:1}
:where(.thihasa-product-enquiry) .tpe-add__icon svg{width:1em;height:1em;fill:currentColor}
:where(.thihasa-product-enquiry) .tpe-selector{display:flex;flex-direction:column;gap:10px;padding:12px;border:1px solid #e5e7eb;border-radius:10px;background:#fff}
:where(.thihasa-product-enquiry) .tpe-search{width:100%;margin:0;padding:10px 12px;border:1px solid #d1d5db;border-radius:8px;background:#fff;color:#111827;font:inherit;font-size:14px}
:where(.thihasa-product-enquiry) .tpe-selector__status{margin:0;color:#6b7280;font-size:13px}
:where(.thihasa-product-enquiry) .tpe-selector__list{display:flex;flex-direction:column;gap:6px;max-height:260px;margin:0;padding:0;overflow-y:auto;list-style:none}
:where(.thihasa-product-enquiry) .tpe-selector__list li{margin:0;padding:0;list-style:none}
:where(.thihasa-product-enquiry) .tpe-product{display:flex;align-items:center;gap:12px;width:100%;margin:0;padding:8px;border:1px solid transparent;border-radius:8px;background:transparent;color:#111827;font:inherit;text-align:left;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-product:hover{background-color:#f3f4f6;color:#111827}
:where(.thihasa-product-enquiry) .tpe-product.is-selected{background-color:#eef2ff;border-color:#c7d2fe}
:where(.thihasa-product-enquiry) .tpe-product__name{flex:1 1 auto;min-width:0;font-size:14px;line-height:1.35;color:#111827}
:where(.thihasa-product-enquiry) .tpe-product__add{flex:0 0 auto;display:inline-flex;font-size:18px;line-height:1;color:#1d4ed8}
:where(.thihasa-product-enquiry) .tpe-product__add svg{width:1em;height:1em;fill:currentColor}
:where(.thihasa-product-enquiry) .tpe-product.is-selected .tpe-product__add{transform:rotate(45deg)}
:where(.thihasa-product-enquiry) .tpe-summary{display:flex;flex-wrap:wrap;gap:6px 18px;font-size:13px;color:#4b5563}

/* ---------- Fields ---------- */
:where(.thihasa-product-enquiry) .tpe-section--details{display:flex;flex-direction:column;gap:16px}
:where(.thihasa-product-enquiry) .tpe-field{display:flex;flex-direction:column;gap:6px}
:where(.thihasa-product-enquiry) .tpe-field__label{font-size:14px;font-weight:500;color:#111827}
:where(.thihasa-product-enquiry) .tpe-req{color:#b91c1c}
:where(.thihasa-product-enquiry) .tpe-field__input{width:100%;margin:0;padding:11px 12px;border:1px solid #d1d5db;border-radius:8px;background:#fff;color:#111827;font:inherit;font-size:14px;line-height:1.4}
:where(.thihasa-product-enquiry) .tpe-field__textarea{min-height:100px;resize:vertical}
:where(.thihasa-product-enquiry) .tpe-field__input:focus,:where(.thihasa-product-enquiry) .tpe-search:focus{border-color:#1d4ed8;outline:0;box-shadow:0 0 0 2px rgba(29,78,216,.15)}
:where(.thihasa-product-enquiry) .tpe-field__input.is-invalid{border-color:#b91c1c}
:where(.thihasa-product-enquiry) .tpe-field__error,:where(.thihasa-product-enquiry) .tpe-form__error{margin:0;font-size:13px;line-height:1.4;color:#b91c1c}

/* ---------- Place order ---------- */
:where(.thihasa-product-enquiry) .tpe-submit{display:inline-flex;align-items:center;justify-content:center;gap:10px;width:100%;margin:0;padding:14px 24px;border:1px solid transparent;border-radius:8px;background-color:#1d4ed8;color:#fff;font:inherit;font-weight:600;cursor:pointer;appearance:none;-webkit-appearance:none;transition:background-color .2s ease,color .2s ease,opacity .2s ease}
:where(.thihasa-product-enquiry) .tpe-submit:hover:not(:disabled){background-color:#1e40af;color:#fff}
:where(.thihasa-product-enquiry) .tpe-submit:disabled{opacity:.55;cursor:not-allowed}
:where(.thihasa-product-enquiry) .tpe-submit.is-loading{cursor:progress}
:where(.thihasa-product-enquiry) .tpe-submit.is-loading::after{content:"";width:16px;height:16px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:tpe-spin .7s linear infinite}
@keyframes tpe-spin{to{transform:rotate(360deg)}}

/* ---------- Success ---------- */
:where(.thihasa-product-enquiry) .tpe-success{display:flex;flex-direction:column;align-items:stretch;gap:12px;padding:40px 8px;text-align:center}
:where(.thihasa-product-enquiry) .tpe-success__icon{font-size:72px;line-height:1;color:#16a34a}
:where(.thihasa-product-enquiry) .tpe-success__icon svg{width:1em;height:1em;fill:currentColor}
:where(.thihasa-product-enquiry) .tpe-success__title{margin:0;font-size:26px;line-height:1.25;color:#111827}
:where(.thihasa-product-enquiry) .tpe-success__text{margin:0;font-size:15px;line-height:1.55;color:#4b5563}
:where(.thihasa-product-enquiry) .tpe-continue{align-self:center;margin:12px 0 0;padding:12px 24px;border:1px solid transparent;border-radius:8px;background-color:#1d4ed8;color:#fff;font:inherit;font-weight:600;cursor:pointer;appearance:none;-webkit-appearance:none}
:where(.thihasa-product-enquiry) .tpe-continue:hover{background-color:#1e40af;color:#fff}

@media (max-width:480px){
	:where(.thihasa-product-enquiry) .tpe-drawer__panel{padding:20px}
}

/* Product Quick View Icon */

.thihasa-product-enquiry .tpe-product-row {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
    list-style: none !important;
}

.thihasa-product-enquiry .tpe-product-row > .tpe-product {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    width: auto !important;
}

.thihasa-product-enquiry .tpe-product-row > .tpe-quick-view {
    position: static !important;
    transform: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 36px !important;
    width: 36px !important;
    height: 36px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #8b103b !important;
    visibility: visible !important;
    opacity: 1 !important;
    cursor: pointer !important;
}

.thihasa-product-enquiry .tpe-quick-view svg {
    display: block !important;
    width: 20px !important;
    height: 20px !important;
    stroke: #8b103b !important;
    fill: none !important;
}

.thihasa-product-enquiry .tpe-quick-view:hover {
    color: #cc2c60 !important;
}


/* =========================================
   CENTER SCREEN PRODUCT POPUP
========================================= */

#tpe-product-popup {
    position: fixed;
    inset: 0;
    margin: auto;
    width: 720px;
    max-width: calc(100vw - 32px);
    max-height: 85vh;
    padding: 0;
    border: none;
    border-radius: 12px;
    background: #faf0eb;
    color: #161616;
    overflow-y: auto;
    overscroll-behavior: contain;
    box-sizing: border-box;
    box-shadow: 0 15px 60px rgba(0, 0, 0, 0.25);
}

#tpe-product-popup::backdrop {
    background: rgba(0, 0, 0, 0.65);
}

#tpe-product-popup .tpe-popup-content {
    position: relative;
    padding: 45px;
}

#tpe-product-popup .tpe-popup-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: #8b103b;
    color: #ffffff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

#tpe-product-popup #tpe-popup-title {
    margin: 0 30px 20px 0;
    color: #8b103b;
    font-family: Georgia, serif;
    font-size: 40px;
    font-weight: 400;
    line-height: 1.2;
}


/* Decorative divider */

#tpe-product-popup .tpe-popup-divider {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 28px;
}

#tpe-product-popup .tpe-popup-divider::before,
#tpe-product-popup .tpe-popup-divider::after {
    content: "";
    display: block;
    width: 45px;
    height: 3px;
    background: #8b103b;
}

#tpe-product-popup .tpe-popup-divider span {
    width: 10px;
    height: 10px;
    background: #8b103b;
    transform: rotate(45deg);
}


/* Product details */

#tpe-product-popup .tpe-popup-field {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 17px;
    line-height: 1.65;
}

#tpe-product-popup .tpe-popup-field strong {
    color: #111111;
    font-family: Georgia, serif;
    font-size: 19px;
    font-weight: 600;
}

#tpe-product-popup .tpe-popup-field span {
    color: #252525;
    overflow-wrap: anywhere;
    white-space: pre-line;
}

#tpe-product-popup .tpe-popup-field.is-block {
    display: block;
}

#tpe-product-popup .tpe-popup-field.is-block strong {
    display: block;
    margin-bottom: 8px;
}

#tpe-product-popup .tpe-popup-field.is-block span {
    display: block;
}


/* Mobile responsive */

@media (max-width: 767px) {

    #tpe-product-popup {
        width: calc(100vw - 24px);
        max-height: 85vh;
        border-radius: 10px;
    }

    #tpe-product-popup .tpe-popup-content {
        padding: 30px 22px;
    }

    #tpe-product-popup #tpe-popup-title {
        font-size: 28px;
    }

    #tpe-product-popup .tpe-popup-field {
        font-size: 15px;
        margin-bottom: 16px;
    }

    #tpe-product-popup .tpe-popup-field strong {
        font-size: 17px;
    }

}
