/* Local page-level adjustments. The template's global stylesheet is unchanged. */
.brand span {
  font-size: 0.94rem;
}

.slide.module-page .image-frame {
  min-height: 0;
  width: fit-content;
  max-width: 100%;
  aspect-ratio: auto;
  margin: 0 auto;
  background: #f7fbff;
}

.slide.module-page .image-frame img,
.slide.module-page.source-image .image-frame img,
.slide.module-page.cover-page .image-frame img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  background: #f7fbff;
}

.slide.module-page.large-visual {
  grid-template-columns: 0.92fr 1.08fr;
  align-items: center;
}

.slide.module-page.large-visual .image-panel {
  align-self: center;
}

.slide.module-page.tall-visual {
  grid-template-columns: 1fr 1fr;
}

.slide.module-page.tall-visual .image-frame img {
  max-height: 470px;
}

.slide.module-page.medium-visual .image-frame img {
  max-height: 450px;
}

.slide.module-page.closing-visual .image-frame img {
  max-height: 360px;
}

.slide.module-page.compact .rich p {
  font-size: 0.99rem;
  line-height: 1.48;
  margin-bottom: 9px;
}

.slide.module-page.compact .rich li {
  font-size: 0.96rem;
  line-height: 1.42;
  margin-bottom: 6px;
}

.author-note {
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid #dce5f1;
  color: #4f5d71;
  font-size: 0.88rem;
  line-height: 1.45;
}

.author-note p {
  margin: 0 0 4px;
  font-size: inherit;
  line-height: inherit;
}

.cover-highlight {
  margin-top: 16px;
  padding: 13px 18px;
  border-left: 6px solid var(--vita-red);
  border-radius: 8px;
  background: #4f87a8;
  color: #ffffff;
  box-shadow: none;
}

.cover-highlight::before {
  content: none;
}

.cover-highlight span {
  display: block;
  color: #ffffff;
  font-family: "Source Serif 4", Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.35;
}

.two-column-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 20px;
  margin: 0;
  padding-left: 20px;
}

.principles-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  margin: 0;
  padding-left: 20px;
}

