/* EzBizz Appointment Booking — front-end styles.
 * Theme authors: override the custom properties on .ezb to match the site. */
.ezb {
	--ezb-ink: #14213d;
	--ezb-muted: #5b6577;
	--ezb-line: #dfe4ec;
	--ezb-bg: #ffffff;
	--ezb-soft: #f4f7fb;
	--ezb-brand: #0f2a4a;
	--ezb-accent: #0b8a7a;
	--ezb-accent-ink: #ffffff;
	--ezb-error: #b42318;
	--ezb-warn: #a15c07;
	--ezb-radius: 12px;
	--ezb-font: inherit;
	box-sizing: border-box;
	max-width: 1100px;
	width: 100%;
	margin: 0 auto;
	padding: clamp(16px, 3vw, 32px);
	background: var(--ezb-bg);
	border: 1px solid var(--ezb-line);
	border-radius: calc(var(--ezb-radius) + 4px);
	box-shadow: 0 8px 30px rgba(15, 42, 74, 0.06);
	color: var(--ezb-ink);
	font-family: var(--ezb-font);
	font-size: 16px;
	line-height: 1.5;
}

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

.ezb [hidden] {
	display: none !important;
}

.ezb-h {
	margin: 0 0 6px;
	font-size: 1.35rem;
	line-height: 1.3;
	color: var(--ezb-brand);
	outline: none;
}

.ezb-muted {
	color: var(--ezb-muted);
	margin: 0 0 16px;
	font-size: 0.95rem;
}

/* Progress */
.ezb-steps {
	display: flex;
	gap: 8px;
	list-style: none;
	margin: 0 0 24px;
	padding: 0;
	counter-reset: none;
}

.ezb-steps li {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 10px 12px;
	border-radius: 10px;
	background: var(--ezb-soft);
	color: var(--ezb-muted);
	font-size: 0.85rem;
	font-weight: 600;
	margin: 0;
}

.ezb-steps li span {
	display: inline-grid;
	place-items: center;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: #fff;
	border: 1px solid var(--ezb-line);
	font-size: 0.78rem;
	flex: none;
}

.ezb-steps li.is-active {
	background: var(--ezb-brand);
	color: #fff;
}

.ezb-steps li.is-active span {
	background: var(--ezb-accent);
	border-color: var(--ezb-accent);
	color: #fff;
}

.ezb-steps li.is-done {
	color: var(--ezb-brand);
}

.ezb-steps li.is-done span {
	background: var(--ezb-accent);
	border-color: var(--ezb-accent);
	color: #fff;
}

/* Alerts */
.ezb-alert {
	padding: 12px 14px;
	border-radius: 10px;
	margin: 0 0 16px;
	font-size: 0.95rem;
	border: 1px solid;
}

.ezb-alert--error {
	background: #fef3f2;
	border-color: #fecdca;
	color: var(--ezb-error);
}

.ezb-alert--warning {
	background: #fffaeb;
	border-color: #fedf89;
	color: var(--ezb-warn);
}

.ezb-alert--info {
	background: #eff8ff;
	border-color: #b2ddff;
	color: #175cd3;
}

/* Service cards */
.ezb-services {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
	gap: 14px;
	margin-top: 16px;
}

.ezb-card {
	all: unset;
	box-sizing: border-box;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 18px;
	border: 1.5px solid var(--ezb-line);
	border-radius: var(--ezb-radius);
	background: #fff;
	transition: border-color .15s, box-shadow .15s, transform .15s;
}

.ezb-card:hover {
	border-color: var(--ezb-accent);
	box-shadow: 0 6px 18px rgba(11, 138, 122, 0.12);
	transform: translateY(-1px);
}

.ezb-card:focus-visible {
	outline: 3px solid rgba(11, 138, 122, .35);
	outline-offset: 2px;
}

.ezb-card.is-selected {
	border-color: var(--ezb-accent);
	background: #f0fbf9;
}

.ezb-card__name {
	font-weight: 700;
	font-size: 1.05rem;
	color: var(--ezb-brand);
}

.ezb-card__desc {
	color: var(--ezb-muted);
	font-size: 0.92rem;
}

.ezb-card__meta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: auto;
	padding-top: 6px;
}

