{“@context”:”https://schema.org”,”@type”:”WebApplication”,”name”:”Cake Business Compliance Checker”,”description”:”Free 2-minute checker for UK home bakers and cake-shed owners (England and Wales): answer four questions and get a personalised legal checklist — council registration, SFBB and daily fridge records, the 8°C rule, Natasha’s Law PPDS labelling, planning, rates and insurance flags — plus the kit tier that makes compliance provable.”,”applicationCategory”:”BusinessApplication”,”operatingSystem”:”Any”,”offers”:{“@type”:”Offer”,”price”:”0″,”priceCurrency”:”GBP”},”author”:{“@type”:”Person”,”@id”:”https://www.cravencooling.co.uk/harrison/#person”,”name”:”Harrison Craven”,”jobTitle”:”Junior Refrigeration Engineer”,”url”:”https://www.cravencooling.co.uk/harrison/”,”image”:”https://www.cravencooling.co.uk/wp-content/uploads/2026/07/Harrison-Craven-1-1024×683.webp”,”worksFor”:{“@type”:”Organization”,”name”:”Craven Cooling”,”url”:”https://cravencooling.co.uk”}},”publisher”:{“@type”:”Organization”,”name”:”Craven Cooling”,”url”:”https://www.cravencooling.co.uk”}} .cckc-wrap { font-family: ‘Figtree’, Arial, sans-serif; color: #334155; line-height: 1.55; max-width: 980px; margin: 0 auto; } .cckc-wrap * { box-sizing: border-box; } .cckc-wrap h2, .cckc-wrap h3 { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; } .cckc-hero { position: relative; overflow: hidden; border-radius: 16px; padding: 40px 30px 34px; text-align: center; color: #fff; background: linear-gradient(135deg, #000 0%, #1E293B 70%, #003A55 100%); } .cckc-hero::after { content: “”; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px); background-size: 22px 22px; opacity: 0.5; pointer-events: none; } .cckc-hero > * { position: relative; z-index: 1; } .cckc-kicker { display: inline-block; font-size: 0.72em; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: #00aeef; border: 1px solid rgba(0,174,239,0.4); border-radius: 100px; padding: 6px 15px; margin-bottom: 16px; } .cckc-hero h2 { font-size: clamp(26px, 4.6vw, 42px); font-weight: 800; line-height: 1.1; margin: 0 0 12px; } .cckc-hero h2 em { font-style: normal; color: #00aeef; } .cckc-hero p { font-size: 0.97em; color: #B9C6D6; max-width: 620px; margin: 0 auto; } .cckc-hero-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 20px; } .cckc-hero-chip { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14); border-radius: 100px; padding: 7px 15px; font-size: 0.76em; font-weight: 700; color: #DCE7F2; } .cckc-hero-chip strong { color: #00aeef; font-weight: 800; } .cckc-progress { display: flex; align-items: center; gap: 12px; margin: 22px 4px 0; } .cckc-progress-label { font-size: 0.72em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; color: #64748B; white-space: nowrap; } .cckc-bar { flex: 1; height: 7px; border-radius: 999px; background: #E2E8F0; overflow: hidden; } .cckc-bar-fill { height: 100%; width: 0; border-radius: 999px; background: linear-gradient(90deg, #0091CC, #00aeef); transition: width 0.35s ease; } @media (prefers-reduced-motion: reduce) { .cckc-bar-fill { transition: none; } } .cckc-card { background: #fff; border: 1px solid #E2E8F0; border-top: 4px solid #00aeef; border-radius: 14px; padding: 26px; margin-top: 16px; } @media (max-width: 560px) { .cckc-card { padding: 20px 15px; } } .cckc-card h3 { font-size: 0.84em !important; font-weight: 800; text-transform: uppercase; letter-spacing: 0.09em; color: #1E293B !important; margin: 0 0 6px !important; } .cckc-card h3 span { color: #00aeef; } .cckc-card-sub { font-size: 0.87em; color: #64748B; margin: 0 0 18px; } .cckc-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 11px; } .cckc-opt { display: flex; align-items: flex-start; gap: 13px; text-align: left; background: #F9FAFB; border: 1px solid #DBDBDB; border-radius: 11px; padding: 15px 16px; cursor: pointer; font-family: inherit; width: 100%; transition: border-color 0.15s, background 0.15s; } .cckc-opt-ico { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 10px; background: #EEF8FC; color: #0091CC; display: flex; align-items: center; justify-content: center; } .cckc-opt-ico svg { width: 22px; height: 22px; } .cckc-opt-txt { flex: 1; min-width: 0; } .cckc-opt-name { display: block; font-size: 0.92em; font-weight: 700; color: #1E293B; line-height: 1.3; } .cckc-opt-desc { display: block; font-size: 0.77em; color: #64748B; margin-top: 3px; line-height: 1.45; } .cckc-pill { display: inline-block; margin-top: 7px; font-size: 0.62em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; border-radius: 100px; padding: 3px 9px; } .cckc-pill-amb { background: #F1F5F9; color: #64748B; } .cckc-pill-hot { background: #FEF3E2; color: #B45309; } .cckc-tick { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; border: 2px solid #CBD5E1; margin-top: 2px; display: flex; align-items: center; justify-content: center; color: #fff; } .cckc-tick svg { width: 13px; height: 13px; opacity: 0; } .cckc-opt.cckc-on { border-color: #00aeef; background: #EEF8FC; } .cckc-opt.cckc-on .cckc-tick { background: #00aeef; border-color: #00aeef; } .cckc-opt.cckc-on .cckc-tick svg { opacity: 1; } .cckc-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; flex-wrap: wrap; } .cckc-back { background: transparent; border: 1px solid #DBDBDB; color: #64748B; border-radius: 8px; padding: 11px 18px; font-family: inherit; font-size: 0.85em; font-weight: 700; cursor: pointer; } .cckc-next { background: #00aeef; color: #fff; border: none; border-radius: 8px; padding: 13px 30px; font-family: inherit; font-size: 0.92em; font-weight: 800; cursor: pointer; } .cckc-next:disabled { opacity: 0.45; cursor: not-allowed; } .cckc-hide { display: none !important; } .cckc-results-head { background: linear-gradient(135deg, #000 0%, #1E293B 65%, #003A55 100%); border-radius: 14px; padding: 28px 26px; margin-top: 16px; color: #fff; } .cckc-vbadge { display: inline-flex; align-items: center; gap: 7px; font-size: 0.68em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; border-radius: 100px; padding: 6px 14px; margin-bottom: 14px; background: rgba(0,174,239,0.14); border: 1px solid rgba(0,174,239,0.45); color: #7FD6F7; } .cckc-vtitle { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; font-size: clamp(21px, 3.4vw, 30px); font-weight: 800; color: #fff !important; line-height: 1.18; margin: 0 0 8px; } .cckc-vsub { font-size: 0.9em; color: #AEC0D4; max-width: 640px; } .cckc-answers { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; } .cckc-ans-chip { background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.15); border-radius: 100px; padding: 5px 13px; font-size: 0.73em; font-weight: 700; color: #DCE7F2; } .cckc-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(145px, 1fr)); gap: 12px; margin-top: 20px; } .cckc-metric { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); border-radius: 10px; padding: 14px 13px; } .cckc-metric-hero { background: rgba(0,174,239,0.12); border-color: rgba(0,174,239,0.45); } .cckc-m-label { font-size: 0.64em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: #8FA6BC; margin-bottom: 6px; } .cckc-m-value { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; font-size: 1.25em; font-weight: 800; line-height: 1.1; color: #fff; } .cckc-group-h { display: flex; align-items: center; gap: 10px; font-size: 0.78em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.09em; margin: 22px 2px 10px; } .cckc-group-h::after { content: “”; flex: 1; height: 1px; background: #E2E8F0; } .cckc-gh-must { color: #0091CC; } .cckc-gh-flag { color: #B45309; } .cckc-gh-info { color: #64748B; } .cckc-gh-done { color: #16a34a; } .cckc-item { display: flex; gap: 14px; background: #fff; border: 1px solid #E2E8F0; border-radius: 12px; padding: 16px 17px; margin-top: 9px; border-left: 4px solid #CBD5E1; } .cckc-l-must { border-left-color: #00aeef; } .cckc-l-flag { border-left-color: #F5A623; } .cckc-l-done { border-left-color: #16a34a; } .cckc-l-info { border-left-color: #CBD5E1; } .cckc-item-ico { flex: 0 0 auto; width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; } .cckc-item-ico svg { width: 21px; height: 21px; } .cckc-l-must .cckc-item-ico { background: #EEF8FC; color: #0091CC; } .cckc-l-flag .cckc-item-ico { background: #FEF3E2; color: #B45309; } .cckc-l-done .cckc-item-ico { background: #EAF7EF; color: #16a34a; } .cckc-l-info .cckc-item-ico { background: #F1F5F9; color: #64748B; } .cckc-item-main { flex: 1; min-width: 0; } .cckc-item-title { display: block; font-size: 0.95em; font-weight: 800; color: #1E293B; line-height: 1.3; } .cckc-item-body { display: block; font-size: 0.84em; color: #475569; margin-top: 5px; } .cckc-item-law { display: block; font-size: 0.75em; color: #64748B; margin-top: 8px; padding-top: 8px; border-top: 1px dashed #E2E8F0; } .cckc-item-law em { font-style: normal; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.9em; color: #94A3B8; } .cckc-item-law a { color: #0091CC; font-weight: 700; text-decoration: none; } .cckc-item-law a:hover { text-decoration: underline; } .cckc-kit-note { background: #F9FAFB; border: 1px solid #E2E8F0; border-radius: 10px; padding: 14px 16px; font-size: 0.86em; color: #475569; margin-bottom: 16px; } .cckc-kit-note strong { color: #1E293B; } .cckc-tier-name { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; font-size: 1.15em; font-weight: 800; color: #1E293B; margin: 0 0 4px; } .cckc-tier-line { font-size: 0.86em; color: #475569; margin: 0 0 16px; } .cckc-tier-line a { color: #0091CC; font-weight: 700; text-decoration: none; } .cckc-prod-row { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 2px 2px 10px; } .cckc-prod { flex: 0 0 215px; scroll-snap-align: start; background: #fff; border: 1px solid #E2E8F0; border-radius: 12px; padding: 15px 15px 14px; display: flex; flex-direction: column; } .cckc-prod-role { font-size: 0.62em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: #0091CC; margin-bottom: 7px; } .cckc-prod-name { font-size: 0.8em; font-weight: 700; color: #1E293B; line-height: 1.4; margin-bottom: 9px; min-height: 3.2em; } .cckc-prod-price { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; font-size: 1.25em; font-weight: 800; color: #1E293B; } .cckc-prod-vat { font-size: 0.66em; color: #94A3B8; } .cckc-prod-fin { font-size: 0.7em; color: #16a34a; font-weight: 700; margin-top: 5px; min-height: 1.2em; } .cckc-wrap div > br { display: none !important; } header.entry-header.ast-no-title { display: none !important; } .cckc-prod-imgbox { margin: -15px -15px 12px; height: 142px; background: #fff; border-bottom: 1px solid #F1F5F9; border-radius: 12px 12px 0 0; display: flex; align-items: center; justify-content: center; padding: 10px; } .cckc-prod-imgbox img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; } .cckc-live-pill { display: inline-flex; align-items: center; gap: 7px; margin-left: 10px; font-size: 0.66em; font-weight: 800; text-transform: uppercase; letter-spacing: 0.07em; color: #0B7A44; background: #EAFBF2; border: 1px solid #BBEAD1; border-radius: 999px; padding: 3px 10px; vertical-align: middle; } .cckc-live-dot { width: 7px; height: 7px; border-radius: 50%; background: #16a34a; animation: cckcPulse 1.6s ease-in-out infinite; } @keyframes cckcPulse { 0%,100% { opacity: 1; transform: scale(1);} 50% { opacity: .45; transform: scale(.8);} } @media (prefers-reduced-motion: reduce) { .cckc-live-dot { animation: none; } } .cckc-prod-view { display: block; text-align: center; background: #00aeef; color: #fff !important; border-radius: 7px; padding: 9px 10px; font-size: 0.76em; font-weight: 800; text-decoration: none !important; margin-top: 11px; } .cckc-prod-view:hover { background: #0091CC; } .cckc-cta { background: linear-gradient(135deg, #000 0%, #1E293B 65%, #003A55 100%); border-radius: 14px; padding: 24px 24px 20px; margin-top: 16px; color: #fff; } .cckc-cta-title { font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif; font-size: 1.1em; font-weight: 800; color: #fff !important; margin: 0 0 4px; } .cckc-cta-sub { font-size: 0.83em; color: #AEC0D4; margin: 0 0 16px; } .cckc-cta-row { display: flex; flex-wrap: wrap; gap: 10px; } .cckc-copybtn { display: inline-flex; align-items: center; gap: 8px; background: #00aeef; color: #fff; border: none; border-radius: 8px; padding: 13px 22px; font-family: inherit; font-size: 0.88em; font-weight: 800; cursor: pointer; } .cckc-copybtn svg { width: 17px; height: 17px; } .cckc-btn-ghostlink { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.22); color: #fff !important; border-radius: 8px; padding: 13px 22px; font-size: 0.88em; font-weight: 800; text-decoration: none !important; } .cckc-btn-ghostlink:hover { background: rgba(255,255,255,0.16); } .cckc-btn-ghostlink svg { width: 17px; height: 17px; } .cckc-scot { font-size: 0.78em; color: #64748B; margin-top: 14px; padding: 12px 15px; background: #F9FAFB; border: 1px solid #E2E8F0; border-radius: 10px; } .cckc-disclaimer { font-size: 0.72em; color: #94A3B8; margin-top: 12px; line-height: 1.6; } .cckc-restart-row { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; } .cckc-wrap button.cckc-opt { background: #F9FAFB !important; color: #334155 !important; border: 1px solid #DBDBDB !important; border-left: 1px solid #DBDBDB !important; border-radius: 11px !important; padding: 15px 16px !important; font-size: 1em !important; font-weight: 400 !important; text-transform: none !important; letter-spacing: normal !important; box-shadow: none !important; } .cckc-wrap button.cckc-opt:hover, .cckc-wrap button.cckc-opt:focus { background: #EEF8FC !important; border-color: #00aeef !important; color: #334155 !important; } .cckc-wrap button.cckc-opt.cckc-on, .cckc-wrap button.cckc-opt.cckc-on:hover, .cckc-wrap button.cckc-opt.cckc-on:focus { background: #EEF8FC !important; border-color: #00aeef !important; color: #334155 !important; } .cckc-wrap button.cckc-next { background: #00aeef !important; color: #fff !important; border: none !important; border-radius: 8px !important; padding: 13px 30px !important; font-size: 0.92em !important; font-weight: 800 !important; text-transform: none !important; letter-spacing: normal !important; box-shadow: none !important; } .cckc-wrap button.cckc-next:hover, .cckc-wrap button.cckc-next:focus { background: #0091CC !important; color: #fff !important; } .cckc-wrap button.cckc-next:disabled { background: #A5DFF7 !important; color: #fff !important; } .cckc-wrap button.cckc-back { background: transparent !important; color: #64748B !important; border: 1px solid #DBDBDB !important; border-radius: 8px !important; padding: 11px 18px !important; font-size: 0.85em !important; font-weight: 700 !important; text-transform: none !important; letter-spacing: normal !important; box-shadow: none !important; } .cckc-wrap button.cckc-back:hover, .cckc-wrap button.cckc-back:focus { background: #F1F5F9 !important; color: #334155 !important; border-color: #CBD5E1 !important; } .cckc-wrap button.cckc-copybtn { background: #00aeef !important; color: #fff !important; border: none !important; border-radius: 8px !important; padding: 13px 22px !important; font-size: 0.88em !important; font-weight: 800 !important; text-transform: none !important; letter-spacing: normal !important; box-shadow: none !important; } .cckc-wrap button.cckc-copybtn:hover, .cckc-wrap button.cckc-copybtn:focus { background: #0091CC !important; color: #fff !important; } .cckc-wrap .cckc-hero h2 { color: #fff !important; font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif !important; } .cckc-wrap .cckc-hero h2 em { color: #00aeef !important; } .cckc-wrap .cckc-vtitle, .cckc-wrap .cckc-cta-title { color: #fff !important; font-family: ‘Varela Round’, ‘Figtree’, Arial, sans-serif !important; } .cckc-hero-bg { position:absolute !important; inset:0; width:100%; height:100%; object-fit:cover; object-position:center 42%; z-index:0 !important; opacity:.34; filter:saturate(.9) contrast(1.05); } .cckc-hero::before { content:””; position:absolute; inset:0; z-index:1; background:linear-gradient(90deg,rgba(0,0,0,.9) 0%,rgba(12,20,29,.78) 48%,rgba(0,42,61,.38) 100%); } .cckc-hero > :not(.cckc-hero-bg) { position:relative; z-index:2; } .cckc-step-visual { display:block; width:100%; height:180px; object-fit:cover; object-position:center 48%; border-radius:10px; margin:0 0 22px; border:1px solid #D8E3E9; } .cckc-result-visual { display:block; width:100%; height:210px; object-fit:cover; object-position:center 40%; border-radius:10px; margin:0 0 22px; border:1px solid rgba(255,255,255,.16); } @media (max-width:560px){.cckc-step-visual{height:128px;margin-bottom:18px}.cckc-result-visual{height:150px}.cckc-hero-bg{object-position:62% center}.cckc-hero::before{background:rgba(5,12,18,.78)}} /* Dimensional, object-like option icons */ .cckc-opt-ico { position:relative; overflow:hidden; width:48px; height:48px; border-radius:14px; color:#007EAF; background:linear-gradient(145deg,#FFFFFF 0%,#DDF4FC 58%,#BCE9F8 100%); border:1px solid #C4E8F5; box-shadow:0 5px 12px rgba(0,117,163,.14),inset 0 1px 0 rgba(255,255,255,.95),inset 0 -2px 5px rgba(0,145,204,.08); } .cckc-opt-ico::before { content:””; position:absolute; left:7px; right:7px; top:5px; height:13px; border-radius:999px; background:linear-gradient(180deg,rgba(255,255,255,.9),rgba(255,255,255,0)); transform:rotate(-8deg); pointer-events:none; } .cckc-opt-ico::after { content:””; position:absolute; width:22px; height:7px; left:13px; bottom:4px; border-radius:50%; background:rgba(0,84,119,.12); filter:blur(3px); pointer-events:none; } .cckc-opt-ico svg { position:relative; z-index:1; width:27px; height:27px; stroke:currentColor; stroke-width:2.15; filter:drop-shadow(0 1px 0 rgba(255,255,255,.95)); } .cckc-opt:has(.cckc-pill-hot) .cckc-opt-ico { color:#A94F08; background:linear-gradient(145deg,#FFFDF8 0%,#FFF0D8 58%,#FFD7A3 100%); border-color:#F4D19F; box-shadow:0 5px 12px rgba(180,83,9,.13),inset 0 1px 0 #fff,inset 0 -2px 5px rgba(180,83,9,.08); } .cckc-opt[data-val=”yes”] .cckc-opt-ico { color:#147A48; background:linear-gradient(145deg,#FFFFFF 0%,#DDF5E8 58%,#B9E7CE 100%); border-color:#BCE4CF; } .cckc-opt[data-val=”no”] .cckc-opt-ico { color:#A94F08; background:linear-gradient(145deg,#FFFDF8 0%,#FFF0D8 58%,#FFD7A3 100%); border-color:#F4D19F; } .cckc-opt[data-val=”notyet”] .cckc-opt-ico { color:#526171; background:linear-gradient(145deg,#FFFFFF 0%,#EEF2F6 58%,#D7E0E8 100%); border-color:#D8E1E8; } .cckc-opt.cckc-on .cckc-opt-ico { color:#fff; background:linear-gradient(145deg,#35C6F6 0%,#00AEEF 48%,#007FB2 100%); border-color:#008FC8; box-shadow:0 7px 16px rgba(0,145,204,.28),inset 0 1px 0 rgba(255,255,255,.5),inset 0 -3px 8px rgba(0,61,86,.18); } .cckc-opt.cckc-on .cckc-opt-ico::after { background:rgba(0,35,50,.18); } @media(max-width:560px){.cckc-opt-ico{width:44px;height:44px;border-radius:12px}.cckc-opt-ico svg{width:25px;height:25px}}

Home baker in an organised cake studio with refrigeration and compliance recordsFree · 2-minute checker

Is your cake business
fully legal?

Four questions. A personalised checklist with the actual law behind every line — registration, fridge rules, Natasha’s Law, planning and insurance. Built for home bakers and cake sheds in England and Wales.

28 days — registration lead time8°C — the legal chill limit14 allergens — Natasha’s Law
Step 1 of 4

Ambient cakes and chilled high-risk cakes shown side by side

01 / What do you sell?

Tick everything on your menu — this decides which fridge law applies to you.

Family kitchen, garden shed and dedicated cake studio compared side by side

02 / Where do you bake?

The building decides your planning, insurance and fridge-environment flags.

Made-to-order collection, honesty stall and online cake order routes

03 / How do you sell?

Tick every route you use — each one carries its own allergen-labelling rule.

Food-safety records, calendar, thermometer and cake box arranged for business readiness

04 / Registered with your council?

Food business registration is free, cannot be refused — and has a legal deadline.

Organised cake-business compliance kitYour personalised checklist

Your checklist / Every line, with the law behind it

Covers England and Wales. Scotland’s food temperature law is worded differently — there is no 8°C figure — so check Scottish guidance if you’re there.

Your kit tier / Making the outcome provable

Straight answer first: the law never says “buy a commercial fridge”. It says high-risk food above 8°C is an offence — and your daily records have to prove it never happens. Kit is how you make that outcome provable, not a legal requirement in itself.

Prices ex VAT · in stock at time of writing · finance figures are illustrative, subject to status.
Take your checklist with you

Copy it, save it, tick it off — and if the fridge question is the bit you’re unsure about, that’s the bit we do all day.

General guidance for England and Wales, not legal advice — your local council’s environmental health team has the final word on your setup. Product prices ex VAT and correct at time of writing. Craven Cooling.

(() => {
var root = document.querySelector(‘.cckc-wrap’);
if (!root) return;
if (root.dataset.cckcBound) return;
root.dataset.cckcBound = ‘1’;
var $ = (id) => document.getElementById(id);
var esc = (s) => { var d = document.createElement(‘div’); d.textContent = s; return d.innerHTML; };
var money = (n) => ‘£’ + n.toLocaleString(‘en-GB’, { minimumFractionDigits: (n % 1 === 0 ? 0 : 2), maximumFractionDigits: 2 });
var reduced = window.matchMedia ? window.matchMedia(‘(prefers-reduced-motion: reduce)’).matches : false;
var state = { sell: {}, where: null, how: {}, reg: null };
var hist = [];
var STEPS = [‘cckc-step1’, ‘cckc-step2’, ‘cckc-step3’, ‘cckc-step4’];
var SELL_LABELS = {
traybakes: ‘Brownies and traybakes’,
celebration: ‘Celebration cakes’,
freshcream: ‘Fresh cream’,
cheesecake: ‘Cheesecake’,
creamcheese: ‘Cream-cheese frosting’,
royalicing: ‘Raw-egg royal icing’
};
var WHERE_LABELS = { kitchen: ‘Family kitchen’, shed: ‘Shed / garden building’, room: ‘Dedicated garden room’ };
var HOW_LABELS = { collection: ‘Made-to-order collection’, honesty: ‘Honesty box / stall’, online: ‘Online and social orders’ };
var REG_LABELS = { yes: ‘Registered’, no: ‘Not registered’, notyet: ‘Not trading yet’ };
var HIGH = [‘freshcream’, ‘cheesecake’, ‘creamcheese’, ‘royalicing’];
var PRODUCTS = {
hallco: { id: 164498, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/07/hr200sn-hf200sn.webp’, name: ‘Hallco Undercounter Fridge 127 Litre Stainless Steel HR200SN’, price: 359, role: ‘Separate business fridge’, url: ‘https://www.cravencooling.co.uk/product/commercial-storage/storage-fridges/commercial-upright-fridges/under-counter-fridges/hallco-undercounter-fridge-127-litre-stainless-steel-hr200sn/’ },
ur200g: { id: 152430, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/07/cGVyZmlvbi83ZWIxOTViOS1mNjMzLTQ5MjMtYmZmZS03Nzc1NTE5OWUzZWEucG5n.webp’, name: ‘TEFCOLD UR200G Glass Door Merchandiser’, price: 374, role: ‘See-at-a-glance stock’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/glass-door-fridges/under-counter-glass-door-fridges/tefcold-ur200g-glass-door-merchandiser/’ },
polar120: { id: 133626, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/05/pg003_ctg24-1.jpg’, name: ‘Polar G-Series Countertop Display Fridge Black Square Glass 120Ltr PG003’, price: 580.13, role: ‘Countertop display — the honesty-shelf unlock’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/cake-display-fridges/countertop-cake-display-fridges/polar-g-series-countertop-display-fridge-black-square-glass-120ltr-pg003/’ },
polar160: { id: 133634, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/05/pg004_ctg24-2.jpg’, name: ‘Polar G-Series Countertop Display Fridge Black Square Glass 160Ltr PG004’, price: 599.93, role: ‘Countertop display — bigger shelf’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/cake-display-fridges/countertop-cake-display-fridges/polar-g-series-countertop-display-fridge-black-square-glass-160ltr-pg004/’ },
polarround: { id: 133753, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/05/pg026_npi25-1.jpg’, name: ‘Polar G-Series Rounded Glass Countertop Display Fridge 145Ltr PG026’, price: 799.91, role: ‘Countertop display — rounded glass’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/cake-display-fridges/countertop-cake-display-fridges/polar-g-series-rounded-glass-countertop-display-fridge-145ltr-pg026/’ },
scu1425: { id: 154378, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/07/cGVyZmlvbi9hMTFmMmRmMC02MTcyLTQ4MmItYjcwNC1iZGU2Nzg1MDhiODAucG5n.webp’, name: ‘TEFCOLD SCU1425H Glass Door Merchandiser’, price: 673, role: ‘Slimline upright glass door’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/glass-door-fridges/single-door-glass-door-fridges/tefcold-scu1425h-glass-door-merchandiser/’ },
atomc1db: { id: 154084, img: ‘https://www.cravencooling.co.uk/wp-content/uploads/2026/07/cGVyZmlvbi80MWU0NmQ4NC1hZDRkLTQ0MGQtYTc4My0wODNhZWFiN2U3NjYucG5n.webp’, name: ‘TEFCOLD Atom Maxi C1DB Glass Door Merchandiser’, price: 906, role: ‘Full-height glass door merchandiser’, url: ‘https://www.cravencooling.co.uk/product/commercial-display/fridges/glass-door-fridges/single-door-glass-door-fridges/tefcold-atom-maxi-c1db-glass-door-merchandiser/’ }
};
var ICO = {
clip: ”,
therm: ”,
alert: ”,
info: ”,
check: ”,
tag: ”,
home: ”,
clock: ”
};
var showStep = (idx) => {
STEPS.forEach((id, i) => {
var el = $(id);
if (el) { if (i === idx) el.classList.remove(‘cckc-hide’); else el.classList.add(‘cckc-hide’); }
});
$(‘cckc-results’).classList.add(‘cckc-hide’);
$(‘cckc-progress’).classList.remove(‘cckc-hide’);
$(‘cckc-progress-label’).textContent = ‘Step ‘ + (idx + 1) + ‘ of 4’;
$(‘cckc-bar-fill’).style.width = (((idx + 1) / 4) * 100) + ‘%’;
};
var goTo = (idx) => { hist.push(idx); showStep(idx); };
var goBack = () => {
if (hist.length > 1) { hist.pop(); showStep(hist[hist.length – 1]); }
};
var countSel = (obj) => Object.keys(obj).filter((k) => obj[k]).length;
var syncNext = () => {
var n1 = $(‘cckc-next1’);
var n3 = $(‘cckc-next3’);
if (n1) n1.disabled = countSel(state.sell) === 0;
if (n3) n3.disabled = countSel(state.how) === 0;
};
root.querySelectorAll(‘.cckc-opt’).forEach((btn) => {
btn.addEventListener(‘click’, () => {
var multi = btn.getAttribute(‘data-multi’);
var single = btn.getAttribute(‘data-single’);
var val = btn.getAttribute(‘data-val’);
if (multi) {
state[multi][val] = !state[multi][val];
btn.classList.toggle(‘cckc-on’, !!state[multi][val]);
syncNext();
return;
}
if (single) {
state[single] = val;
var group = root.querySelectorAll(‘.cckc-opt[data-single=”‘ + single + ‘”]’);
group.forEach((b) => { b.classList.toggle(‘cckc-on’, b === btn); });
if (single === ‘where’) { window.setTimeout(() => { goTo(2); }, reduced ? 0 : 180); }
if (single === ‘reg’) { window.setTimeout(() => { showResults(); }, reduced ? 0 : 180); }
}
});
});
$(‘cckc-next1’).addEventListener(‘click’, () => { if (countSel(state.sell) > 0) goTo(1); });
$(‘cckc-next3’).addEventListener(‘click’, () => { if (countSel(state.how) > 0) goTo(3); });
root.querySelectorAll(‘.cckc-back[data-goback]’).forEach((b) => { b.addEventListener(‘click’, goBack); });
var buildItems = () => {
var sells = Object.keys(state.sell).filter((k) => state.sell[k]);
var highRisk = sells.some((k) => HIGH.indexOf(k) > -1);
var ppds = !!state.how.honesty;
var distance = !!state.how.online;
var collection = !!state.how.collection;
var outbuilding = state.where === ‘shed’ || state.where === ‘room’;
var items = [];
if (state.reg === ‘no’) {
items.push({ lvl: ‘must’, ico: ICO.clip, title: ‘Register with your council — at least 28 days before trading’, body: ‘Registration is free, cannot be refused and there is no certificate — but the deadline is real: at least 28 days before you start trading. Winchester’s environmental health team put it plainly: “you can be prosecuted if you do not register before starting.” If you are already selling, register today.’, law: ‘Food business registration is a legal requirement with a 28-day lead time’, src: ‘gov.uk — starting a food business’, url: ‘https://www.gov.uk/guidance/starting-a-food-business’ });
}
if (state.reg === ‘notyet’) {
items.push({ lvl: ‘must’, ico: ICO.clip, title: ‘Put your registration date in the diary now’, body: ‘Count back 28 days from your first planned sale — that is your registration deadline. It is free, cannot be refused, and there is no certificate to wait for, so there is nothing to gain by leaving it late.’, law: ‘Register at least 28 days before trading’, src: ‘gov.uk — starting a food business’, url: ‘https://www.gov.uk/guidance/starting-a-food-business’ });
}
if (state.reg === ‘yes’) {
items.push({ lvl: ‘done’, ico: ICO.check, title: ‘Council registration — done’, body: ‘Expect unannounced inspections: food law applies in a home kitchen exactly as it does to commercial premises. The reassuring bit, in an EHO’s own words: “We’re not expecting a commercial kitchen when we arrive.”’, law: ‘Registered food businesses are inspected and rated’, src: ‘Winchester council EHO guidance for home bakers’, url: ‘https://www.winchester.gov.uk/assets/attach/22945/advice-for-home-bakers-wcc-version.pdf’ });
}
items.push({ lvl: ‘must’, ico: ICO.clip, title: ‘Run SFBB — with the daily fridge temperature diary’, body: ‘A written food-safety management system is a legal requirement, and the FSA’s Safer Food, Better Business (SFBB) pack is the accepted way to run one at home. It includes a diary of daily fridge and freezer temperature checks — Bromley’s EHOs suggest checking at least twice a day. This diary is the record an inspector asks for first.’, law: ‘Regulation 852/2004, Article 5 — HACCP-based procedures’, src: ‘sfbb.org.uk’, url: ‘https://sfbb.org.uk/’ });
if (highRisk) {
items.push({ lvl: ‘must’, ico: ICO.therm, title: ‘8°C is the legal line — run at 5°C or below’, body: ‘Councils name fresh cream, some cheesecakes and raw-egg royal icing as high-risk, and cream-cheese frosting sits under the same dairy principle. Keeping high-risk food above 8°C is a criminal offence in England — Wales has its equivalent in the 2006 regulations. EHOs recommend actually running your fridge at 5°C or below, so a door-opening never takes you over the limit.’, law: ‘Food Safety and Hygiene (England) Regulations 2013, Schedule 4’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/uksi/2013/2996/schedule/4’ });
items.push({ lvl: ‘must’, ico: ICO.clock, title: ‘The 4-hour rule — ONE single period, then chill or bin’, body: ‘Chilled food may be out of temperature control for one single period of under four hours — decorating, photographing, a collection window. It does not reset: after that period the food goes back into the chill or in the bin, and EHOs advise writing the period down.’, law: ‘Schedule 4 tolerance period — a single period under 4 hours’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/uksi/2013/2996/schedule/4’ });
items.push({ lvl: ‘flag’, ico: ICO.therm, title: ‘Don’t trust the door display — fit an internal thermometer’, body: ‘“The accuracy should be checked by an internal thermometer” — West Norfolk’s guidance for cake makers. An independent thermometer plus the daily diary is the cheapest rating-day win there is.’, law: ‘EHO expectation on temperature monitoring’, src: ‘West Norfolk council cake makers guidance’, url: ‘https://www.west-norfolk.gov.uk/download/downloads/id/6393/cakemakers_guidance.pdf’ });
items.push({ lvl: ‘flag’, ico: ICO.home, title: ‘The separate business fridge expectation’, body: ‘Council guidance repeats the same line as you grow: “domestic fridges are not designed to cope with large amounts of food” (Ealing). A separate business fridge — or at minimum a strictly separated section — is what inspectors expect once volume builds. Overloading kills airflow, and airflow is what holds temperature.’, law: ‘EHO expectation, stated by Ealing, Winchester and West Norfolk’, src: ‘Ealing council home catering guidance’, url: ‘https://www.ealing.gov.uk/info/201016/food_businesses/3150/support_and_guidance_for_home_catering_businesses/2’ });
if (collection) {
items.push({ lvl: ‘must’, ico: ICO.therm, title: ‘The cold chain travels with the cake’, body: ‘Temperature control does not stop at your door: high-risk cakes must stay at 8°C or below in transport and at handover too — the law requires an unbroken cold chain.’, law: ‘Regulation 852/2004, Annex II, Chapter IX(5) — the cold chain must not be interrupted’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/eur/2004/852/annex/II’ });
}
if (distance) {
items.push({ lvl: ‘must’, ico: ICO.therm, title: ‘Delivered orders: the cold chain still applies’, body: ‘High-risk cakes ordered online must stay at 8°C or below through delivery or collection — the unbroken cold chain is a legal requirement, not a nice-to-have.’, law: ‘Regulation 852/2004, Annex II, Chapter IX(5)’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/eur/2004/852/annex/II’ });
}
items.push({ lvl: ‘info’, ico: ICO.clock, title: ‘Date cautiously: day of production plus two’, body: ‘For cakes, Winchester’s EHO team recommend a shelf life of “day of production +2”. Cautious dating protects your customers and your rating.’, law: ‘EHO shelf-life advice for home-baked cakes’, src: ‘Winchester council EHO guidance for home bakers’, url: ‘https://www.winchester.gov.uk/assets/attach/22945/advice-for-home-bakers-wcc-version.pdf’ });
} else {
items.push({ lvl: ‘info’, ico: ICO.check, title: ‘Your bakes are low-risk — the chilled-storage law doesn’t bite (yet)’, body: ‘Brownies, traybakes and sugar-paste celebration cakes are ambient bakes, so the 8°C rules don’t apply to them. The moment you add fresh cream, cheesecake or cream-cheese frosting, they do — worth knowing before you say yes to that first fresh-cream order.’, law: ‘The 8°C requirement applies to food needing temperature control’, src: ‘Food Safety and Hygiene (England) Regulations 2013, Schedule 4’, url: ‘https://www.legislation.gov.uk/uksi/2013/2996/schedule/4’ });
}
if (ppds) {
items.push({ lvl: ‘must’, ico: ICO.tag, title: ‘Natasha’s Law applies: your pre-packed shelf is PPDS’, body: ‘A cake boxed BEFORE the customer chooses it — an honesty-box shelf or a pre-packed stall — is “prepacked for direct sale” (PPDS). Every one needs a full ingredient label with the 14 allergens emphasised. The bakery heavy-hitters: gluten, egg, milk, nuts, peanuts, soya, and sulphites in dried fruit.’, law: ‘PPDS allergen labelling (Natasha’s Law)’, src: ‘gov.uk — introduction to allergen labelling for PPDS food’, url: ‘https://www.gov.uk/government/publications/introduction-to-allergen-labelling-for-ppds-food/introduction-to-allergen-labelling-for-ppds-food’ });
} else if (collection) {
items.push({ lvl: ‘info’, ico: ICO.tag, title: ‘Made-to-order is NOT PPDS — but allergen info is still due’, body: ‘A bespoke cake boxed at the point of order is not prepacked for direct sale, so no full ingredient label is required — but you must still be able to give customers the allergen information for the 14 allergens.’, law: ‘The PPDS distinction — packed before vs at the point of order’, src: ‘gov.uk — introduction to allergen labelling for PPDS food’, url: ‘https://www.gov.uk/government/publications/introduction-to-allergen-labelling-for-ppds-food/introduction-to-allergen-labelling-for-ppds-food’ });
}
if (distance) {
items.push({ lvl: ‘must’, ico: ICO.tag, title: ‘Distance selling: give allergen information TWICE’, body: ‘Taking orders over Facebook, Instagram, the phone or a website is distance selling. Allergen information must be given twice — before the purchase is completed AND again when the cake is delivered or collected.’, law: ‘FSA distance-selling allergen requirements’, src: ‘food.gov.uk — distance selling and pre-ordering’, url: ‘https://www.food.gov.uk/business-guidance/allergen-information-for-non-prepacked-foods-best-practice-distance-selling-and-pre-ordering’ });
}
if (state.where === ‘kitchen’) {
items.push({ lvl: ‘info’, ico: ICO.home, title: ‘Your family kitchen is legally a food business premises’, body: ‘Food law applies to a home kitchen exactly as it does to commercial premises, and inspections are unannounced — but “we’re not expecting a commercial kitchen when we arrive” (Winchester EHO). Your hygiene rating is published online; your home address is not.’, law: ‘Home kitchens fall under the same food hygiene law’, src: ‘Winchester council EHO guidance for home bakers’, url: ‘https://www.winchester.gov.uk/assets/attach/22945/advice-for-home-bakers-wcc-version.pdf’ });
}
if (outbuilding) {
items.push({ lvl: ‘flag’, ico: ICO.home, title: ‘Planning: “incidental use” vs a business’, body: ‘Outbuilding permitted development covers use “incidental to the enjoyment of the dwellinghouse”. Regular trade, customer visits or a dedicated bakery building can trip a “material change of use” — it depends on scale and traffic, and councils themselves say take advice from the planning department. Renting or mortgaged? Your landlord, lender or title deeds can also have a say.’, law: ‘Permitted development rules for outbuildings’, src: ‘Planning Portal — outbuildings’, url: ‘https://www.planningportal.co.uk/permission/common-projects/outbuildings/planning-permission/’ });
items.push({ lvl: ‘flag’, ico: ICO.info, title: ‘Business rates can apply to a dedicated business building’, body: ‘A building used wholly for the business, or customers visiting, can trigger business rates. Small business rate relief is 100% below £12,000 rateable value — so this is usually a conversation with the council, not a bill. Worth the call before they call you.’, law: ‘Working from home and business rates’, src: ‘gov.uk — introduction to business rates’, url: ‘https://www.gov.uk/introduction-to-business-rates/working-at-home’ });
items.push({ lvl: ‘flag’, ico: ICO.alert, title: ‘Insurance: home cover won’t stretch to the business’, body: ‘Home insurance won’t cover a food business. Public and product liability cover is the recommended baseline — and if anyone helps you in the business, employers’ liability insurance is legally required.’, law: ‘Running a business from home — insurance responsibilities’, src: ‘gov.uk — run a business from home’, url: ‘https://www.gov.uk/run-business-from-home’ });
items.push({ lvl: ‘must’, ico: ICO.alert, title: ‘Handwashing: the shed pinch point’, body: ‘The law requires “adequate facilities” for washing hands — in domestic premises, “so far as is reasonably practicable”. One-sink workarounds are accepted in home kitchens; a garden building with no hot water is where inspections get difficult. Solve water before you solve worktops.’, law: ‘Regulation 852/2004, Annex II, Chapter III — domestic premises’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/eur/2004/852/annex/II’ });
items.push({ lvl: ‘must’, ico: ICO.alert, title: ‘Pest-proof the building’, body: ‘Pest-proofing is a legal requirement, and garden buildings are the classic rodent risk. Proof the building before the first bake, not after the first evidence.’, law: ‘Regulation 852/2004, Annex II, Chapter IX(4) — pest control’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/eur/2004/852/annex/II’ });
}
if (state.where === ‘shed’) {
items.push({ lvl: ‘flag’, ico: ICO.therm, title: ‘A domestic fridge is outside its design range in a shed’, body: ‘Domestic fridges are rated by climate class: SN covers 10–32°C room temperature, N covers 16–32°C. An uninsulated garden building spends much of the year outside those ranges at both ends — and West Norfolk’s EHO guidance warns directly that fridges in external storage spaces without good ventilation “may impact on their effectiveness”. Commercial cabinets are tested to hold food temperature at 25/30/40°C ambients (EN ISO 23953 climate classes 3/4/5) — and note that domestic warranties commonly exclude business use.’, law: ‘Climate-class design ranges vs commercial test standards’, src: ‘West Norfolk council cake makers guidance’, url: ‘https://www.west-norfolk.gov.uk/download/downloads/id/6393/cakemakers_guidance.pdf’ });
}
if (ppds) {
if (state.where === ‘shed’) {
items.push({ lvl: ‘flag’, ico: ICO.info, title: ‘Driveway sheds and street trading — one call settles it’, body: ‘Some councils have taken the view that a driveway cake shed needs a street trading licence — a 2026 Nottinghamshire dispute over exactly this made national news. Rare, but a five-minute call to your council settles it before a letter does.’, law: ‘Street trading rules vary by council’, src: ‘reported nationally, 2026 (Bassetlaw dispute)’, url: ” });
}
}
items.push({ lvl: ‘info’, ico: ICO.info, title: ‘Level 2 food hygiene — expected, not technically compulsory’, body: ‘No law names a certificate, but training “commensurate with the work activity” is required — and council EHOs name Level 2 Food Hygiene (Catering) as sufficient for a home baking business.’, law: ‘Regulation 852/2004, Annex II, Chapter XII — training’, src: ‘legislation.gov.uk’, url: ‘https://www.legislation.gov.uk/eur/2004/852/annex/II’ });
return items;
};
var pickKit = () => {
var sells = Object.keys(state.sell).filter((k) => state.sell[k]);
var highRisk = sells.some((k) => HIGH.indexOf(k) > -1);
var ppds = !!state.how.honesty;
var bigRoom = state.where === ‘room’;
var out = { ids: [], name: ”, line: ”, short: ” };
if (!highRisk) {
out.ids = [‘hallco’, ‘ur200g’];
out.name = ‘Starter tier — the separate business fridge’;
out.short = ‘Separate fridge’;
out.line = ‘No fridge law bites on ambient bakes — this tier is about the EHO expectation of separate, uncrowded business storage as you grow, with a readout you can trust for the SFBB diary. From ‘ + money(359) + ‘ ex VAT.’ + (ppds ? ‘ When youu2019re ready to add fresh-cream or cheesecake lines to the shelf, a countertop chilled display (from ‘ + money(580.13) + ‘) becomes the unlock u2014 the Cake Shed Guide covers that step.’ : ”);
} else if (ppds) {
out.ids = bigRoom ? [‘polar120’, ‘polar160’, ‘atomc1db’, ‘hallco’] : [‘polar120’, ‘polar160’, ‘scu1425’, ‘hallco’];
out.name = ‘The chilled display unlock u2014 shed-sized’;
out.short = ‘Chilled display’;
out.line = ‘A pre-packed shelf canu2019t lawfully carry fresh cream or cheesecake unless itu2019s provably held at 8u00b0C or below u2014 which is why most honesty boxes only sell traybakes. A countertop chilled display, from ‘ + money(580.13) + ‘ ex VAT, turns the honesty shelf into a chilled counter that actually fits a shed u2014 it sits on the bench, plugs into a 13A socket, and your best-margin bakes go on sale. Stepping up? The rounded-glass Polar (‘ + money(799.91) + ‘) and the Atom Maxi full-height merchandiser (‘ + money(906) + ‘) grow with the queue.’;
} else {
out.ids = bigRoom ? [‘hallco’, ‘ur200g’, ‘scu1425’] : [‘hallco’, ‘ur200g’];
out.name = ‘High-risk tier u2014 provable 8u00b0C storage’;
out.short = ‘Provable 8u00b0C’;
out.line = ‘Your high-risk bakes make the fridge diary the heart of your paperwork. A commercial cabinet with an accurate readout, from ‘ + money(359) + ‘ ex VAT, is how u201c5u00b0C or belowu201d stops being hope and starts being a record.’ + (bigRoom ? ‘ And with a dedicated production room, a slimline glass door merchandiser adds tall-cake storage you can check at a glance u2014 without giving up floor space.’ : ”);
}
return out;
};
var renderKit = (kit) => {
$(‘cckc-tier-name’).textContent = kit.name;
$(‘cckc-tier-line’).innerHTML = kit.line;
var html = ”;
kit.ids.forEach((id) => {
var p = PRODUCTS[id];
var fin = ”;
if (p.price > 1000) {
var wk = p.price * 0.00535;
fin = ‘≈ £’ + wk.toFixed(2) + ‘ a week over 5 years, subject to status’;
}
var stockTxt = (p.inStock === false) ? ‘ex VAT · check availability’ : ‘ex VAT · in stock’;
var imgTag = p.img ? ” : ”;
html += ” + imgTag + ” + esc(p.role) + ” +
” + esc(p.name) + ” +
” + money(p.price) + ” +
” + stockTxt + ” +
” + fin + ” +
‘View product’;
});
$(‘cckc-kit’).innerHTML = html;
fetchLive();
};
var liveState = 0; // 0 = not tried, 1 = in flight, 2 = done
var API_BASE = /cravencooling/.test(location.hostname) ? ” : ‘https://www.cravencooling.co.uk’;
var fetchLive = () => {
if (liveState) return;
liveState = 1;
var ids = Object.keys(PRODUCTS).map((k) => PRODUCTS[k].id).filter(Boolean);
var qs = [‘include=’ + ids.join(‘,’), ‘per_page=’ + ids.length].join(String.fromCharCode(38));
fetch(API_BASE + ‘/wp-json/wc/store/v1/products?’ + qs)
.then((r) => { if (!r.ok) throw 0; return r.json(); })
.then((rows) => {
var byId = {};
(rows || []).forEach((r) => { byId[r.id] = r; });
var touched = false;
Object.keys(PRODUCTS).forEach((k) => {
var p = PRODUCTS[k];
var r = byId[p.id];
if (!r) return;
var minor = ((r.prices || {}).currency_minor_unit) || 2;
var raw = parseInt((r.prices || {}).price, 10);
if (raw > 0) { p.price = raw / Math.pow(10, minor); touched = true; }
if (r.permalink) { p.url = r.permalink; }
p.inStock = r.is_in_stock !== false;
var img0 = (r.images || [])[0];
if (img0) { if (img0.thumbnail) { p.img = img0.thumbnail; } else if (img0.src) { p.img = img0.src; } }
});
liveState = 2;
if (touched) {
var pill = $(‘cckc-live’);
if (pill) pill.hidden = false;
if (lastKit) renderKit(lastKit);
}
})
.catch(() => { liveState = 2; });
};
var itemHtml = (it) => {
var law = ‘The law: ‘ + it.law +
(it.url ? ‘ · ‘ + esc(it.src) + ” : ‘ · ‘ + esc(it.src)) + ”;
return ” +
” + it.ico + ” +
” + it.title + ” +
” + it.body + ” + law + ”;
};
var lastItems = [];
var lastKit = null;
var showResults = () => {
var sells = Object.keys(state.sell).filter((k) => state.sell[k]);
var highRisk = sells.some((k) => HIGH.indexOf(k) > -1);
var ppds = !!state.how.honesty;
var items = buildItems();
var kit = pickKit();
lastItems = items;
lastKit = kit;
var musts = items.filter((i) => i.lvl === ‘must’);
var flags = items.filter((i) => i.lvl === ‘flag’);
var infos = items.filter((i) => i.lvl === ‘info’);
var dones = items.filter((i) => i.lvl === ‘done’);
var title;
var mword = musts.length === 1 ? ‘must-do’ : ‘must-dos’;
if (state.reg === ‘yes’) { title = ‘Nearly there — ‘ + musts.length + ‘ ‘ + mword + ‘ between you and fully provable.’; }
else if (state.reg === ‘no’) { title = ‘Fixable this week — ‘ + musts.length + ‘ ‘ + mword + ‘ to get properly legal.’; }
else { title = ‘Doable in a weekend — ‘ + musts.length + ‘ ‘ + mword + ‘ before your first sale.’; }
$(‘cckc-vtitle’).textContent = title;
$(‘cckc-vsub’).textContent = highRisk ?
‘Your menu includes high-risk bakes, so the 8°C rules apply — every line below tells you the law behind it, in plain English.’ :
‘Your menu is all ambient bakes, so the chilled rules stay light for now — every line below tells you the law behind it, in plain English.’;
var chips = [];
sells.forEach((k) => { chips.push(SELL_LABELS[k]); });
chips.push(WHERE_LABELS[state.where]);
Object.keys(state.how).forEach((k) => { if (state.how[k]) chips.push(HOW_LABELS[k]); });
chips.push(REG_LABELS[state.reg]);
$(‘cckc-answers’).innerHTML = chips.map((c) => ” + esc(c) + ”).join(”);
var regTile = state.reg === ‘yes’ ? ‘Done’ : (state.reg === ‘notyet’ ? ’28 days before first sale’ : ‘Now — before selling’);
$(‘cckc-tiles’).innerHTML =
‘Must-dos’ + musts.length + ” +
‘Worth checking’ + flags.length + ” +
‘PPDS labels’ + (ppds ? ‘Yes’ : ‘No’) + ” +
‘Register by’ + regTile + ” +
‘Kit tier’ + esc(kit.short) + ”;
var listHtml = ”;
if (musts.length) { listHtml += ‘Must do — the law’ + musts.map(itemHtml).join(”); }
if (flags.length) { listHtml += ‘Worth checking — flags for your setup’ + flags.map(itemHtml).join(”); }
if (infos.length) { listHtml += ‘Good to know’ + infos.map(itemHtml).join(”); }
if (dones.length) { listHtml += ‘Already covered’ + dones.map(itemHtml).join(”); }
$(‘cckc-list’).innerHTML = listHtml;
renderKit(kit);
STEPS.forEach((id) => { $(id).classList.add(‘cckc-hide’); });
$(‘cckc-progress’).classList.add(‘cckc-hide’);
$(‘cckc-results’).classList.remove(‘cckc-hide’);
root.scrollIntoView({ behavior: reduced ? ‘auto’ : ‘smooth’, block: ‘start’ });
};
var stripTags = (s) => { var d = document.createElement(‘div’); d.innerHTML = s; return d.textContent; };
var buildCopyText = () => {
var B = String.fromCharCode(8226);
var NL = String.fromCharCode(10);
var lines = [];
lines.push(‘MY CAKE BUSINESS COMPLIANCE CHECKLIST’);
lines.push(‘Built with the free checker at cravencooling.co.uk (England and Wales)’);
var sells = Object.keys(state.sell).filter((k) => state.sell[k]).map((k) => SELL_LABELS[k]);
var hows = Object.keys(state.how).filter((k) => state.how[k]).map((k) => HOW_LABELS[k]);
lines.push(‘My answers: ‘ + sells.join(‘, ‘) + ‘ | ‘ + WHERE_LABELS[state.where] + ‘ | ‘ + hows.join(‘, ‘) + ‘ | ‘ + REG_LABELS[state.reg]);
lines.push(”);
var groups = [[‘must’, ‘MUST DO — THE LAW’], [‘flag’, ‘WORTH CHECKING’], [‘info’, ‘GOOD TO KNOW’], [‘done’, ‘ALREADY COVERED’]];
groups.forEach((g) => {
var its = lastItems.filter((i) => i.lvl === g[0]);
if (!its.length) return;
lines.push(g[1] + ‘:’);
its.forEach((it) => {
lines.push(B + ‘ ‘ + stripTags(it.title) + ‘ [‘ + stripTags(it.law) + ‘ — ‘ + it.src + ‘]’);
});
lines.push(”);
});
if (lastKit) {
lines.push(‘MY KIT TIER: ‘ + lastKit.name);
lastKit.ids.forEach((id) => {
var p = PRODUCTS[id];
lines.push(B + ‘ ‘ + p.name + ‘ — ‘ + money(p.price) + ‘ ex VAT — ‘ + p.url);
});
lines.push(”);
}
lines.push(‘Craven Cooling — 01792 732702 — www.cravencooling.co.uk’);
lines.push(‘Covers England and Wales; Scotland differs. General guidance, not legal advice.’);
return lines.join(NL);
};
var copyFallback = (text) => {
var ta = document.createElement(‘textarea’);
ta.value = text;
ta.setAttribute(‘readonly’, ”);
ta.style.position = ‘absolute’;
ta.style.left = ‘-9999px’;
document.body.appendChild(ta);
ta.select();
var ok = false;
try { ok = document.execCommand(‘copy’); } catch (e) { ok = false; }
document.body.removeChild(ta);
return ok;
};
var copyTimer = null;
var copyDone = () => {
var lab = $(‘cckc-copy-label’);
lab.textContent = ‘Copied — paste it anywhere’;
if (copyTimer) window.clearTimeout(copyTimer);
copyTimer = window.setTimeout(() => { lab.textContent = ‘Copy my checklist’; }, 2200);
};
$(‘cckc-copy’).addEventListener(‘click’, () => {
var text = buildCopyText();
var nav = window.navigator || {};
if (nav.clipboard ? nav.clipboard.writeText : null) {
nav.clipboard.writeText(text).then(copyDone, () => { if (copyFallback(text)) copyDone(); });
} else if (copyFallback(text)) { copyDone(); }
});
var resetSelections = () => {
state = { sell: {}, where: null, how: {}, reg: null };
root.querySelectorAll(‘.cckc-opt’).forEach((b) => { b.classList.remove(‘cckc-on’); });
syncNext();
};
$(‘cckc-edit’).addEventListener(‘click’, () => {
hist = [0];
showStep(0);
syncNext();
root.scrollIntoView({ behavior: reduced ? ‘auto’ : ‘smooth’, block: ‘start’ });
});
$(‘cckc-restart’).addEventListener(‘click’, () => {
resetSelections();
hist = [0];
showStep(0);
root.scrollIntoView({ behavior: reduced ? ‘auto’ : ‘smooth’, block: ‘start’ });
});
hist = [0];
syncNext();
})();