/*
Theme Name: Contact Sheet
Description: A custom block theme scaffolded by Studio Code. Direction: "Contact Sheet" — a photographer's workbook for learning the Fujifilm X-M5.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: contact-sheet
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* WordPress inserts margin-block-start: var(--wp--style--block-gap) between the
   template's top-level sections (header part, main, footer part). Zero it so
   sections butt edge-to-edge and own their vertical rhythm via padding. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* ==========================================================================
   1. THEME VARIABLES + DARK MODE
   The palette lives in theme.json. Dark mode re-points the generated preset
   variables so every block that uses a palette slug flips automatically.
   ========================================================================== */

:root {
	--cs-shadow-1: 0 1px 2px rgba(44, 41, 37, 0.06);
	--cs-shadow-2: 0 1px 2px rgba(44, 41, 37, 0.06), 0 2px 6px rgba(44, 41, 37, 0.07);
	--cs-shadow-3: 0 2px 4px rgba(44, 41, 37, 0.06), 0 10px 26px rgba(44, 41, 37, 0.1);
	--cs-border: var(--wp--preset--color--rule);
	--cs-focus: var(--wp--preset--color--teal);
	--cs-grain: rgba(140, 130, 113, 0.05);
	color-scheme: light;
}

@media (prefers-color-scheme: dark) {
	:root {
		color-scheme: dark;
		--wp--preset--color--paper: #171614;
		--wp--preset--color--card: #201e1b;
		--wp--preset--color--sunken: #100f0e;
		--wp--preset--color--rule: #39352f;
		--wp--preset--color--ink: #f3f0ea;
		--wp--preset--color--ink-soft: #c7c1b6;
		--wp--preset--color--ink-muted: #a09989;
		--wp--preset--color--night: #100f0e;
		--wp--preset--color--night-soft: #282521;
		--wp--preset--color--teal: #5fcfbd;
		--wp--preset--color--teal-deep: #84e0d1;
		--wp--preset--color--teal-soft: #12312d;
		--wp--preset--color--amber: #e6b25f;
		--wp--preset--color--amber-soft: #332616;
		--cs-shadow-1: 0 1px 2px rgba(0, 0, 0, 0.34);
		--cs-shadow-2: 0 1px 2px rgba(0, 0, 0, 0.36), 0 2px 6px rgba(0, 0, 0, 0.3);
		--cs-shadow-3: 0 2px 4px rgba(0, 0, 0, 0.38), 0 10px 26px rgba(0, 0, 0, 0.4);
		--cs-grain: rgba(255, 250, 240, 0.035);
	}

	/* Filled teal buttons need dark ink in dark mode, never white. Outline
	   buttons are handled separately below, where the ink must stay light. */
	.wp-element-button,
	.wp-block-button__link {
		color: #0b2622 !important;
	}
}

/* ==========================================================================
   1b. OUTLINE BUTTONS
   Core's is-style-outline draws its border from currentColor, so the ink has
   to be set explicitly or the button disappears against a dark section.
   ========================================================================== */

.wp-block-button.is-style-outline > .wp-element-button {
	background-color: transparent;
	color: var(--wp--preset--color--teal) !important;
	border: 1.5px solid currentColor;
	transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease;
}

.wp-block-button.is-style-outline > .wp-element-button:hover,
.wp-block-button.is-style-outline > .wp-element-button:focus-visible {
	background-color: var(--wp--preset--color--teal);
	color: #fff !important;
	border-color: var(--wp--preset--color--teal);
}

@media (prefers-color-scheme: dark) {
	.wp-block-button.is-style-outline > .wp-element-button:hover,
	.wp-block-button.is-style-outline > .wp-element-button:focus-visible {
		color: #0b2622 !important;
	}
}

/* On the night-coloured hero the outline button reads as a quiet secondary
   action: warm off-white ink, hairline border, fills teal on hover. */
.cs-hero .wp-block-button.is-style-outline > .wp-element-button {
	color: #f3f0ea !important;
	border-color: rgba(243, 240, 234, 0.38);
}

