/*
 * LUDISC Page & Post Templates
 * All rules are scoped so they cannot restyle unrelated site content.
 */

.ludisc-template {
	--ludisc-green: #4caf50;
	--ludisc-green-dark: #2f7d32;
	--ludisc-green-light: #79c342;
	--ludisc-orange: #ff9800;
	--ludisc-blue: #2196f3;
	--ludisc-text: #263238;
	--ludisc-muted: #64748b;
	--ludisc-light: #f8fafc;
	--ludisc-border: #dce8df;
	--ludisc-radius: 20px;
	--ludisc-shadow: 0 14px 36px rgba(38, 50, 56, 0.1);
	color: var(--ludisc-text);
	min-width: 0;
	width: 100%;
}

.ludisc-template.content-area.primary {
	border: 0;
	float: none;
	max-width: 100%;
	padding-left: 0;
	padding-right: 0;
	width: 100%;
}

.ludisc-template__main {
	padding: clamp(2.25rem, 5vw, 4.75rem) 0 clamp(3.5rem, 7vw, 6rem);
	width: 100%;
}


.ludisc-article {
	margin: 0 auto;
	max-width: 1200px;
	width: 100%;
}

.ludisc-article__header {
	margin: 0 auto clamp(2rem, 4vw, 3.25rem);
	max-width: 920px;
	padding: 0 1.25rem;
	text-align: center;
}

.ludisc-article__eyebrow,
.ludisc-template .ludisc-kicker {
	color: var(--ludisc-green-dark);
	font-family: Poppins, Arial, sans-serif;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	margin: 0 0 1rem;
	text-transform: uppercase;
}

.ludisc-article__eyebrow {
	background: #edf8ee;
	border: 1px solid #d3ead5;
	border-radius: 999px;
	display: inline-flex;
	padding: 0.48rem 0.9rem;
}

.ludisc-article__title {
	color: var(--ludisc-text);
	font-family: Poppins, Arial, sans-serif;
	font-size: clamp(2.15rem, 5vw, 4.4rem);
	font-weight: 750;
	letter-spacing: -0.04em;
	line-height: 1.08;
	margin: 0;
}

.ludisc-article__excerpt {
	color: var(--ludisc-muted);
	font-size: clamp(1.08rem, 2vw, 1.28rem);
	line-height: 1.7;
	margin: 1.35rem auto 0;
	max-width: 760px;
}

.ludisc-article__excerpt p {
	margin: 0;
}

.ludisc-article__meta {
	align-items: center;
	color: var(--ludisc-muted);
	display: flex;
	flex-wrap: wrap;
	font-size: 0.92rem;
	gap: 0.55rem;
	justify-content: center;
	margin-top: 1.15rem;
}

.ludisc-article__featured-image {
	background: var(--ludisc-light);
	border-radius: var(--ludisc-radius);
	box-shadow: var(--ludisc-shadow);
	margin: 0 auto clamp(2.75rem, 6vw, 5.25rem);
	overflow: hidden;
	width: min(100%, 1200px);
}

.ludisc-article__featured-image img {
	display: block;
	height: auto;
	margin: 0;
	max-width: 100%;
	width: 100%;
}

.ludisc-article__content,
.ludisc-article__footer,
.ludisc-template .comments-area {
	font-family: Inter, Arial, sans-serif;
	font-size: 1.0625rem;
	line-height: 1.78;
	margin-left: auto;
	margin-right: auto;
	max-width: 840px;
	padding-left: 1.25rem;
	padding-right: 1.25rem;
}

.ludisc-article__content > *:first-child {
	margin-top: 0;
}

.ludisc-article__content p,
.ludisc-article__content ul,
.ludisc-article__content ol {
	color: var(--ludisc-text);
}

.ludisc-article__content h2,
.ludisc-article__content h3,
.ludisc-article__content h4 {
	color: var(--ludisc-text);
	font-family: Poppins, Arial, sans-serif;
	font-weight: 700;
	letter-spacing: -0.025em;
	line-height: 1.22;
}

.ludisc-article__content h2 {
	font-size: clamp(1.7rem, 3.4vw, 2.55rem);
	margin-bottom: 1rem;
	margin-top: clamp(2.75rem, 6vw, 4.75rem);
}

.ludisc-article__content h3 {
	font-size: clamp(1.28rem, 2.4vw, 1.65rem);
	margin-bottom: 0.8rem;
	margin-top: 2.25rem;
}

.ludisc-article__content a:not(.wp-block-button__link) {
	color: var(--ludisc-green-dark);
	font-weight: 650;
	text-decoration-color: rgba(47, 125, 50, 0.35);
	text-underline-offset: 0.18em;
}

