
  .fondo-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
  }
  .fondo-modal.activo {display: flex; opacity: 1;}

  .contenedor-modal {
    background-color: white;
    border-radius: 0px;
    width: 90%;
    height: 60%;
    max-width: 700px;
    max-height: 600px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    overflow-y: auto;   /* scroll vertical si se pasa */
  }

  .contenedor-modal::-webkit-scrollbar {
    width: 8px;
  }
  
  .contenedor-modal::-webkit-scrollbar-track {
    background: #928f8f;     /* track oscuro */
  }
  
  .contenedor-modal::-webkit-scrollbar-thumb {
    background: #130b75;  /* scroll azul */
    border-radius: 4px;
  }

  .fondo-modal.activo .contenedor-modal {transform: scale(1);}


  .encabezado-modal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
    background-color: #f8f9fa;
  }
  .titulo-modal {font-size: 24px; font-weight: 600; color: #1b11a3;}
  .boton-cerrar {
    background: none; border: none;
    font-size: 24px; cursor: pointer;
    color: #666; padding: 5px;
    transition: color 0.3s;
  }
  .boton-cerrar:hover {color: #000;}

  .contenido-modal {display: flex; padding: 0;}
  .imagen-modal {
    flex: 1; min-height: 300px;
    display: flex; align-items: center; justify-content: center;
    max-width: 250px;
    max-height: 250px;
  }
  .imagen-modal img {
    width: 100%; height: 100%;
    object-fit: cover;
    padding: 20px;
  }
  .texto-modal {flex: 1; padding: 30px; background-color: white;}
  .texto-modal p {
    line-height: 1.5; color: #555;
    margin-bottom: 15px; font-size: 15px;
    text-align: justify;
  }
  .texto-modal p:last-child {margin-bottom: 0;}

  @media (max-width: 768px) {
    .contenido-modal {flex-direction: column; align-items: center;}
    .imagen-modal {width: 250px; height: 250px; justify-content: center; align-items: center;}
    .contenedor-modal {width: 95%; max-height: 95vh;}
    .titulo-modal {font-size: 20px;}
  }
  @media (max-width: 480px) {
    .encabezado-modal {padding: 15px;}
    .texto-modal {padding: 20px;}
  }