/*
 * Annual pass signup (page-templates/annual-pass-signup.php), "All-Access Create Account" design:
 * short navy hero, a card with "Your order" beside the account form, support strip. Same layout as
 * myLawCLE's, in the Federal Bar colours and Lora. Loaded on that page only.
 *
 * The plan shown follows the form state with :has(): .ap-if-premium shows when the Premium plan
 * or the Premium add-on is chosen, .ap-if-basic otherwise.
 */

/* No white band above the footer on tall screens */
.mylaw-annual-pass-signup .site-main {
	background: #f2f4f7;
}

.ap-create {
	--ap-navy: #002868;
	--ap-ink: #002868;
	--ap-muted: #4e6288;
	--ap-pale: #99a9c3;
	--ap-ring: #a4b2cb;
	--ap-border: #ccd4e1;
	--ap-line: #e2e6ee;
	--ap-page: #f2f4f7;
	--ap-aside: #f6f7fa;
	--ap-chosen: #eef1f7;
	--ap-gold: #fcb514;
	--ap-gold-hover: #fdc443;
	--ap-gold-text: #8a6300; /* gold dark enough for text on white */
	--ap-sans: "Lora", Georgia, "Times New Roman", serif;
	--ap-serif: "Lora", Georgia, "Times New Roman", serif;

	background: var(--ap-page);
	color: var(--ap-navy);
	font-family: var(--ap-sans);
	font-size: 14px;
	line-height: 1.35;
	-webkit-font-smoothing: antialiased;
}

.ap-create a {
	color: var(--ap-navy);
	text-decoration: none;
}

.ap-create a:hover {
	color: var(--ap-gold-text);
}

.ap-create p {
	margin: 0;
}

