/* =========================================================
   BIBLIOTECA V2
   ========================================================= */

.hei-bib-shell{
  padding:0px;
}

/* ---------------------------------------------------------
   FILTROS
--------------------------------------------------------- */

.hei-bib-filters{
  display:grid;
  grid-template-columns: minmax(240px,1.5fr) repeat(2,180px) auto;
  gap:14px;
  align-items:end;
  margin-bottom:18px;
}

.hei-bib-filter{
  display:flex;
  flex-direction:column;
  gap:6px;
}

.hei-bib-filter label{
  font-size:12px;
  font-weight:600;
  color:#64748b;
}

.hei-bib-filter-actions{
  display:flex;
  gap:10px;
  align-items:end;
}

/* ---------------------------------------------------------
   GRID
--------------------------------------------------------- */

.hei-bib-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, 300px);
  gap:20px;
  justify-content:center;
}

/* ---------------------------------------------------------
   CARD
--------------------------------------------------------- */

.hei-bib-card{
  width:300px;
  border:1px solid #e5e7eb;
  border-radius:16px;
  background:#fff;
  overflow:hidden;
  transition:transform .15s ease, border-color .15s ease;
  box-shadow:0 2px 6px rgba(0,0,0,0.04);

  /* NOVO */
  display:flex;
  flex-direction:column;
  height:100%;
  min-height:480px;
}

.hei-bib-card:hover{
  transform:translateY(-2px);
  border-color:#d1d5db;
}

/* ---------------------------------------------------------
   MEDIA AREA
--------------------------------------------------------- */

.hei-bib-card-media{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:center;
}

/* Vídeo */

