/* 제휴 배너 자리 — src/js/ads.js 가 [data-ad-slot] 패널을 채운다.
 * 패널은 배너가 늦게 떠도 본문이 밀리지 않게 처음부터 배너 높이 + 라벨·문구 줄만큼 높이를 갖는다.
 * 배너 로드 실패·제외 페이지·폭 미달이면 JS 가 패널째 제거한다(빈 상자 금지).
 * 배너 높이는 site.css 의 --ad-h(100px)·--ad-side-h(600px) 를 쓴다(affiliate.json banner 크기와 짝). */
[data-ad-slot] {
  display: flex; flex-direction: column; gap: 4px; box-sizing: border-box;
  padding: 8px 12px 12px; margin: 4px 0;
  background: var(--card); border: 1px solid var(--line); border-top: 3px solid var(--steel); border-radius: var(--r);
}
[data-ad-slot] .ad-label {
  align-self: flex-start; padding: 1px 6px; border-radius: var(--r-badge);
  background: var(--steel); color: var(--steel-tx); font-size: .7rem; font-weight: 800;
}
[data-ad-slot] .ad-body {
  display: flex; justify-content: center; overflow: hidden;
  min-height: var(--ad-h); border: 0; border-radius: 0; background: transparent;
}
[data-ad-slot] .ad-disc { margin: 0; font-size: .7rem; line-height: 1.5; color: var(--muted); min-height: 3em; }
@media (min-width: 641px) { [data-ad-slot] .ad-disc { min-height: 1.5em; } }
/* PC 폭에서는 본문 배너가 680x140(affiliate.json inline.wide 와 짝) */
@media (min-width: 960px) { [data-ad-slot] .ad-body { min-height: 140px; } }

/* 측면 레일 — 1560px 이상에서만(JS 의 rail_min_width 와 짝). 위치는 site.css 의 .side 규칙을 따른다 */
.ad-side[data-ad-slot] { width: 178px; padding: 8px; }
.ad-side[data-ad-slot] .ad-body { width: 160px; min-height: var(--ad-side-h); }
@media (max-width: 1559px) { .ad-side[data-ad-slot] { display: none !important; } }
