/* ==========================================================================
   Integral Primer — Front-end Styles
   ========================================================================== */

/* ---------- CSS Custom Properties ---------- */

:root {
    --primer-bg: #faf8f4;
    --primer-text: #1a1a2e;
    --primer-text-muted: #5a5a6e;
    --primer-accent: #c9a96e;
    --primer-accent-hover: #b8944f;
    --primer-accent-light: rgba(201, 169, 110, 0.12);
    --primer-chrome: #2a3a4a;
    --primer-dark-bg: #0f1923;
    --primer-border: #e8e4dc;
    --primer-section-bg: #ffffff;
    --primer-content-max: 780px;
    --primer-font-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --primer-font-body: 'Raleway', 'Segoe UI', Roboto, sans-serif;
    --primer-transition-duration: 380ms;
    --primer-transition-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- Theme Accent Overrides ---------- */

.primer-reader[data-theme="polarities"] {
    --primer-accent: #c9a96e;
    --primer-accent-hover: #b8944f;
    --primer-accent-light: rgba(201, 169, 110, 0.12);
}

.primer-reader[data-theme="quadrants"] {
    --primer-accent: #5b8c6e;
    --primer-accent-hover: #4a7a5d;
    --primer-accent-light: rgba(91, 140, 110, 0.12);
}

.primer-reader[data-theme="stages"] {
    --primer-accent: #9b6b9e;
    --primer-accent-hover: #87568a;
    --primer-accent-light: rgba(155, 107, 158, 0.12);
}

.primer-reader[data-theme="lines"] {
    --primer-accent: #6a8eb8;
    --primer-accent-hover: #5879a3;
    --primer-accent-light: rgba(106, 142, 184, 0.12);
}

.primer-reader[data-theme="states"] {
    --primer-accent: #b07a5b;
    --primer-accent-hover: #9d6a4d;
    --primer-accent-light: rgba(176, 122, 91, 0.12);
}

/* ---------- Page-level Reset (scoped to primer template) ---------- */

body.primer-page {
    background-color: var(--primer-bg);
}

body.primer-page .primer-page-wrapper {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Override common theme content wrappers */
body.primer-page .site-content,
body.primer-page .entry-content,
body.primer-page .page-content,
body.primer-page #primary,
body.primer-page #content,
body.primer-page .content-area {
    max-width: 100%;
    padding-left: 0;
    padding-right: 0;
    margin-left: 0;
    margin-right: 0;
}

/* Hide sidebar on primer pages */
body.primer-page #secondary,
body.primer-page .widget-area,
body.primer-page .sidebar {
    display: none;
}

/* Hide default page title */
body.primer-page .entry-title,
body.primer-page .page-title {
    display: none;
}

/* ---------- Primer Reader Container ---------- */

.primer-reader {
    position: relative;
    max-width: 100%;
    min-height: 80vh;
    font-family: var(--primer-font-body);
    color: var(--primer-text);
    line-height: 1.8;
    font-size: 17px;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ---------- Progress Bar ---------- */

.primer-progress {
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    height: 4px;
    background: var(--primer-border);
}

.primer-progress__track {
    display: flex;
    height: 100%;
    width: 100%;
}

.primer-progress__segment {
    flex: 1;
    height: 100%;
    background: transparent;
    transition: background-color var(--primer-transition-duration) var(--primer-transition-ease);
    border-right: 1px solid var(--primer-bg);
}

.primer-progress__segment:last-child {
    border-right: none;
}

.primer-progress__segment.is-complete {
    background: var(--primer-accent);
}

.primer-progress__segment.is-active {
    background: var(--primer-accent);
    box-shadow: 0 0 8px rgba(201, 169, 110, 0.4);
}

/* Admin bar offset */
.admin-bar .primer-progress {
    top: 32px;
}
@media (max-width: 782px) {
    .admin-bar .primer-progress {
        top: 46px;
    }
}

/* ---------- Header ---------- */

.primer-header {
    max-width: var(--primer-content-max);
    margin: 0 auto;
    padding: 72px 24px 48px;
    text-align: center;
    position: relative;
}

/* Decorative ornament above title */
.primer-header::before {
    content: '';
    display: block;
    width: 48px;
    height: 2px;
    background: var(--primer-accent);
    margin: 0 auto 32px;
    border-radius: 1px;
}

.primer-header__title {
    font-family: var(--primer-font-display);
    font-size: clamp(2.2rem, 5.5vw, 3.4rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--primer-text);
    margin: 0 0 14px;
    letter-spacing: -0.015em;
}

.primer-header__subtitle {
    font-family: var(--primer-font-body);
    font-size: clamp(0.9rem, 1.8vw, 1.1rem);
    font-weight: 500;
    color: var(--primer-text-muted);
    margin: 0 0 28px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* Decorative ornament below subtitle */
.primer-header__subtitle::after {
    content: '';
    display: block;
    width: 120px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primer-border), transparent);
    margin: 24px auto 0;
}

.primer-header__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    font-size: 0.875rem;
    color: var(--primer-text-muted);
}

/* ---------- Section Counter ---------- */

.primer-section-counter {
    font-family: var(--primer-font-body);
    font-size: 0.8125rem;
    color: var(--primer-text-muted);
    letter-spacing: 0.04em;
}

/* ---------- TOC Toggle Button ---------- */

.primer-toc-toggle {
    background: none;
    border: 1px solid var(--primer-border);
    border-radius: 6px;
    padding: 6px 10px;
    cursor: pointer;
    color: var(--primer-text-muted);
    display: flex;
    align-items: center;
    transition: color 0.2s, border-color 0.2s;
}

.primer-toc-toggle:hover {
    color: var(--primer-accent);
    border-color: var(--primer-accent);
}

/* ---------- TOC Drawer ---------- */

.primer-toc-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.primer-toc-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.primer-toc {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 340px;
    max-width: 90vw;
    background: var(--primer-section-bg);
    z-index: 999;
    transform: translateX(100%);
    transition: transform 0.35s var(--primer-transition-ease);
    overflow-y: auto;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
}

.primer-toc.is-open {
    transform: translateX(0);
}

.primer-toc__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--primer-border);
    flex-shrink: 0;
}