.cs-hero .wp-block-button.is-style-outline > .wp-element-button:hover,
.cs-hero .wp-block-button.is-style-outline > .wp-element-button:focus-visible {
	background-color: #5fcfbd;
	border-color: #5fcfbd;
	color: #0b2622 !important;
}

body {
	background-color: var(--wp--preset--color--paper);
	color: var(--wp--preset--color--ink);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

/* ==========================================================================
   2. TYPOGRAPHY DETAIL
   ========================================================================== */

h1 em,
.cs-display em {
	font-style: italic;
}

p,
li {
	text-wrap: pretty;
}

h1, h2, h3, h4 {
	text-wrap: balance;
}

/* Every camera value — f/5.6, 1/250s, ISO 3200 — is monospace with tabular
   figures so columns of settings align the way they do on a cheat sheet. */
code,
kbd,
.cs-val,
.cs-path {
	font-family: var(--wp--preset--font-family--mono);
	font-variant-numeric: tabular-nums;
	font-feature-settings: "ss01" on;
}

:where(.entry-content, .cs-prose) code {
	background: var(--wp--preset--color--teal-soft);
	color: var(--wp--preset--color--teal);
	border-radius: 4px;
	padding: 0.12em 0.4em;
	font-size: 0.88em;
	letter-spacing: -0.01em;
}

/* Eyebrow: small caps label above a heading. */
.cs-eyebrow {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem !important;
	font-weight: 500;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--wp--preset--color--teal);
	margin-bottom: 0.6rem !important;
	display: flex;
	align-items: center;
	gap: 0.6rem;
}

.cs-eyebrow::after {
	content: "";
	flex: 1 1 auto;
	height: 1px;
	background: var(--cs-border);
}

.cs-lede {
	font-size: var(--wp--preset--font-size--lg);
	color: var(--wp--preset--color--ink-soft);
	line-height: 1.55;
	max-width: 42ch;
}

/* Menu path chip: renders "I.Q > IMAGE QUALITY" like the camera's own menu. */
.cs-path {
	display: inline-block;
	font-size: 0.8125rem;
	letter-spacing: 0.02em;
	background: var(--wp--preset--color--sunken);
	border: 1px solid var(--cs-border);
	border-radius: 4px;
	padding: 0.15em 0.5em;
	color: var(--wp--preset--color--ink-soft);
	white-space: nowrap;
}

/* ==========================================================================
   3. LAYOUT + SURFACES
   ========================================================================== */

.cs-section {
	padding-block: clamp(3rem, 7vw, 6rem);
	position: relative;
}

.cs-section--tight {
	padding-block: clamp(2rem, 4vw, 3.5rem);
}

/* A raised "print laid on the paper": white card, hairline edge, soft shadow. */
.cs-card {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-radius: 12px;
	box-shadow: var(--cs-shadow-2);
}

.cs-card--flat {
	box-shadow: none;
}

/* Interactive card: the whole tile lifts on hover. */
.cs-tile {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-radius: 12px;
	box-shadow: var(--cs-shadow-1);
	transition: transform var(--cs-dur, 180ms) cubic-bezier(0.22, 1, 0.36, 1),
		box-shadow 180ms cubic-bezier(0.22, 1, 0.36, 1),
		border-color 180ms ease;
	height: 100%;
}

.cs-tile:hover,
.cs-tile:focus-within {
	transform: translateY(-3px);
	box-shadow: var(--cs-shadow-3);
	border-color: var(--wp--preset--color--teal);
}

.cs-tile a:where(:not(.wp-element-button)) {
	text-decoration: none;
}

.cs-tile a:where(:not(.wp-element-button)):hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Sunken well: quiet panel inside a card or on the page. */
.cs-well {
	background: var(--wp--preset--color--sunken);
	border-radius: 10px;
}

/* Hairline divider used between prose sections. */
.cs-rule {
	border: 0;
	border-top: 1px solid var(--cs-border);
	margin-block: 0;
}

/* ==========================================================================
   4. CONTACT-SHEET TEXTURE
   A faint 3:2 frame grid, printed behind dark sections only. Decorative.
   ========================================================================== */

.cs-sheet {
	position: relative;
	isolation: isolate;
	overflow: hidden;
}

