Huurbaken website — Marstark 24-Hour Build Challenge (bilingual NL/EN)

This commit is contained in:
2026-12-06 06:24:38 +06:00
commit 124289e742
7 changed files with 1697 additions and 0 deletions
+103
View File
@@ -0,0 +1,103 @@
# Huurbaken — Verkoop uw verhuurde pand direct
A fictional German company that buys rented homes and buildings directly from
their owners. Property owners leave their details and receive a fair,
non-binding offer within 48 hours — no viewings, no estate-agent fees, and
the tenants simply stay.
> **Fictional demo website — test data.** Huurbaken is a fictional company.
> This website was created for the **Marstark Senior Web Developer —
> AI-Native Builder 24-Hour Build Challenge**. All content, names, figures and
> quotes are fictional test data written for this challenge. Nothing here is
> copied from any existing website or company.
## How to run
No build step, no backend. Just open `index.html` in a browser, or serve the
folder statically, e.g.:
```bash
python3 -m http.server 8000
# then open http://localhost:8000
```
## Tech stack
- Plain HTML + CSS + JavaScript (static site, zero dependencies at runtime)
- Google Fonts (loaded from CDN): Fraunces + Inter
- Photography: Unsplash (direct `images.unsplash.com` URLs, with fallback
images if one fails to load)
- No frameworks, no build tools, no backend
## Files
| File | What it is |
| --- | --- |
| `index.html` | Single-page site: hero, how it works, why Huurbaken, property types, value teaser, testimonials, FAQ, lead form, footer |
| `styles.css` | All styling, responsive breakpoints (480px / 768px / 1020px) |
| `script.js` | NL/EN language switcher with full dictionaries, mobile menu, FAQ accordion, form validation + success state |
| `logo.svg` | Original Huurbaken logo (house + beacon mark + wordmark) |
| `favicon.svg` | Simplified logo mark for browsers/tabs |
| `favicon.png` | PNG version of the favicon mark (local file — the site itself uses `favicon.svg`) |
| `README.md` | This file |
## Features
- **Bilingual NL / EN with a working language switch** (NL | EN in the header).
Default language is Dutch. Every visible string switches — navigation, hero,
sections, form labels and placeholders, buttons, FAQ, footer, and the
document title. The choice is remembered in `localStorage`.
- **Fully responsive** — phone, tablet and desktop layouts, with a working
mobile menu.
- **Lead form** (name, email, phone, property type, city/address, monthly
rent optional, message) with client-side validation and a success state in
the active language. Demo form: no data is sent or stored.
- **FAQ accordion**, smooth scrolling, semantic HTML, keyboard-accessible
controls.
## Brand identity
The name **Huurbaken** combines the Dutch words *huur* (rent) and *baken*
(beacon): a beacon for owners of rented property. The logo is a house with a
golden beacon light above the roof — guidance and certainty for owners who
want to sell.
### Logo
- `logo.svg` — full lock-up: house + beacon mark with the “Huurbaken”
wordmark (Fraunces Bold).
- `favicon.svg` / `favicon.png` — simplified mark: the house and beacon on a
deep-green rounded square.
### Colors
| Name | Hex | Use |
| --- | --- | --- |
| Deep Green | `#0E3B2E` | Primary — headings, header, footer, buttons (hover) |
| Green 2 | `#14503F` | Secondary green — links, accents |
| Dark Green | `#0A2E24` | Footer background |
| Cream | `#F7F3EC` | Page background |
| Sand | `#EFE7D8` | Tinted sections, badges |
| Sand 2 | `#E6DCC8` | Image placeholders, borders |
| Gold / Amber | `#C9A227` | Accent — primary CTA buttons, beacon, highlights |
| Gold dark | `#B08D1E` | CTA hover, eyebrow text |
| Ink | `#1C2420` | Body text |
| Muted | `#5B6B62` | Secondary text |
| Line | `#DDD5C3` | Borders |
| Error | `#B3261E` | Form validation |
### Fonts
- **Fraunces** (Google Fonts, weights 500/600/700) — display serif for
headings, the logo wordmark and quotes.
- **Inter** (Google Fonts, weights 400/500/600/700) — body text, navigation,
forms and UI.
## Content note
All copy is original and written for this challenge in Dutch and English.
Testimonials use clearly fictional names and are labelled as test data; the
value-indication table is labelled as fictional example figures. Contact
email shown on the site is `contact@huurbaken.example` (the `.example`
domain is reserved for documentation, so it cannot belong to a real company).
No real addresses or phone numbers appear anywhere on the site.
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

+16
View File
@@ -0,0 +1,16 @@
<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64" role="img" aria-label="Huurbaken favicon">
<title>Huurbaken</title>
<rect width="64" height="64" rx="14" fill="#0E3B2E"/>
<!-- Beacon rays -->
<g stroke="#C9A227" stroke-width="2.6" stroke-linecap="round">
<line x1="32" y1="9" x2="32" y2="5"/>
<line x1="26" y1="11" x2="22.5" y2="7"/>
<line x1="38" y1="11" x2="41.5" y2="7"/>
</g>
<!-- Beacon light -->
<circle cx="32" cy="15" r="4" fill="#C9A227"/>
<!-- House -->
<path d="M14 35 L32 21 L50 35 V52 H14 Z" fill="#F7F3EC"/>
<!-- Door -->
<rect x="29" y="41" width="6" height="11" fill="#0E3B2E"/>
</svg>

After

Width:  |  Height:  |  Size: 670 B