.primer-toc__heading {
    font-family: var(--primer-font-display);
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
    color: var(--primer-text);
}

.primer-toc__close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primer-text-muted);
    padding: 4px;
    transition: color 0.2s;
}

.primer-toc__close:hover {
    color: var(--primer-text);
}

.primer-toc__list {
    list-style: none;
    margin: 0;
    padding: 16px 0;
    flex: 1;
    overflow-y: auto;
}

.primer-toc__item {
    margin: 0;
    padding: 0;
}

.primer-toc__link {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 24px;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font-family: var(--primer-font-body);
    font-size: 0.9375rem;
    color: var(--primer-text-muted);
    transition: background-color 0.2s, color 0.2s;
    line-height: 1.4;
}

.primer-toc__link:hover {
    background: rgba(201, 169, 110, 0.08);
    color: var(--primer-text);
}

.primer-toc__item.is-active .primer-toc__link {
    color: var(--primer-text);
    font-weight: 600;
    border-left: 3px solid var(--primer-accent);
    padding-left: 21px;
}

.primer-toc__icon {
    flex-shrink: 0;
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

.primer-toc__title {
    flex: 1;
}

.primer-toc__time {
    flex-shrink: 0;
    font-size: 0.75rem;
    color: var(--primer-text-muted);
    opacity: 0.7;
}

/* ---------- Sections Container ---------- */

.primer-sections {
    max-width: var(--primer-content-max);
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
}

/* ---------- Individual Section ---------- */

.primer-section {
    display: none;
    opacity: 0;
    transform: translateY(16px);
    transition:
        opacity var(--primer-transition-duration) var(--primer-transition-ease),
        transform var(--primer-transition-duration) var(--primer-transition-ease);
    will-change: opacity, transform;
}

.primer-section.is-active {
    display: block;
}

.primer-section.is-visible {
    opacity: 1;
    transform: translateY(0) translateX(0);
}

/* Direction-aware transitions */
.primer-section.is-entering-forward {
    transform: translateX(24px);
    opacity: 0;
}

.primer-section.is-entering-backward {
    transform: translateX(-24px);
    opacity: 0;
}

.primer-section.is-exiting {
    opacity: 0;
    transform: translateY(-10px);
}

.primer-section.is-exiting-forward {
    opacity: 0;
    transform: translateX(-24px);
}

.primer-section.is-exiting-backward {
    opacity: 0;
    transform: translateX(24px);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .primer-section {
        transition: none;
        transform: none;
        will-change: auto;
    }

    .primer-section.is-visible,
    .primer-section.is-exiting,
    .primer-section.is-exiting-forward,
    .primer-section.is-exiting-backward,
    .primer-section.is-entering-forward,
    .primer-section.is-entering-backward {
        transform: none;
    }

    .primer-progress__segment {
        transition: none;
    }

    .primer-toc,
    .primer-toc-overlay {
        transition: none;
    }
}

/* Read-all mode */
.primer-reader.is-read-all .primer-section {
    display: block;
    opacity: 1;
    transform: none;
}

.primer-reader.is-read-all .primer-section + .primer-section {
    margin-top: 64px;
    padding-top: 64px;
    border-top: none;
    position: relative;
}

/* Decorative separator between sections in read-all mode */
.primer-reader.is-read-all .primer-section + .primer-section::before {
    content: '§';
    display: block;
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--primer-font-display);
    font-size: 1.4rem;
    color: var(--primer-accent);
    background: var(--primer-bg);
    padding: 0 20px;
    line-height: 1;
}

