/* Text sizes on ACSS variables since 8 November 2026: this page runs on the 10px root, so the old rem sizes
   (written for 16px) came out at 7-8.5px on the cards. */
/**
 * Samye Course Library — page-scoped stylesheet.
 * Page slug: course-library (file: page-course-library.php). Enqueued only
 * when is_page('course-library') matches.
 *
 * Pathway colours sourced from the Elementor kit global colours
 * (post 50324 _elementor_page_settings.custom_colors):
 *   Dignity        → #9A874A  (gold-brown)
 *   Transformation → #8B0202  (deep red)
 *   Realization    → #10426A  (deep blue)
 *
 * Accent: Samye Red #B83029 (kit "accent"). Ink: kit "primary" #111111.
 */

.scl {
	--scl-dignity: #9A874A;
	--scl-transformation: #8B0202;
	--scl-realization: #10426A;
	--scl-accent: var(--samye-crimson);
	--scl-ink: #111111;
	--scl-cream: var(--samye-cream);
	--scl-stone: #f5f5f3;
	--scl-line: #e6e0d6;
	--scl-muted: #6b6b76;
	--scl-green: #2E6E29;

	/* Outer is 100% width so section background washes go full-bleed.
	   Inner content is centered at 1200px via .scl-hero__inner and
	   .scl-section__inner. */
	width: 100%;
	padding: 0 0 96px;
	font-family: 'Poppins', sans-serif;
	color: var(--scl-ink);
}

/* =========================================================
   Hero — pathway chooser
   ========================================================= */
.scl-hero {
	padding: 64px clamp(20px, 4.7619vw + 2.857px, 60px) 32px;
	border-bottom: 1px solid var(--scl-line);
}
.scl-hero__inner {
	max-width: 1200px;
	margin: 0 auto;
}
.scl-hero__title {
	font-family: 'Merriweather', serif;
	font-size: var(--h1);
	font-weight: 400;
	line-height: 1.2;
	color: var(--scl-ink);
	margin: 0 0 16px;
}
.scl-hero__lede {
	max-width: 720px;
	margin: 0 0 16px;
}
.scl-hero__lede p {
	font-size: var(--text-m);
	line-height: 1.6;
	color: var(--scl-ink);
	margin: 0 0 14px;
}
.scl-hero__lede p:last-child { margin-bottom: 0; }
/* Pathway nav — title in pathway colour, count beneath in muted text.
   No underlines, arrows, dots, or borders. Three columns, generous gap. */
.scl-hero__chooser {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 48px;
	margin: 32px 0 4px;
}
.scl-hero__card {
	display: block;
	text-decoration: none;
	transition: opacity 0.18s ease;
}
.scl-hero__card:hover,
.scl-hero__card:focus-visible {
	opacity: 0.7;
	outline: none;
}
.scl-hero__card--dignity        { --pathway-color: var(--scl-dignity); }
.scl-hero__card--transformation { --pathway-color: var(--scl-transformation); }
.scl-hero__card--realization    { --pathway-color: var(--scl-realization); }

.scl-hero__card-pathway {
	display: block;
	font-family: 'Merriweather', serif;
	font-size: var(--text-m);
	font-weight: 400;
	line-height: 1.3;
	color: var(--pathway-color, var(--scl-ink));
}
.scl-hero__card-count {
	display: block;
	margin-top: 6px;
	font-size: var(--text-s);
	color: var(--scl-muted);
}

@media (max-width: 720px) {
	.scl-hero__chooser { grid-template-columns: 1fr; gap: 24px; }
}

/* =========================================================
   Section heads
   ========================================================= */
/* Gutter as the header: clamp(20px, 4.7619vw + 2.857px, 60px) each side; the inners cap content at 1200px. */
.scl-section {
	padding: 64px clamp(20px, 4.7619vw + 2.857px, 60px) 40px;
	scroll-margin-top: 24px;
	background-image: linear-gradient(180deg, var(--scl-section-wash, transparent) 0%, transparent 65%);
}
.scl-section--dignity        { --scl-section-wash: rgba(154, 135, 74, 0.05); }
.scl-section--transformation { --scl-section-wash: rgba(139, 2, 2, 0.04); }
.scl-section--realization    { --scl-section-wash: rgba(16, 66, 106, 0.04); }
.scl-section__inner {
	max-width: 1200px;
	margin: 0 auto;
}
.scl-section__head {
	display: flex;
	align-items: baseline;
	flex-wrap: wrap;
	gap: 16px;
	margin: 0 0 28px;
}
.scl-section__eyebrow {
	font-size: var(--text-xs);
	font-weight: 600;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	margin: 0;
	flex-basis: 100%;
}
.scl-section--dignity        .scl-section__eyebrow { color: var(--scl-dignity); }
.scl-section--transformation .scl-section__eyebrow { color: var(--scl-transformation); }
.scl-section--realization    .scl-section__eyebrow { color: var(--scl-realization); }

.scl-section__title {
	font-family: 'Merriweather', serif;
	font-size: var(--h2);
	font-weight: 400;
	color: var(--scl-ink);
	margin: 0;
}
.scl-section__count {
	font-size: var(--text-s);
	color: var(--scl-muted);
	margin-left: auto;
}