.hei-bib-card-media.is-video{
  min-height:120px;
  background:linear-gradient(
    135deg,
    color-mix(in srgb, var(--hei-brand-color) 8%, #fff) 0%,
    #f8fafc 100%
  );
}

.hei-bib-card-media img{
  width:100%;
  height:120px;
  object-fit:cover;
}

/* Documento */

.hei-bib-card-media.is-file{
  min-height:auto;
  padding:12px 14px;
  background:#f8fafc;
  border-bottom:1px solid #eef2f7;
  justify-content:flex-start;
}

.hei-bib-file-placeholder{
  display:flex;
  align-items:center;
  gap:10px;
}

/* ---------------------------------------------------------
   ICONES
--------------------------------------------------------- */

.hei-bib-icon-wrap{
  width:42px;
  height:42px;
  border-radius:10px;
  display:flex;
  align-items:center;
  justify-content:center;

  background:color-mix(in srgb, var(--hei-brand-color) 12%, #fff);
  color:var(--hei-brand-color);

  box-shadow:inset 0 0 0 1px
    color-mix(in srgb, var(--hei-brand-color) 18%, #fff);
}

.hei-bib-icon-wrap svg{
  width:22px;
  height:22px;
}

/* ---------------------------------------------------------
   PLAY OVERLAY (VÍDEO)
--------------------------------------------------------- */

.hei-bib-play-overlay{
  width:58px;
  height:58px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;

  background:rgba(255,255,255,.9);
  color:var(--hei-brand-color);

  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%, -50%);

  box-shadow:0 6px 14px rgba(15,23,42,.12);
}

.hei-bib-play-overlay svg{
  width:26px;
  height:26px;
}

/* ---------------------------------------------------------
   HEADER DOCUMENTO
--------------------------------------------------------- */

.hei-bib-file-meta{
  display:flex;
  flex-direction:column;
  gap:2px;
}

.hei-bib-file-label{
  font-size:11px;
  font-weight:700;
  color:#475569;
  text-transform:uppercase;
  letter-spacing:.05em;
}

/* ---------------------------------------------------------
   BODY
--------------------------------------------------------- */

.hei-bib-card-body{
  padding:14px 14px 16px;
  display:flex;
  flex-direction:column;
  flex:1;

  /* NOVO */
  display:flex;
  flex-direction:column;
  flex:1;
}

/* ---------------------------------------------------------
   BADGES
--------------------------------------------------------- */

.hei-bib-badges{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  margin-bottom:6px;
}

.hei-bib-badge{
  display:inline-flex;
  align-items:center;
  padding:4px 8px;
  border-radius:6px;
  font-size:11px;
  font-weight:600;
  background:#f1f5f9;
  color:#475569;
}

.hei-bib-badge--categoria{
  background:#eef2f7;
  color:#334155;
}

.hei-bib-badge--tipo{
  background:#f1f5f9;
  color:#475569;
}

/* --------------------------------------------------------- 
   TITULO
--------------------------------------------------------- */

.hei-bib-card-title{
  margin:4px 0 6px;
  font-size:16px;
  font-weight:600;
  line-height:1.35;
  color:#0f172a;

  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  min-height:44px;
}

/* ---------------------------------------------------------
   DESCRIÇÃO
--------------------------------------------------------- */

.hei-bib-card-desc{
  margin:0;
  color:#64748b;
  font-size:13px;
  line-height:1.5;

  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  min-height:40px;
  max-height:40px;
}
/* ---------------------------------------------------------
   FOOTER
--------------------------------------------------------- */

.hei-bib-card-footer{
  margin-top:auto;
  padding-top:14px;
}

.hei-bib-card-footer .hei-btn{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
}   

/* ---------------------------------------------------------
   RESPONSIVO
--------------------------------------------------------- */

@media (max-width:900px){

  .hei-bib-grid{
    grid-template-columns:repeat(auto-fill, 260px);
  }

  .hei-bib-card{
    width:260px;
  }

}

@media (max-width:640px){

  .hei-bib-filters{
    grid-template-columns:1fr;
  }

}


/* =========================================================
   VIDEO MODAL
========================================================= */

.hei-bib-video-modal{
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 999999;
  background: rgba(15, 23, 42, 0.72);
  display: none;
  align-items: center;
  justify-content: center;
}

.hei-bib-video-modal.is-open{
  display: flex;
}

.hei-bib-video-modal.active{
  display:flex;
}

.hei-bib-video-modal-inner{
  width:90%;
  max-width:900px;
  position:relative;
}

.hei-bib-video-frame{
  position:relative;
  padding-top:56.25%;
  background:#000;
  border-radius:10px;
  overflow:hidden;
}

.hei-bib-video-frame iframe{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
}

.hei-bib-video-close{
  position:absolute;
  top:-40px;
  right:0;
  background:none;
  border:none;
  color:#fff;
  font-size:28px;
  cursor:pointer;
}

/* =========================================================
   BIBLIOTECA ADM MASTER
   ========================================================= */

.hei-bib-admin-wrap{
  display:grid;
  gap:20px;
  margin-top:16px;
}

.hei-bib-admin-form-card,
.hei-bib-admin-list-card{
  border:1px solid #e5e7eb;
  border-radius:16px;
  background:#fff;
  padding:18px;
}

.hei-bib-admin-form .hei-field--full{
  grid-column:1 / -1;
}

.hei-bib-admin-form textarea.hei-input{
  min-height:110px;
  resize:vertical;
}

.hei-btn-sm{
  padding:6px 10px;
  font-size:12px;
  border-radius:8px;
}




.hei-bib-admin-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

.hei-inline{
  display:inline-flex;
}




.hei-bib-field-quiz{
  display:none;
}


/* =========================================================
   BIBLIOTECA - ABAS
   ========================================================= */

.hei-bib-tabs-wrap{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:16px;
  flex-wrap:wrap;
  margin:0 0 20px;
  padding:0 0 12px;
  border-bottom:1px solid #e5e7eb;
}

.hei-bib-tabs-left,
.hei-bib-tabs-right{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.hei-bib-tabs-right{
  padding:6px;
  border:1px solid #e5e7eb;
  border-radius:999px;
  background:#f8fafc;
}

.hei-bib-tablink{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:38px;
  padding:0 16px;
  border-radius:999px;
  border:1px solid transparent;
  background:transparent;
  color:#64748b;
  text-decoration:none;
  font-size:13px;
  font-weight:600;
  line-height:1;
  white-space:nowrap;
  transition:
    background .15s ease,
    color .15s ease,
    border-color .15s ease,
    box-shadow .15s ease,
    transform .08s ease;
}

.hei-bib-tablink:hover{
  background:#eef2f7;
  color:#0f172a;
}

.hei-bib-tabs-left .hei-bib-tablink{
  background:#f8fafc;
  border-color:#e5e7eb;
  color:#0f172a;
}

.hei-bib-tablink.is-active{
  background:#878787;
  color:#ffffff;
  border-color:#5a5a5a;
}

.hei-bib-tabs-left .hei-bib-tablink.is-active{
  transform:translateY(-1px);
}

@media (max-width: 768px){
  .hei-bib-tabs-wrap{
    align-items:flex-start;
  }

  .hei-bib-tabs-right{
    width:100%;
  }
}

/* =========================================================
   STATUS DOS CARDS
   ========================================================= */

.hei-bib-status{
  margin:6px 0 8px;
}

.hei-bib-status-ok{
  display:inline-flex;
  align-items:center;
  padding:4px 8px;
  border-radius:6px;
  font-size:11px;
  font-weight:700;
  background:#ecfdf5;
  color:#047857;
}

.hei-bib-status-pending{
  display:inline-flex;
  align-items:center;
  padding:4px 8px;
  border-radius:6px;
  font-size:11px;
  font-weight:600;
  background:#f1f5f9;
  color:#475569;
}

/* Card concluído mais suave */
.hei-bib-card.is-concluido{
  background:#f8fafc;
  border-color:#e2e8f0;
}

/* leve efeito ao passar mouse */
.hei-bib-card.is-concluido:hover{
  border-color:#cbd5f5;
}

/* =========================================================
   BIBLIOTECA - DASHBOARD PREMIUM
   LOOK & FEEL ALINHADO AO MAPEAMENTO
   ========================================================= */

.hei-bib-dashboard-wrap{
  display:flex;
  flex-direction:column;
  gap:24px;
  margin-top:10px;
}

/* ---------------------------------------------------------
   TOPO / INSIGHT
--------------------------------------------------------- */

.hei-bib-resumo-topo{
  margin:0;
}

.hei-bib-dashboard-wrap .hei-alert.hei-ok{
  margin:0;
  padding:18px 20px;
  border:1px solid #e6edf5;
  border-radius:18px;
  background:linear-gradient(135deg, #f8fafc 0%, #eef6ff 100%);
  color:#0f172a;
  box-shadow:0 8px 20px rgba(15, 23, 42, 0.04);
}

.hei-bib-dashboard-wrap .hei-alert.hei-ok strong{
  font-weight:800;
  color:#0f172a;
}

/* ---------------------------------------------------------
   SEÇÕES
--------------------------------------------------------- */

.hei-bib-dashboard-section{
  margin:0;
}

.hei-bib-dashboard-section-head{
  margin-bottom:16px;
}

.hei-bib-dashboard-section-title{
  margin:0 0 6px;
  font-size:20px;
  line-height:1.2;
  font-weight:800;
  color:#0f172a;
  letter-spacing:-0.02em;
}

.hei-bib-dashboard-section-sub{
  margin:0;
  font-size:14px;
  line-height:1.6;
  color:#64748b;
}

.hei-bib-dashboard-wrap .hei-hr{
  margin:0;
  border:0;
  border-top:1px solid #e5e7eb;
}

/* ---------------------------------------------------------
   GRID KPI
--------------------------------------------------------- */

.hei-bib-kpi-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(220px, 1fr));
  gap:18px;
}

.hei-bib-kpi-grid--compact{
  grid-template-columns:repeat(auto-fit, minmax(220px, 1fr));
}

/* ---------------------------------------------------------
   CARD KPI
--------------------------------------------------------- */

.hei-bib-kpi-card{
  position:relative;
  overflow:hidden;
  border:1px solid #e5e7eb;
  border-radius:20px;
  background:#ffffff;
  padding:22px;
  box-shadow:0 8px 24px rgba(15, 23, 42, 0.05);
  transition:
    transform .16s ease,
    box-shadow .16s ease,
    border-color .16s ease;
}

.hei-bib-kpi-card::after{
  content:"";
  position:absolute;
  inset:auto -30px -30px auto;
  width:100px;
  height:100px;
  border-radius:999px;
  background:rgba(148, 163, 184, 0.08);
}

.hei-bib-kpi-card:hover{
  transform:translateY(-2px);
  border-color:#d9e2ec;
  box-shadow:0 12px 28px rgba(15, 23, 42, 0.08);
}

.hei-bib-kpi-head{
  position:relative;
  z-index:1;
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}

.hei-bib-kpi-label{
  font-size:13px;
  font-weight:700;
  line-height:1.35;
  color:#0f172a;
  letter-spacing:-0.01em;
}

.hei-bib-kpi-value{
  position:relative;
  z-index:1;
  font-size:36px;
  font-weight:800;
  line-height:1;
  color:#0f172a;
  margin-bottom:10px;
  letter-spacing:-0.03em;
}

.hei-bib-kpi-sub{
  position:relative;
  z-index:1;
  font-size:12px;
  line-height:1.5;
  color:#64748b;
}

/* ---------------------------------------------------------
   TOOLTIP INFO
--------------------------------------------------------- */

.hei-bib-kpi-help{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  cursor:help;
}

.hei-bib-kpi-help-icon{
  width:18px;
  height:18px;
  border-radius:999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:#f3f6fa;
  color:#5b6b7f;
  font-size:11px;
  font-weight:700;
  line-height:1;
  border:1px solid #dde5ee;
  transition:
    background .15s ease,
    color .15s ease,
    border-color .15s ease,
    transform .12s ease;
}

.hei-bib-kpi-help:hover .hei-bib-kpi-help-icon,
.hei-bib-kpi-help:focus-within .hei-bib-kpi-help-icon{
  background:#eaf0f6;
  color:#334155;
  border-color:#cfd9e4;
  transform:translateY(-1px);
}

.hei-bib-kpi-help-tooltip{
  position:absolute;
  right:0;
  bottom:calc(100% + 10px);
  width:260px;
  padding:11px 12px;
  border-radius:12px;
  background:#0f172a;
  color:#ffffff;
  font-size:12px;
  line-height:1.45;
  box-shadow:0 14px 34px rgba(15,23,42,.20);
  opacity:0;
  visibility:hidden;
  transform:translateY(4px);
  transition:
    opacity .16s ease,
    transform .16s ease,
    visibility .16s ease;
  z-index:40;
  pointer-events:none;
}

.hei-bib-kpi-help:hover .hei-bib-kpi-help-tooltip,
.hei-bib-kpi-help:focus-within .hei-bib-kpi-help-tooltip{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}

/* ---------------------------------------------------------
   CATEGORIAS / CONTEXTO DO ACERVO
--------------------------------------------------------- */

.hei-bib-cat-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(220px, 1fr));
  gap:16px;
}