.principles-list li {
  break-inside: avoid;
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.compare-box {
  border: 1px solid #d0deef;
  background: #f8fbff;
  border-radius: 8px;
  padding: 11px 12px;
}

.compare-box h3 {
  margin: 0 0 7px;
  color: #08335e;
  font-size: 1rem;
}

.compare-box p,
.compare-box li {
  font-size: 0.92rem !important;
  line-height: 1.4 !important;
}

.links-list li {
  overflow-wrap: anywhere;
}

.quiz-finish h3 {
  margin: 0 0 8px;
  color: #08335e;
}

.quiz-finish p {
  margin: 0 0 10px;
}

.small-note {
  color: #4f5d71;
  font-size: 0.9rem !important;
}

@media (max-width: 920px) {
  .slide.module-page.large-visual,
  .slide.module-page.tall-visual {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .two-column-list,
  .compare-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-height: 820px) {
  body {
    padding-top: 12px;
    padding-bottom: 12px;
  }
}


/* Final page-specific balancing */
.principles-page .principles-list {
  padding-left: 36px;
}

.regulation-page {
  grid-template-columns: 1.14fr 0.86fr;
  align-items: center;
}

.regulation-page .image-panel {
  width: 100%;
  max-width: 390px;
  justify-self: center;
}

.regulation-page .image-frame img {
  width: 100%;
  max-height: 390px;
}

.downloads-page {
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
}

.downloads-page .image-panel {
  width: 100%;
  max-width: 330px;
  justify-self: center;
}

.downloads-page .image-frame img {
  width: 100%;
  max-height: 320px;
}

@media (max-width: 920px) {
  .regulation-page,
  .downloads-page {
    grid-template-columns: 1fr;
  }

  .regulation-page .image-panel,
  .downloads-page .image-panel {
    max-width: 480px;
  }
}

/* Keep the closing page within a standard 1366 x 768 viewport. */
.closing-visual .rights-box {
  padding: 10px 12px;
}

.closing-visual .rights-box p {
  margin-bottom: 7px;
  font-size: 0.94rem;
  line-height: 1.4;
}

.closing-visual .slide-footer {
  font-size: 0.86rem;
  line-height: 1.35;
}

/* M2-T2-MLC6 local balancing; global design remains the M1-T3-MLC2 template. */
.dense-page .rich p {
  font-size: 0.92rem;
  line-height: 1.4;
  margin-bottom: 7px;
}

.dense-page .rich li {
  font-size: 0.9rem;
  line-height: 1.34;
  margin-bottom: 4px;
}

.quiz-textarea {
  width: 100%;
  min-height: 145px;
  resize: vertical;
  border: 1px solid #cedaeb;
  border-radius: 8px;
  padding: 11px 12px;
  font: inherit;
  font-size: 0.98rem;
  line-height: 1.45;
  color: var(--text);
  background: #ffffff;
}

.quiz-textarea:focus {
  outline: 2px solid rgba(0, 87, 168, 0.2);
  border-color: var(--vita-blue);
}

.quiz-textarea:disabled {
  background: #f5f7fa;
  color: #33455c;
}

.references-page .rich li {
  font-size: 0.92rem;
  line-height: 1.35;
  margin-bottom: 5px;
}

@media (max-height: 820px) {
  .dense-page .rich p,
  .dense-page .rich li,
  .references-page .rich li {
    font-size: 0.86rem;
  }
}


/* Page 6 rebalance: two-column competency list with a larger collage. */
.competencies-page {
  grid-template-columns: 0.92fr 1.08fr;
  align-items: start;
}

.competencies-page .principles-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 20px;
  padding-left: 20px;
  margin-top: 2px;
}

.competencies-page .principles-list li {
  margin-bottom: 0;
  break-inside: avoid;
  font-size: 0.88rem;
  line-height: 1.34;
}

.competencies-page .image-panel {
  align-self: start;
}

.competencies-page .image-frame {
  width: 100%;
  min-height: 0;
}

.competencies-page .image-frame img {
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: contain;
}

@media (max-width: 920px) {
  .competencies-page {
    grid-template-columns: 1fr;
  }

  .competencies-page .principles-list {
    grid-template-columns: 1fr;
  }
}


/* Final refinement pass requested by reviewer feedback */

/* Page 3: enlarge the illustration for a fuller, more balanced layout. */
.slide-3 {
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
}

.slide-3 .image-panel {
  width: 100%;
  max-width: 610px;
  justify-self: end;
  align-self: center;
}

.slide-3 .image-frame {
  width: 100%;
}

.slide-3 .image-frame img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Page 4: remove visible empty frame space and slightly increase the visual. */
.slide-4 {
  grid-template-columns: 0.92fr 1.08fr;
  align-items: center;
}

.slide-4 .image-panel {
  width: 100%;
  max-width: 620px;
  justify-self: end;
}

.slide-4 .image-frame {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: #ffffff;
}

.slide-4 .image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

/* Page 6: tighten typography and enlarge the collage, following the supplied sketch more closely. */
.slide-6 {
  grid-template-columns: 0.9fr 1.1fr;
  gap: 20px;
  align-items: start;
}

.slide-6 h1 {
  max-width: 560px;
}

.slide-6 h2 {
  max-width: 560px;
}

.slide-6 .principles-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
  padding-left: 20px;
}

.slide-6 .principles-list li {
  font-size: 0.87rem;
  line-height: 1.32;
  margin-bottom: 0;
}

.slide-6 .image-panel {
  width: 100%;
  max-width: 640px;
  justify-self: end;
}

.slide-6 .image-frame {
  width: 100%;
}

.slide-6 .image-frame img {
  width: 100%;
  max-height: 510px;
  object-fit: contain;
}

