input,
select,
textarea {
	background-color: #fff;
	line-height: 1.4;
    padding: .5em;
	border: 1px solid #E2E4E9;
	border-radius: 4px;
	max-width: 100%;
}

textarea {
	min-width: 8em;
	min-height: 3em;
}

form input[type="submit"] {
    display: block;
    margin: 2em auto;
}

input:hover, 
select:hover, 
textarea:hover {
    box-shadow: 0 0 0 1px #E2E4E9;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #6B98F2;
    box-shadow: 0 0 0 1px #6B98F2;
}

input:not(:placeholder-shown):invalid,
select:invalid,
textarea:not(:placeholder-shown):invalid,
.error_val,
input.error_val,
select.error_val,
textarea.error_val {
	background-color: #fff;
	border-color: #F56166;
	box-shadow: 0 0 0 1px #F56166;
}

input[type="date"],
input[type="time"] {
    -webkit-appearance: textfield;
    -moz-appearance: textfield;
}

input[type="file"] {
    cursor: pointer;
}

input[type="file"]::-webkit-file-upload-button {
    background-color: transparent;
    border: 1px solid #E2E4E9;
    border-radius: 4px;
    padding: .25em .5em;
}

input[type="file"]:hover::-webkit-file-upload-button {
    box-shadow: 0 0 0 1px #E2E4E9;
}

input[type="file"]:focus::-webkit-file-upload-button {
    border-color: #6B98F2;
    box-shadow: 0 0 0 1px #6B98F2;
}

form button[type="submit"] {
    display: block;
    margin: .5em auto;
}

.floating-label {
	display: block;
    position: relative;
    padding-top: 1em;
}

.floating-label input,
.floating-label textarea,
.new_patient_form input[type="text"],
.new_patient_form input[type="tel"],
.new_patient_form input[type="email"],
.new_patient_form input[type="date"],
.new_patient_form select,
.new_patient_form textarea {
	display: block;
	width: 100%;
}

.floating-label input + span,
.floating-label textarea + span {
    position: absolute;
    left: .5em;
    top: .25em;
    font-size: .9em;
    line-height: 1;
    background-color: #fff;
	color: #2B303A;
    padding: 4px;
	opacity: 1;
    transform: translateY(0) scale(.9);
	transition: opacity .2s, transform .2s;
	pointer-events: none;
}

.floating-label input:placeholder-shown + span,
.floating-label textarea:placeholder-shown + span {
	opacity: .8;
	transform: translateY(1.5em) scale(1);
}

.floating-label input:focus + span,
.floating-label textarea:focus + span {
	color: #6B98F2;
	opacity: 1;
    transform: translateY(0) scale(.9);
}

.floating-label input:focus:invalid + span,
.floating-label textarea:focus:invalid + span {
	color: #3F4656;
}