/* Hairline behind the section mark */
.primer-reader.is-read-all .primer-section + .primer-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primer-border), transparent);
}

.primer-reader.is-read-all .primer-nav {
    display: none;
}

.primer-reader.is-read-all .primer-progress {
    display: none;
}

.primer-reader.is-read-all .primer-section-counter {
    display: none;
}

/* ---------- Section Header ---------- */

.primer-section__header {
    text-align: center;
    margin-bottom: 48px;
    padding-bottom: 32px;
    position: relative;
}

/* Decorative bottom border with center ornament */
.primer-section__header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primer-accent), transparent);
}

.primer-section__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: var(--primer-accent-light);
    border-radius: 50%;
    line-height: 1;
}

.primer-section__title {
    font-family: var(--primer-font-display);
    font-size: clamp(1.7rem, 3.5vw, 2.5rem);
    font-weight: 700;
    line-height: 1.2;
    color: var(--primer-text);
    margin: 0 0 10px;
    letter-spacing: -0.01em;
}

.primer-section__read-time {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--primer-text-muted);
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* ---------- Section Content Typography ---------- */

.primer-section__content {
    font-size: 1.0625rem;
    line-height: 1.9;
    letter-spacing: 0.005em;
}

/* Drop cap on the first paragraph of each section */
.primer-section__content > p:first-child::first-letter {
    font-family: var(--primer-font-display);
    font-size: 3.4em;
    float: left;
    line-height: 0.8;
    margin: 0.05em 0.12em 0 0;
    color: var(--primer-accent);
    font-weight: 600;
}

.primer-section__content h2 {
    font-family: var(--primer-font-display);
    font-size: 1.8rem;
    font-weight: 700;
    margin: 56px 0 20px;
    color: var(--primer-text);
    line-height: 1.25;
    letter-spacing: -0.01em;
}

.primer-section__content h3 {
    font-family: var(--primer-font-display);
    font-size: 1.4rem;
    font-weight: 600;
    margin: 20px 0 16px;
    color: var(--primer-text);
    line-height: 1.3;
}