.hei-bib-cat-card{
  position:relative;
  overflow:hidden;
  border:1px solid #e5e7eb;
  border-radius:18px;
  background:#ffffff;
  padding:18px;
  box-shadow:0 6px 18px rgba(15, 23, 42, 0.04);
  transition:
    transform .14s ease,
    box-shadow .14s ease,
    border-color .14s ease;
}

.hei-bib-cat-card:hover{
  transform:translateY(-2px);
  border-color:#d9e2ec;
  box-shadow:0 10px 24px rgba(15, 23, 42, 0.06);
}

.hei-bib-cat-name{
  font-size:13px;
  font-weight:700;
  color:#0f172a;
  margin-bottom:10px;
  line-height:1.4;
}

.hei-bib-cat-total{
  font-size:32px;
  font-weight:800;
  line-height:1;
  color:#0f172a;
  letter-spacing:-0.03em;
}

/* ---------------------------------------------------------
   TABELA - TOP USUÁRIOS / TABELAS DE APOIO
--------------------------------------------------------- */

.hei-bib-dashboard-wrap .hei-table-wrap{
  overflow:auto;
  border:1px solid #eef2f7;
  border-radius:16px;
  background:#fff;
  box-shadow:0 6px 18px rgba(15, 23, 42, 0.04);
}

