/**
 * Byron Bay Property tenancy application.
 *
 * Monochrome to match the brand: near-black ink, grey supporting text,
 * Montserrat.
 *
 * A note on !important. This form is dropped into a site whose theme styles
 * every heading, button and input globally - uppercase, letter spacing, pink
 * borders, its own padding. Those rules out-specify ours inside our own
 * markup, so the properties a theme typically claims are asserted here. It is
 * deliberate and limited to those properties.
 */

.bta {
	--bta-ink: #151515;
	--bta-grey: #707070;
	--bta-line: #e4e4e4;
	--bta-wash: #f6f6f6;
	--bta-bad: #b3261e;
	--bta-max: 780px;

	max-width: var(--bta-max);
	margin: 0 auto;
	padding: 8px 20px 64px;
	color: var(--bta-ink);
	font-family: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
	box-sizing: border-box;
}

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

/* --------------------------------------------------------------- theme guard */

.bta h1,
.bta h2,
.bta h3,
.bta p,
.bta label,
.bta span,
.bta li,
.bta button,
.bta input,
.bta select,
.bta textarea,
.bta a {
	text-transform: none !important;
	letter-spacing: normal !important;
	font-family: inherit !important;
	text-shadow: none !important;
}

.bta button,
.bta input,
.bta select,
.bta textarea {
	margin: 0;
	text-align: left;
	min-height: 0;
	text-decoration: none;
	transform: none !important;
	background-image: none !important;
}

.bta button::after,
.bta button::before,
.bta .bta-step::after,
.bta .bta-step::before {
	content: none !important;
}

/* ------------------------------------------------------------------ header */

.bta-head {
	text-align: center;
	padding: 8px 0;
}

.bta .bta-title {
	margin: 0 0 12px;
	font-size: clamp(28px, 6vw, 40px);
	font-weight: 700;
	letter-spacing: -0.02em !important;
	line-height: 1.1;
	color: var(--bta-ink);
}

.bta .bta-sub {
	margin: 0 auto;
	max-width: 52ch;
	color: var(--bta-grey);
	font-size: 15px;
}

/* ------------------------------------------------------------------- steps */

.bta-steps {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	justify-content: center;
	margin: 32px 0 28px;
	padding: 0 0 24px;
	border-bottom: 1px solid var(--bta-line);
}

.bta .bta-step {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 7px 13px !important;
	border: 1px solid var(--bta-line) !important;
	border-radius: 100px !important;
	background-color: transparent !important;
	color: var(--bta-grey) !important;
	font-size: 12px !important;
	font-weight: 400 !important;
	line-height: 1.4 !important;
	width: auto !important;
	box-shadow: none !important;
	cursor: pointer;
	transition: border-color .15s, color .15s, background-color .15s;
}

.bta .bta-step:hover {
	border-color: var(--bta-ink) !important;
	color: var(--bta-ink) !important;
}

.bta .bta-step.is-active {
	background-color: var(--bta-ink) !important;
	border-color: var(--bta-ink) !important;
	color: #fff !important;
}

.bta .bta-step.is-done {
	border-color: var(--bta-ink) !important;
	color: var(--bta-ink) !important;
}

.bta .bta-step-n {
	font-weight: 700;
	font-size: 11px;
	opacity: .65;
}

.bta-progress {
	display: none;
	margin: 28px 0;
	padding: 0 0 22px;
	border-bottom: 1px solid var(--bta-line);
}

.bta-progress-bar {
	height: 3px;
	background: var(--bta-line);
	border-radius: 100px;
	overflow: hidden;
}

.bta-progress-bar span {
	display: block;
	height: 100%;
	background: var(--bta-ink);
	transition: width .3s ease;
}

.bta .bta-progress-t {
	margin: 10px 0 0;
	font-size: 12.5px;
	color: var(--bta-grey);
}

.bta .bta-progress-t strong {
	color: var(--bta-ink);
	font-weight: 600;
}

.bta .bta-progress-t strong::after {
	content: " \00b7";
	color: var(--bta-line);
}

@media (max-width: 639px) {
	.bta-steps { display: none; }
	.bta-progress { display: block; }
}

/* The theme prints the page title above the form, which would repeat ours. */
body.bta-page .entry-title,
body.bta-page .page-header,
body.bta-page header.entry-header {
	display: none !important;
}

/* ------------------------------------------------------------------ panels */

.bta-panel {
	display: none;
	animation: bta-in .28s ease;
}

.bta-panel.is-active {
	display: block;
}