.primer-section__content h4 {
    font-family: var(--primer-font-body);
    font-size: 0.9rem;
    font-weight: 700;
    margin: 32px 0 12px;
    color: var(--primer-accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.primer-section__content p {
    margin: 0 0 1.6em;
}

.primer-section__content a {
    color: var(--primer-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: var(--primer-accent-light);
    text-decoration-thickness: 2px;
    transition: text-decoration-color 0.2s, color 0.2s;
}

.primer-section__content a:hover {
    color: var(--primer-accent-hover);
    text-decoration-color: var(--primer-accent-hover);
}

.primer-section__content ul,
.primer-section__content ol {
    margin: 0 0 1.6em;
    padding-left: 1.25em;
}

.primer-section__content ul {
    list-style: none;
}

.primer-section__content ul > li {
    position: relative;
    padding-left: 0.5em;
}

.primer-section__content ul > li::before {
    content: '';
    position: absolute;
    left: -1em;
    top: 0.7em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--primer-accent);
}

.primer-section__content li {
    margin-bottom: 0.6em;
    line-height: 1.7;
}

/* Generic blockquotes (not from [primer_quote] shortcode) */
.primer-section__content blockquote:not(.primer-quote__text) {
    margin: 2.5em 0;
    padding: 1.5em 2em;
    border-left: 3px solid var(--primer-accent);
    background: var(--primer-accent-light);
    border-radius: 0 8px 8px 0;
    font-family: var(--primer-font-display);
    font-size: 1.2rem;
    font-style: italic;
    line-height: 1.6;
    color: var(--primer-text);
}

.primer-section__content blockquote p:last-child {
    margin-bottom: 0;
}

.primer-section__content img:not(.primer-video__thumb):not(.no-shadow) {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.primer-section__content img.no-shadow,
.primer-section__content .no-shadow img {
    box-shadow: none;
    border-radius: 0;
}

/* Prevent content img styles from leaking into video/promo components */
.primer-promo img {
    border-radius: 0;
    margin: 0;
    box-shadow: none;
}

.primer-section__content table {
    width: 100%;
    border-collapse: collapse;
    margin: 2.5em 0;
    font-size: 0.9375rem;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.primer-section__content th,
.primer-section__content td {
    padding: 14px 18px;
    text-align: left;
    border-bottom: 1px solid var(--primer-border);
}

.primer-section__content th {
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primer-text-muted);
    background: rgba(42, 58, 74, 0.04);
}

.primer-section__content tr:last-child td {
    border-bottom: none;
}

.primer-section__content strong {
    font-weight: 600;
    color: var(--primer-text);
}

.primer-section__content em {
    font-style: italic;
}

.primer-section__content hr {
    border: none;
    height: 0;
    margin: 3em 0;
    text-align: center;
}

/* Decorative divider with three dots */
.primer-section__content hr::after {
    content: '· · ·';
    display: inline-block;
    font-size: 1.4rem;
    letter-spacing: 0.6em;
    color: var(--primer-accent);
}

/* ---------- Background Variants ---------- */

.primer-section--bg-dark {
    background: var(--primer-dark-bg);
    color: #e0ddd5;
    padding: 40px 32px;
    border-radius: 12px;
    margin: 0 -32px;
}

.primer-section--bg-dark .primer-section__title {
    color: #ffffff;
}

.primer-section--bg-dark .primer-section__read-time {
    color: rgba(255, 255, 255, 0.5);
}

.primer-section--bg-warm {
    background: rgba(201, 169, 110, 0.06);
    padding: 40px 32px;
    border-radius: 12px;
    margin: 0 -32px;
}

.primer-section--bg-accent .primer-section__header {
    border-bottom-color: var(--primer-accent);
}

/* ---------- Navigation ---------- */

.primer-nav {
    max-width: var(--primer-content-max);
    margin: 56px auto 0;
    padding: 0 24px 24px;
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 16px;
}

/* Decorative separator above nav */
.primer-nav::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primer-border), transparent);
    margin-top: -28px;
}

.primer-nav__btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 28px;
    background: var(--primer-section-bg);
    border: 1px solid var(--primer-border);
    border-radius: 12px;
    cursor: pointer;
    font-family: var(--primer-font-body);
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--primer-text);
    transition: border-color 0.25s, box-shadow 0.25s, color 0.25s, transform 0.2s;
    min-height: 60px;
    line-height: 1.3;
}

.primer-nav__btn:hover:not(:disabled) {
    border-color: var(--primer-accent);
    box-shadow: 0 4px 16px rgba(201, 169, 110, 0.15);
    color: var(--primer-accent);
    transform: translateY(-1px);
}

.primer-nav__btn:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(201, 169, 110, 0.1);
}

.primer-nav__btn:disabled {
    opacity: 0.3;
    cursor: default;
}

.primer-nav__btn svg {
    flex-shrink: 0;
    transition: transform 0.2s;
}

.primer-nav__next:hover:not(:disabled) svg {
    transform: translateX(3px);
}

.primer-nav__prev:hover:not(:disabled) svg {
    transform: translateX(-3px);
}

.primer-nav__prev {
    flex: 0 1 auto;
}

.primer-nav__next {
    flex: 1 1 auto;
    justify-content: flex-end;
    text-align: right;
}

.primer-nav__label {
    display: flex;
    flex-direction: column;
    align-items: inherit;
}

.primer-nav__hint {
    display: block;
    font-family: var(--primer-font-display);
    font-size: 0.875rem;
    font-weight: 500;
    font-style: italic;
    color: var(--primer-text-muted);
    margin-top: 3px;
}

/* ==========================================================================
   Session 2: Content Shortcode Styles
   ========================================================================== */

/* ---------- Practice / Reflection Box ---------- */

.primer-practice {
    margin: 2.5em 0;
    padding: 32px 32px 28px;
    background: linear-gradient(135deg, rgba(201, 169, 110, 0.06) 0%, rgba(201, 169, 110, 0.02) 100%);
    border-left: 4px solid var(--primer-accent);
    border-radius: 0 12px 12px 0;
    position: relative;
}

.primer-practice__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--primer-accent);
    color: #fff;
    border-radius: 50%;
    margin-bottom: 16px;
}

.primer-practice__title {
    font-family: var(--primer-font-display);
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--primer-text);
    margin: 0 0 12px;
    line-height: 1.3;
}

.primer-practice__content {
    font-size: 1rem;
    line-height: 1.75;
}

