
<script>
// //winGo Timer 10 minutes
const countdown = () => {
  let timer = document.getElementById("winGo10m");
  let dt = new Date();
  let m = dt.getMinutes();
  let s = dt.getSeconds();

  // minutes remaining until next 10 minute mark
  m = s ? 9 - (m % 10) : 10 - (m % 10);

  // seconds remaining until next minute mark
  if (s) {
    s = 60 - s;
  }

  timer.textContent = `${m}:${s < 10 ? "0" + s : s} `;
};
setInterval(countdown, 1000);

// //winGo Timer 1 minutes



// //winGo Timer 3 minutes
const winGo3mcountdown = () => {
  let timer = document.getElementById("winGo3m");
  let dt = new Date();
  let m = dt.getMinutes();
  let s = dt.getSeconds();

  // minutes remaining until next 10 minute mark
  m = s ? 2 - (m % 3) : 3 - (m % 3);

  // seconds remaining until next minute mark
  if (s) {
    s = 60 - s;
  }
  timer.textContent = `${m}:${s < 10 ? "0" + s : s}`;
};
setInterval(winGo3mcountdown, 180);

// //winGo Timer 5 minutes
const winGo5mcountdown = () => {
  let timer = document.getElementById("winGo5m");
  let dt = new Date();
  let m = dt.getMinutes();
  let s = dt.getSeconds();

  // minutes remaining until next 10 minute mark
  m = s ? 4 - (m % 5) : 5 - (m % 5);

  // seconds remaining until next minute mark
  if (s) {
    s = 60 - s;
  }
  timer.textContent = `${m}:${s < 10 ? "0" + s : s}`;
};
setInterval(winGo5mcountdown, 300);

</script>