/**
 * Form CSS
 *
 * For styling the front-end registration form.
 *
 * @package     Restrict Content Pro
 * @subpackage  CSS/Forms
 * @copyright   Copyright (c) 2017, Restrict Content Pro
 * @license     http://opensource.org/licenses/gpl-2.0.php GNU Public License
 */

/* General Form Layout
-------------------------------------------------------------- */

#rcp_registration_form {
	padding: 5px;
}

.rcp_form fieldset {
	border: none;
	margin: 0;
	padding: 0;
}

.rcp_form label {
	display: block;
	cursor: pointer;
}

.rcp_form .rcp_gateway_option_label {
	display: inline-block;
	margin-right: 10px;
}

.rcp_form input.required {
	color: #000;
}

.rcp_form p {
	margin: 0 0 10px;
	min-height: 20px;
}

.rcp_form p br {
	display: none; /* fix for stupid theme's that mess with wpautop */
}

.rcp_form ul {
	margin: 0 0 15px;
	padding: 0;
}

.rcp_form li {
	list-style: none;
	margin: 0 0 15px;
}

.rcp_form #rcp_auto_renew_wrap {
	min-height: 30px;
}

.rcp_subscription_level label {
	width: auto;
	display: inline-block;
}

.rcp_subscription_level .rcp_level {
	float: left;
	margin: 5px 10px 0 0;
}

.rcp_message {
	margin: 0 0 15px;
}

.rcp_level_description {
	border-left: 1px solid #f0f0f0;
	padding-left: 8px;
	font-size: 12px;
}

.rcp_discount_valid {
	color: #42961e;
}

.rcp_discount_invalid {
	color: #b01000;
}

.rcp_current_cards_fieldset span {
	display: block;
}
div#rcp_card_name_wrap, div#rcp_card_wrap {
	margin-bottom: 10px;
}

.rcp-total td,
.rcp-recurring-total td {
	border-top: none;
}

#order_summary .rcp-ppe-confirm-price {
	text-align: right;
	width: 70px;
}
#order_summary tfoot th {
	text-align: right;
}

#rcp-sandbox-gateway-test-cards {
	background: #f4f4f4;
	margin: 0 0 1.5em;
	padding: 1em;
}

/* Input Fields
-------------------------------------------------------------- */

.rcp_form input[type="text"], .rcp_form input[type="password"],
.rcp_form input[type="email"] {
	padding: 4px 8px;
	margin: 0;
}

.rcp_form input[type="checkbox"] {
	float: left;
	margin: 7px 8px 0 0;
}

.rcp_form input[type="text"]:focus,
.rcp_form input[type="password"]:focus,
.rcp_form input[type="email"]:focus {
	border-color: #aaa;
}

.rcp_form input.error,
.rcp_form input[type="text"]:focus.error,
.rcp_form input[type="password"]:focus.error,
.rcp_form input[type="email"]:focus.error {
	border-color: #ffa5a5;
	-moz-box-shadow: 0 0 3px #ffbfbf;
	-webkit-box-shadow: 0 0 3px #ffbfbf;
	box-shadow: 0 0 3px #ffbfbf;
}

/* Error and Success Messages
-------------------------------------------------------------- */

p.rcp_error {
	-webkit-border-radius: 3px;
	-moz-border-radius: 3px;
	border-radius: 3px;
	border: 1px solid #c00;
	margin: 0 0 10px;
	padding: 4px;
	background: #ffebe8;
	color: #333;
}

p.rcp_success span, p.rcp_error span {
	margin: 0 !important;
	padding: 10px;
}

p.rcp_success {
	-webkit-border-radius: 3px;
	-moz-border-radius: 3px;
	border-radius: 3px;
	border: 1px solid #E6DB55;
	margin: 0 0 10px;
	padding: 4px;
	background: #FFFFE0;
	color: #333;
}

/* Responsive Tables on Small Screens
-------------------------------------------------------------- */

@media only screen and (max-width: 480px) {
	.rcp-table {
		overflow: hidden;
		width: 100%;
	}

	.rcp-table th {
		display: none;
	}

	.rcp-table tr td {
		display: block;
		text-align: left;
		padding-left: 50%;
	}

	.rcp-table td:first-child {
		padding-top: .5em;
	}

	.rcp-table td:last-child {
		padding-bottom: .5em;
	}

	.rcp-table td:before {
		content: attr(data-th) ": ";
		font-weight: bold;
		display: inline-block;
		height: 100%;
		line-height: 100%;
		width: 100%;
		margin-left: -100%;
	}

	.rcp-table td:first-child {
		background-color: rgba(0, 0, 0, 0.1);
	}

	#order_summary .rcp-ppe-confirm-price {
		text-align: left;
		width: auto;
	}
}

/* Stripe Elements
-------------------------------------------------------------- */

.StripeElement--focus {
	border-color: #aaa;
}

.StripeElement--invalid {
	border-color: #b01000;
}

.StripeElement--webkit-autofill {
	background-color: #fefde5 !important;
}

#rcp-card-element-errors:not(:empty) {
	margin-top: 10px;
}

/* Stripe Checkout Modal
-------------------------------------------------------------- */

.rcp-modal-wrapper {
	display: none;
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	background: rgba( 0, 0, 0, .6 );
	z-index: 999;
	padding: 5% 0 0;
	overflow-y: scroll;
	transition: display 0.5s ease;
	-webkit-transition: display 0.5s ease;
	-moz-transition: display 0.5s ease;
}

.rcp-register-form-modal-wrapper {
	z-index: 1999 !important; /* On top of blockUI */
}

.rcp-modal {
	background: #f5f5f7;
	box-shadow: 0 12px 30px 0 rgba(0,0,0,.5), inset 0 1px 0 0 hsla(0,0%,100%,.65);
	margin: 0 auto;
	border-radius: 6px;
	padding: 0;
	position: relative;
	max-width: 450px;
}

.rcp-modal-inner {
	padding: 0 0 36px;
}

.rcp-modal-header {
	background: #e8e9eb;
	border-top-left-radius: 6px;
	border-top-right-radius: 6px;
	padding: 12px 36px;
	position: relative;
	text-align: center;
}

.rcp-modal-close {
	background: #b7b7b7;
	border-radius: 50%;
	color: white;
	cursor: pointer;
	font-size: 20px;
	font-weight: bold;
	line-height: 25px;
	height: 25px;
	width: 25px;
	position: absolute;
	top: 6px;
	right: 6px;
	text-align: center;
}

.rcp-modal-membership-name {
	font-weight: bold;
}

.rcp-modal-body {
	margin: 20px 36px 0;
}

.rcp-modal-body input[type="text"] {
	display: block;
	width: 100%;
}

.rcp-modal #rcp_card_wrap label {
	display: none;
}

.rcp-modal-submit {
	display: block;
	text-align: center;
	width: 100%;
}