.ludisc-article__content a:not(.wp-block-button__link):hover,
.ludisc-article__content a:not(.wp-block-button__link):focus {
	color: var(--ludisc-blue);
	text-decoration-color: currentColor;
}

.ludisc-article__content img {
	border-radius: 16px;
}

.ludisc-article__content .alignwide {
	margin-left: min(-10vw, -110px);
	margin-right: min(-10vw, -110px);
	max-width: 1060px;
	width: auto;
}

.ludisc-article__content .alignfull {
	margin-left: calc((840px - min(100vw, 1200px)) / 2);
	margin-right: calc((840px - min(100vw, 1200px)) / 2);
	max-width: 1200px;
	width: min(100vw, 1200px);
}

.ludisc-template .ludisc-lead {
	color: #3d4d53;
	font-size: clamp(1.15rem, 2vw, 1.32rem);
	font-weight: 450;
	line-height: 1.72;
}

.ludisc-template .ludisc-highlight-panel,
.ludisc-template .ludisc-key-points,
.ludisc-template .ludisc-disclosure,
.ludisc-template .ludisc-safety-note,
.ludisc-template .ludisc-product-card,
.ludisc-template .ludisc-cta {
	border-radius: var(--ludisc-radius);
	box-sizing: border-box;
	margin-bottom: clamp(2rem, 5vw, 3.5rem);
	margin-top: clamp(2rem, 5vw, 3.5rem);
	padding: clamp(1.35rem, 4vw, 2.4rem);
}