@keyframes bta-in {
	from { opacity: 0; transform: translateY(6px); }
	to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
	.bta-panel { animation: none; }
	.bta-progress-bar span { transition: none; }
}

.bta .bta-h2 {
	margin: 0 0 6px;
	font-size: 25px;
	font-weight: 700;
	letter-spacing: -0.015em !important;
	line-height: 1.2;
	color: var(--bta-ink);
}

.bta .bta-h2:focus,
.bta .bta-h2:focus-visible {
	outline: none !important;
	border: 0 !important;
	box-shadow: none !important;
	background: none !important;
}

.bta .bta-h3 {
	margin: 0;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--bta-ink);
}

.bta .bta-intro {
	margin: 0 0 26px;
	color: var(--bta-grey);
	font-size: 14px;
	max-width: 58ch;
}

/* ------------------------------------------------------------------ fields */

.bta-grid {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 18px 16px;
}

.bta-fld { grid-column: span 6; min-width: 0; }

@media (min-width: 640px) {
	.bta-half  { grid-column: span 3; }
	.bta-third { grid-column: span 2; }
}

.bta .bta-label {
	display: block;
	margin: 0 0 6px;
	font-size: 12.5px;
	font-weight: 600;
	color: var(--bta-ink);
}

.bta .bta-req {
	color: var(--bta-grey);
	margin-left: 2px;
}

.bta .bta-input {
	display: block;
	width: 100% !important;
	max-width: 100%;
	padding: 11px 13px !important;
	border: 1px solid var(--bta-line) !important;
	border-radius: 2px !important;
	background-color: #fff !important;
	color: var(--bta-ink) !important;
	font-size: 15px !important;
	font-weight: 400 !important;
	line-height: 1.4 !important;
	box-shadow: none !important;
	transition: border-color .15s, box-shadow .15s;
	-webkit-appearance: none;
	appearance: none;
}

.bta select.bta-input {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='7' viewBox='0 0 11 7'%3E%3Cpath d='M1 1l4.5 4.5L10 1' fill='none' stroke='%23707070' stroke-width='1.4'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat;
	background-position: right 13px center;
	padding-right: 34px !important;
}

.bta .bta-input:focus {
	outline: none;
	border-color: var(--bta-ink) !important;
	box-shadow: 0 0 0 3px rgba(21, 21, 21, .08) !important;
}

.bta .bta-input.is-bad {
	border-color: var(--bta-bad) !important;
}

.bta textarea.bta-input {
	resize: vertical;
	min-height: 130px;
}

.bta .bta-help {
	margin: 6px 0 0;
	font-size: 12.5px;
	color: var(--bta-grey);
	line-height: 1.45;
}

.bta-money {
	position: relative;
	display: flex;
	align-items: center;
}

.bta-money > span {
	position: absolute;
	left: 13px;
	color: var(--bta-grey);
	font-size: 15px;
	pointer-events: none;
	z-index: 1;
}

.bta-money .bta-input {
	padding-left: 26px !important;
}

/* ----------------------------------------------------------------- choices */

.bta-radios {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.bta .bta-choice {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	margin: 0;
	padding: 10px 15px !important;
	border: 1px solid var(--bta-line) !important;
	border-radius: 2px !important;
	background-color: #fff !important;
	color: var(--bta-ink) !important;
	font-size: 14px !important;
	font-weight: 400 !important;
	line-height: 1.35;
	cursor: pointer;
	transition: border-color .15s, background-color .15s;
}

.bta .bta-choice:hover { border-color: var(--bta-grey) !important; }

.bta .bta-choice:has(input:checked) {
	border-color: var(--bta-ink) !important;
	background-color: var(--bta-wash) !important;
}

.bta .bta-choice input[type="checkbox"],
.bta .bta-choice input[type="radio"] {
	-webkit-appearance: none !important;
	appearance: none !important;

	/* The theme hides checkboxes with the screen-reader-only pattern
	   (position:absolute; clip:rect(0,0,0,0)), which erases ours no matter how
	   they are painted. Put them back in the layout explicitly. */
	position: static !important;
	clip: auto !important;
	clip-path: none !important;
	pointer-events: auto !important;
	opacity: 1 !important;
	visibility: visible !important;
	overflow: visible !important;
	left: auto !important;
	top: auto !important;
	transform: none !important;

	flex: none;
	width: 18px !important;
	height: 18px !important;
	min-width: 18px;
	min-height: 0;
	margin: 0;
	padding: 0 !important;
	border: 1px solid var(--bta-grey) !important;
	background-color: #fff !important;
	background-image: none !important;
	background-repeat: no-repeat;
	background-position: center;
	box-shadow: none !important;
	cursor: pointer;
	transition: background-color .12s, border-color .12s;
}

.bta .bta-choice input[type="checkbox"] { border-radius: 3px !important; }
.bta .bta-choice input[type="radio"] { border-radius: 50% !important; }

.bta .bta-choice input[type="checkbox"]:checked,
.bta .bta-choice input[type="radio"]:checked {
	background-color: var(--bta-ink) !important;
	border-color: var(--bta-ink) !important;
}

.bta .bta-choice input[type="checkbox"]:checked {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10' viewBox='0 0 12 10'%3E%3Cpath d='M1 5l3.4 3.4L11 1.6' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
	background-size: 11px 9px;
}

.bta .bta-choice input[type="radio"]:checked {
	box-shadow: inset 0 0 0 3px #fff !important;
}

.bta .bta-choice input:focus-visible {
	outline: 2px solid var(--bta-ink) !important;
	outline-offset: 2px;
}

.bta .bta-choice-block {
	display: flex;
	width: 100%;
	align-items: flex-start;
	padding: 14px 16px !important;
}

.bta .bta-choice-block input { margin-top: 1px; }

/* --------------------------------------------------------------- repeaters */

.bta-rep-row {
	padding: 22px 0 4px;
	border-top: 1px solid var(--bta-line);
}

.bta-rep > .bta-rep-row:first-child {
	border-top: none;
	padding-top: 0;
}

.bta-rep-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin: 0 0 16px;
}