/* Page 10: crop the visual a bit tighter so it better fills the right column. */
.slide-10 {
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.slide-10 .image-panel {
  width: 100%;
  max-width: 560px;
  justify-self: end;
}

.slide-10 .image-frame {
  width: 100%;
  aspect-ratio: 4 / 3;
}

.slide-10 .image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

/* Pages 11 and 13: larger visuals for a more even page fill. */
.slide-11,
.slide-13 {
  grid-template-columns: 0.92fr 1.08fr;
  align-items: center;
}

.slide-11 .image-panel,
.slide-13 .image-panel {
  width: 100%;
  max-width: 600px;
  justify-self: end;
}

.slide-11 .image-frame,
.slide-13 .image-frame {
  width: 100%;
}

.slide-11 .image-frame img,
.slide-13 .image-frame img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Page 12: highlight the instructor minimum in a full-width callout style. */
.slide-12 .small-note {
  display: block;
  width: 100%;
  margin-top: 14px;
  padding: 12px 16px;
  border-left: 6px solid var(--vita-blue);
  border-radius: 8px;
  background: #eef5ff;
  color: #1f3451;
  font-size: 0.95rem !important;
  line-height: 1.45 !important;
}

/* Page 16: enlarge the closing illustration while keeping the legal block readable. */
.slide-16 {
  grid-template-columns: 0.98fr 1.02fr;
  align-items: start;
}

.slide-16 .image-panel {
  width: 100%;
  max-width: 600px;
  justify-self: end;
}

.slide-16 .image-frame {
  width: 100%;
}

.slide-16 .image-frame img {
  width: 100%;
  max-height: 430px;
  object-fit: cover;
}

@media (max-width: 920px) {
  .slide-3,
  .slide-4,
  .slide-6,
  .slide-10,
  .slide-11,
  .slide-13,
  .slide-16 {
    grid-template-columns: 1fr;
  }

  .slide-6 .principles-list {
    grid-template-columns: 1fr;
  }
}


/* Additional final balancing revisions */
.page3-balanced {
  grid-template-columns: 0.98fr 1.02fr;
  align-items: center;
}
.page3-balanced .image-panel {
  align-self: center;
}
.page3-balanced .image-frame {
  width: 100%;
}
.page3-balanced .image-frame img {
  width: 100%;
  max-height: 545px;
  object-fit: cover;
}

.page4-balanced {
  grid-template-columns: 0.96fr 1.04fr;
  align-items: center;
}
.page4-balanced .image-panel {
  align-self: center;
}
.page4-balanced .image-frame {
  width: 100%;
}
.page4-balanced .image-frame img {
  width: 100%;
  max-height: 470px;
  object-fit: cover;
  object-position: center top;
}

/* Page 6 closer to the approved sketch */
.competencies-page {
  grid-template-columns: 0.95fr 1.05fr;
  gap: 22px;
}
.competencies-page .rich {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 22px;
  align-items: start;
}
.competencies-page .rich .principles-list {
  grid-column: 1 / -1;
}
.competencies-page .img-caption {
  font-size: 0.84rem;
  line-height: 1.32;
}

.tools-page {
  grid-template-columns: 1fr 1fr;
  align-items: center;
}
.tools-page .image-panel,
.project-page .image-panel,
.references-page .image-panel {
  align-self: center;
}
.tools-page .image-frame,
.project-page .image-frame,
.references-page .image-frame,
.final-page .image-frame {
  width: 100%;
}
.tools-page .image-frame img {
  width: 100%;
  max-height: 455px;
  object-fit: cover;
  object-position: center center;
}

.project-page {
  grid-template-columns: 0.98fr 1.02fr;
  align-items: center;
}
.project-page .image-frame img {
  width: 100%;
  max-height: 470px;
  object-fit: cover;
  object-position: center center;
}

.checklist-page .slide-footer {
  padding-top: 10px;
}
.checklist-page .wide-highlight {
  display: block;
  width: 100%;
  border-left: 6px solid var(--vita-blue);
  background: #f1f7ff;
  border-radius: 8px;
  padding: 14px 16px;
  color: #1f3451;
  font-size: 1rem;
  line-height: 1.5;
}

.references-page {
  grid-template-columns: 1.02fr 0.98fr;
  align-items: center;
}
.references-page .image-frame img {
  width: 100%;
  max-height: 470px;
  object-fit: cover;
  object-position: center center;
}

.final-page {
  grid-template-columns: 0.96fr 1.04fr;
  align-items: center;
}
.final-page .image-frame img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  object-position: center center;
}

@media (max-width: 920px) {
  .page3-balanced,
  .page4-balanced,
  .tools-page,
  .project-page,
  .references-page,
  .final-page,
  .competencies-page {
    grid-template-columns: 1fr;
  }
}


/* Aliases for existing slide class names */
.page-3-visual {
  grid-template-columns: 0.98fr 1.02fr;
  align-items: center;
}
.page-3-visual .image-panel,
.page-4-visual .image-panel {
  align-self: center;
}
.page-3-visual .image-frame,
.page-4-visual .image-frame {
  width: 100%;
}
.page-3-visual .image-frame img {
  width: 100%;
  max-height: 545px;
  object-fit: cover;
  object-position: center center;
}
.page-4-visual {
  grid-template-columns: 0.96fr 1.04fr;
  align-items: center;
}
.page-4-visual .image-frame img {
  width: 100%;
  max-height: 470px;
  object-fit: cover;
  object-position: center top;
}
@media (max-width: 920px) {
  .page-3-visual,
  .page-4-visual {
    grid-template-columns: 1fr;
  }
}

/* --- Reviewer preview fix: page 6 and page 16 --- */
.slide-6 {
  grid-template-columns: 0.92fr 1.08fr;
  gap: 22px;
  align-items: start;
}

.slide-6 .text-panel {
  gap: 12px;
}

.slide-6 h1,
.slide-6 h2 {
  max-width: 560px;
}