.hei-bib-dashboard-wrap .hei-table{
  width:100%;
  border-collapse:collapse;
  background:#fff;
}

.hei-bib-dashboard-wrap .hei-table thead th{
  padding:12px 14px;
  text-align:left;
  font-size:12px;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.04em;
  color:#64748b;
  border-bottom:1px solid #e5e7eb;
  background:#f8fafc;
}

.hei-bib-dashboard-wrap .hei-table tbody td{
  padding:13px 14px;
  border-bottom:1px solid #f1f5f9;
  color:#334155;
  font-size:14px;
}

.hei-bib-dashboard-wrap .hei-table tbody tr:last-child td{
  border-bottom:none;
}

.hei-bib-dashboard-wrap .hei-table tbody tr:hover{
  background:#fbfdff;
}

/* ---------------------------------------------------------
   BLOCOS DEMOGRÁFICOS
--------------------------------------------------------- */

.hei-bib-dashboard-wrap .hei-bib-kpi-grid--compact .hei-bib-kpi-card{
  min-height:148px;
}

.hei-bib-dashboard-wrap .hei-bib-kpi-grid--compact .hei-bib-kpi-value{
  font-size:34px;
}

.hei-bib-dashboard-wrap .hei-bib-kpi-card strong{
  color:#0f172a;
  font-weight:700;
}

