Calculadora de Calorias de Fast Food — Monte Sua Refeição

Calculadora de Calorias de Fast Food — Monte Sua Refeição e Conte as Calorias | FindHealthTips

Calculadora de Calorias de Fast Food
Monte Sua Refeição e Conte as Calorias

Escolha seu restaurante favorito, adicione os itens um a um e veja o total de calorias atualizar em tempo real — depois descubra exatamente como essa refeição se encaixa na sua meta diária de 2.000 calorias. Sem baixar aplicativo, sem cadastro, só consciência nutricional na hora.

Passo 1 — Escolha o Restaurante

Selecione um restaurante

Sua Refeição

Total de Calorias
0
kcal
Adicione itens do cardápio para começar a contar.
🍽️ Nenhum item ainda — escolha um restaurante e comece a montar!

Perguntas Frequentes sobre Calorias no Fast Food

`; return; } items.forEach(item => { const div = document.createElement("div"); div.className = "menu-item"; div.innerHTML = `
${escHtml(item.name)}
${item.cal} cal
`; div.querySelector(".add-btn").addEventListener("click", () => addItem(item)); itemList.appendChild(div); }); } // ── MEAL LOGIC ───────────────────────────────────────────────────────────── function addItem(item) { const entry = { id: nextId++, name: item.name, cal: item.cal, chain: activeChain.label }; meal.push(entry); renderMeal(); showToast(`✅ ${item.name} adicionado!`); } function removeItem(id) { meal = meal.filter(e => e.id !== id); renderMeal(); } function clearMeal() { meal = []; renderMeal(); } function renderMeal() { const total = meal.reduce((s, e) => s + e.cal, 0); // color let colorClass = "green"; if (total > 900) colorClass = "red"; else if (total >= 600) colorClass = "yellow"; calNum.className = `calorie-number ${colorClass}`; calNum.textContent = total.toLocaleString(); // daily pct if (total === 0) { dailyPct.innerHTML = "Adicione itens do cardápio para começar a contar."; } else { const pct = Math.round((total / 2000) * 100); dailyPct.innerHTML = `Com base em uma dieta diária de 2.000 calorias, esta refeição representa ${pct}% da sua ingestão diária.`; } // items list mealItems.innerHTML = ""; if (meal.length === 0) { mealEmpty.style.display = ""; mealItems.appendChild(mealEmpty); } else { mealEmpty.style.display = "none"; meal.forEach(entry => { const div = document.createElement("div"); div.className = "meal-item"; div.innerHTML = ` ${escHtml(entry.name)} ${entry.cal} cal `; div.querySelector(".remove-btn").addEventListener("click", () => removeItem(entry.id)); mealItems.appendChild(div); }); } shareBtn.disabled = meal.length === 0; clearBtn.disabled = meal.length === 0; } // ── SHARE ───────────────────────────────────────────────────────────────── shareBtn.addEventListener("click", () => { if (meal.length === 0) return; const total = meal.reduce((s, e) => s + e.cal, 0); const chain = meal[meal.length - 1].chain; const text = `Minha refeição no ${chain} tem ${total} calorias! Calculado no FindHealthTips.com 🍔 👉 https://findhealthtips.com/pt/fast-food-calories/`; if (navigator.share) { navigator.share({ title: "Minha Refeição de Fast Food", text }).catch(() => {}); } else if (navigator.clipboard) { navigator.clipboard.writeText(text).then(() => { showToast("📋 Resumo da refeição copiado para a área de transferência!"); }); } else { prompt("Copie o resumo da sua refeição:", text); } }); clearBtn.addEventListener("click", clearMeal); // ── FAQ ─────────────────────────────────────────────────────────────────── const faqList = document.getElementById("faqList"); FAQS.forEach((faq, i) => { const item = document.createElement("div"); item.className = "faq-item"; item.innerHTML = `
${escHtml(faq.a)}
`; item.querySelector(".faq-q").addEventListener("click", () => { const isOpen = item.classList.contains("open"); document.querySelectorAll(".faq-item.open").forEach(el => { el.classList.remove("open"); el.querySelector(".faq-q").setAttribute("aria-expanded", "false"); }); if (!isOpen) { item.classList.add("open"); item.querySelector(".faq-q").setAttribute("aria-expanded", "true"); } }); faqList.appendChild(item); }); // ── TOAST ───────────────────────────────────────────────────────────────── let toastTimer; function showToast(msg) { toast.textContent = msg; toast.classList.add("show"); clearTimeout(toastTimer); toastTimer = setTimeout(() => toast.classList.remove("show"), 2400); } // ── UTILS ───────────────────────────────────────────────────────────────── function escHtml(s) { return String(s).replace(/&/g,"&").replace(//g,">").replace(/"/g,"""); } // ── INIT ────────────────────────────────────────────────────────────────── renderMeal(); function ffcSocialShare(platform) { var text = (typeof ffcShareText !== "undefined" && ffcShareText) ? ffcShareText : document.title + " — " + window.location.href; var url = encodeURIComponent(window.location.href); var enc = encodeURIComponent(text); var links = { wa: "https://wa.me/?text=" + enc, fb: "https://www.facebook.com/sharer/sharer.php?u=" + url, tw: "https://twitter.com/intent/tweet?text=" + enc, li: "https://www.linkedin.com/shareArticle?mini=true&url=" + url + "&title=" + encodeURIComponent(document.title) }; if (platform === "copy") { var btn = document.getElementById("ffc-copy-btn"); if (navigator.clipboard && navigator.clipboard.writeText) { navigator.clipboard.writeText(text).then(function(){ if(btn){ btn.textContent = "✅ Copiado!"; btn.classList.add("ffc-sbtn-copied"); setTimeout(function(){ btn.textContent = "📋 Copiar"; btn.classList.remove("ffc-sbtn-copied"); }, 2000); } }); } else { var ta = document.createElement("textarea"); ta.value = text; ta.style.cssText = "position:fixed;opacity:0"; document.body.appendChild(ta); ta.select(); document.execCommand("copy"); document.body.removeChild(ta); if(btn){ btn.textContent = "✅ Copiado!"; btn.classList.add("ffc-sbtn-copied"); setTimeout(function(){ btn.textContent = "📋 Copiar"; btn.classList.remove("ffc-sbtn-copied"); }, 2000); } } return; } if (links[platform]) window.open(links[platform], "_blank", "width=600,height=450,noopener"); } window.ffcSocialShare = ffcSocialShare;