.cs-sheet::before {
	content: "";
	position: absolute;
	inset: -1px;
	z-index: -1;
	background-image: linear-gradient(to right, var(--cs-grain) 1px, transparent 1px),
		linear-gradient(to bottom, var(--cs-grain) 1px, transparent 1px);
	background-size: 90px 60px;
	pointer-events: none;
}

/* ==========================================================================
   5. CALLOUTS — the citation / confidence system
   Usage: a core/group with class cs-note cs-note--official etc.
   ========================================================================== */

/* Callouts, answer blocks and cards are self-contained boxes, and their own
   padding is the only inset they should have. Because these are constrained-
   layout groups, WordPress also caps their children at the global content size
   and centres them with auto margins — which on a box wider than that content
   size reads as a stray left indent that does not line up with the surrounding
   prose. The box owns its inset; the children fill it. */
.cs-note > *,
.cs-answer > *,
.cs-card > *,
.cs-tile > *,
.cs-well > * {
	max-width: none;
	margin-left: 0;
	margin-right: 0;
}

.cs-note {
	border-radius: 10px;
	border: 1px solid var(--cs-border);
	border-left: 3px solid var(--wp--preset--color--ink-muted);
	background: var(--wp--preset--color--sunken);
	padding: var(--wp--preset--spacing--30) var(--wp--preset--spacing--40);
}

.cs-note > *:first-child {
	margin-top: 0;
}

.cs-note > *:last-child {
	margin-bottom: 0;
}

.cs-note__label {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem !important;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	font-weight: 500;
	margin-bottom: 0.35rem !important;
}

.cs-note--official {
	border-left-color: #1d5b8f;
	background: #e3eef8;
}

.cs-note--official .cs-note__label {
	color: #1d5b8f;
}

.cs-note--start {
	border-left-color: var(--wp--preset--color--teal);
	background: var(--wp--preset--color--teal-soft);
}

.cs-note--start .cs-note__label {
	color: var(--wp--preset--color--teal);
}

.cs-note--warn {
	border-left-color: var(--wp--preset--color--amber);
	background: var(--wp--preset--color--amber-soft);
}

.cs-note--warn .cs-note__label {
	color: var(--wp--preset--color--amber);
}

.cs-note--mistake {
	border-left-color: #a62b20;
	background: #fbe7e4;
}

.cs-note--mistake .cs-note__label {
	color: #a62b20;
}

@media (prefers-color-scheme: dark) {
	.cs-note--official {
		border-left-color: #84b8e8;
		background: #152836;
	}

	.cs-note--official .cs-note__label {
		color: #84b8e8;
	}

	.cs-note--mistake {
		border-left-color: #f19488;
		background: #3a1f1b;
	}

	.cs-note--mistake .cs-note__label {
		color: #f19488;
	}
}

/* ==========================================================================
   6. ANSWER BLOCK — the progressive-disclosure promise: the short answer
   first, detail underneath.
   ========================================================================== */

.cs-answer {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-left: 4px solid var(--wp--preset--color--teal);
	border-radius: 12px;
	box-shadow: var(--cs-shadow-2);
	padding: var(--wp--preset--spacing--40);
}

.cs-answer p {
	font-size: var(--wp--preset--font-size--lg);
	line-height: 1.5;
}

.cs-answer > *:first-child {
	margin-top: 0;
}

.cs-answer > *:last-child {
	margin-bottom: 0;
}

