/* Customer booking app: shared pieces (buttons, fields, dialog, history rows, choices, notes) and "Minu broneeringud". */

.fg-app,
.fg-dialog {
	--fgb-bg: var(--fg-color-bg, #f1eada);
	--fgb-surface: color-mix(in srgb, var(--fg-color-surface, #ded0b9) 42%, var(--fg-color-bg, #f1eada));
	--fgb-surface-strong: var(--fg-color-surface, #ded0b9);
	--fgb-ink: var(--fg-color-text, #3d2e22);
	--fgb-muted: var(--fg-color-muted, #62503f);
	--fgb-line: var(--fg-color-line, #897158);
	--fgb-action: var(--fg-color-action, #493a2f);
	--fgb-on-action: var(--fg-color-action-text, #fffaf0);
	--fgb-accent: var(--fg-color-accent, #694514);
	--fgb-success: var(--fg-color-success, #2f5d3a);
	--fgb-warning: var(--fg-color-warning, #894a08);
	--fgb-danger: var(--fg-color-danger, #a3281f);
	--fgb-radius: var(--fg-radius-m, 4px);
	--fgb-display: var(--fg-font-display, Georgia, serif);
	--fgb-body: var(--fg-font-body, system-ui, sans-serif);
	--fgb-ease-out: var(--fg-ease-out, cubic-bezier(0.23, 1, 0.32, 1));

	color: var(--fgb-ink);
	font-family: var(--fgb-body);
	font-size: 1rem;
	line-height: 1.55;
}

.fg-app {
	min-height: 12rem;
}

.fg-app *,
.fg-dialog * {
	box-sizing: border-box;
	min-width: 0;
}

.fg-app [hidden],
.fg-dialog [hidden] {
	display: none !important;
}

.fg-app p,
.fg-dialog p {
	margin: 0 0 16px;
	max-width: 62ch;
}

.fg-app__loading,
.fg-app__noscript {
	margin: 0;
	padding: var(--fg-space-5, 24px) 0;
	color: var(--fg-color-muted, inherit);
}

/* Headings: the page owns the h1; the app's h2/h3 stay quieter than the theme's page scale. */

.fg-app h2,
.fg-dialog h2 {
	margin: 0 0 16px;
	font-family: var(--fgb-display);
	font-size: clamp(1.75rem, 3.2vw, 2.25rem);
	font-weight: 400;
	line-height: 1.15;
	letter-spacing: -0.02em;
	text-wrap: balance;
}

.fg-app h3,
.fg-dialog h3 {
	margin: 0;
	font-family: var(--fgb-body);
	font-size: 1.125rem;
	font-weight: 600;
	line-height: 1.35;
	letter-spacing: 0;
}

[data-step-heading]:focus {
	outline: none;
}

.fg-lead {
	color: var(--fgb-ink);
}

.fg-hint {
	margin: 0;
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

/* Buttons and links */

.fg-app button,
.fg-dialog button,
.fg-app .fg-button,
.fg-dialog .fg-button {
	font: inherit;
	color: inherit;
	cursor: pointer;
	border-radius: var(--fg-radius-s, 2px);
	transition: transform 160ms var(--fgb-ease-out), background-color 160ms ease, border-color 160ms ease;
}

.fg-app button:active:not(:disabled, [aria-disabled='true']),
.fg-dialog button:active:not(:disabled, [aria-disabled='true']),
.fg-app .fg-button:active,
.fg-dialog .fg-button:active {
	transform: scale(0.97);
}

.fg-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 48px;
	padding: 12px 22px;
	border: 1px solid var(--fgb-action);
	background: var(--fgb-action);
	color: var(--fgb-on-action) !important;
	font-weight: 600;
	line-height: 1.25;
	text-align: center;
	text-decoration: none;
}

.fg-button.secondary {
	border-color: var(--fgb-line);
	background: transparent;
	color: var(--fgb-ink) !important;
}

.fg-button--danger.secondary {
	border-color: var(--fgb-danger);
	color: var(--fgb-danger) !important;
}

.fg-button:disabled,
.fg-button[aria-busy='true'] {
	cursor: progress;
	opacity: 0.7;
}

.fg-link {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 8px 4px;
	border: 0;
	background: transparent;
	color: var(--fgb-ink);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 4px;
}

.fg-arrow-link {
	font-weight: 600;
	text-underline-offset: 5px;
}

.fg-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 24px;
}

.fg-actions > * {
	flex: 1 1 auto;
}

.fg-actions--tight {
	margin-top: 16px;
}

.fg-actions--tight > * {
	flex: 0 1 auto;
}

.fg-actions--links {
	gap: 4px 20px;
	margin-top: 8px;
}

.fg-actions--links > * {
	flex: 0 0 auto;
}

.fg-actions--links .fg-link {
	padding-inline: 0;
}

/* Fields */

.fg-form-stack {
	display: grid;
	gap: 20px;
}

.fg-form-stack > .fg-button {
	justify-self: start;
}

.fg-form-stack + .fg-status-line,
.fg-form-stack + .fg-hint,
.fg-status-line + .fg-hint {
	margin-top: 16px;
}

.fg-field {
	display: grid;
	gap: 6px;
}

.fg-field label {
	font-weight: 600;
}

.fg-field input,
.fg-field select,
.fg-field textarea {
	width: 100%;
	min-height: 48px;
	padding: 12px 14px;
	border: 1px solid var(--fgb-line);
	border-radius: var(--fgb-radius);
	background: var(--fgb-bg);
	color: var(--fgb-ink);
	font: inherit;
	color-scheme: light;
}

.fg-field input[aria-invalid='true'],
.fg-consent input[aria-invalid='true'] {
	border-color: var(--fgb-danger);
	outline: 1px solid var(--fgb-danger);
}

.fg-app .fg-field-error,
.fg-dialog .fg-field-error {
	margin: 0;
	color: var(--fgb-danger);
	font-weight: 600;
}

.fg-app .fg-consent,
.fg-dialog .fg-consent {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
}

.fg-consent label {
	min-height: 44px;
}

.fg-app .fg-consent input,
.fg-dialog .fg-consent input {
	flex: 0 0 auto;
	width: 24px;
	height: 24px;
	margin: 2px 0 0;
	accent-color: var(--fgb-action);
}

.fg-consent label a {
	padding-block: 3px;
	font-weight: 600;
}

.fg-consent-field {
	display: grid;
	gap: 6px;
}

.fg-error {
	margin: 0;
	padding: 12px 14px;
	border: 2px solid var(--fgb-danger);
	color: var(--fgb-danger);
	font-weight: 600;
}

.fg-note {
	margin: 16px 0;
	padding: 16px;
	border: 1px solid var(--fgb-line);
	background: var(--fgb-surface);
	font-size: 0.9375rem;
}

.fg-note > p:last-child {
	margin-bottom: 0;
}

.fg-status-line:empty {
	display: none;
}

.fg-status-line {
	margin: 0;
	font-weight: 600;
}

/* Choices (step-flow options) */

.fg-choices {
	display: grid;
	gap: 10px;
	margin: 24px 0 0;
}

.fg-choice {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	min-height: 64px;
	padding: 16px;
	border: 1px solid var(--fgb-line);
	background: var(--fgb-surface);
	color: var(--fgb-ink);
	text-align: left;
}

.fg-choice span {
	display: grid;
	gap: 4px;
}

.fg-choice small {
	font-size: 0.9375rem;
	font-weight: 400;
}

.fg-choice strong {
	font-size: 1.1rem;
}

.fg-choice-price {
	white-space: nowrap;
}

/* People */

.fg-person {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0;
}

.fg-monogram {
	display: inline-grid;
	flex-shrink: 0;
	place-items: center;
	width: 28px;
	height: 28px;
	border: 1px solid currentColor;
	border-radius: 50%;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.02em;
}

/* Dialog */

.fg-dialog {
	width: min(620px, calc(100% - 24px));
	max-height: calc(100dvh - 32px);
	padding: 24px;
	border: 1px solid var(--fgb-line);
	border-radius: var(--fgb-radius);
	background: var(--fgb-bg);
	box-shadow: 0 24px 72px rgb(32 26 20 / 33%);
	overscroll-behavior: contain;
	opacity: 1;
	transform: scale(1);
	transition: opacity 250ms var(--fgb-ease-out), transform 250ms var(--fgb-ease-out), overlay 250ms allow-discrete, display 250ms allow-discrete;
}

.fg-dialog:not([open]) {
	opacity: 0;
	transform: scale(0.96);
}

@starting-style {
	.fg-dialog[open] {
		opacity: 0;
		transform: scale(0.96);
	}
}

.fg-dialog::backdrop {
	background: rgb(33 26 21 / 67%);
	opacity: 1;
	transition: opacity 250ms var(--fgb-ease-out), overlay 250ms allow-discrete, display 250ms allow-discrete;
}

.fg-dialog:not([open])::backdrop {
	opacity: 0;
}

@starting-style {
	.fg-dialog[open]::backdrop {
		opacity: 0;
	}
}

.fg-dialog-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 16px;
}

.fg-dialog-top p {
	margin: 0;
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

.fg-close {
	margin-left: auto;
	min-width: 44px;
	min-height: 44px;
	padding: 8px;
	border: 1px solid var(--fgb-line);
	background: transparent;
	font-size: 1.25rem;
	line-height: 1;
}

.fg-history {
	display: grid;
	margin: 0 0 24px;
}

.fg-history-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 0;
	border-bottom: 1px solid var(--fgb-line);
	font-size: 0.9375rem;
}

.fg-history-row span {
	overflow-wrap: anywhere;
}

.fg-history-row button {
	flex-shrink: 0;
}

.fg-history-row button[aria-disabled='true'] {
	cursor: not-allowed;
	opacity: 0.45;
	text-decoration: none;
}

.fg-step p {
	max-width: 58ch;
}

.fg-summary {
	font-weight: 600;
}

/* "Minu broneeringud" */

.fg-flash {
	margin: 0 0 32px;
	padding: 16px 20px;
	border: 1px solid var(--fgb-success);
	background: color-mix(in srgb, var(--fgb-success) 8%, var(--fgb-bg));
	font-weight: 600;
}

.fg-flash.is-error {
	border: 2px solid var(--fgb-danger);
	background: var(--fgb-bg);
	color: var(--fgb-danger);
}

.fg-flash:focus {
	outline: none;
}

.fg-flash:focus-visible {
	outline: 3px solid var(--fgb-accent);
	outline-offset: 4px;
}

.fg-flash p {
	margin: 0;
}

.fg-flash p + p {
	margin-top: 4px;
	font-weight: 400;
}

.fg-panel {
	padding: clamp(24px, 4vw, 48px);
	border: 1px solid var(--fgb-line);
	background: var(--fgb-bg);
}

.fg-panel--narrow {
	max-width: 640px;
}

.fg-panel + .fg-mine,
.fg-panel + .fg-panel {
	margin-top: 48px;
}

.fg-divider {
	display: flex;
	align-items: center;
	gap: 16px;
	margin: 32px 0 16px;
	color: var(--fgb-muted);
}

.fg-divider::before,
.fg-divider::after {
	content: '';
	flex: 1 1 auto;
	height: 1px;
	background: var(--fgb-line);
}

.fg-auth-submit {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 24px;
}

.fg-google {
	margin-top: 12px;
}

.fg-app .fg-whoami {
	margin: 0 0 24px;
	color: var(--fgb-muted);
}

.fg-mine-grid,
.fg-mine-side {
	display: grid;
	align-items: start;
	gap: 48px;
}

.fg-section-title {
	padding-bottom: 12px;
	border-bottom: 1px solid var(--fgb-line);
}

.fg-cards {
	display: grid;
	margin: 0;
	padding: 0;
	list-style: none;
}

.fg-cards > li + li {
	border-top: 1px solid color-mix(in srgb, var(--fgb-line) 55%, var(--fgb-bg));
}

.fg-card {
	display: grid;
	gap: 6px;
	padding: 20px 0;
}

.fg-card p {
	margin: 0;
}

.fg-card-head {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 6px 16px;
}

.fg-booking-card .fg-when {
	font-size: 1.0625rem;
}

.fg-facts,
.fg-card-note {
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

.fg-card.is-compact {
	padding: 14px 0;
	gap: 2px;
}

.fg-card.is-compact .fg-person {
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

.fg-card.is-inactive .fg-card-title {
	color: var(--fgb-muted);
}

.fg-chip {
	display: inline-block;
	padding: 2px 8px;
	border: 1px solid currentColor;
	border-radius: var(--fg-radius-s, 2px);
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.5;
	white-space: nowrap;
	color: var(--fgb-muted);
}

.fg-chip--confirmed,
.fg-chip--completed,
.fg-chip--order-paid {
	color: var(--fgb-success);
}

.fg-chip--held,
.fg-chip--payment_conflict,
.fg-chip--order-pending {
	color: var(--fgb-warning);
}

.fg-chip--order-failed {
	color: var(--fgb-danger);
}

.fg-section.is-side {
	padding: clamp(20px, 3vw, 32px);
	background: var(--fgb-surface);
}

.fg-section.is-side .fg-cards > li + li {
	border-top-color: var(--fgb-line);
}

.fg-balances {
	display: grid;
	gap: 2px;
	margin: 6px 0 0;
	padding: 0;
	list-style: none;
	font-weight: 600;
}

.fg-app .fg-details {
	margin-top: 4px;
	border: 0;
}

.fg-app .fg-details summary {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 8px 32px 8px 0;
	font-size: 1rem;
	font-weight: 400;
	text-decoration: underline;
	text-underline-offset: 4px;
}

.fg-app .fg-details summary::after {
	top: 50%;
	transform: translateY(-50%);
}

.fg-history-list {
	display: grid;
	gap: 10px;
	margin: 4px 0 8px;
	padding: 0;
	list-style: none;
	font-size: 0.9375rem;
}

.fg-history-list li {
	display: grid;
	grid-template-columns: 6.5rem minmax(0, 1fr);
	gap: 0 12px;
}

.fg-history-list li > :not(.fg-history-date) {
	grid-column: 2;
}

.fg-history-date {
	color: var(--fgb-muted);
}

.fg-dl {
	display: grid;
	grid-template-columns: max-content minmax(0, 1fr);
	gap: 4px 20px;
	margin: 8px 0 0;
	font-size: 0.9375rem;
}

.fg-dl dt {
	color: var(--fgb-muted);
}

.fg-dl dd {
	margin: 0;
	overflow-wrap: anywhere;
}

.fg-subsection + .fg-subsection {
	margin-top: 28px;
	padding-top: 24px;
	border-top: 1px solid var(--fgb-line);
}

.fg-subsection .fg-form-stack {
	margin-top: 16px;
}

.fg-app .fg-sub-title {
	margin-bottom: 8px;
}

.fg-manage .fg-booking-card {
	margin: 8px 0 16px;
	padding: 20px;
	border: 1px solid var(--fgb-line);
	background: var(--fgb-surface);
}

.fg-app .fg-nudge {
	margin: 0;
}

.fg-manage-login {
	margin-top: 32px;
	padding-top: 32px;
	border-top: 1px solid var(--fgb-line);
}

@media (min-width: 1000px) {
	.fg-mine-grid {
		grid-template-columns: minmax(0, 1fr) minmax(340px, 420px);
		grid-template-areas:
			'upcoming side'
			'past side'
			'orders side';
		grid-template-rows: auto auto 1fr;
		gap: 56px 64px;
	}

	.fg-section--upcoming {
		grid-area: upcoming;
	}

	.fg-mine-side {
		grid-area: side;
		gap: 32px;
	}

	.fg-section--past {
		grid-area: past;
	}

	.fg-section--orders {
		grid-area: orders;
	}
}

@media (prefers-reduced-motion: reduce) {
	.fg-app button,
	.fg-dialog button,
	.fg-app .fg-button,
	.fg-dialog .fg-button {
		transition: background-color 160ms ease, border-color 160ms ease;
	}

	.fg-app button:active:not(:disabled),
	.fg-dialog button:active:not(:disabled),
	.fg-app .fg-button:active,
	.fg-dialog .fg-button:active {
		transform: none;
	}

	.fg-dialog,
	.fg-dialog:not([open]) {
		transform: none;
		transition: opacity 200ms ease, overlay 200ms allow-discrete, display 200ms allow-discrete;
	}

	@starting-style {
		.fg-dialog[open] {
			transform: none;
		}
	}
}

/* Booking calendar */

#fg-booking {
	--fgb-paper: color-mix(in srgb, var(--fgb-bg) 22%, #fff);

	padding: clamp(16px, 2.5vw, 38px);
	border: 1px solid var(--fgb-line);
	background: var(--fgb-bg);
}

.fg-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 16px;
	margin-bottom: 16px;
}

.fg-app .fg-toolbar p {
	margin: 0;
	font-weight: 500;
}

.fg-filters {
	display: grid;
	grid-template-columns: 2fr 1fr;
	gap: 16px;
	margin-bottom: 16px;
}

.fg-service-line {
	margin: 16px 0;
}

.fg-app .fg-service-line p {
	margin: 0 0 4px;
}

.fg-service-price {
	font-weight: 600;
}

.fg-week-control {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin: 16px 0;
}

.fg-app .fg-week-control h2 {
	margin: 0;
	font-family: var(--fgb-body);
	font-size: clamp(1.125rem, 2.4vw, 1.5rem);
	font-weight: 500;
	text-align: center;
}

.fg-week-control h2:focus {
	outline: none;
}

.fg-week-button {
	flex-shrink: 0;
	min-width: 48px;
	min-height: 48px;
	border: 1px solid var(--fgb-line);
	background: var(--fgb-paper);
	font-size: 1.125rem;
}

.fg-week-button:disabled {
	border-color: color-mix(in srgb, var(--fgb-line) 45%, var(--fgb-bg));
	background: transparent;
	color: var(--fgb-muted);
	cursor: default;
}

.fg-app .fg-horizon {
	margin: -8px 0 16px auto;
	text-align: right;
}

.fg-days {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 8px;
	margin-bottom: 14px;
}

.fg-days button {
	display: grid;
	justify-items: center;
	gap: 2px;
	min-height: 56px;
	padding: 10px 4px;
	border: 1px solid var(--fgb-line);
	background: var(--fgb-paper);
	font-variant-numeric: tabular-nums;
}

.fg-days strong {
	font-size: 1.4rem;
	line-height: 1.1;
}

.fg-days [aria-pressed='true'] {
	border-color: var(--fgb-action);
	background: var(--fgb-action);
	color: var(--fgb-on-action);
}

.fg-legend {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 24px;
	margin: 0 0 20px;
	font-size: 0.9375rem;
}

.fg-legend > span {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.fg-legend i {
	flex-shrink: 0;
	width: 17px;
	height: 17px;
	border: 1px solid var(--fgb-ink);
	background: var(--fgb-paper);
}

.fg-legend .legend-available {
	box-shadow: inset 0 -5px var(--fgb-action);
}

.fg-legend .legend-few {
	border-width: 3px;
}

.fg-legend .legend-full {
	border-style: dashed;
	background: var(--fgb-surface);
}

.fg-legend .legend-past {
	border-color: var(--fgb-line);
	background: color-mix(in srgb, var(--fgb-surface-strong) 45%, var(--fgb-bg));
}

.fg-board {
	min-height: 8rem;
}

.fg-board-status {
	padding: 24px 0;
	color: var(--fgb-muted);
}

.fg-week-empty {
	display: grid;
	justify-items: start;
	gap: 12px;
	margin-bottom: 16px;
}

.fg-app .fg-week-empty p {
	margin: 0;
	font-weight: 600;
}

.fg-calendar {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	align-items: start;
	gap: 12px;
	padding: 16px 12px;
	border: 1px solid color-mix(in srgb, var(--fgb-line) 50%, var(--fgb-bg));
	background: var(--fgb-surface);
}

.fg-day-column {
	display: grid;
	align-content: start;
	gap: 12px;
}

.fg-app .fg-day-title {
	font-size: 1rem;
}

.fg-app .fg-empty {
	margin: 0;
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

.fg-slot {
	display: grid;
	gap: 8px;
	width: 100%;
	min-height: 44px;
	padding: 14px 12px;
	border: 1px solid var(--fgb-ink);
	background: var(--fgb-paper);
	line-height: 1.35;
	text-align: left;
	overflow-wrap: anywhere;
}

.fg-slot time {
	font-size: 1.5rem;
	font-weight: 600;
	letter-spacing: -0.02em;
	font-variant-numeric: tabular-nums;
}

.fg-slot-name {
	font-weight: 600;
}

.fg-slot .fg-person {
	gap: 6px;
	font-size: 0.9375rem;
}

.fg-spots {
	justify-self: start;
	padding: 4px 8px;
	background: var(--fgb-action);
	color: var(--fgb-on-action);
	font-size: 0.875rem;
	font-weight: 600;
}

.fg-slot.is-few {
	padding: 13px 11px;
	border-width: 2px;
}

.fg-slot.is-full {
	border-style: dashed;
	background: var(--fgb-surface-strong);
}

.fg-slot.is-full .fg-spots,
.fg-slot:disabled .fg-spots {
	padding-inline: 0;
	background: transparent;
	color: inherit;
}

.fg-app .fg-slot:disabled {
	border-color: color-mix(in srgb, var(--fgb-line) 70%, var(--fgb-bg));
	background: color-mix(in srgb, var(--fgb-surface-strong) 45%, var(--fgb-bg));
	color: var(--fgb-muted);
	cursor: not-allowed;
}

.fg-app .fg-slot.is-own {
	border-style: solid;
	color: var(--fgb-ink);
}

.fg-app .fg-view-note {
	margin: 24px 0 0;
	color: var(--fgb-muted);
	font-size: 0.9375rem;
}

@media (hover: hover) and (pointer: fine) {
	.fg-button:not(:disabled):hover {
		background: color-mix(in srgb, var(--fgb-action) 88%, var(--fgb-bg));
	}

	.fg-button.secondary:not(:disabled):hover {
		border-color: var(--fgb-ink);
		background: var(--fgb-surface);
	}

	.fg-link:not([aria-disabled='true']):hover {
		text-decoration-thickness: 2px;
	}

	.fg-choice:hover:not(:focus-visible) {
		outline: 1px solid var(--fgb-ink);
		outline-offset: -1px;
	}

	.fg-slot:not(:disabled, :focus-visible):hover {
		outline: 2px solid var(--fgb-ink);
		outline-offset: 2px;
	}

	.fg-days button:not([aria-pressed='true']):hover,
	.fg-week-button:not(:disabled):hover {
		border-color: var(--fgb-ink);
	}
}

/* Standalone pass purchase */

.fg-pass-summary {
	display: grid;
	gap: 24px 48px;
	margin: 8px 0 24px;
	padding: clamp(20px, 3vw, 32px);
	border: 1px solid var(--fgb-line);
	background: var(--fgb-paper);
}

.fg-app .fg-pass-facts p {
	margin: 0 0 8px;
}

.fg-pass-price {
	font-size: 1.25rem;
	font-weight: 600;
}

.fg-price-regular {
	color: var(--fgb-muted);
	font-size: 0.9rem;
	font-weight: 400;
}

.fg-pass-facts .fg-balances {
	margin-bottom: 12px;
}

/* Pass panel: bank or card */

.fg-method-set {
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.fg-method-set legend {
	margin: 0 0 8px;
	padding: 0;
	font-weight: 600;
}

.fg-methods {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr));
	gap: 8px;
}

.fg-app .fg-methods > p {
	grid-column: 1 / -1;
	margin: 0;
}

.fg-methods .fg-actions {
	grid-column: 1 / -1;
	margin-top: 0;
}

.fg-method {
	display: flex;
	align-items: center;
	gap: 12px;
	min-height: 52px;
	padding: 12px 14px;
	border: 1px solid var(--fgb-line);
	border-radius: var(--fg-radius-s, 2px);
	background: var(--fgb-surface);
	font-weight: 600;
	cursor: pointer;
	transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.fg-method input {
	flex: 0 0 auto;
	width: 20px;
	height: 20px;
	margin: 0;
	accent-color: var(--fgb-action);
}

.fg-method:has(input:checked) {
	border-color: var(--fgb-action);
	background: var(--fgb-paper);
	box-shadow: inset 0 0 0 1px var(--fgb-action);
}

.fg-method:has(input:focus-visible) {
	outline: 3px solid var(--fgb-accent);
	outline-offset: 2px;
}

.fg-method-set.is-invalid .fg-method {
	border-color: var(--fgb-danger);
}

.fg-method-set .fg-field-error {
	margin-top: 8px;
}

.fg-app .fg-redirect-note {
	margin-top: -8px;
}

/* Payment return */

.fg-return {
	margin: 0 0 32px;
	padding: clamp(20px, 3vw, 32px);
	border: 1px solid var(--fgb-line);
	background: var(--fgb-paper);
}

.fg-return.is-success {
	border-color: var(--fgb-success);
}

.fg-return .fg-success-mark {
	margin: 0 0 16px;
}

.fg-return .fg-summary-block {
	margin: 4px 0 20px;
	padding: 16px 0;
	border-block: 1px solid color-mix(in srgb, var(--fgb-line) 45%, transparent);
}

.fg-app .fg-summary-block p {
	margin: 0 0 4px;
}

.fg-app .fg-summary-block .fg-person {
	margin: 4px 0 8px;
}

.fg-app .fg-summary-block .fg-return-amount {
	margin: 8px 0 0;
}

.fg-app .fg-return-amount {
	margin: 8px 0 16px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

@media (min-width: 761px) {
	.fg-return .fg-actions > * {
		flex: 0 1 auto;
	}
}

.fg-return .fg-error {
	margin: 16px 0 0;
}

.fg-return-retry {
	margin-top: 24px;
}

.fg-return-retry h3:focus {
	outline: none;
}

.fg-return-retry .fg-choices {
	max-width: 560px;
	margin-top: 12px;
}

.fg-choice[aria-busy='true'] {
	border-color: var(--fgb-action);
}

/* Booking dialog steps */

.fg-consent-group {
	display: grid;
	gap: 12px;
}

.fg-summary-block {
	margin: 0 0 8px;
}

.fg-dialog .fg-summary-block p {
	margin: 0 0 4px;
}

.fg-dialog .fg-summary-block .fg-person {
	margin: 4px 0 8px;
}

.fg-dialog .fg-price-total {
	margin: 20px 0 4px;
	font-size: 2.25rem;
	line-height: 1.2;
	letter-spacing: -0.03em;
	font-variant-numeric: tabular-nums;
}

.fg-pay-line {
	color: var(--fgb-muted);
}

.fg-success-mark {
	display: grid;
	place-items: center;
	width: 64px;
	height: 64px;
	margin: 8px 0 24px;
	border: 1px solid var(--fgb-success);
	border-radius: 50%;
	color: var(--fgb-success);
	font-size: 2rem;
}

.fg-dialog .fg-error {
	margin: 12px 0;
}

@media (min-width: 761px) {
	.fg-app .fg-day-title {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
		white-space: nowrap;
	}
}

@media (min-width: 900px) {
	.fg-pass-summary {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
	}
}

@media (max-width: 1100px) and (min-width: 761px) {
	.fg-calendar {
		gap: 6px;
		padding: 14px 8px;
	}

	.fg-slot {
		padding: 12px 8px;
	}

	.fg-slot.is-few {
		padding: 11px 7px;
	}

	.fg-slot time {
		font-size: 1.25rem;
	}
}

@media (max-width: 760px) {
	.fg-dialog {
		max-height: calc(100dvh - 16px);
		padding: 20px;
	}

	.fg-history-row {
		align-items: start;
	}

	.fg-choice {
		padding: 14px;
	}

	.fg-actions > *,
	.fg-form-stack > .fg-button {
		flex: 1 1 100%;
		justify-self: stretch;
	}

	.fg-actions--tight > * {
		flex: 1 1 auto;
	}

	.fg-history-list li {
		grid-template-columns: minmax(0, 1fr);
	}

	.fg-history-list li > :not(.fg-history-date) {
		grid-column: 1;
	}

	#fg-booking {
		padding: 16px 12px;
	}

	.fg-filters {
		grid-template-columns: 1fr;
		gap: 12px;
	}

	.fg-week-control {
		gap: 8px;
	}

	.fg-days {
		gap: 4px;
	}

	.fg-days button {
		padding: 8px 2px;
		font-size: 0.875rem;
	}

	.fg-days strong {
		font-size: 1.25rem;
	}

	.fg-calendar {
		display: block;
		padding: 16px;
	}

	.fg-day-column:not(.is-selected) {
		display: none;
	}

	.fg-slot {
		grid-template-columns: 84px minmax(0, 1fr);
		gap: 6px 16px;
		padding: 18px;
	}

	.fg-slot.is-few {
		padding: 17px;
	}

	.fg-slot time {
		grid-row: span 3;
	}

	.fg-slot > :not(time) {
		grid-column: 2;
	}

	.fg-app .fg-horizon {
		margin-top: 0;
		text-align: left;
	}
}