::-webkit-input-placeholder {color: #B3B9C2;}
::-moz-placeholder {color: #B3B9C2;}
:-ms-input-placeholder {color: #B3B9C2;}
:-moz-placeholder {color: #B3B9C2;}
::placeholder {color: #B3B9C2;}
.floating-label ::-webkit-input-placeholder {opacity: 0;}
.floating-label ::-moz-placeholder {opacity: 0;}
.floating-label :-moz-placeholder {opacity: 0;}
.floating-label ::placeholder {opacity: 0;}
.floating-label :focus::-webkit-input-placeholder {opacity: 1;}
.floating-label :focus::-moz-placeholder {opacity: 1;}
.floating-label :focus:-ms-input-placeholder {opacity: 1;}
.floating-label :focus:-moz-placeholder {opacity: 1;}
.floating-label :focus::placeholder {opacity: 1;}


@supports (-webkit-appearance: none) or (-moz-appearance: none) {
	input[type="checkbox"],
	input[type="radio"] {
		-moz-appearance: none;
		-webkit-appearance: none;
		appearance: none;
		box-sizing: border-box;
		display: inline-block;
		width: 1em;
		height: 1em;
		border: 2px solid #C4C4C4;
		background-color: #fff;
		background-color: rgba(255,255,255,0);
		background-position: center center;
		background-repeat: no-repeat;
		box-shadow: none;
		margin-right: .5em;
		cursor: pointer;
		transition: all .2s;
	}

	input[type="checkbox"] {
		border-radius: 2px;
		background-size: contain;
	}

	input[type="radio"] {
		border-radius: 100%;
		background-size: 1em;
	}

	input[type="checkbox"]:checked {
		background-color: #6B98F2;
		background-image: url(../../../../images/check.svg);
		border-color: #6B98F2;
	} 
	
	input[type="radio"]:checked {
		background-color: transparent;
		background-image: url(../../../../images/radio.svg);
		border-color: #6B98F2;
	} 

	.checkbox-label,
	.radio-label,
	.switch-label {
		position: relative;
		padding: .5em;
		margin: .5em 0;
		display: flex;
		align-items: center;
	}

	.checkbox-label input[type="checkbox"],
	.radio-label input[type="radio"],
	.switch-label input[type="checkbox"] {
		position: relative;
		z-index: 2;
		display: inline-block;
		flex: 0 0 1em;
	}
	
	.switch-label input[type="checkbox"] {
		flex: 0 0 2em;
	}
	
	.checkbox-label input + label[for],
	.radio-label input + label[for],
	.switch-label input + label[for] {
		cursor: pointer
	}

	.checkbox-label input[type="checkbox"] + span::after,
	.radio-label input[type="radio"] + span::after,
	.switch-label input[type="checkbox"] + span::after {
		content: "";
		box-sizing: border-box;
		width: 2em;
		height: 2em;
		position: absolute;
		left: 0;
		top: 50%;
		transform: translateY(-50%);
		z-index: 1;
		border-radius: 50%;
		background-color: #fff;
		opacity: 0;
		transition: all .2s;
	}

	.checkbox-label input[type="checkbox"]:hover + span::after,
	.checkbox-label input[type="checkbox"] + span:hover::after,
	.radio-label input[type="radio"]:hover + span::after,
	.radio-label input[type="radio"] + span:hover::after,
	.switch-label input[type="checkbox"]:hover + span::after,
	.switch-label input[type="checkbox"] + span:hover::after {
		opacity: .5;
	}

	.checkbox-label input[type="checkbox"]:hover:checked + span::after,
	.checkbox-label input[type="checkbox"]:checked + span:hover::after,
	.radio-label input[type="radio"]:hover:checked + span::after,
	.radio-label input[type="radio"]:checked + span:hover::after,
	.switch-label input[type="checkbox"]:hover:checked + span::after,
	.switch-label input[type="checkbox"]:checked + span:hover::after {
		background-color: rgba(81, 164, 234, 0.2);
		opacity: 1;
	}

	.checkbox-label input[type="checkbox"]:focus + span::after,
	.radio-label input[type="radio"]:focus + span::after,
	.switch-label input[type="checkbox"]:focus + span::after {
		background-color: rgba(81, 164, 234, 0.3);
		opacity: 1;
	}

	.switch-label input[type="checkbox"] {
		width: 2em;
		height: .8em;
		border: none;
		background-color: #D4D9E0;
		border-radius: .5em;
	}

	.switch-label input[type="checkbox"]:checked {
		background-color: #B8DBF8;
		background-image: none;
	}

	.switch-label input[type="checkbox"] + span::before {
		content: "";
		box-sizing: border-box;
		display: inline-block;
		width: 1.1em;
		height: 1.1em;
		position: absolute;
		top: 50%;
		transform: translateY(-50%);
		left: .45em;
		z-index: 3;
		background-color: #fff;
		background-position: center center;
		background-repeat: no-repeat;
		border-radius: 50%;
		box-shadow: 0px 2px 2px rgba(0, 0, 0, 0.24), 0px 0px 2px rgba(0, 0, 0, 0.12);
		cursor: pointer;
		transition: all .2s;
	} 

	.switch-label input[type="checkbox"]:checked + span::before {
		left: 1.45em;
		background-color: #6B98F2;
		border-color: #6B98F2;
	} 

	.switch-label input[type="checkbox"]:checked + span::after {
		left: 1em;
	}
	
	form[id^="bs"] > div {
		display: flex;
		flex-direction: column;
	}

	.switch-label {
		align-self: center;
	}
}

form .row {
    margin-left: -.5em;
    margin-right: -.5em;
}

form .row > div[class*="col"] {
    padding: 0 .5em;
}

/* Appointment request form update */

.preferred-contact .radio-row {
    justify-content: flex-start;
    border-bottom: 1px solid #E2E4E9;
}
.preferred-contact .radio-label {
    position: relative;
	padding: 4px 8px 0;
    margin-bottom: 0;
}
.preferred-contact .radio-label.hidden {
    display: none;
}
.preferred-contact .radio-label.hidden + .radio-label + .radio-label {
    order: -1;
}
.preferred-contact input[type="radio"] {
    background-image: none;
    height: 100%;
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 0;
    border-width: 1px;
    border-color: transparent;
	border-bottom: 2px solid transparent;
}

.preferred-contact input[type="radio"]:checked {
    border-bottom: 2px solid #6b98f2;
}

.preferred-contact input[type="radio"]:checked + span {
    color: #2D3748;
}

.preferred-contact input[type="radio"] + span::after {
    display: none;
}

.optional-message {
    text-align: center;
	margin: 1em 0;
}

.optional-message input[type="checkbox"] {
	background-color: #6B98F2;
    background-image: url(../../../../images/plus.svg);
	background-size: 12px auto;
	border-color: #6B98F2;
	margin-right: 0.5em;
	cursor: pointer;
}

.optional-message input[type="checkbox"] + label {
	cursor: pointer;
}

.optional-message input[type="checkbox"]:checked {
	background-color: #fff;
    background-image: url(../../../../images/minus.svg);
	border-color: #C4C4C4;
}

.optional-message .floating-label {
    height: 1em;
    opacity: 0;
    transition: opacity .2s;
	overflow: hidden;
}

.optional-message .floating-label textarea {
	max-height: 4em;
}

.optional-message input:checked ~ .floating-label {
    height: 5em;
    opacity: 1;
	overflow: visible;
}

.appointment-form > div > .current-patient {
    display: none;
}

/* Patient forms */
.radio-row {
    display: flex;
    flex-wrap: wrap;
	justify-content: center;
	align-items: center;
}

.radio-row .radio-label {
    margin-right: 1em;
}

.select-row {
	display: block;
    margin-top: 1em;
}

.select-row select {
    display: block;
    width: 100%;
}

.form-group > .radio-row,
.form-group > .row {
    display: flex;
    flex-direction: column-reverse;
    align-items: flex-start;
	margin: 0;
}

form [class*="lefty"] {
    display: flex;
    flex-wrap: wrap;
}

form [class*="lefty"] .radio-label {
    margin: 0;
}

/*input[type="radio"].val:indeterminate {
    border-color: #F56166;
}*/

/* Form JS features */
.bp-submit-wrap {
    display: flex;
    flex-direction: column;
}
.bp-submit-wrap button[type="submit"] {
	display: flex;
	align-items: center;
}
.honey,
.hidden-fields .magnet {
	display: none !important;
}
form .magnet,
form .magnet input {
	font-size: 0;
	line-height: 0;
	width: 0;
    height: 0;
    padding: 0;
    border: 0;
	margin: 0;
	opacity: 0;
}

.response_success,
.response_failure,
.success,
.failure {
	display: none;
	text-align: center;
	padding: .5em 1em;
	margin: 1em auto;
	background-color: #333;
}

.form_success .success {
	display: block;
	color: #11322A;
	border: 2px solid #3DB9A0;
	background-color: #F5FFFF;
}

.form_success .success .catch-primary-btn {
	display: block;
	max-width: max-content;
	margin: .5em auto;
}

.form_failure .failure {
	display: block;
	color: #210B0A;
	border: 2px solid #F56166;
	background-color: #fffafa;
}

@keyframes submitting {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(360deg);
	}
}
form button[type="submit"]::before {
    content: "";
    width: 0px;
    height: 0px;
    display: inline-block;
    vertical-align: middle;
    margin-right: 0px;
	background-color: #fff;
	background-size: contain;
	background-repeat: no-repeat;
	background-position: center center;
	border-radius: 100%;
    transition: all .2s;
}
.form_submitting button[type="submit"],
.form_success button[type="submit"] {
    pointer-events: none;
}
.form_failure button[type="submit"] {
	pointer-events: all;
}
.form_submitting button[type="submit"]::before,
.form_success button[type="submit"]::before,
.form_failure button[type="submit"]::before {
	box-sizing: border-box;
	border: 2px solid #fff;
    width: 24px;
    height: 24px;
    margin-right: .5em;
    background-image: url(../../../../images/loading-icon.svg);
	animation: submitting 2s linear infinite;
}
.form_success button[type="submit"]::before,
.form_failure button[type="submit"]::before {
	animation: none;
}
.form_success button[type="submit"]::before {
	background-color: #fff;
	background-image: url(../../../../images/success-icon.svg);
}
.form_failure button[type="submit"]::before {
	background-color: #fff;
	background-image: url(../../../../images/failure-icon.svg);
}


.page-form-confirm {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
}
.page-form-confirm > p {
	width: 100%;
}
.page-form-confirm > div {
	font-size: 16px;
    line-height: 1.5;
    padding: 8px 16px;
    border-width: 1px;
    border-style: solid;
    border-radius: 4px; 
	cursor: pointer;
}
.form_success .page-form-confirm {
	display: none;
}
.catch-primary-btn,
.catch-primary-btn:visited {
    border-color: #6B98F2;
    background-color: #6B98F2;
    color: #fff;
}
.catch-primary-btn:hover {
    border-color: #5F8AE1;
    background-color: #5F8AE1;
}
.catch-secondary-btn {
    border-color: #E2E7F0;
    background-color: #fff;
    color: #2D3748;
}
.catch-secondary-btn:hover {
    border-color: #CBD5E0;
    background-color: #F2F5F7;
}

.states-select {
	margin: 1em 0;
}
.states-select select {
	display: block;
	width: 100%;
}