/*
 * TSSH Single Post Promotions
 * Uses the design system from the TSSH homepage.
 */

/*
 * TSSH Article Advertising Blocks
 * Matches the Spanish Schoolhouse homepage design system.
 */

.ssh-article-promo,
.ssh-article-promo * {
	box-sizing: border-box;
}

.ssh-article-promo {
	--ssh-blue: #22b6e7;
	--ssh-blue-dark: #087eaf;
	--ssh-navy: #17304b;
	--ssh-lime: #b3d789;
	--ssh-lime-hover: #a1c873;
	--ssh-yellow: #ffe34e;
	--ssh-white: #ffffff;
	--ssh-body: #53697d;

	position: relative;
	isolation: isolate;
	overflow: hidden;
	margin: 44px 0;
	padding: clamp(28px, 4vw, 38px);
	border: 3px solid var(--ssh-blue);
	border-radius: 20px;
	background:
		linear-gradient(
			115deg,
			#fff9d8 0%,
			#ffffff 48%,
			#e4f8fd 100%
		);
	box-shadow: 0 18px 45px rgba(8, 126, 175, 0.16);
	color: var(--ssh-navy);
	font-family: inherit;
}

/*
 * Decorative circle used throughout the homepage.
 */
.ssh-article-promo::before {
	position: absolute;
	top: -80px;
	right: -70px;
	z-index: -1;
	width: 190px;
	height: 190px;
	border: 32px solid rgba(255, 227, 78, 0.3);
	border-radius: 50%;
	content: "";
	pointer-events: none;
}

/*
 * Small blue decorative shape.
 */
.ssh-article-promo::after {
	position: absolute;
	right: 110px;
	bottom: -58px;
	z-index: -1;
	width: 115px;
	height: 115px;
	border-radius: 28px;
	background: rgba(34, 182, 231, 0.08);
	content: "";
	pointer-events: none;
	transform: rotate(22deg);
}

.ssh-article-promo__content {
	position: relative;
	z-index: 2;
	max-width: 850px;
}

/*
 * Eyebrow label
 */
.ssh-article-promo__label {
	display: inline-flex;
	align-items: center;
	width: fit-content;
	margin: 0 0 12px;
	padding: 7px 11px;
	border-radius: 999px;
	background: #e5f8fd;
	color: var(--ssh-blue-dark);
	font-size: 12px;
	font-weight: 900;
	letter-spacing: 0.1em;
	line-height: 1.2;
	text-transform: uppercase;
}

/*
 * Heading
 */
.ssh-article-promo h3 {
	max-width: 720px;
	margin: 0 0 12px;
	color: var(--ssh-navy);
	font-family: inherit;
	font-size: clamp(27px, 3.2vw, 38px);
	font-weight: 850;
	letter-spacing: -0.035em;
	line-height: 1.06;
}

/*
 * Description
 */
.ssh-article-promo p {
	max-width: 760px;
	margin: 0 0 23px;
	color: var(--ssh-body);
	font-size: 17px;
	line-height: 1.6;
}

/*
 * Button group
 */
.ssh-article-promo__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 11px;
}

/*
 * Primary button
 */
.ssh-article-promo__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 13px 18px;
	border: 2px solid var(--ssh-lime);
	border-radius: 4px;
	background: var(--ssh-lime);
	box-shadow: 0 10px 24px rgba(99, 134, 55, 0.2);
	color: var(--ssh-navy) !important;
	font-family: inherit;
	font-size: 14px;
	font-weight: 900;
	letter-spacing: 0.02em;
	line-height: 1.1;
	text-align: center;
	text-decoration: none !important;
	text-transform: uppercase;
	transition:
		transform 0.2s ease,
		background-color 0.2s ease,
		border-color 0.2s ease,
		box-shadow 0.2s ease;
}

.ssh-article-promo__button::after {
	margin-left: 9px;
	content: "→";
	font-size: 17px;
	font-weight: 900;
	line-height: 1;
	transition: transform 0.2s ease;
}

.ssh-article-promo__button:hover,
.ssh-article-promo__button:focus-visible {
	border-color: var(--ssh-lime-hover);
	background: var(--ssh-lime-hover);
	box-shadow: 0 13px 28px rgba(99, 134, 55, 0.28);
	color: var(--ssh-navy) !important;
	transform: translateY(-2px);
}