.ezb-card__price {
	font-weight: 700;
	color: var(--ezb-ink);
}

.ezb-pill {
	font-size: 0.8rem;
	padding: 3px 10px;
	border-radius: 999px;
	background: var(--ezb-soft);
	color: var(--ezb-muted);
	font-weight: 600;
}

/* Date & time */
.ezb-dt {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
	gap: 24px;
}

.ezb-cal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 10px;
}

.ezb-cal__title {
	font-size: 1rem;
}

.ezb-iconbtn {
	all: unset;
	cursor: pointer;
	width: 36px;
	height: 36px;
	display: grid;
	place-items: center;
	border-radius: 8px;
	border: 1px solid var(--ezb-line);
	font-size: 1.3rem;
	line-height: 1;
}

.ezb-iconbtn:hover:not(:disabled) {
	background: var(--ezb-soft);
}

.ezb-iconbtn:disabled {
	opacity: .35;
	cursor: default;
}

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

.ezb-cal__dow {
	text-align: center;
	font-size: 0.75rem;
	font-weight: 700;
	color: var(--ezb-muted);
	padding: 4px 0;
	text-transform: uppercase;
	letter-spacing: .03em;
}

.ezb-cal__day {
	all: unset;
	box-sizing: border-box;
	aspect-ratio: 1;
	display: grid;
	place-items: center;
	border-radius: 8px;
	font-size: 0.92rem;
	color: #b3bac6;
	cursor: default;
}

.ezb-cal__day.is-available {
	color: var(--ezb-ink);
	font-weight: 600;
	background: var(--ezb-soft);
	cursor: pointer;
}

.ezb-cal__day.is-available:hover {
	background: #e3f4f1;
}

.ezb-cal__day.is-selected {
	background: var(--ezb-accent) !important;
	color: #fff;
}

.ezb-cal__day:focus-visible,
.ezb-slot:focus-visible {
	outline: 3px solid rgba(11, 138, 122, .35);
	outline-offset: 1px;
}

.is-loading {
	opacity: .5;
	pointer-events: none;
	position: relative;
}

.is-loading::after {
	content: "";
	position: absolute;
	inset: 50% auto auto 50%;
	width: 22px;
	height: 22px;
	margin: -11px;
	border: 3px solid var(--ezb-line);
	border-top-color: var(--ezb-accent);
	border-radius: 50%;
	animation: ezb-spin .8s linear infinite;
}

@keyframes ezb-spin {
	to {
		transform: rotate(360deg);
	}
}

.ezb-slots__title {
	font-weight: 600;
	color: var(--ezb-ink);
}

.ezb-slots__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
	gap: 8px;
	min-height: 60px;
}

.ezb-slot {
	all: unset;
	box-sizing: border-box;
	cursor: pointer;
	text-align: center;
	padding: 10px 6px;
	border: 1.5px solid var(--ezb-line);
	border-radius: 8px;
	font-weight: 600;
	font-size: 0.92rem;
}

.ezb-slot:hover {
	border-color: var(--ezb-accent);
}

.ezb-slot.is-selected {
	background: var(--ezb-accent);
	border-color: var(--ezb-accent);
	color: #fff;
}

/* Form */
.ezb-form {
	margin-top: 12px;
}

.ezb-grid2 {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0 16px;
}

.ezb-field {
	margin: 0 0 14px;
	border: 0;
	padding: 0;
	min-width: 0;
}

.ezb-field label,
.ezb-field legend {
	display: block;
	font-weight: 600;
	font-size: 0.9rem;
	margin-bottom: 6px;
	padding: 0;
}

.ezb-field input[type="text"],
.ezb-field input[type="email"],
.ezb-field input[type="tel"],
.ezb-field input[type="number"],
.ezb-field textarea {
	width: 100%;
	padding: 11px 12px;
	border: 1.5px solid var(--ezb-line);
	border-radius: 8px;
	font: inherit;
	color: inherit;
	background: #fff;
	margin: 0;
}

.ezb-field input[type="number"] {
	max-width: 140px;
}

.ezb-field input:focus,
.ezb-field textarea:focus {
	outline: none;
	border-color: var(--ezb-accent);
	box-shadow: 0 0 0 3px rgba(11, 138, 122, .15);
}

