.br-planner {
–green-dark: #173f35;
–green: #2f6b58;
–green-light: #e7f0eb;
–coral: #e97861;
–cream: #fbf7ef;
–text: #24342f;
–muted: #66736e;
max-width: 760px;
margin: 30px auto;
font-family: inherit;
color: var(–text);
}
.br-planner-card {
background: #ffffff;
border: 1px solid #e4e8e5;
border-radius: 22px;
padding: 38px;
box-shadow: 0 12px 35px rgba(23, 63, 53, 0.08);
}
.br-planner-card h2 {
margin: 0 0 12px;
color: var(–green-dark);
font-size: 30px;
line-height: 1.2;
}
.br-planner-intro {
margin: 0 0 30px;
color: var(–muted);
font-size: 17px;
line-height: 1.6;
}
.br-field {
margin-bottom: 20px;
}
.br-field label {
display: block;
margin-bottom: 7px;
color: var(–green-dark);
font-size: 15px;
font-weight: 700;
}
.br-field input[type=”time”] {
width: 100%;
box-sizing: border-box;
min-height: 52px;
padding: 10px 14px;
border: 1px solid #ccd8d2;
border-radius: 12px;
background: #fff;
color: var(–text);
font-size: 18px;
}
.br-field input[type=”time”]:focus {
outline: none;
border-color: var(–green);
box-shadow: 0 0 0 3px rgba(47, 107, 88, 0.12);
}
#br-calculate {
width: 100%;
min-height: 54px;
margin-top: 6px;
padding: 14px 20px;
border: 0;
border-radius: 12px;
background: var(–green-dark);
color: #ffffff;
font-size: 17px;
font-weight: 700;
cursor: pointer;
}
#br-calculate:hover {
background: var(–green);
}
.br-result {
margin-top: 25px;
padding: 20px;
border-radius: 14px;
background: var(–green-light);
border-left: 4px solid var(–coral);
}
.br-result p {
margin: 0;
}
/* =========================================
GDJE SAM SADA
========================================= */
.br-now {
margin-top: 22px;
padding: 18px;
border-radius: 14px;
background: #ffffff;
border: 1px solid #dfe8e3;
}
.br-now h4 {
margin: 0 0 10px;
color: var(–green-dark);
font-size: 18px;
}
.br-now-status {
margin-bottom: 12px;
font-weight: 700;
color: var(–green-dark);
}
.br-progress-wrap {
width: 100%;
height: 12px;
background: #dfe8e3;
border-radius: 999px;
overflow: hidden;
margin: 10px 0 10px;
}
.br-progress-bar {
height: 100%;
width: 0%;
background: var(–green);
border-radius: 999px;
transition: width 0.4s ease;
}
.br-now-text {
color: var(–muted);
line-height: 1.5;
font-size: 14px;
}
/* =========================================
EMAIL / BREVO BLOK
========================================= */
.br-email-box {
margin-top: 22px;
padding: 22px;
border-radius: 16px;
background: var(–cream);
border: 1px solid #e6ddd0;
}
.br-email-box h4 {
margin: 0 0 7px;
color: var(–green-dark);
font-size: 20px;
line-height: 1.3;
}
.br-email-intro {
margin: 0 0 18px !important;
padding: 0 !important;
background: transparent !important;
border: 0 !important;
color: var(–muted);
font-size: 14px;
line-height: 1.55;
}
.br-email-field {
margin-bottom: 14px;
}
.br-email-field label {
display: block;
margin-bottom: 7px;
color: var(–green-dark);
font-size: 14px;
font-weight: 700;
}
.br-email-field input[type=”email”] {
width: 100%;
box-sizing: border-box;
min-height: 52px;
padding: 11px 14px;
border: 1px solid #ccd8d2;
border-radius: 11px;
background: #ffffff;
color: var(–text);
font-size: 16px;
}
.br-email-field input[type=”email”]:focus {
outline: none;
border-color: var(–green);
box-shadow: 0 0 0 3px rgba(47, 107, 88, 0.12);
}
.br-consent {
display: flex;
align-items: flex-start;
gap: 10px;
margin: 13px 0 16px;
color: var(–muted);
font-size: 13px;
line-height: 1.5;
}
.br-consent input {
width: 18px;
height: 18px;
margin: 2px 0 0;
flex: 0 0 auto;
}
.br-consent a {
color: var(–green-dark);
text-decoration: underline;
}
.br-email-submit {
width: 100%;
min-height: 52px;
padding: 13px 18px;
border: 0;
border-radius: 11px;
background: var(–coral);
color: #ffffff;
font-size: 16px;
font-weight: 700;
cursor: pointer;
}
.br-email-submit:hover {
opacity: 0.92;
}
.br-email-note {
margin: 10px 0 0 !important;
padding: 0 !important;
background: transparent !important;
border: 0 !important;
color: var(–muted);
font-size: 12px;
line-height: 1.45;
}
.br-hidden-field {
display: none !important;
}
/* =========================================
MOBITEL
========================================= */
@media (max-width: 600px) {
.br-planner {
margin: 15px auto;
}
.br-planner-card {
padding: 22px 18px;
border-radius: 18px;
}
.br-planner-card h2 {
font-size: 25px;
}
.br-planner-intro {
font-size: 16px;
margin-bottom: 24px;
}
.br-field input[type=”time”] {
min-height: 54px;
font-size: 17px;
}
#br-calculate {
min-height: 56px;
}
.br-email-box {
padding: 18px 15px;
}
.br-email-box h4 {
font-size: 19px;
}
}
/* =========================================
BOLJI IZGLED REZULTATA
========================================= */
.br-result h3 {
font-size: 23px;
margin-bottom: 24px;
}
.br-result p {
margin: 0 0 12px;
padding: 12px 14px;
border-radius: 12px;
background: rgba(255, 255, 255, 0.55);
line-height: 1.55;
}
.br-result p:last-child {
margin-bottom: 0;
}
.br-result p strong {
color: var(–green-dark);
}
/* Unimate */
.br-result > p:nth-of-type(1) {
border-left: 4px solid #d6a746;
}
/* Balance prije ručka */
.br-result > p:nth-of-type(2) {
border-left: 4px solid #4e9bc6;
}
/* Ručak */
.br-result > p:nth-of-type(3) {
border-left: 4px solid var(–green);
}
/* Balance prije večere */
.br-result > p:nth-of-type(4) {
border-left: 4px solid #4e9bc6;
}
/* Večera */
.br-result > p:nth-of-type(5) {
border-left: 4px solid var(–green);
}
/* Početak posta */
.br-result > p:nth-of-type(6) {
background: #fff1ed;
border-left: 4px solid var(–coral);
}
/* Završetak 16 sati */
.br-result > p:nth-of-type(7) {
background: #e7f0eb;
border-left: 4px solid var(–green-dark);
font-weight: 600;
}
@media (max-width: 600px) {
.br-result > p {
padding: 11px 12px;
font-size: 14px;
}
.br-result h3 {
font-size: 20px;
}
}
16:8 kalkulator posta i Feel Great planer
Unesi vrijeme buđenja, prvog obroka i večere.
Planer će automatski složiti tvoj dnevni 16:8 raspored.
Vrijeme buđenja
Vrijeme ručka / prvog obroka
Vrijeme večere
Izradi moj plan
Ovdje će se prikazati tvoj raspored.
document.addEventListener(“DOMContentLoaded”, function () {
const button = document.getElementById(“br-calculate”);
const result = document.getElementById(“br-result”);
function timeToMinutes(time) {
const parts = time.split(“:”);
return parseInt(parts[0]) * 60 + parseInt(parts[1]);
}
function minutesToTime(minutes) {
minutes = ((minutes % 1440) + 1440) % 1440;
const hours = Math.floor(minutes / 60);
const mins = minutes % 60;
return String(hours).padStart(2, “0”) + “:” +
String(mins).padStart(2, “0”);
}
function formatDuration(minutes) {
const hours = Math.floor(minutes / 60);
const mins = minutes % 60;
if (hours > 0 && mins > 0) {
return hours + ” h ” + mins + ” min”;
}
if (hours > 0) {
return hours + ” h”;
}
return mins + ” min”;
}
button.addEventListener(“click”, function () {
const wake = document.getElementById(“br-wake”).value;
const lunch = document.getElementById(“br-lunch”).value;
const dinner = document.getElementById(“br-dinner”).value;
if (!wake || !lunch || !dinner) {
result.innerHTML =
“
Molimo unesi sva vremena. “;
return;
}
const wakeMinutes = timeToMinutes(wake);
const lunchMinutes = timeToMinutes(lunch);
const dinnerMinutes = timeToMinutes(dinner);
const unimateEnd = wakeMinutes + 60;
const balanceLunchStart = lunchMinutes – 10;
const balanceLunchEnd = lunchMinutes – 5;
const balanceDinnerStart = dinnerMinutes – 10;
const balanceDinnerEnd = dinnerMinutes – 5;
const closeMinutes = lunchMinutes + (8 * 60);
const close = minutesToTime(closeMinutes);
const nextMeal = closeMinutes + (16 * 60);
const nextMealTime = minutesToTime(nextMeal);
/* PROVJERA VEČERE */
if (dinnerMinutes = closeMinutes) {
result.innerHTML = `
Provjeri vrijeme večere
⚠️ Ako tvoj prvi obrok počinje u
${lunch} , tvoj 8-satni prozor za jelo
završava u ${close} .
Večeru postavi između prvog obroka i završetka
prozora za jelo.
`;
return;
}
/* =========================================
GDJE SAM SADA
========================================= */
const now = new Date();
const currentMinutes = now.getHours() * 60 + now.getMinutes();
let nowTitle = “”;
let nowText = “”;
let progressPercent = 0;
if (currentMinutes >= lunchMinutes && currentMinutes = closeMinutes) {
elapsedFast = currentMinutes – closeMinutes;
} else {
elapsedFast = (1440 – closeMinutes) + currentMinutes;
}
if (elapsedFast > 960) {
elapsedFast = 960;
}
const remainingFast = 960 – elapsedFast;
progressPercent = (elapsedFast / 960) * 100;
nowTitle = “Trenutno si u periodu posta”;
if (remainingFast > 0) {
nowText =
“Post traje približno ” +
formatDuration(elapsedFast) +
“. Do planiranog završetka posta ostaje još ” +
formatDuration(remainingFast) +
“.”;
} else {
nowText =
“Tvoj planirani 16-satni period posta je završen.”;
}
}
/* =========================================
PODACI ZA BREVO
========================================= */
const planWake = wake;
const planUnimate =
wake + ” – ” + minutesToTime(unimateEnd);
const planLunchBalance =
minutesToTime(balanceLunchStart) +
” – ” +
minutesToTime(balanceLunchEnd);
const planLunch = lunch;
const planDinnerBalance =
minutesToTime(balanceDinnerStart) +
” – ” +
minutesToTime(balanceDinnerEnd);
const planDinner = dinner;
const planFastStart = close;
const planFastEnd = nextMealTime;
result.innerHTML = `
Tvoj dnevni plan
☀️ ${wake} – ${minutesToTime(unimateEnd)}
Unimate — 1 vrećica u najmanje 5 dl hladne vode.
🔵 ${minutesToTime(balanceLunchStart)} – ${minutesToTime(balanceLunchEnd)}
Balance prije ručka — 1 vrećica u 2–3 dl vode.
🍽️ ${lunch}
Ručak — prvi glavni obrok i početak 8-satnog prozora za jelo.
🔵 ${minutesToTime(balanceDinnerStart)} – ${minutesToTime(balanceDinnerEnd)}
Balance prije večere — 1 vrećica u 2–3 dl vode.
🍽️ ${dinner}
Večera — drugi glavni obrok dana.
🌙 ${close}
Kraj prozora za jelo i početak 16-satnog posta.
✓ ${nextMealTime}
Završetak 16 sati posta i početak novog prozora za jelo.
⏱️ Gdje sam sada?
${nowTitle}
${nowText}
📩 Pošalji si svoj 16:8 plan
Ostavi svoju e-mail adresu i poslat ćemo ti tvoj
16:8 + Feel Great raspored kako bi ga imao pri ruci.
E-mail adresa
Želim primiti svoj 16:8 plan i povremene korisne
informacije projekta Bolja Rutina te prihvaćam
Pravila privatnosti
.
POŠALJI MI MOJ PLAN
Odjaviti se možeš u bilo kojem trenutku.
`;
});
});
/* =========================================
SEO SADRŽAJ ISPOD KALKULATORA
Namjerno koristi zasebne klase kako ne bi
utjecao na postojeći kalkulator.
========================================= */
.br-seo-extra {
max-width: 760px;
margin: 38px auto 20px;
font-family: inherit;
color: #24342f;
}
.br-seo-extra h2 {
margin: 28px 0 10px;
color: #173f35;
font-size: 25px;
line-height: 1.3;
}
.br-seo-extra p {
margin: 0 0 14px;
font-size: 16px;
line-height: 1.7;
}
.br-seo-extra strong {
color: #173f35;
}
.br-seo-extra-example {
margin: 18px 0 26px;
padding: 17px 18px;
border-radius: 14px;
background: #e7f0eb;
border-left: 4px solid #2f6b58;
}
.br-seo-extra-example p {
margin: 0;
}
.br-seo-extra-faq details {
margin-bottom: 10px;
border: 1px solid #dfe7e3;
border-radius: 12px;
background: #ffffff;
overflow: hidden;
}
.br-seo-extra-faq summary {
padding: 15px 17px;
color: #173f35;
font-weight: 700;
cursor: pointer;
line-height: 1.45;
}
.br-seo-extra-faq details p {
margin: 0;
padding: 0 17px 16px;
color: #66736e;
font-size: 15px;
line-height: 1.65;
}
.br-seo-extra-cta {
margin: 28px 0 0;
padding: 20px;
border-radius: 14px;
background: #173f35;
text-align: center;
}
.br-seo-extra-cta p {
margin: 0 0 14px;
color: #e7f0eb;
font-size: 15px;
}
.br-seo-extra-cta a {
display: inline-block;
padding: 12px 18px;
border-radius: 10px;
background: #ffffff;
color: #173f35;
text-decoration: none;
font-weight: 700;
}
.br-seo-extra-note {
margin-top: 26px;
padding-top: 18px;
border-top: 1px solid #e1e6e3;
color: #66736e;
font-size: 13px;
line-height: 1.6;
}
@media (max-width: 600px) {
.br-seo-extra {
margin-top: 30px;
}
.br-seo-extra h2 {
font-size: 22px;
}
.br-seo-extra p {
font-size: 15px;
}
.br-seo-extra-cta {
padding: 18px 15px;
}
.br-seo-extra-cta a {
display: block;
}
}
/* =========================================
MOBILNI POPRAVAK ŠIRINE
– sprječava izlazak kalkulatora iz okvira
– daje više prostora email polju
========================================= */
@media (max-width: 600px) {
.br-planner,
.br-planner *,
.br-seo-extra,
.br-seo-extra * {
box-sizing: border-box;
}
.br-planner {
width: 100%;
max-width: 100%;
margin: 15px 0;
padding: 0;
}
.br-planner-card {
width: 100%;
max-width: 100%;
padding: 20px 14px;
overflow: hidden;
}
.br-field,
.br-field input[type=”time”],
#br-calculate {
width: 100%;
max-width: 100%;
min-width: 0;
}
.br-result {
width: 100%;
max-width: 100%;
padding: 14px 10px;
overflow: hidden;
}
.br-result > p,
.br-window-note,
.br-now,
.br-email-box,
.br-feelgreat-cta {
width: 100%;
max-width: 100%;
}
.br-email-box {
padding: 16px 10px;
}
.br-email-field {
width: 100%;
max-width: 100%;
}
.br-email-field input[type=”email”] {
display: block;
width: 100% !important;
max-width: 100% !important;
min-width: 0 !important;
}
.br-consent {
width: 100%;
max-width: 100%;
}
.br-consent span {
min-width: 0;
}
.br-email-submit {
width: 100%;
max-width: 100%;
}
.br-feelgreat-button {
width: 100%;
max-width: 100%;
}
.br-seo-extra {
width: 100%;
max-width: 100%;
}
}
@media (max-width: 600px) {
.br-field {
width: 100%;
max-width: 100%;
overflow: hidden;
}
.br-field input[type=”time”] {
display: block;
width: 100% !important;
max-width: 100% !important;
min-width: 0 !important;
box-sizing: border-box !important;
-webkit-appearance: none;
appearance: none;
}
}