+429
View File
@@ -0,0 +1,429 @@
<!DOCTYPE html>
<html lang="nl">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title data-i18n="meta.title">Huurbaken — Verkoop uw verhuurde pand direct</title>
<meta name="description" data-i18n-content="meta.description" content="Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren. Binnen 48 uur een vrijblijvend bod, zonder makelaarskosten.">
<link rel="icon" type="image/svg+xml" href="favicon.svg">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="styles.css">
</head>
<body>
<a class="skip-link" href="#contact" data-i18n="a11y.skip">Direct naar het aanvraagformulier</a>
<!-- ============ HEADER ============ -->
<header class="site-header" id="top">
<div class="container header-inner">
<a class="brand" href="#top" aria-label="Huurbaken — home">
<img class="brand-logo" src="logo.svg" alt="Huurbaken logo" width="40" height="40">
<span class="brand-name">Huurbaken</span>
</a>
<nav class="main-nav" id="mainNav" aria-label="Hoofdnavigatie">
<a href="#how" data-i18n="nav.how">Hoe het werkt</a>
<a href="#why" data-i18n="nav.why">Waarom Huurbaken</a>
<a href="#types" data-i18n="nav.types">Wat wij kopen</a>
<a href="#faq" data-i18n="nav.faq">Veelgestelde vragen</a>
<a href="#contact" data-i18n="nav.contact">Contact</a>
</nav>
<div class="header-actions">
<div class="lang-switch" role="group" aria-label="Taal / Language">
<button type="button" class="lang-btn is-active" data-lang="nl" aria-pressed="true">NL</button>
<span class="lang-sep" aria-hidden="true">|</span>
<button type="button" class="lang-btn" data-lang="en" aria-pressed="false">EN</button>
</div>
<a class="btn btn-primary header-cta" href="#contact" data-i18n="nav.cta">Ontvang een bod</a>
<button class="menu-toggle" id="menuToggle" type="button" aria-expanded="false" aria-controls="mainNav" aria-label="Menu openen">
<span></span><span></span><span></span>
</button>
</div>
</div>
</header>
<main>
<!-- ============ HERO ============ -->
<section class="hero">
<div class="container hero-grid">
<div class="hero-copy">
<p class="hero-badge" data-i18n="hero.badge">Directe aankoop van verhuurd vastgoed</p>
<h1 data-i18n="hero.title">Verkoop uw verhuurde pand direct — zonder bezichtigingen, zonder wachten.</h1>
<p class="hero-sub" data-i18n="hero.sub">Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren. Binnen 48 uur een eerlijk, vrijblijvend bod. Geen makelaarskosten — en uw huurders blijven gewoon wonen.</p>
<div class="hero-ctas">
<a class="btn btn-primary" href="#contact" data-i18n="hero.cta1">Ontvang een gratis bod</a>
<a class="btn btn-ghost" href="#how" data-i18n="hero.cta2">Zo werkt het</a>
</div>
<ul class="trust-points">
<li><span class="trust-icon" aria-hidden="true">✓</span><span data-i18n="hero.trust1">Bod binnen 48 uur</span></li>
<li><span class="trust-icon" aria-hidden="true">✓</span><span data-i18n="hero.trust2">Geen makelaarskosten</span></li>
<li><span class="trust-icon" aria-hidden="true">✓</span><span data-i18n="hero.trust3">Huurders blijven wonen</span></li>
</ul>
</div>
<div class="hero-media">
<img src="https://images.unsplash.com/photo-1600585154340-be6161a56a0c?auto=format&fit=crop&w=1600&q=80"
data-i18n-alt="hero.imgAlt" alt="Moderne woning"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1560518883-ce09059eeffa?auto=format&fit=crop&w=1600&q=80';">
<div class="hero-card">
<p class="hero-card-label" data-i18n="hero.cardLabel">Eerste bod binnen</p>
<p class="hero-card-value">48 <span data-i18n="hero.cardUnit">uur</span></p>
<p class="hero-card-note" data-i18n="hero.cardNote">Vrijblijvend &amp; gratis</p>
</div>
</div>
</div>
</section>
<!-- ============ HOW IT WORKS ============ -->
<section class="section" id="how">
<div class="container">
<p class="section-eyebrow" data-i18n="how.eyebrow">Het proces</p>
<h2 data-i18n="how.title">Zo werkt het</h2>
<p class="section-sub" data-i18n="how.sub">Van eerste contact tot uitbetaling in vier duidelijke stappen.</p>
<ol class="steps">
<li class="step">
<span class="step-num" aria-hidden="true">1</span>
<h3 data-i18n="how.s1t">Laat uw gegevens achter</h3>
<p data-i18n="how.s1d">Vul het formulier in — binnen twee minuten gedaan. Wij nemen binnen één werkdag contact met u op.</p>
</li>
<li class="step">
<span class="step-num" aria-hidden="true">2</span>
<h3 data-i18n="how.s2t">Ontvang een vrijblijvend bod</h3>
<p data-i18n="how.s2d">Binnen 48 uur ontvangt u een eerlijk bod op basis van huurinkomsten, locatie en staat van het pand.</p>
</li>
<li class="step">
<span class="step-num" aria-hidden="true">3</span>
<h3 data-i18n="how.s3t">Wij regelen alles</h3>
<p data-i18n="how.s3d">Taxatie, huurders, administratie en papierwerk: wij nemen het u volledig uit handen.</p>
</li>
<li class="step">
<span class="step-num" aria-hidden="true">4</span>
<h3 data-i18n="how.s4t">Notaris en uitbetaling</h3>
<p data-i18n="how.s4d">Na uw akkoord regelen wij de notaris. Het bedrag staat snel op uw rekening.</p>
</li>
</ol>
</div>
</section>
<!-- ============ WHY HUURBAKEN ============ -->
<section class="section section-tinted" id="why">
<div class="container why-grid">
<div class="why-copy">
<p class="section-eyebrow" data-i18n="why.eyebrow">Waarom Huurbaken</p>
<h2 data-i18n="why.title">Waarom verkopen aan Huurbaken?</h2>
<p class="section-sub" data-i18n="why.sub">Verkopen zonder gedoe — met zekerheid en een eerlijke prijs.</p>
<img class="why-img" src="https://images.unsplash.com/photo-1600607687939-ce8a6c25118c?auto=format&fit=crop&w=1200&q=80"
data-i18n-alt="why.imgAlt" alt="Interieur van een woning" loading="lazy"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1560448204-e02f11c3d0e2?auto=format&fit=crop&w=1200&q=80';">
</div>
<div class="why-cards">
<article class="why-card">
<h3 data-i18n="why.c1t">Geen bezichtigingen</h3>
<p data-i18n="why.c1d">Geen vreemden over de vloer en geen open huizen. Uw huurders worden niet gestoord.</p>
</article>
<article class="why-card">
<h3 data-i18n="why.c2t">Geen makelaarskosten</h3>
<p data-i18n="why.c2d">U betaalt geen courtage en geen verkoopkosten. Het bod is het bedrag dat u ontvangt.</p>
</article>
<article class="why-card">
<h3 data-i18n="why.c3t">Huurders blijven wonen</h3>
<p data-i18n="why.c3d">Wij nemen de huurovereenkomsten over zoals ze zijn. Niemand hoeft te verhuizen.</p>
</article>
<article class="why-card">
<h3 data-i18n="why.c4t">Snel zekerheid</h3>
<p data-i18n="why.c4d">Binnen 48 uur weet u waar u aan toe bent — geen maanden wachten op een koper.</p>
</article>
<article class="why-card">
<h3 data-i18n="why.c5t">Wij kopen zoals het is</h3>
<p data-i18n="why.c5d">Renoveren hoeft niet. Ook panden met achterstallig onderhoud nemen wij over.</p>
</article>
<article class="why-card">
<h3 data-i18n="why.c6t">Discreet en persoonlijk</h3>
<p data-i18n="why.c6d">Eén vast aanspreekpunt, geen veiling en geen openbare verkoop.</p>
</article>
</div>
</div>
</section>
<!-- ============ PROPERTY TYPES ============ -->
<section class="section" id="types">
<div class="container">
<p class="section-eyebrow" data-i18n="types.eyebrow">Ons aanbod</p>
<h2 data-i18n="types.title">Wat wij kopen</h2>
<p class="section-sub" data-i18n="types.sub">Verhuurde panden in heel Duitsland — van één appartement tot een compleet complex.</p>
<div class="type-grid">
<article class="type-card">
<img src="https://images.unsplash.com/photo-1545324418-cc1a3fa10c00?auto=format&fit=crop&w=1200&q=80"
data-i18n-alt="types.t1img" alt="Appartementencomplex" loading="lazy"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1460317442991-0ec209397118?auto=format&fit=crop&w=1200&q=80';">
<div class="type-body">
<h3 data-i18n="types.t1t">Verhuurde appartementen</h3>
<p data-i18n="types.t1d">Eén of meerdere appartementen, bewoond of leegstaand.</p>
</div>
</article>
<article class="type-card">
<img src="https://images.unsplash.com/photo-1568605114967-8130f3a36994?auto=format&fit=crop&w=1200&q=80"
data-i18n-alt="types.t2img" alt="Verhuurde woning" loading="lazy"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1580587771525-78b9dba3b914?auto=format&fit=crop&w=1200&q=80';">
<div class="type-body">
<h3 data-i18n="types.t2t">Verhuurde woningen</h3>
<p data-i18n="types.t2d">Eengezinswoningen en herenhuizen met lopende huur.</p>
</div>
</article>
<article class="type-card">
<img src="https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=1200&q=80"
data-i18n-alt="types.t3img" alt="Appartementencomplex" loading="lazy"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1487958449943-2429e8be8625?auto=format&fit=crop&w=1200&q=80';">
<div class="type-body">
<h3 data-i18n="types.t3t">Appartementencomplexen</h3>
<p data-i18n="types.t3d">Complete complexen met meerdere eenheden en huurders.</p>
</div>
</article>
<article class="type-card">
<img src="https://images.unsplash.com/photo-1449157291145-7efd050a4d0e?auto=format&fit=crop&w=1200&q=80"
data-i18n-alt="types.t4img" alt="Gemengd gebouw" loading="lazy"
onerror="this.onerror=null;this.src='https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=1200&q=80';">
<div class="type-body">
<h3 data-i18n="types.t4t">Gemengd gebruik</h3>
<p data-i18n="types.t4d">Combinaties van wonen en werken, winkels of kantoren.</p>
</div>
</article>
</div>
</div>
</section>
<!-- ============ VALUE TEASER ============ -->
<section class="section section-tinted" id="value">
<div class="container value-grid">
<div>
<p class="section-eyebrow" data-i18n="value.eyebrow">Eerste indicatie</p>
<h2 data-i18n="value.title">Wat zou uw pand waard kunnen zijn?</h2>
<p class="section-sub" data-i18n="value.sub">Een eerste indicatie op basis van huurinkomsten. De cijfers hieronder zijn fictieve voorbeelden (testdata).</p>
<p class="value-note" data-i18n="value.note">Elk pand is anders. Uw definitieve bod volgt na een korte beoordeling — altijd vrijblijvend.</p>
</div>
<div class="value-table-wrap">
<table class="value-table">
<thead>
<tr>
<th data-i18n="value.col1">Type pand</th>
<th data-i18n="value.col2">Huur per maand</th>
<th data-i18n="value.col3">Indicatie</th>
</tr>
</thead>
<tbody>
<tr>
<td data-i18n="value.r1c1">Verhuurd appartement</td>
<td>€ 1.200</td>
<td>€ 180.000 – € 220.000</td>
</tr>
<tr>
<td data-i18n="value.r2c1">Verhuurde woning</td>
<td>€ 1.800</td>
<td>€ 270.000 – € 330.000</td>
</tr>
<tr>
<td data-i18n="value.r3c1">Appartementencomplex (8 eenheden)</td>
<td>€ 9.500</td>
<td>€ 1.400.000 – € 1.700.000</td>
</tr>
</tbody>
</table>
<p class="testdata-tag" data-i18n="value.testdata">Fictieve voorbeeldcijfers — testdata</p>
</div>
</div>
</section>
<!-- ============ TESTIMONIALS ============ -->
<section class="section" id="stories">
<div class="container">
<p class="section-eyebrow" data-i18n="testi.eyebrow">Ervaringen</p>
<h2 data-i18n="testi.title">Wat eigenaren zeggen</h2>
<p class="section-sub" data-i18n="testi.sub">Fictieve citaten — testdata.</p>
<div class="testi-grid">
<figure class="testi-card">
<blockquote data-i18n="testi.q1">“Binnen drie dagen hadden we een bod op tafel. Geen bezichtigingen, geen gedoe — en onze huurders konden gewoon blijven.”</blockquote>
<figcaption>
<span class="avatar" aria-hidden="true">MV</span>
<span><strong data-i18n="testi.a1n">Marleen V.</strong><br><span data-i18n="testi.a1r">Eigenaar van twee verhuurde appartementen</span></span>
</figcaption>
</figure>
<figure class="testi-card">
<blockquote data-i18n="testi.q2">“Na het overlijden van mijn vader wilde ik het verhuurde huis snel en netjes verkopen. Huurbaken regelde alles, inclusief de huurder.”</blockquote>
<figcaption>
<span class="avatar" aria-hidden="true">JD</span>
<span><strong data-i18n="testi.a2n">Johan D.</strong><br><span data-i18n="testi.a2r">Erfgenaam van een verhuurde woning</span></span>
</figcaption>
</figure>
<figure class="testi-card">
<blockquote data-i18n="testi.q3">“Eindelijk een koper die begrijpt dat huurders mensen zijn. De afhandeling was snel, helder en discreet.”</blockquote>
<figcaption>
<span class="avatar" aria-hidden="true">SE</span>
<span><strong data-i18n="testi.a3n">Samira E.</strong><br><span data-i18n="testi.a3r">Eigenaar van een appartementencomplex</span></span>
</figcaption>
</figure>
</div>
</div>
</section>
<!-- ============ FAQ ============ -->
<section class="section section-tinted" id="faq">
<div class="container faq-wrap">
<p class="section-eyebrow" data-i18n="faq.eyebrow">Vragen &amp; antwoorden</p>
<h2 data-i18n="faq.title">Veelgestelde vragen</h2>
<div class="faq-list">
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q1">Moet ik mijn huurders uitzetten?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a1">Nee. Wij nemen de bestaande huurovereenkomsten over zoals ze zijn. Uw huurders blijven gewoon wonen en merken weinig van de verkoop.</p></div>
</div>
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q2">Hoe snel ontvang ik een bod?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a2">Binnen 48 uur na uw aanvraag ontvangt u een eerste, vrijblijvend bod — op werkdagen vaak nog sneller.</p></div>
</div>
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q3">Zijn er kosten aan verbonden?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a3">Nee. U betaalt geen makelaarskosten en geen verkoopcommissie. Ook de taxatie- en notariskosten nemen wij voor onze rekening.</p></div>
</div>
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q4">Welke documenten heb ik nodig?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a4">In eerste instantie alleen de basis: huurinkomsten, adres en type pand. Later vragen wij om de huurovereenkomst en, indien beschikbaar, het WOZ- of taxatierapport.</p></div>
</div>
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q5">Welke panden kopen jullie?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a5">Verhuurde appartementen, woningen, appartementencomplexen en gemengd gebruik — in heel Duitsland, in elke staat van onderhoud.</p></div>
</div>
<div class="faq-item">
<button class="faq-q" type="button" aria-expanded="false">
<span data-i18n="faq.q6">Is het bod bindend?</span>
<span class="faq-icon" aria-hidden="true">+</span>
</button>
<div class="faq-a"><p data-i18n="faq.a6">Nee. Ons bod is altijd vrijblijvend. U beslist in alle rust of u wilt verkopen — zonder druk en zonder verplichtingen.</p></div>
</div>
</div>
</div>
</section>
<!-- ============ LEAD FORM ============ -->
<section class="section" id="contact">
<div class="container form-grid">
<div class="form-intro">
<p class="section-eyebrow" data-i18n="form.eyebrow">Gratis &amp; vrijblijvend</p>
<h2 data-i18n="form.title">Ontvang uw gratis, vrijblijvende bod</h2>
<p class="section-sub" data-i18n="form.sub">Vul het formulier in — wij nemen binnen één werkdag contact met u op.</p>
<ul class="form-points">
<li><span aria-hidden="true">✓</span> <span data-i18n="form.p1">Bod binnen 48 uur</span></li>
<li><span aria-hidden="true">✓</span> <span data-i18n="form.p2">Geen makelaarskosten</span></li>
<li><span aria-hidden="true">✓</span> <span data-i18n="form.p3">Huurders blijven wonen</span></li>
</ul>
<p class="form-demo-note" data-i18n="form.demoNote">Demoformulier: er worden geen gegevens verzonden of opgeslagen.</p>
</div>
<div class="form-card">
<form id="leadForm" novalidate>
<div class="field">
<label for="fName" data-i18n="form.f_name">Naam *</label>
<input type="text" id="fName" name="name" autocomplete="name" data-i18n-ph="form.ph_name" placeholder="Bijv. Anna Jansen" required>
<p class="field-error" id="errName" hidden></p>
</div>
<div class="field-row">
<div class="field">
<label for="fEmail" data-i18n="form.f_email">E-mailadres *</label>
<input type="email" id="fEmail" name="email" autocomplete="email" data-i18n-ph="form.ph_email" placeholder="naam@voorbeeld.nl" required>
<p class="field-error" id="errEmail" hidden></p>
</div>
<div class="field">
<label for="fPhone" data-i18n="form.f_phone">Telefoonnummer *</label>
<input type="tel" id="fPhone" name="phone" autocomplete="tel" data-i18n-ph="form.ph_phone" placeholder="+31 6 12345678" required>
<p class="field-error" id="errPhone" hidden></p>
</div>
</div>
<div class="field">
<label for="fType" data-i18n="form.f_type">Type pand *</label>
<select id="fType" name="type" required>
<option value="" data-i18n="form.type_ph">Kies een type</option>
<option value="apartment" data-i18n="form.type1">Verhuurd appartement</option>
<option value="house" data-i18n="form.type2">Verhuurde woning</option>
<option value="complex" data-i18n="form.type3">Appartementencomplex</option>
<option value="mixed" data-i18n="form.type4">Gemengd gebruik</option>
<option value="other" data-i18n="form.type5">Anders</option>
</select>
<p class="field-error" id="errType" hidden></p>
</div>
<div class="field-row">
<div class="field">
<label for="fCity" data-i18n="form.f_city">Plaats en adres *</label>
<input type="text" id="fCity" name="city" autocomplete="address-line1" data-i18n-ph="form.ph_city" placeholder="Plaats, straat + huisnummer" required>
<p class="field-error" id="errCity" hidden></p>
</div>
<div class="field">
<label for="fRent" data-i18n="form.f_rent">Maandelijkse huur (optioneel)</label>
<input type="text" id="fRent" name="rent" inputmode="decimal" data-i18n-ph="form.ph_rent" placeholder="Bijv. 1.250">
</div>
</div>
<div class="field">
<label for="fMsg" data-i18n="form.f_msg">Bericht</label>
<textarea id="fMsg" name="message" rows="4" data-i18n-ph="form.ph_msg" placeholder="Vertel kort iets over uw pand…"></textarea>
</div>
<button class="btn btn-primary btn-block" type="submit" data-i18n="form.submit">Vraag een bod aan</button>
<p class="privacy-note" data-i18n="form.privacy">Uw gegevens gebruiken wij alleen om contact met u op te nemen.</p>
</form>
<div class="form-success" id="formSuccess" hidden>
<p class="success-icon" aria-hidden="true">✓</p>
<h3 data-i18n="form.success_title">Bedankt voor uw aanvraag!</h3>
<p data-i18n="form.success_text">Wij nemen binnen één werkdag contact met u op met een eerste indicatie.</p>
<p class="form-demo-note" data-i18n="form.demoNote2">Demoformulier: er worden geen gegevens verzonden of opgeslagen.</p>
<button class="btn btn-ghost" type="button" id="formReset" data-i18n="form.again">Nieuwe aanvraag doen</button>
</div>
</div>
</div>
</section>
</main>
<!-- ============ FOOTER ============ -->
<footer class="site-footer">
<div class="container footer-grid">
<div class="footer-brand">
<a class="brand" href="#top">
<img class="brand-logo" src="logo.svg" alt="Huurbaken logo" width="36" height="36">
<span class="brand-name">Huurbaken</span>
</a>
<p data-i18n="footer.tagline">Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren — snel, eerlijk en discreet.</p>
</div>
<nav class="footer-col" aria-label="Footer navigatie">
<h3 data-i18n="footer.navTitle">Navigatie</h3>
<a href="#how" data-i18n="nav.how">Hoe het werkt</a>
<a href="#why" data-i18n="nav.why">Waarom Huurbaken</a>
<a href="#types" data-i18n="nav.types">Wat wij kopen</a>
<a href="#faq" data-i18n="nav.faq">Veelgestelde vragen</a>
<a href="#contact" data-i18n="nav.contact">Contact</a>
</nav>
<div class="footer-col">
<h3 data-i18n="footer.contactTitle">Contact</h3>
<p><a href="mailto:contact@huurbaken.example">contact@huurbaken.example</a></p>
<p data-i18n="footer.langNote">Deze website is beschikbaar in het Nederlands en Engels.</p>
</div>
</div>
<div class="container footer-bottom">
<p data-i18n="footer.demo">Huurbaken is een fictief bedrijf. Deze website is een demo met testdata, gemaakt voor de Marstark Build Challenge.</p>
<p data-i18n="footer.rights">© 2026 Huurbaken — fictieve demo-website</p>
</div>
</footer>
<script src="script.js"></script>
</body>
</html>
+19
View File
@@ -0,0 +1,19 @@
<svg xmlns="http://www.w3.org/2000/svg" width="220" height="48" viewBox="0 0 220 48" role="img" aria-label="Huurbaken logo">
<title>Huurbaken</title>
<!-- Beacon rays -->
<g stroke="#C9A227" stroke-width="2.4" stroke-linecap="round">
<line x1="24" y1="4.5" x2="24" y2="0.8"/>
<line x1="18.6" y1="6.2" x2="15.4" y2="2.4"/>
<line x1="29.4" y1="6.2" x2="32.6" y2="2.4"/>
</g>
<!-- Beacon light -->
<circle cx="24" cy="10" r="3.6" fill="#C9A227"/>
<!-- House -->
<path d="M6 27 L24 14 L42 27 V44 H6 Z" fill="#0E3B2E"/>
<!-- Door + windows (cream cut-outs) -->
<rect x="21" y="32" width="6" height="12" fill="#F7F3EC"/>
<rect x="11" y="31" width="5" height="5" fill="#F7F3EC"/>
<rect x="32" y="31" width="5" height="5" fill="#F7F3EC"/>
<!-- Wordmark -->
<text x="56" y="33" font-family="Fraunces, Georgia, 'Times New Roman', serif" font-size="27" font-weight="700" fill="#0E3B2E" letter-spacing="-0.5">Huurbaken</text>
</svg>

