
/* =====================================================
   CATALOGO FARMACEUTICO COMPACTO
   Corrige imagenes gigantes y organiza medicamentos en tarjetas.
===================================================== */
.pageContent .catalog-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(245px,1fr));
  gap:18px;
  width:100%;
  max-width:1400px;
  margin:22px auto 40px;
  padding:0 4px;
}
.pageContent .catalog-card{
  position:relative;
  display:flex;
  flex-direction:column;
  min-width:0;
  overflow:hidden;
  background:#fff;
  border:1px solid #dcece8;
  border-radius:18px;
  box-shadow:0 8px 24px rgba(7,94,87,.08);
  transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease;
}
.pageContent .catalog-card:hover{
  transform:translateY(-4px);
  border-color:#9fd8cd;
  box-shadow:0 15px 34px rgba(7,94,87,.14);
}
.pageContent .catalog-card::before{
  content:"";
  position:absolute;
  top:0;left:0;right:0;
  height:4px;
  background:#18a58f;
  z-index:2;
}
.pageContent .catalog-card.low::before{background:#e7a51a}
.pageContent .catalog-card.critical::before{background:#ef7a45}
.pageContent .catalog-card.out::before{background:#d94b5b}
.pageContent .catalog-image{
  width:100%;
  height:150px;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:16px;
  overflow:hidden;
  background:linear-gradient(145deg,#f4fbf9,#e8f6f2);
  border-bottom:1px solid #e6f0ed;
}
.pageContent .catalog-image img{
  display:block;
  width:100%!important;
  height:100%!important;
  max-width:165px!important;
  max-height:118px!important;
  object-fit:contain!important;
  object-position:center!important;
  margin:0 auto!important;
}
.pageContent .catalog-body{
  flex:1;
  padding:16px 17px 12px;
  color:#4d6562;
  font-size:.86rem;
  line-height:1.38;
}
.pageContent .catalog-body p{margin:0 0 5px!important}
.pageContent .catalog-category{
  display:inline-block;
  max-width:100%;
  margin-bottom:9px;
  padding:4px 9px;
  overflow:hidden;
  color:#08766b;
  background:#e4f7f2;
  border-radius:999px;
  font-size:.68rem;
  font-weight:800;
  letter-spacing:.035em;
  text-overflow:ellipsis;
  white-space:nowrap;
  text-transform:uppercase;
}
.pageContent .catalog-name{
  margin:0 0 7px!important;
  color:#153e3a;
  font-size:1.08rem;
  font-weight:800;
  line-height:1.22;
  text-transform:none;
}
.pageContent .catalog-code{
  color:#7a8e8b;
  font-size:.75rem;
  word-break:break-all;
}
.pageContent .catalog-price{
  margin:10px 0 7px;
  color:#08766b;
  font-size:1.3rem;
  font-weight:900;
}
.pageContent .catalog-actions{
  display:flex;
  gap:8px;
  padding:12px 16px 16px;
  border-top:1px solid #edf3f1;
}
.pageContent .catalog-actions .button{
  flex:1;
  min-height:34px;
  border-radius:10px;
  font-weight:700;
}
@media(min-width:1500px){
  .pageContent .catalog-grid{grid-template-columns:repeat(5,minmax(220px,1fr))}
}
@media(max-width:700px){
  .pageContent .catalog-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:14px}
  .pageContent .catalog-image{height:115px;padding:10px}
  .pageContent .catalog-image img{max-width:120px!important;max-height:92px!important}
  .pageContent .catalog-body{padding:12px 11px 9px;font-size:.78rem}
  .pageContent .catalog-name{font-size:.94rem}
  .pageContent .catalog-price{font-size:1.08rem}
  .pageContent .catalog-actions{padding:9px 10px 11px;gap:5px;flex-direction:column}
}
@media(max-width:390px){
  .pageContent .catalog-grid{grid-template-columns:1fr}
}
