/*
 * Site kind: academy (risksacademy.com and its subsites). The pages layer sets the reading measure; the academy layer
 * (inc/nexus-academy-tutor.php, inc/nexus-academy-gamipress.php, tutor/single-*.php; owner OD-66, 2026-10-22) styles
 * Tutor's course, lesson and quiz records in the kit: black and white shell on the kit tokens, enterprise cards
 * (nx-xcard: mono code and status, title, meta, strip, button row, the Academy's pastel gradient as a thin rule only),
 * colour only in data. The kit page a record carries (ra_kit_page) brings its own stylesheet inside its embed root.
 */
html[data-nx-kind="academy"] .nx-pages-main--standard .nx-pages-body { max-inline-size: 72ch; }

/* shell */
.nx-academy-main { background: var(--nx-bg-canvas); color: var(--nx-text-primary); }
.nx-academy-shell { max-inline-size: 1200px; margin-inline: auto; padding-inline: 16px; }
.nx-academy-hero { padding-block: 40px 28px; border-bottom: 1px solid var(--nx-border-hairline); position: relative; }
.nx-academy-hero::after { content: ""; position: absolute; inset: auto 0 -1px 0; height: 2px; background: linear-gradient(90deg, var(--nxi-a), var(--nxi-b)); }
.nx-academy-hero--inner { padding-block: 8px 20px; border-bottom: 0; }
.nx-academy-hero--inner::after { display: none; }
.nx-academy-title { font-size: clamp(28px, 4vw, 44px); line-height: 1.08; letter-spacing: -0.015em; margin: 6px 0 10px; font-weight: 600; }
.nx-academy-lede { font-size: 18px; line-height: 1.5; max-inline-size: 64ch; margin: 0 0 10px; color: var(--nx-text-secondary); }
.nx-academy-entry { margin-top: 18px; }
.nx-academy-body { padding-block: 8px 48px; }
.nx-academy-section { padding-block: 28px; border-top: 1px solid var(--nx-border-hairline); }
.nx-academy-section:first-child { border-top: 0; }
.nx-academy-kit { margin: 0; }
.nx-academy-kit .nxe-host, .nx-academy-kit .nxe { width: 100%; }

/* enterprise card grammar (mirrors the kit's nx-xcard) */
.nx-xcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin: 12px 0; }
.nx-xcard { position: relative; border: 1px solid var(--nx-border-hairline); border-radius: var(--nx-r, 5px); padding: 16px 16px 14px; background: var(--nx-bg-canvas); overflow: hidden; }
.nx-xcard::before { content: ""; position: absolute; inset: 0 auto auto 0; height: 2px; width: 0; background: linear-gradient(90deg, var(--nxi-a), var(--nxi-b)); transition: width 0.25s ease; }
.nx-xcard:hover::before, .nx-xcard:focus-within::before { width: 100%; }
.nx-xcard-code { display: flex; gap: 10px; align-items: baseline; margin: 0 0 6px; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--nx-text-muted); }
.nx-mono { font-family: var(--nx-font-mono, ui-monospace, SFMono-Regular, Menlo, monospace); }
.nx-xcard-status { font-family: var(--nx-font-mono, ui-monospace, monospace); }
.nx-xcard-title { font-size: 17px; line-height: 1.3; margin: 0 0 6px; font-weight: 600; }
.nx-xcard-title a { color: inherit; text-decoration: none; }
.nx-xcard-title a:hover { text-decoration: underline; }
.nx-xcard-meta { margin: 0 0 8px; font-size: 13px; color: var(--nx-text-secondary); }
.nx-xcard-figure { margin: 8px 0; font-size: 14px; }
.nx-xcard-figure strong { font-size: 24px; font-weight: 600; letter-spacing: -0.01em; }
.nx-xcard-strip { height: 2px; background: var(--nx-border-hairline); margin: 8px 0; overflow: hidden; }
.nx-xcard-strip span { display: block; height: 100%; background: linear-gradient(90deg, var(--nxi-a), var(--nxi-b)); }
.nx-xcard-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0 0; }
.nx-btn { display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border: 1px solid var(--nx-text-primary); border-radius: var(--nx-r, 5px); color: var(--nx-text-primary); background: transparent; text-decoration: none; font-size: 14px; }
.nx-btn-sm { height: 30px; padding: 0 12px; font-size: 13px; }
.nx-btn:hover { background: var(--nx-text-primary); color: var(--nx-bg-canvas); }
.nx-eyebrow { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--nx-text-muted); margin: 0 0 6px; }
.nx-h2 { font-size: clamp(22px, 2.6vw, 30px); line-height: 1.15; margin: 0 0 14px; font-weight: 600; letter-spacing: -0.01em; }
.nx-note { font-size: 13px; color: var(--nx-text-muted); margin: 10px 0 0; }
.nx-prose { max-inline-size: 72ch; line-height: 1.6; }

