.lic-section{
  padding:var(--pad-section-y) 0 var(--pad-band-t);
  background:linear-gradient(180deg, var(--cream-alt) 0%, #fff 30%);
}

.lic-header{
  margin-bottom:48px;
}

.lic-stats{
  display:flex;
  gap:32px;
  flex-wrap:wrap;
  margin-top:24px;
}

.lic-stat{
  display:flex;
  align-items:baseline;
  gap:8px;
}

.lic-stat-num{
  font-family:var(--slab);
  font-size:2.5rem;
  font-weight:400;
  color:var(--navy);
  line-height:1;
}

.lic-stat-label{
  font-size:13px;
  color:var(--muted);
  font-weight:500;
}
.lic-filters{
  margin-bottom:40px;
}
.lic-filters-toolbar-outer{
  width:100%;
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
  scrollbar-width:thin;
}

.lic-filters-toolbar.row{
  width:100%;
}

.lic-filters-toolbar--single-row .col.min-w-0{
  flex:1 1 0%;
  min-width:0;
}

/* Móvil (por debajo de md): columna completa, sin anchos fijos que comprimen la fila */
@media (max-width: 767.98px){
  .lic-filters-toolbar--single-row > [class*="col-"]{
    width:100%;
    max-width:100%;
  }
  .lic-search-wrap--toolbar,
  .lic-entidad-wrap--toolbar{
    width:100%;
    max-width:none;
  }
  .lic-filters-lic .lic-entidad-wrap--toolbar{
    max-width:none;
  }
  .lic-filters-toolbar--single-row{
    row-gap:0.75rem;
  }
}

.lic-search-wrap--toolbar{
  width:clamp(160px, 28vw, 260px);
  max-width:100%;
}

.lic-entidad-wrap--toolbar{
  width:clamp(180px, 32vw, 280px);
  max-width:100%;
}

/* Licenciaturas: select de entidad más angosto (solo ancho, no altura de tipografía) */
.lic-filters-lic .lic-entidad-wrap--toolbar{
  max-width:360px;
}

.lic-entidad-wrap{
  width:100%;
}

.lic-filters-lic .form-select{
  min-width:0;
  width:100%;
  max-width:100%;
  padding:12px 36px 12px 16px;
  border:1px solid #e0ddd8;
  border-radius:10px;
  font-size:15px;
  background:#fff;
  transition:border-color 0.2s, box-shadow 0.2s;
}

.lic-filters-lic .form-select:focus{
  outline:none;
  border-color:#4f7fd5;
  box-shadow:0 0 0 3px rgba(79, 127, 213, 0.14);
}

.lic-search-wrap{
  position:relative;
  min-width:0;
  max-width:320px;
}

.lic-search-wrap i{
  position:absolute;
  left:16px;
  top:50%;
  transform:translateY(-50%);
  color:var(--muted);
  font-size:14px;
}

.lic-search-wrap input{
  width:100%;
  padding:14px 16px 14px 50px;
  border:1px solid #e0ddd8;
  border-radius:12px;
  font-size:15px;
  background:#fff;
  transition:border-color 0.2s, box-shadow 0.2s;
}

.lic-search-inline{
  max-width:none;
}

.lic-search-wrap input:focus{
  outline:none;
  border-color:#4f7fd5;
  box-shadow:0 0 0 3px rgba(79, 127, 213, 0.14);
}
/* Chips de filtro: mismo lenguaje visual que pestañas en servicios al estudiante (.se-tabs / .se-tab) */
.lic-chips--se-style,
.lic-filters .lic-chips.lic-chips--se-style{
  display:flex;
  flex-wrap:nowrap;
  align-items:center;
  gap:0;
  padding:6px;
  margin:0;
  background:var(--off);
  border-radius:999px;
  box-shadow:0 2px 12px rgba(0, 24, 51, 0.06);
  width:100%;
  max-width:100%;
  min-width:0;
  overflow-x:auto;
  overflow-y:hidden;
  -webkit-overflow-scrolling:touch;
  scrollbar-width:thin;
}

.lic-chips--se-style .lic-chip{
  flex:0 0 auto;
}

/* Licenciaturas: sin scroll horizontal; chips envuelven en varias líneas dentro del contenedor */
.lic-filters-lic .lic-filters-toolbar-outer{
  overflow:visible;
}

.lic-filters-lic .lic-chips--se-style{
  flex-wrap:wrap;
  overflow:visible;
  row-gap:4px;
  column-gap:0;
  border-radius:16px;
  justify-content:flex-start;
}

.lic-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  padding:12px 20px;
  margin:0;
  border:none;
  border-radius:999px;
  font-size:13px;
  font-weight:600;
  font-family:var(--sans);
  color:var(--text);
  background:transparent;
  cursor:pointer;
  transition:color 0.2s, background 0.2s, box-shadow 0.2s;
  white-space:nowrap;
  user-select:none;
}

