/**
 * FC Bookings — self-contained booking form styling.
 *
 * The plugin ships its own layout so the booking form, the option blocks and
 * the live summary look right in any theme. Everything is scoped to .fhc-*
 * classes and driven by CSS variables, so a theme can restyle it by
 * redefining the variables instead of fighting the selectors.
 */

.fhc-booking-layout {
	--fhc-ink: #1d2b24;
	--fhc-muted: #5c6b63;
	--fhc-line: rgba(29, 43, 36, 0.14);
	--fhc-surface: #fff;
	--fhc-surface-alt: #f5f8f5;
	--fhc-accent: #2f7d54;
	--fhc-radius: 14px;

	display: grid;
	grid-template-columns: minmax(0, 1.6fr) minmax(260px, 0.9fr);
	gap: 28px;
	align-items: start;
	color: var(--fhc-ink);
}

@media (max-width: 900px) {
	.fhc-booking-layout {
		grid-template-columns: minmax(0, 1fr);
	}
}

.fhc-form--booking {
	background: var(--fhc-surface);
	border: 1px solid var(--fhc-line);
	border-radius: var(--fhc-radius);
	padding: clamp(18px, 3vw, 30px);
	margin: 0;
}

.fhc-form__section {
	margin: 26px 0 14px;
	font-size: 1.05rem;
	line-height: 1.3;
}

.fhc-form__section:first-of-type {
	margin-top: 0;
}

.fhc-field {
	display: block;
	margin: 0 0 16px;
}

.fhc-field > label {
	display: block;
	margin-bottom: 6px;
	font-weight: 600;
	font-size: 0.95rem;
}

.fhc-field input[type="text"],
.fhc-field input[type="email"],
.fhc-field input[type="tel"],
.fhc-field input[type="date"],
.fhc-field input[type="number"],
.fhc-field input[type="password"],
.fhc-field select,
.fhc-field textarea {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	padding: 11px 12px;
	font: inherit;
	color: inherit;
	background: var(--fhc-surface);
	border: 1px solid var(--fhc-line);
	border-radius: 10px;
}

.fhc-field select {
	appearance: none;
	background-image: linear-gradient(45deg, transparent 49%, currentColor 50%), linear-gradient(-45deg, transparent 49%, currentColor 50%);
	background-position: calc(100% - 18px) 55%, calc(100% - 12px) 55%;
	background-size: 6px 6px;
	background-repeat: no-repeat;
	padding-right: 34px;
}

.fhc-field :is(input, select, textarea):focus-visible {
	outline: 2px solid var(--fhc-accent);
	outline-offset: 1px;
}

.fhc-field :is(input, select):disabled {
	opacity: 0.6;
}

.fhc-req {
	color: #b3261e;
}

.fhc-help {
	display: block;
	margin-top: 6px;
	color: var(--fhc-muted);
	font-size: 0.85rem;
	line-height: 1.45;
}

/* Per-service option blocks. */
.fhc-service-fields[hidden] {
	display: none;
}

.fhc-service-fields {
	background: var(--fhc-surface-alt);
	border: 1px solid var(--fhc-line);
	border-radius: var(--fhc-radius);
	padding: 14px 16px 2px;
	margin: 0 0 18px;
}

/* Tie the option card to the Service select above it: the two belong
   together, so the gap between them is tightened. */
.fhc-field--service {
	margin-bottom: 6px;
}

.fhc-service-fields > .fhc-field:last-child {
	margin-bottom: 12px;
}

/* Tick-box cards used for add-ons and extras. */
.fhc-checkgroup {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
	gap: 10px;
}

.fhc-extras__group {
	display: block;
	margin-bottom: 14px;
}

.fhc-extras .fhc-extras__heading {
	display: flex;
	align-items: center;
	gap: 8px;
	width: 100%;
	margin: 0 0 8px;
	padding: 8px 0;
	background: none;
	border: 0;
	border-bottom: 1px solid var(--fhc-line);
	font-family: inherit;
	font-size: 0.8rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--fhc-muted);
	text-align: left;
	cursor: pointer;
}

.fhc-extras .fhc-extras__heading:hover,
.fhc-extras .fhc-extras__heading:focus-visible {
	color: var(--fhc-accent);
}

.fhc-extras .fhc-extras__heading-text {
	flex: 1 1 auto;
}

.fhc-extras__count:not(:empty) {
	flex: 0 0 auto;
	padding: 2px 8px;
	border-radius: 999px;
	background: var(--fhc-accent);
	color: #fff;
	font-size: 0.7rem;
	letter-spacing: 0.04em;
}

.fhc-extras__chevron {
	flex: 0 0 auto;
	width: 8px;
	height: 8px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform 0.18s ease;
}

.fhc-extras__group.is-collapsed .fhc-extras__chevron {
	transform: rotate(-45deg);
}

.fhc-extras__group.is-collapsed [data-fhc-extras-panel] {
	display: none;
}


.fhc-check {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	cursor: pointer;
}

.fhc-check--card {
	background: var(--fhc-surface);
	border: 1px solid var(--fhc-line);
	border-radius: 12px;
	padding: 11px 12px;
}