/* lesson and quiz: the course contents dock beside the record */
.nx-academy-lesson-grid { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 32px; padding-block: 24px 48px; }
.nx-academy-lesson-side { border-inline-end: 1px solid var(--nx-border-hairline); padding-inline-end: 20px; position: sticky; top: 16px; align-self: start; max-height: calc(100vh - 32px); overflow: auto; }
.nx-academy-lesson-main { min-width: 0; }
.nx-academy-quiz-body { margin-block: 12px 24px; }
.nx-academy-loop-reward { font-size: 12px; color: var(--nx-text-muted); margin: 6px 0 0; }
.nx-academy-learning { padding-block: 8px; }

/* Tutor's parts inside the shell: kit faces, no gradient fills, no shadows */
.nx-academy-record .tutor-btn, .nx-academy-record .tutor-btn-primary { border-radius: var(--nx-r, 5px); box-shadow: none; background-image: none; }
.nx-academy-record .tutor-card, .nx-academy-record .tutor-course-topic-single-header { border-radius: var(--nx-r, 5px); box-shadow: none; border-color: var(--nx-border-hairline); }
.nx-academy-record .tutor-course-topic-item { border-color: var(--nx-border-hairline); }

@media (max-width: 900px) {
	.nx-academy-lesson-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
	.nx-academy-lesson-side { position: static; border-inline-end: 0; padding-inline-end: 0; max-height: none; border-bottom: 1px solid var(--nx-border-hairline); padding-bottom: 12px; }
	.nx-academy-hero { padding-block: 24px 20px; }
}
@media (prefers-color-scheme: dark) {
	.nx-academy-main { background: var(--nx-bg-canvas); color: var(--nx-text-primary); }
	.nx-xcard { background: var(--nx-bg-canvas); border-color: var(--nx-border-hairline); }
	.nx-btn { border-color: var(--nx-text-primary); color: var(--nx-text-primary); }
	.nx-btn:hover { background: var(--nx-text-primary); color: var(--nx-bg-canvas); }
}

/* The course heading (owner 2026-10-28): the article hero's eyebrow, title and dek, the facts and entry box, the
   course cover as the plate beside them. One column on phones (the cover after the title block). */
.nx-course-hero { padding-block: var(--nx-space-8, 32px) var(--nx-space-8, 32px); border-bottom: 1px solid var(--nx-border-hairline); }
.nx-course-hero__grid { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-areas: "text" "plate" "entry"; gap: var(--nx-space-6, 24px); max-width: calc(var(--nx-wide, 1180px) + 2 * var(--nx-gutter, 24px)); margin-inline: auto; padding-inline: var(--nx-gutter, 24px); box-sizing: border-box; }
.nx-course-hero__text { grid-area: text; }
.nx-course-hero__plate { grid-area: plate; }
.nx-course-hero .nx-academy-entry { grid-area: entry; }
@media (min-width: 1000px) {
	.nx-course-hero--plate .nx-course-hero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 560px); grid-template-areas: "text plate" "entry plate"; column-gap: var(--nx-space-12, 48px); align-content: start; }
	.nx-course-hero--plate .nx-course-hero__plate { align-self: start; margin-top: 6px; }
}
.nx-course-hero .nx-hero__title { max-width: 18ch; }
.nx-course-hero .nx-hero__dek { max-width: 60ch; }
.nx-course-hero__facts { margin: 14px 0 0; color: var(--nx-text-muted); font: 500 12px/1.4 var(--nx-font-mono, ui-monospace, monospace); letter-spacing: 0.08em; text-transform: uppercase; }
.nx-course-hero .nx-academy-entry { margin-top: 0; max-width: 440px; }
.nx-course-hero__plate { margin: 0; }
.nx-course-hero__plate img { display: block; inline-size: 100%; block-size: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--nx-radius, 5px); border: 1px solid var(--nx-border-hairline); }
.nx-course-hero__status { color: var(--nx-text-primary, inherit); }
