Free
Blog
Leafway Blog
A blog block extracted from the Leafway template, available in Tailwind CSS.
0
33
A blog block extracted from the Leafway template, available in Tailwind CSS.
Free download · up to 5 blocks per day. Unlimited with All-Access
<!DOCTYPE html>
<html lang="en">
<head>
<script>
window.FontAwesomeConfig = { autoReplaceSvg: 'nest' };
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/js/all.min.js" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Leafway Blog | Tailwind CSS UI Block</title>
<meta name="description" content="A blog block extracted from the Leafway template, available in Tailwind CSS.">
<meta name="keywords" content="Leafway, Tailwind CSS template, HTML website template, startup template, mobile app landing page, eco app, green mobility, bike sharing app, sustainable transport, app download page">
<meta name="author" content="Let's templates">
<link rel="canonical" href="">
<meta property="og:type" content="product">
<meta property="og:site_name" content="Let's templates">
<meta property="og:locale" content="en_US">
<meta property="og:url" content="">
<meta property="og:title" content="Leafway | Tailwind CSS Startup Template">
<meta property="og:description" content="A playful, illustrated Tailwind CSS startup template for green mobility apps, with phone hotspots, a commute impact simulator and a transit pass pricing card.">
<meta property="og:image" content="">
<meta property="og:image:alt" content="Leafway template preview">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:url" content="">
<meta name="twitter:title" content="Leafway | Tailwind CSS Startup Template">
<meta name="twitter:description" content="A playful, illustrated Tailwind CSS startup template for green mobility apps, with phone hotspots, a commute impact simulator and a transit pass pricing card.">
<meta name="twitter:image" content="">
<meta name="twitter:image:alt" content="Leafway template preview">
<script src="https://cdn.tailwindcss.com/3.4.17"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=Chivo:wght@300;400;500;700&family=Syne:wght@700;800&display=swap" rel="stylesheet">
<script>
tailwind.config = {
theme: {
extend: {
colors: { leaf: { DEFAULT: '#55ae80', deep: '#3f9168', soft: '#e9f5ee' }, lilac: { DEFAULT: '#b693f2', soft: '#efe6fd' }, lime: '#c8e57c', ink: '#2b2d36' },
fontFamily: { sans: ['Chivo', 'sans-serif'], display: ['Syne', 'sans-serif'] }
}
}
}
</script>
<style>
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 180ms ease-out both page-fade-out; }
::view-transition-new(root) { animation: 220ms ease-in both page-fade-in; }
@keyframes page-fade-out { to { opacity: 0; } }
@keyframes page-fade-in { from { opacity: 0; } }
html { scroll-behavior: smooth; }
[hidden] { display: none !important; }
.float { animation: float 6s ease-in-out infinite; }
.float-slow { animation: float 9s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-10px); } }
.spin-slow { animation: spin 14s linear infinite; transform-origin: center; transform-box: fill-box; }
@keyframes spin { to { transform: rotate(360deg); } }
.hotspot::after { content: ""; position: absolute; inset: -6px; border-radius: 9999px; border: 2px solid currentColor; opacity: .5; animation: ping 1.8s ease-out infinite; }
@keyframes ping { to { transform: scale(1.6); opacity: 0; } }
.sim-tree { transition: opacity .4s ease, transform .4s ease; transform-origin: bottom; transform-box: fill-box; }
.sim-tree[data-off] { opacity: 0; transform: scale(.2); }
.marquee { display: flex; overflow: hidden; gap: 2.5rem; }
.marquee-track { display: flex; flex-shrink: 0; align-items: center; gap: 2.5rem; animation: marquee 32s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(calc(-100% - 2.5rem)); } }
.reveal-ready [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; transition-delay: var(--reveal-delay, 0ms); }
.reveal-ready [data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
html { scroll-behavior: auto; }
.float, .float-slow, .spin-slow, .marquee-track, .hotspot::after { animation: none; }
.marquee { overflow-x: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}
</style>
</head>
<body class="bg-white font-sans text-ink antialiased">
<!-- block:start blog -->
<section class="bg-leaf-soft">
<div class="mx-auto max-w-6xl px-5 py-20 md:px-8 lg:py-28">
<div class="flex flex-wrap items-end justify-between gap-6">
<h2 class="font-display text-4xl font-extrabold md:text-5xl">From the blog</h2>
<a href="blog.html" class="inline-flex items-center gap-2 font-bold underline underline-offset-4">All stories <i class="fa-solid fa-arrow-right" aria-hidden="true"></i></a>
</div>
<div class="mt-12 grid gap-8 lg:grid-cols-[1.3fr_1fr]">
<a href="e-bikes-beat-traffic.html" class="group block overflow-hidden rounded-3xl border-2 border-ink bg-white">
<img src="https://images.unsplash.com/photo-1541625602330-2277a4c46182?auto=format&fit=crop&w=1200&q=80" alt="Two cyclists riding side by side along a coastal road" class="aspect-[16/10] w-full object-cover transition duration-500 group-hover:scale-105" loading="lazy">
<div class="p-6 md:p-8">
<p class="text-sm"><span class="rounded-full bg-lime px-3 py-1 font-bold">Research</span> <span class="ml-2 text-ink/60">Oct 2, 2026 · 6 min read</span></p>
<h3 class="mt-4 text-2xl font-bold md:text-3xl">Why e-bikes beat traffic in 9 out of 10 city trips</h3>
</div>
</a>
<ul class="grid content-start gap-4">
<li>
<a href="e-bikes-beat-traffic.html" class="group flex items-center gap-5 rounded-2xl border-2 border-transparent p-3 transition hover:border-ink hover:bg-white">
<img src="https://images.unsplash.com/photo-1570125909232-eb263c188f7e?auto=format&fit=crop&w=400&q=80" alt="Modern coach bus parked at sunset" class="h-24 w-24 shrink-0 rounded-2xl object-cover" loading="lazy">
<span><span class="text-xs font-bold uppercase tracking-wide text-leaf-deep">Cities</span><span class="mt-1 block text-lg font-bold leading-snug">Night buses are back, and they're electric</span><span class="mt-1 block text-sm text-ink/60">Sep 24, 2026 · 4 min</span></span>
</a>
</li>
<li>
<a href="e-bikes-beat-traffic.html" class="group flex items-center gap-5 rounded-2xl border-2 border-transparent p-3 transition hover:border-ink hover:bg-white">
<img src="https://images.unsplash.com/photo-1497435334941-8c899ee9e8e9?auto=format&fit=crop&w=400&q=80" alt="Rows of solar panels across green fields" class="h-24 w-24 shrink-0 rounded-2xl object-cover" loading="lazy">
<span><span class="text-xs font-bold uppercase tracking-wide text-leaf-deep">Inside Leafway</span><span class="mt-1 block text-lg font-bold leading-snug">Where the power for your ride comes from</span><span class="mt-1 block text-sm text-ink/60">Sep 12, 2026 · 5 min</span></span>
</a>
</li>
<li>
<a href="e-bikes-beat-traffic.html" class="group flex items-center gap-5 rounded-2xl border-2 border-transparent p-3 transition hover:border-ink hover:bg-white">
<img src="https://images.unsplash.com/photo-1441974231531-c6227db76b6e?auto=format&fit=crop&w=400&q=80" alt="Sunlight through a tall green forest" class="h-24 w-24 shrink-0 rounded-2xl object-cover" loading="lazy">
<span><span class="text-xs font-bold uppercase tracking-wide text-leaf-deep">Tips</span><span class="mt-1 block text-lg font-bold leading-snug">Five small habits that cut your travel footprint</span><span class="mt-1 block text-sm text-ink/60">Aug 30, 2026 · 3 min</span></span>
</a>
</li>
</ul>
</div>
</div>
</section>
<!-- block:end blog -->
<script>
document.querySelectorAll('[data-menu-toggle]').forEach((button) => {
const menu = document.getElementById(button.getAttribute('aria-controls'));
if (!menu) return;
button.addEventListener('click', () => {
const open = button.getAttribute('aria-expanded') === 'true';
button.setAttribute('aria-expanded', String(!open));
menu.classList.toggle('hidden', open);
});
});
document.querySelectorAll('[data-hotspots]').forEach((root) => {
const select = (id) => {
root.querySelectorAll('[data-hotspot]').forEach((spot) => spot.setAttribute('aria-pressed', String(spot.dataset.hotspot === id)));
root.querySelectorAll('[data-hotspot-item]').forEach((item) => item.setAttribute('aria-pressed', String(item.dataset.hotspotItem === id)));
};
root.addEventListener('click', (event) => {
const target = event.target.closest('[data-hotspot], [data-hotspot-item]');
if (target) select(target.dataset.hotspot || target.dataset.hotspotItem);
});
});
document.querySelectorAll('[data-simulator]').forEach((sim) => {
const km = sim.querySelector('[data-sim-km]');
const trees = [...sim.querySelectorAll('[data-sim-tree]')];
const checked = (name) => [...sim.querySelectorAll(`[name="${name}"]`)].find((input) => input.checked);
const update = () => {
const mode = checked('mode');
const days = Number(checked('days')?.value || 5);
const distance = Number(km.value);
const kmYear = distance * 2 * days * 48;
const co2 = Math.round((Number(sim.dataset.carGram) - Number(mode.dataset.gram)) * kmYear / 1000);
const money = Math.round((Number(sim.dataset.carCost) - Number(mode.dataset.cost)) * kmYear);
const treeCount = Math.round(co2 / 21);
sim.querySelector('[data-sim-km-label]').textContent = `${distance} km`;
sim.querySelector('[data-sim-co2]').textContent = co2.toLocaleString('en-US');
sim.querySelector('[data-sim-money]').textContent = money.toLocaleString('en-US');
sim.querySelector('[data-sim-trees]').textContent = treeCount.toLocaleString('en-US');
trees.forEach((tree, index) => tree.toggleAttribute('data-off', index >= Math.min(treeCount, trees.length)));
};
sim.addEventListener('input', update);
sim.addEventListener('change', update);
});
document.querySelectorAll('[data-like]').forEach((button) => {
button.addEventListener('click', () => {
const liked = button.getAttribute('aria-pressed') === 'true';
const count = button.querySelector('[data-like-count]');
button.setAttribute('aria-pressed', String(!liked));
count.textContent = Number(count.textContent) + (liked ? -1 : 1);
});
});
document.querySelectorAll('[data-flip]').forEach((card) => {
card.addEventListener('click', () => card.setAttribute('aria-pressed', String(card.getAttribute('aria-pressed') !== 'true')));
});
document.querySelectorAll('[data-compare]').forEach((compare) => {
const range = compare.querySelector('[data-compare-range]');
const update = () => compare.style.setProperty('--split', `${range.value}%`);
range.addEventListener('input', update);
update();
});
document.querySelectorAll('[data-tabs]').forEach((tablist) => {
const tabs = [...tablist.querySelectorAll('[role="tab"]')];
const select = (tab) => tabs.forEach((other) => {
const active = other === tab;
other.setAttribute('aria-selected', String(active));
other.tabIndex = active ? 0 : -1;
document.getElementById(other.getAttribute('aria-controls')).hidden = !active;
});
tabs.forEach((tab, index) => {
tab.addEventListener('click', () => select(tab));
tab.addEventListener('keydown', (event) => {
const step = { ArrowRight: 1, ArrowDown: 1, ArrowLeft: -1, ArrowUp: -1 }[event.key];
if (!step) return;
event.preventDefault();
const next = tabs[(index + step + tabs.length) % tabs.length];
next.focus();
select(next);
});
});
});
document.querySelectorAll('[data-chat-faq]').forEach((chat) => {
const log = chat.querySelector('[data-chat-log]');
chat.querySelectorAll('[data-chat-question]').forEach((button) => {
button.addEventListener('click', () => {
const template = chat.querySelector(`#${button.dataset.chatQuestion}`);
const entry = template.content.cloneNode(true);
log.append(entry);
button.disabled = true;
log.lastElementChild?.scrollIntoView({ block: 'nearest', behavior: matchMedia('(prefers-reduced-motion: reduce)').matches ? 'auto' : 'smooth' });
});
});
});
document.querySelectorAll('[data-sentence-form]').forEach((form) => {
form.addEventListener('submit', (event) => {
event.preventDefault();
const status = form.querySelector('[data-form-status]');
if (!form.checkValidity()) {
status.textContent = form.dataset.error;
form.querySelector(':invalid')?.focus();
return;
}
status.textContent = form.dataset.success;
form.reset();
});
});
document.querySelectorAll('[data-current-year]').forEach((el) => { el.textContent = new Date().getFullYear(); });
(() => {
const skip = navigator.webdriver || !('IntersectionObserver' in window) || matchMedia('(prefers-reduced-motion: reduce)').matches;
if (skip) return;
const counters = document.querySelectorAll('[data-count-to]');
const countObserver = new IntersectionObserver((entries) => {
entries.forEach((entry) => {
if (!entry.isIntersecting) return;
countObserver.unobserve(entry.target);
const target = Number(entry.target.dataset.countTo);
const start = performance.now();
const tick = (now) => {
const progress = Math.min(1, (now - start) / 1400);
entry.target.textContent = Math.round(target * (1 - Math.pow(1 - progress, 3))).toLocaleString('en-US');
if (progress < 1) requestAnimationFrame(tick);
};
requestAnimationFrame(tick);
});
}, { threshold: 0.5 });
counters.forEach((counter) => countObserver.observe(counter));
const items = document.querySelectorAll('[data-reveal]');
if (!items.length) return;
document.documentElement.classList.add('reveal-ready');
const observer = new IntersectionObserver((entries) => {
entries.forEach((entry) => {
if (!entry.isIntersecting) return;
entry.target.classList.add('is-visible');
observer.unobserve(entry.target);
});
}, { rootMargin: '0px 0px -10% 0px' });
items.forEach((item) => observer.observe(item));
})();
</script>
<!-- Optional credit — delete this block if you prefer a clean footer -->
<p class="lt-built-with" style="margin:0;padding:12px 16px;text-align:center;font:500 11px/1.4 system-ui,-apple-system,sans-serif;color:#9ca3af;">Built with <a href="https://letstemplates.com" style="color:#059669;text-decoration:none;">Let's templates</a></p>
</body>
</html>
Premium
Startup
Unlock the entire library of premium templates and blocks. Renews automatically, cancel anytime.
Tailwind CSS · HTML download