After

Width:  |  Height:  |  Size: 961 B

+484
View File
@@ -0,0 +1,484 @@
/* ============================================================
Huurbaken — script.js
Language switcher (NL/EN), mobile menu, FAQ accordion,
lead-form validation with success state.
No backend: the form is a demo and stores nothing.
============================================================ */
"use strict";
/* ---------------- i18n dictionaries ---------------- */
const I18N = {
nl: {
"meta.title": "Huurbaken — Verkoop uw verhuurde pand direct",
"meta.description": "Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren. Binnen 48 uur een vrijblijvend bod, zonder makelaarskosten.",
"a11y.skip": "Direct naar het aanvraagformulier",
"nav.how": "Hoe het werkt",
"nav.why": "Waarom Huurbaken",
"nav.types": "Wat wij kopen",
"nav.faq": "Veelgestelde vragen",
"nav.contact": "Contact",
"nav.cta": "Ontvang een bod",
"hero.badge": "Directe aankoop van verhuurd vastgoed",
"hero.title": "Verkoop uw verhuurde pand direct — zonder bezichtigingen, zonder wachten.",
"hero.sub": "Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren. Binnen 48 uur een eerlijk, vrijblijvend bod. Geen makelaarskosten — en uw huurders blijven gewoon wonen.",
"hero.cta1": "Ontvang een gratis bod",
"hero.cta2": "Zo werkt het",
"hero.trust1": "Bod binnen 48 uur",
"hero.trust2": "Geen makelaarskosten",
"hero.trust3": "Huurders blijven wonen",
"hero.imgAlt": "Moderne woning",
"hero.cardLabel": "Eerste bod binnen",
"hero.cardUnit": "uur",
"hero.cardNote": "Vrijblijvend & gratis",
"how.eyebrow": "Het proces",
"how.title": "Zo werkt het",
"how.sub": "Van eerste contact tot uitbetaling in vier duidelijke stappen.",
"how.s1t": "Laat uw gegevens achter",
"how.s1d": "Vul het formulier in — binnen twee minuten gedaan. Wij nemen binnen één werkdag contact met u op.",
"how.s2t": "Ontvang een vrijblijvend bod",
"how.s2d": "Binnen 48 uur ontvangt u een eerlijk bod op basis van huurinkomsten, locatie en staat van het pand.",
"how.s3t": "Wij regelen alles",
"how.s3d": "Taxatie, huurders, administratie en papierwerk: wij nemen het u volledig uit handen.",
"how.s4t": "Notaris en uitbetaling",
"how.s4d": "Na uw akkoord regelen wij de notaris. Het bedrag staat snel op uw rekening.",
"why.eyebrow": "Waarom Huurbaken",
"why.title": "Waarom verkopen aan Huurbaken?",
"why.sub": "Verkopen zonder gedoe — met zekerheid en een eerlijke prijs.",
"why.imgAlt": "Interieur van een woning",
"why.c1t": "Geen bezichtigingen",
"why.c1d": "Geen vreemden over de vloer en geen open huizen. Uw huurders worden niet gestoord.",
"why.c2t": "Geen makelaarskosten",
"why.c2d": "U betaalt geen courtage en geen verkoopkosten. Het bod is het bedrag dat u ontvangt.",
"why.c3t": "Huurders blijven wonen",
"why.c3d": "Wij nemen de huurovereenkomsten over zoals ze zijn. Niemand hoeft te verhuizen.",
"why.c4t": "Snel zekerheid",
"why.c4d": "Binnen 48 uur weet u waar u aan toe bent — geen maanden wachten op een koper.",
"why.c5t": "Wij kopen zoals het is",
"why.c5d": "Renoveren hoeft niet. Ook panden met achterstallig onderhoud nemen wij over.",
"why.c6t": "Discreet en persoonlijk",
"why.c6d": "Eén vast aanspreekpunt, geen veiling en geen openbare verkoop.",
"types.eyebrow": "Ons aanbod",
"types.title": "Wat wij kopen",
"types.sub": "Verhuurde panden in heel Duitsland — van één appartement tot een compleet complex.",
"types.t1img": "Appartementencomplex",
"types.t1t": "Verhuurde appartementen",
"types.t1d": "Eén of meerdere appartementen, bewoond of leegstaand.",
"types.t2img": "Verhuurde woning",
"types.t2t": "Verhuurde woningen",
"types.t2d": "Eengezinswoningen en herenhuizen met lopende huur.",
"types.t3img": "Appartementencomplex",
"types.t3t": "Appartementencomplexen",
"types.t3d": "Complete complexen met meerdere eenheden en huurders.",
"types.t4img": "Gemengd gebouw",
"types.t4t": "Gemengd gebruik",
"types.t4d": "Combinaties van wonen en werken, winkels of kantoren.",
"value.eyebrow": "Eerste indicatie",
"value.title": "Wat zou uw pand waard kunnen zijn?",
"value.sub": "Een eerste indicatie op basis van huurinkomsten. De cijfers hieronder zijn fictieve voorbeelden (testdata).",
"value.note": "Elk pand is anders. Uw definitieve bod volgt na een korte beoordeling — altijd vrijblijvend.",
"value.col1": "Type pand",
"value.col2": "Huur per maand",
"value.col3": "Indicatie",
"value.r1c1": "Verhuurd appartement",
"value.r2c1": "Verhuurde woning",
"value.r3c1": "Appartementencomplex (8 eenheden)",
"value.testdata": "Fictieve voorbeeldcijfers — testdata",
"testi.eyebrow": "Ervaringen",
"testi.title": "Wat eigenaren zeggen",
"testi.sub": "Fictieve citaten — testdata.",
"testi.q1": "“Binnen drie dagen hadden we een bod op tafel. Geen bezichtigingen, geen gedoe — en onze huurders konden gewoon blijven.”",
"testi.a1n": "Marleen V.",
"testi.a1r": "Eigenaar van twee verhuurde appartementen",
"testi.q2": "“Na het overlijden van mijn vader wilde ik het verhuurde huis snel en netjes verkopen. Huurbaken regelde alles, inclusief de huurder.”",
"testi.a2n": "Johan D.",
"testi.a2r": "Erfgenaam van een verhuurde woning",
"testi.q3": "“Eindelijk een koper die begrijpt dat huurders mensen zijn. De afhandeling was snel, helder en discreet.”",
"testi.a3n": "Samira E.",
"testi.a3r": "Eigenaar van een appartementencomplex",
"faq.eyebrow": "Vragen & antwoorden",
"faq.title": "Veelgestelde vragen",
"faq.q1": "Moet ik mijn huurders uitzetten?",
"faq.a1": "Nee. Wij nemen de bestaande huurovereenkomsten over zoals ze zijn. Uw huurders blijven gewoon wonen en merken weinig van de verkoop.",
"faq.q2": "Hoe snel ontvang ik een bod?",
"faq.a2": "Binnen 48 uur na uw aanvraag ontvangt u een eerste, vrijblijvend bod — op werkdagen vaak nog sneller.",
"faq.q3": "Zijn er kosten aan verbonden?",
"faq.a3": "Nee. U betaalt geen makelaarskosten en geen verkoopcommissie. Ook de taxatie- en notariskosten nemen wij voor onze rekening.",
"faq.q4": "Welke documenten heb ik nodig?",
"faq.a4": "In eerste instantie alleen de basis: huurinkomsten, adres en type pand. Later vragen wij om de huurovereenkomst en, indien beschikbaar, het WOZ- of taxatierapport.",
"faq.q5": "Welke panden kopen jullie?",
"faq.a5": "Verhuurde appartementen, woningen, appartementencomplexen en gemengd gebruik — in heel Duitsland, in elke staat van onderhoud.",
"faq.q6": "Is het bod bindend?",
"faq.a6": "Nee. Ons bod is altijd vrijblijvend. U beslist in alle rust of u wilt verkopen — zonder druk en zonder verplichtingen.",
"form.eyebrow": "Gratis & vrijblijvend",
"form.title": "Ontvang uw gratis, vrijblijvende bod",
"form.sub": "Vul het formulier in — wij nemen binnen één werkdag contact met u op.",
"form.p1": "Bod binnen 48 uur",
"form.p2": "Geen makelaarskosten",
"form.p3": "Huurders blijven wonen",
"form.demoNote": "Demoformulier: er worden geen gegevens verzonden of opgeslagen.",
"form.f_name": "Naam *",
"form.ph_name": "Bijv. Anna Jansen",
"form.f_email": "E-mailadres *",
"form.ph_email": "naam@voorbeeld.nl",
"form.f_phone": "Telefoonnummer *",
"form.ph_phone": "+31 6 12345678",
"form.f_type": "Type pand *",
"form.type_ph": "Kies een type",
"form.type1": "Verhuurd appartement",
"form.type2": "Verhuurde woning",
"form.type3": "Appartementencomplex",
"form.type4": "Gemengd gebruik",
"form.type5": "Anders",
"form.f_city": "Plaats en adres *",
"form.ph_city": "Plaats, straat + huisnummer",
"form.f_rent": "Maandelijkse huur (optioneel)",
"form.ph_rent": "Bijv. 1.250",
"form.f_msg": "Bericht",
"form.ph_msg": "Vertel kort iets over uw pand…",
"form.submit": "Vraag een bod aan",
"form.privacy": "Uw gegevens gebruiken wij alleen om contact met u op te nemen.",
"form.success_title": "Bedankt voor uw aanvraag!",
"form.success_text": "Wij nemen binnen één werkdag contact met u op met een eerste indicatie.",
"form.demoNote2": "Demoformulier: er worden geen gegevens verzonden of opgeslagen.",
"form.again": "Nieuwe aanvraag doen",
"footer.tagline": "Huurbaken koopt verhuurde woningen en gebouwen rechtstreeks van eigenaren — snel, eerlijk en discreet.",
"footer.navTitle": "Navigatie",
"footer.contactTitle": "Contact",
"footer.langNote": "Deze website is beschikbaar in het Nederlands en Engels.",
"footer.demo": "Huurbaken is een fictief bedrijf. Deze website is een demo met testdata, gemaakt voor de Marstark Build Challenge.",
"footer.rights": "© 2026 Huurbaken — fictieve demo-website",
"err.required": "Dit veld is verplicht.",
"err.email": "Vul een geldig e-mailadres in.",
"err.phone": "Vul een geldig telefoonnummer in.",
"menu.open": "Menu openen",
"menu.close": "Menu sluiten"
},
en: {
"meta.title": "Huurbaken — Sell your rented property directly",
"meta.description": "Huurbaken buys rented homes and buildings directly from owners. A non-binding offer within 48 hours, no estate-agent fees.",
"a11y.skip": "Skip to the request form",
"nav.how": "How it works",
"nav.why": "Why Huurbaken",
"nav.types": "What we buy",
"nav.faq": "FAQ",
"nav.contact": "Contact",
"nav.cta": "Get an offer",
"hero.badge": "Direct purchase of rented property",
"hero.title": "Sell your rented property directly — no viewings, no waiting.",
"hero.sub": "Huurbaken buys rented homes and buildings directly from owners. A fair, non-binding offer within 48 hours. No estate-agent fees — and your tenants simply stay.",
"hero.cta1": "Get a free offer",
"hero.cta2": "How it works",
"hero.trust1": "Offer within 48 hours",
"hero.trust2": "No estate-agent fees",
"hero.trust3": "Tenants stay put",
"hero.imgAlt": "Modern house",
"hero.cardLabel": "First offer within",
"hero.cardUnit": "hours",
"hero.cardNote": "Non-binding & free",
"how.eyebrow": "The process",
"how.title": "How it works",
"how.sub": "From first contact to payment in four clear steps.",
"how.s1t": "Leave your details",
"how.s1d": "Fill in the form — done in two minutes. We will contact you within one working day.",
"how.s2t": "Receive a non-binding offer",
"how.s2d": "Within 48 hours you receive a fair offer based on rental income, location and the condition of the property.",
"how.s3t": "We handle everything",
"how.s3d": "Valuation, tenants, administration and paperwork: we take it all off your hands.",
"how.s4t": "Notary and payment",
"how.s4d": "Once you agree, we arrange the notary. The money is in your account quickly.",
"why.eyebrow": "Why Huurbaken",
"why.title": "Why sell to Huurbaken?",
"why.sub": "Sell without the hassle — with certainty and a fair price.",
"why.imgAlt": "Interior of a home",
"why.c1t": "No viewings",
"why.c1d": "No strangers through the house and no open-house days. Your tenants are not disturbed.",
"why.c2t": "No agent fees",
"why.c2d": "You pay no commission and no selling costs. The offer is the amount you receive.",
"why.c3t": "Tenants stay put",
"why.c3d": "We take over the tenancy agreements as they are. Nobody has to move.",
"why.c4t": "Fast certainty",
"why.c4d": "Within 48 hours you know where you stand — no months of waiting for a buyer.",
"why.c5t": "We buy as-is",
"why.c5d": "No renovation needed. We also take on properties with a maintenance backlog.",
"why.c6t": "Discreet and personal",
"why.c6d": "One dedicated contact, no auction and no public sale.",
"types.eyebrow": "What we buy",
"types.title": "What we buy",
"types.sub": "Rented properties across Germany — from a single apartment to a full complex.",
"types.t1img": "Apartment building",
"types.t1t": "Rented apartments",
"types.t1d": "One or more apartments, occupied or vacant.",
"types.t2img": "Rented house",
"types.t2t": "Rented houses",
"types.t2d": "Family homes and townhouses with ongoing tenancies.",
"types.t3img": "Apartment building",
"types.t3t": "Apartment buildings",
"types.t3d": "Entire complexes with multiple units and tenants.",
"types.t4img": "Mixed-use building",
"types.t4t": "Mixed-use buildings",
"types.t4d": "Combinations of living and working, shops or offices.",
"value.eyebrow": "First indication",
"value.title": "What could your property be worth?",
"value.sub": "A first indication based on rental income. The figures below are fictional examples (test data).",
"value.note": "Every property is different. Your final offer follows a short assessment — always non-binding.",
"value.col1": "Property type",
"value.col2": "Rent per month",
"value.col3": "Indication",
"value.r1c1": "Rented apartment",
"value.r2c1": "Rented house",
"value.r3c1": "Apartment building (8 units)",
"value.testdata": "Fictional example figures — test data",
"testi.eyebrow": "Experiences",
"testi.title": "What owners say",
"testi.sub": "Fictional quotes — test data.",
"testi.q1": "“Within three days we had an offer on the table. No viewings, no hassle — and our tenants could simply stay.”",
"testi.a1n": "Marleen V.",
"testi.a1r": "Owner of two rented apartments",
"testi.q2": "“After my father passed away, I wanted to sell the rented house quickly and properly. Huurbaken arranged everything, including the tenant.”",
"testi.a2n": "Johan D.",
"testi.a2r": "Heir to a rented house",
"testi.q3": "“Finally a buyer who understands that tenants are people. The process was fast, clear and discreet.”",
"testi.a3n": "Samira E.",
"testi.a3r": "Owner of an apartment building",
"faq.eyebrow": "Questions & answers",
"faq.title": "Frequently asked questions",
"faq.q1": "Do I need to evict my tenants?",
"faq.a1": "No. We take over the existing tenancy agreements as they are. Your tenants simply stay and barely notice the sale.",
"faq.q2": "How fast do I get an offer?",
"faq.a2": "Within 48 hours of your request you receive a first, non-binding offer — on working days often even faster.",
"faq.q3": "Are there any fees?",
"faq.a3": "No. You pay no estate-agent fees and no sales commission. We also cover the valuation and notary costs.",
"faq.q4": "What documents do I need?",
"faq.a4": "At first only the basics: rental income, address and property type. Later we ask for the tenancy agreement and, if available, the WOZ or valuation report.",
"faq.q5": "Which properties do you buy?",
"faq.a5": "Rented apartments, houses, apartment buildings and mixed-use properties — across Germany, in any state of repair.",
"faq.q6": "Is the offer binding?",
"faq.a6": "No. Our offer is always non-binding. You decide in your own time whether to sell — no pressure, no obligations.",
"form.eyebrow": "Free & non-binding",
"form.title": "Get your free, non-binding offer",
"form.sub": "Fill in the form — we will contact you within one working day.",
"form.p1": "Offer within 48 hours",
"form.p2": "No estate-agent fees",
"form.p3": "Tenants stay put",
"form.demoNote": "Demo form: no data is sent or stored.",
"form.f_name": "Name *",
"form.ph_name": "E.g. Anna Jansen",
"form.f_email": "Email address *",
"form.ph_email": "name@example.com",
"form.f_phone": "Phone number *",
"form.ph_phone": "+31 6 12345678",
"form.f_type": "Property type *",
"form.type_ph": "Choose a type",
"form.type1": "Rented apartment",
"form.type2": "Rented house",
"form.type3": "Apartment building",
"form.type4": "Mixed-use building",
"form.type5": "Other",
"form.f_city": "City and address *",
"form.ph_city": "City, street + number",
"form.f_rent": "Monthly rent (optional)",
"form.ph_rent": "E.g. 1,250",
"form.f_msg": "Message",
"form.ph_msg": "Tell us briefly about your property…",
"form.submit": "Request an offer",
"form.privacy": "We use your details only to contact you.",
"form.success_title": "Thank you for your request!",
"form.success_text": "We will contact you within one working day with a first indication.",
"form.demoNote2": "Demo form: no data is sent or stored.",
"form.again": "Make a new request",
"footer.tagline": "Huurbaken buys rented homes and buildings directly from owners — fast, fair and discreet.",
"footer.navTitle": "Navigation",
"footer.contactTitle": "Contact",
"footer.langNote": "This website is available in Dutch and English.",
"footer.demo": "Huurbaken is a fictional company. This website is a demo with test data, created for the Marstark Build Challenge.",
"footer.rights": "© 2026 Huurbaken — fictional demo website",
"err.required": "This field is required.",
"err.email": "Please enter a valid email address.",
"err.phone": "Please enter a valid phone number.",
"menu.open": "Open menu",
"menu.close": "Close menu"
}
};
const DEFAULT_LANG = "nl";
const STORAGE_KEY = "huurbaken-lang";
let currentLang = DEFAULT_LANG;
function getStoredLang() {
try {
const saved = window.localStorage.getItem(STORAGE_KEY);
if (saved === "nl" || saved === "en") return saved;
} catch (e) { /* storage unavailable — use default */ }
return DEFAULT_LANG;
}
function applyLanguage(lang) {
if (!I18N[lang]) lang = DEFAULT_LANG;
currentLang = lang;
const dict = I18N[lang];
document.documentElement.lang = lang;
document.title = dict["meta.title"] || document.title;
document.querySelectorAll("[data-i18n]").forEach((el) => {
const key = el.getAttribute("data-i18n");
if (dict[key] !== undefined) el.textContent = dict[key];
});
document.querySelectorAll("[data-i18n-ph]").forEach((el) => {
const key = el.getAttribute("data-i18n-ph");
if (dict[key] !== undefined) el.setAttribute("placeholder", dict[key]);
});
document.querySelectorAll("[data-i18n-alt]").forEach((el) => {
const key = el.getAttribute("data-i18n-alt");
if (dict[key] !== undefined) el.setAttribute("alt", dict[key]);
});
const metaDesc = document.querySelector('meta[name="description"]');
if (metaDesc && dict["meta.description"]) {
metaDesc.setAttribute("content", dict["meta.description"]);
}
document.querySelectorAll(".lang-btn").forEach((btn) => {
const active = btn.getAttribute("data-lang") === lang;
btn.classList.toggle("is-active", active);
btn.setAttribute("aria-pressed", active ? "true" : "false");
});
try { window.localStorage.setItem(STORAGE_KEY, lang); } catch (e) { /* ignore */ }
}
/* ---------------- Mobile menu ---------------- */
function initMenu() {
const toggle = document.getElementById("menuToggle");
const nav = document.getElementById("mainNav");
if (!toggle || !nav) return;
toggle.addEventListener("click", () => {
const open = nav.classList.toggle("open");
toggle.setAttribute("aria-expanded", open ? "true" : "false");
toggle.setAttribute("aria-label", I18N[currentLang][open ? "menu.close" : "menu.open"]);
});
nav.querySelectorAll("a").forEach((link) => {
link.addEventListener("click", () => {
nav.classList.remove("open");
toggle.setAttribute("aria-expanded", "false");
toggle.setAttribute("aria-label", I18N[currentLang]["menu.open"]);
});
});
}
/* ---------------- FAQ accordion ---------------- */
function initFaq() {
document.querySelectorAll(".faq-item").forEach((item) => {
const btn = item.querySelector(".faq-q");
const answer = item.querySelector(".faq-a");
if (!btn || !answer) return;
btn.addEventListener("click", () => {
const isOpen = item.classList.contains("open");
document.querySelectorAll(".faq-item.open").forEach((other) => {
other.classList.remove("open");
other.querySelector(".faq-a").style.maxHeight = null;
other.querySelector(".faq-q").setAttribute("aria-expanded", "false");
});
if (!isOpen) {
item.classList.add("open");
answer.style.maxHeight = answer.scrollHeight + "px";
btn.setAttribute("aria-expanded", "true");
}
});
});
}
/* ---------------- Lead form ---------------- */
function showError(input, errorEl, message) {
if (input) input.classList.add("invalid");
if (errorEl) {
errorEl.textContent = message;
errorEl.hidden = false;
}
}
function clearError(input, errorEl) {
if (input) input.classList.remove("invalid");
if (errorEl) errorEl.hidden = true;
}
function initForm() {
const form = document.getElementById("leadForm");
const success = document.getElementById("formSuccess");
const resetBtn = document.getElementById("formReset");
if (!form || !success) return;
const fields = [
{ input: document.getElementById("fName"), error: document.getElementById("errName"), kind: "required" },
{ input: document.getElementById("fEmail"), error: document.getElementById("errEmail"), kind: "email" },
{ input: document.getElementById("fPhone"), error: document.getElementById("errPhone"), kind: "phone" },
{ input: document.getElementById("fType"), error: document.getElementById("errType"), kind: "required" },
{ input: document.getElementById("fCity"), error: document.getElementById("errCity"), kind: "required" }
];
fields.forEach(({ input, error }) => {
if (!input) return;
input.addEventListener("input", () => clearError(input, error));
input.addEventListener("change", () => clearError(input, error));
});
form.addEventListener("submit", (event) => {
event.preventDefault();
const dict = I18N[currentLang];
let valid = true;
let firstInvalid = null;
fields.forEach(({ input, error, kind }) => {
if (!input) return;
const value = input.value.trim();
if (kind === "required" && !value) {
showError(input, error, dict["err.required"]);
valid = false;
if (!firstInvalid) firstInvalid = input;
} else if (kind === "email" && value && !/^[^\s@]+@[^\s@]+\.[^\s@]{2,}$/.test(value)) {
showError(input, error, dict["err.email"]);
valid = false;
if (!firstInvalid) firstInvalid = input;
} else if (kind === "phone" && value && !/^\+?[0-9\s\-().]{7,20}$/.test(value)) {
showError(input, error, dict["err.phone"]);
valid = false;
if (!firstInvalid) firstInvalid = input;
}
});
if (!valid) {
if (firstInvalid) firstInvalid.focus();
return;
}
// Demo form: no data is sent or stored.
form.hidden = true;
success.hidden = false;
success.scrollIntoView({ behavior: "smooth", block: "center" });
});
if (resetBtn) {
resetBtn.addEventListener("click", () => {
form.reset();
fields.forEach(({ input, error }) => clearError(input, error));
success.hidden = true;
form.hidden = false;
});
}
}
/* ---------------- Language buttons ---------------- */
function initLangSwitch() {
document.querySelectorAll(".lang-btn").forEach((btn) => {
btn.addEventListener("click", () => applyLanguage(btn.getAttribute("data-lang")));
});
}
/* ---------------- Init ---------------- */
document.addEventListener("DOMContentLoaded", () => {
applyLanguage(getStoredLang());
initLangSwitch();
initMenu();
initFaq();
initForm();
});
+646
View File
@@ -0,0 +1,646 @@
/* ============================================================
Huurbaken — styles
Brand: deep green #0E3B2E · cream #F7F3EC · sand #EFE7D8
gold/amber accent #C9A227 · ink #1C2420
Fonts: Fraunces (display serif) · Inter (body sans)
============================================================ */
:root {
--green: #0e3b2e;
--green-2: #14503f;
--green-3: #0a2e24;
--cream: #f7f3ec;
--sand: #efe7d8;
--sand-2: #e6dcc8;
--gold: #c9a227;
--gold-2: #b08d1e;
--ink: #1c2420;
--muted: #5b6b62;
--white: #ffffff;
--line: #ddd5c3;
--error: #b3261e;
--radius: 14px;
--shadow: 0 10px 30px rgba(14, 59, 46, 0.10);
--header-h: 72px;
}
* { box-sizing: border-box; }
html {
scroll-behavior: smooth;
scroll-padding-top: calc(var(--header-h) + 16px);
}
body {
margin: 0;
font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
font-size: 16px;
line-height: 1.6;
color: var(--ink);
background: var(--cream);
-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
h1, h2, h3 {
font-family: "Fraunces", Georgia, "Times New Roman", serif;
font-weight: 600;
line-height: 1.15;
color: var(--green);
margin: 0 0 0.5em;
}
h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
a { color: var(--green-2); }
a:hover { color: var(--gold-2); }
.container {
width: min(1180px, 92%);
margin-inline: auto;
}
.section { padding: 84px 0; }
.section-tinted { background: var(--sand); }
.section-eyebrow {
margin: 0 0 0.4em;
font-size: 0.82rem;
font-weight: 700;
letter-spacing: 0.14em;
text-transform: uppercase;
color: var(--gold-2);
}
.section-sub {
max-width: 640px;
color: var(--muted);
font-size: 1.08rem;
margin-bottom: 2.2em;
}
.skip-link {
position: absolute;
left: -9999px;
top: 0;
background: var(--green);
color: #fff;
padding: 10px 16px;
z-index: 200;
border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: #fff; }
/* ---------- Buttons ---------- */
.btn {
display: inline-block;
padding: 13px 26px;
border-radius: 999px;
font-weight: 600;
font-size: 0.98rem;
text-decoration: none;
border: 2px solid transparent;
cursor: pointer;
transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
text-align: center;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--gold); color: #231f08; border-color: var(--gold); }
.btn-primary:hover { background: var(--gold-2); border-color: var(--gold-2); color: #fff; }
.btn-ghost { background: transparent; color: var(--green); border-color: var(--green); }
.btn-ghost:hover { background: var(--green); color: #fff; }
.btn-block { width: 100%; }
/* ---------- Header ---------- */
.site-header {
position: sticky;
top: 0;
z-index: 100;
background: rgba(247, 243, 236, 0.96);
backdrop-filter: blur(6px);
border-bottom: 1px solid var(--line);
min-height: var(--header-h);
display: flex;
align-items: center;
}
.header-inner {
display: flex;
align-items: center;
gap: 28px;
}
.brand {
display: flex;
align-items: center;
gap: 10px;
text-decoration: none;
flex-shrink: 0;
}
.brand-logo { width: 40px; height: 40px; }
.brand-name {
font-family: "Fraunces", Georgia, serif;
font-weight: 700;
font-size: 1.45rem;
color: var(--green);
letter-spacing: -0.01em;
}
.main-nav {
display: flex;
gap: 26px;
margin-left: auto;
}
.main-nav a {
color: var(--ink);
text-decoration: none;
font-weight: 500;
font-size: 0.95rem;
white-space: nowrap;
}
.main-nav a:hover { color: var(--gold-2); }
.header-actions {
display: flex;
align-items: center;
gap: 14px;
margin-left: auto;
}
.main-nav + .header-actions { margin-left: 0; }
.lang-switch {
display: flex;
align-items: center;
gap: 2px;
border: 1.5px solid var(--line);
border-radius: 999px;
padding: 3px;
background: var(--white);
}
.lang-btn {
border: 0;
background: transparent;
font: inherit;
font-weight: 700;
font-size: 0.85rem;
color: var(--muted);
padding: 5px 10px;
border-radius: 999px;
cursor: pointer;
}
.lang-btn.is-active { background: var(--green); color: #fff; }
.lang-sep { color: var(--line); font-size: 0.8rem; }
.header-cta { padding: 10px 20px; font-size: 0.92rem; }
.menu-toggle {
display: none;
background: none;
border: 0;
cursor: pointer;
padding: 8px;
flex-direction: column;
gap: 5px;
}
.menu-toggle span {
display: block;
width: 24px;
height: 2.5px;
background: var(--green);
border-radius: 2px;
transition: transform 0.2s ease, opacity 0.2s ease;
}
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
/* ---------- Hero ---------- */
.hero { padding: 72px 0 84px; }
.hero-grid {
display: grid;
grid-template-columns: 1.05fr 0.95fr;
gap: 56px;
align-items: center;
}
.hero-badge {
display: inline-block;
background: var(--sand);
border: 1px solid var(--line);
color: var(--green-2);
font-size: 0.85rem;
font-weight: 600;
padding: 6px 14px;
border-radius: 999px;
margin-bottom: 1.2em;
}
.hero-sub { font-size: 1.12rem; color: var(--muted); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.6em 0 1.8em; }
.trust-points {
list-style: none;
margin: 0;
padding: 0;
display: flex;
flex-wrap: wrap;
gap: 8px 22px;
}
.trust-points li { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 0.95rem; }
.trust-icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 22px;
height: 22px;
border-radius: 50%;
background: var(--green);
color: #fff;
font-size: 0.78rem;
flex-shrink: 0;
}
.hero-media { position: relative; }
.hero-media img {
width: 100%;
height: 480px;
object-fit: cover;
border-radius: 20px;
background: var(--sand-2);
}
.hero-card {
position: absolute;
left: -14px;
bottom: 26px;
background: var(--white);
border-radius: var(--radius);
box-shadow: var(--shadow);
padding: 16px 22px;
min-width: 190px;
}
.hero-card-label { margin: 0; font-size: 0.85rem; color: var(--muted); }
.hero-card-value {
margin: 0;
font-family: "Fraunces", Georgia, serif;
font-size: 2.1rem;
font-weight: 700;
color: var(--green);
line-height: 1.1;
}
.hero-card-note { margin: 0; font-size: 0.85rem; font-weight: 600; color: var(--gold-2); }
/* ---------- Steps ---------- */
.steps {
list-style: none;
margin: 0;
padding: 0;
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 22px;
counter-reset: step;
}
.step {
background: var(--white);
border: 1px solid var(--line);
border-radius: var(--radius);
padding: 28px 24px;
}
.step-num {
display: inline-flex;
align-items: center;
justify-content: center;
width: 46px;
height: 46px;
border-radius: 50%;
background: var(--green);
color: #fff;
font-family: "Fraunces", Georgia, serif;
font-size: 1.3rem;
font-weight: 700;
margin-bottom: 16px;
}
.step h3 { margin-bottom: 0.4em; }
.step p { color: var(--muted); margin: 0; font-size: 0.96rem; }
/* ---------- Why ---------- */
.why-grid {
display: grid;
grid-template-columns: 0.85fr 1.15fr;
gap: 56px;
align-items: start;
}
.why-img {
width: 100%;
height: 300px;
object-fit: cover;
border-radius: 18px;
margin-top: 8px;
background: var(--sand-2);
}
.why-cards {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 18px;
}
.why-card {
background: var(--white);
border: 1px solid var(--line);
border-radius: var(--radius);
padding: 24px;
}
.why-card h3 { margin-bottom: 0.35em; }
.why-card p { color: var(--muted); margin: 0; font-size: 0.95rem; }
/* ---------- Property types ---------- */
.type-grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 20px;
}
.type-card {
background: var(--white);
border: 1px solid var(--line);
border-radius: var(--radius);
overflow: hidden;
box-shadow: 0 4px 16px rgba(14, 59, 46, 0.06);
}
.type-card img { width: 100%; height: 180px; object-fit: cover; background: var(--sand-2); }
.type-body { padding: 20px; }
.type-body h3 { margin-bottom: 0.3em; }
.type-body p { color: var(--muted); margin: 0; font-size: 0.95rem; }
/* ---------- Value teaser ---------- */
.value-grid {
display: grid;
grid-template-columns: 0.9fr 1.1fr;
gap: 56px;
align-items: start;
}
.value-note { color: var(--muted); }
.value-table-wrap { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.value-table { width: 100%; border-collapse: collapse; font-size: 0.97rem; }
.value-table th, .value-table td { padding: 14px 18px; text-align: left; }
.value-table thead th {
background: var(--green);
color: #fff;
font-weight: 600;
font-size: 0.88rem;
letter-spacing: 0.02em;
}
.value-table tbody tr + tr td { border-top: 1px solid var(--line); }
.value-table tbody td:last-child { font-weight: 600; color: var(--green); white-space: nowrap; }
.testdata-tag {
margin: 0;
padding: 10px 18px;
background: var(--sand);
font-size: 0.82rem;
color: var(--muted);
}
/* ---------- Testimonials ---------- */
.testi-grid {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 20px;
}
.testi-card {
margin: 0;
background: var(--white);
border: 1px solid var(--line);
border-radius: var(--radius);
padding: 26px;
display: flex;
flex-direction: column;
gap: 18px;
}
.testi-card blockquote {
margin: 0;
font-family: "Fraunces", Georgia, serif;
font-size: 1.12rem;
line-height: 1.5;
color: var(--green);
}
.testi-card figcaption {
display: flex;
align-items: center;
gap: 12px;
font-size: 0.9rem;
color: var(--muted);
margin-top: auto;
}
.testi-card figcaption strong { color: var(--ink); }
.avatar {
display: inline-flex;
align-items: center;
justify-content: center;
width: 44px;
height: 44px;
border-radius: 50%;
background: var(--green);
color: #fff;
font-weight: 700;
font-size: 0.9rem;
flex-shrink: 0;
}
/* ---------- FAQ ---------- */
.faq-wrap { max-width: 820px; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
gap: 16px;
background: none;
border: 0;
padding: 20px 4px;
font: inherit;
font-family: "Fraunces", Georgia, serif;
font-size: 1.15rem;
font-weight: 600;
color: var(--green);
text-align: left;
cursor: pointer;
}
.faq-icon {
flex-shrink: 0;
width: 30px;
height: 30px;
border-radius: 50%;
border: 1.5px solid var(--green);
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 1.2rem;
line-height: 1;
transition: transform 0.2s ease;
}
.faq-item.open .faq-icon { transform: rotate(45deg); background: var(--green); color: #fff; }
.faq-a {
max-height: 0;
overflow: hidden;
transition: max-height 0.28s ease;
}
.faq-a p { color: var(--muted); padding: 0 4px 20px; margin: 0; }
/* ---------- Lead form ---------- */
.form-grid {
display: grid;
grid-template-columns: 0.9fr 1.1fr;
gap: 56px;
align-items: start;
}
.form-points {
list-style: none;
margin: 0 0 1.4em;
padding: 0;
display: grid;
gap: 8px;
}
.form-points li { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.form-points li span:first-child {
display: inline-flex;
align-items: center;
justify-content: center;
width: 22px;
height: 22px;
border-radius: 50%;
background: var(--green);
color: #fff;
font-size: 0.78rem;
flex-shrink: 0;
}
.form-demo-note { font-size: 0.85rem; color: var(--muted); }
.form-card {
background: var(--white);
border: 1px solid var(--line);
border-radius: 18px;
padding: 32px;
box-shadow: var(--shadow);
}
.field { margin-bottom: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { display: block; font-weight: 600; font-size: 0.92rem; margin-bottom: 6px; }
.field input,
.field select,
.field textarea {
width: 100%;
font: inherit;
font-size: 0.97rem;
padding: 12px 14px;
border: 1.5px solid var(--line);
border-radius: 10px;
background: var(--cream);
color: var(--ink);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
outline: none;
border-color: var(--green);
background: var(--white);
box-shadow: 0 0 0 3px rgba(14, 59, 46, 0.14);
}
.field input.invalid,
.field select.invalid { border-color: var(--error); background: #fdf3f2; }
.field textarea { resize: vertical; min-height: 110px; }
.field-error { color: var(--error); font-size: 0.85rem; margin: 6px 0 0; }
.privacy-note { font-size: 0.85rem; color: var(--muted); text-align: center; margin: 14px 0 0; }
.form-success { text-align: center; padding: 24px 8px; }
.success-icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 64px;
height: 64px;
border-radius: 50%;
background: var(--green);
color: #fff;
font-size: 1.8rem;
margin: 0 0 16px;
}
.form-success h3 { font-size: 1.5rem; }
.form-success p { color: var(--muted); }
.form-success .btn { margin-top: 8px; }
/* ---------- Footer ---------- */
.site-footer { background: var(--green-3); color: #cfd8d2; }
.site-footer .brand-name { color: #fff; }
.footer-grid {
display: grid;
grid-template-columns: 1.4fr 1fr 1fr;
gap: 48px;
padding: 64px 0 40px;
}
.footer-brand p { color: #b9c4bb; max-width: 380px; }
.footer-col h3 {
color: #fff;
font-family: "Inter", system-ui, sans-serif;
font-size: 0.92rem;
letter-spacing: 0.08em;
text-transform: uppercase;
margin-bottom: 14px;
}
.footer-col a {
display: block;
color: #cfd8d2;
text-decoration: none;
margin-bottom: 8px;
font-size: 0.95rem;
}
.footer-col a:hover { color: var(--gold); }
.footer-col p { margin: 0 0 10px; font-size: 0.95rem; }
.footer-bottom {
border-top: 1px solid rgba(255, 255, 255, 0.14);
padding: 20px 0 26px;
display: flex;
flex-wrap: wrap;
gap: 8px 32px;
justify-content: space-between;
font-size: 0.85rem;
color: #9fb0a4;
}
.footer-bottom p { margin: 0; }
/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
.hero-grid { gap: 36px; }
.steps { grid-template-columns: repeat(2, 1fr); }
.type-grid { grid-template-columns: repeat(2, 1fr); }
.why-grid, .value-grid, .form-grid { grid-template-columns: 1fr; gap: 36px; }
.why-img { height: 260px; }
}
@media (max-width: 768px) {
.section { padding: 60px 0; }
.main-nav {
display: none;
position: absolute;
top: var(--header-h);
left: 0;
right: 0;
background: var(--cream);
border-bottom: 1px solid var(--line);
flex-direction: column;
gap: 0;
padding: 8px 4%;
box-shadow: 0 18px 30px rgba(14, 59, 46, 0.12);
}
.main-nav.open { display: flex; }
.main-nav a { padding: 13px 6px; border-top: 1px solid var(--line); }
.main-nav a:first-child { border-top: 0; }
.header-actions { margin-left: auto; }
.header-cta { display: none; }
.menu-toggle { display: flex; }
.hero { padding: 48px 0 60px; }
.hero-grid { grid-template-columns: 1fr; }
.hero-media img { height: 320px; }
.hero-card { left: 12px; bottom: 14px; }
.testi-grid { grid-template-columns: 1fr; }
.footer-grid { grid-template-columns: 1fr; gap: 32px; padding: 48px 0 32px; }
}
@media (max-width: 480px) {
body { font-size: 15px; }
.steps, .type-grid, .why-cards { grid-template-columns: 1fr; }
.field-row { grid-template-columns: 1fr; }
.form-card { padding: 24px 20px; }
.hero-media img { height: 260px; }
.brand-name { font-size: 1.3rem; }
.lang-btn { padding: 5px 8px; }
}