/* IN-CONTENT UNITS HOLD THEIR HEIGHT -- COOKINGHUB'S OWN SHEET (2026-10-15).

   Not a tomthechef copy (ad-slots.css and ad-top-hold.css are, byte for byte,
   less their marked deviations). tomthechef keeps a lazy in-content unit at
   0px until the reader is within a screen, opens it to its reserved height,
   and COLLAPSES it on any unfilled answer. CookingHub's rule is the top
   band's (M3, 2026-10-14): a reserved height HOLDS whatever Google answers.

   SO THE HEIGHT IS HELD ONE LEVEL OUT, exactly as the band's is: core/ads.py
   draws these units inside `.ttc-adhold`, a ONE-TRACK GRID whose row is the
   unit's reserved height plus the frame a filled unit is drawn in. Google's
   loader writes inline `height: auto !important` on every ancestor of its
   <ins>; it never writes `grid-template-rows`, and with `height: auto` a grid
   is exactly as tall as its track. The unit inside keeps every state the
   copied script gives it -- resting, armed, filled, orphan, empty -- inside a
   box that cannot change size, so nothing below it ever moves.

   The frame: a filled unit's box has 24px margins top and bottom, 10px
   padding top and bottom, a 1px border top and bottom, and the
   ADVERTISEMENT label (14px x 1.3 line + 4px) -- ad-slots.css. */
.ttc-adhold {
  --hold-frame: calc(24px * 2 + 10px * 2 + 1px * 2 + 14px * 1.3 + 4px);
  display: grid;
  grid-template-columns: 100%;
  grid-template-rows: calc(var(--adh-m, 0px) + var(--hold-frame));
  width: 100%;
  overflow-x: clip;
}
@media (min-width: 768px) {
  .ttc-adhold { grid-template-rows: calc(var(--adh-d, 0px) + var(--hold-frame)); }
}
/* the unit sits in the middle of the held space in every state */
.ttc-adhold > .ttc-ad { align-self: center; }
/* never taller than the hold: the <ins> asks Google for the reserved height */
.ttc-adhold .ttc-ad__in > ins.adsbygoogle { max-height: var(--adh-m, 0px); }
@media (min-width: 768px) {
  .ttc-adhold .ttc-ad__in > ins.adsbygoogle { max-height: var(--adh-d, 0px); }
}
@media print { .ttc-adhold { display: none !important; } }
