/* Tour enquiry forms (two-step #nt-enquiry-form and Tour Master's #tourmaster-enquiry-form) and the admin enquiry screen */

/* ---------- two-step form ---------- */

#nt-enquiry-form fieldset {
	border: 0;
	margin: 0;
	padding: 0;
	min-width: 0;
}

#nt-enquiry-form [hidden] {
	display: none !important;
}

/* spam trap: off-screen for people, still filled in by bots */
#nt-enquiry-form .nt-enquiry-hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

#nt-enquiry-form .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
}

#nt-enquiry-form .nt-enquiry-steps {
	display: flex;
	gap: 18px;
	margin-bottom: 22px;
	font-size: 14px;
}

#nt-enquiry-form .nt-enquiry-step-label {
	padding-bottom: 6px;
	border-bottom: 2px solid #e6e6e6;
	color: #9a9a9a;
}

#nt-enquiry-form .nt-enquiry-step-label.nt-active {
	border-bottom-color: currentColor;
	color: inherit;
	font-weight: 600;
}

#nt-enquiry-form .nt-enquiry-date {
	cursor: pointer;
	background-color: #fff;
}

#nt-enquiry-form .tourmaster-type-datepicker .fa-calendar {
	cursor: pointer;
}

/* Next / Submit Enquiry: sized and styled by Tour Master's own .tourmaster-enquiry-form .tourmaster-button rules */
#nt-enquiry-form .nt-enquiry-submit[disabled] {
	opacity: .8;
	cursor: wait;
}

/* Back: a small text link under the button. The theme styles every <button> as a coloured button. */
#nt-enquiry-form button.nt-enquiry-back,
#nt-enquiry-form button.nt-enquiry-back:hover,
#nt-enquiry-form button.nt-enquiry-back:focus {
	display: block;
	margin: 16px auto 0;
	padding: 0;
	background: transparent;
	border: 0;
	box-shadow: none;
	color: inherit;
	font-size: 14px;
	font-weight: normal;
	letter-spacing: normal;
	text-transform: none;
	text-decoration: underline;
	cursor: pointer;
}

#nt-enquiry-form .nt-enquiry-message {
	display: none;
	margin-bottom: 22px;
}

/* departure dates in the calendar */
.ui-datepicker td.nt-available a {
	font-weight: 700;
}

/* ---------- international phone field ---------- */

#nt-enquiry-form .iti,
#tourmaster-enquiry-form .iti {
	display: block;
	width: 100%;
}

#nt-enquiry-form .iti input,
#tourmaster-enquiry-form .iti input {
	width: 100%;
}

/* the theme styles every <button> as a coloured button; the flag / dial code selector is one */
#nt-enquiry-form .iti button.iti__selected-country,
#nt-enquiry-form .iti button.iti__selected-country:hover,
#nt-enquiry-form .iti button.iti__selected-country:focus,
#tourmaster-enquiry-form .iti button.iti__selected-country,
#tourmaster-enquiry-form .iti button.iti__selected-country:hover,
#tourmaster-enquiry-form .iti button.iti__selected-country:focus {
	background: transparent;
	border: 0;
	box-shadow: none;
	color: inherit;
	margin: 0;
	padding: 0;
	font-size: inherit;
	font-weight: normal;
	letter-spacing: normal;
	text-transform: none;
	line-height: normal;
}

#nt-enquiry-form .iti .iti__selected-country-primary,
#tourmaster-enquiry-form .iti .iti__selected-country-primary {
	padding: 0 6px 0 14px;
}

#nt-enquiry-form .iti .iti__selected-dial-code,
#tourmaster-enquiry-form .iti .iti__selected-dial-code {
	color: inherit;
}

/* the country search box inside the dropdown should not look like a form field of the enquiry form */
#nt-enquiry-form .iti .iti__search-input,
#tourmaster-enquiry-form .iti .iti__search-input {
	width: 100%;
	margin: 0;
	border-radius: 0;
}