.primer-practice__content p:last-child {
    margin-bottom: 0;
}

/* ---------- Insight Callout ---------- */

.primer-insight {
    margin: 2.5em 0;
    padding: 36px 40px;
    background: var(--primer-text);
    color: #f0ede6;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
}

.primer-insight__accent {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primer-accent) 0%, transparent 100%);
}

.primer-insight__content {
    font-family: var(--primer-font-display);
    font-size: 1.3rem;
    font-style: italic;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.primer-insight__content p:last-child {
    margin-bottom: 0;
}

/* ---------- Quote ---------- */

.primer-quote {
    margin: 0 0 20px;
    padding: 0;
}

.primer-quote__text {
    margin: 0;
    padding: 28px 36px;
    border-left: 3px solid var(--primer-accent);
    background: rgba(201, 169, 110, 0.05);
    border-radius: 0 10px 10px 0;
    font-family: var(--primer-font-display);
    font-size: 1.25rem;
    font-style: italic;
    line-height: 1.6;
    color: var(--primer-text);
}

.primer-quote__text p:last-child {
    margin-bottom: 0;
}

.primer-quote__attribution {
    margin-top: 10px;
    margin-bottom: 0;
    float: right;
    padding-left: 36px;
    font-family: var(--primer-font-body);
    font-size: 0.9rem;
    font-style: normal;
    color: var(--primer-text-muted);
    letter-spacing: 0.02em;
}

/* ---------- Video Embed Card ---------- */

.primer-video {
    margin: 2.5em 0;
    background: var(--primer-dark-bg);
    border-radius: 12px;
    overflow: hidden;
    color: #d0cdc5;
}

.primer-video__player {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 */
    background: #000;
    cursor: pointer;
}

.primer-video .primer-video__thumb {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
}

.primer-video__player:hover .primer-video__thumb {
    opacity: 0.85;
}

.primer-video__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: none;
    border: none;
    cursor: pointer;
    transition: transform 0.2s;
    z-index: 2;
}

.primer-video__player:hover .primer-video__play {
    transform: translate(-50%, -50%) scale(1.08);
}

/* Loaded state: hide facade, show iframe */
.primer-video__player.is-loaded .primer-video__thumb,
.primer-video__player.is-loaded .primer-video__play {
    display: none;
}

.primer-video__player iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.primer-video__info {
    padding: 24px 28px;
}

.primer-video .primer-video__title {
    font-family: var(--primer-font-display);
    font-size: 1.3rem;
    font-weight: 600;
    color: #f0ede6;
    margin: 0 0 8px;
    line-height: 1.3;
}

.primer-video__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 12px;
}

.primer-video__speaker {
    font-style: italic;
}

.primer-video__duration::before {
    content: '·';
    margin-right: 16px;
}

.primer-video__description {
    font-size: 0.9375rem;
    line-height: 1.65;
    margin: 0 0 16px;
    color: #b0ada5;
}

.primer-video .primer-video__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--primer-font-body);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primer-accent);
    text-decoration: none;
    transition: color 0.2s;
}

.primer-video .primer-video__cta:hover {
    color: #dfc08a;
}

/* ---------- Promo Card ---------- */

.primer-promo {
    margin: 2.5em 0;
    background: var(--primer-dark-bg);
    border-radius: 12px;
    overflow: hidden;
    color: #d0cdc5;
}

.primer-promo__image {
    width: 100%;
    overflow: hidden;
}

.primer-promo__image img {
    width: 100%;
    height: 420px;
    object-fit: cover;
    display: block;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
}

.primer-promo__body {
    padding: 28px 28px 24px;
}

.primer-promo__label {
    display: inline-block;
    font-family: var(--primer-font-body);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primer-accent);
    background: rgba(201, 169, 110, 0.12);
    padding: 4px 12px;
    border-radius: 4px;
    margin-bottom: 14px;
}

.primer-promo__header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.primer-promo__icon {
    font-size: 1.75rem;
    flex-shrink: 0;
}

.primer-promo .primer-promo__title {
    font-family: var(--primer-font-display);
    font-size: 1.4rem;
    font-weight: 600;
    color: #f0ede6;
    margin: 0;
    line-height: 1.3;
}

.primer-promo__instructor {
    font-size: 0.9rem;
    font-style: italic;
    color: rgba(255, 255, 255, 0.55);
    margin: 0 0 12px;
}

.primer-promo__description {
    font-size: 0.9375rem;
    line-height: 1.65;
    margin: 0 0 20px;
    color: #b0ada5;
}

