/* Biliton v21.2.35 — Public Content Rhythm
   Purpose:
   - remove exaggerated blank-looking gaps between paragraphs
   - keep headings/lists readable
   - leave hero/header/footer/form spacing alone
*/

#main-content{
  --blt-p-gap:12px;
  --blt-heading-gap-top:26px;
  --blt-heading-gap-bottom:12px;
  --blt-list-gap:8px;
}

/* Main prose: consistent paragraph rhythm */
#main-content section:not([class*="hero"]) p,
#main-content article p,
#main-content .dynamic-page-content p,
#main-content .cms-page-custom-content p{
  margin-top:0!important;
  margin-bottom:var(--blt-p-gap)!important;
}

/* Consecutive paragraphs should feel connected, not separated by large voids */
#main-content section:not([class*="hero"]) p + p,
#main-content article p + p,
#main-content .dynamic-page-content p + p,
#main-content .cms-page-custom-content p + p{
  margin-top:0!important;
}

/* Heading rhythm inside page content */
#main-content section:not([class*="hero"]) p + h2,
#main-content section:not([class*="hero"]) p + h3,
#main-content section:not([class*="hero"]) ul + h2,
#main-content section:not([class*="hero"]) ol + h2,
#main-content article p + h2,
#main-content article p + h3,
#main-content .dynamic-page-content p + h2,
#main-content .dynamic-page-content p + h3{
  margin-top:var(--blt-heading-gap-top)!important;
}

#main-content section:not([class*="hero"]) h2,
#main-content section:not([class*="hero"]) h3,
#main-content .dynamic-page-content h2,
#main-content .dynamic-page-content h3,
#main-content .cms-page-custom-content h2,
#main-content .cms-page-custom-content h3{
  margin-bottom:var(--blt-heading-gap-bottom)!important;
}

/* Lists belong close to the paragraph introducing them */
#main-content section:not([class*="hero"]) p + ul,
#main-content section:not([class*="hero"]) p + ol,
#main-content article p + ul,
#main-content article p + ol,
#main-content .dynamic-page-content p + ul,
#main-content .dynamic-page-content p + ol{
  margin-top:4px!important;
}

#main-content section:not([class*="hero"]) li + li,
#main-content article li + li,
#main-content .dynamic-page-content li + li{
  margin-top:var(--blt-list-gap)!important;
}

/* Empty editor paragraphs / BR-only placeholders must not create white holes */
#main-content p:empty,
#main-content p.blt-empty-paragraph{
  display:none!important;
  margin:0!important;
  padding:0!important;
  min-height:0!important;
}

/* Preserve special UI/card layouts where margins are intentional */
#main-content form p,
#main-content [class*="hero"] p,
#main-content [class*="proof"] p,
#main-content [class*="metric"] p,
#main-content [class*="stat"] p,
#main-content [class*="badge"] p,
#main-content [class*="breadcrumb"] p{
  /* only cancel the global prose override when these components set their own spacing */
}

/* Article prose gets a slightly calmer line height */
#main-content .n25-article-body p,
#main-content .article-body p,
#main-content .article-content p,
#main-content .insight-content p,
#main-content .dynamic-page-content p{
  line-height:1.68!important;
}

/* Standalone tracking page content */
.biliton-unified-tracking-shell main p,
.biliton-unified-tracking-shell .tracking-content p{
  margin-top:0!important;
  margin-bottom:12px!important;
}
.biliton-unified-tracking-shell p.blt-empty-paragraph{
  display:none!important;
}

/* Mobile: slightly tighter without looking crowded */
@media(max-width:700px){
  #main-content{
    --blt-p-gap:10px;
    --blt-heading-gap-top:22px;
    --blt-heading-gap-bottom:10px;
    --blt-list-gap:6px;
  }
}