/* Settings strip: the row of camera values under an answer. */
.cs-strip {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.cs-strip .cs-val,
.cs-val--chip {
	display: inline-block;
	font-size: 0.875rem;
	line-height: 1.2;
	padding: 0.42em 0.6em;
	border-radius: 6px;
	background: var(--wp--preset--color--sunken);
	border: 1px solid var(--cs-border);
	color: var(--wp--preset--color--ink);
	white-space: nowrap;
}

/* ==========================================================================
   7. DETAILS / ACCORDION
   ========================================================================== */

.entry-content details,
.cs-prose details {
	border: 1px solid var(--cs-border);
	border-radius: 10px;
	background: var(--wp--preset--color--card);
	padding: 0.9rem 1.1rem;
	margin-block: 1rem;
}

.entry-content details > summary,
.cs-prose details > summary {
	cursor: pointer;
	font-weight: 600;
	list-style: none;
	display: flex;
	align-items: center;
	gap: 0.6rem;
	min-height: 1.8rem;
	color: var(--wp--preset--color--ink);
}

.entry-content details > summary::-webkit-details-marker,
.cs-prose details > summary::-webkit-details-marker {
	display: none;
}

.entry-content details > summary::before,
.cs-prose details > summary::before {
	content: "+";
	font-family: var(--wp--preset--font-family--mono);
	color: var(--wp--preset--color--teal);
	font-weight: 500;
	width: 1.2em;
	text-align: center;
	flex: none;
}

.entry-content details[open] > summary::before,
.cs-prose details[open] > summary::before {
	content: "–";
}

/* ==========================================================================
   8. FOCUS + MOTION
   ========================================================================== */

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
	outline: 3px solid var(--cs-focus);
	outline-offset: 2px;
	border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 1ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 1ms !important;
		scroll-behavior: auto !important;
	}

	.cs-tile:hover {
		transform: none;
	}
}

/* ==========================================================================
   9. TABLES — settings references and cheat sheets
   ========================================================================== */

.wp-block-table {
	margin-block: 1.5rem;
}

.wp-block-table table {
	border-collapse: collapse;
	width: 100%;
	font-size: var(--wp--preset--font-size--sm);
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-radius: 10px;
	overflow: hidden;
}

.wp-block-table thead {
	border-bottom: 1px solid var(--wp--preset--color--ink-muted);
}

.wp-block-table th {
	text-align: left;
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 500;
	color: var(--wp--preset--color--ink-soft);
	background: var(--wp--preset--color--sunken);
	padding: 0.7rem 0.85rem;
	border: 0;
}

.wp-block-table td {
	padding: 0.7rem 0.85rem;
	border: 0;
	border-top: 1px solid var(--cs-border);
	vertical-align: top;
	line-height: 1.45;
}

.wp-block-table tbody tr:nth-child(even) td {
	background: color-mix(in srgb, var(--wp--preset--color--sunken) 55%, transparent);
}

/* First column of a settings table reads as a label. */
.wp-block-table.cs-table--spec td:first-child {
	font-weight: 600;
	white-space: nowrap;
}

/* Values column set in mono so f-numbers and shutter speeds align. */
.wp-block-table.cs-table--values td:not(:first-child) {
	font-family: var(--wp--preset--font-family--mono);
	font-variant-numeric: tabular-nums;
	font-size: 0.875rem;
}

/* Narrow screens: a settings table is data, so let it scroll sideways rather
   than crushing three columns into unreadable slivers. */
@media (max-width: 782px) {
	.wp-block-table {
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: thin;
	}

	.wp-block-table table {
		min-width: 32rem;
	}

	.wp-block-table td,
	.wp-block-table th {
		padding: 0.6rem 0.7rem;
	}

	.wp-block-table figcaption {
		position: sticky;
		inset-inline-start: 0;
	}
}

.wp-block-table figcaption {
	font-size: var(--wp--preset--font-size--xs);
	color: var(--wp--preset--color--ink-muted);
	text-align: left;
	margin-top: 0.5rem;
}

/* Lists: tighter, with teal markers. */
.entry-content ul,
.cs-prose ul {
	padding-left: 1.15rem;
}

.entry-content ul li::marker,
.cs-prose ul li::marker {
	color: var(--wp--preset--color--teal);
}

.entry-content li + li,
.cs-prose li + li {
	margin-top: 0.35rem;
}

.entry-content ol,
.cs-prose ol {
	padding-left: 1.3rem;
}

.entry-content ol li::marker,
.cs-prose ol li::marker {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.9em;
	color: var(--wp--preset--color--teal);
}

/* ==========================================================================
   10. HEADER + FOOTER
   ========================================================================== */

.cs-header {
	position: sticky;
	top: 0;
	z-index: 200;
	background: color-mix(in srgb, var(--wp--preset--color--paper) 88%, transparent);
	-webkit-backdrop-filter: saturate(160%) blur(10px);
	backdrop-filter: saturate(160%) blur(10px);
	border-bottom: 1px solid var(--cs-border);
}