.primer-promo .primer-promo__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--primer-font-body);
    font-size: 0.9375rem;
    font-weight: 600;
    color: #0f1923;
    background: var(--primer-accent);
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    transition: background-color 0.2s, transform 0.15s;
}

.primer-promo .primer-promo__cta:hover {
    color: #0f1923;
    background: #dfc08a;
    transform: translateY(-1px);
}

.primer-promo__cta svg {
    stroke: #0f1923;
}

/* Promo with custom theme color */
.primer-promo[style*="--promo-accent"] {
    background: var(--promo-accent, var(--primer-dark-bg));
}

/* ---------- Accordion ---------- */

.primer-accordion {
    margin: 2em 0;
    border: 1px solid var(--primer-border);
    border-radius: 12px;
    overflow: hidden;
}

.primer-accordion__item {
    border-bottom: 1px solid var(--primer-border);
}

.primer-accordion__item:last-child {
    border-bottom: none;
}

.primer-accordion__trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 18px 24px;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--primer-font-body);
    font-size: 1rem;
    font-weight: 500;
    color: var(--primer-text);
    text-align: left;
    transition: background-color 0.2s;
    line-height: 1.4;
    min-height: 48px;
}

.primer-accordion__trigger:hover {
    background: rgba(201, 169, 110, 0.05);
}

.primer-accordion__trigger-text {
    flex: 1;
    padding-right: 12px;
}

.primer-accordion__arrow {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    color: var(--primer-text-muted);
    transition: transform 0.25s var(--primer-transition-ease);
}

.primer-accordion__item.is-open .primer-accordion__arrow {
    transform: rotate(180deg);
}

.primer-accordion__panel {
    overflow: hidden;
}

.primer-accordion__panel[hidden] {
    display: none;
}

.primer-accordion__content {
    padding: 0 24px 20px;
    font-size: 0.9625rem;
    line-height: 1.75;
}

.primer-accordion__content p:last-child {
    margin-bottom: 0;
}

/* ---------- Embed Placeholder ---------- */

.primer-embed {
    margin: 2.5em 0;
    border: 2px dashed var(--primer-border);
    border-radius: 12px;
    overflow: hidden;
    background: rgba(42, 58, 74, 0.02);
}

.primer-embed__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: inherit;
    padding: 48px 24px;
}

.primer-embed__loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--primer-text-muted);
    font-size: 0.9375rem;
}

.primer-embed__loading svg {
    opacity: 0.4;
    animation: primer-spin 3s linear infinite;
}

@keyframes primer-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ---------- Quadrant Grid ---------- */

.primer-quadrant-grid {
    margin: 2.5em 0;
    position: relative;
    padding: 32px 48px;
}

.primer-quadrant-grid__labels {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.primer-quadrant-grid__label {
    position: absolute;
    font-family: var(--primer-font-body);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--primer-text-muted);
    white-space: nowrap;
}

.primer-quadrant-grid__label--top {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.primer-quadrant-grid__label--bottom {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.primer-quadrant-grid__label--left {
    left: 0;
    top: 50%;
    transform: translateY(-50%) rotate(-90deg);
}

.primer-quadrant-grid__label--right {
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(90deg);
}

.primer-quadrant-grid__cells {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 2px;
    background: var(--primer-border);
    border-radius: 12px;
    overflow: hidden;
}

.primer-quadrant-grid__cell {
    background: var(--primer-section-bg);
    padding: 28px 24px;
}

.primer-quadrant-grid__cell--ul {
    grid-column: 1;
    grid-row: 1;
}

.primer-quadrant-grid__cell--ur {
    grid-column: 2;
    grid-row: 1;
}

.primer-quadrant-grid__cell--ll {
    grid-column: 1;
    grid-row: 2;
}

.primer-quadrant-grid__cell--lr {
    grid-column: 2;
    grid-row: 2;
}

.primer-quadrant-grid__cell-title {
    font-family: var(--primer-font-display);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primer-text);
    margin: 0 0 10px;
    line-height: 1.3;
}

.primer-quadrant-grid__cell-content {
    font-size: 0.9rem;
    line-height: 1.65;
    color: var(--primer-text-muted);
}

.primer-quadrant-grid__cell-content p:last-child {
    margin-bottom: 0;
}

/* ---------- Stages Gallery Placeholder ---------- */

.primer-stages-gallery--placeholder {
    margin: 2.5em 0;
    padding: 48px 32px;
    text-align: center;
    background: linear-gradient(135deg, rgba(201, 169, 110, 0.04) 0%, rgba(42, 58, 74, 0.04) 100%);
    border: 1px dashed var(--primer-border);
    border-radius: 12px;
}

.primer-stages-gallery__icon {
    display: block;
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.primer-stages-gallery__title {
    font-family: var(--primer-font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primer-text);
    margin: 0 0 8px;
}

.primer-stages-gallery__message {
    font-size: 0.9375rem;
    color: var(--primer-text-muted);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.65;
}

/* ---------- Read All Toggle ---------- */

.primer-read-all {
    text-align: center;
    padding: 16px 24px 48px;
}

.primer-read-all__toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--primer-font-body);
    font-size: 0.875rem;
    color: var(--primer-text-muted);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    transition: color 0.2s;
}

