/**
 * The Vala - front-end styles.
 *
 * Colors and sizes come from theme.json presets (--wp--preset--*); fonts from fonts.css (--font-serif, --font-sans). This file maps them onto the
 * vala-lessons custom properties (--vala-*), sets the layout (top bar, dashboard sidebar, footer), and styles
 * the templates and Vala blocks to match /mockups/. The mockups are left-aligned; the site is centered.
 *
 *   1. Tokens
 *   2. Base (resets over Cosmos, typography, links, buttons, forms)
 *   3. Layout (site, top bar, sidebar, footer)
 *   4. Templates (page header, content, lesson, course)
 *   5. Vala blocks (cards, grids, nav, lesson media, library, seasonal, forms, locked page, My Page)
 *   6. Utilities
 */

/* ==================================================================
 * 1. Tokens
 * ================================================================== */

:root {
	--white: var(--wp--preset--color--white, #FFFFFF);
	--chalk: var(--wp--preset--color--chalk, #F5F3EF);
	--linen: var(--wp--preset--color--chalk, #F5F3EF);
	--sand: var(--wp--preset--color--chalk, #F5F3EF);
	--line: var(--wp--preset--color--line, #E6D3BD);
	--stone: var(--wp--preset--color--stone, #5A6362);
	--ink: var(--wp--preset--color--ink, #1E2B2C);
	--moss: var(--wp--preset--color--moss, #30635C);
	--moss-deep: var(--wp--preset--color--moss-deep, #30635C);

	/*	NEW COLOR*/
	--chalk-deep: var(--wp--preset--color--chalk, #EDE6D8);
	--blackthorn: var(--wp--preset--color--blackthorn, #1E2B2C);
	--blackthorn-muted: var(--wp--preset--color--black-muted, #5A6362);
	--copper-light: var(--wp--preset--color--copper, #E1AD79);
	--copper-soft: var(--wp--preset--color--copper-soft, #E6D3BD);
	--copper-deep: var(--wp--preset--color--copper-deep, #9B683D);
	--juniper: var(--wp--preset--color--juniper, #30635C);
	--sea-glass-deep: var(--wp--preset--color--sea-glass-deep, #367670);
	--sea-glass: var(--wp--preset--color--sea-glass, #44918B);
	--madder-red: var(--wp--preset--color--madder-red, #C0392B);
	--madder-tint: var(--wp--preset--color--madder-tint, #F6E3DF);

	/* --font-serif and --font-sans are defined in fonts.css */

	--content-size: var(--wp--style--global--content-size, 760px);
	--wide-size: var(--wp--style--global--wide-size, 1160px);
	--gutter: clamp(1.25rem, 4vw, 3rem);
	--sidebar-width: clamp(260px, 22vw, 300px);
	--header-height: 76px;

	/* Type scale for sans UI text. */
	--text-xs: 0.6875rem;   /* 11px: eyebrows, small caps labels, nav items */
	--text-sm: 0.875rem;   /* 14px: meta lines, links, descriptions */
	--text-md: 1.0625rem;   /* 17px: inputs, emphasized UI text */
	--text-button: 0.75rem;  /* 12px: buttons */
	--size-14: 0.875rem; /* 14px */
	--size-15: 0.9375rem; /* 15px */
	--size-16: 1rem; /* 16px */
	--size-20: 1.25rem;   /* 20px */
	--size-24: 1.5rem; /* 24px */
	--size-30: 1.875rem;  /* 30px */
	--size-34: 2.125rem;  /* 34px */
	--size-40: 2.5rem;    /* 40px */
	--size-56: 3.5rem; /* 56px */

	/* vala-lessons */
	--vala-accent: var(--juniper);
	--vala-accent-contrast: #f2efe6;
	--vala-text: var(--blackthorn);
	--vala-muted: var(--blackthorn);
	--vala-surface: var(--chalk);
	--vala-surface-alt: var(--linen);
	--vala-border: var(--copper-soft);
	--vala-radius: 0px;
	--vala-gap: clamp(1.25rem, 2.5vw, 2rem);
	--vala-shadow: none;
	--vala-locked-opacity: 0.55;
}

/* ==================================================================
 * 2. Base
 * ================================================================== */

/*
 * Cosmos sets html { font-size: 62.5% } (1rem = 10px). theme.json presets and vala-lessons assume the browser
 * default (1rem = 16px), so restore it.
 */
html {
	font-size: 100%;
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	background: var(--white);
	color: var(--blackthorn);
	font-family: var(--font-sans);
	font-size: var(--size-16);
	font-weight: 400;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

/* Highlighted text: a pale sea-glass, visible against the chalk and white backgrounds */
::selection {
	background: #D0E4E2;
	color: var(--blackthorn);
}

img {
	max-width: 100%;
	height: auto;
}

h1, h2, h3, h4 {
	margin: 0 0 0.5em;
	font-family: var(--font-serif);
	font-weight: 400;
	line-height: 1.15;
	color: var(--blackthorn);
	letter-spacing: 0;
	text-transform: none;
}

h1 {
	font-size: var(--size-56);
}

h2 {
	font-size: var(--size-34);
}

h3 {
	font-size: var(--size-24);
}

h4 {
	font-size: var(--size-20);
}

p {
	margin: 0 0 1em;
}

a {
	color: var(--juniper);
	text-decoration-color: var(--juniper);
	text-underline-offset: 0.2em;
	text-decoration-thickness: 1px;
	transition: color 0.15s ease;
}

a:hover {
	color: var(--blackthorn);
}

:focus-visible {
	outline: 2px solid var(--juniper);
	outline-offset: 3px;
}

hr,
.wp-block-separator {
	border: 0;
	border-top: 1px solid var(--copper-soft);
	margin: 2.5rem 0;
}

blockquote {
	margin: 1.5rem 0;
	padding: 0 0 0 1.25rem;
	border-left: 1px solid var(--juniper);
	font-style: italic;
	color: var(--blackthorn);
}

/* Small caps label used above titles (eyebrow) */
.eyebrow, h6,
.vala-card__label,
.vala-celebration__eyebrow,
.vala-moon__eyebrow,
.lesson-content h6,
.vala-module__number,
.vala-acard__category, 
.vala-resource__label, 
.vala-month-card__eyebrow, 
.vala-gatherings__label, 
.vala-worksheet__eyebrow, 
.vala-thresholds__subtitle, 
.vala-arc-rings__eyebrow, 
.vala-arc-rings__label, 
.vala-alibrary__rail-title, 
.vala-courses-of-study__row--head, 
.vala-steps__hint,
.vala-acard__link .vala-pill,
.vala-library__filter,
.vala-resource-grid__heading {
	margin: 0 0 0.75rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn-muted);
}

/* Eyebrow as a back link: "← Belonging to Place" */
.eyebrow--back .back-link {
	color: var(--blackthorn-muted);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: color 0.15s ease, border-color 0.15s ease;
}

.eyebrow--back .back-link:hover {
	color: var(--blackthorn);
	border-bottom-color: var(--juniper);
}

.back-link__arrow {
	display: inline-block;
	margin-right: 0.35em;
	transition: transform 0.15s ease;
}

.eyebrow--back .back-link:hover .back-link__arrow {
	transform: translateX(-2px);
}

.eyebrow__sep {
	margin: 0 0.35em;
}

/* Small sans meta line: "32 min · Cosmology · Video" */
.meta {
	margin: 0;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	color: var(--blackthorn-muted);
}

/* Underlined text link: "View lesson" */
.text-link {
	display: inline-block;
	padding-bottom: 3px;
	border-bottom: 1px solid var(--juniper);
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	line-height: 1.2;
	color: var(--juniper);
	text-decoration: none;
}

.text-link:hover {
	color: var(--sea-glass-deep);
	border-bottom-color: var(--sea-glass-deep);
}

/* Buttons: solid moss, and an outlined secondary. Gravity Forms submit buttons too: the selector is specific enough
   to win over the Gravity Forms theme framework (surveys, lesson forms) */
.vala-button,
.gform_wrapper.gform-theme.gform-theme--framework .gform-footer button.gform_button.button,
.wp-block-button__link,
.wp-element-button,
.button.button-primary,
button.button,
a.button,
input[type="submit"],
input[type="submit"].button-primary {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5em;
	padding: 0.95rem 1.5rem;
	border: 1px solid var(--juniper);
	border-radius: 0;
	background: var(--juniper);
	color: var(--chalk);
	font-family: var(--font-btn);
	font-size: var(--text-button);
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.vala-button:hover,
.gform_wrapper.gform-theme.gform-theme--framework .gform-footer button.gform_button.button:hover,
.wp-block-button__link:hover,
.wp-element-button:hover,
.button.button-primary:hover,
button.button:hover,
a.button:hover,
input[type="submit"]:hover,
input[type="submit"].button-primary:hover {
	background: var(--sea-glass-deep);
	border-color: var(--sea-glass-deep);
	color: var(--chalk);
}

.vala-button:focus,
.gform_wrapper.gform-theme.gform-theme--framework .gform-footer button.gform_button.button:focus,
.wp-block-button__link:focus,
.wp-element-button:focus,
.button.button-primary:focus,
button.button:focus,
a.button:focus,
input[type="submit"]:focus,
input[type="submit"].button-primary:focus  {
    color: var(--chalk);
    outline: var(--sea-glass) solid 2px;
    outline-offset: 2px;
	box-shadow: none;
}

.vala-button--secondary,
.is-style-outline .wp-block-button__link {
	background: transparent;
	border-color: var(--juniper);
	color: var(--juniper);
}

.vala-button--secondary:hover,
.is-style-outline .wp-block-button__link:hover {
	background: rgb(48 99 92 / 20%);
	color: var(--juniper);
}

/* Forms. Gravity Forms single-line and paragraph fields too: the selectors are specific enough to win over the
   Gravity Forms theme framework */
.gform_wrapper.gform-theme.gform-theme--framework .ginput_container_text input[type="text"],
.gform_wrapper.gform-theme.gform-theme--framework .ginput_container_textarea textarea.textarea,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="url"],
input[type="tel"],
input[type="number"],
input[type="date"],
select,
textarea {
	width: 100%;
	max-width: 100%;
	padding: 0.7rem 0.9rem;
	border: 1px solid var(--copper-soft);
	border-radius: 0;
	background: var(--chalk);
	color: var(--blackthorn);
	font-family: var(--font-sans);
	font-size: var(--size-16);
	font-weight: 400;
	line-height: 1.4;
	box-shadow: none;
}

input[type="search"] {
    background-color: var(--chalk);
    color: var(--blackthorn);
    font-size: var(--size-16);
    padding: 1rem;
	margin-bottom: 0;
}


/* Checkboxes. Gravity Forms checkboxes too (not the .vala-scale rating boxes, which hide their inputs) */
input[type="checkbox"],
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 1px solid #858b8a;
  border-radius: 0;
  background: transparent;
  box-sizing: border-box;
  flex: 0 0 auto;
  cursor: pointer;
  display: inline-grid;
  place-content: center;
}

input[type="checkbox"]:checked,
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]:checked {
  background: var(--juniper);
  border-color: var(--juniper);
}

input[type="checkbox"]::before,
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]::before {
  content: "✓";
  color: var(--chalk);
  font-size: 12px;
  line-height: 1;
  transform: scale(0);
}

input[type="checkbox"]:checked::before,
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]:checked::before {
  transform: scale(1);
}

input[type="checkbox"]:focus-visible,
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--juniper);
  outline-offset: 2px;
}

/* No Gravity Forms focus ring (blue) after a click. Keyboard focus keeps the moss :focus-visible outline */
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]:focus:not(:focus-visible),
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"]:focus:not(:focus-visible) {
  outline: none;
}

/* Gravity Forms draws its tick with an icon font (marked !important): use the theme's ✓ instead */
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="checkbox"]::before {
  font-family: var(--font-sans) !important;
  opacity: 1;
}

/* Radio buttons (Gravity Forms): an 18px circle to match the checkboxes, with a moss dot when chosen */
.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 1px solid #858b8a;
  border-radius: 50%;
  background: transparent;
  box-sizing: border-box;
  box-shadow: none;
  flex: 0 0 auto;
  cursor: pointer;
  display: inline-grid;
  place-content: center;
}

.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"]:checked {
  border-color: var(--juniper);
}

.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"]::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--juniper);
  opacity: 1;
  transform: scale(0);
  transition: transform 0.12s ease;
}

.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"]:checked::before {
  transform: scale(1);
}

.gform_wrapper.gform-theme.gform-theme--framework .gfield:not(.vala-scale) input[type="radio"]:focus-visible {
  outline: 2px solid var(--juniper);
  outline-offset: 2px;
}

input:focus,
select:focus,
textarea:focus,
.gform_wrapper.gform-theme.gform-theme--framework .ginput_container_text input[type="text"]:focus,
.gform_wrapper.gform-theme.gform-theme--framework .ginput_container_textarea textarea.textarea:focus {
	outline: none;
	border-color: var(--copper-soft);
	background: var(--chalk--deep);
	box-shadow: none !important;
	color: var(--blockthorn);
}

input[type="email"]:focus, input[type="number"]:focus, input[type="search"]:focus, input[type="text"]:focus, input[type="tel"]:focus, input[type="url"]:focus, input[type="password"]:focus, textarea:focus, select:focus, .gform_wrapper.gform-theme.gform-theme--framework .ginput_container_text input[type="text"]:focus, .gform_wrapper.gform-theme.gform-theme--framework .ginput_container_textarea textarea.textarea:focus {
	background-color: var(--chalk);
	color: var(--blockthorn);
}

select:not([multiple]) {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 7'%3E%3Cpath fill='%235a6362' d='M0 0h12L6 7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 20px center;
  background-size: 12px 7px;
  padding: 15px 44px 15px 20px; /* 20px left, room for the caret on the right */
  border: 1px solid var(--copper-soft);
}

/* Filter applied: juniper caret, tint background, juniper border */
select:not([multiple]).is-filtered {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 7'%3E%3Cpath fill='%2330635c' d='M0 0h12L6 7z'/%3E%3C/svg%3E");
  background-color: #e0e3db;
  border-color: var(--juniper);
  color: var(--juniper);
}

/* Error: madder red caret and border */
select:not([multiple]).is-error {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 7'%3E%3Cpath fill='%23c0392b' d='M0 0h12L6 7z'/%3E%3C/svg%3E");
  border-color: #c0392b;
}

select:not([multiple]):not([data-vala-library-sort]):has(option:checked:not([value=""])) {
  border: 1px solid rgb(48, 99, 92);
  background-color: rgb(224, 227, 219);
  color: rgb(48, 99, 92);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 7'%3E%3Cpath fill='%2330635c' d='M0 0h12L6 7z'/%3E%3C/svg%3E");
}

label,
legend {
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	color: var(--blackthorn);
}

::placeholder {
	color: var(--blackthorn);
	opacity: 1;
}

.has-moss-deep-color {
	color: var(--juniper) !important;
}

/* ==================================================================
 * 3. Layout
 * ================================================================== */

.skip-link:focus {
	position: fixed;
	top: 0.5rem;
	left: 0.5rem;
	z-index: 100001;
	width: auto;
	height: auto;
	padding: 0.75rem 1rem;
	clip: auto;
	clip-path: none;
	background: var(--blackthorn);
	color: var(--chalk);
}

.site {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

.site-content {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.site-main {
	flex: 1;
	padding-bottom: clamp(3rem, 8vw, 6rem);
}

/* The site mark: the logo, or the site name if the logo file is missing */
.site-logo {
	display: inline-flex;
	align-items: center;
	font-family: var(--font-serif);
	font-size: 1.625rem;
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.01em;
	color: var(--blackthorn);
	text-decoration: none;
	white-space: nowrap;
}

.site-logo:hover {
	color: var(--blackthorn);
}

.site-logo__image {
	display: block;
	width: auto;
	height: 34px;
}

.site-sidebar .site-logo__image {
	height: 46px;
}

.site-logo--footer .site-logo__image {
	height: 26px;
	opacity: 0.75;
}

.site-logo--footer:hover .site-logo__image {
	opacity: 1;
}

/* Top bar: ruled, serif mark left, nav right */
.site-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--white);
	border-bottom: 1px solid var(--copper-soft);
}

.admin-bar .site-header {
	top: var(--wp-admin--admin-bar--height, 32px);
}

@media (max-width: 600px) {
	.admin-bar .site-header {
		top: 0;
	}
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 2rem;
	max-width: calc(var(--wide-size) + var(--gutter) * 2);
	min-height: var(--header-height);
	margin: 0 auto;
	padding: 0 var(--gutter);
}

.site-header__signin {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--blackthorn);
	text-decoration: none;
}

/* Dashboard: sidebar left, content right */
.vala-layout-sidebar .site {
	display: grid;
	grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
}

.site-sidebar {
	background: var(--linen);
	border-right: 1px solid var(--copper-soft);
}

/* Reset Cosmoso theme "aside" styles */
aside.site-sidebar {
	float: none;
	width: auto;
	margin-right: 0;
	word-wrap: normal;
}

.site-sidebar__inner {
	position: sticky;
	top: 0;
	display: flex;
	flex-direction: column;
	gap: 2.5rem;
	max-height: 100vh;
	overflow-y: auto;
	padding: 2.5rem 1.75rem 2rem;
}

.admin-bar .site-sidebar__inner {
	top: var(--wp-admin--admin-bar--height, 32px);
	max-height: calc(100vh - var(--wp-admin--admin-bar--height, 32px));
}

.site-sidebar .site-logo {
	font-size: 2rem;
}

@media (max-width: 900px) {
	.vala-layout-sidebar .site {
		display: flex;
	}

	.site-sidebar {
		border-right: 0;
		border-bottom: 1px solid var(--copper-soft);
	}

	.site-sidebar__inner {
		position: static;
		max-height: none;
		padding: 1.5rem var(--gutter);
		gap: 1.5rem;
	}
}

/* Footer */
.site-footer {
	margin-top: auto;
	padding: 0 var(--gutter);
}

.site-footer__inner {
	max-width: var(--wide-size);
	margin: 0 auto;
	border-top: 1px solid var(--copper-soft);
}

.site-footer__columns {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(2rem, 6vw, 5rem);
	padding: 3rem 0;
}

@media (max-width: 700px) {
	.site-footer__columns {
		grid-template-columns: 1fr;
	}
}

.site-footer__column p {
	max-width: 34em;
	font-size: var(--size-20);
	color: var(--blackthorn);
	font-family: var(--font-serif);
}

.site-footer__column .eyebrow {
	margin-bottom: 1rem;
}

.site-footer__search {
	display: flex;
	align-items: center;
	gap: 1rem;
	max-width: 22rem;
	border-bottom: 1px solid var(--copper-soft);
}

.site-footer__search input[type="search"] {
	flex: 1;
	padding: 0.5rem 0;
	border: 0;
	background: transparent;
	font-family: var(--font-serif);
	font-size: 1.125rem;
}

.site-footer__search button {
	padding: 0.5rem 0;
	border: 0;
	background: none;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--blackthorn);
	cursor: pointer;
}

.site-footer__bottom {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 1rem;
	padding: 1.5rem 0 2rem;
	border-top: 1px solid var(--copper-soft);
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	color: var(--blackthorn);
}

.vala-layout-public .site-footer__bottom {
	border-top: 0;
}

.site-footer__bottom p {
	margin: 0;
}

.site-footer__menu ul {
	display: flex;
	gap: 1.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-footer__menu a {
	color: var(--blackthorn);
	text-decoration: none;
}

/* ==================================================================
 * 4. Templates
 * ================================================================== */

/*
 * Constrained content. The page is a centered column at the wide width; reading text (content width) and wide
 * blocks share its left edge, so titles, text and grids line up as in the mockups.
 */
.is-layout-constrained > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
	max-width: var(--wide-size) !important;
	margin-left: auto !important;
	margin-right: auto !important;
}

.is-layout-constrained > .alignwide {
	max-width: var(--wide-size);
	margin-left: auto !important;
	margin-right: auto !important;
}

.has-global-padding {
	padding-left: var(--gutter);
	padding-right: var(--gutter);
}

.has-global-padding > .alignfull {
	margin-left: calc(var(--gutter) * -1) !important;
	margin-right: calc(var(--gutter) * -1) !important;
	max-width: none;
}

/* Vala blocks use the wide width by default: they are grids and layouts, not reading text */
.entry-content > .vala-grid,
.entry-content > .vala-library,
.entry-content > .vala-modules,
.entry-content > .vala-celebration,
.entry-content > .vala-moon,
.entry-content > .vala-moon-library,
.entry-content > .vala-favorites,
.entry-content > .vala-announcements,
.entry-content > .vala-lesson-nav,
.entry-content > [data-vala-slot],
.entry-content > .wp-block-columns,
.entry-content > .wp-block-separator,
.entry-header > .page-header {
	max-width: var(--wide-size) !important;
	margin-left: auto !important;
	margin-right: auto !important;
}

/* A block hidden for this member (Course Overview without access, apprentice-only for others) drops one of its separators */
.entry-content > .vala-coverview[hidden] + .wp-block-separator,
body:not(.vala-apprentice) .entry-content > .wp-block-separator:has(+ .is-style-vala-apprentice-only) {
	display: none;
}

/*.entry-content > * + * {
	margin-top: var(--wp--style--block-gap, 1.25rem);
}*/

.entry-content > h2,
.entry-content > h3 {
	margin-top: 2.5rem;
}

/* Page header: eyebrow, large serif title, intro */
.entry-header {
	padding-top: clamp(2.5rem, 7vw, 5rem);
}

.page-header {
	max-width: var(--wide-size);
	margin: 0 auto clamp(2rem, 4vw, 3rem) !important;
	padding-bottom: clamp(2rem, 4vw, 3rem);
	border-bottom: 1px solid var(--copper-soft);
}

.page-header:not(:has(h1 + p)) {
	padding-bottom: clamp(1rem, 3vw, 2rem) !important;
}

.entry-header.is-layout-constrained > .page-header {
	max-width: var(--wide-size);
}

.page-title {
	margin: 0;
	font-size: var(--size-56);
	line-height: 1.08;
}

.page-intro {
	margin: 1.25rem 0 0;
	font-size: var(--size-16);
	line-height: 1.5;
	color: var(--blackthorn);
	font-family: var(--font-sans);
	font-weight: 400;
}

.page-header .meta {
	margin-top: 1rem;
}

/* 404: nothing follows the header, so it drops the divider and keeps some room above the footer */
.site-main--404 .page-header {
	margin-bottom: clamp(4rem, 12vw, 9rem) !important;
	padding-bottom: 0 !important;
	border-bottom: 0;
}

.site-main--404 .page-actions {
	margin: 2rem 0 0;
}

/* Pages that are all blocks (Dashboard) */
.site-main--blocks .entry-content {
	padding-top: clamp(2.5rem, 6vw, 4.5rem);
}

/* Lesson (wireframe 2a): video two thirds, header one third */
.lesson-hero {
	padding-top: clamp(2rem, 5vw, 3.5rem);
}

.lesson-hero__inner {
	display: grid;
	grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: start;
	max-width: var(--wide-size);
	/* Same space below the rule as around the lesson navigation's rules */
	margin: 0 auto 1.5rem;
	padding-bottom: clamp(2rem, 4vw, 3rem);
	border-bottom: 1px solid var(--copper-soft);
}

.lesson-hero__inner--no-media {
	grid-template-columns: minmax(0, 1fr);
}

/* !important: beats .page-header's centering auto margins, which shrink a grid item to its text */
.lesson-hero__header.page-header {
	max-width: none;
	margin: 0 !important;
	padding: 0 !important;
	border: 0;
}

.lesson-hero__header .page-title {
	font-size: var(--size-34);
}

.lesson-hero__inner--no-media .page-title {
	font-size: var(--wp--preset--font-size--display, 3.5rem);
}

.lesson-hero__header .page-intro {
	font-size: var(--size-16);
}

.lesson-hero__media > * {
	margin: 0;
}


@media (max-width: 800px) {
	.lesson-hero__inner {
		grid-template-columns: 1fr;
	}
}

.lesson-materials p {
	font-family: var(--font-sans);
	font-size: var(--size-15);
}

/* Course (wireframe 1b): image beside title */
.course-hero {
	padding-top: clamp(2.5rem, 6vw, 4.5rem);
}

.course-hero__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: center;
	max-width: var(--wide-size);
	margin: 0 auto clamp(2rem, 5vw, 3.5rem);
	padding-bottom: clamp(2rem, 4vw, 3rem);
	border-bottom: 1px solid var(--copper-soft);
}

.course-hero__header.page-header {
	margin: 0;
	padding: 0;
	border: 0;
}

.course-hero__media img,
.course-hero__media .placeholder-image {
	display: block;
	width: 100%;
	aspect-ratio: 5 / 4;
	object-fit: cover;
}

@media (max-width: 700px) {
	.course-hero__inner {
		grid-template-columns: 1fr;
	}
}

/* Striped sand placeholder where an image is missing */
.placeholder-image {
	background-color: var(--sand);
	background-image: repeating-linear-gradient(135deg, transparent 0 14px, rgba(255, 255, 255, 0.35) 14px 28px);
}

.archive-list {
	padding-left: 1.25rem;
}

/* ==================================================================
 * 5. Vala blocks
 * ================================================================== */

/* ---- Cards (theme override: vala-lessons/parts/card.php) ---- */

.vala-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: clamp(2rem, 4vw, 2.75rem) var(--vala-gap);
}

@media (max-width: 900px) {
	.vala-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 600px) {
	.vala-grid {
		grid-template-columns: 1fr;
	}
}

.vala-card {
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}

.vala-card__link {
	gap: 1rem;
	color: inherit;
}

.vala-card__media {
	aspect-ratio: 3 / 2;
	border-radius: 0;
	background: var(--sand);
}

.vala-card__media.placeholder-image {
	display: block;
}

.vala-card__image {
	transition: transform 0.4s ease;
}

.vala-card__link:hover .vala-card__image {
	transform: scale(1.02);
}

.vala-card__body {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	padding: 0;
}

.vala-card__label {
	margin: 0;
}

.vala-card__title {
	margin: 0;
	font-family: var(--font-serif);
	font-size: var(--size-24);
	font-weight: 400;
	line-height: 1.2;
	color: var(--blackthorn);
}

.vala-card__description {
	margin: 0;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	line-height: 1.6;
	color: var(--blackthorn);
}

.vala-card__meta {
	margin: 0;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	color: var(--blackthorn-muted);
}

.vala-card__more {
	align-self: flex-start;
	margin-top: 0.25rem;
}

.vala-card__link:hover .vala-card__more {
	color: var(--sea-glass-deep);
	border-bottom-color: var(--sea-glass-deep);
}

.vala-card__note {
	margin: 0.5rem 0 0;
	padding: 0 0 0 1rem;
	border-left: 1px solid var(--juniper);
	border-radius: 0;
	background: none;
	font-family: var(--font-serif);
	font-size: var(--size-16);
	font-style: italic;
	color: var(--blackthorn);
}

.vala-card__note p {
	margin: 0;
}

.vala-card__status {
	display: inline-block;
	padding-bottom: 3px;
	border-bottom: 1px solid var(--juniper);
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	line-height: 1.2;
	color: var(--juniper);
	text-decoration: none;
	align-self: flex-start;
	margin-top: 0.25rem;
}

.vala-card__tooltip {
	border-radius: 0;
	background: var(--blackthorn);
	color: var(--chalk);
	font-family: var(--font-sans);
	font-weight: 400;
}

/* Favorite (on cards: a quiet mark in the image corner) */
.vala-favorite {
	top: 0.6rem;
	right: 0.6rem;
	padding: 0.45rem;
	background: rgba(244, 239, 231, 0.92);
	color: var(--juniper);
}

.vala-favorite__icon {
	width: var(--text-button);
    height: var(--text-button);
}

/* Labeled favorite button (lesson/resource pages): outlined, small caps */
.vala-favorite--labeled {
    border: 1px solid var(--juniper);
    border-radius: 0;
    background: transparent;
    font-family: var(--font-btn);
    color: var(--juniper);
    font-size: var(--text-button);
    padding: 0.95rem 1.5rem;
	gap: 0.5em;
    font-weight: 400;
    line-height: 1;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.vala-favorite--labeled:hover {
	background: rgb(48 99 92 / 20%);
	border-color: var(--juniper);
	color: var(--juniper);
}

/* List cards (My Page, list libraries): image left, text right, ruled */
.vala-library--list .vala-card,
.vala-my-page .vala-grid .vala-card,
.post-type-individual .vala-grid .vala-card,
.vala-favorites .vala-grid .vala-card {
	padding: clamp(2rem, 4vw, 2.75rem) 0;
	border-bottom: 1px solid var(--copper-soft);
	border-radius: 0;
}

.vala-library--list .vala-card:last-child,
.vala-my-page .vala-grid .vala-card:last-child,
.post-type-individual .vala-grid .vala-card:last-child,
.vala-favorites .vala-grid .vala-card:last-child {
	border-bottom: 0;
	padding-bottom: 0;
}

.vala-library--list .vala-card:first-child,
.vala-my-page .vala-grid .vala-card:first-child,
.post-type-individual .vala-grid .vala-card:first-child,
.vala-favorites .vala-grid .vala-card:first-child {
	padding-top: 0;
}

.vala-library--list .vala-card__link {
	gap: clamp(1.25rem, 3vw, 2rem);
}

.vala-library--list .vala-card__media {
	flex: 0 0 clamp(160px, 28%, 280px);
	border-radius: 0;
}

/* Recordings: imageless tiles, four across (wireframe 5a) */
.vala-course-recordings {
    border-top: 1px solid var(--copper-soft);
    padding-top: clamp(2.5rem, 5vw, 3.5rem);
}
.vala-library--recordings .vala-library__items,
.vala-grid--recordings {
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1rem;
}
.vala-library--recordings .vala-card,
.vala-grid--recordings .vala-card {
	padding: 1.25rem 1.25rem 1.5rem;
	background: var(--chalk);
}
.vala-library--recordings .vala-card__link,
.vala-grid--recordings .vala-card__link {
	flex-direction: column;
}

@media (max-width: 900px) {
	.vala-library--recordings .vala-library__items,
	.vala-grid--recordings {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/* ---- Member navigation ---- */

.vala-nav__skeleton span {
	background: linear-gradient(90deg, var(--linen), var(--sand), var(--linen));
	background-size: 200% 100%;
}

/* Top bar: small caps sans items */
.vala-nav--top {
	gap: 2rem;
}

.vala-nav--top .vala-nav__menu--main {
	gap: 2rem;
}

.vala-nav--top .vala-nav__link,
.vala-nav--top .vala-nav__toggle {
	padding: 0.5rem 0;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-nav--top .vala-nav__link:hover,
.vala-nav--top .vala-nav__toggle:hover,
.vala-nav--top .vala-nav__link[aria-current="page"] {
	color: var(--blackthorn);
	font-weight: 400;
}

.vala-nav--top .vala-nav__link[aria-current="page"] {
	box-shadow: inset 0 -1px 0 var(--chalk--deep);
}

.vala-nav--top .vala-nav__toggle::after {
	content: "";
	display: inline-block;
	width: 7px;
	height: 5px;
	margin-left: 0.5em;
	vertical-align: 0.15em;
	background: currentColor;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='black' stroke-width='1.6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.vala-nav--top .vala-nav__submenu {
	top: calc(100% + 0.75rem);
	padding: 0.75rem 1.25rem;
	border: 1px solid var(--copper-soft);
	border-radius: 0;
	background: var(--chalk);
	box-shadow: 0 12px 30px rgba(46, 44, 38, 0.08);
}

.vala-nav--top .vala-nav__submenu .vala-nav__link,
.vala-nav--top .vala-nav__submenu .vala-nav__toggle {
	font-family: var(--font-serif);
	font-size: 1.125rem;
	letter-spacing: 0;
	text-transform: none;
	color: var(--blackthorn);
}

/* Menu button: hamburger + "Menu" (account items; on small screens, the main items too) */
.vala-nav__menu-toggle {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 0.5rem 0;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn);
	cursor: pointer;
	list-style: none;
}

.vala-nav__menu-toggle::-webkit-details-marker {
	display: none;
}

.vala-nav__menu-toggle:hover {
	color: var(--blackthorn);
}

.vala-nav__menu-icon {
	display: grid;
	gap: 4px;
	width: 20px;
}

.vala-nav__menu-icon span {
	display: block;
	height: 1px;
	background: currentColor;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.vala-nav__account[open] .vala-nav__menu-icon span:nth-child(1) {
	transform: translateY(5px) rotate(45deg);
}

.vala-nav__account[open] .vala-nav__menu-icon span:nth-child(2) {
	opacity: 0;
}

.vala-nav__account[open] .vala-nav__menu-icon span:nth-child(3) {
	transform: translateY(-5px) rotate(-45deg);
}

.vala-nav--top .vala-nav__submenu--account {
	min-width: 240px;
}

.vala-nav__signed-in {
	margin: 0 0 0.5rem;
	padding: 0.25rem 0 0.75rem;
	border-bottom: 1px solid var(--copper-soft);
	font-family: var(--font-sans);
	font-size: var(--size-14);
	color: var(--blackthorn);
}

/* Main items inside the menu only on small screens */
.vala-nav__item--mobile {
	display: none;
}

@media (max-width: 782px) {
	.vala-nav--top .vala-nav__menu--main {
		display: none;
	}

	.vala-nav__item--mobile {
		display: block;
	}

	.vala-nav--top .vala-nav__item--mobile .vala-nav__submenu {
		position: static;
		padding: 0 0 0 1rem;
		border: 0;
		box-shadow: none;
	}

	.vala-nav__item--mobile + .vala-nav__item:not(.vala-nav__item--mobile) {
		margin-top: 0.5rem;
		padding-top: 0.5rem;
		border-top: 1px solid var(--copper-soft);
	}
}

/* Sidebar: grouped serif items (structure mockup 4D) */
.vala-nav--sidebar {
	display: flex;
	flex-direction: column;
	gap: 2rem;
	flex: 1;
}

.vala-nav__heading {
	margin: 0 0 0.5rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-nav--sidebar .vala-nav__link,
.vala-nav--sidebar .vala-nav__toggle {
	padding: 0.3rem 0;
	font-family: var(--font-serif);
	font-size: 1.25rem;
	line-height: 1.3;
	color: var(--blackthorn);
}

.vala-nav--sidebar .vala-nav__link:hover,
.vala-nav--sidebar .vala-nav__toggle:hover {
	color: var(--juniper);
}

.vala-nav--sidebar .vala-nav__link[aria-current="page"] {
	font-weight: 400;
	color: var(--juniper);
}

.vala-nav--sidebar .vala-nav__submenu {
	padding: 0.1rem 0 0.4rem 1rem;
	border-left: 1px solid var(--copper-soft);
	margin-left: 0.15rem;
}

.vala-nav--sidebar .vala-nav__submenu .vala-nav__link,
.vala-nav--sidebar .vala-nav__submenu .vala-nav__toggle {
	font-size: 1.125rem;
	color: var(--blackthorn);
}

.vala-nav--sidebar .vala-nav__menu--account {
	margin: 0;
	padding: 0;
	border: 0;
}

/* Log out sits apart, as small caps */
.vala-nav--sidebar .vala-nav__item--logout {
	margin-top: 1.5rem;
	padding-top: 1.25rem;
	border-top: 1px solid var(--copper-soft);
}

.vala-nav--sidebar .vala-nav__item--logout .vala-nav__link {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

@media (max-width: 900px) {
	.vala-nav--sidebar {
		flex-direction: row;
		flex-wrap: wrap;
		gap: 1.5rem 3rem;
	}
}

/*
 * Sidebar on mobile: three states (dashboard wireframe 1a/1b/1c), set by nav.js as data-mobile-state.
 *   short      Top 3 programs as single lines, account links in one row, "Full menu · N more +"
 *   collapsed  A slim "Menu" strip (after "Hide menu"; remembered)
 *   full       Every program (top 3 first, then "More programs"), one open at a time
 * The controls and the "More programs" heading only exist on mobile.
 */
.vala-nav__hide,
.vala-nav__strip,
.vala-nav__expand,
.vala-nav__more-heading {
	display: none;
}

@media (max-width: 900px) {
	/* top/max-height: undo the desktop sticky offset for the admin bar (.admin-bar .site-sidebar__inner),
	   which would otherwise push the relatively positioned menu down past the sidebar's edge */
	.vala-layout-sidebar .site-sidebar__inner {
		position: relative;
		top: 0;
		max-height: none;
		padding-top: 1rem;
		padding-bottom: 1.25rem;
		gap: 1.25rem;
	}

	.vala-nav--sidebar.has-mobile-states {
		flex-direction: column;
		flex-wrap: nowrap;
		gap: 0;
	}

	.has-mobile-states button {
		margin: 0;
		padding: 0;
		border: 0;
		background: none;
		color: inherit;
		cursor: pointer;
	}

	/* Small caps controls: buttons follow the theme's small-caps text buttons (.vala-login__link-button);
	   the "More programs" heading follows the eyebrow */
	.has-mobile-states .vala-nav__hide,
	.has-mobile-states .vala-nav__expand,
	.has-mobile-states .vala-nav__strip-label {
		font-family: var(--font-btn);
		font-size: var(--text-xs);
		font-weight: 400;
		line-height: 1;
		letter-spacing: 0.16em;
		text-transform: uppercase;
	}

	.has-mobile-states .vala-nav__hide:hover,
	.has-mobile-states .vala-nav__expand:hover,
	.has-mobile-states .vala-nav__strip:hover {
		color: var(--sea-glass-deep);
	}

	.has-mobile-states .vala-nav__more-heading {
		font-family: var(--font-sans);
		font-size: var(--text-xs);
		font-weight: 400;
		letter-spacing: 0.14em;
		text-transform: uppercase;
	}

	/* "Hide menu", across from the logo */
	.has-mobile-states .vala-nav__hide {
		position: absolute;
		top: 0.6rem;
		right: var(--gutter);
		display: flex;
		align-items: center;
		gap: 0.4rem;
		height: 2.75rem;
		color: var(--juniper);
	}

	.has-mobile-states .vala-nav__hide::after {
		content: "";
		border-left: 4px solid transparent;
		border-right: 4px solid transparent;
		border-bottom: 5px solid currentColor;
	}

	/* Programs: single-line rows with rules between them, in priority order */
	.has-mobile-states .vala-nav__heading {
		margin-bottom: 0.25rem;
	}

	.has-mobile-states .vala-nav__menu--main {
		display: flex;
		flex-direction: column;
	}

	.has-mobile-states .vala-nav__menu--main > li {
		order: var(--vala-nav-order, 0);
		border-top: 1px solid var(--copper-soft);
	}

	.has-mobile-states .vala-nav__menu--main > li.is-first,
	.has-mobile-states .vala-nav__menu--main > li.is-first-more {
		border-top: 0;
	}

	.has-mobile-states .vala-nav__menu--main > li > .vala-nav__link,
	.has-mobile-states .vala-nav__menu--main > li > details > .vala-nav__toggle {
		display: flex;
		justify-content: space-between;
		align-items: center;
		gap: 1rem;
		min-height: 2.875rem;
		padding: 0.35rem 0;
		font-size: 1.1875rem;
	}

	.has-mobile-states .vala-nav__menu--main > li > details > .vala-nav__toggle::after {
		content: "";
		flex: none;
		margin: 0;
		border-left: 4px solid transparent;
		border-right: 4px solid transparent;
		border-top: 5px solid currentColor;
	}

	.has-mobile-states .vala-nav__menu--main > li > details[open] > .vala-nav__toggle::after {
		border-top: 0;
		border-bottom: 5px solid currentColor;
	}

	.has-mobile-states .vala-nav__menu--main > li > details > .vala-nav__submenu {
		margin: 0 0 0.5rem 0.25rem;
	}

	/* Account links */
	.has-mobile-states .vala-nav__section--account {
		margin-top: 1.5rem;
	}

	.has-mobile-states .vala-nav__menu--account {
		margin: 0;
		padding: 0;
		border: 0;
	}

	/* ---- short (on load) ---- */
	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--main > li:not(.is-priority) {
		display: none;
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--main > li > .vala-nav__link::after,
	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--main > li > details > .vala-nav__toggle::after {
		content: "\203A";
		border: 0;
		font-family: var(--font-sans);
		font-size: 1rem;
		font-weight: 300;
		color: var(--blackthorn-muted);
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__section--account {
		display: flex;
		justify-content: space-between;
		align-items: center;
		gap: 0.75rem 1rem;
		flex-wrap: wrap;
		margin-top: 0.75rem;
		padding-top: 0.875rem;
		border-top: 1px solid var(--copper-soft);
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__section--account .vala-nav__heading {
		display: none;
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--account {
		display: flex;
		flex-wrap: wrap;
		gap: 0.25rem 1rem;
	}

	/* My Favorites only in the full menu */
	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--account .vala-nav__item--favorites {
		display: none;
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--account .vala-nav__item--logout {
		margin: 0;
		padding: 0;
		border: 0;
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__menu--account .vala-nav__link {
		padding: 0.25rem 0;
		font-family: var(--font-sans);
		font-size: var(--text-xs);
		letter-spacing: 0.14em;
		text-transform: uppercase;
		white-space: nowrap;
	}

	.has-mobile-states[data-mobile-state="short"] .vala-nav__expand {
		display: block;
		margin-left: auto;
		padding: 0.25rem 0;
		white-space: nowrap;
		color: var(--juniper);
	}

	/* ---- full ---- */
	.has-mobile-states[data-mobile-state="full"] .vala-nav__more-heading {
		display: block;
		padding: 1.125rem 0 0.25rem;
		color: var(--blackthorn-muted);
	}

	/* ---- collapsed ---- */
	.has-mobile-states[data-mobile-state="collapsed"] .vala-nav__hide,
	.has-mobile-states[data-mobile-state="collapsed"] .vala-nav__section {
		display: none;
	}

	.has-mobile-states[data-mobile-state="collapsed"] .vala-nav__strip {
		display: flex;
		align-items: center;
		gap: 0.75rem;
		width: 100%;
		min-height: 3rem;
		border-top: 1px solid var(--copper-soft);
		text-align: left;
	}

	.has-mobile-states .vala-nav__strip .vala-nav__menu-icon {
		width: 18px;
	}

	.has-mobile-states .vala-nav__strip-sections {
		flex: 1;
		font-family: var(--font-sans);
		font-size: 0.75rem;
		font-weight: 300;
		color: var(--blackthorn-muted);
	}

	.has-mobile-states .vala-nav__strip::after {
		content: "";
		border-left: 4px solid transparent;
		border-right: 4px solid transparent;
		border-top: 5px solid var(--juniper);
	}

	.vala-layout-sidebar .site-sidebar:has(.vala-nav[data-mobile-state="collapsed"]) .site-sidebar__inner {
		gap: 0.5rem;
		padding-bottom: 0;
	}
}

/* Other pages (top navigation), small screens: the dashboard menu (1a/1b/1c) in a panel under the logo,
   set by nav.js on .vala-nav__panel. It starts collapsed (1b). Replaces the Menu dropdown below 782px, and
   undoes the top bar's small-caps links and dropdown positioning inside the panel. */
.vala-nav__panel {
	display: none;
}

@media (max-width: 782px) {
	/* The header scrolls away on phones: an open menu would otherwise cover the page */
	.site-header:has(.vala-nav__panel) {
		position: relative;
		top: 0;
		background: var(--linen);
	}

	.site-header:has(.vala-nav__panel) .site-header__inner {
		position: relative;
		flex-wrap: wrap;
		gap: 0;
	}

	.site-header:has(.vala-nav__panel) .site-header__inner {
		min-height: 0;
	}

	.site-header:has(.vala-nav__panel) .site-logo {
		min-height: 4.25rem;
	}

	.vala-nav--top:has(.vala-nav__panel) {
		flex: 1 1 100%;
	}

	.vala-nav--top:has(.vala-nav__panel) .vala-nav__account {
		display: none;
	}

	.vala-nav--top .vala-nav__panel {
		display: flex;
		flex-direction: column;
		width: 100%;
		padding-bottom: 1.25rem;
	}

	.vala-nav--top .vala-nav__panel[data-mobile-state="collapsed"] {
		padding-bottom: 0;
	}

	.vala-nav--top .vala-nav__panel .vala-nav__hide {
		top: calc((4.25rem - 2.75rem) / 2);
	}

	.vala-nav--top .vala-nav__panel .vala-nav__menu--main {
		display: flex;
		flex-direction: column;
		flex-wrap: nowrap;
		align-items: stretch;
		gap: 0;
	}

	/* Serif items, as in the sidebar */
	.vala-nav--top .vala-nav__panel .vala-nav__link,
	.vala-nav--top .vala-nav__panel .vala-nav__toggle {
		padding: 0.3rem 0;
		font-family: var(--font-serif);
		font-size: 1.25rem;
		line-height: 1.3;
		letter-spacing: 0;
		text-transform: none;
		color: var(--blackthorn);
		box-shadow: none;
	}

	.vala-nav--top .vala-nav__panel .vala-nav__link[aria-current="page"] {
		color: var(--juniper);
	}

	.vala-nav--top .vala-nav__panel .vala-nav__toggle::after {
		width: auto;
		height: auto;
		vertical-align: middle;
		background: none;
		mask: none;
	}

	.vala-nav--top .vala-nav__panel details {
		position: static;
	}

	.vala-nav--top .vala-nav__panel .vala-nav__submenu {
		position: static;
		min-width: 0;
		margin: 0 0 0.5rem 0.25rem;
		padding: 0.1rem 0 0.4rem 1rem;
		border: 0;
		border-left: 1px solid var(--copper-soft);
		background: none;
		box-shadow: none;
	}

	.vala-nav--top .vala-nav__panel .vala-nav__submenu .vala-nav__link {
		font-size: 1.125rem;
	}

	/* Full menu: Log out apart, as small caps (as in the sidebar) */
	.vala-nav--top .vala-nav__panel[data-mobile-state="full"] .vala-nav__item--logout {
		margin-top: 1.5rem;
		padding-top: 1.25rem;
		border-top: 1px solid var(--copper-soft);
	}

	.vala-nav--top .vala-nav__panel[data-mobile-state="full"] .vala-nav__item--logout .vala-nav__link {
		font-family: var(--font-sans);
		font-size: var(--text-xs);
		letter-spacing: 0.14em;
		text-transform: uppercase;
	}
}

/* ---- Lesson navigation, Mark Complete ---- */

.vala-lesson-nav {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	gap: 1rem 2rem;
	padding: 1.5rem 0;
	border-top: 1px solid var(--copper-soft);
	border-bottom: 1px solid var(--copper-soft);
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	margin-bottom: 1.5rem;
}

/* First in the lesson (the video moved up into the hero): the hero's rule above is enough */
.lesson-content > .vala-lesson-nav:first-child {
	border-top: 0;
	padding-top: 0;
}

.vala-lesson-nav__breadcrumb {
	margin: 0;
}

.vala-lesson-nav__breadcrumb a,
.vala-lesson-nav__links a {
	text-decoration: none;
	font-size: var(--size-14);
}

.vala-lesson-nav__breadcrumb a:hover,
.vala-lesson-nav__links a:hover {
	color: var(--sea-glass-deep);
}

.vala-lesson-nav__module {
	font-size: var(--size-14);
}

.vala-lesson-nav__links {
	gap: 2rem;
}

.vala-lesson-nav__direction {
	font-size: var(--text-xs);
	letter-spacing: 0.18em;
}

.vala-lesson-nav__title {
	font-family: var(--font-sans);
	font-size: var(--size-14);
}

.vala-complete {
	margin: 2rem 0;
}

.vala-complete__button.is-complete {
	background: transparent;
	border-color: var(--juniper);
	color: var(--juniper);
}

.vala-complete__button.is-complete:hover {
	background: rgb(48 99 92 / 20%);
	border-color: var(--juniper);
	color: var(--juniper);
}

.vala-complete__button.is-complete::before {
    font-size: var(--text-button);
}

.vala-module__title {
	font-size: var(--size-34);
} 

.vala-module__title:has(+ p) {
	margin-bottom: 5px;
}

.vala-module__description {
	font-family: var(--font-sans);
	font-size: var(--size-16);
}

/* ---- Course modules: Sort by, on mobile only (wireframe 2b) ---- */

.vala-course-sort {
	min-height: 34px;
	margin-bottom: 4px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--copper-soft);
}

.vala-course-sort .eyebrow {
	margin: 0;
}

button.vala-course-sort__trigger {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 34px;
	padding: 0 12px;
	border: 1px solid var(--copper-soft);
	border-radius: 0;
	background: transparent;
	font-family: var(--font-sans);
	font-size: 13px;
	font-weight: 400;
	letter-spacing: 0;
	line-height: 1;
	text-transform: none;
	color: var(--blackthorn);
	cursor: pointer;
}

button.vala-course-sort__trigger::after {
	content: "";
	border-left: 4px solid transparent;
	border-right: 4px solid transparent;
	border-top: 5px solid currentColor;
}

button.vala-course-sort__trigger:hover,
button.vala-course-sort__trigger:focus,
button.vala-course-sort__trigger[aria-expanded="true"] {
	border-color: var(--blackthorn);
	background: transparent;
	color: var(--blackthorn);
}

button.vala-course-sort__trigger[aria-expanded="true"]::after {
	border-top: 0;
	border-bottom: 5px solid currentColor;
}

.vala-course-sort__menu {
	background: var(--white);
	border-color: var(--copper-soft);
	box-shadow: 0 10px 28px rgba(43, 43, 38, 0.14);
}

button.vala-course-sort__option {
	display: flex;
	justify-content: space-between;
	align-items: center;
	min-height: 48px;
	padding: 0 16px;
	border: 0;
	border-radius: 0;
	background: transparent;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 300;
	letter-spacing: 0;
	line-height: 1.2;
	text-align: left;
	text-transform: none;
	color: var(--blackthorn);
	cursor: pointer;
}

button.vala-course-sort__option + button.vala-course-sort__option {
	border-top: 1px solid #EDE6D8;
}

button.vala-course-sort__option:hover,
button.vala-course-sort__option:focus {
	background: var(--chalk);
	color: var(--blackthorn);
}

button.vala-course-sort__option[aria-checked="true"] {
	background: var(--chalk);
	font-weight: 400;
}

button.vala-course-sort__option[aria-checked="true"]::after {
	content: "\2713";
	color: var(--juniper);
}

/* The card's module in its eyebrow: on mobile only (below), where it replaces the module headings */
.vala-card__section,
.vala-card__label--section-only {
	display: none;
}

/* ---- Course modules on mobile: compact rows (wireframe 2a). Square image, 32% wide, text beside it ---- */

@media (max-width: 600px) {
	.vala-module > .vala-module__title,
	.vala-module > .vala-module__description {
		display: none;
	}

	.vala-course-modules .vala-card__section {
		display: inline;
	}

	.vala-course-modules .vala-card__label--section-only {
		display: block;
	}

	.vala-course-modules .vala-module + .vala-module {
		margin-top: 0;
	}

	.vala-course-modules .vala-grid--lessons {
		gap: 0;
	}

	.vala-course-modules .vala-grid--lessons .vala-card {
		padding: 16px 0;
		border-bottom: 1px solid #EDE6D8;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__link {
		display: grid;
		grid-template-columns: 32% minmax(0, 1fr);
		gap: 14px;
		align-items: start;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__media {
		aspect-ratio: 1 / 1;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__body {
		gap: 7px;
		min-width: 0;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__label {
		margin: 0;
		font-size: 9.5px;
		line-height: 1.3;
		letter-spacing: 0.16em;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__title {
		font-size: 19px;
		line-height: 1.18;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__description {
		display: none;
	}

	.vala-course-modules .vala-grid--lessons .vala-card__more,
	.vala-course-modules .vala-grid--lessons .vala-card__status {
		margin-top: 2px;
		font-size: 12.5px;
	}

	/* The favorite stays in the image's corner, now that the image doesn't span the card */
	.vala-course-modules .vala-grid--lessons .vala-favorite {
		top: 22px;
		right: auto;
		left: calc(32% - 30px);
		padding: 6px;
	}

	.vala-course-modules .vala-grid--lessons .vala-favorite::after {
		content: "";
		position: absolute;
		inset: -8px;
	}

	.vala-course-sorted__group + .vala-course-sorted__group {
		margin-top: 2rem;
	}

	.vala-course-sorted__group > .vala-module__title {
		margin: 0;
		padding-bottom: 14px;
		border-bottom: 1px solid var(--copper-soft);
		font-size: var(--size-24);
	}
}

/* ---- Lesson media: video, audio, downloads ---- */

.vala-video__frame {
	border-radius: 0;
	background: var(--sand);
}

.vala-video__poster {
	background: var(--sand);
}

.vala-video__play {
	width: 64px;
	height: 64px;
	background: var(--juniper);
	transition: background-color 0.15s ease;
}

.vala-video__poster:hover .vala-video__play {
	background: var(--juniper);
}

.vala-video__play::after {
	border-width: 9px 0 9px 15px;
	border-color: transparent transparent transparent var(--vala-accent-contrast);
}

/* Pasted player embeds (Bunny etc.): <div class="videoreplay"><iframe …></iframe></div> stays 16:9 at every width.
   !important wins over the inline styles the embed code carries. */
.videoreplay {
	position: relative;
	width: 100%;
	height: auto !important;
	padding: 0 !important;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: var(--sand);
}

.videoreplay iframe {
	position: absolute !important;
	inset: 0 !important;
	width: 100% !important;
	height: 100% !important;
	max-width: none;
	border: 0;
}

/* wpautop can slip <p>/<br> around the iframe */
.videoreplay > p {
	margin: 0;
}

.videoreplay br {
	display: none;
}

.vala-downloads__title,
.lesson-materials h3.wp-block-heading {
	margin: 0 0 0.5rem;
	font-family: var(--font-serif);
	font-size: var(--text-md);
	font-weight: 400;
}

.vala-audio__transcript summary,
.vala-faq__question {
	font-weight: 400;
}

.vala-audio__transcript summary {
	font-family: var(--font-sans);
	font-size: var(--size-14);
	color: var(--juniper);
}

.vala-downloads__item a {
	padding: 0.9rem 0;
	border-bottom-color: var(--copper-soft);
	color: var(--blackthorn);
	font-family: var(--font-sans);
	font-size: var(--size-16);
}

.vala-downloads__item a:hover {
	color: var(--juniper);
}

.vala-downloads__type {
	border-radius: 0;
	background: var(--linen);
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-downloads__size {
	font-family: var(--font-sans);
	font-weight: 400;
	font-size: var(--size-14);
}

/* ---- FAQs, announcements, notices ---- */

.vala-faq {
	padding: 1.25rem 0;
	border-bottom-color: var(--copper-soft);
}

.vala-faq__question {
	position: relative;
	padding-right: 2rem;
	list-style: none;
	font-family: var(--font-serif);
	font-size: 1.375rem;
	line-height: 1.3;
}

.vala-faq__question::-webkit-details-marker {
	display: none;
}

.vala-faq__question::after {
	content: "+";
	position: absolute;
	top: 0;
	right: 0.25rem;
	font-family: var(--font-sans);
	font-weight: 400;
	color: var(--blackthorn);
}

.vala-faq[open] .vala-faq__question::after {
	content: "\2212";
}

.vala-faq__answer {
	color: var(--blackthorn);
}

.vala-announcement,
.vala-notice {
	border-left: 1px solid var(--copper-soft);
	background: var(--linen);
}

.vala-announcement__title {
	font-size: 1.375rem;
}

.vala-toast {
	border-radius: 0;
	background: var(--sea-glass);
	color: var(--chalk);
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
}

.vala-toast__undo {
	color: var(--chalk);
    margin: 0;
    padding: 0;
}

.vala-toast__undo:hover {
	font-weight: 700;
	color: var(--chalk);
}

/* ---- Resource library (wireframe 3a): search, dropdowns, favorites toggle ---- */

.vala-card--resource .vala-card__title {
    font-size: var(--size-24);
}

.vala-resource-grid,
.vala-course-modules  {
    max-width: var(--wide-size) !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* Course intro text from the editor, then the modules: a rule between them */
.site-main--course .entry-content > :not(.vala-course-modules) + .vala-course-modules {
	margin-top: clamp(2.5rem, 5vw, 3.5rem);
	padding-top: clamp(2.5rem, 5vw, 3.5rem);
	border-top: 1px solid var(--copper-soft);
}

.vala-library__filters {
	align-items: flex-end;
	gap: 1rem;
	margin-bottom: clamp(2rem, 4vw, 3rem);
	padding-bottom: 1.5rem;
	border-bottom: 1px solid var(--copper-soft);
}

.vala-library__filter {
	flex: 0 0 calc((100% - 2rem) / 3);
	min-width: 0;
	order: 2;
}

.vala-library__filter--search {
	flex: 1 1 100%;
	order: 1;
}

.vala-library__filter--search input {
	padding-left: 2.5rem;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a8579' stroke-width='1.5'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4-4'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: 0.85rem center;
	background-size: 16px;
	border: 1px solid var(--copper-soft);
}

/* ---- Member search ---- */

.vala-search__form input {
	font-size: 1rem;
}

.vala-search__summary {
	font-family: var(--font-sans);
	font-size: var(--size-14);
	color: var(--blackthorn);
}

.vala-my-page__content h6 {
    font-size: var(--wp--preset--font-size--eyebrow);
}

.vala-my-page__content .page-intro {
    max-width: 100%;
    border-bottom: 1px solid #ddd7c9;
    padding-bottom: 35px;
    margin-bottom: 40px;
}

/* ---- The Present Moment (structure mockup: Wheel Header) ---- */

.vala-present {
	padding: clamp(1rem, 3vw, 2rem) 0 0;
}

/* On the Dashboard it sits in a wide Group, whose global padding would inset it from the blocks around it */
.has-global-padding:has(> .vala-present) {
	padding-left: 0;
	padding-right: 0;
}

.vala-present__top {
	gap: clamp(2rem, 7vw, 6.5rem);
}

.vala-present__eyebrow {
	margin: 0 0 1.5rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-present__title {
	margin: 0 0 1.25rem;
	max-width: 12em;
	font-size: clamp(2.5rem, 6vw, 4.25rem);
	line-height: 1.02;
}

.vala-present__text {
	max-width: 30em;
	margin: 0;
	font-size: var(--wp--preset--font-size--lead, 1.5rem);
	line-height: 1.6;
	color: var(--blackthorn);
}

.vala-present__moon {
	/* Puts the label's first line on the intro's last baseline: the larger intro text has more leading below it,
	   and the "Through" line hangs below */
	margin-bottom: calc((var(--wp--preset--font-size--lead, 1.5rem) - var(--text-xs)) / 2 - var(--text-xs) * 1.6);
}

.vala-present__moon-svg {
	color: var(--sand);
}

.vala-present__moon-label {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.16em;
	line-height: 1.6;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-present__arc {
	color: var(--blackthorn);
}

.vala-present__tick.is-current {
	stroke: var(--juniper);
}

.vala-present__stop-name {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	color: var(--blackthorn);
}

.vala-present__stop-date {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.1em;
	color: var(--blackthorn);
}

.vala-present__stop.is-current .vala-present__stop-name {
	color: var(--blackthorn);
}

/* The wheel as a list, below 900px */
.vala-present__list {
	border-top: 1px solid var(--copper-soft);
}

.vala-present__list-item {
	border-bottom-color: var(--copper-soft);
	color: var(--blackthorn);
}

.vala-present__list-name {
	font-family: var(--font-serif);
	font-size: 1.375rem;
	color: var(--blackthorn);
}

.vala-present__list-date {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.vala-present__list-item.is-current {
	color: var(--juniper);
}

.vala-present__list-item.is-current .vala-present__list-name {
	color: var(--blackthorn);
}

.vala-present__list-now {
	margin-top: 0.15rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--juniper);
}

@media (max-width: 900px) {
	.vala-present__top {
		gap: 1.25rem;
	}

	.vala-present__title {
		margin-bottom: 0.25rem;
	}

	.vala-present__date {
		margin: 0 0 0.5rem;
		font-family: var(--font-sans);
		font-size: var(--text-xs);
		letter-spacing: 0.14em;
		text-transform: uppercase;
		color: var(--blackthorn);
	}

	.vala-present__text {
		font-size: 1.125rem;
	}

	.vala-present__moon {
		margin-bottom: 0;
	}

	.vala-present__moon-svg,
	.vala-present__moon-image {
		width: 84px;
		height: 84px;
	}

	.vala-present__moon-label {
		max-width: 11rem;
	}
}

/* ---- Celebrations and moons (mockup 4a) ---- */

.vala-celebration__intro,
.vala-wheel__intro {
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: center;
}

.vala-celebration__image {
	border-radius: 0;
}

.vala-celebration__title {
	margin: 0 0 0.5rem;
	font-size: var(--wp--preset--font-size--title, 2.25rem);
}

.vala-celebration__date {
	margin: 0 0 1rem;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	color: var(--blackthorn);
}

.vala-celebration__description,
.vala-wheel__description {
	color: var(--blackthorn);
}

.vala-celebration__resources,
.vala-wheel__panel {
	margin-top: clamp(2rem, 4vw, 2.75rem);
}

.vala-wheel__panel {
	gap: clamp(1.75rem, 4vw, 2.25rem);
}

/* Wheel: ruled rows, image left, text right, resources full width below */
.vala-wheel {
	gap: 0;
	border-top: 0;
}

.vala-wheel__item {
	padding: clamp(2rem, 4vw, 2.75rem) 0;
	border: 0;
	border-bottom: 1px solid var(--copper-soft);
	border-radius: 0;
}

.vala-wheel__item:first-child {
	padding-top: 0;
}

.vala-wheel__item.is-current {
	border-color: var(--copper-soft);
	box-shadow: none;
}

.vala-wheel__media {
	background-color: var(--sand);
	background-image: repeating-linear-gradient(135deg, transparent 0 14px, rgba(255, 255, 255, 0.35) 14px 28px);
}

.vala-wheel__date {
	margin: 0 0 0.75rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-wheel__title {
	margin: 0 0 0.75rem;
	font-size: var(--size-24);
}

.vala-wheel__description {
	margin: 0 0 1rem;
}

.vala-wheel__toggle {
	padding: 0 0 3px;
	border: 0;
	border-bottom: 1px solid var(--juniper);
	border-radius: 0;
	background: none;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: none;
	text-decoration: none;
	color: var(--juniper);
}

.vala-wheel__toggle:hover {
	background: none;
	color: var(--sea-glass-deep);
	border-bottom-color: var(--sea-glass-deep);
}

/* Opened celebration: extended content, then "Related" resources */
.vala-wheel__extended {
	max-width: 68ch;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	line-height: 1.7;
	color: var(--blackthorn);
}

.vala-wheel__extended > :first-child {
	margin-top: 0;
}

.vala-wheel__extended > :last-child {
	margin-bottom: 0;
}

.vala-wheel__extended h2,
.vala-wheel__extended h3,
.vala-wheel__extended h4 {
	margin: 1.5em 0 0.5em;
	font-family: var(--font-serif);
	font-size: var(--size-20);
	font-weight: 400;
	line-height: 1.25;
}

.vala-wheel__resources-label {
	margin: 0 0 1rem;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--blackthorn-muted);
}

.vala-wheel__resources .vala-card__title {
	font-size: var(--size-20);
}

/* Phones: related resources as compact rows, thumbnail left (mobile wireframe 8a) */
@media (max-width: 600px) {
	.vala-wheel__resources .vala-grid {
		gap: 0.75rem;
	}

	.vala-wheel__resources .vala-card__link {
		display: grid;
		grid-template-columns: 84px minmax(0, 1fr);
		gap: 14px;
		align-items: start;
		padding: 14px;
		background: var(--linen);
	}

	.vala-wheel__resources .vala-card.no-image .vala-card__link {
		grid-template-columns: minmax(0, 1fr);
	}

	.vala-wheel__resources .vala-card__media {
		width: 84px;
		height: 84px;
		aspect-ratio: 1;
	}

	.vala-wheel__resources .vala-card__body {
		gap: 0.3rem;
	}

	.vala-wheel__resources .vala-card__title {
		font-size: var(--size-16);
		line-height: 1.25;
	}

	.vala-wheel__resources .vala-card__description,
	.vala-wheel__resources .vala-card__more {
		display: none;
	}
}

.vala-moon__item + .vala-moon__item {
	border-top-color: var(--copper-soft);
}

.vala-moon__term {
	border-color: var(--copper-soft);
	background: var(--linen);
}

/* The sign glyph as a soft wash, to sit beside the watercolor phase artwork */
.vala-moon__term-glyph {
	background: radial-gradient(circle at 38% 35%, #eef1f6 0%, #d5dcea 70%, #c6cfe1 100%);
	color: #56698c;
	font-family: var(--font-serif);
}

.vala-moon__term-label {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--blackthorn-muted);
}

.vala-moon__term-name {
	font-size: 1.625rem;
	line-height: 1.15;
	color: var(--blackthorn);
}

.vala-moon__term-note {
	font-family: var(--font-sans);
	font-size: var(--text-sm);
	color: var(--blackthorn-muted);
}

/* ---- Forms (My Account, Login) ---- */

.vala-form legend {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-form__hint {
	font-size: var(--text-xs);
	font-weight: 400;
}

/* ---- Sign In (Login Form block, Sign In wireframe 1a-1c / 2a-2c) ----
   A 400px column: eyebrow and serif title, email, then password or one-time link, or "Check your email".
   Centered on desktop, left-aligned on phones. States are switched by vala-lessons (vala.css, login.js). */

.entry-content > .vala-login {
	max-width: 400px !important;
	margin: clamp(1rem, 6vw, 4.5rem) auto clamp(4rem, 10vw, 7rem) !important;
}

/* "Check your email" has no form fields, so it gets more room: the title stays on one line on desktop */
.entry-content > .vala-login[data-state="sent"] {
	max-width: 560px !important;
}

.vala-login__panel {
	display: flex;
	flex-direction: column;
	gap: 2rem;
}

.vala-login__panel:focus {
	outline: none;
}

.vala-login__header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.75rem;
	text-align: center;
}

.vala-login__eyebrow {
	margin: 0;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--blackthorn-muted);
}

.vala-login__title {
	margin: 0;
	padding: 0;
	border: 0;
	font-size: var(--size-56);
	font-style: normal;
	line-height: 1;
}

.vala-login__text {
	margin: 0.25rem 0 0;
	font-size: var(--size-15);
	line-height: 1.6;
	color: var(--blackthorn-muted);
	text-wrap: pretty;
}

.vala-login__text strong {
	font-weight: 600;
	color: var(--blackthorn);
	overflow-wrap: anywhere;
}

.vala-login__notice,
.vala-login__error {
	margin: 0;
	font-size: var(--size-14);
}

.vala-login__error {
	border-left-color: var(--madder-red);
	background: var(--madder-tint);
}

.vala-login__error a {
	color: var(--blackthorn);
}

.vala-login__form,
.vala-login__password-fields {
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}

.vala-login__form {
	gap: 2rem;
}

.vala-login__field {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.vala-login__label-row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
}

.vala-login__label {
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--blackthorn);
}

.vala-login__input {
	height: 3rem;
	margin: 0;
}

.vala-login__input:focus {
	border-color: var(--blackthorn);
	outline: none;
}

.vala-login__forgot {
	padding-bottom: 2px;
	border-bottom: 1px solid var(--juniper);
	font-size: var(--size-14);
	line-height: 1;
	color: var(--juniper);
	text-decoration: none;
	white-space: nowrap;
}

.vala-login__forgot:hover {
	color: var(--sea-glass-deep);
	border-bottom-color: var(--sea-glass-deep);
}

.vala-login__remember {
	display: flex;
	align-items: center;
	gap: 0.625rem;
	margin: 0;
	font-size: var(--size-15);
	line-height: 1;
	color: var(--blackthorn);
	cursor: pointer;
}

.vala-login__actions {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.vala-login__actions--password {
	align-items: center;
	gap: 1.25rem;
}

.vala-login .vala-login__button {
	align-self: stretch;
	min-height: 3.125rem;
	letter-spacing: 0.18em;
}

/* Small-caps text links: "Login with One-Time Link instead", "Resend link", "Use a different email" */
.vala-login__link-button {
	padding: 0 0 4px;
	border: 0;
	border-bottom: 1px solid var(--juniper);
	border-radius: 0;
	background: none;
	font-family: var(--font-btn);
	font-size: var(--text-xs);
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--juniper);
	cursor: pointer;
}

.vala-login__link-button:hover {
	color: var(--sea-glass-deep);
	border-bottom-color: var(--sea-glass-deep);
}

.vala-login__link-button:focus-visible {
	outline: var(--sea-glass) solid 2px;
	outline-offset: 3px;
}

.vala-login__link-button:disabled {
	opacity: 0.6;
	cursor: wait;
}

.vala-login__help {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.875rem;
	padding-top: 1.5rem;
	border-top: 1px solid var(--copper-soft);
	text-align: center;
}

.vala-login__help-text,
.vala-login__status {
	margin: 0;
	font-size: var(--size-14);
	line-height: 1.5;
	color: var(--blackthorn-muted);
	text-wrap: pretty;
}

.vala-login__help-text + .vala-login__help-links {
	margin-top: 0;
}

.vala-login__help-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.75rem 1.625rem;
}

.vala-login__status:empty {
	display: none;
}

.vala-login__help-links + .vala-login__status,
.vala-login__help-links ~ .vala-login__help-text {
	margin-top: 0.625rem;
}

@media (max-width: 600px) {
	.vala-login__header,
	.vala-login__help {
		align-items: flex-start;
		text-align: left;
	}

	.vala-login__title {
		font-size: var(--size-40);
	}

	.vala-login__help-links {
		justify-content: flex-start;
	}
}

/* ---- Locked page ---- */

.vala-locked-page {
	padding: clamp(4rem, 10vw, 8rem) var(--gutter);
}

.vala-locked-page__icon::before {
	width: 2rem;
	height: 2rem;
	background: var(--blackthorn);
}

.vala-locked-page__title {
	font-size: var(--wp--preset--font-size--display, 3.5rem);
}

.vala-locked-page__message {
	font-size: var(--wp--preset--font-size--lead, 1.5rem);
	color: var(--blackthorn);
}

/* ---- My Page (wireframe 7a) ---- */

.vala-my-page-wrap {
	padding: clamp(2.5rem, 7vw, 5rem) var(--gutter) clamp(3rem, 8vw, 6rem);
}

.vala-my-page__inner {
	max-width: var(--wide-size);
}

.vala-my-page__title {
	margin: 0 0 1.25rem;
	font-size: var(--size-34);
}

.vala-staff-notice {
	border-radius: 0;
	background: var(--linen);
	border: 1px solid var(--copper-soft);
	font-family: var(--font-sans);
	font-weight: 400;
}

.post-type-individual .vala-my-resources .vala-grid,
.vala-my-page .vala-my-resources .vala-grid,
.vala-favorites .vala-grid {
    display: block;
}

.vala-favorites .vala-card__link,
.vala-my-page .vala-my-resources .vala-card__link,
.post-type-individual .vala-my-resources .vala-card__link {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 5fr);
    align-items: center;
    gap: clamp(1.5rem, 4vw, 3rem);
}

.vala-favorites {
    margin-top: clamp(2rem, 4vw, 3rem) !important;
}

/* Resources that expand in place (My Page): "Expand" opens the resource's body under the card */
/* A <button>, so undo the Cosmos button styles and look exactly like the "View" text link */
button.vala-card__expand {
	display: inline-block;
	margin: 0.25rem 0 0;
	padding: 0 0 3px;
	border: 0;
	border-bottom: 1px solid var(--juniper);
	border-radius: 0;
	background: none;
	box-shadow: none;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	line-height: 1.2;
	letter-spacing: normal;
	text-align: left;
	text-transform: none;
	color: var(--juniper);
	cursor: pointer;
}

button.vala-card__expand:hover,
button.vala-card__expand:focus {
	background: none;
	color: var(--sea-glass-deep);
	border-color: var(--sea-glass-deep);
}

.vala-card__detail {
	margin-top: clamp(1.5rem, 4vw, 2.5rem);
}

.vala-card__detail .vala-rpage__section:first-child {
	margin-top: 0;
	padding-top: 0;
}

/* The resource page spaces its blocks through its constrained layout; the expanded card isn't in one, so give it
   the same gap (otherwise blocks touch: two Practice players merge into one box). Full width, like the page. */
.vala-card__detail .vala-rpage__content > * {
	margin-block: 0;
}

.vala-card__detail .vala-rpage__content > * + * {
	margin-block-start: var(--wp--style--block-gap, 1.25rem);
}

/* ---- Editor notices in the front end preview ---- */

.vala-editor-notice {
	border-radius: 0;
	font-family: var(--font-sans);
}

/* ==================================================================
 * 6. Utilities
 * ================================================================== */

.screen-reader-text:not(:focus) {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	width: 1px;
	word-wrap: normal !important;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition: none !important;
		animation: none !important;
	}
}


/* Vala Apprentice */

.vala-month-schedule {
    margin-top: clamp(1rem, 3vw, 2rem) !important;
}
.vala-month-schedule__emphasis {
	max-width: 100%;
	font-size: var(--size-16);
}

.vala-month-card__name {
	font-size: var(--size-24);
}
.vala-month-card {
    background-color: var(--chalk);
    border: 0;
}



.vala-month-schedule__months {
	gap: 0.9375rem;
}

.vala-month-card__more {
    display: inline-block;
    padding-bottom: 3px;
    border-bottom: 1px solid var(--juniper);
    font-family: var(--font-sans);
    font-size: var(--size-14);
    font-weight: 400;
    line-height: 1.2;
    color: var(--juniper);
    text-decoration: none;
    align-self: flex-start;
}

.wp-block-quote.is-style-vala-emphasis {
	border-left: 2px solid var(--juniper, #30635C);
}

.apprentice_page .page-intro {
    max-width: 100%;
}
.apprentice_page .wp-block-quote.is-style-vala-emphasis {
    font-size: var(--size-20);
}

.is-style-vala-diamonds li {
    border-top: 1px solid var(--copper-soft);
    padding: 12px;
    padding-left: 1.4rem;
    margin-bottom: 0;
    margin-top: 0 !important;
	color: var(--blackthorn);
	font-size: var(--size-16);
}

.vala-steps__prompts li::before, .is-style-vala-diamonds > li::before {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
}

.vala-courses-of-study__table {
	border-top: 0;
}

.vala-courses-of-study__question {
    color: var(--juniper);
}

.vala-courses-of-study__row:last-child {
	border-bottom: 0;
}
.is-column-two {
	column-count: 2;
	column-gap: var(--size-30);
}

.is-column-three {
    column-count: 3;
    column-gap: var(--size-30);
}

.is-column-two > *,
.is-column-three > * {
	break-inside: avoid;
}

.vala-thresholds__tab {
    border-radius: 0;
}

.is-style-block {
    column-gap: 50px;
    list-style: none;
    padding: 0;
}

.is-style-block li {
    padding: 15px 0;
    border: 0;
}
.is-style-block li:before {
	display: none;
}
.is-style-block li strong {
	display: block;
	font-weight: 400;
	text-transform: uppercase;
	color: var(--blackthorn);
	font-size: var(--text-xs);
	letter-spacing: 0.14em;
	margin-bottom: 5px;
}

.wp-block-details.is-style-vala-example td {
	border-color: color-mix(in srgb, var(--ink, #2b2b26) 12%, transparent);
}

/* Gatherings: Upcoming and Past, session cards up to three across (fewer in a narrow column, e.g. beside focuses) */
.vala-gatherings__group + .vala-gatherings__group {
	margin-top: clamp(2rem, 4vw, 3rem);
}
.vala-gatherings__dates .vala-gatherings__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(max(14rem, calc((100% - 2 * 16px) / 3)), 1fr));
	gap: 16px;
}
.vala-gatherings__group--past .vala-gatherings__date {
	color: var(--blackthorn-muted);
}
.vala-gatherings__session {
	padding: 20px 18px;
    background: var(--chalk);
    flex-direction: column;
    gap: 8px;
    align-items: start;
    border-bottom: 0;
}
.is-vala-no-border li {
	border: 0;
	padding-top: 0;
	padding-bottom: 0;
	margin-bottom: 10px;
}
.vala-thresholds__prompts {
    display: block;
    column-count: 2;
    gap: 50px;
}
.vala-thresholds__prompt {
    display: block;
    padding: 20px 0;
}
.vala-thresholds__intro {
    font-family: var(--font-serif);
    font-style: italic;
}
.vala-worksheet__downloads .vala-button {
    border-color: var(--juniper);
    color: var(--juniper);
    font-size: var(--size-14);
}
.is-style-block.column-serif strong {
    font-family: var(--font-serif);
    color: var(--a-ink);
    letter-spacing: 0;
    font-size: var(--text-md);
    text-transform: none;
}
.vala-acard__category, .vala-resource__label, .vala-month-card__eyebrow, .vala-gatherings__label, .vala-worksheet__eyebrow, .vala-thresholds__subtitle, .vala-arc-rings__eyebrow, .vala-arc-rings__label, .vala-alibrary__rail-title, .vala-courses-of-study__row--head, .vala-steps__hint {
	color: var(--blackthorn-muted);
}

.vala-lesson-nav__links .vala-lesson-nav__course {
    color: var(--blackthorn);
	font-size: var(--size-14);
}
.vala-lesson-nav__links .vala-lesson-nav__course:hover {
	text-decoration: underline;
	color: var(--blackthorn);
}
.vala-complete__message:empty{
	display: none;
}
.vala-module__number {
    margin-right: 0.75em;
}

/* ---------- Related resources: .vala-grid--list ---------- */

.vala-resource-grid .vala-grid--list .vala-card__link {
	display: grid;
	grid-template-columns: minmax(0, 2fr) minmax(0, 4fr);
	gap: 14px;
	align-items: center;
}

.vala-resource-grid .vala-grid--list .vala-card__media {
	width: 100%;
	height: auto;
	aspect-ratio: 3 / 2;
}


/* Not shown in the related-resources design */
.vala-resource-grid .vala-grid--list .vala-card__label,
.vala-resource-grid .vala-grid--list .vala-card__meta,
.vala-resource-grid .vala-grid--list .vala-card__status {
  display: none;
}


/* One column on small screens */
@media (max-width: 600px) {
  .vala-resource-grid .vala-grid--list {
    grid-template-columns: 1fr;
  }
}

/* Apprentice */

/* apprentice month */
.vala-acard-grid {
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 900px) {
  .vala-acard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .vala-acard-grid {
    grid-template-columns: 1fr;
  }

  /* Back-to-back resource sections (e.g. Self-Study First / Second Session): keep the next title off the cards above */
  .vala-apprentice-resources + .vala-apprentice-resources {
    margin-top: 3rem;
  }
}

.vala-apprentice-nav {
    margin-top: 3rem !important;
}

.vala-gatherings__focuses li {
	font-size: var(--size-16)
}
.vala-acard {
	border: 1px solid var(--copper-soft);
}

.vala-arc-rings__text,
.wp-block-columns.is-style-vala-pairs p {
    color: var(--blackthorn);
    font-size: var(--size-16);
}
.vala-month-card__meta {
    font: 400 var(--size-14) / 1.4 var(--a-sans);
}
.vala-apprentice-resources__heading, 
.vala-courses-of-study__heading, 
.vala-gatherings__heading, 
.vala-resource__details-title, 
.vala-month-schedule__title {
	font-size: var(--size-34);
}

.vala-present__title {
	font-size: clamp(2.5rem, 6vw, 3.5rem);
	line-height: 1.08;
}

.vala-courses-of-study__responsibility {
  font: 400 var(--size-16) / 1.65 var(--a-sans);
}

.wp-block-columns.is-style-vala-pairs h3,
.vala-gatherings__date,
.vala-arc-rings__title,
.vala-worksheet__title {
	font-size: var(--size-24);
}

.vala-alibrary__sort,
.vala-worksheet__description {
	font-size: var(--size-14);
	color: var(--blackthorn);
}
.vala-alibrary__sort select {
    padding: 16px 44px 16px 20px;
    margin-bottom: 0;
}
.vala-alibrary__rail {
    background-color: transparent;
    border-left: 1px solid var(--copper-soft);
}
.vala-alibrary__toggle, 
.vala-alibrary__options label {
    font-size: var(--size-14);
    color: var(--blackthorn);
}
button.vala-alibrary__clear.text-link {
    padding: 0;
    color: var(--blackthorn);
    border: 0;
    margin-top: 8px;
}

.vala-alibrary__group {
    border-bottom: 0;
}
.vala-alibrary__group summary {
    font-family: var(--font-btn);
    font-size: var(--size-14);
    border-bottom: 1px solid var(--a-line);
    margin-bottom: var(--size-20);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.vala-acard {
    background-color: var(--chalk);
    border: 0;
}
.vala-acard__link .vala-pill {
    background: transparent;
}
.vala-acard__link .vala-pill--required {
    color: var(--juniper);
}

.vala-worksheet {
    gap: 40px;
}

.vala-worksheet__image {
  width: 6rem;
  height: 7rem;
}

.wp-block-details.is-style-vala-example[open] {
	border-color: 
	color-mix(in srgb, var(--juniper, #30635C) 40%, transparent);
	background: var(--a-tint);
}
.bg-tint {
	background: var(--a-tint) !important;
}

/* Audio version player
   Source: Type Roles, "Audio player" (2B type, scheme 1a color)
   Markup: .aap > .aap__play + .aap__seek + .aap__time
   State:  data-state="paused" | "playing"
   Progress: set --aap-progress (e.g. "34%") on .aap from JS */

.aap {
	--aap-track: var(--copper-soft);
	box-sizing: border-box;
	display: flex;
	align-items: center;
	gap: 20px;
	width: 100%;
	max-width: 520px;
	padding: 18px 24px;
	background: var(--chalk);
	color: var(--blackthorn);
	margin-bottom: 5px;
}
 
/* Play / pause button */
.aap__play {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--juniper);
  cursor: pointer;
  margin-bottom: 0;
  transition: background-color 0.15s ease;
}
 
.aap__play:hover {
  background: var(--sea-glass-deep);
}
 
.aap__play:focus-visible,
.aap__seek:focus-visible {
  outline: 2px solid var(--sea-glass);
  outline-offset: 2px;
}
 
/* Icon: triangle when paused, two bars when playing */
.aap__icon {
  display: block;
  width: 0;
  height: 0;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 11px solid var(--chalk);
  margin-left: 3px;
}
 
.aap[data-state="playing"] .aap__icon {
  width: 4px;
  height: 12px;
  margin-left: 0;
  border-top: 0;
  border-bottom: 0;
  border-left: 4px solid var(--chalk);
  border-right: 4px solid var(--chalk);
}
 
/* Seek bar: 3px track, juniper fill driven by --aap-progress */
.aap__seek {
  -webkit-appearance: none;
  appearance: none;
  flex: 1 1 auto;
  min-width: 0;
  height: 20px; /* larger hit area; visible track stays 3px */
  margin: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
}
 
.aap__seek::-webkit-slider-runnable-track {
  height: 3px;
  border: 0;
  border-radius: 0;
  background: linear-gradient(
    to right,
    var(--juniper) 0 var(--aap-progress, 0%),
    var(--aap-track) var(--aap-progress, 0%) 100%
  );
}
 
.aap__seek::-moz-range-track {
  height: 3px;
  border: 0;
  border-radius: 0;
  background: var(--aap-track);
}
 
.aap__seek::-moz-range-progress {
  height: 3px;
  background: var(--juniper);
}
 
/* Thumb is hidden at rest (the design shows a plain bar),
   and appears on hover or keyboard focus so it can be grabbed */
.aap__seek::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  margin-top: -4.5px; /* centers 12px thumb on 3px track */
  border: 0;
  border-radius: 50%;
  background: var(--juniper);
  opacity: 0;
  transition: opacity 0.15s ease;
}
 
.aap__seek::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 50%;
  background: var(--juniper);
  opacity: 0;
  transition: opacity 0.15s ease;
}
 
.aap__seek:hover::-webkit-slider-thumb,
.aap__seek:focus-visible::-webkit-slider-thumb {
  opacity: 1;
}
 
.aap__seek:hover::-moz-range-thumb,
.aap__seek:focus-visible::-moz-range-thumb {
  opacity: 1;
}
 
/* Disabled (audio not loaded yet): quiet the controls */
.aap__seek:disabled {
  cursor: default;
}
 
.aap__seek:disabled::-webkit-slider-thumb {
  opacity: 0;
}
 
.aap__seek:disabled::-moz-range-thumb {
  opacity: 0;
}
 
/* Time: meta style, Open Sans 13px #5A6362 */
.aap__time {
  flex: none;
  font-size: 13px;
  line-height: 1;
  color: var(--blackthorn);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
 
@media (prefers-reduced-motion: reduce) {
  .aap__play,
  .aap__seek::-webkit-slider-thumb,
  .aap__seek::-moz-range-thumb {
    transition: none;
  }
}

/* Resources Apprentice */
.vala-resource__details {
    border-top: 1px solid var(--a-line);
    padding-top: 2rem;
}

/* Audio Practice: the card style (wireframe 9a) here, the simple style (2a) after it.
   Card, laid out by the block's own width:
   wide    image | eyebrow, title, description | player and download
   medium  small image beside eyebrow and title, then description, player, download
   narrow  no image, everything stacked
   The download links (audio, transcript) sit side by side below, full width. Without an image the image column
   goes; without a description the eyebrow and title center beside the image or player. */

.vala-audio {
	container-type: inline-size;
	padding: 0;
	background: var(--chalk);
}

.vala-audio__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	grid-template-areas: "header" "description" "controls" "downloads" "transcript";
	gap: 12px;
	padding: 22px 20px;
}

.vala-audio__image {
	display: none;
	grid-area: image;
	aspect-ratio: 1;
	overflow: hidden;
}

.vala-audio__header {
	grid-area: header;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.vala-audio--no-description .vala-audio__header {
	justify-content: center;
}

.vala-audio__eyebrow {
	margin: 0;
	font-family: var(--font-sans);
	font-size: var(--text-xs);
	font-weight: 400;
	line-height: 1.2;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--blackthorn-muted);
}

.vala-audio__title {
	margin: 0;
	font-family: var(--font-serif);
	font-size: var(--size-24);
	font-weight: 400;
	line-height: 1.15;
	color: var(--blackthorn);
}

.vala-audio__description {
	grid-area: description;
	font-family: var(--font-sans);
	font-size: var(--size-14);
	line-height: 1.65;
	color: var(--blackthorn-muted);
}

.vala-audio__description > * {
	margin: 0 0 0.75em;
}

.vala-audio__description > :last-child {
	margin-bottom: 0;
}

.vala-audio__description strong {
	font-weight: 600;
	color: var(--blackthorn);
}

.vala-audio__controls {
	grid-area: controls;
	display: flex;
	flex-direction: column;
	gap: 14px;
	min-width: 0;
}

.vala-audio .aap {
	max-width: none;
	margin: 0;
	padding: 10px 12px;
	gap: 12px;
	background: #fff;
}

.vala-audio .aap__play {
	width: 36px;
	height: 36px;
}

.vala-audio .aap__time {
	font-size: 12px;
}

/* Download links: a ruled row each, label left and arrow right, two across when there's room */
.vala-audio__downloads {
	grid-area: downloads;
	display: flex;
	flex-wrap: wrap;
	gap: 0 38px;
	min-width: 0;
}

.vala-audio__download {
	flex: 1 1 220px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	min-width: 0;
	padding: 18px 0;
	border-top: 1px solid var(--a-line, var(--copper-soft));
	border-bottom: 1px solid var(--a-line, var(--copper-soft));
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	line-height: 1.2;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--juniper);
	text-decoration: none;
	transition: color 0.15s ease;
}

.vala-audio__download-arrow {
	flex: none;
	font-size: 1.4em;
	line-height: 1;
	letter-spacing: 0;
	color: var(--blackthorn);
	transition: transform 0.15s ease, color 0.15s ease;
}

.vala-audio__download:hover,
.vala-audio__download:focus-visible {
	color: var(--sea-glass-deep);
}

.vala-audio__download:hover .vala-audio__download-arrow,
.vala-audio__download:focus-visible .vala-audio__download-arrow {
	color: var(--sea-glass-deep);
	transform: translateX(4px);
}

.vala-audio__download[aria-busy="true"] {
	cursor: progress;
	opacity: 0.7;
}

.vala-audio__transcript {
	grid-area: transcript;
	padding-top: 12px;
	border-top: 1px solid var(--copper-soft);
}

.vala-audio__transcript summary {
	font-family: var(--font-sans);
	font-size: var(--size-14);
	font-weight: 400;
	color: var(--juniper);
	cursor: pointer;
}

.vala-audio__transcript-text {
	padding-top: 12px;
	font-size: var(--size-14);
}

/* Medium: small image beside the eyebrow and title */
@container (min-width: 420px) {
	.vala-audio__inner {
		gap: 16px;
		padding: 24px;
	}

	.vala-audio--has-image .vala-audio__inner {
		grid-template-columns: 96px minmax(0, 1fr);
		grid-template-areas: "image header" "description description" "controls controls" "downloads downloads" "transcript transcript";
		column-gap: 18px;
	}

	.vala-audio--has-image .vala-audio__image {
		display: block;
		align-self: center;
	}

	.vala-audio__header {
		gap: 9px;
	}

	.vala-audio__title {
		font-size: 1.625rem;
	}

	.vala-audio .aap {
		padding: 12px 14px;
		gap: 14px;
	}

	.vala-audio .aap__play {
		width: 40px;
		height: 40px;
	}
}

/* Wide: three columns */
@container (min-width: 760px) {
	.vala-audio__inner,
	.vala-audio--has-image .vala-audio__inner {
		grid-template-columns: minmax(0, 1fr) 320px;
		grid-template-rows: auto auto auto auto;
		grid-template-areas: "header controls" "description controls" "downloads downloads" "transcript transcript";
		column-gap: 32px;
		row-gap: 10px;
		padding: 28px 30px;
	}

	.vala-audio--has-image .vala-audio__inner {
		grid-template-columns: 150px minmax(0, 1fr) 320px;
		grid-template-areas: "image header controls" "image description controls" ". downloads downloads" "transcript transcript transcript";
	}

	.vala-audio--has-image .vala-audio__image {
		align-self: center;
	}

	.vala-audio__header {
		align-self: end;
	}

	.vala-audio__description {
		align-self: start;
	}

	/* No description: the eyebrow and title take both rows, centered beside the image and player */
	.vala-audio--no-description .vala-audio__header {
		grid-row: 1 / 3;
		align-self: center;
	}

	/* Audio and transcript links: two columns in their own row */
	.vala-audio__downloads {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		margin-top: 14px;
	}

	/* A single link: under the player, the two together centered beside the header and description */
	.vala-audio--single-download .vala-audio__inner {
		grid-template-areas: "header controls" "description downloads" "transcript transcript";
		grid-template-rows: auto auto auto;
	}

	.vala-audio--single-download.vala-audio--has-image .vala-audio__inner {
		grid-template-areas: "image header controls" "image description downloads" "transcript transcript transcript";
	}

	.vala-audio--single-download .vala-audio__controls {
		align-self: end;
	}

	.vala-audio--single-download .vala-audio__downloads {
		display: flex;
		align-self: start;
		margin-top: 4px;
	}

	.vala-audio__controls {
		align-self: center;
	}

	.vala-audio__title {
		font-size: var(--size-30);
	}

	.vala-audio .aap__play {
		width: 42px;
		height: 42px;
	}
}

/* Audio Practice, simple style (wireframe 2a "Lesson materials"): title, a compact player, the download link.
   Two classes so these win over the card's container-width rules above. */

.vala-audio.vala-audio--simple {
	container-type: normal;
	background: none;
}

.vala-audio--simple .vala-audio__inner {
	grid-template-columns: minmax(0, 1fr);
	grid-template-areas: "header" "description" "controls" "downloads" "transcript";
	gap: 10px;
	padding: 0;
}

.vala-audio--simple .vala-audio__title {
	font-family: var(--font-serif);
	font-size: var(--text-md);
	line-height: 1.25;
}

.vala-audio--simple .vala-audio__controls {
	gap: 10px;
}

.vala-audio--simple .aap {
	gap: 10px;
	padding: 10px 12px;
	background: var(--chalk);
}

.vala-audio--simple .aap__play {
	width: 26px;
	height: 26px;
}

.vala-audio--simple .aap__icon {
	border-top-width: 5px;
	border-bottom-width: 5px;
	border-left-width: 8px;
	margin-left: 2px;
}

.vala-audio--simple .aap[data-state="playing"] .aap__icon {
	width: 3px;
	height: 10px;
	margin-left: 0;
	border-left-width: 3px;
	border-right-width: 3px;
}

.vala-audio--simple .aap__time {
	font-size: 11px;
	color: var(--blackthorn-muted);
}

.vala-audio--simple .vala-audio__download {
	padding-bottom: 3px;
	font-size: var(--size-14);
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: none;
}