.ssh-article-promo__button:hover::after,
.ssh-article-promo__button:focus-visible::after {
	transform: translateX(4px);
}

.ssh-article-promo__button:focus-visible {
	outline: 3px solid var(--ssh-yellow);
	outline-offset: 3px;
}

/*
 * Secondary button
 */
.ssh-article-promo__button--secondary {
	border-color: var(--ssh-blue-dark);
	background: var(--ssh-blue-dark);
	box-shadow: none;
	color: var(--ssh-white) !important;
}

.ssh-article-promo__button--secondary:hover,
.ssh-article-promo__button--secondary:focus-visible {
	border-color: #066e99;
	background: #066e99;
	box-shadow: 0 10px 22px rgba(8, 126, 175, 0.2);
	color: var(--ssh-white) !important;
}

/*
 * CHILDREN'S CLASSES BLOCK
 */
.ssh-article-promo--children {
	border-color: var(--ssh-blue);
	background:
		linear-gradient(
			115deg,
			#fff9d8 0%,
			#ffffff 48%,
			#e4f8fd 100%
		);
}

.ssh-article-promo--children
	.ssh-article-promo__label {
	background: var(--ssh-yellow);
	color: var(--ssh-navy);
	transform: rotate(-1deg);
}

.ssh-article-promo--children::before {
	border-color: rgba(184, 219, 117, 0.36);
}

/*
 * ADULT ONLINE CLASSES BLOCK
 */
.ssh-article-promo--adults {
	border: 1px solid #cce8f2;
	background:
		linear-gradient(
			110deg,
			#ffffff 0%,
			#f1fbfe 100%
		);
	box-shadow: 0 16px 40px rgba(23, 48, 75, 0.09);
}

.ssh-article-promo--adults::before {
	border-color: rgba(34, 182, 231, 0.16);
}

.ssh-article-promo--adults::after {
	background: rgba(184, 219, 117, 0.17);
}

.ssh-article-promo--adults
	.ssh-article-promo__label {
	background: #e5f8fd;
	color: var(--ssh-blue-dark);
}

/*
 * TRIAL CLASS BLOCK
 */
.ssh-article-promo--trial {
	border: 1px solid rgba(255, 255, 255, 0.16);
	background:
		linear-gradient(
			135deg,
			#005a7d 0%,
			#17304b 60%,
			#10253a 100%
		);
	box-shadow: 0 24px 60px rgba(3, 24, 42, 0.28);
	color: var(--ssh-white);
}

.ssh-article-promo--trial::before {
	border-color: rgba(255, 227, 78, 0.16);
}

.ssh-article-promo--trial::after {
	background: rgba(34, 182, 231, 0.12);
}

.ssh-article-promo--trial
	.ssh-article-promo__label {
	background: var(--ssh-yellow);
	color: var(--ssh-navy);
	transform: rotate(-1deg);
}

.ssh-article-promo--trial h3 {
	color: var(--ssh-white);
}

.ssh-article-promo--trial p {
	color: #d9eff7;
}

.ssh-article-promo--trial
	.ssh-article-promo__button {
	border-color: var(--ssh-lime);
	background: var(--ssh-lime);
	box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
	color: var(--ssh-navy) !important;
}

.ssh-article-promo--trial
	.ssh-article-promo__button:hover,
.ssh-article-promo--trial
	.ssh-article-promo__button:focus-visible {
	border-color: #c7e7a2;
	background: #c7e7a2;
	color: var(--ssh-navy) !important;
}

/*
 * Remove unexpected Divi paragraph and heading spacing.
 */
.et_pb_text_inner .ssh-article-promo h3,
.et_pb_code_inner .ssh-article-promo h3 {
	padding-bottom: 0;
}

.et_pb_text_inner .ssh-article-promo p,
.et_pb_code_inner .ssh-article-promo p {
	padding-bottom: 0;
}

/*
 * Tablet
 */
@media (max-width: 767px) {
	.ssh-article-promo {
		margin: 36px 0;
		padding: 28px 24px;
	}

	.ssh-article-promo h3 {
		font-size: clamp(27px, 7vw, 34px);
	}

	.ssh-article-promo p {
		font-size: 16px;
	}

	.ssh-article-promo::before {
		top: -90px;
		right: -90px;
	}
}

/*
 * Mobile
 */
