window.addEventListener("load", function () { const footer = document.createElement("div"); footer.className = "custom-footer"; footer.innerHTML = `
`; document.body.appendChild(footer); }); document.addEventListener("DOMContentLoaded", function () { const sections = [ { title: "العناية الشخصية", image: "https://i.ibb.co/GQPvCsZD/Ellipse-2635-1.png", link: "https://zel-elenaya.com/%D9%85%D9%86%D8%AA%D8%AC%D8%A7%D8%AA-%D8%A7%D9%84%D8%B9%D9%86%D8%A7%D9%8A%D8%A9-%D8%A8%D8%A7%D9%84%D8%AC%D8%B3%D9%85/c485986516" }, { title: "العناية بالشعر", image: "https://i.ibb.co/pjxZs2C4/Ellipse-2634.png", link: "https://zel-elenaya.com/%D9%85%D9%86%D8%AA%D8%AC%D8%A7%D8%AA-%D8%A7%D9%84%D8%B9%D9%86%D8%A7%D9%8A%D8%A9-%D8%A8%D8%A7%D9%84%D8%B4%D8%B9%D8%B1/c1719364290" }, { title: "العناية بالبشرة", image: "https://i.ibb.co/xt7yfhxW/Ellipse-2633.png", link: "https://zel-elenaya.com/%D9%85%D9%86%D8%AA%D8%AC%D8%A7%D8%AA-%D8%A7%D9%84%D8%B9%D9%86%D8%A7%D9%8A%D8%A9-%D8%A8%D8%A7%D9%84%D8%A8%D8%B4%D8%B1%D8%A9/c1370206452" } ]; const sectionBlock = document.createElement("div"); sectionBlock.className = "sections-block"; const title = document.createElement("h2"); title.className = "section-title"; title.textContent = "الاقسام"; sectionBlock.appendChild(title); const wrapper = document.createElement("div"); wrapper.className = "sections-wrapper"; sections.forEach((sec) => { // إنشاء الرابط الخارجي للكارد const link = document.createElement("a"); link.href = sec.link; link.className = "section-card-link"; link.style.textDecoration = "none"; // إزالة الخط السفلي link.style.color = "inherit"; // الحفاظ على لون النص // محتوى الكارد const card = document.createElement("div"); card.className = "section-card"; const img = document.createElement("img"); img.src = sec.image; img.alt = sec.title; img.className = "section-image"; const label = document.createElement("p"); label.className = "section-label"; label.textContent = sec.title; // تجميع العناصر card.appendChild(img); card.appendChild(label); link.appendChild(card); // وضع الكارد داخل الرابط wrapper.appendChild(link); // إضافة الرابط إلى الـ wrapper }); sectionBlock.appendChild(wrapper); const targetSection = document.querySelector(".s-block.container"); if (targetSection && targetSection.parentNode) { targetSection.parentNode.insertBefore(sectionBlock, targetSection.nextSibling); } }); document.addEventListener("DOMContentLoaded", function () { const features = [ { text: "شحن سريع", icon: "https://i.ibb.co/DDF2hN3d/Group-1261154874-1.png", style: "feature-filled" }, { text: "الدعم الفني", icon: "https://i.ibb.co/M51g4dzJ/Group-1261154874-2.png", style: "feature-outline" }, { text: "اسعار منافسة", icon: "https://i.ibb.co/M51g4dzJ/Group-1261154874-2.png", style: "feature-filled" } ]; const section = document.createElement("div"); section.className = "features-section"; features.forEach((feat) => { const box = document.createElement("div"); box.className = `feature-box ${feat.style}`; // ✅ الأيقونة أولاً const iconContainer = document.createElement("div"); iconContainer.className = "feature-icon"; const img = document.createElement("img"); img.src = feat.icon; img.alt = feat.text; iconContainer.appendChild(img); const text = document.createElement("span"); text.textContent = feat.text; box.appendChild(iconContainer); // أيقونة box.appendChild(text); // النص section.appendChild(box); }); // إدراج السكشن قبل الفوتر مباشرة const footer = document.querySelector("footer"); if (footer && footer.parentNode) { footer.parentNode.insertBefore(section, footer); } });