document.addEventListener("DOMContentLoaded", function () { // تحديد العنصر المستهدف (ديف وصف المنتج) const targetDesc = document.querySelector('[data-testid="store-product-description"]') || document.querySelector('.product__description'); if (targetDesc && !document.getElementById("custom-install-service-box")) { // كود التنسيق المدمج const style = document.createElement("style"); style.textContent = ` .install-service-wrapper { display: flex; align-items: center; justify-content: space-between; gap: 12px; background-color: #f7fafc; border: 1px solid #e2e8f0; border-radius: 12px; padding: 12px 18px; margin-top: 15px; margin-bottom: 20px; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03); } .install-service-text { font-size: 15px; font-weight: 700; color: #2d3748; display: flex; align-items: center; gap: 6px; } .install-service-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background-color: #25D366; color: #ffffff !important; text-decoration: none !important; font-size: 14px; font-weight: bold; padding: 9px 18px; border-radius: 8px; transition: background-color 0.25s ease, transform 0.2s ease; white-space: nowrap; } .install-service-btn:hover { background-color: #1ebe57; transform: translateY(-1px); color: #ffffff !important; } .install-service-btn svg { width: 19px; height: 19px; fill: currentColor; } /* تنسيق خاص للجوال لضمان الشكل المنظم */ @media (max-width: 640px) { .install-service-wrapper { flex-direction: column; align-items: stretch; text-align: center; gap: 10px; padding: 14px; } .install-service-text { justify-content: center; font-size: 14px; } .install-service-btn { width: 100%; padding: 10px; } } `; document.head.appendChild(style); // بناء قالب العنصر const boxHTML = `