.cs-brand {
	font-family: var(--wp--preset--font-family--display);
	font-size: 1.35rem;
	line-height: 1;
	letter-spacing: -0.01em;
	text-decoration: none !important;
	color: var(--wp--preset--color--ink) !important;
}

.cs-brand__mark {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--teal);
	display: block;
}

.cs-header .wp-block-navigation {
	font-size: var(--wp--preset--font-size--sm);
	font-weight: 500;
}

.cs-header .wp-block-navigation a {
	text-decoration: none;
	color: var(--wp--preset--color--ink-soft);
	padding-block: 0.4rem;
}

.cs-header .wp-block-navigation a:hover {
	color: var(--wp--preset--color--teal);
}

.cs-header .wp-block-navigation .current-menu-item a,
.cs-header .wp-block-navigation .wp-block-navigation-item.current-menu-item > a {
	color: var(--wp--preset--color--teal);
}

.cs-header .wp-block-navigation__responsive-container.is-menu-open {
	background: var(--wp--preset--color--paper);
	color: var(--wp--preset--color--ink);
}

.cs-footer {
	border-top: 1px solid var(--cs-border);
	background: var(--wp--preset--color--sunken);
	font-size: var(--wp--preset--font-size--sm);
}

.cs-footer a {
	color: var(--wp--preset--color--ink-soft);
	text-decoration: none;
}

.cs-footer a:hover {
	color: var(--wp--preset--color--teal);
	text-decoration: underline;
}

/* Footer link columns read as lists of links, not bulleted prose. */
.cs-footer .wp-block-list {
	list-style: none;
	padding-left: 0;
	margin: 0;
}

.cs-footer .wp-block-list li::marker {
	content: "";
}

/* ==========================================================================
   11. HERO
   ========================================================================== */

.cs-hero {
	background: var(--wp--preset--color--night);
	color: #f3f0ea;
	border-bottom: 1px solid var(--wp--preset--color--rule);
}

.cs-hero h1,
.cs-hero h2,
.cs-hero p,
.cs-hero li {
	color: #f3f0ea;
}

.cs-hero .cs-lede {
	color: #c7c1b6;
}

.cs-hero .cs-eyebrow {
	color: #5fcfbd;
}

.cs-hero .cs-eyebrow::after {
	background: #4b463e;
}

.cs-hero .cs-val--chip {
	background: rgba(255, 255, 255, 0.06);
	border-color: #4b463e;
	color: #f3f0ea;
}

.cs-hero .cs-title {
	font-family: var(--wp--preset--font-family--display);
	font-weight: 400;
	line-height: 0.98;
	letter-spacing: -0.02em;
}

.cs-hero .cs-title em {
	color: #5fcfbd;
}

/* Aperture-blade motif: a soft lens-coating flare off the right edge of the
   hero. Decorative only, drawn from the section itself so no extra markup is
   needed in the editor. */
.cs-hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
}

.cs-hero::after {
	content: "";
	position: absolute;
	inset-inline-end: -10rem;
	top: 50%;
	translate: 0 -50%;
	width: 42rem;
	height: 42rem;
	border-radius: 50%;
	background:
		radial-gradient(circle at 50% 50%, rgba(95, 207, 189, 0.14) 0%, rgba(95, 207, 189, 0.05) 38%, transparent 60%);
	box-shadow:
		inset 0 0 0 1px rgba(95, 207, 189, 0.16),
		inset 0 0 0 7rem rgba(95, 207, 189, 0.05),
		inset 0 0 0 14rem rgba(95, 207, 189, 0.04);
	pointer-events: none;
	z-index: -1;
}

@media (max-width: 781px) {
	.cs-hero::after {
		width: 26rem;
		height: 26rem;
		inset-inline-end: -11rem;
		top: 22%;
		translate: 0 0;
	}
}

/* ==========================================================================
   12. SENSEI LMS
   Course outline, progress, lesson actions and quizzes restyled as workbook
   furniture instead of default LMS chrome.
   ========================================================================== */

/* ---- Course outline ---------------------------------------------------- */

