/**
 * Version 5.0.19: fixed-left popup reader and text-visibility repair.
 *
 * Education and Career drawers now use the same desktop reading model as the
 * journal-paper drawer: the authentic image remains fixed at left while only
 * the complete record on the right scrolls.  This file also repairs pale/
 * invisible Education Record copy left behind by older cascade rules.
 */

/* Education Record: fixed image / independently scrollable copy. */
.had-detail-drawer.is-career-education-record .had-drawer-body{
  grid-template-columns:minmax(250px,320px) minmax(0,1fr)!important;
  gap:clamp(24px,3vw,42px)!important;
  align-items:stretch!important;
  overflow:hidden!important;
}
.had-detail-drawer.is-career-education-record .had-record-cover{
  position:sticky!important;
  top:0!important;
  align-self:start!important;
  width:100%!important;
  height:clamp(340px,52vh,430px)!important;
  margin:0!important;
  padding:12px!important;
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
  background:#f3f7f8!important;
  border:1px solid #b9d6dd!important;
  box-shadow:0 18px 38px rgba(0,31,48,.16)!important;
}
.had-detail-drawer.is-career-education-record .had-record-cover:before{display:none!important}
.had-detail-drawer.is-career-education-record .had-record-cover img{
  position:static!important;
  inset:auto!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  padding:0!important;
  object-fit:contain!important;
  object-position:center!important;
  background:#fff!important;
  filter:none!important;
  transform:none!important;
}
.had-detail-drawer.is-career-education-record .had-record-copy{
  min-width:0!important;
  min-height:0!important;
  max-height:100%!important;
  overflow-y:auto!important;
  overscroll-behavior:contain;
  padding-right:10px!important;
  scrollbar-width:thin;
  scrollbar-color:#13899a #dce8eb;
}
.had-detail-drawer.is-career-education-record .had-record-copy::-webkit-scrollbar{width:10px}
.had-detail-drawer.is-career-education-record .had-record-copy::-webkit-scrollbar-track{background:#dce8eb}
.had-detail-drawer.is-career-education-record .had-record-copy::-webkit-scrollbar-thumb{background:#13899a;border:2px solid #dce8eb;border-radius:999px}
.had-detail-drawer.is-career-education-record .had-record-copy>.had-lead{
  display:block!important;
  visibility:visible!important;
  opacity:1!important;
  margin:0 0 16px!important;
  color:#315864!important;
  -webkit-text-fill-color:#315864!important;
  font-size:12px!important;
  line-height:1.65!important;
}
.had-detail-drawer.is-career-education-record .had-rich-content{
  display:block!important;
  visibility:visible!important;
  opacity:1!important;
  max-height:none!important;
  overflow:visible!important;
  color:#405c68!important;
  -webkit-text-fill-color:#405c68!important;
  font-size:12px!important;
  line-height:1.65!important;
}
.had-detail-drawer.is-career-education-record .had-rich-content[hidden]{display:none!important}
.had-detail-drawer.is-career-education-record .had-rich-content p,
.had-detail-drawer.is-career-education-record .had-rich-content li,
.had-detail-drawer.is-career-education-record .had-pedagogy-course-summary{
  color:#405c68!important;
  -webkit-text-fill-color:#405c68!important;
  opacity:1!important;
}
.had-detail-drawer.is-career-education-record .had-rich-content h2,
.had-detail-drawer.is-career-education-record .had-rich-content h3{
  color:#154a5b!important;
  -webkit-text-fill-color:#154a5b!important;
  opacity:1!important;
}

/* Career Record: match the journal reader exactly on desktop. */
.had-detail-drawer.is-career-record .had-drawer-body{
  grid-template-columns:minmax(250px,320px) minmax(0,1fr)!important;
  gap:clamp(24px,3vw,42px)!important;
  align-items:stretch!important;
  overflow:hidden!important;
}
.had-detail-drawer.is-career-record .had-record-cover{
  position:sticky!important;
  top:0!important;
  align-self:start!important;
}
.had-detail-drawer.is-career-record .had-record-copy{
  min-width:0!important;
  min-height:0!important;
  max-height:100%!important;
  overflow-y:auto!important;
  overscroll-behavior:contain;
  padding-right:10px!important;
  scrollbar-width:thin;
  scrollbar-color:#13899a #dce8eb;
}
.had-detail-drawer.is-career-record .had-record-copy::-webkit-scrollbar{width:10px}
.had-detail-drawer.is-career-record .had-record-copy::-webkit-scrollbar-track{background:#dce8eb}
.had-detail-drawer.is-career-record .had-record-copy::-webkit-scrollbar-thumb{background:#13899a;border:2px solid #dce8eb;border-radius:999px}

/* Teaching popup images should always be fully contained and stay fixed while
   the long-form record, reactions and comments scroll on the right. */
.had-detail-drawer.is-teaching-portfolio-context .had-drawer-body{overflow:hidden!important}
.had-detail-drawer.is-teaching-portfolio-context .had-record-cover{position:sticky!important;top:0!important;align-self:start!important}
.had-detail-drawer.is-teaching-portfolio-context .had-record-copy{min-height:0!important;max-height:100%!important;overflow-y:auto!important}

@media(max-width:900px){
  .had-detail-drawer.is-career-education-record .had-drawer-body,
  .had-detail-drawer.is-career-record .had-drawer-body,
  .had-detail-drawer.is-teaching-portfolio-context .had-drawer-body{
    display:block!important;
    overflow:auto!important;
  }
  .had-detail-drawer.is-career-education-record .had-record-cover,
  .had-detail-drawer.is-career-record .had-record-cover,
  .had-detail-drawer.is-teaching-portfolio-context .had-record-cover{
    position:relative!important;
    top:auto!important;
    width:min(100%,420px)!important;
    margin:0 auto 22px!important;
  }
  .had-detail-drawer.is-career-education-record .had-record-copy,
  .had-detail-drawer.is-career-record .had-record-copy,
  .had-detail-drawer.is-teaching-portfolio-context .had-record-copy{
    max-height:none!important;
    overflow:visible!important;
    padding-right:0!important;
  }
}
