document.addEventListener("DOMContentLoaded", function () { const counter = document.querySelector(".counter16"); if (!counter) { console.log("Элемент не найден"); return; } let current = 1; const end = 16; const timer = setInterval(function () { counter.textContent = current; if (current >= end) { clearInterval(timer); } current++; }, 80); });