/* Arabic-only typography, reading direction and mixed-script isolation. */
html[lang="ar"] body{font-family:Tahoma,Arial,"Geeza Pro",sans-serif;letter-spacing:normal;}
html[lang="ar"] :is(button,input,textarea,select){font-family:inherit;letter-spacing:normal;}
html[lang="ar"] :is(.product-copy,.detail-info-line,.detail-remark,.item-copy,.quote-note,.quote-note-content){direction:rtl;text-align:start;unicode-bidi:plaintext;line-height:1.65;}
html[lang="ar"] :is(.product-copy>strong,.item-sku,.price-value,.price-line,.quote-header-date,.quote-customer-name){direction:ltr;unicode-bidi:isolate;}
html[lang="ar"] .product-copy>strong{display:inline-block;}
html[lang="ar"] :is(.access-address,.store-address,.contact-address){unicode-bidi:plaintext;line-height:1.6;}
html[lang="ar"] :is(.access-card,.brand-mark-block,.wechat-card){text-align:center;}
html[lang="ar"] :is(.search,.search-wrap,.quote-item,.cart-item){direction:rtl;}
html[lang="ar"] :is(input[type=search],#customerAccessInput){text-align:start;unicode-bidi:plaintext;}
html[lang="ar"] :is(.detail-note-cn:empty,.mobile-hide-cn){display:none!important;}
html[lang="ar"] .cart-quote-image-sheet{direction:rtl;}
html[lang="ar"] .cart-quote-description{text-align:start;}
html[lang="ar"] .cart-quote-description>strong{direction:ltr;unicode-bidi:isolate;text-align:start;}
html[lang="ar"] .cart-quote-price{direction:ltr;unicode-bidi:isolate;}
html[lang="ar"] .cart-quote-image-sheet header>span{text-align:end;}
html[lang="ar"] :is(.quote-btn-lines,.quote-heading-translation){line-height:1.6;}

/* v15.23: Arabic quote layout; share data and actions with other languages. */
html[lang="ar"] .quote-shell .quote-info{direction:rtl;text-align:right;justify-items:stretch;}
html[lang="ar"] .quote-shell .quote-info .item-sku{direction:ltr;unicode-bidi:isolate;text-align:right;justify-self:stretch;}
html[lang="ar"] .quote-shell .customer-order-toggle{text-align:right;}
html[lang="ar"] .quote-shell .quote-group>.quote-section-title{direction:rtl;}
html[lang="ar"] .quote-shell .quote-group>.quote-section-title #quotePrintSelect,
html[lang="ar"] .quote-shell #pendingSection>.quote-section-title #pendingPrintSelect{margin-left:0!important;margin-right:auto!important;top:0!important;flex-shrink:0;}
html[lang="ar"] .quote-shell .pending-group #submitQuoteBtn{margin-left:0!important;margin-right:12px!important;}
html[lang="ar"] .quote-welcome-footer{direction:rtl;line-height:1.7;}

/* v15.24: Arabic gallery and dialog alignment, including legacy physical margins. */
html[lang="ar"] #customerContent>.store-info .store-address{display:flex!important;direction:rtl;justify-content:flex-start!important;align-items:center;gap:10px;}
html[lang="ar"] #customerContent>.store-info .address-copy-btn{direction:rtl!important;unicode-bidi:plaintext;text-align:right!important;flex:0 1 auto!important;width:auto!important;margin:0!important;}
html[lang="ar"] #customerContent>.store-info .map-marker{flex:none;margin:0!important;}
html[lang="ar"] .product-copy>strong{display:block;direction:ltr;text-align:right!important;unicode-bidi:isolate;}
html[lang="ar"] :is(.product-copy,.group-product-copy,.detail-info-line){text-align:right!important;}
html[lang="ar"] .new-product-badge{background:#e52b28!important;background-image:none!important;color:white!important;text-indent:0!important;display:flex!important;align-items:center;justify-content:center;width:42px!important;height:25px!important;border-radius:0 0 0 8px;font:700 12px/1.4 Tahoma,Arial,sans-serif!important;animation:none!important;filter:none!important;}
html[lang="ar"] .new-product-badge::after{display:none!important;}
html[lang="ar"] .detail-image-stage.is-loading::before{content:"جارٍ تحميل الصورة…";}
html[lang="ar"] :is(.quote-heading-translation,.quote-header-count-en){display:none!important;}
@media(max-width:780px){html[lang="ar"] #customerContent>.store-info .store-address{display:block!important;}html[lang="ar"] #customerContent>.store-info .address-copy-btn{width:100%!important;}}

html[lang="ar"] :is(.quote-switch .cart-open-btn,.quote-list-row-btn)::after{content:"جديد";}
html[lang="ar"] .pending-group .quote-item.is-return-target .quote-info::after{content:"تم طلب عرض السعر";}
html[lang="ar"] .submitted-group .quote-item.is-return-target .quote-info::after{content:"تم التسعير";}
html[lang="ar"] :is(.detail-sku,#detailSku,.history-product-copy strong){direction:ltr;unicode-bidi:isolate;text-align:right!important;}

/* v15.25: Arabic quote preview and captured/PDF sheets share bounded columns. */
html[lang="ar"] .cart-quote-image-sheet .cart-quote-description{direction:rtl;text-align:right!important;align-items:stretch;min-width:0;}
html[lang="ar"] .cart-quote-image-sheet .cart-quote-description>strong{direction:ltr;unicode-bidi:isolate;text-align:right!important;width:100%;box-sizing:border-box;}
html[lang="ar"] .cart-quote-image-sheet .cart-quote-price{direction:ltr;unicode-bidi:isolate;display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:0;max-width:100%;white-space:normal!important;overflow-wrap:anywhere;}
html[lang="ar"] .cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{position:static!important;inset:auto!important;transform:none!important;display:block!important;margin:0!important;max-width:100%;line-height:1.3;white-space:nowrap;}
html[lang="ar"] .cart-quote-image-sheet :is(.cart-quote-image-columns,.cart-quote-image-row){direction:rtl;min-width:0;box-sizing:border-box;}
html[lang="ar"] .cart-quote-image-sheet .cart-quote-image-columns>span:nth-child(2){text-align:right;}
html[lang="ar"] .cart-quote-image-dialog>.cart-quote-image-sheet header .quote-header-count{display:block!important;direction:rtl;text-align:left;}
html[lang="ar"] .cart-quote-image-dialog>.cart-quote-image-sheet header .quote-header-count-en{display:none!important;}

/* v15.26: mirror original inline brand/amount order without absolute overflow. */
html[lang="ar"] .cart-quote-image-sheet .cart-quote-price{flex-direction:row-reverse!important;flex-wrap:nowrap;gap:7px;white-space:nowrap!important;overflow-wrap:normal;font-variant-numeric:tabular-nums;}
html[lang="ar"] .cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{flex:0 0 auto;font-size:10px!important;letter-spacing:0!important;}
@media(max-width:780px){html[lang="ar"] .cart-quote-image-dialog>.cart-quote-image-sheet .cart-quote-price{gap:4px;font-size:11px!important;}html[lang="ar"] .cart-quote-image-dialog>.cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{font-size:8px!important;}}

/* v15.27: stable language picker positions regardless of selected language. */
#customerAccessForm .access-language-actions{direction:ltr!important;}
#customerAccessForm .access-language-actions>[data-customer-lang="en"]{grid-column:1;grid-row:1;}
#customerAccessForm .access-language-actions>[data-customer-lang="es"]{grid-column:2;grid-row:1;}
#customerAccessForm .access-language-actions>[data-customer-lang="ru"]{grid-column:1;grid-row:2;}
#customerAccessForm .access-language-actions>[data-customer-lang="ar"]{grid-column:2;grid-row:2;direction:rtl;}

/* v15.28: Spanish and Russian use their native LTR layout and typography. */
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) body{direction:ltr;font-family:Arial,"Helvetica Neue",sans-serif;letter-spacing:normal;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) :is(button,input,textarea,select){font-family:inherit;letter-spacing:normal;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) :is(.mobile-hide-cn,.gallery-title-cn,.quote-heading-translation,.quote-header-count-en){display:none!important;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .cart-quote-image-sheet .cart-quote-price{display:flex;direction:ltr;flex-direction:row;align-items:center;justify-content:center;gap:6px;white-space:nowrap;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{position:static!important;transform:none!important;font-size:10px!important;letter-spacing:0;flex:none;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .new-product-badge{background:#e52b28!important;background-image:none!important;color:white;text-indent:0!important;display:flex!important;align-items:center;justify-content:center;width:auto!important;min-width:44px;height:25px!important;padding:0 6px;border-radius:0 0 0 8px;font:700 11px/1.4 Arial,sans-serif!important;animation:none!important;filter:none!important;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .new-product-badge::after{display:none!important;}
html[lang="es"] .detail-image-stage.is-loading::before{content:"Cargando imagen…";}
html[lang="ru"] .detail-image-stage.is-loading::before{content:"Загрузка изображения…";}
html[lang="es"] :is(.quote-switch .cart-open-btn,.quote-list-row-btn)::after{content:"Nuevo";}
html[lang="ru"] :is(.quote-switch .cart-open-btn,.quote-list-row-btn)::after{content:"Новое";}
html[lang="es"] .pending-group .quote-item.is-return-target .quote-info::after{content:"Cotización solicitada";}
html[lang="ru"] .pending-group .quote-item.is-return-target .quote-info::after{content:"Цена запрошена";}
html[lang="es"] .submitted-group .quote-item.is-return-target .quote-info::after{content:"Precio indicado";}
html[lang="ru"] .submitted-group .quote-item.is-return-target .quote-info::after{content:"Цена указана";}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .quote-section-title{flex-wrap:wrap;line-height:1.5;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .quote-btn-lines{line-height:1.4;}
html:is([lang="zh"],[lang="en"],[lang="es"],[lang="ru"]) .quote-welcome-footer{line-height:1.6;}

/* v15.29: five languages in two fixed rows. */
#customerAccessForm .access-language-actions{grid-template-columns:repeat(6,minmax(0,1fr))!important;}
#customerAccessForm .access-language-actions>[data-customer-lang="zh"]{grid-column:1/3;grid-row:1;}
#customerAccessForm .access-language-actions>[data-customer-lang="en"]{grid-column:3/5;grid-row:1;}
#customerAccessForm .access-language-actions>[data-customer-lang="es"]{grid-column:5/7;grid-row:1;}
#customerAccessForm .access-language-actions>[data-customer-lang="ru"]{grid-column:1/4;grid-row:2;}
#customerAccessForm .access-language-actions>[data-customer-lang="ar"]{grid-column:4/7;grid-row:2;}
#customerAccessForm .access-language-actions>#customerAccessMessage{grid-column:1/-1;}

/* v15.30: single-language English and Chinese feedback and export labels. */
html[lang="en"] .detail-image-stage.is-loading::before{content:"Loading image…";}
html[lang="zh"] .detail-image-stage.is-loading::before{content:"图片加载中…";}
html[lang="en"] .pending-group .quote-item.is-return-target .quote-info::after{content:"Quote requested";}
html[lang="en"] .submitted-group .quote-item.is-return-target .quote-info::after{content:"Quoted";}
html[lang="zh"] .pending-group .quote-item.is-return-target .quote-info::after{content:"已申请报价";}
html[lang="zh"] .submitted-group .quote-item.is-return-target .quote-info::after{content:"已报价";}
html[lang="zh"] :is(.quote-switch .cart-open-btn,.quote-list-row-btn)::after{content:"新品";}

/* v15.32: show the complete localized access address without fitting/clipping. */
#customerAccessForm .access-address{height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important;white-space:normal!important;text-overflow:clip!important;display:block!important;font-size:12px!important;line-height:1.5!important;overflow-wrap:anywhere;}
@media(max-width:780px){#customerAccessForm .access-address{font-size:11px!important;}}

/* v15.35: clearer brand size and spacing in all quote exports. */
html[lang] .cart-quote-image-sheet .cart-quote-price{gap:14px!important;}
html[lang] .cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{font-size:12px!important;}
@media(max-width:780px){html[lang] .cart-quote-image-dialog>.cart-quote-image-sheet .cart-quote-price{gap:8px!important;}html[lang] .cart-quote-image-dialog>.cart-quote-image-sheet .cart-quote-price .cart-quote-price-brand{font-size:10px!important;}}