/* =========================================================
   GRAFICOS DASHBOARD
   ========================================================= */

.hei-bib-charts-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:20px;
}

.hei-bib-chart-card{
  background:#ffffff;
  border:1px solid #e5e7eb;
  border-radius:20px;
  padding:22px;
  box-shadow:0 8px 24px rgba(15, 23, 42, 0.05);
  text-align:left;
}

.hei-bib-chart-card h5{
  margin:0 0 6px;
  font-size:18px;
  font-weight:800;
  color:#0f172a;
  letter-spacing:-0.01em;
}

.hei-bib-chart-card canvas{
  margin:18px auto 0;
}

/* =========================================================
   COMPORTAMENTO DE ACESSO
   ========================================================= */

.hei-bib-temporal-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:20px;
  align-items:stretch;
}

.hei-bib-temporal-grid .hei-bib-chart-card--wide{
  grid-column:1 / -1;
}

.hei-bib-chart-card--wide canvas{
  height:280px !important;
  max-height:280px !important;
  width:100% !important;
}

.hei-bib-chart-card--mini canvas{
  height:220px !important;
  max-height:220px !important;
  width:100% !important;
}

.hei-bib-legend-mini{
  margin-top:12px;
  font-size:12px;
  color:#64748b;
  line-height:1.55;
}

.hei-bib-legend-mini div{
  margin-top:4px;
}

/* RESPONSIVO */
@media (max-width:1100px){
  .hei-bib-temporal-grid{
    grid-template-columns:1fr;
  }

  .hei-bib-temporal-grid .hei-bib-chart-card--wide{
    grid-column:auto;
  }
}

@media (max-width:768px){
  .hei-bib-charts-grid{
    grid-template-columns:1fr;
  }
}

/* ---------------------------------------------------------
   RESPONSIVO
--------------------------------------------------------- */

@media (max-width: 900px){
  .hei-bib-kpi-grid,
  .hei-bib-kpi-grid--compact,
  .hei-bib-cat-grid{
    grid-template-columns:repeat(auto-fit, minmax(200px, 1fr));
  }

  .hei-bib-kpi-value,
  .hei-bib-cat-total{
    font-size:30px;
  }

  .hei-bib-charts-grid{
    grid-template-columns:1fr;
  }
}

@media (max-width: 640px){
  .hei-bib-dashboard-section{
    margin:0;
  }

  .hei-bib-kpi-card,
  .hei-bib-cat-card,
  .hei-bib-chart-card{
    padding:18px 16px;
    border-radius:18px;
  }

  .hei-bib-kpi-value,
  .hei-bib-cat-total{
    font-size:28px;
  }

  .hei-bib-kpi-help-tooltip{
    right:auto;
    left:0;
    width:220px;
  }

  .hei-bib-dashboard-wrap .hei-table thead th,
  .hei-bib-dashboard-wrap .hei-table tbody td{
    padding:10px 10px;
    font-size:12px;
  }
}

@media (max-width: 768px){
  .hei-bib-charts-grid{
    grid-template-columns:1fr;
  }
}

/* =========================================================
   BIBLIOTECA - SEÇÕES
   ========================================================= */

.hei-bib-section{
  margin-top:28px;
}

.hei-bib-section-head{
  margin-bottom:14px;
}

.hei-bib-section-title{
  margin:0 0 4px;
  font-size:20px;
  font-weight:800;
  color:#0f172a;
}

.hei-bib-section-sub{
  margin:0;
  font-size:14px;
  color:#64748b;
  line-height:1.5;
}

/* =========================================================
   DOCUMENTOS - LISTA
   ========================================================= */

.hei-bib-doc-list{
  display:flex;
  flex-direction:column;
  gap:14px;
}

.hei-bib-doc-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding:18px 20px;
  border:1px solid #e5e7eb;
  border-radius:18px;
  background:#ffffff;
  box-shadow:0 6px 18px rgba(15, 23, 42, 0.04);
}

.hei-bib-doc-main{
  display:flex;
  align-items:flex-start;
  gap:14px;
  min-width:0;
  flex:1 1 auto;
}

