/* uni-cnb-like-v2 — portada desde .cap-banner del corpus */
.libro-container[data-v-addc1c37],
.container.libro-container{
  max-width:min(1520px,100%)!important;
  margin:0 auto!important;
  padding:1rem 1.25rem 2.5rem!important;
}
.workspace-inner[data-v-addc1c37]{
  display:flex!important;
  flex-direction:row!important;
  align-items:flex-start!important;
  gap:clamp(.85rem,2vw,1.35rem)!important;
  width:100%!important;
}
.reader-sidebar[data-v-addc1c37]{
  flex:0 0 clamp(280px,26vw,340px)!important;
  max-width:340px!important;
  display:flex;
  flex-direction:column!important;
  max-height:calc(100vh - 5.5rem)!important;
  position:sticky!important;
  top:4.75rem!important;
  overflow:hidden!important;
  background:#fff!important;
  border:1px solid #e5e7eb!important;
  border-radius:16px!important;
  box-shadow:0 10px 28px rgba(15,23,42,.06)!important;
}
.sidebar-uni-logo[data-v-addc1c37]{
  width:40px!important;height:40px!important;object-fit:contain!important;
  border-radius:8px!important;background:#f8fafc!important;border:1px solid #e5e7eb!important;padding:2px!important;
}
.chapter-nav-scroll[data-v-addc1c37]{
  display:flex!important;flex-direction:column!important;gap:.4rem!important;
  padding:0 .85rem 1rem!important;max-height:52vh!important;overflow:auto!important;
}
.chapter-item[data-v-addc1c37]{
  display:flex!important;gap:.65rem!important;align-items:flex-start!important;width:100%!important;
  text-align:left!important;white-space:normal!important;padding:.6rem .7rem!important;
  border-radius:12px!important;border:1px solid #e5e7eb!important;background:#fff!important;
}
.chapter-item.active[data-v-addc1c37]{
  border-color:#2b9ba6!important;background:rgba(43,155,166,.08)!important;
}
.reader-main[data-v-addc1c37],main.reader-main{
  flex:1 1 auto!important;min-width:0!important;background:#fff!important;
  border:1px solid #e5e7eb!important;border-radius:16px!important;
  box-shadow:0 10px 28px rgba(15,23,42,.05)!important;overflow:hidden!important;
}
.chapter-body-html{
  --cnb-p:#1a5276;--cnb-s:#2980b9;--cnb-border:#dce4ec;
  padding:1rem 1.15rem 2rem!important;line-height:1.75!important;color:#2c3e50!important;
  max-width:none!important;width:100%!important;margin:0!important;
  font-size:1.14rem!important;box-sizing:border-box!important;
}
.chapter-body-html .wrap,
.chapter-body-html .content,
.chapter-body-html .content-body,
.chapter-body-html .content-main{
  max-width:none!important;width:100%!important;margin:0!important;
  padding:.2rem 0 1.25rem!important;box-sizing:border-box!important;
}
.chapter-body-html h2{
  color:var(--cnb-p)!important;font-size:1.4rem!important;margin:1.6rem 0 .85rem!important;
  padding-bottom:.4rem!important;border-bottom:2px solid var(--cnb-border)!important;
}
.chapter-body-html h3{color:var(--cnb-s)!important;font-size:1.12rem!important;margin:1.2rem 0 .55rem!important}
.chapter-body-html .lesson-label{
  display:inline-block!important;font-size:.78rem!important;font-weight:800!important;
  letter-spacing:.04em!important;text-transform:uppercase!important;color:#0f766e!important;
  background:#ecfdf5!important;border:1px solid #a7f3d0!important;border-radius:999px!important;
  padding:.2rem .65rem!important;margin:1rem 0 .35rem!important;
}
.chapter-body-html .lesson{
  background:#fff!important;border:1px solid #eef2f7!important;border-radius:14px!important;
  padding:.85rem 1rem 1rem!important;margin:.85rem 0 1.1rem!important;
}