.ludisc-template .ludisc-highlight-panel {
	background: linear-gradient(135deg, #f4fbf4 0%, #fffaf1 100%);
	border: 1px solid var(--ludisc-border);
}

.ludisc-template .ludisc-highlight-panel > h2,
.ludisc-template .ludisc-key-points > h2,
.ludisc-template .ludisc-cta > h2 {
	margin-top: 0;
}

.ludisc-template .ludisc-card-grid {
	gap: 1rem;
}

.ludisc-template .ludisc-card-grid > .wp-block-column {
	background: #fff;
	border: 1px solid var(--ludisc-border);
	border-radius: 16px;
	box-shadow: 0 8px 22px rgba(38, 50, 56, 0.06);
	padding: 1.25rem;
}

.ludisc-template .ludisc-card-grid h3 {
	font-size: 1.2rem;
	margin-top: 0;
}

.ludisc-template .ludisc-key-points {
	background: #f2f8fe;
	border-left: 5px solid var(--ludisc-blue);
}

.ludisc-template .ludisc-key-points li + li {
	margin-top: 0.6rem;
}

.ludisc-template .ludisc-disclosure {
	background: #fff8e8;
	border: 1px solid #ffd58b;
	box-shadow: none;
	font-size: 0.95rem;
}

.ludisc-template .ludisc-disclosure p {
	margin: 0;
}

.ludisc-template .ludisc-safety-note {
	background: #fffaf1;
	border: 1px solid #ffd89b;
	border-left: 5px solid var(--ludisc-orange);
}

.ludisc-template .ludisc-safety-note h3 {
	margin-top: 0;
}

.ludisc-template .ludisc-product-card {
	background: #fff;
	border: 1px solid var(--ludisc-border);
	box-shadow: var(--ludisc-shadow);
}

.ludisc-template .ludisc-product-card h3 {
	font-size: clamp(1.45rem, 3vw, 2rem);
	margin-top: 0;
}

.ludisc-template .ludisc-cta {
	background: linear-gradient(135deg, var(--ludisc-green) 0%, var(--ludisc-green-light) 100%);
	box-shadow: var(--ludisc-shadow);
	color: #fff;
	text-align: center;
}

.ludisc-template .ludisc-cta h2,
.ludisc-template .ludisc-cta p {
	color: #fff;
}

.ludisc-template .wp-block-button__link {
	background: var(--ludisc-orange);
	border: 0;
	border-radius: 999px;
	box-shadow: 0 8px 20px rgba(175, 94, 0, 0.22);
	color: #1f2933;
	font-family: Poppins, Arial, sans-serif;
	font-size: 0.98rem;
	font-weight: 700;
	line-height: 1.2;
	padding: 0.9rem 1.4rem;
	text-decoration: none;
	transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.ludisc-template .wp-block-button__link:hover,
.ludisc-template .wp-block-button__link:focus {
	background: #ffad2f;
	box-shadow: 0 10px 24px rgba(175, 94, 0, 0.28);
	color: #172026;
	transform: translateY(-2px);
}

.ludisc-template table {
	border: 1px solid var(--ludisc-border);
	border-collapse: separate;
	border-radius: 14px;
	border-spacing: 0;
	overflow: hidden;
	width: 100%;
}

.ludisc-template th {
	background: #edf8ee;
	color: var(--ludisc-text);
	font-family: Poppins, Arial, sans-serif;
	font-weight: 700;
}

.ludisc-template th,
.ludisc-template td {
	border-bottom: 1px solid var(--ludisc-border);
	padding: 0.85rem 1rem;
	text-align: left;
	vertical-align: top;
}

.ludisc-template tr:last-child td {
	border-bottom: 0;
}

.ludisc-template details.wp-block-details {
	background: #fff;
	border: 1px solid var(--ludisc-border);
	border-radius: 14px;
	margin: 0 0 0.85rem;
	padding: 1rem 1.15rem;
}

.ludisc-template details.wp-block-details summary {
	cursor: pointer;
	font-family: Poppins, Arial, sans-serif;
	font-weight: 700;
}

.ludisc-template details.wp-block-details[open] summary {
	color: var(--ludisc-green-dark);
	margin-bottom: 0.75rem;
}

.ludisc-article__footer {
	border-top: 1px solid var(--ludisc-border);
	font-size: 0.95rem;
	margin-top: 3.5rem;
	padding-top: 1.25rem;
}

.ludisc-article__tag-label {
	font-weight: 700;
	margin-right: 0.45rem;
}

.ludisc-article__tags a {
	background: #edf8ee;
	border-radius: 999px;
	color: var(--ludisc-green-dark);
	display: inline-flex;
	font-size: 0.88rem;
	font-weight: 650;
	margin: 0.25rem;
	padding: 0.35rem 0.7rem;
	text-decoration: none;
}

.ludisc-post-navigation {
	display: grid;
	gap: 1rem;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	margin: 3.5rem auto 0;
	max-width: 840px;
	padding: 0 1.25rem;
}

.ludisc-post-navigation a {
	border: 1px solid var(--ludisc-border);
	border-radius: 14px;
	color: var(--ludisc-text);
	display: flex;
	flex-direction: column;
	height: 100%;
	padding: 1rem 1.15rem;
	text-decoration: none;
}

.ludisc-post-navigation a:hover,
.ludisc-post-navigation a:focus {
	border-color: var(--ludisc-green);
	box-shadow: 0 8px 22px rgba(38, 50, 56, 0.08);
}

.ludisc-post-navigation span {
	color: var(--ludisc-muted);
	font-size: 0.82rem;
	margin-bottom: 0.3rem;
}

.ludisc-post-navigation strong {
	font-family: Poppins, Arial, sans-serif;
	font-size: 0.98rem;
	line-height: 1.35;
}

.ludisc-post-navigation__next {
	text-align: right;
}

@media (max-width: 921px) {
	.ludisc-template__main {
		padding-top: 2.5rem;
	}

	.ludisc-article__content .alignwide,
	.ludisc-article__content .alignfull {
		margin-left: 0;
		margin-right: 0;
		max-width: 100%;
		width: 100%;
	}
}

@media (max-width: 600px) {
	.ludisc-article__header,
	.ludisc-article__content,
	.ludisc-article__footer,
	.ludisc-post-navigation,
	.ludisc-template .comments-area {
		padding-left: 1rem;
		padding-right: 1rem;
	}

	.ludisc-article__title {
		font-size: clamp(2rem, 11vw, 3rem);
	}

	.ludisc-article__meta {
		gap: 0.38rem;
	}

	.ludisc-post-navigation {
		grid-template-columns: 1fr;
	}

	.ludisc-post-navigation__next {
		text-align: left;
	}

	.ludisc-template .ludisc-highlight-panel,
	.ludisc-template .ludisc-key-points,
	.ludisc-template .ludisc-disclosure,
	.ludisc-template .ludisc-safety-note,
	.ludisc-template .ludisc-product-card,
	.ludisc-template .ludisc-cta {
		border-radius: 16px;
		padding: 1.2rem;
	}

	.ludisc-template th,
	.ludisc-template td {
		padding: 0.7rem;
	}
}

@media print {
	.ludisc-template__main {
		padding: 0;
	}

	.ludisc-article__header,
	.ludisc-article__content,
	.ludisc-article__footer {
		max-width: none;
	}

	.ludisc-post-navigation,
	.ludisc-template .wp-block-buttons,
	.ludisc-template .comments-area {
		display: none !important;
	}

	.ludisc-template .ludisc-highlight-panel,
	.ludisc-template .ludisc-key-points,
	.ludisc-template .ludisc-disclosure,
	.ludisc-template .ludisc-safety-note,
	.ludisc-template .ludisc-product-card,
	.ludisc-template .ludisc-cta {
		box-shadow: none;
		break-inside: avoid;
	}
}