/* the "00000 00000" format hint should read as a hint, not as a typed number */
#nt-enquiry-form .iti input::placeholder,
#tourmaster-enquiry-form .iti input::placeholder,
#nt-enquiry-details .iti input::placeholder {
	color: #c4c4c4;
	opacity: 1;
}

/* above the theme's sticky header and Tour Master's form elements */
.iti__dropdown-content {
	z-index: 1000;
}

/* ---------- mobile "Book Now" panel (assets/js/enquiry-form.js, setupMobileSheet()) ---------- */

.nt-enquiry-sheet {
	position: fixed;
	inset: 0;
	z-index: 10000; /* above the theme's mobile header (9999) */
	display: flex;
	align-items: flex-end;
}

.nt-enquiry-sheet[hidden] {
	display: none;
}

.nt-enquiry-sheet__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.5);
}

.nt-enquiry-sheet__panel {
	position: relative;
	width: 100%;
	max-height: 92vh;
	max-height: 92dvh;
	overflow-y: auto;
	overscroll-behavior: contain;
	padding-bottom: env(safe-area-inset-bottom);
	background: var(--tt-white, #fff);
	border-radius: var(--tt-radius-lg, 16px) var(--tt-radius-lg, 16px) 0 0;
	animation: nt-enquiry-sheet-up 0.25s ease-out;
}

.nt-enquiry-sheet__panel:focus {
	outline: none;
}

@keyframes nt-enquiry-sheet-up {
	from { transform: translateY(100%); }
	to { transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
	.nt-enquiry-sheet__panel { animation: none; }
}

.nt-enquiry-sheet__head {
	position: sticky;
	top: 0;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 12px 12px var(--tt-space-5, 24px); /* title lines up with the form below */
	background: var(--tt-white, #fff);
	border-bottom: 1px solid var(--tt-lilac-tint, #efedf4);
}

.nt-enquiry-sheet__title {
	margin: 0;
	color: var(--tt-blue, #30418d);
	font-family: var(--tt-font-display, "EB Garamond", Georgia, serif);
	font-size: 22px;
	line-height: 28px;
	font-weight: 500;
}

/* the sidebar normally gives the form its side padding and full-width buttons; the panel does the same.
   body …: specific enough that no theme / Tour Master rule on the moved form wrapper can take the gutter away */
body .nt-enquiry-sheet .nt-enquiry-sheet__body {
	padding: 16px var(--tt-space-5, 24px) var(--tt-space-5, 24px);
}

body .nt-enquiry-sheet .nt-enquiry-sheet__body > * {
	margin-left: 0;
	margin-right: 0;
}

.nt-enquiry-sheet .nt-enquiry-form .tourmaster-button {
	width: 100%;
}

/* body .nt-enquiry-sheet …: the theme styles every <button> as a red filled button; this one is a plain icon */
body .nt-enquiry-sheet .nt-enquiry-sheet__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: none;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 0;
	border-radius: var(--tt-radius-sm, 4px);
	background: transparent;
	color: var(--tt-ink, #000);
	font-size: 32px;
	line-height: 1;
	cursor: pointer;
}

body .nt-enquiry-sheet .nt-enquiry-sheet__close:hover {
	background: var(--tt-lilac-tint, #efedf4);
	color: var(--tt-ink, #000);
}

/* the page behind stays put while the panel is open */
html.nt-enquiry-sheet-open,
html.nt-enquiry-sheet-open body {
	overflow: hidden;
}

/* the phone field's full-screen country list (mobile) opens above the panel */
.nt-enquiry-sheet-open .iti--detached-country-selector {
	z-index: 10010;
}

/* ---------- admin edit screen ---------- */

#nt-enquiry-details .iti {
	display: inline-block;
	vertical-align: middle;
	width: 25em;
	max-width: 100%;
}

#nt-enquiry-details .iti input {
	width: 100%;
}

#nt-enquiry-details .nt-field-error {
	color: #b32d2e;
	margin: 4px 0 0;
}
