Transport of dense fluid by an inclined gravity current can control the vertical density structure of the receiving basin in many natural and industrial settings. A case familiar to many is a lake fed by river water that is dense relative to the lake water. In laboratory experiments, we pulsed dye into the basin inflow to visualise the transport pathway of the inflow fluid through the basin. We also measured the evolving density profile as the basin filled. The experiments confirmed previous observations that when the turbulent gravity current travelled through ambient fluid of uniform density, only entrainment into the dense current occurred. When the gravity current travelled through the stratified part of the ambient fluid, however, the outer layers of the gravity current outflowed from the current by a peeling detrainment mechanism and moved directly into the ambient fluid over a large range of depths. The prevailing model of a filling box flow assumes that a persistently entraining gravity current entrains fluid from the basin as the current descends to the deepest point in the basin. This model, however, is inconsistent with the transport pathway observed in visualisations and poorly matches the stratifications measured in basin experiments. The main contribution of the present work is to extend the prevailing filling box model by incorporating the observed peeling detrainment. The analytical expressions given by the peeling detrainment model match the experimental observations of the density profiles more closely than the persistently entraining model. Incorporating peeling detrainment into multiprocess models of geophysical systems, such as lakes, will lead to models that better describe inflow behaviour.