feat: enhance booking flow with BPF wizard, weekend pricing, and document uploads

- Updated translations for German and English to reflect changes in deposit terminology.
- Modified index.html to implement a new booking flow with a step-by-step wizard for vehicle selection, contact details, and ID verification.
- Added CSS styles for the new booking flow interface, including responsive design and improved input styles.
- Created new database policies and tables for handling customer and lead attachments during the booking process.
- Introduced weekend pricing and daily KM limits for vehicles in the database schema.
- Implemented email-based customer upsert functionality to streamline lead qualification and attachment transfer.

Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
LagoESP
2026-04-29 15:01:25 +02:00
parent d17fe0651e
commit d960e37aa8
10 changed files with 880 additions and 86 deletions
+134 -2
View File
@@ -329,6 +329,24 @@ select, input, textarea {
transition: border-color 0.15s;
}
input[type="date"] {
color-scheme: dark;
text-transform: uppercase;
letter-spacing: 0.05em;
font-size: 0.9rem;
cursor: pointer;
}
input[type="date"]::-webkit-calendar-picker-indicator {
opacity: 0.5;
transition: opacity 0.2s;
cursor: pointer;
}
input[type="date"]::-webkit-calendar-picker-indicator:hover {
opacity: 1;
}
select:focus, input:focus, textarea:focus {
outline: none;
border-color: var(--accent);
@@ -562,7 +580,7 @@ select:focus, input:focus, textarea:focus {
.booking-form label { display: grid; gap: 0.5rem; font-size: 0.88rem; color: var(--text); font-weight: 500; transition: color 0.2s; }
.booking-form label:focus-within { color: var(--accent-strong); }
select, input, textarea {
.bpf-panel select, .bpf-panel input, .bpf-panel textarea {
width: 100%;
padding: 0.85rem 1rem;
background: var(--bg-elev);
@@ -573,7 +591,7 @@ select, input, textarea {
transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}
select:focus, input:focus, textarea:focus {
.bpf-panel select:focus, .bpf-panel input:focus, .bpf-panel textarea:focus {
outline: none;
border-color: var(--accent);
box-shadow: 0 0 0 3px rgba(196, 138, 66, 0.2);
@@ -587,6 +605,120 @@ select:focus, input:focus, textarea:focus {
}
.form-feedback.error { color: var(--danger); }
/* ---------------- Booking BPF Wizard ---------------- */
.bpf-header { text-align: center; margin-bottom: 2.5rem; }
.bpf-header h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 0.5rem; }
.bpf-header .sub { color: var(--muted); font-size: 1rem; max-width: 50ch; margin: 0 auto; }
.bpf-steps {
display: flex; align-items: center; justify-content: center;
gap: 0.5rem; margin-bottom: 2.5rem; flex-wrap: wrap;
}
.bpf-step {
display: inline-flex; align-items: center; gap: 0.5rem;
background: rgba(255,255,255,0.03); border: 1px solid var(--line);
border-radius: 999px; padding: 0.6rem 1.2rem;
color: var(--muted); font-size: 0.88rem; font-weight: 500;
cursor: default; font-family: inherit; transition: all 0.3s ease;
}
.bpf-step.active {
background: var(--accent); color: #0b0c10; border-color: var(--accent);
font-weight: 600;
}
.bpf-step.done { border-color: var(--ok); color: var(--ok); }
.bpf-step-num {
display: inline-grid; place-items: center;
width: 1.5rem; height: 1.5rem; border-radius: 50%;
background: rgba(255,255,255,0.1); font-size: 0.75rem; font-weight: 700;
}
.bpf-step.active .bpf-step-num { background: rgba(0,0,0,0.2); color: #0b0c10; }
.bpf-step-arrow { color: var(--muted); font-size: 1.2rem; }
.bpf-layout {
display: grid; grid-template-columns: 1fr 340px; gap: 2rem; align-items: start;
}
.bpf-main { min-width: 0; }
.bpf-panel {
background: var(--bg-card); border: 1px solid var(--line);
border-radius: var(--radius); padding: 2rem;
animation: slideUpFade 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.bpf-panel-title { font-size: 1.1rem; font-family: "Inter", sans-serif; margin-bottom: 1.5rem; font-weight: 600; }
.bpf-field { margin-bottom: 1.2rem; }
.bpf-field label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.4rem; color: var(--text); }
.bpf-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.bpf-weekend-def {
font-size: 0.8rem; color: var(--accent-strong); margin: 0.5rem 0 1.5rem;
padding: 0.5rem 0.8rem; background: rgba(196, 138, 66, 0.08);
border-radius: 8px; border-left: 3px solid var(--accent);
}
/* Duration presets */
.bpf-duration-presets {
display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; margin-top: 0.4rem;
}
.bpf-preset {
display: flex; flex-direction: column; align-items: center; justify-content: center;
gap: 0.4rem; padding: 1rem 0.8rem;
background: var(--bg-elev); border: 1px solid var(--line); border-radius: 12px;
color: var(--text); font-family: inherit; font-size: 0.88rem; font-weight: 500;
cursor: pointer; transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.bpf-preset:hover { border-color: var(--accent); background: rgba(196, 138, 66, 0.06); }
.bpf-preset.active {
background: rgba(180, 50, 50, 0.15); border-color: var(--danger);
color: var(--text); box-shadow: 0 0 0 1px var(--danger);
}
.bpf-preset-icon { font-size: 1.3rem; }
.bpf-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 1.5rem; }
/* Upload boxes */
.bpf-upload-box {
display: flex; flex-direction: column; align-items: center; justify-content: center;
gap: 0.4rem; padding: 2rem;
border: 1px dashed var(--line); border-radius: 10px;
cursor: pointer; position: relative; transition: border-color 0.2s ease, background 0.2s ease;
min-height: 120px;
}
.bpf-upload-box:hover { border-color: var(--accent); background: rgba(196,138,66,0.04); }
.bpf-upload-icon { font-size: 1.5rem; }
.bpf-file-input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.bpf-file-name { font-size: 0.82rem; color: var(--ok); margin-top: 0.3rem; min-height: 1.2rem; }
.bpf-notice {
display: flex; align-items: flex-start; gap: 0.8rem;
padding: 1rem; background: var(--bg-elev);
border: 1px solid var(--line); border-radius: 10px; margin: 1.5rem 0;
}
.bpf-notice span { font-size: 1.2rem; flex-shrink: 0; }
.bpf-notice p { margin: 0; font-size: 0.85rem; color: var(--muted); line-height: 1.5; }
/* Sidebar */
.bpf-sidebar {
background: var(--bg-card); border: 1px solid var(--line);
border-radius: var(--radius); padding: 1.8rem;
position: sticky; top: 6rem;
}
.bpf-sidebar-placeholder { color: var(--muted); text-align: center; font-size: 0.9rem; }
.bpf-sidebar-content h4 { font-family: "Inter", sans-serif; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 1rem; }
.bpf-sidebar-content .bpf-price-row { display: flex; justify-content: space-between; padding: 0.5rem 0; font-size: 0.9rem; }
.bpf-sidebar-content .bpf-price-row.total { font-weight: 700; font-size: 1.1rem; color: var(--accent-strong); border-top: 1px solid var(--line); padding-top: 0.8rem; margin-top: 0.5rem; }
.bpf-sidebar-content .bpf-price-row .muted { color: var(--muted); }
.bpf-sidebar-content .bpf-car-preview { width: 100%; aspect-ratio: 16/10; border-radius: 10px; background: var(--bg-elev) center/cover no-repeat; margin-top: 1.2rem; }
.bpf-sidebar-content .bpf-car-name { font-weight: 700; margin-top: 0.6rem; text-transform: uppercase; font-size: 0.85rem; letter-spacing: 0.05em; }
.bpf-sidebar-content .bpf-car-specs { font-size: 0.82rem; color: var(--muted); }
@media (max-width: 900px) {
.bpf-layout { grid-template-columns: 1fr; }
.bpf-sidebar { position: static; }
.bpf-field-row { grid-template-columns: 1fr; }
}
/* ---------------- Footer ---------------- */
.site-footer {
border-top: 1px solid var(--line);