/* Shared reader-figure frame. Case colors and source-specific diagrams remain
   in their cohort stylesheets; this layer only aligns the teaching chrome. */
:is(.emt-reader-visual, .emt-rv2, .emt-rv3, .tvc-reader-visual, .tv2, .tv3, .tv4) {
  --reader-figure-accent: #79ddc8;
  --reader-figure-muted: #bdd7d9;
  min-width: 0;
  margin: 1.15rem 0 .3rem;
  padding: clamp(.85rem, 2vw, 1.2rem);
  border: 1px solid #4e9d9f;
  border-radius: 16px;
  background: linear-gradient(150deg, #102e3b 0%, #103341 54%, #142c40 100%);
  color: #eefaf7;
  box-shadow: 0 10px 28px rgb(14 43 54 / .13), inset 0 1px rgb(255 255 255 / .07);
}

:is(.tvc-reader-visual, .tv2, .tv3, .tv4) {
  --reader-figure-accent: #9bdcef;
  border-color: #609eaf;
}

:is(.emt-reader-visual, .emt-rv2, .emt-rv3, .tvc-reader-visual, .tv2, .tv3, .tv4)::before {
  display: block;
  width: fit-content;
  margin-bottom: .66rem;
  padding: .23rem .55rem .23rem .68rem;
  border-left: 3px solid var(--reader-figure-accent);
  border-radius: 2px 6px 6px 2px;
  background: rgb(190 239 232 / .09);
  color: #cde7e4;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .09em;
  line-height: 1.3;
  text-transform: uppercase;
  content: "EMT / BLS · lesson visual";
}

:is(.tvc-reader-visual, .tv2, .tv3, .tv4)::before {
  content: "Nursing / Telemetry · lesson visual";
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > h4,
:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > figcaption h4,
.emt-reader-visual .emt-rv-header h4,
.tvc-reader-visual .tvc-head h4 {
  margin: 0 0 .35rem;
  color: #f5fffc;
  font-size: clamp(1.06rem, 2.4vw, 1.24rem);
  line-height: 1.28;
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > figcaption {
  display: grid;
  gap: .22rem;
  margin: 0 0 .75rem;
  padding: 0 0 .75rem;
  border-bottom: 1px solid rgb(181 226 225 / .22);
}

:is(.emt-rv2, .emt-rv3) > h4 {
  margin-bottom: .2rem;
}

:is(.emt-rv2, .emt-rv3) > figcaption :is(.emt-rv2-lead, .emt-rv3-lead),
:is(.tv2, .tv3) > figcaption :is(.tv2-job, .tv3-job),
.tv4 > figcaption .tv4-line.tv4-job {
  margin: 0;
  color: #e7f8f4;
  font-size: .84rem;
  font-weight: 650;
  line-height: 1.42;
}

:is(.emt-rv2, .emt-rv3) > figcaption :is(.emt-rv2-note, .emt-rv3-note),
:is(.tv2, .tv3) > figcaption :is(.tv2-note, .tv3-note),
.tv4 > figcaption .tv4-line.tv4-boundary {
  margin: 0;
  color: var(--reader-figure-muted);
  font-size: .82rem;
  line-height: 1.43;
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > :is(.emt-rv2-board, .emt-rv3-board, .tv2-board, .tv3-board, .tv4-board) {
  min-width: 0;
  margin-top: .7rem;
  padding: clamp(.62rem, 1.7vw, .9rem);
  border: 1px solid #bfd9d9;
  border-radius: 11px;
  background: #f1f7f7;
  color: #173b49;
}

:is(.emt-rv2-choice, .emt-rv3-choice, .tv2-choice, .tv3-choice, .tv4-choice, .emt-rv-control, .tvc-button) {
  min-height: 42px;
  max-width: 100%;
  border: 1px solid #83b6bf;
  border-radius: 8px;
  background: #173d4e;
  color: #effaf8;
  font-size: .8rem;
  font-weight: 710;
  line-height: 1.3;
  white-space: normal;
}

:is(.emt-rv2-choice, .emt-rv3-choice, .tv2-choice, .tv3-choice, .tv4-choice, .emt-rv-control, .tvc-button):hover {
  border-color: #f4d69a;
  background: #255464;
  color: #fff;
}

:is(.emt-rv2-choice, .emt-rv3-choice, .tv2-choice, .tv3-choice, .tv4-choice, .emt-rv-control, .tvc-button)[aria-pressed="true"] {
  border-color: #ffd48c;
  background: #26615f;
  color: #fff;
  box-shadow: inset 0 -3px #ffd48c;
}

:is(.emt-rv2-choice, .emt-rv3-choice, .tv2-choice, .tv3-choice, .tv4-choice, .emt-rv-control, .tvc-button):focus-visible {
  outline: 3px solid #ffe0a2;
  outline-offset: 2px;
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > :is(.emt-rv2-text-details, .emt-rv3-text-details, .tv2-details, .tv3-details, .tv4-details) {
  margin-top: .8rem;
  padding-top: .65rem;
  border-top: 1px solid rgb(181 226 225 / .22);
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > :is(.emt-rv2-text-details, .emt-rv3-text-details, .tv2-details, .tv3-details, .tv4-details) summary {
  color: #b8f0df;
  font-size: .8rem;
  font-weight: 720;
}

:is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > :is(.emt-rv2-text-details, .emt-rv3-text-details, .tv2-details, .tv3-details, .tv4-details) :is(.emt-rv2-equivalent, .emt-rv3-equivalent, .tv2-equivalent, .tv3-equivalent, .tv4-equivalent) {
  color: #d7ece9;
}

@media (max-width: 360px) {
  :is(.emt-reader-visual, .emt-rv2, .emt-rv3, .tvc-reader-visual, .tv2, .tv3, .tv4) {
    padding: .68rem;
    border-radius: 12px;
  }
  :is(.emt-rv2, .emt-rv3, .tv2, .tv3, .tv4) > :is(.emt-rv2-board, .emt-rv3-board, .tv2-board, .tv3-board, .tv4-board) {
    padding: .5rem;
  }
}