.hei-bib-doc-icon{
  width:42px;
  height:42px;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#f8fafc;
  border:1px solid #e2e8f0;
  color:#475569;
  flex:0 0 auto;
}

.hei-bib-doc-icon svg{
  width:22px;
  height:22px;
}

.hei-bib-doc-content{
  min-width:0;
  flex:1 1 auto;
}

.hei-bib-doc-title{
  font-size:17px;
  font-weight:700;
  color:#0f172a;
  line-height:1.35;
  margin-bottom:6px;
}

.hei-bib-doc-meta{
  display:flex;
  flex-wrap:wrap;
  gap:10px 14px;
  font-size:13px;
  color:#64748b;
  line-height:1.5;
}

.hei-bib-doc-side{
  display:flex;
  align-items:center;
  gap:12px;
  flex:0 0 auto;
}

.hei-bib-doc-status{
  display:inline-flex;
  align-items:center;
  padding:5px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:700;
}

.hei-bib-doc-status.is-concluido{
  background:#ecfdf5;
  color:#047857;
}

.hei-bib-doc-status.is-pendente{
  background:#f1f5f9;
  color:#475569;
}

.hei-bib-doc-empty{
  font-size:12px;
  color:#94a3b8;
}

@media (max-width: 820px){
  .hei-bib-doc-row{
    flex-direction:column;
    align-items:flex-start;
  }

  .hei-bib-doc-side{
    width:100%;
    justify-content:space-between;
  }
}

.hei-bib-subtabs{
  background:#f1f5f9;
  border-radius:999px;
  padding:4px;
}

/* força esquerda */
.hei-bib-subtabs-left{
  justify-content:flex-start;
}

/* direita continua como está */
.hei-bib-tabs-right{
  margin-left:auto;
}



.hei-bib-quiz-modal-inner{
  width:min(760px, 94vw);
  max-height:90vh;
  overflow:auto;
  background:#fff;
  border-radius:24px;
  box-shadow:0 24px 80px rgba(15,23,42,.28);
  padding:0;
}

.hei-bib-quiz-shell{
  padding:28px 32px 32px;
}

.hei-bib-quiz-shell h3{
  font-size:22px;
  font-weight:800;
  margin-bottom:6px;
  color:#0f172a;
}

.hei-bib-quiz-shell .hei-sub{
  color:#64748b;
  border-bottom:1px solid #e5e7eb;
  padding-bottom:18px;
}

.hei-bib-quiz-question{
  padding:18px 0 6px;
}

.hei-bib-quiz-question h4{
  font-size:16px;
  font-weight:800;
  margin:0 0 14px;
  color:#1e293b;
}

.hei-bib-quiz-question label{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 14px;
  margin:8px 0;
  border:1px solid #e5e7eb;
  border-radius:14px;
  background:#f8fafc;
  cursor:pointer;
  transition:.18s ease;
}

.hei-bib-quiz-question label:hover{
  background:#eef6ff;
  border-color:#bfdbfe;
}

.hei-bib-quiz-question input[type="radio"]{
  width:18px;
  height:18px;
}

.hei-bib-quiz-form .hei-actions{
  border-top:1px solid #e5e7eb;
  padding-top:20px;
  display:flex;
  gap:10px;
}

.hei-bib-quiz-feedback-item{
  padding:12px 14px;
  border-radius:14px;
  margin-top:10px;
  font-weight:700;
}

.hei-bib-quiz-feedback-item.is-correct{
  background:#ecfdf5;
  color:#047857;
}

.hei-bib-quiz-feedback-item.is-wrong{
  background:#fef2f2;
  color:#b91c1c;
}

.hei-bib-quiz-close{
  top:16px;
  right:16px;
}


.hei-bib-badge--quiz-ok{
  background:#ecfdf5;
  color:#047857;
  border:1px solid #bbf7d0;
}

/* botão sempre embaixo */
.hei-bib-card-body .hei-bib-btn,
.hei-bib-card-body .button{
  margin-top:auto;
  width:100%;
  text-align:center;
}


/* compactar badges */
.hei-bib-badges{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  margin-bottom:6px;
}

/* título mais próximo */
.hei-bib-card-title{
  margin:2px 0 4px;
}

/* status mais compacto */
.hei-bib-status{
  margin:4px 0 6px;
}

/* descrição mais colada */
.hei-bib-card-desc{
  margin:0 0 6px;
}