/* =========================================================
   Subsections (within Transformation / Realization)
   Italic Merriweather echoes the original page's subtitle styling.
   ========================================================= */
.scl-subsection {
	margin: 0 0 48px;
}
.scl-subsection:last-child { margin-bottom: 0; }
.scl-subsection__title {
	font-family: 'Merriweather', serif;
	font-size: var(--h3);
	font-weight: 300;
	font-style: italic;
	line-height: 1.3;
	color: var(--scl-ink);
	margin: 0 0 20px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--scl-line);
	opacity: 0.92;
}
.scl-section--dignity        .scl-subsection__title { border-bottom-color: rgba(154, 135, 74, 0.25); }
.scl-section--transformation .scl-subsection__title { border-bottom-color: rgba(139, 2, 2, 0.20); }
.scl-section--realization    .scl-subsection__title { border-bottom-color: rgba(16, 66, 106, 0.20); }

/* =========================================================
   Grid + Card
   ========================================================= */
.scl-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
}
@media (max-width: 1024px) { .scl-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .scl-grid { grid-template-columns: 1fr; } }

.scl-card {
	position: relative;
	display: flex;
	flex-direction: column;
	background: #fff;
	border-radius: 10px;
	overflow: hidden;
	text-decoration: none;
	color: var(--scl-ink);
	box-shadow: 0 1px 3px rgba(0,0,0,0.06);
	transition: transform 0.18s ease, box-shadow 0.18s ease;
	min-height: 100%;
}
.scl-card:hover,
.scl-card:focus-visible {
	transform: translateY(-3px);
	box-shadow: 0 10px 24px rgba(0,0,0,0.12);
	outline: none;
}
.scl-card__accent {
	position: absolute;
	top: 0; left: 0; right: 0;
	height: 4px;
	background: var(--scl-ink);
	z-index: 2;
}
.scl-card--dignity        .scl-card__accent { background: var(--scl-dignity); }
.scl-card--transformation .scl-card__accent { background: var(--scl-transformation); }
.scl-card--realization    .scl-card__accent { background: var(--scl-realization); }

.scl-card__thumb {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 16 / 10;
	background: var(--scl-ink) center/cover no-repeat;
	overflow: hidden;
}
.scl-card__thumb--blank {
	background: linear-gradient(135deg, var(--scl-ink), #282828);
}

/* Hover/focus CTA reveal — slides up from the bottom-right of the thumb */
.scl-card__cta {
	position: absolute;
	bottom: 10px;
	right: 10px;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	background: rgba(255, 255, 255, 0.96);
	color: var(--scl-ink);
	border-radius: 999px;
	font-size: var(--text-xs);
	font-weight: 600;
	letter-spacing: 0.3px;
	text-transform: uppercase;
	opacity: 0;
	transform: translateY(6px);
	transition: opacity 0.2s ease, transform 0.2s ease;
	pointer-events: none;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.scl-card__cta svg { display: block; }
.scl-card:hover .scl-card__cta,
.scl-card:focus-visible .scl-card__cta {
	opacity: 1;
	transform: translateY(0);
}

.scl-card__body {
	padding: 18px 18px 20px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
}
.scl-card__pathway {
	font-size: var(--text-xs);
	font-weight: 600;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: var(--scl-muted);
}
.scl-card--dignity        .scl-card__pathway { color: var(--scl-dignity); }
.scl-card--transformation .scl-card__pathway { color: var(--scl-transformation); }
.scl-card--realization    .scl-card__pathway { color: var(--scl-realization); }

.scl-card__title {
	font-family: 'Merriweather', serif;
	font-size: var(--h4);
	font-weight: 400;
	line-height: 1.3;
	color: var(--scl-ink);
	margin: 0;
}
.scl-card__excerpt {
	font-size: var(--text-s);
	line-height: 1.55;
	color: var(--scl-muted);
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.scl-card__meta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: auto;
	padding-top: 6px;
}
.scl-card__teacher {
	font-size: var(--text-xs);
	color: var(--scl-muted);
	line-height: 1.3;
	flex: 1;
	min-width: 0;
}
.scl-card__teacher-name {
	color: var(--scl-ink);
	font-weight: 500;
}
.scl-card__badge {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 4px 9px;
	border-radius: 999px;
	font-size: var(--text-xs);
	font-weight: 600;
	letter-spacing: 0.3px;
	flex-shrink: 0;
}
.scl-card__badge--gated {
	background: rgba(184, 48, 41, 0.08);
	color: var(--scl-accent);
}
.scl-card__badge--free {
	background: rgba(46, 110, 41, 0.08);
	color: var(--scl-green);
}

/* =========================================================
   Responsive horizontal padding
   Side padding is the header's gutter at every width (on .scl-hero and
   .scl-section above), so left edges align with the header and footer.
   ========================================================= */
@media (max-width: 640px) {
	.scl-hero { padding-top: 40px; padding-bottom: 24px; }
	.scl-section { padding-top: 40px; padding-bottom: 16px; }
	.scl-section__title { font-size: var(--h3); }
}

/* Reduce-motion respect */
@media (prefers-reduced-motion: reduce) {
	.scl-hero__card,
	.scl-card { transition: none; }
	.scl-hero__card:hover,
	.scl-card:hover { transform: none; }
}