.wp-block-sensei-lms-course-outline {
	border: 1px solid var(--cs-border);
	border-radius: 12px;
	background: var(--wp--preset--color--card);
	box-shadow: var(--cs-shadow-2);
	overflow: hidden;
}

.sensei-course-theme .wp-block-sensei-lms-course-outline {
	box-shadow: none;
}

.wp-block-sensei-lms-course-outline__progress-bar-container,
.sensei-course-theme-course-progress-bar,
.sensei-progress-bar {
	background: var(--wp--preset--color--sunken) !important;
	border-radius: 999px;
	height: 6px !important;
	overflow: hidden;
}

.wp-block-sensei-lms-course-outline__progress-bar-inner,
.sensei-progress-bar__bar,
.sensei-course-theme-course-progress-bar__bar {
	background: var(--wp--preset--color--teal) !important;
	border-radius: 999px;
	height: 6px !important;
}

.wp-block-sensei-lms-course-outline-module {
	border: 0 !important;
	border-top: 1px solid var(--cs-border) !important;
}

.wp-block-sensei-lms-course-outline-module:first-child {
	border-top: 0 !important;
}

.wp-block-sensei-lms-course-outline-module__name,
.wp-block-sensei-lms-collapsible__header h2,
.wp-block-sensei-lms-collapsible__header h3 {
	font-family: var(--wp--preset--font-family--sans) !important;
	font-size: var(--wp--preset--font-size--lg) !important;
	font-weight: 600 !important;
	letter-spacing: -0.015em;
}

.wp-block-sensei-lms-course-outline-module__header,
.wp-block-sensei-lms-collapsible__header {
	background: var(--wp--preset--color--sunken) !important;
	color: var(--wp--preset--color--ink) !important;
	padding: 1rem 1.25rem !important;
}

.wp-block-sensei-lms-course-outline-module__description {
	color: var(--wp--preset--color--ink-soft);
	font-size: var(--wp--preset--font-size--sm);
}

.wp-block-sensei-lms-course-outline-lesson {
	border-top: 1px solid var(--cs-border) !important;
	padding: 0.9rem 1.25rem !important;
	font-size: var(--wp--preset--font-size--base) !important;
	color: var(--wp--preset--color--ink) !important;
	text-decoration: none !important;
	transition: background 140ms ease, padding-inline-start 140ms ease;
}

.wp-block-sensei-lms-course-outline-lesson:hover {
	background: var(--wp--preset--color--teal-soft) !important;
	color: var(--wp--preset--color--teal) !important;
}

.wp-block-sensei-lms-course-outline-lesson .wp-block-sensei-lms-course-outline-lesson__title {
	font-weight: 500;
}

.wp-block-sensei-lms-course-outline-lesson.completed .wp-block-sensei-lms-course-outline-lesson__title {
	color: var(--wp--preset--color--ink-muted) !important;
}

.wp-block-sensei-lms-course-outline-lesson svg {
	color: var(--wp--preset--color--teal);
}

/* ---- Lesson chrome ---------------------------------------------------- */

.wp-block-sensei-lms-lesson-properties,
.sensei-lesson-meta,
.wp-block-sensei-lms-learning-mode-lesson-properties {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.78rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--wp--preset--color--ink-muted);
}

.wp-block-sensei-lms-lesson-actions .wp-block-button__link,
.wp-block-sensei-lms-course-actions .wp-block-button__link {
	border-radius: 6px;
}

/* ---- Quiz ------------------------------------------------------------- */

.sensei-quiz,
.wp-block-sensei-lms-quiz {
	margin-top: 1.5rem;
}

.sensei-quiz-question,
.wp-block-sensei-lms-quiz-question {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-radius: 12px;
	box-shadow: var(--cs-shadow-1);
	padding: 1.25rem 1.4rem;
	margin-bottom: 1.25rem;
}

.sensei-quiz-question .question-title,
.sensei-quiz-question h2 {
	font-size: var(--wp--preset--font-size--lg) !important;
	font-weight: 600;
}

.sensei-quiz-question ul {
	list-style: none;
	padding-left: 0;
}