.fhc-check--card:has(input:checked) {
	border-color: var(--fhc-accent);
	box-shadow: inset 0 0 0 1px var(--fhc-accent);
}

.fhc-check input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.fhc-check__box {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin-top: 2px;
	border: 1px solid var(--fhc-line);
	border-radius: 5px;
	background: var(--fhc-surface);
}

.fhc-check input:checked + .fhc-check__box {
	background: var(--fhc-accent);
	border-color: var(--fhc-accent);
	background-image: linear-gradient(45deg, transparent 52%, #fff 53%, #fff 62%, transparent 63%), linear-gradient(-45deg, transparent 62%, #fff 63%, #fff 72%, transparent 73%);
}

.fhc-check__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	font-size: 0.9rem;
	line-height: 1.35;
}

.fhc-check__price {
	color: var(--fhc-muted);
	font-size: 0.85rem;
}

/* Locked / package intro card. */
.fhc-booking-package {
	background: var(--fhc-surface-alt);
	border: 1px solid var(--fhc-line);
	border-radius: var(--fhc-radius);
	padding: 16px;
	margin: 0 0 20px;
}

.fhc-booking-package__title {
	margin: 0 0 4px;
}

.fhc-booking-package__price {
	margin: 0 0 8px;
	font-weight: 700;
}

.fhc-booking-package__list {
	margin: 0 0 8px;
	padding-left: 18px;
	font-size: 0.9rem;
	color: var(--fhc-muted);
}

/* Live summary. */
.fhc-checkout {
	position: sticky;
	top: 24px;
	background: var(--fhc-surface);
	border: 1px solid var(--fhc-line);
	border-radius: var(--fhc-radius);
	padding: 20px;
}

.fhc-checkout__title {
	margin: 0 0 14px;
	font-size: 1.05rem;
}

.fhc-checkout__lines {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 6px 12px;
	margin: 0 0 14px;
	font-size: 0.9rem;
}

.fhc-checkout__lines dt,
.fhc-checkout__lines dd {
	margin: 0;
}

.fhc-checkout__lines dd {
	text-align: right;
	font-variant-numeric: tabular-nums;
}

.fhc-checkout__lines .is-note {
	color: var(--fhc-muted);
	font-size: 0.85rem;
}

.fhc-checkout__lines .is-primary,
.fhc-checkout__lines .is-emphasis {
	font-weight: 700;
}

.fhc-checkout__lines .is-primary + .is-primary,
.fhc-checkout__lines .is-emphasis + .is-emphasis {
	margin-top: 4px;
}

.fhc-checkout__total {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 12px;
	padding-top: 12px;
	border-top: 1px solid var(--fhc-line);
	font-weight: 700;
}

.fhc-checkout__duration,
.fhc-checkout__note {
	margin: 10px 0 0;
	color: var(--fhc-muted);
	font-size: 0.83rem;
	line-height: 1.45;
}

.fhc-field--submit {
	margin-top: 22px;
}

.fhc-btn {
	display: inline-block;
	padding: 13px 22px;
	border: 0;
	border-radius: 999px;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
}

.fhc-btn--primary {
	background: var(--fhc-accent);
	color: #fff;
}

.fhc-btn--primary:hover {
	filter: brightness(1.07);
}

.fhc-notice {
	padding: 12px 14px;
	border-radius: 10px;
	margin-bottom: 16px;
	border: 1px solid var(--fhc-line);
	background: #f5f8f5;
}

.fhc-notice--error {
	border-color: #e5b4b0;
	background: #fdf3f2;
}

.fhc-notice--success {
	border-color: #b6dcc4;
	background: #f1faf4;
}

/* Neutralise the theme's decorative rule so the toggle row stays clean. */
.fhc-extras .fhc-extras__heading::after {
	content: none;
	display: none;
}

/* ---- Message attachments ------------------------------------------------ */
.fhc-message-form__files {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: .5rem .75rem;
	margin: .5rem 0 .75rem;
}

.fhc-message-form__file {
	position: relative;
	display: inline-flex;
	margin: 0;
}

.fhc-message-form__file input[type="file"] {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
}

.fhc-message-form__file-btn {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	padding: .45rem .8rem;
	border: 1px dashed var(--fhc-line, #d7dbd7);
	border-radius: 999px;
	font-size: .875rem;
	line-height: 1.2;
	background: #fff;
}

.fhc-message-form__file-btn::before {
	content: "\1F4CE";
}

.fhc-msg__files {
	display: flex;
	flex-wrap: wrap;
	gap: .35rem .5rem;
	margin: .5rem 0 0;
	padding: 0;
	list-style: none;
}

.fhc-msg__files li {
	max-width: 100%;
	margin: 0;
}

.fhc-msg__files a {
	display: inline-flex;
	align-items: center;
	gap: .35rem;
	max-width: 100%;
	padding: .25rem .6rem;
	border: 1px solid var(--fhc-line, #d7dbd7);
	border-radius: 999px;
	font-size: .8125rem;
	overflow-wrap: anywhere;
	background: #fff;
	text-decoration: none;
}

.fhc-msg__files a::before {
	content: "\1F4C4";
}

.fhc-msg__filesize {
	margin-left: .25rem;
	font-size: .75rem;
	opacity: .7;
}