/* Plan shown: basic unless the Premium plan or add-on is chosen */
.ap-create:is(:has(#ap-plan-premium:checked), :has(#ap-addon:checked)) .ap-if-basic,
.ap-create:not(:has(#ap-plan-premium:checked)):not(:has(#ap-addon:checked)) .ap-if-premium {
	display: none !important;
}

/* Hero */

.ap-create__hero {
	padding: 30px 20px 0;
	background: var(--ap-navy);
	text-align: center;
}

.ap-create .ap-create__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: var(--ap-pale);
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.ap-create__eyebrow-dot {
	width: 7px;
	height: 7px;
	background: var(--ap-gold);
}

.ap-create .ap-create__title {
	margin: 12px 0 0;
	padding-bottom: 26px;
	color: #fff;
	font-family: var(--ap-serif);
	font-size: clamp(30px, 3.6vw, 44px);
	font-weight: 400;
	line-height: 1.1;
}

/* Card: the navy runs 44px behind its top */

.ap-create__shell {
	padding: 0 20px 28px;
	background: linear-gradient(var(--ap-navy) 0 44px, var(--ap-page) 44px);
}

.ap-create__card {
	display: flex;
	flex-wrap: wrap;
	max-width: 960px;
	margin: 0 auto;
	background: #fff;
	box-shadow: 0 2px 10px rgba(0, 40, 104, 0.12);
}

.ap-create .ap-create__heading {
	font-size: 12.5px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.ap-create__label {
	color: var(--ap-muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.ap-create__text-btn {
	padding: 0;
	color: var(--ap-muted);
	font-size: 12.5px;
	font-weight: 500;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

.ap-create__text-btn:hover {
	color: var(--ap-navy);
}

/* Your order */

.ap-create__order {
	display: flex;
	flex: 0 1 340px;
	flex-direction: column;
	gap: 18px;
	min-width: min(100%, 280px);
	padding: 28px 26px;
	border-right: 1px solid var(--ap-line);
	background: var(--ap-aside);
}

.ap-create .ap-create__back {
	align-self: flex-start;
	margin: -8px 0 -6px;
	color: var(--ap-muted);
	font-size: 12.5px;
	font-weight: 500;
}

.ap-create .ap-create__back:hover {
	color: var(--ap-navy);
}

/* "Change" / "Done" open and close the picker (compact layout) */
.ap-create__toggle {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: 0;
	opacity: 0;
	pointer-events: none;
}

.ap-create__toggle:checked ~ .ap-create__chosen,
.ap-create__toggle:not(:checked) ~ .ap-create__picker {
	display: none;
}

.ap-create__toggle:focus-visible ~ .ap-create__chosen .ap-create__text-btn,
.ap-create__toggle:focus-visible ~ .ap-create__picker .ap-create__text-btn {
	outline: 2px solid var(--ap-navy);
	outline-offset: 2px;
}

.ap-create__chosen {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--ap-border);
}

/* No Premium add-on between the plan and the order lines: one rule, not two */
.ap-create__chosen:has(+ .ap-create__totals) {
	padding-bottom: 0;
	border-bottom: 0;
}

.ap-create__chosen-text {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.ap-create__chosen-plan {
	font-size: 16px;
	font-weight: 600;
}

.ap-create .ap-create__picker-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 10px;
}

.ap-create__plans {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.ap-create__plan {
	position: relative;
	display: grid;
	grid-template-columns: 18px minmax(0, 1fr) auto;
	align-items: center;
	gap: 10px;
	padding: 12px 14px;
	border: 1px solid var(--ap-border);
	background: #fff;
	cursor: pointer;
}

.ap-create__plan:has(.ap-create__radio:checked) {
	border: 2px solid var(--ap-navy);
	padding: 11px 13px;
}

.ap-create__radio {
	position: absolute;
	top: 0;
	left: 0;
	width: 1px;
	height: 1px;
	margin: 0;
	opacity: 0;
}

.ap-create__ring {
	width: 18px;
	height: 18px;
	border: 1.5px solid var(--ap-ring);
	border-radius: 50%;
}

.ap-create__radio:checked + .ap-create__ring {
	border: 5px solid var(--ap-navy);
}

.ap-create__radio:focus-visible + .ap-create__ring {
	outline: 2px solid var(--ap-navy);
	outline-offset: 2px;
}

.ap-create__plan-text {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.ap-create__plan-name {
	font-size: 14.5px;
	font-weight: 600;
}

.ap-create__plan-desc {
	color: var(--ap-muted);
	font-size: 12px;
}

.ap-create__plan-price {
	font-family: var(--ap-serif);
	font-size: 22px;
}

/* Premium add-on (basic plan, compact layout) */
.ap-create__addon {
	display: grid;
	grid-template-columns: 17px minmax(0, 1fr);
	gap: 10px;
	padding: 12px 14px;
	border: 1px solid var(--ap-navy);
	background: var(--ap-chosen);
	color: var(--ap-muted);
	font-size: 13px;
	line-height: 1.45;
	cursor: pointer;
}

.ap-create:has(#ap-plan-premium:checked) .ap-create__addon {
	display: none;
}

.ap-create__addon input {
	width: 17px;
	height: 17px;
	margin: 1px 0 0;
	accent-color: var(--ap-navy);
	cursor: pointer;
}

.ap-create__addon strong {
	color: var(--ap-navy);
	font-weight: 600;
}

/* Benefits (full layout) */
.ap-create .ap-create__benefits {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ap-create__benefits li {
	display: grid;
	grid-template-columns: 14px minmax(0, 1fr);
	gap: 9px;
	margin: 0;
	color: var(--ap-muted);
	font-size: 12.5px;
	line-height: 1.5;
}

.ap-create__benefits svg {
	margin-top: 3px;
}

/* Order lines */
.ap-create__totals {
	display: flex;
	flex-direction: column;
	font-size: 14px;
	font-variant-numeric: tabular-nums;
}

.ap-create .ap-create__line,
.ap-create .ap-create__total {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	border-top: 1px solid var(--ap-border);
}

.ap-create .ap-create__line {
	padding: 9px 0;
}

.ap-create .ap-create__total {
	padding: 12px 0 8px;
	font-weight: 600;
}

.ap-create__total strong {
	font-family: var(--ap-serif);
	font-size: 34px;
	font-weight: 400;
	line-height: 1;
}

.ap-create .ap-create__renew {
	margin-top: 10px;
	color: var(--ap-muted);
	font-size: 12.5px;
	line-height: 1.5;
}

/* Form column */

.ap-create__form-col {
	flex: 1 1 440px;
	min-width: 0;
	padding: 28px 30px 24px;
}

.ap-create__view[hidden] {
	display: none;
}

.ap-create__form {
	display: flex;
	flex-direction: column;
	gap: 22px;
}

.ap-create__form .ap-create__heading {
	margin-bottom: -8px;
}

.ap-create .ap-create__welcome {
	margin: 0 0 8px;
	color: var(--ap-navy);
	font-family: var(--ap-serif);
	font-size: 26px;
	font-weight: 400;
	line-height: 1.15;
}

.ap-create .ap-create__lead {
	color: var(--ap-muted);
	font-size: 13.5px;
}

.ap-create__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
}

.ap-create__field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
	margin: 0;
}

.ap-create__field--wide {
	grid-column: 1 / -1;
}

.ap-create__field .ap-create__label {
	letter-spacing: 0.05em;
}

.ap-create .ap-create__input {
	width: 100%;
	height: 40px;
	padding: 0 12px;
	border: 1px solid var(--ap-border);
	border-radius: 0;
	background: #fff;
	color: var(--ap-navy);
	font-family: var(--ap-sans);
	font-size: 14px;
	letter-spacing: 0;
	box-shadow: none;
}

.ap-create select.ap-create__input {
	padding: 0 10px;
}

.ap-create .ap-create__input:focus {
	border-color: var(--ap-navy);
	outline: none;
}

.ap-create .ap-create__note {
	color: var(--ap-muted);
	font-size: 13px;
}

.ap-create__password {
	position: relative;
	display: block;
}

.ap-create__password .ap-create__input {
	padding-right: 42px;
}

.ap-create__pw-toggle {
	position: absolute;
	top: 50%;
	right: 8px;
	display: flex;
	padding: 4px;
	border: 0;
	background: none;
	color: var(--ap-pale);
	cursor: pointer;
	transform: translateY(-50%);
}

.ap-create__pw-toggle:hover,
.ap-create__pw-toggle.is-on {
	color: var(--ap-navy);
}

.ap-create .ap-create__row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 16px;
	margin-top: -8px;
}

.ap-create__check {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	color: var(--ap-muted);
	font-size: 12.5px;
	cursor: pointer;
}

.ap-create__check input {
	width: 15px;
	height: 15px;
	margin: 0;
	accent-color: var(--ap-navy);
}

.ap-create .ap-create__forgot {
	color: var(--ap-muted);
	font-size: 12.5px;
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Submit */

.ap-create__actions {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	margin-top: 6px;
	text-align: center;
}

.ap-create .ap-create__submit {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	padding: 4px 4px 4px 22px;
	border: 0;
	border-radius: 999px;
	background: var(--ap-gold);
	color: var(--ap-ink);
	font-family: var(--ap-sans);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	text-align: left;
	cursor: pointer;
}

.ap-create .ap-create__submit:hover {
	background: var(--ap-gold-hover);
	color: var(--ap-ink);
}

.ap-create .ap-create__submit:focus-visible {
	outline: 2px solid var(--ap-navy);
	outline-offset: 3px;
}

.ap-create__cta-icon {
	display: grid;
	flex: none;
	place-items: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: #fff;
}

.ap-create .ap-create__secure {
	color: var(--ap-muted);
	font-size: 12px;
}

.ap-create__secure svg {
	margin-right: 6px;
	vertical-align: -1px;
}

/* WooCommerce's registration privacy text (its settings), under the button */
.ap-create .woocommerce-privacy-policy-text {
	max-width: 380px;
}

.ap-create .woocommerce-privacy-policy-text p {
	color: var(--ap-pale);
	font-size: 11.5px;
	line-height: 1.45;
}

.ap-create .woocommerce-privacy-policy-text a {
	color: var(--ap-muted);
	text-decoration: underline;
}

.ap-create .ap-create__switch {
	margin-top: 22px;
	padding-top: 16px;
	border-top: 1px solid var(--ap-line);
	font-size: 13px;
	text-align: center;
}

.ap-create__switch a {
	margin-left: 6px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

/* Notices (registration / login errors) above the form */
.ap-create__form-col .woocommerce-error,
.ap-create__form-col .woocommerce-message,
.ap-create__form-col .woocommerce-info {
	margin: 0 0 20px;
	font-size: 13.5px;
}

/* Support strip */

.ap-create__support {
	padding: 16px 20px;
	border-top: 1px solid var(--ap-border);
}

.ap-create__support-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 24px;
	max-width: 880px;
	margin: 0 auto;
	color: var(--ap-muted);
	font-size: 12.5px;
}

.ap-create__support-inner p a {
	font-weight: 500;
}

.ap-create .ap-create__support-link {
	font-weight: 600;
}

/* Narrow screens */

/* The two columns (340px + 440px) stack below this */
@media (max-width: 820px) {
	.ap-create__order {
		flex-basis: 100%;
		border-right: 0;
		border-bottom: 1px solid var(--ap-line);
	}
}

@media (max-width: 480px) {
	.ap-create__order,
	.ap-create__form-col {
		padding: 24px 18px;
	}

	.ap-create__shell {
		padding: 0 12px 24px;
	}

	.ap-create__grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.ap-create .ap-create__submit {
		font-size: 13.5px;
	}
}