.sensei-quiz-question label {
	display: flex;
	gap: 0.6rem;
	align-items: flex-start;
	padding: 0.6rem 0.75rem;
	border: 1px solid var(--cs-border);
	border-radius: 8px;
	background: var(--wp--preset--color--paper);
	cursor: pointer;
	min-height: 44px;
	transition: border-color 140ms ease, background 140ms ease;
}

.sensei-quiz-question label:hover {
	border-color: var(--wp--preset--color--teal);
	background: var(--wp--preset--color--teal-soft);
}

.sensei-quiz-question input[type="radio"],
.sensei-quiz-question input[type="checkbox"] {
	accent-color: var(--wp--preset--color--teal);
	margin-top: 0.2rem;
}

.sensei-course-theme .sensei-quiz-actions {
	border-top: 1px solid var(--cs-border);
	padding-top: 1rem;
}

/* ---- Learning mode --------------------------------------------------- */

/* Sensei's course theme ships its own type scale; restate ours so lesson
   prose keeps the workbook hierarchy. */
.sensei-course-theme .entry-content h2,
.sensei-course-theme .entry-content h3,
.sensei-course-theme .entry-content h4 {
	font-family: var(--wp--preset--font-family--sans);
	letter-spacing: -0.018em;
	line-height: 1.22;
	color: var(--wp--preset--color--ink);
	margin-top: 2.4rem;
	margin-bottom: 0.85rem;
}

.sensei-course-theme .entry-content h2 {
	font-size: var(--wp--preset--font-size--2-xl);
	font-weight: 600;
	padding-bottom: 0.5rem;
	border-bottom: 1px solid var(--cs-border);
}

.sensei-course-theme .entry-content h3 {
	font-size: var(--wp--preset--font-size--xl);
	font-weight: 600;
}

.sensei-course-theme .entry-content h4 {
	font-size: var(--wp--preset--font-size--lg);
	font-weight: 600;
}

.sensei-course-theme .entry-content > p,
.sensei-course-theme .entry-content > ul,
.sensei-course-theme .entry-content > ol {
	font-size: var(--wp--preset--font-size--base);
	line-height: 1.62;
}

.sensei-course-theme .entry-content .cs-note__label,
.sensei-course-theme .entry-content .cs-eyebrow {
	margin-top: 0 !important;
	border-bottom: 0;
}

/* Sensei's course theme ships its own font stack; put ours back. */
.sensei-course-theme,
.sensei-course-theme__frame,
.sensei-course-theme button,
.sensei-course-theme input,
.sensei-course-theme .sensei-lms-course-navigation,
.sensei-course-theme .wp-block-button__link {
	font-family: var(--wp--preset--font-family--sans);
}

/* Sensei renders lesson actions with is-style-outline; the primary action on a
   lesson should read as the primary action. */
.sensei-course-theme .wp-block-button.is-style-outline > .wp-block-button__link,
.sensei-course-theme .wp-block-sensei-lms-button-complete-lesson .wp-block-button__link {
	background-color: var(--wp--preset--color--teal);
	border: 1px solid var(--wp--preset--color--teal);
	color: #fff;
	border-radius: 6px;
	font-size: var(--wp--preset--font-size--sm);
	font-weight: 500;
	padding: 0.8rem 1.35rem;
}

.sensei-course-theme .wp-block-button.is-style-outline > .wp-block-button__link:hover,
.sensei-course-theme .wp-block-sensei-lms-button-complete-lesson .wp-block-button__link:hover {
	background-color: var(--wp--preset--color--teal-deep);
	border-color: var(--wp--preset--color--teal-deep);
}

@media (prefers-color-scheme: dark) {
	.sensei-course-theme .wp-block-button.is-style-outline > .wp-block-button__link,
	.sensei-course-theme .wp-block-sensei-lms-button-complete-lesson .wp-block-button__link {
		color: #0b2622;
	}
}

/* Reset / secondary lesson actions stay quiet. */
.sensei-course-theme .wp-block-sensei-lms-button-reset-lesson .wp-block-button__link {
	background-color: transparent;
	border-color: var(--cs-border);
	color: var(--wp--preset--color--ink-soft);
}