.primer-read-all__toggle:hover {
    color: var(--primer-accent);
}

/* Read-all mode: show return button */
.primer-reader.is-read-all .primer-read-all__toggle::before {
    content: '';
}

/* ---------- Focus & Accessibility ---------- */

.primer-nav__btn:focus-visible,
.primer-toc-toggle:focus-visible,
.primer-toc__close:focus-visible,
.primer-toc__link:focus-visible,
.primer-accordion__trigger:focus-visible,
.primer-read-all__toggle:focus-visible,
.primer-video__play:focus-visible {
    outline: 2px solid var(--primer-accent);
    outline-offset: 3px;
}

.primer-section__title:focus {
    outline: none;
}

/* ---------- Responsive: Tablet (768–1023px) ---------- */

@media (max-width: 1023px) {
    .primer-header {
        padding: 48px 20px 32px;
    }

    .primer-sections {
        padding: 0 20px;
    }

    .primer-nav {
        padding: 0 20px 20px;
    }

    /* TOC: full width from bottom on tablet */
    .primer-toc {
        top: auto;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        max-width: 100%;
        max-height: 70vh;
        transform: translateY(100%);
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -4px 32px rgba(0, 0, 0, 0.15);
    }

    .primer-toc.is-open {
        transform: translateY(0);
    }

    /* Bottom sheet drag handle */
    .primer-toc__header::before {
        content: '';
        display: block;
        width: 36px;
        height: 4px;
        background: var(--primer-border);
        border-radius: 2px;
        margin: 0 auto 16px;
    }
}

/* ---------- Responsive: Mobile (< 768px) ---------- */