.slide-6 .rich {
  display: block;
}

.slide-6 .rich .principles-list-top {
  display: block;
  margin: 4px 0 0 20px;
  padding: 0;
}

.slide-6 .rich .principles-list-top li {
  margin-bottom: 10px;
  font-size: 0.94rem;
  line-height: 1.4;
}

.slide-6 .image-panel {
  width: 100%;
  max-width: 640px;
  justify-self: end;
  align-self: start;
}

.slide-6 .image-frame {
  width: 100%;
}

.slide-6 .image-frame img {
  width: 100%;
  max-height: 500px;
  object-fit: contain;
  object-position: center top;
}

.slide-6 .img-caption {
  font-size: 0.84rem;
  line-height: 1.32;
}

.slide-6 .slide-footer {
  padding-top: 0;
  margin-top: -2px;
  color: var(--text);
}

.slide-6 .competencies-bottom-wrap {
  width: 100%;
}

.slide-6 .competencies-bottom-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 34px;
  margin: 0 0 2px 20px;
  padding: 0;
}

.slide-6 .competencies-bottom-list li {
  margin-bottom: 0;
  font-size: 0.96rem;
  line-height: 1.45;
  color: var(--text);
}

.slide-16 {
  grid-template-columns: 0.95fr 1.05fr;
  align-items: start;
  gap: 24px;
}

.slide-16 .text-panel {
  gap: 10px;
}

.slide-16 h2:empty {
  display: none;
}

.slide-16 .rich {
  margin-top: 2px;
}

.slide-16 .image-panel {
  width: 100%;
  max-width: 610px;
  justify-self: end;
  align-self: start;
}

.slide-16 .image-frame {
  width: 100%;
}

.slide-16 .image-frame img {
  width: 100%;
  max-height: 430px;
  object-fit: cover;
  object-position: center center;
}

.slide-16 .slide-footer {
  padding-top: 6px;
  font-size: 0.92rem;
  line-height: 1.4;
}

@media (max-width: 920px) {
  .slide-6,
  .slide-16 {
    grid-template-columns: 1fr;
  }

  .slide-6 .competencies-bottom-list {
    grid-template-columns: 1fr;
  }
}

/* Page 6: user-approved reference sketch. Keep six items in the left half
   (three rows by two columns), and two items immediately beneath the collage. */
@media (min-width: 921px) {
  .slide-6 {
    grid-template-columns: 0.97fr 1.03fr;
    column-gap: 22px;
    align-items: start;
  }
  .slide-6 .text-panel { gap: 13px; }
  .slide-6 h1 { max-width: 100%; }
  .slide-6 .rich .principles-list-top {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(3, auto);
    grid-auto-flow: column;
    column-gap: 22px;
    row-gap: 12px;
    margin: 3px 0 0 21px;
    padding: 0;
  }
  .slide-6 .rich .principles-list-top li {
    font-size: 0.92rem;
    line-height: 1.48;
    margin: 0;
    padding-left: 0;
  }
  .slide-6 .image-panel { width: 100%; max-width: none; justify-self: stretch; }
  .slide-6 .image-frame { width: 100%; background: transparent; }
  .slide-6 .image-frame img { width: 100%; max-height: none; height: auto; object-fit: contain; }
  .slide-6 .img-caption { font-size: 0.84rem; line-height: 1.38; padding: 0 4px; }
  .slide-6 .slide-footer {
    display: block;
    grid-column: auto;
    width: 100%;
    margin: 11px 0 0;
    padding: 0 0 0 8px;
  }
  .slide-6 .competencies-bottom-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 21px;
    row-gap: 0;
    margin: 0 0 0 19px;
    padding: 0;
  }
  .slide-6 .competencies-bottom-list li {
    font-size: 0.92rem;
    line-height: 1.48;
    margin: 0;
  }
}
@media (max-width: 920px) {
  .slide-6 .rich .principles-list-top {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 20px;
    margin-left: 21px;
    padding: 0;
  }
  .slide-6 .slide-footer { grid-column: auto; }
  .slide-6 .competencies-bottom-list { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 590px) {
  .slide-6 .rich .principles-list-top,
  .slide-6 .competencies-bottom-list {grid-template-columns: 1fr;}
}
/* Match the reference's 3-line heading and row-major 2-column items. */
@media (min-width: 921px) {
  .slide-6 h1 { font-size: 2.06rem; line-height: 1.20; max-width: 500px; }
  .slide-6 .rich .principles-list-top { grid-auto-flow: row; }
}
@media (min-width: 921px) {
  .slide-6 { min-height: 578px; }
}
