/* LivieG Booking — front end. Uses the Kadence global palette when present. */

.lgb-app {
	--lgb-accent: var(--global-palette1, #0f766e);
	--lgb-accent-2: var(--global-palette2, #115e59);
	--lgb-text: var(--global-palette3, #1f2937);
	--lgb-muted: var(--global-palette5, #6b7280);
	--lgb-line: var(--global-palette7, #e5e7eb);
	--lgb-soft: var(--global-palette8, #f3f4f6);
	--lgb-bg: var(--global-palette9, #ffffff);
	--lgb-danger: #b91c1c;
	--lgb-radius: 14px;
	--lgb-focus: 0 0 0 3px var(--lgb-bg), 0 0 0 6px var(--lgb-accent);
	max-width: 720px;
	margin: 0 auto;
	color: var(--lgb-text);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: 16px;
	line-height: 1.5;
	box-sizing: border-box;
}

.lgb-app *,
.lgb-app *::before,
.lgb-app *::after {
	box-sizing: inherit;
}

.lgb-app [hidden] {
	display: none !important;
}

/* "Did not load" message: hidden at first, shown after 6 s by CSS alone. booking.js removes it as
   soon as it runs, so people only ever see it when the script is blocked or failed to load. */
.lgb-app .lgb-fallback {
	visibility: hidden;
	max-height: 0;
	overflow: hidden;
	margin-top: 0;
	margin-bottom: 0;
	padding-top: 0;
	padding-bottom: 0;
	border-width: 0;
	animation: lgb-fallback 0s linear 6s forwards;
}

@keyframes lgb-fallback {
	to { visibility: visible; max-height: 20em; margin-bottom: 1rem; padding-top: 12px; padding-bottom: 12px; border-width: 1px; }
}

.lgb-contact {
	color: var(--lgb-text);
}

.lgb-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	margin: -1px;
	padding: 0;
	border: 0;
}

.lgb-app button,
.lgb-app input,
.lgb-app textarea {
	font: inherit;
	color: inherit;
}

.lgb-app :focus-visible {
	outline: none;
	box-shadow: var(--lgb-focus);
}

.lgb-h {
	font-size: 1.35rem;
	line-height: 1.25;
	margin: 0;
	outline: none;
}

.lgb-h3 {
	font-size: 1.05rem;
	margin: 1.5rem 0 .5rem;
}

.lgb-muted,
.lgb-tz,
.lgb-small {
	color: var(--lgb-muted);
	font-size: .9rem;
}

/* ---- Progress strip ---------------------------------------------- */

.lgb-progress {
	display: flex;
	gap: 4px;
	list-style: none;
	margin: 0 0 1.25rem;
	padding: 0;
	counter-reset: none;
}

.lgb-progress__item {
	flex: 1 1 0;
	min-width: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	margin: 0;
	padding: 0 0 8px;
	border-bottom: 4px solid var(--lgb-line);
	color: var(--lgb-muted);
	font-size: .75rem;
	text-align: center;
}

.lgb-progress__num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: var(--lgb-soft);
	font-weight: 700;
	font-size: .8rem;
}

.lgb-progress__label {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 100%;
}

.lgb-progress__item.is-done {
	border-color: var(--lgb-accent);
	color: var(--lgb-text);
}

.lgb-progress__item.is-done .lgb-progress__num,
.lgb-progress__item.is-current .lgb-progress__num {
	background: var(--lgb-accent);
	color: #fff;
}

.lgb-progress__item.is-current {
	border-color: var(--lgb-accent);
	color: var(--lgb-text);
	font-weight: 700;
}

/* ---- Steps -------------------------------------------------------- */

.lgb-step {
	animation: lgb-in .2s ease-out;
}

@keyframes lgb-in {
	from { opacity: 0; transform: translateY(6px); }
	to { opacity: 1; transform: none; }
}

.lgb-step__head {
	display: flex;
	align-items: baseline;
	gap: 12px;
	flex-wrap: wrap;
	margin-bottom: .25rem;
}

.lgb-step__head .lgb-h,
.lgb-step__head h2,
.lgb-step__head h3 {
	margin: 0;
}

.lgb-step > .lgb-h {
	margin-bottom: 1rem;
}

.lgb-chosen {
	margin: .25rem 0 1rem;
	color: var(--lgb-muted);
	font-size: .95rem;
	min-height: 1.4em;
}

.lgb-back {
	min-height: 44px;
	padding: 8px 14px;
	border: 1px solid var(--lgb-line);
	border-radius: 999px;
	background: var(--lgb-bg);
	cursor: pointer;
	font-size: .9rem;
}

.lgb-back:hover {
	border-color: var(--lgb-accent);
	color: var(--lgb-accent);
}

/* ---- Lesson cards ------------------------------------------------- */

.lgb-cards {
	display: grid;
	gap: 12px;
	grid-template-columns: 1fr;
}

@media (min-width: 560px) {
	.lgb-cards {
		grid-template-columns: repeat(2, 1fr);
	}
}

.lgb-card {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 4px;
	width: 100%;
	min-height: 96px;
	padding: 18px 20px;
	border: 2px solid var(--lgb-line);
	border-radius: var(--lgb-radius);
	background: var(--lgb-bg);
	text-align: left;
	cursor: pointer;
	transition: border-color .15s, box-shadow .15s, transform .15s;
}

.lgb-card:hover {
	border-color: var(--lgb-accent);
	box-shadow: 0 6px 18px rgba(0, 0, 0, .06);
	transform: translateY(-1px);
}

.lgb-card[aria-pressed="true"] {
	border-color: var(--lgb-accent);
	background: #ecfdf5;
	background: color-mix(in srgb, var(--lgb-accent) 6%, var(--lgb-bg));
}

.lgb-card__title {
	font-weight: 700;
	font-size: 1.1rem;
}

.lgb-card__meta {
	color: var(--lgb-muted);
	font-size: .9rem;
}

.lgb-card__price {
	margin-top: 6px;
	font-weight: 700;
	color: var(--lgb-accent);
}

/* ---- Calendar ----------------------------------------------------- */

.lgb-cal {
	border: 1px solid var(--lgb-line);
	border-radius: var(--lgb-radius);
	padding: 12px;
	background: var(--lgb-bg);
}

.lgb-cal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	margin-bottom: 8px;
}

.lgb-cal__title {
	margin: 0;
	font-size: 1.05rem;
}

.lgb-cal__nav {
	width: 44px;
	height: 44px;
	border: 1px solid var(--lgb-line);
	border-radius: 50%;
	background: var(--lgb-bg);
	font-size: 1.4rem;
	line-height: 1;
	cursor: pointer;
}

.lgb-cal__nav:disabled {
	opacity: .35;
	cursor: default;
}

.lgb-cal__grid {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 4px;
}

.lgb-cal__wd {
	text-align: center;
	font-size: .75rem;
	color: var(--lgb-muted);
	padding: 4px 0;
	text-transform: uppercase;
	letter-spacing: .03em;
}

.lgb-cal__day {
	aspect-ratio: 1 / 1;
	min-height: 44px; /* touch target */
	width: 100%;
	margin: 0;
	padding: 0; /* theme button padding otherwise wraps "10" onto two lines on phones */
	display: flex;
	align-items: center;
	justify-content: center;
	white-space: nowrap;
	overflow: hidden;
	line-height: 1;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: var(--lgb-muted);
	opacity: .45;
	font-size: .95rem;
	cursor: default;
}

.lgb-cal__day.is-open {
	opacity: 1;
	color: var(--lgb-accent-2);
	background: #ecfdf5;
	background: color-mix(in srgb, var(--lgb-accent) 12%, var(--lgb-bg));
	font-weight: 700;
	cursor: pointer;
}

.lgb-cal__day.is-open:hover,
.lgb-cal__day.is-selected {
	background: var(--lgb-accent);
	color: #fff;
}

/* ---- Slots -------------------------------------------------------- */

.lgb-slotgroup {
	margin-bottom: 1rem;
}

.lgb-slotgroup__h {
	margin: 0 0 .5rem;
	font-size: .85rem;
	text-transform: uppercase;
	letter-spacing: .05em;
	color: var(--lgb-muted);
}

.lgb-slotgrid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
	gap: 8px;
}

.lgb-slot {
	min-height: 48px;
	padding: 10px 8px;
	border: 2px solid var(--lgb-accent);
	border-radius: 10px;
	background: var(--lgb-bg);
	color: var(--lgb-accent-2);
	font-weight: 700;
	cursor: pointer;
	transition: background .15s, color .15s;
}

.lgb-slot:hover,
.lgb-slot.is-selected {
	background: var(--lgb-accent);
	color: #fff;
}

/* ---- Form --------------------------------------------------------- */

.lgb-form {
	display: grid;
	gap: 14px;
}

.lgb-field {
	margin: 0;
	padding: 0;
	border: 0;
	min-width: 0;
}

.lgb-field > label,
.lgb-field > legend,
.lgb-label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
	padding: 0;
}

.lgb-req {
	color: var(--lgb-danger);
}

.lgb-hint {
	font-weight: 400;
	color: var(--lgb-muted);
	font-size: .9rem;
}

.lgb-form input[type="text"],
.lgb-form input[type="email"],
.lgb-form input[type="tel"],
.lgb-form input[type="number"],
.lgb-form textarea {
	display: block;
	width: 100%;
	min-height: 48px;
	padding: 10px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 10px;
	background: var(--lgb-bg);
	font-size: 16px; /* prevents iOS zoom */
}

.lgb-form textarea {
	min-height: 88px;
	resize: vertical;
}

.lgb-form input.lgb-age {
	max-width: 8rem;
}

/* "Where?" above the calendar (only when some place is offered on certain days only). */
.lgb-where-first {
	margin: 0 0 1rem;
	padding: 0;
	border: 0;
	min-width: 0;
}

.lgb-where-first > legend {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
	padding: 0;
}

.lgb-form input:focus-visible,
.lgb-form textarea:focus-visible {
	border-color: var(--lgb-accent);
}

.lgb-form [aria-invalid="true"] {
	border-color: var(--lgb-danger) !important;
}

.lgb-pills,
.lgb-options {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.lgb-options {
	flex-direction: column;
}

.lgb-pill,
.lgb-option {
	position: relative;
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 48px;
	padding: 10px 16px;
	border: 2px solid var(--lgb-line);
	border-radius: 12px;
	background: var(--lgb-bg);
	cursor: pointer;
	font-weight: 500;
}

.lgb-pill {
	flex: 1 1 120px;
	justify-content: center;
}

.lgb-pill input,
.lgb-option input {
	width: 20px;
	height: 20px;
	margin: 0;
	accent-color: var(--lgb-accent);
	flex: 0 0 auto;
}

.lgb-pill:has(input:checked),
.lgb-option:has(input:checked) {
	border-color: var(--lgb-accent);
	background: #ecfdf5;
	background: color-mix(in srgb, var(--lgb-accent) 6%, var(--lgb-bg));
}

.lgb-pill:has(input:focus-visible),
.lgb-option:has(input:focus-visible) {
	box-shadow: var(--lgb-focus);
}

/* Optional tick boxes above the notes: same cards as the location options, lighter text. */
.lgb-app .lgb-extras .lgb-option {
	font-weight: 400;
}

.lgb-fixed {
	margin: 0;
	padding: 10px 14px;
	background: var(--lgb-soft);
	border-radius: 10px;
}

.lgb-hp {
	position: absolute !important;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.lgb-field-error,
.lgb-error {
	color: var(--lgb-danger);
	font-size: .9rem;
	margin: 6px 0 0;
}

.lgb-error[role="alert"]:not(:empty) {
	padding: 10px 12px;
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 10px;
}

/* ---- Buttons ------------------------------------------------------ */

.lgb-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 52px;
	padding: 12px 22px;
	border: 2px solid var(--lgb-accent);
	border-radius: 12px;
	background: var(--lgb-bg);
	color: var(--lgb-accent);
	font-weight: 700;
	font-size: 1rem;
	cursor: pointer;
	text-decoration: none;
}

.lgb-btn--primary {
	width: 100%;
	background: var(--lgb-accent);
	color: #fff;
	font-size: 1.05rem;
}

.lgb-btn--primary:hover {
	background: var(--lgb-accent-2);
	border-color: var(--lgb-accent-2);
}

.lgb-btn--danger {
	border-color: var(--lgb-danger);
	color: var(--lgb-danger);
	margin-top: .5rem;
}

.lgb-btn--danger:hover {
	background: var(--lgb-danger);
	color: #fff;
}

.lgb-btn--small {
	min-height: 44px;
	padding: 6px 12px;
	font-size: .85rem;
	border-color: var(--lgb-danger);
	color: var(--lgb-danger);
}

.lgb-btn:disabled {
	opacity: .6;
	cursor: wait;
}

.lgb-link {
	color: var(--lgb-accent);
	font-weight: 600;
}

/* The reset above (.lgb-app button { font: inherit; color: inherit }) outranks single-class rules, so the
   button colours and weights were being lost: the primary button's text came out in the body colour on
   the accent background (about 2.6:1 with the default palette, ink on ink with the live site's).
   Same values as above, with enough weight to apply. */
.lgb-app .lgb-btn {
	color: var(--lgb-accent);
	font-weight: 700;
	font-size: 1rem;
}

.lgb-app .lgb-btn--primary {
	color: #fff;
	font-size: 1.05rem;
}

.lgb-app .lgb-btn--danger,
.lgb-app .lgb-btn--small {
	color: var(--lgb-danger);
}

.lgb-app .lgb-btn--small {
	font-size: .85rem;
}

.lgb-app .lgb-btn--danger:hover {
	color: #fff;
}

.lgb-app .lgb-slot {
	color: var(--lgb-accent-2);
	font-weight: 700;
}

.lgb-app .lgb-slot:hover,
.lgb-app .lgb-slot.is-selected {
	color: #fff;
}

.lgb-app .lgb-back {
	font-size: .9rem;
}

.lgb-app .lgb-back:hover {
	color: var(--lgb-accent);
}

/* ---- Done / manage ------------------------------------------------ */

.lgb-done {
	text-align: center;
}

.lgb-done__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 64px;
	height: 64px;
	margin-bottom: .75rem;
	border-radius: 50%;
	background: var(--lgb-accent);
	color: #fff;
	font-size: 2rem;
	font-weight: 700;
}

.lgb-summary {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 8px 16px;
	margin: 1.25rem auto;
	padding: 16px;
	max-width: 480px;
	text-align: left;
	background: var(--lgb-soft);
	border-radius: var(--lgb-radius);
}

.lgb-summary dt {
	color: var(--lgb-muted);
	margin: 0;
}

.lgb-summary dd {
	margin: 0;
	font-weight: 600;
	word-break: break-word;
}

.lgb-manage .lgb-summary {
	margin-left: 0;
}

.lgb-note,
.lgb-notice {
	margin: 1rem auto;
	max-width: 480px;
	padding: 12px 16px;
	border-radius: 12px;
	background: #ecfdf5;
	background: color-mix(in srgb, var(--lgb-accent) 8%, var(--lgb-bg));
	border: 1px solid #a7f3d0;
	border: 1px solid color-mix(in srgb, var(--lgb-accent) 30%, var(--lgb-bg));
	text-align: left;
}

.lgb-note p {
	margin: 0 0 .5em;
}

.lgb-note p:last-child {
	margin: 0;
}

.lgb-status {
	display: inline-block;
	margin: .75rem 0 0;
	padding: 4px 12px;
	border-radius: 999px;
	font-weight: 700;
	font-size: .9rem;
	background: var(--lgb-soft);
}

.lgb-status--approved {
	background: #dcfce7;
	color: #166534;
}

.lgb-status--pending {
	background: #fef9c3;
	color: #854d0e;
}

.lgb-status--declined,
.lgb-status--cancelled {
	background: #fee2e2;
	color: #991b1b;
}

.lgb-success {
	padding: 10px 12px;
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	border-radius: 10px;
	color: #166534;
}

.lgb-series {
	list-style: none;
	margin: 0;
	padding: 0;
}

.lgb-series li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	padding: 10px 0;
	border-bottom: 1px solid var(--lgb-line);
}

/* ---- Small screens ------------------------------------------------ */

@media (max-width: 400px) {
	.lgb-progress__label {
		font-size: .68rem;
	}

	/* Phones: the calendar uses the full width and the days touch, so each day stays a 44 px target
	   even inside the live site's framed box (7 x 44 = 308 px). An inset ring keeps them apart visually. */
	.lgb-cal {
		padding: 4px 0;
		border: 0;
	}

	.lgb-cal__grid {
		gap: 0;
	}

	.lgb-cal__day {
		box-shadow: inset 0 0 0 2px var(--lgb-bg);
	}

	.lgb-cal__day:focus-visible {
		box-shadow: inset 0 0 0 3px var(--lgb-accent);
	}

	.lgb-card {
		padding: 16px;
	}
}

/* ---- Reduced motion ----------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
	.lgb-app *,
	.lgb-app *::before,
	.lgb-app *::after {
		animation: none !important;
		transition: none !important;
		scroll-behavior: auto !important;
	}

	.lgb-card:hover {
		transform: none;
	}

	/* Not motion: a timer that reveals the "did not load" message. Keep it. */
	.lgb-app .lgb-fallback {
		animation: lgb-fallback 0s linear 6s forwards !important;
	}
}