@media (max-width: 767px) {
    .primer-reader {
        font-size: 16px;
    }

    .primer-header {
        padding: 40px 20px 28px;
    }

    .primer-header::before {
        margin-bottom: 24px;
        width: 36px;
    }

    .primer-header__title {
        font-size: 1.75rem;
    }

    .primer-header__subtitle {
        font-size: 0.8rem;
        margin-bottom: 20px;
    }

    .primer-header__subtitle::after {
        width: 80px;
        margin-top: 18px;
    }

    .primer-sections {
        padding: 0 20px;
    }

    .primer-section__icon {
        font-size: 1.6rem;
        width: 52px;
        height: 52px;
        margin-bottom: 16px;
    }

    .primer-section__title {
        font-size: 1.4rem;
    }

    .primer-section__header {
        margin-bottom: 32px;
        padding-bottom: 24px;
    }

    /* Smaller drop cap on mobile */
    .primer-section__content > p:first-child::first-letter {
        font-size: 2.8em;
    }

    .primer-section__content h2 {
        font-size: 1.4rem;
    }

    .primer-section__content h3 {
        font-size: 1.15rem;
    }

    .primer-section__content blockquote {
        padding: 1em 1.25em;
        font-size: 1.05rem;
    }

    /* Stacked nav buttons on mobile */
    .primer-nav {
        flex-direction: column;
        padding: 0 20px 20px;
        margin-top: 36px;
    }

    .primer-nav__btn {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .primer-nav__next {
        justify-content: center;
        text-align: center;
    }

    .primer-nav__label {
        align-items: center;
    }

    /* TOC: full screen overlay from bottom */
    .primer-toc {
        top: auto;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        max-width: 100%;
        max-height: 85vh;
        transform: translateY(100%);
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -4px 32px rgba(0, 0, 0, 0.18);
    }

    .primer-toc.is-open {
        transform: translateY(0);
    }

    /* Bottom sheet drag handle */
    .primer-toc__header::before {
        content: '';
        display: block;
        width: 36px;
        height: 4px;
        background: var(--primer-border);
        border-radius: 2px;
        margin: 0 auto 16px;
    }

    .primer-toc__link {
        padding: 14px 20px;
        min-height: 52px;
    }

    .primer-section--bg-dark,
    .primer-section--bg-warm {
        margin: 0 -20px;
        padding: 32px 20px;
        border-radius: 0;
    }

    /* Practice box */
    .primer-practice {
        padding: 24px 20px 20px;
        margin: 2em 0;
    }

    /* Insight callout */
    .primer-insight {
        padding: 28px 24px;
        margin: 2em 0;
    }

    .primer-insight__content {
        font-size: 1.1rem;
    }

    /* Quote */
    .primer-quote__text {
        padding: 20px 24px;
        font-size: 1.1rem;
    }

    .primer-quote__attribution {
        padding-left: 24px;
    }

    /* Video card */
    .primer-video__info {
        padding: 20px;
    }

    .primer-video__title {
        font-size: 1.15rem;
    }

    .primer-video__meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .primer-video__duration::before {
        display: none;
    }

    /* Promo card */
    .primer-promo__body {
        padding: 20px;
    }

    .primer-promo__image img {
        height: 180px;
    }

    .primer-promo__title {
        font-size: 1.2rem;
    }

    .primer-promo__cta {
        width: 100%;
        justify-content: center;
    }

    /* Accordion */
    .primer-accordion__trigger {
        padding: 16px 20px;
    }

    .primer-accordion__content {
        padding: 0 20px 16px;
    }

    /* Quadrant grid: stack on mobile */
    .primer-quadrant-grid {
        padding: 0;
    }

    .primer-quadrant-grid__labels {
        display: none;
    }

    .primer-quadrant-grid__cells {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .primer-quadrant-grid__cell--ul,
    .primer-quadrant-grid__cell--ur,
    .primer-quadrant-grid__cell--ll,
    .primer-quadrant-grid__cell--lr {
        grid-column: 1;
        grid-row: auto;
    }

    .primer-quadrant-grid__cell {
        padding: 20px;
    }
}

/* ==========================================================================
   Kit-Aware Primer Reader Navigation
   ========================================================================== */

/* ---------- Kit Breadcrumb ---------- */

.primer-breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--primer-font-body);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.primer-breadcrumb__kit-link {
    color: #c9a96e;
    text-decoration: none;
    transition: color 0.2s;
}

.primer-breadcrumb__kit-link:hover {
    color: var(--primer-accent-hover);
    text-decoration: underline;
}

.primer-breadcrumb__separator {
    color: #8a9bb0;
}

.primer-breadcrumb__position {
    color: #8a9bb0;
    font-weight: 500;
}

/* Hide breadcrumb in read-all mode */
.primer-reader.is-read-all .primer-breadcrumb {
    display: none;
}

/* Hide next button when kit nav takes over */
.primer-nav__next[aria-hidden="true"] {
    display: none;
}

/* ---------- Next Primer Card (inside nav) ---------- */

.primer-nav__next-primer {
    display: none;
    flex: 1;
}

.primer-nav__next-primer[aria-hidden="false"] {
    display: block;
    animation: primerNextFadeIn 0.4s var(--primer-transition-ease) forwards;
}

.primer-nav__next-primer-inner {
    background: var(--primer-dark-bg);
    border: 1px solid var(--primer-accent);
    border-radius: 12px;
    padding: 32px 40px;
    text-align: center;
}

.primer-nav__next-primer-eyebrow {
    font-family: var(--primer-font-body);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--primer-accent);
    margin: 0 0 12px;
}

.primer-nav__next-primer-title {
    font-family: var(--primer-font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 8px;
    line-height: 1.2;
}

.primer-nav__next-primer-subtitle {
    font-family: var(--primer-font-body);
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 0 24px;
    letter-spacing: 0.04em;
}

.primer-nav__next-primer-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primer-accent);
    color: var(--primer-dark-bg);
    font-family: var(--primer-font-body);
    font-size: 0.9375rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-decoration: none;
    padding: 12px 28px;
    border-radius: 6px;
    transition: background-color 0.2s, transform 0.2s;
}

.primer-nav__next-primer-btn:hover {
    background: var(--primer-accent-hover);
    transform: translateX(2px);
}

@keyframes primerNextFadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Return to Kit Link (inside nav) ---------- */

.primer-nav__return-kit {
    display: none;
    flex: 1;
    justify-content: center;
    text-align: center;
    text-decoration: none;
}

.primer-nav__return-kit[aria-hidden="false"] {
    display: flex;
}

/* Hide kit nav elements in read-all mode */
.primer-reader.is-read-all .primer-nav__next-primer,
.primer-reader.is-read-all .primer-nav__return-kit {
    display: none !important;
}

@media (max-width: 640px) {
    .primer-nav__next-primer-inner {
        padding: 24px 20px;
    }
}