@media (max-width: 520px) {
	.ssh-article-promo {
		margin: 30px 0;
		padding: 25px 20px;
		border-radius: 18px;
	}

	.ssh-article-promo__label {
		font-size: 11px;
	}

	.ssh-article-promo h3 {
		font-size: 28px;
		line-height: 1.08;
	}

	.ssh-article-promo__actions {
		display: grid;
		grid-template-columns: 1fr;
	}

	.ssh-article-promo__button {
		width: 100%;
		min-height: 50px;
		padding-right: 15px;
		padding-left: 15px;
	}

	.ssh-article-promo::after {
		display: none;
	}
}

/*
 * Accessibility
 */
@media (prefers-reduced-motion: reduce) {
	.ssh-article-promo__button,
	.ssh-article-promo__button::after {
		transition: none;
	}
}
/* TSSH styled numbered lists on single blog posts */
body.single-post .et_pb_post_content ol.wp-block-list {
	--ssh-blue: #22b6e7;
	--ssh-blue-dark: #087eaf;
	--ssh-navy: #17304b;
	--ssh-yellow: #ffe34e;

	counter-reset: tssh-post-list;
	display: grid;
	grid-template-columns: 1fr;
	gap: 12px;
	margin: 24px 0 30px !important;
	padding: 0 !important;
	list-style: none !important;
}

body.single-post .et_pb_post_content ol.wp-block-list > li {
	position: relative;
	min-height: 58px;
	margin: 0 !important;
	padding: 16px 18px 16px 63px !important;
	border: 1px solid #dce9ee;
	border-left: 4px solid var(--ssh-blue);
	border-radius: 14px;
	background: linear-gradient(
		110deg,
		#ffffff 0%,
		#f1fbfe 100%
	);
	box-shadow: 0 8px 22px rgba(23, 48, 75, 0.07);
	color: #53697d;
	font-size: 16px;
	line-height: 1.55;
	list-style: none !important;
	counter-increment: tssh-post-list;
}

body.single-post .et_pb_post_content ol.wp-block-list > li::before {
	position: absolute;
	top: 13px;
	left: 14px;
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 10px;
	background: var(--ssh-blue);
	box-shadow: 5px 5px 0 var(--ssh-yellow);
	color: #ffffff;
	content: counter(tssh-post-list);
	font-size: 15px;
	font-weight: 900;
	line-height: 1;
}

body.single-post .et_pb_post_content ol.wp-block-list > li strong {
	color: var(--ssh-navy);
	font-weight: 850;
}

body.single-post .et_pb_post_content ol.wp-block-list > li a {
	color: var(--ssh-blue-dark);
	font-weight: 800;
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
}

body.single-post .et_pb_post_content ol.wp-block-list > li a:hover {
	color: var(--ssh-navy);
}

@media (max-width: 520px) {
	body.single-post .et_pb_post_content ol.wp-block-list {
		gap: 10px;
		margin: 20px 0 26px !important;
	}

	body.single-post .et_pb_post_content ol.wp-block-list > li {
		min-height: 54px;
		padding: 14px 14px 14px 57px !important;
		border-radius: 12px;
		font-size: 15px;
	}

	body.single-post .et_pb_post_content ol.wp-block-list > li::before {
		top: 12px;
		left: 12px;
		width: 31px;
		height: 31px;
		border-radius: 9px;
		box-shadow: 4px 4px 0 var(--ssh-yellow);
		font-size: 14px;
	}
}
/* TSSH inline links inside single blog-post content */
body.single-post .et_pb_post_content p a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button),
body.single-post .et_pb_post_content li a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button),
body.single-post .et_pb_post_content blockquote a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button) {
	padding: 0 2px;
	border-radius: 3px;
	background-image: linear-gradient(
		to top,
		rgba(255, 227, 78, 0.72),
		rgba(255, 227, 78, 0.72)
	);
	background-position: 0 100%;
	background-repeat: no-repeat;
	background-size: 100% 0.18em;
	color: #087eaf !important;
	font-weight: 800;
	text-decoration: none !important;
	-webkit-box-decoration-break: clone;
	box-decoration-break: clone;
	transition:
		color 0.2s ease,
		background-size 0.22s ease,
		box-shadow 0.2s ease;
}

/* Hover */
body.single-post .et_pb_post_content p a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):hover,
body.single-post .et_pb_post_content li a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):hover,
body.single-post .et_pb_post_content blockquote a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):hover {
	background-size: 100% 100%;
	color: #17304b !important;
}