/* Lesson chrome buttons: filled teal, matching the rest of the site. */
.sensei-course-theme .wp-block-button__link,
.sensei-course-theme .sensei-course-theme__button.is-primary,
.sensei-course-theme button.is-primary {
	background-color: var(--wp--preset--color--teal);
	border-color: var(--wp--preset--color--teal);
	color: #fff;
	border-radius: 6px;
	font-weight: 500;
}

@media (prefers-color-scheme: dark) {
	.sensei-course-theme .wp-block-button__link,
	.sensei-course-theme .sensei-course-theme__button.is-primary,
	.sensei-course-theme button.is-primary {
		color: #0b2622;
	}
}

.sensei-course-theme .wp-block-button__link:hover,
.sensei-course-theme button.is-primary:hover {
	background-color: var(--wp--preset--color--teal-deep);
	border-color: var(--wp--preset--color--teal-deep);
}

/* Sidebar: module names as workbook section labels. */
.sensei-course-theme .sensei-lms-course-navigation-module__title {
	font-family: var(--wp--preset--font-family--sans);
	font-size: var(--wp--preset--font-size--base);
	font-weight: 600;
	letter-spacing: -0.01em;
	color: var(--wp--preset--color--teal);
}

.sensei-course-theme .sensei-lms-course-navigation-lesson__title {
	font-size: var(--wp--preset--font-size--sm);
	line-height: 1.4;
}

.sensei-course-theme .sensei-lms-course-navigation-module__lessons {
	border-left: 1px solid var(--cs-border);
	margin-left: 0.35rem;
	padding-left: 0.65rem;
}

.sensei-course-theme .sensei-lms-course-navigation-lesson--status-completed .sensei-lms-course-navigation-lesson__title {
	color: var(--wp--preset--color--ink-muted);
}

.sensei-course-theme__sidebar,
.sensei-course-theme__frame {
	background: var(--wp--preset--color--paper);
}

.sensei-course-theme__sidebar {
	border-inline-end: 1px solid var(--cs-border);
}

.sensei-course-theme__header,
.sensei-course-theme__top-right-menu {
	background: transparent;
}

/* ---- Course cards on the Courses archive ----------------------------- */

.course-container .course,
.sensei-course-list .wp-block-post {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--cs-border);
	border-radius: 12px;
	padding: 1.25rem;
	box-shadow: var(--cs-shadow-1);
}

.wp-block-sensei-lms-course-categories a,
.course-category a {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.72rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	text-decoration: none;
	background: var(--wp--preset--color--teal-soft);
	color: var(--wp--preset--color--teal);
	border-radius: 999px;
	padding: 0.3em 0.7em;
}

/* Sensei notices */
.sensei-message,
.sensei-course-theme-notices .sensei-notice {
	border-radius: 10px;
	border: 1px solid var(--cs-border);
	border-left: 3px solid var(--wp--preset--color--teal);
	background: var(--wp--preset--color--teal-soft);
	color: var(--wp--preset--color--ink);
	font-size: var(--wp--preset--font-size--sm);
}

/* ==========================================================================
   13. PRINT — cheat sheets must survive a printer
   ========================================================================== */

@media print {
	.cs-header,
	.cs-footer,
	.wp-block-navigation,
	.wp-block-sensei-lms-lesson-actions,
	.cs-no-print {
		display: none !important;
	}

	:root {
		--wp--preset--color--paper: #ffffff;
		--wp--preset--color--card: #ffffff;
		--wp--preset--color--sunken: #f4f4f4;
		--wp--preset--color--ink: #000000;
	}

	body {
		background: #fff;
		color: #000;
		font-size: 11pt;
	}

	.cs-card,
	.cs-tile,
	.cs-answer,
	.cs-note,
	.wp-block-table table {
		box-shadow: none !important;
		border: 1px solid #999 !important;
		break-inside: avoid;
	}

	.cs-hero {
		background: #fff !important;
		color: #000 !important;
	}

	.cs-hero h1,
	.cs-hero p,
	.cs-hero .cs-lede,
	.cs-hero .cs-eyebrow {
		color: #000 !important;
	}

	.cs-section {
		padding-block: 0.5rem;
	}

	details {
		break-inside: avoid;
	}

	details > *:not(summary) {
		display: revert !important;
	}
}
