/**
 * Reservations — front end booking form.
 *
 * Scoped to .rsv and driven by custom properties, so a theme can restyle it
 * by overriding the variables rather than fighting selectors.
 */

.rsv {
	box-sizing: border-box;
	font-family: var(--rsv-font, inherit);
	color: var(--rsv-ink);
	font-size: 16px;
	line-height: 1.6;
	max-width: 100%;
}

.rsv *,
.rsv *::before,
.rsv *::after {
	box-sizing: border-box;
}

.rsv-sr {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

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

/* ---------- heading ---------- */
.rsv-head {
	margin-bottom: 22px;
	text-align: center;
}

.rsv-title {
	margin: 0;
	font-size: clamp(22px, 2.6vw, 28px);
	font-weight: 600;
	letter-spacing: -.015em;
	line-height: 1.2;
}

.rsv-intro {
	margin: 8px auto 0;
	max-width: 60ch;
	color: var(--rsv-muted);
	font-size: 15px;
}

/* ---------- step rail ---------- */
.rsv-steps {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0 0 26px;
	padding: 0;
	list-style: none;
	counter-reset: rsv;
}

.rsv-steps-item {
	display: flex;
	flex: 1 1 190px;
	align-items: center;
	gap: 10px;
	padding: 11px 14px;
	border: 1px solid var(--rsv-line);
	border-radius: var(--rsv-radius);
	background: var(--rsv-paper);
	color: var(--rsv-muted);
	font-size: 13.5px;
	font-weight: 500;
	line-height: 1.3;
	transition: border-color .25s var(--rsv-ease), color .25s var(--rsv-ease), background .25s var(--rsv-ease);
}

.rsv-steps-num {
	display: grid;
	flex: 0 0 auto;
	width: 24px;
	height: 24px;
	place-items: center;
	border-radius: 50%;
	background: rgba(30, 27, 26, .08);
	color: var(--rsv-ink-soft);
	font-size: 12.5px;
	font-weight: 700;
	transition: background .25s var(--rsv-ease), color .25s var(--rsv-ease);
}

.rsv-steps-item.is-current {
	border-color: var(--rsv-brand);
	background: rgba(184, 32, 37, .05);
	color: var(--rsv-ink);
}

.rsv-steps-item.is-current .rsv-steps-num {
	background: var(--rsv-brand);
	color: #fff;
}

.rsv-steps-item.is-done {
	border-color: rgba(47, 122, 79, .45);
	color: var(--rsv-ink-soft);
}

.rsv-steps-item.is-done .rsv-steps-num {
	background: var(--rsv-green);
	color: #fff;
}

/* ---------- steps ---------- */
.rsv-step {
	animation: rsv-in .34s var(--rsv-ease) both;
}

@keyframes rsv-in {
	from {
		opacity: 0;
		transform: translateY(8px);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

.rsv-step-count {
	margin: 0 0 6px;
	color: var(--rsv-brand);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: .18em;
	text-transform: uppercase;
}

.rsv-step-title {
	margin: 0;
	font-size: clamp(19px, 2.2vw, 23px);
	font-weight: 600;
	letter-spacing: -.012em;
	line-height: 1.25;
}

.rsv-step-blurb {
	margin: 6px 0 20px;
	color: var(--rsv-muted);
	font-size: 14.5px;
}

/* ---------- fields ---------- */
.rsv-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
	gap: 18px;
}

.rsv-field.is-wide {
	grid-column: 1 / -1;
}

.rsv-label {
	display: block;
	margin-bottom: 6px;
	font-size: 13.5px;
	font-weight: 600;
	color: var(--rsv-ink-soft);
}

.rsv-req {
	color: var(--rsv-brand);
}

.rsv-input {
	width: 100%;
	min-height: 48px;
	padding: 11px 14px;
	border: 1px solid var(--rsv-line);
	border-radius: var(--rsv-radius);
	background: var(--rsv-paper);
	color: var(--rsv-ink);
	font-family: inherit;
	font-size: 15.5px;
	line-height: 1.4;
	transition: border-color .2s var(--rsv-ease), box-shadow .2s var(--rsv-ease);
}

textarea.rsv-input {
	min-height: 104px;
	resize: vertical;
}

select.rsv-input {
	appearance: none;
	-webkit-appearance: none;
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='7' fill='none'%3E%3Cpath d='M1 1l4.5 4.5L10 1' stroke='%23756b65' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 15px center;
}

.rsv-input:focus {
	outline: none;
	border-color: var(--rsv-brand);
	box-shadow: 0 0 0 3px rgba(184, 32, 37, .14);
}

.rsv-input.is-bad {
	border-color: var(--rsv-brand);
	background: rgba(184, 32, 37, .035);
}

.rsv-hint {
	margin: 6px 0 0;
	color: var(--rsv-muted);
	font-size: 12.5px;
	line-height: 1.5;
}

.rsv-err {
	margin: 6px 0 0;
	color: var(--rsv-brand);
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1.5;
}

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

/* ---------- review ---------- */
.rsv-summary {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 14px 26px;
	margin: 0;
	padding: 18px;
	border: 1px solid var(--rsv-line);
	border-radius: var(--rsv-radius);
	background: var(--rsv-cream);
}

.rsv-summary dt {
	color: var(--rsv-muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: .14em;
	text-transform: uppercase;
}

.rsv-summary dd {
	margin: 4px 0 0;
	font-size: 15px;
	font-weight: 500;
	word-break: break-word;
}

/* ---------- alert ---------- */
.rsv-alert {
	margin: 18px 0 0;
	padding: 12px 14px;
	border: 1px solid rgba(184, 32, 37, .35);
	border-radius: var(--rsv-radius);
	background: rgba(184, 32, 37, .06);
	color: var(--rsv-brand-deep);
	font-size: 14px;
	font-weight: 500;
}

/* ---------- buttons ---------- */
.rsv-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 24px;
}

.rsv-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 50px;
	padding: 0 28px;
	border: 1.5px solid transparent;
	border-radius: 100px;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: .02em;
	text-decoration: none;
	cursor: pointer;
	transition: background .22s var(--rsv-ease), color .22s var(--rsv-ease),
		border-color .22s var(--rsv-ease), box-shadow .22s var(--rsv-ease), transform .16s var(--rsv-ease);
}

.rsv-btn-solid {
	margin-left: auto;
	background: var(--rsv-brand);
	border-color: var(--rsv-brand);
	color: #fff;
}

.rsv-btn-solid:hover:not(:disabled) {
	background: var(--rsv-brand-deep);
	border-color: var(--rsv-brand-deep);
	box-shadow: 0 8px 22px rgba(184, 32, 37, .3);
	color: #fff;
}

.rsv-btn-ghost {
	background: transparent;
	border-color: var(--rsv-line);
	color: var(--rsv-ink);
}

.rsv-btn-ghost:hover {
	border-color: var(--rsv-ink);
	color: var(--rsv-ink);
}

.rsv-btn:active:not(:disabled) {
	transform: scale(.985);
}

.rsv-btn:disabled {
	opacity: .6;
	cursor: not-allowed;
}

.rsv-btn:focus-visible,
.rsv-input:focus-visible {
	outline: 2px solid var(--rsv-brand);
	outline-offset: 2px;
}

/* ---------- success ---------- */
.rsv-done {
	padding: 12px 4px 4px;
	text-align: center;
	animation: rsv-in .4s var(--rsv-ease) both;
}

.rsv-done-mark {
	display: grid;
	width: 58px;
	height: 58px;
	margin: 0 auto 18px;
	place-items: center;
	border-radius: 50%;
	background: rgba(47, 122, 79, .12);
	color: var(--rsv-green);
}

.rsv-done-mark svg {
	width: 26px;
	height: 26px;
}

.rsv-done-title {
	margin: 0;
	font-size: clamp(21px, 2.5vw, 26px);
	font-weight: 600;
	letter-spacing: -.015em;
}

.rsv-done-text {
	margin: 10px auto 0;
	max-width: 50ch;
	color: var(--rsv-ink-soft);
	font-size: 15.5px;
}

.rsv-done-ref {
	display: inline-block;
	margin: 16px 0 0;
	padding: 7px 16px;
	border: 1px dashed var(--rsv-line);
	border-radius: 100px;
	background: var(--rsv-cream);
	font-size: 14px;
	font-weight: 600;
	letter-spacing: .04em;
}

.rsv-done-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px;
	margin-top: 24px;
}

.rsv-done-actions .rsv-btn-solid {
	margin-left: 0;
}

.rsv-done-note {
	margin: 18px auto 0;
	max-width: 46ch;
	color: var(--rsv-muted);
	font-size: 13px;
}

/* ---------- phone ---------- */
@media (max-width: 600px) {
	.rsv-steps-item {
		flex: 1 1 100%;
		padding: 9px 12px;
		font-size: 13px;
	}

	.rsv-grid {
		grid-template-columns: minmax(0, 1fr);
		gap: 16px;
	}

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

	.rsv-btn {
		width: 100%;
		margin-left: 0;
	}

	.rsv-summary {
		grid-template-columns: minmax(0, 1fr);
		padding: 16px;
	}

	.rsv-done-actions .rsv-btn {
		width: 100%;
	}
}

/* ---------- motion ---------- */
@media (prefers-reduced-motion: reduce) {
	.rsv *,
	.rsv *::before,
	.rsv *::after {
		animation-duration: .01ms !important;
		transition-duration: .01ms !important;
	}
}
