=== Appointment Booking Calendar & Scheduling – Zoe Booking ===
Contributors: inflowsurge
Tags: booking, appointments, calendar, elementor, woocommerce
Requires at least: 6.0
Tested up to: 7.0.2
Requires PHP: 7.4
Stable tag: 1.7.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Beautiful appointment booking — calendar, staff, group bookings, online payments (Square) and a customer panel. Stripe, PayPal & WooCommerce in PRO.

== Description ==

Zoe Booking turns your WordPress site into a complete booking system in about five minutes. Add services and staff, drop the form on any page, and start taking appointments — free reservations, hosted online payments or the WooCommerce checkout.

**Three ways to take bookings**

* **Standalone** — instant reservations (confirmed automatically or pending your approval). No other plugin needed.
* **Standalone — pay online** — customers pay on a hosted checkout (Square built in; Stripe and PayPal come with the PRO add-on). The booking is created only after the payment is verified server-side; if the slot was taken while paying, the charge is refunded automatically.
* **WooCommerce** (PRO add-on) — bookings ride through the cart and checkout as products, with prefilled customer details.

**A booking form people enjoy using**

* Four friendly steps: service → date & time → details → confirm, with a live price summary.
* Five layouts (sidebar with photo, numbered process timeline, top stepper, slim progress bar, icon rail) and five design skins (Classic, Minimal outline, Soft, Dark, Glass).
* Every colour, corner radius, spacing and font control is free and fully editable — nothing about styling the form is locked.
* **Design presets (PRO add-on)** — nine finished looks (Zoe Classic, Nordic, Midnight, Blush, Atelier, Clinic, Terracotta, Mono, Botanical) applied in one click, plus saving your own and carrying it to another site. What PRO sells here is not the ability to style the form — it is not having to.
* Popup mode — show just a button, the form opens in an elegant modal.
* Calendar days fill up visually as they get booked; time slots show remaining group spots.
* An **"Earliest available"** button jumps to the first free slot — on a calendar where the next three weeks are full, that is the difference between a booking and a closed tab.
* A decoy field and a per-visitor hourly cap keep automated submissions out of the calendar without a CAPTCHA or a third-party service.
* Phone field with a country dial-code picker, validated email, optional customer notes.
* Dedicated Elementor widget — layout, design skin, colours, typography, spacing and the sidebar photo are all editable straight in the Elementor panel. A Gutenberg block and the `[ms_booking]` shortcode render the same form everywhere else.
* A service catalogue with `[ms_services]` or its own Elementor widget: your services as cards (photo, description, duration, price) in list, grid or large-card layouts, with optional category filters, search and sorting — and a Book button that opens the form on that service.
* 12 or 24-hour time, any currency symbol and position, renameable terminology (Service → Class, Person → Coach…), single-person mode.

**Run the business, not the admin**

* A visual month calendar with colour-coded bookings, day panel and one-click manual bookings.
* **Move an appointment** straight from the day panel — pick a new date, pick from the free times. The booking keeps everything (id, customer, price, payment) and the customer gets a calendar invite for the new time. Moving is not bound by the minimum-notice rule: "the customer just called to say they're running late" has to be answerable.
* A bookings list tinted by status, with print-ready details sheets, one-click deletes and a CSV export of whatever your filters select.
* **Private notes** on any booking — what you need to remember about a customer, never shown to them.
* **CSV import** to bring an existing calendar (and its customers) over from a spreadsheet or another plugin, with a dry run before anything is written and no emails sent to anyone.
* Optional **conversion tracking**: a completed booking is announced to your own analytics — GA4, Google Tag Manager or Meta Pixel — without Zoe loading a single third-party script.
* A dashboard with 30-day revenue, bookings, average value and cancellation-rate charts.
* Emails with .ics calendar invites, automatic reminders, and a QR code customers scan to drop the appointment into their phone's calendar.

**Schedules that fit real people**