.bta .bta-rep-del,
.bta .bta-add {
	display: inline-block;
	width: auto !important;
	background: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	padding: 0 !important;
	font-size: 12.5px !important;
	font-weight: 400 !important;
	color: var(--bta-grey) !important;
	text-decoration: underline;
	text-underline-offset: 3px;
	box-shadow: none !important;
	cursor: pointer;
}

.bta .bta-rep-del:hover,
.bta .bta-add:hover { color: var(--bta-ink) !important; }

.bta .bta-add {
	margin-top: 20px;
	font-weight: 600 !important;
	color: var(--bta-ink) !important;
}

.bta-group {
	padding: 20px;
	background: var(--bta-wash);
	border-radius: 3px;
}

.bta-rep-inline .bta-rep-row {
	padding: 16px 0 0;
}

.bta-rep-inline .bta-rep-row:first-child {
	border-top: none;
	padding-top: 12px;
}

.bta-rep-inline .bta-rep-del { margin-top: 10px; }

/* ------------------------------------------------------------------- files */

.bta .bta-file {
	padding: 10px 13px !important;
	cursor: pointer;
	font-size: 14px !important;
}

.bta .bta-file::file-selector-button {
	margin-right: 12px;
	padding: 7px 14px;
	border: 1px solid var(--bta-line);
	border-radius: 2px;
	background: var(--bta-wash);
	color: var(--bta-ink);
	font: inherit;
	font-size: 13px;
	cursor: pointer;
}

.bta .bta-filelist {
	list-style: none;
	margin: 10px 0 0;
	padding: 0;
	font-size: 12.5px;
	color: var(--bta-grey);
}

.bta .bta-filelist li {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 14px;
	padding: 6px 0;
	margin: 0;
	border-bottom: 1px solid var(--bta-line);
}

.bta .bta-filelist li.is-bad { color: var(--bta-bad); }

.bta .bta-file-name {
	min-width: 0;
	overflow-wrap: anywhere;
}

.bta .bta-file-del {
	flex: none;
	width: auto !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: none !important;
	color: var(--bta-grey) !important;
	font-size: 12px !important;
	font-weight: 400 !important;
	text-decoration: underline;
	text-underline-offset: 3px;
	box-shadow: none !important;
	cursor: pointer;
}

.bta .bta-file-del:hover { color: var(--bta-ink) !important; }

.bta .bta-filelist li.bta-file-hint {
	border-bottom: 0;
	padding-top: 8px;
	color: var(--bta-grey);
	font-size: 12px;
}

/* ----------------------------------------------------------------- summary */

.bta-summary {
	display: flex;
	flex-wrap: wrap;
	gap: 28px;
	margin: 28px 0 0;
	padding: 22px 24px;
	background: var(--bta-wash);
	border-radius: 3px;
}

.bta .bta-summary-n {
	display: block;
	font-size: 26px;
	font-weight: 700;
	letter-spacing: -0.02em !important;
	line-height: 1.1;
	color: var(--bta-ink);
}

.bta .bta-summary-l {
	display: block;
	margin-top: 3px;
	font-size: 12px;
	color: var(--bta-grey);
}