.ezb-invalid {
	border-color: var(--ezb-error) !important;
}

.ezb-err {
	color: var(--ezb-error);
	font-size: 0.85rem;
	margin: 4px 0 0;
	min-height: 0;
}

.ezb-err:empty {
	display: none;
}

.ezb-methods {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ezb-radio {
	display: inline-flex !important;
	align-items: center;
	gap: 8px;
	padding: 10px 14px;
	border: 1.5px solid var(--ezb-line);
	border-radius: 8px;
	cursor: pointer;
	font-weight: 600 !important;
	margin: 0 !important;
}

.ezb-radio:has(input:checked) {
	border-color: var(--ezb-accent);
	background: #f0fbf9;
}

.ezb-radio input {
	margin: 0;
	accent-color: var(--ezb-accent);
}

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

.ezb-req {
	color: var(--ezb-error);
}

.ezb-check {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	margin: 16px 0 4px;
	font-size: 0.95rem;
	cursor: pointer;
}

.ezb-check input {
	margin-top: 4px;
	accent-color: var(--ezb-accent);
	width: 18px;
	height: 18px;
	flex: none;
}

/* Summary */
.ezb-summary {
	display: grid;
	grid-template-columns: max-content 1fr;
	gap: 0;
	margin: 16px 0;
	border: 1px solid var(--ezb-line);
	border-radius: var(--ezb-radius);
	overflow: hidden;
}

.ezb-summary dt,
.ezb-summary dd {
	margin: 0;
	padding: 10px 14px;
	border-bottom: 1px solid var(--ezb-line);
}

.ezb-summary dt {
	background: var(--ezb-soft);
	font-weight: 600;
	color: var(--ezb-muted);
	font-size: 0.9rem;
}

.ezb-summary dt:last-of-type,
.ezb-summary dd:last-of-type {
	border-bottom: 0;
}

.ezb-panel[data-step="review"] .ezb-summary dd:last-of-type {
	font-weight: 800;
	font-size: 1.1rem;
	color: var(--ezb-brand);
}

.ezb-secure {
	font-size: 0.88rem;
	margin-top: 12px;
}

/* Buttons */
.ezb-actions {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-top: 24px;
	flex-wrap: wrap;
}

.ezb-actions--center {
	justify-content: center;
}

.ezb-btn {
	all: unset;
	box-sizing: border-box;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 22px;
	border-radius: 10px;
	background: var(--ezb-accent);
	color: var(--ezb-accent-ink);
	font-weight: 700;
	font-size: 0.98rem;
	text-align: center;
	transition: filter .15s, opacity .15s;
}

.ezb-btn:hover:not(:disabled) {
	filter: brightness(1.08);
}

.ezb-btn:focus-visible {
	outline: 3px solid rgba(11, 138, 122, .35);
	outline-offset: 2px;
}

.ezb-btn:disabled {
	opacity: .45;
	cursor: not-allowed;
}

.ezb-btn--ghost {
	background: transparent;
	color: var(--ezb-brand);
	border: 1.5px solid var(--ezb-line);
}

.ezb-btn--pay {
	background: var(--ezb-brand);
	min-width: 240px;
}

.ezb-btn.is-busy {
	opacity: .75;
	cursor: progress;
}

/* Status */
.ezb-status {
	text-align: center;
	padding: 8px 0;
}

.ezb-status .ezb-summary {
	text-align: left;
	max-width: 560px;
	margin: 20px auto;
}

.ezb-status__icon {
	width: 64px;
	height: 64px;
	margin: 0 auto 14px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	font-size: 2rem;
	font-weight: 800;
	color: #fff;
}

.ezb-status__icon.is-ok {
	background: #12a150;
}

.ezb-status__icon.is-warn {
	background: #dc8a0b;
}

.ezb-status__icon.is-error {
	background: var(--ezb-error);
}

.ezb-status__icon.is-wait {
	border: 5px solid var(--ezb-line);
	border-top-color: var(--ezb-accent);
	animation: ezb-spin 1s linear infinite;
}

.ezb-status__text {
	color: var(--ezb-muted);
	max-width: 520px;
	margin: 0 auto;
}

/* Responsive */
@media (max-width: 760px) {
	.ezb-dt {
		grid-template-columns: minmax(0, 1fr);
	}

	/* V2: stop the calendar overflowing narrow phones */
	.ezb-steps li {
		font-size: 0;
		padding: 8px;
		justify-content: center;
	}

	.ezb-steps li span {
		font-size: 0.8rem;
	}

	.ezb-steps li.is-active {
		font-size: 0.8rem;
		flex: 2.4;
	}
}

@media (max-width: 520px) {
	.ezb {
		border-radius: 10px;
		padding: 16px;
	}

	.ezb-grid2 {
		grid-template-columns: 1fr;
	}

	.ezb-summary {
		grid-template-columns: 1fr;
	}

	.ezb-summary dt {
		border-bottom: 0;
		padding-bottom: 2px;
	}

	.ezb-actions .ezb-btn {
		flex: 1 1 100%;
	}

	.ezb-actions {
		flex-direction: column-reverse;
	}

	.ezb-btn--pay {
		min-width: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ezb * {
		animation: none !important;
		transition: none !important;
	}
}

/* EzBizz V2 service card styles — single, consistent override */
.ezb .ezb-services {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 16px;
}

.ezb .ezb-services > button.ezb-card {
    all: unset;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    width: 100%;
    min-width: 0;
    min-height: 185px;
    padding: 18px;
    border: 1.5px solid var(--ezb-line, #dfe4ec);
    border-radius: var(--ezb-radius, 12px);
    background: #ffffff;
    color: var(--ezb-ink, #14213d);
    box-shadow: 0 4px 14px rgba(15, 42, 74, 0.06);
    font-family: inherit;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: normal;
    text-align: left;
    text-decoration: none;
    text-transform: none;
    white-space: normal;
    cursor: pointer;
    transition: background-color .15s ease, border-color .15s ease,
                box-shadow .15s ease, transform .15s ease;
}

.ezb .ezb-services > button.ezb-card:hover {
    background: #f0fbf9;
    border-color: var(--ezb-accent, #0b8a7a);
    color: var(--ezb-ink, #14213d);
    box-shadow: 0 6px 18px rgba(11, 138, 122, 0.12);
    transform: translateY(-1px);
}

.ezb .ezb-services > button.ezb-card:focus-visible {
    outline: 3px solid rgba(11, 138, 122, .35);
    outline-offset: 2px;
}

.ezb .ezb-services > button.ezb-card[aria-checked="true"],
.ezb .ezb-services > button.ezb-card.is-selected {
    background: #f0fbf9;
    border: 2px solid var(--ezb-accent, #0b8a7a);
    color: var(--ezb-ink, #14213d);
    box-shadow: 0 4px 14px rgba(11, 138, 122, .12);
}

.ezb .ezb-services > button.ezb-card .ezb-card__name {
    display: block;
    margin: 0;
    padding: 0;
    color: var(--ezb-brand, #0f2a4a);
    font-family: inherit;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: normal;
    text-align: left;
    text-transform: none;
    overflow-wrap: anywhere;
}

.ezb .ezb-services > button.ezb-card .ezb-card__desc {
    display: block;
    margin: 0;
    padding: 0;
    color: var(--ezb-muted, #5b6577);
    font-size: .92rem;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: normal;
    text-align: left;
    text-transform: none;
    overflow-wrap: anywhere;
}

.ezb .ezb-services > button.ezb-card .ezb-card__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    margin-top: auto;
    padding-top: 6px;
}

.ezb .ezb-services > button.ezb-card .ezb-card__price {
    color: var(--ezb-ink, #14213d);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: normal;
    text-transform: none;
    overflow-wrap: anywhere;
}

.ezb .ezb-services > button.ezb-card .ezb-pill {
    display: inline-block;
    max-width: 100%;
    padding: 3px 10px;
    border: 0;
    border-radius: 999px;
    background: var(--ezb-soft, #f4f7fb);
    color: var(--ezb-muted, #5b6577);
    font-size: .8rem;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: normal;
    text-align: left;
    text-transform: none;
    white-space: normal;
    overflow-wrap: anywhere;
}

@media (max-width: 900px) {
    .ezb .ezb-services {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .ezb .ezb-services {
        grid-template-columns: 1fr;
    }

    .ezb .ezb-services > button.ezb-card {
        min-height: 0;
    }
}