/* Portada CNB-like: usar el banner del corpus (no ocultarlo) */
.chapter-body-html .cap-banner,
.reader-main header.cap-banner,
.uni-portada{
  display:block!important;
  margin:0 0 1.35rem!important;border-radius:18px!important;overflow:hidden!important;color:#fff!important;
  background:radial-gradient(circle at top right,rgba(78,205,196,.35),transparent 42%),
    linear-gradient(135deg,#0f766e 0%,#1a5f7a 48%,#f59e0b 140%)!important;
  box-shadow:0 12px 28px rgba(15,23,42,.12)!important;
  padding:1.35rem 1.4rem 1.2rem!important;border:0!important;
}
.chapter-body-html .cap-tag,
.uni-portada-kicker{
  display:inline-block!important;margin:0 0 .55rem!important;font-size:.78rem!important;font-weight:800!important;
  letter-spacing:.06em!important;text-transform:uppercase!important;color:#fff!important;
  background:rgba(255,255,255,.22)!important;border:1px solid rgba(255,255,255,.35)!important;
  border-radius:999px!important;padding:.28rem .75rem!important;
}
.chapter-body-html .cap-tema,
.uni-portada-title{
  display:block!important;margin:0 0 .45rem!important;font-size:clamp(1.35rem,2.4vw,1.85rem)!important;
  line-height:1.2!important;font-weight:800!important;color:#fff!important;border:0!important;padding:0!important;
}
.chapter-body-html .cap-sub,
.uni-portada-book,.uni-portada-meta{
  display:block!important;margin:0 0 .25rem!important;opacity:.95!important;font-size:.95rem!important;color:#fff!important;
}
.uni-portada-inner{padding:0!important}
.uni-portada-pills{display:flex!important;flex-wrap:wrap!important;gap:.4rem!important;margin-top:.9rem!important}
.uni-portada-pills span{
  display:inline-block!important;background:rgba(255,255,255,.18)!important;
  border:1px solid rgba(255,255,255,.28)!important;border-radius:999px!important;
  padding:.22rem .7rem!important;font-size:.75rem!important;font-weight:700!important;
}

/* Solo chrome duplicado del shell Vue — no el banner del capítulo */
.reader-main .chapter-header,
.reader-main .chapter-kicker,
.reader-main .chapter-title,
.chapter-body-html .book-header,
.chapter-body-html .unit-eyebrow{display:none!important}

.open-book-shell,.open-book-shell .book-spread,.open-book-shell .page-margin-frame{
  background:transparent!important;box-shadow:none!important;border:0!important;
  max-width:none!important;padding:0!important;margin:0!important;
}

/* Toolbar tipografía + paginación (faltaba CSS de culturaChapterBody en uni) */
.uni-libro-page .reader-toolbar,
.open-book-shell .reader-toolbar{
  display:flex!important;align-items:center!important;justify-content:space-between!important;
  gap:.65rem!important;padding:.45rem .7rem!important;margin:0 0 .85rem!important;
  background:#fff!important;border:1px solid #e5e7eb!important;border-radius:999px!important;
  box-shadow:0 4px 14px rgba(15,23,42,.05)!important;
}
.uni-libro-page .toolbar-left,
.uni-libro-page .toolbar-right,
.open-book-shell .toolbar-left,
.open-book-shell .toolbar-right{
  display:flex!important;align-items:center!important;gap:.2rem!important;flex-shrink:0!important;
}
.uni-libro-page .toolbar-center,
.open-book-shell .toolbar-center{
  flex:1 1 auto!important;min-width:0!important;text-align:center!important;
}
.uni-libro-page .toolbar-chapter-label,
.open-book-shell .toolbar-chapter-label{
  display:block!important;font-size:.8rem!important;font-weight:700!important;
  color:#64748b!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
.uni-libro-page .toolbar-btn,
.open-book-shell .toolbar-btn{
  width:2.2rem!important;height:2.2rem!important;min-width:2.2rem!important;
  border-radius:50%!important;display:inline-grid!important;place-items:center!important;
  background:transparent!important;color:#64748b!important;border:0!important;
  cursor:pointer!important;padding:0!important;line-height:1!important;
}
.uni-libro-page .toolbar-btn:hover,
.open-book-shell .toolbar-btn:hover{
  background:rgba(43,155,166,.12)!important;color:#0f766e!important;
}
.uni-libro-page .toolbar-btn.active,
.open-book-shell .toolbar-btn.active{
  background:rgba(43,155,166,.2)!important;color:#0f766e!important;
}
.uni-libro-page .font-btn,
.open-book-shell .font-btn{
  font-weight:800!important;font-size:.8rem!important;line-height:1!important;
}
.uni-libro-page .font-btn--lg,
.open-book-shell .font-btn--lg{font-size:.95rem!important}
.uni-libro-page .toolbar-transition,
.open-book-shell .toolbar-transition{
  display:inline-flex!important;align-items:center!important;gap:.1rem!important;
  margin-left:.2rem!important;padding-left:.4rem!important;border-left:1px solid #e5e7eb!important;
}

.uni-libro-page .reader-nav,
.open-book-shell .reader-nav{
  display:flex!important;align-items:center!important;gap:1rem!important;
  margin-top:1.1rem!important;padding:.75rem .15rem!important;
}
.uni-libro-page .nav-btn,
.open-book-shell .nav-btn{
  display:inline-flex!important;align-items:center!important;gap:.4rem!important;
  padding:.55rem 1rem!important;border-radius:999px!important;font-weight:700!important;
  font-size:.82rem!important;flex-shrink:0!important;border:1px solid #e5e7eb!important;
  background:#fff!important;color:#334155!important;cursor:pointer!important;
}
.uni-libro-page .nav-btn:hover:not(:disabled),
.open-book-shell .nav-btn:hover:not(:disabled){
  border-color:#2b9ba6!important;color:#0f766e!important;
}
.uni-libro-page .nav-btn:disabled,
.open-book-shell .nav-btn:disabled{opacity:.35!important;cursor:not-allowed!important}
.uni-libro-page .nav-btn--next,
.open-book-shell .nav-btn--next{
  background:#2b9ba6!important;color:#fff!important;border-color:#2b9ba6!important;
}
.uni-libro-page .nav-btn--next:hover:not(:disabled),
.open-book-shell .nav-btn--next:hover:not(:disabled){
  background:#0f766e!important;border-color:#0f766e!important;color:#fff!important;
}
.uni-libro-page .nav-progress,
.open-book-shell .nav-progress{
  flex:1 1 auto!important;min-width:0!important;display:flex!important;
  flex-direction:column!important;align-items:center!important;gap:.35rem!important;
}
.uni-libro-page .progress-bar,
.open-book-shell .progress-bar{
  width:100%!important;height:4px!important;border-radius:999px!important;
  background:rgba(31,41,55,.1)!important;overflow:hidden!important;
}
.uni-libro-page .progress-fill,
.open-book-shell .progress-fill{
  height:100%!important;border-radius:inherit!important;
  background:linear-gradient(90deg,#2b9ba6,#f59e0b)!important;
}
.uni-libro-page .progress-label,
.open-book-shell .progress-label{
  font-size:.72rem!important;font-weight:700!important;color:#64748b!important;
}

@media (max-width:960px){
  .workspace-inner[data-v-addc1c37]{flex-direction:column!important}
  .reader-topbar[data-v-addc1c37]{
    position:sticky!important;top:64px!important;z-index:190!important;
    background:#f8fafc!important;padding:.35rem 0!important;
  }
  .reader-sidebar--drawer[data-v-addc1c37]{
    position:fixed!important;top:64px!important;left:0!important;bottom:0!important;
    z-index:180!important;width:min(92vw,340px)!important;max-width:92vw!important;
    flex:none!important;max-height:none!important;height:auto!important;
    border-radius:0 16px 16px 0!important;
  }
  .reader-sidebar--drawer .chapter-nav-scroll[data-v-addc1c37]{
    max-height:calc(100dvh - 16rem)!important;
  }
  .libro-container[data-v-addc1c37],
  .container.libro-container{
    padding:.35rem .2rem 1.25rem!important;
  }
  .reader-main[data-v-addc1c37],main.reader-main{
    width:100%!important;overflow:visible!important;
    border-radius:0!important;border-left:0!important;border-right:0!important;
    box-shadow:none!important;
  }
  .chapter-body-html{
    max-width:none!important;width:100%!important;
    padding:.55rem .35rem 1.75rem!important;
    font-size:1.22rem!important;line-height:1.7!important;
  }
  .chapter-body-html .wrap,
  .chapter-body-html .content,
  .chapter-body-html .content-body,
  .chapter-body-html .content-main{
    padding:0 0 1rem!important;
  }
  .chapter-body-html h2{font-size:1.55rem!important}
  .chapter-body-html .lesson{
    padding:.7rem .35rem .85rem!important;margin:.7rem 0!important;
  }
  .uni-libro-page .toolbar-center,
  .open-book-shell .toolbar-center{display:none!important}
}
@media (max-width:640px){
  .uni-libro-page .nav-btn span,
  .open-book-shell .nav-btn span{display:none!important}
  .uni-libro-page .reader-toolbar,
  .open-book-shell .reader-toolbar{border-radius:14px!important}
}

/* Badge de alineación al pensum USAC */
.sidebar-meta .pensum-badge,
.pensum-badge{
  margin-top:.55rem!important;display:inline-flex!important;align-items:center!important;
  font-size:.72rem!important;font-weight:800!important;letter-spacing:.02em!important;
  border-radius:999px!important;padding:.28rem .7rem!important;width:fit-content!important;
}
.pensum-badge--ok{
  background:rgba(16,185,129,.12)!important;color:#047857!important;border:1px solid #6ee7b7!important;
}
.pensum-badge--wip{
  background:rgba(245,158,11,.12)!important;color:#b45309!important;border:1px solid #fcd34d!important;
}