/* -------------------------------------------------------------- navigation */

.bta-nav {
	display: flex;
	gap: 10px;
	align-items: center;
	margin: 38px 0 0;
	padding-top: 26px;
	border-top: 1px solid var(--bta-line);
}

.bta .bta-btn {
	display: inline-block;
	width: auto !important;
	padding: 13px 28px !important;
	border: 1px solid var(--bta-ink) !important;
	border-radius: 2px !important;
	background-color: var(--bta-ink) !important;
	color: #fff !important;
	font-size: 14px !important;
	font-weight: 600 !important;
	line-height: 1.4 !important;
	text-align: center;
	text-decoration: none !important;
	box-shadow: none !important;
	cursor: pointer;
	transition: opacity .15s;
}

.bta .bta-btn:hover { opacity: .85; }

.bta .bta-btn-ghost {
	background-color: transparent !important;
	color: var(--bta-ink) !important;
	border-color: var(--bta-line) !important;
	order: -1;
}

.bta .bta-btn-ghost:hover { border-color: var(--bta-ink) !important; }

.bta .bta-btn-go { margin-left: auto; }

.bta .bta-btn[disabled] { opacity: .45; cursor: progress; }

.bta .bta-btn.is-sending {
	display: inline-flex !important;
	align-items: center;
	gap: 10px;
	opacity: 1 !important;
	background-color: var(--bta-ink) !important;
	color: #fff !important;
	cursor: progress;
}

.bta .bta-spinner {
	flex: none;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, .35);
	border-top-color: #fff;
	border-radius: 50%;
	animation: bta-spin .7s linear infinite;
}

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

.bta .bta-sending-note {
	margin: 14px 0 0;
	font-size: 12.5px;
	line-height: 1.5;
	color: var(--bta-grey);
	text-align: right;
}

@media (prefers-reduced-motion: reduce) {
	.bta .bta-spinner {
		animation: bta-pulse 1.4s ease-in-out infinite;
	}

	@keyframes bta-pulse {
		0%, 100% { opacity: 1; }
		50% { opacity: .35; }
	}
}

/* ------------------------------------------------------------------ dialog */

.bta-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(21, 21, 21, .55);
}

.bta-modal[hidden] { display: none !important; }

.bta-modal-box {
	width: 100%;
	max-width: 460px;
	max-height: 90vh;
	overflow-y: auto;
	padding: 30px;
	background: #fff;
	border-radius: 3px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, .22);
}

.bta .bta-modal-title {
	margin: 0 0 12px;
	font-size: 19px;
	font-weight: 700;
	letter-spacing: -0.01em !important;
	line-height: 1.25;
	color: var(--bta-ink);
}

.bta .bta-modal-lead {
	margin: 0 0 14px;
	font-size: 14px;
	font-weight: 600;
	color: var(--bta-ink);
	overflow-wrap: anywhere;
}

.bta .bta-modal-note {
	margin: 0 0 14px;
	font-size: 13px;
	line-height: 1.55;
	color: var(--bta-grey);
}

.bta .bta-modal-note strong { color: var(--bta-ink); }

.bta .bta-modal-box .bta-btn { margin-top: 6px; }

/* ------------------------------------------------------------- misc states */

.bta-alert {
	margin: 0 0 28px;
	padding: 18px 22px;
	border: 1px solid var(--bta-bad);
	border-left-width: 3px;
	border-radius: 2px;
	background: #fdf6f5;
	font-size: 14px;
}

.bta-alert ul { margin: 8px 0 0; padding-left: 18px; }
.bta-alert li { margin: 3px 0; }

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

.bta .bta-fine {
	margin: 24px 0 0;
	font-size: 12.5px;
	color: var(--bta-grey);
}

.bta .bta-foot {
	margin: 40px 0 0;
	padding-top: 22px;
	border-top: 1px solid var(--bta-line);
	text-align: center;
	font-size: 12.5px;
	color: var(--bta-grey);
}

.bta-done { text-align: center; padding-top: 24px; }
.bta-done .bta-sub { margin-bottom: 18px; }

.bta .bta-ref {
	display: inline-block;
	margin: 6px 0 20px;
	padding: 10px 20px;
	background: var(--bta-wash);
	border-radius: 2px;
	font-size: 14px;
	letter-spacing: .04em !important;
}

/* Our component rules set `display`, which beats the browser's own
   [hidden] { display: none }. Restore it for everything inside the form. */
.bta [hidden],
.bta-modal[hidden] { display: none !important; }