.lic-chip:hover{
  color:var(--blue);
  background:rgba(255, 255, 255, 0.7);
}

.lic-chip.active{
  color:#fff;
  background:var(--blue);
  box-shadow:0 2px 10px rgba(0, 55, 110, 0.25);
}

.lic-chip.active .lic-chip-count{
  opacity:0.92;
  color:rgba(255, 255, 255, 0.95);
}

.lic-chip-count{
  opacity:0.8;
  font-weight:500;
  font-size:0.92em;
  margin-left:2px;
}
.lic-bento{
  display:grid;
  grid-template-columns:repeat(5, minmax(0, 1fr));
  gap:20px;
  grid-auto-rows:360px;
}

.lic-card{
  grid-row:span 1;
  position:relative;
  border-radius:16px;
  overflow:hidden;
  background:var(--navy);
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  padding:20px 20px 22px;
  text-decoration:none;
  color:#fff;
  cursor:pointer;
  box-shadow:0 10px 24px rgba(0, 24, 51, 0.08);
  transition:transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.35s;
}

.posgrado-card{
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
}

.lic-card::before{
  content:'';
  position:absolute;
  inset:0;
  background:linear-gradient(180deg, rgba(0, 0, 0, 0.05) 0%, rgba(0, 24, 51, 0.65) 55%, rgba(0, 24, 51, 0.95) 100%);
  z-index:0;
}

.lic-card:hover{
  transform:translateY(-6px) scale(1.02);
  box-shadow:0 24px 48px rgba(0, 24, 51, 0.18);
}
.lic-card.lic-card--wide{
  grid-column:span 1;
}

.lic-card.lic-card--tall{
  grid-row:span 1;
}

.lic-card-bg{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  transition:transform 0.6s, opacity 0.3s;
}

.lic-card:hover .lic-card-bg{
  transform:scale(1.08);
  opacity:0.5;
}

.lic-card-modalidad-badge{
  position:absolute;
  top:16px;
  right:16px;
  padding:6px 12px;
  border-radius:100px;
  font-size:10px;
  font-weight:700;
  letter-spacing:0.08em;
  text-transform:uppercase;
  z-index:1;
  color:#fff;
}

.lic-badge-abierta{
  background:var(--gold);
  color:#fff;
}

.lic-badge-distancia{
  background:var(--blue2);
  color:#fff;
}

.lic-badge-gradiente{
  background:linear-gradient(90deg, var(--gold) 0%, var(--blue2) 100%);
  color:#fff;
}

.lic-card-body{
  position:relative;
  z-index:1;
  height:52%;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
}

.lic-card-title{
  font-family:var(--slab);
  font-size:1.15rem;
  font-weight:500;
  line-height:1.25;
  margin-bottom:8px;
}

.lic-card-entity{
  font-size:12px;
  opacity:0.92;
  margin-bottom:12px;
}

.lic-card-modalidad{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 12px;
  background:rgba(255, 255, 255, 0.2);
  backdrop-filter:blur(8px);
  border-radius:8px;
  font-size:11px;
  font-weight:600;
}

.lic-card-arrow{
  margin-left:auto;
  font-size:14px;
  opacity:0;
  transform:translateX(-4px);
  transition:all 0.25s;
}

.lic-card:hover .lic-card-arrow{
  opacity:1;
  transform:translateX(0);
}
.lic-empty{
  grid-column:1 / -1;
  text-align:center;
  padding:80px 24px;
}

.lic-empty i{
  font-size:48px;
  color:#ddd;
  margin-bottom:16px;
}

.lic-empty p{
  font-size:16px;
  color:var(--muted);
}
@media (max-width: 768px){
  .lic-bento{
    grid-template-columns:1fr;
    grid-auto-rows:220px;
  }

  .lic-card.lic-card--wide{
    grid-column:span 1;
  }

  .lic-card.lic-card--tall{
    grid-row:span 1;
  }

  .lic-filters-lic .form-select{
    min-width:100%;
  }

  .lic-search-wrap--toolbar,
  .lic-entidad-wrap--toolbar{
    width:200px;
  }

  .lic-chips--se-style .lic-chip{
    padding:10px 14px;
    font-size:12px;
  }
}