/* Keyboard focus */
body.single-post .et_pb_post_content p a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):focus-visible,
body.single-post .et_pb_post_content li a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):focus-visible,
body.single-post .et_pb_post_content blockquote a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):focus-visible {
	outline: 3px solid #ffe34e;
	outline-offset: 3px;
	background-color: #e5f8fd;
	background-size: 100% 100%;
	color: #17304b !important;
}

/* Keep visited links in the TSSH colour system */
body.single-post .et_pb_post_content p a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):visited,
body.single-post .et_pb_post_content li a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):visited,
body.single-post .et_pb_post_content blockquote a:not(.ssh-article-promo__button):not(.et_pb_button):not(.wp-element-button):visited {
	color: #087eaf;
}

/* Remove animation when reduced motion is preferred */
@media (prefers-reduced-motion: reduce) {
	body.single-post .et_pb_post_content p a,
	body.single-post .et_pb_post_content li a,
	body.single-post .et_pb_post_content blockquote a {
		transition: none;
	}
}
/* TSSH styled bullet lists on single blog posts */
body.single-post .et_pb_post_content ul.wp-block-list {
	--ssh-blue: #22b6e7;
	--ssh-blue-dark: #087eaf;
	--ssh-navy: #17304b;
	--ssh-lime: #b3d789;
	--ssh-yellow: #ffe34e;

	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
	margin: 24px 0 30px !important;
	padding: 0 !important;
	list-style: none !important;
}

body.single-post .et_pb_post_content ul.wp-block-list > li {
	position: relative;
	display: flex;
	align-items: flex-start;
	gap: 12px;
	min-height: 58px;
	margin: 0 !important;
	padding: 15px 16px !important;
	border: 1px solid #dce9ee;
	border-radius: 13px;
	background: linear-gradient(
		110deg,
		#ffffff 0%,
		#f5fbfd 100%
	);
	box-shadow: 0 7px 18px rgba(23, 48, 75, 0.06);
	color: #53697d;
	font-size: 15px;
	line-height: 1.45;
	list-style: none !important;
	transition:
		transform 0.2s ease,
		border-color 0.2s ease,
		box-shadow 0.2s ease,
		background 0.2s ease;
}

body.single-post .et_pb_post_content ul.wp-block-list > li::before {
	flex: 0 0 27px;
	display: grid;
	place-items: center;
	width: 27px;
	height: 27px;
	margin-top: 1px;
	border-radius: 50%;
	background: var(--ssh-lime);
	box-shadow: 3px 3px 0 var(--ssh-yellow);
	color: var(--ssh-navy);
	content: "✓";
	font-size: 13px;
	font-weight: 950;
	line-height: 1;
}

/* Hover */
body.single-post .et_pb_post_content ul.wp-block-list > li:hover {
	border-color: rgba(34, 182, 231, 0.65);
	background: #ffffff;
	box-shadow: 0 11px 26px rgba(23, 48, 75, 0.11);
	transform: translateY(-2px);
}

/* Focus when a list item contains a keyboard-focused link */
body.single-post .et_pb_post_content ul.wp-block-list > li:focus-within {
	border-color: var(--ssh-blue);
	outline: 3px solid var(--ssh-yellow);
	outline-offset: 3px;
	background: #ffffff;
	box-shadow: 0 11px 26px rgba(23, 48, 75, 0.11);
}

/* Bold text inside list items */
body.single-post .et_pb_post_content ul.wp-block-list > li strong {
	color: var(--ssh-navy);
	font-weight: 850;
}

/* Mobile */
@media (max-width: 620px) {
	body.single-post .et_pb_post_content ul.wp-block-list {
		grid-template-columns: 1fr;
		gap: 9px;
		margin: 20px 0 26px !important;
	}

	body.single-post .et_pb_post_content ul.wp-block-list > li {
		min-height: 54px;
		padding: 14px !important;
		border-radius: 12px;
		font-size: 15px;
	}

	body.single-post .et_pb_post_content ul.wp-block-list > li::before {
		flex-basis: 25px;
		width: 25px;
		height: 25px;
		font-size: 12px;
	}
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	body.single-post .et_pb_post_content ul.wp-block-list > li {
		transition: none;
	}

	body.single-post .et_pb_post_content ul.wp-block-list > li:hover {
		transform: none;
	}
}