* A **weekly schedule** per person, the services they offer, and time off as single days or whole date ranges.
* **Special days** — different hours on one particular date. A coach who is free on Tuesday this week and Saturday the next does not need a weekly grid that fits nobody: pick the date, set the hours. A special day also opens a day that is normally closed, and a day off always wins over it, so a holiday can never be reopened by accident.
* **Buffers before and after a service** — the room needs resetting, you need to drive there. The gap is held clear on both sides, so the next slot never starts on top of it.
* **Booking rules** you set once: a **minimum notice** (nothing inside the next N hours — no more "someone booked for ten minutes from now"), and a **booking window** (how far ahead the calendar opens, so nobody reserves a haircut for next April). Slots outside the rules are never shown, and a tampered request is refused server-side.
* Free slots are worked out from the schedule, the service length (plus the gaps around it) and the bookings you already have — two customers can never grab the same slot, even if they pay at the very same moment.

**Staff panel (PRO add-on)**

Each team member gets their own small corner of the WordPress admin: a **"today" strip** (how many appointments, how many are done, what is next), **their own appointments** with quick status changes and rescheduling, **their own month calendar**, **their own schedule** — weekly hours, days off and special days — and a **My Profile** page for the name and photo customers see. No settings, no payments, no revenue, nobody else's bookings. You create a WordPress account with the "Zoe Staff" role, link it on the Staff screen, and that is the whole setup.

**You decide how much of that they get.** Settings → *What staff can do* has a switch for each: statuses, rescheduling, managing their own hours, seeing the customer's phone number, editing their own profile. All on by default; every one is enforced on the server, so a switch you turn off is genuinely closed rather than merely hidden.

**Earnings & commissions (PRO add-on)**

What each person brought in over a period, and what you owe them: appointments, revenue, commission and what you keep, per person, for any date range — with a CSV export. Give each person a percentage or a fixed rate; a service with a different margin can override it for everyone who performs it. Revenue comes from the price stored with each booking, so changing a price later never rewrites past months, and cancelled or refunded bookings are excluded.

Zoe **reports** what is owed and stops there — it never moves money. Automatic payment splitting would mean running your own Stripe Connect platform, putting every team member through identity checks and carrying the liability for their payouts and chargebacks. For a three-chair salon that is an absurd amount of paperwork for something a bank transfer already solves.

**Feature switchboard**

Every capability has an on/off switch under Zoe Booking → Features, so the plugin stays exactly as light as you need: design presets, duration variants, taxes, online meeting links, service extras, group appointments, recurring series, per-staff calendar feeds, online payments, QR add-to-calendar, WhatsApp links and the customer panel.

**Events & tickets (PRO add-on)**

Events (workshops, openings, concerts) with a ticket pool, image and description — sold through any booking mode and displayed with the Events widget or `[ms_events]` shortcode in list, grid or standard layouts. An event can run on one date or on many: a workshop series stays a single event, customers choose their date at checkout, and every date sells its own seats. Events are not tied to anyone's working hours, so a date in a quiet month needs no schedule juggling.

**Customer panel**

A front-end account area with passwordless magic-link sign-in: customers see their appointments and tickets, cancel online, download invoices, edit their details — and exercise their GDPR rights (export or permanently delete their data) themselves. `[ms_customer_panel]` or the Elementor widget.

**Free vs Premium**

The free plugin is complete on its own: unlimited services and staff, CSV import, private notes, conversion tracking, the full booking form (all layouts, skins and popup mode), the service catalogue, the visual month calendar, the bookings list with CSV export and the dashboard, weekly schedules with days off and special days, booking rules (minimum notice, booking window, buffers before and after), the "earliest available" shortcut, spam protection, Square online payments, email notifications and reminders, .ics calendar invites, QR add-to-calendar, per-staff calendar feeds, taxes, duration variants, service extras, group appointments, recurring series, WhatsApp links, online-meeting links, the customer panel and full translations.

Zoe Booking PRO (a separate add-on, not included in this plugin) adds: the design-preset gallery and saving your own, the staff panel, the earnings & commissions report, Stripe & PayPal payments, WooCommerce checkout, discount coupons, waiting lists, multiple locations, invoices, refunds and events & tickets.

== External services ==

Zoe Booking runs entirely on your own site and stores all data in your WordPress database. It connects to external services **only** when you enable the corresponding feature and add your own API keys:

* **Stripe** (api.stripe.com) — when Stripe is your payment gateway: creating checkout sessions, verifying payments and issuing refunds. Data sent: booking amount, currency, item name and the customer's email. [Terms](https://stripe.com/legal), [Privacy](https://stripe.com/privacy).
* **PayPal** (api-m.paypal.com) — when PayPal is your gateway: creating and capturing orders and issuing refunds. Data sent: amount, currency, item name. [Terms](https://www.paypal.com/legalhub/home), [Privacy](https://www.paypal.com/privacy).
* **Square** (connect.squareup.com) — when Square is your gateway: creating payment links, verifying orders and issuing refunds. Data sent: amount, currency, item name, buyer email. [Terms](https://squareup.com/legal/general/ua), [Privacy](https://squareup.com/legal/general/privacy).

The optional WhatsApp feature only renders standard `wa.me` links — no data is transmitted until the user taps the link.

* **zoebooking.com** (our own licensing service) — used only for the optional PRO license. Activating or re-checking a PRO license key sends that key and your site's hostname to zoebooking.com to verify it; nothing is sent while no key is entered, and no third-party script is ever loaded. The "Get PRO" admin page simply links to our website. With an activated key, the optional "Install PRO now" button downloads the PRO package you purchased from zoebooking.com (the request carries only your license key) and installs it — nothing is ever downloaded without that explicit click. [Terms](https://zoebooking.com/terms.html), [Privacy](https://zoebooking.com/privacy.html).

Nothing else calls home: the QR code renderer and the flag font ship inside the plugin.

== Installation ==

1. Upload the `zoebooking` folder to `/wp-content/plugins/`, or install it from the Plugins screen.
2. Activate the plugin — a Zoe Booking menu with a welcome dashboard appears.
3. Add a Service and a Staff member (with a weekly schedule).
4. Put the form on a page: the Zoe Booking Elementor widget, the Gutenberg block or `[ms_booking]`.
5. Pick your booking mode under Zoe Booking → Settings and flip on any features you need.

== Frequently Asked Questions ==

= Do I need WooCommerce? =
No. Standalone mode works on its own, and online payments (Stripe / PayPal / Square) work without WooCommerce too. Selling bookings through the WooCommerce cart and checkout is an optional mode available in Zoe Booking PRO.

= Does it work with Elementor? =
Yes — Zoe Booking ships a dedicated Elementor widget with full Style controls: layouts, design skins, colours, typography and spacing are all configurable per widget, live in the editor. No Elementor? The Gutenberg block and the `[ms_booking]` shortcode render the exact same form.

= How do online payments stay safe? =
The reservation is only written after the gateway confirms the payment server-side. Availability is re-checked at that moment — if the slot was taken while the customer was paying, the charge is refunded automatically.

= Can customers manage their own bookings? =
Yes — enable the Customer Panel feature. Customers sign in with a magic email link (no passwords, no WordPress accounts), see their appointments and tickets, cancel, download invoices and edit or delete their personal data.

= Can my team see their own bookings without seeing everything else? =
Yes — that is the Staff panel (PRO). Give the person a WordPress account with the "Zoe Staff" role and link it on the Staff screen. They then see only their own appointments and calendar, and manage their own hours, days off and special days. Settings, payments, revenue and everyone else's bookings stay out of reach.

= What if someone works different hours on one particular date? =
Add a **special day** on the Staff screen: a date with its own start and end time. It replaces the weekly hours for that date and can also open a day that is normally closed. Days off always win, so a holiday cannot be reopened by mistake.

= Can several people share one time slot? =
Yes — set a group capacity on the service. Slots show the remaining spots and prices are per person.

= Are reminders sent automatically? =
Yes, when enabled in Settings. They run on WordPress cron, so they fire on site traffic; for precise timing use a real system cron.

= Is it translation-ready? =
Fully — gettext throughout (text domain `zoebooking`), and it ships with complete Dutch, French, German, Italian, Polish and Spanish translations out of the box. The Terminology settings additionally allow quick renames (Service → Class…) without touching translation files.

= Does uninstalling remove my data? =
Options are cleaned up. Bookings, services, staff and events are only deleted if you tick “Delete all data on uninstall” in Settings first.

== Screenshots ==

1. The customer-facing booking form — pick a service, staff, date and time in a clean, mobile-friendly flow.
2. At-a-glance dashboard — today's bookings, revenue, cancellation rate and your most-booked services.
3. Month calendar with every booking colour-coded by status — click any day for the full agenda.
4. Powerful bookings list — search, filter, change status and export to CSV in one place.
5. Define services — a duration, price and category for everything customers can book.
6. Give each team member a weekly schedule, assigned services and time off.
7. Turn plugin capabilities on and off to match how you work.
8. Configure booking mode, payments, notifications, terminology and brand colours.

== Changelog ==

= 1.7.0 =
* New: **Import bookings from a CSV** — move your calendar over from a spreadsheet or another booking plugin, customers included. Zoe recognises the usual column names, reads several date and time formats, and always offers a **dry run first**: it reads the whole file, tells you exactly what would happen and writes nothing. Services and people are matched by name and never created for you. Imports are silent — nobody is emailed about an appointment they made months ago somewhere else.
* New: **Private notes on a booking** — "always 15 minutes late", "prefers the quiet room". Yours alone: the customer never sees it, and neither does the staff panel.
* New: **Conversion tracking** — announce completed bookings to the analytics your site already runs (a `zoe_booking` dataLayer event, a GA4 `purchase`, a Meta Pixel `Schedule`). Zoe loads no tracking script and contacts nobody; it only speaks to a tag that is already on the page. Off by default.
* New (PRO): **You decide what staff can do** — five switches under Settings → What staff can do: change statuses, move appointments, manage their own hours, see the customer's phone number, edit their own name and photo. Everything starts switched on, so nothing changes when you update; untick what you would rather keep. Each one is enforced on the server, not just hidden from the screen.
* New (PRO): a **"today" strip** at the top of the staff panel — how many appointments, how many are behind them, and what is next — and a **My Profile** page where they can change the name and photo customers see. Uploading a photo does not give them the media library.
* New: **Move an appointment** — reschedule from the calendar day panel instead of deleting and re-booking. Pick a date, pick from the free times, done. The booking keeps its id, its customer, its price and its payment, and the customer is emailed a fresh calendar invite for the new time. Staff can move their own appointments from their panel (PRO), except ones that have been paid for — those stay with the owner.
* New (PRO): **Earnings & commissions** — a per-person report of appointments, revenue, the commission you owe and what you keep, for any date range, with a CSV export. Set a percentage or a fixed rate per person; a service can override it when its margin is different. Figures come from the price saved with each booking, so raising a price next month never rewrites last month. Cancelled bookings and refunded charges are left out. It reports what is owed — Zoe never moves money.
* New (PRO): **Design presets** — a complete look in one click: colours, layout, skin, shape and spacing together. Nine to choose from — Zoe Classic, Nordic, Midnight, Blush, Atelier, Clinic, Terracotta, Mono and Botanical. Applying one only fills the Appearance fields, so nothing changes on your site until you press Save. You can also save your own design as a preset and carry it to another site. Every one of those settings stays free and fully editable by hand; "Neutral", which clears them all back to the defaults, is free too.
* New: **Minimum notice** — refuse bookings made too close to the appointment. Set it to two hours and nobody can take a slot that starts in ten minutes. Works across midnight, so a two-day notice correctly rules out tomorrow as well.
* New: **Booking window** — how far into the future the calendar opens. Thirty days keeps customers inside the next month; leave it at 0 for no limit.
* New: **Buffer before a service** — the gap you need in front of an appointment for setup, travel or preparing the room. Sits alongside the existing buffer after.
* New: **"Earliest available"** — one tap on the booking form jumps straight to the first free slot instead of making customers page through a calendar.
* New: **Spam protection** for the booking form — a decoy field no human ever sees, plus a cap on how many bookings one visitor can make per hour. The public form writes a row and sends mail on every submission, so this keeps a script out of your calendar and off your mail server. Logged-in users are never counted.
* Fixed: **"Buffer after" did not actually keep the gap free.** The buffer was saved with the booking but ignored when the next customer's slots were worked out, so a 15-minute clean-up break could be booked straight over. Buffers now hold in the customer calendar, in the manual "+ Add booking" screen and in every payment mode.
* Fixed: in WooCommerce mode the booking request was only checked for collisions, never against the schedule itself — a tampered request could place an appointment outside working hours or on a day off. It now goes through the same validation as the other two modes.

= 1.6.1 =
* Fixed: if a PRO licence lapses, pages holding the `[ms_events]` shortcode showed the raw text "[ms_events]" to visitors, because WordPress prints shortcodes it does not recognise. Those pages now simply leave the section out until the licence is active again.

= 1.6.0 =
* New: **Special days** — different hours on one particular date, for the weeks that refuse to repeat. A coach free on Tuesday this week and Saturday the next no longer needs a weekly grid that fits nobody: pick the date, set the hours, done. A special day also opens a day that is normally closed, and a day off always wins over it, so a holiday can never be reopened by accident.
* New (PRO): **My Calendar** in the Staff panel — the same month grid the owner uses, showing only that person's own appointments, with the day panel and quick status changes.
* Staff members set their own special days from their panel, without touching anything else on the site.

= 1.5.1 =
* Fixed (PRO): on sites running WooCommerce, a staff member logging in was redirected to the WooCommerce "My account" page and could never reach the Staff Panel — WooCommerce locks anyone without shop permissions out of the WordPress admin. Staff accounts are now allowed into their own panel (and nowhere else).
* Staff now land straight on their own bookings after signing in, instead of on the WordPress profile screen.
* The Staff Panel got a proper Zoe header that greets the team member by name, so it is always obvious whose bookings are on screen — and the view links (Upcoming / Past / All) no longer collide with the page title.
* Linking a WordPress account that already belonged to another staff profile now says so: one account runs one profile, and the previous link is reported as moved instead of disappearing quietly.

= 1.5.0 =
* New (PRO): Staff Panel — each team member gets their own limited wp-admin area. Create a WordPress account with the new "Zoe Staff" role, link it on the Staff edit screen, and that person sees only their own bookings (with quick status updates) plus their own weekly schedule and time off. No settings, no payments, nobody else's data.
* New: a "Regenerate link" button next to the private calendar-feed URL (on the Staff edit screen and in the Staff Panel) — one click invalidates the old .ics link when someone leaves the team.
* Hardening: staff save/delete now verify the record really is a staff member before writing.

= 1.4.1 =
* New (PRO): a fourth Events layout — "Banner" feature rows with a large date badge (rounded square, circle or minimal tile), the date · time · price line, a tickets-left pill and a pill-shaped Get tickets button with an arrow.
* New (PRO): an optional corner decoration image on Banner cards, fading in from the right edge — set one image for all cards, or let each event's photo take that role.
* The badge colours, size, decoration width and opacity are all adjustable in the Elementor widget's new Banner layout section; the `[ms_events]` shortcode accepts `layout="banner"`, `badge="circle"` and `ornament="<image url>"`.

= 1.4.0 =
* New: a service catalogue — `[ms_services]` (and a matching Elementor widget) shows your services as cards with photo, description, duration and price, in list, grid or large-card layouts, with optional category filters, search and sorting.
* New: each card's Book button opens the booking form with that service already selected — and when only one team member offers it, they are picked automatically, so the customer lands straight on the calendar.
* New: services now have a Short description field, shown on those cards.
* Services with duration variants advertise "from <lowest price>" instead of a base price the checkout would never charge.

= 1.3.0 =
* New (PRO): an event can now run on SEVERAL dates. A workshop series is one event with one description, image and price — add a date per session, and customers pick the date they want when they buy. Ticket capacity counts per date, so each session sells its own seats.
* New (PRO): "Duplicate" on the Events screen — copy an event with all its settings and just set the new dates.
* Existing single-date events keep working exactly as before; nothing to migrate.

= 1.2.3 =
* New: export the bookings list to CSV — one click exports exactly what your filters select (staff, service, date range, status, search), with prices, customer details and payment references, ready for Excel, Numbers, Google Sheets or your accountant.

= 1.2.2 =
* New: one-click "Install PRO now" — after activating a PRO license key, the PRO package downloads and installs itself (no more manual ZIP upload). A manual-upload fallback remains for sites where dashboard installs are disabled.
* New: buying PRO from the panel now brings you straight back to WordPress after checkout, with the license key activated automatically.
* Fixed: with an active license key but the PRO package not yet installed, the panel now shows the License page with clear next steps instead of the pricing page.

= 1.2.1 =
* The "Get support" button now opens your email client (hello@zoebooking.com) — quicker help, no separate ticket portal.

= 1.2.0 =
* The plugin no longer bundles any third-party SDK — a fully self-contained install. Licensing & checkout for the separate PRO version now run on Lemon Squeezy (nothing loads or phones home unless you open the Get PRO page or enter a license key).
* New License page (PRO): activate or deactivate your key, re-check its status and jump to the Lemon Squeezy customer portal to manage billing.

= 1.1.4 =
* New (PRO): show a single event (or a hand-picked set) — `[ms_events ids="123"]`, an event picker in the Elementor Events widget, and a copy-ready shortcode column on the Events screen.
* New (PRO): events are now clearly separated from appointments — All/Appointments/Events tabs and a per-event filter on the Bookings list, an "Event" badge on ticket rows, and the calendar collapses each event into a single chip with a sold/capacity counter plus grouped attendee lists in the day panel.

= 1.1.3 =
* New: full Dutch (Nederlands) translation — the plugin now ships in English, Dutch, French, German, Italian, Polish and Spanish.
* Pricing page starts on the Monthly cycle; small admin polish (no tier badge in the free version).

= 1.1.2 =
* Free version got bigger: service extras, group appointments, recurring series, per-staff calendar feeds (.ics), WhatsApp links and the customer panel are now fully included — and the staff limit is gone (unlimited team).
* Security: customer-panel, calendar and invoice access tokens are now signed with a plugin-generated secret instead of WordPress auth salts.
* Under the hood: every admin and front-end script/style now loads through the WordPress enqueue APIs.

= 1.1.1 =
* Fixed: bundled translations (de/fr/es/it/pl) were not loading — the form and admin stayed in English on non-English sites.
* Fixed: dropdown panels could render permanently open on block themes (e.g. Twenty Twenty-Five) that ship no `[hidden]` CSS reset.
* Fixed: theme styles no longer distort the form's line icons (global `svg { fill }` rules), underline the contact links or outline the collapse button.
* New: "Date & time box max height" option — in Settings → Appearance (desktop + mobile) and in the Elementor widget (responsive).
* Improved: service-picker categories stack vertically on small screens instead of a horizontal scroller.

= 1.1.0 =
* First public release on WordPress.org.
* Stability, performance and UI polish across the admin panel and booking form.
* Consistent 12/24-hour time and date formatting everywhere in the panel.
* Updated German, French, Spanish, Italian and Polish translations.

= 0.3.0 =
* Online payments: Stripe Checkout, PayPal and Square — hosted checkouts with server-side verification and automatic slot-conflict refunds.
* Events & tickets with an Elementor widget (list / grid / standard) and ticket sales through every booking mode.
* Customer panel with magic-link sign-in, self-service cancellations, invoices and GDPR data export/erasure.
* New form layouts (process timeline, progress bar, icon rail), design skins (outline, soft, dark, glass) and popup mode.
* Discount coupons, service extras, group appointments, recurring series, waiting list, multiple locations, invoices, per-staff calendar feeds, refunds, WhatsApp links, taxes, duration variants, QR add-to-calendar — all behind feature switches.
* Dashboard reports, currency & time-format settings, phone country picker, customer notes, mobile polish and a recolourable admin panel.

= 0.2.0 =
* Rebranded to Zoe Booking with a single, unified admin menu.
* Custom Services & Staff screens, visual month calendar, dual Standalone / WooCommerce mode.

= 0.1.0 =
* Initial booking engine, WooCommerce product-type integration, Elementor widget.

== Upgrade Notice ==

= 1.1.0 =
First public release. Database upgrades run automatically on the first admin visit.

= 0.3.0 =
Major feature release. Database upgrades run automatically on the first admin visit.
