/* Consistent heading sizes site-wide, by role (set by tools/heading_roles.py).
   The site header, footer, menus and popups are not affected. */
:root {
  --mh-page: 48px;      /* page title (H1) */
  --mh-section: 38px;   /* section titles */
  --mh-card: 22px;      /* card / item titles */
  --mh-art-h2: 30px;    /* blog article body headings */
  --mh-art-h3: 24px;
  --mh-art-h4: 20px;
  --mh-art-h5: 18px;
}
@media (max-width: 1024px) {
  :root { --mh-page: 40px; --mh-section: 32px; --mh-card: 21px; --mh-art-h2: 27px; --mh-art-h3: 22px; }
}
@media (max-width: 767px) {
  :root { --mh-page: 34px; --mh-section: 28px; --mh-card: 19px; --mh-art-h2: 24px; --mh-art-h3: 20px; --mh-art-h4: 18px; --mh-art-h5: 17px; }
}

.mh-r-page    { font-size: var(--mh-page) !important;    line-height: 1.15 !important; }
.mh-r-section { font-size: var(--mh-section) !important; line-height: 1.2 !important; }
.mh-r-card    { font-size: var(--mh-card) !important;    line-height: 1.3 !important; }
h2.mh-r-article { font-size: var(--mh-art-h2) !important; line-height: 1.25 !important; }
h3.mh-r-article { font-size: var(--mh-art-h3) !important; line-height: 1.3 !important; }
h4.mh-r-article { font-size: var(--mh-art-h4) !important; line-height: 1.35 !important; }
:is(h5, h6).mh-r-article { font-size: var(--mh-art-h5) !important; line-height: 1.4 !important; }

/* Some heading widgets set the size on inner spans; make them follow the heading. */
:is(.mh-r-page, .mh-r-section, .mh-r-card, .mh-r-article) :is(span, a, strong, em, b) {
  font-size: inherit !important;
  line-height: inherit !important;
}

/* Feature-list labels (e.g. the "SEO Audits / Keyword Research" tabs) are item titles, not section titles. */
.eael-feature-list-title.mh-r-section,
.eael-feature-list-title.mh-r-card { font-size: var(--mh-card) !important; line-height: 1.3 !important; }

/* Tab labels in service pages' tab lists (styled like headings, but coded as paragraphs). */
.e-n-tab-title-text p.title { font-size: var(--mh-card) !important; line-height: 1.3 !important; }

/* ---- Mobile/tablet header: "Get a Quote" sits beside the menu button, same height ---- */
@media (max-width: 1024px) {
  .elementor-element-d7d7a6c > .e-con-inner,
  .elementor-element-d7d7a6c.e-con { align-items: center !important; }
  .elementor-element-0dae0e9 {
    margin-left: auto !important;
    margin-right: 0 !important;
    width: auto !important;
    max-width: none !important;
    align-self: center !important;
  }
  .elementor-element-0dae0e9 .elementor-button {
    height: 44px !important;
    padding: 0 18px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 10px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }
  .elementor-element-d7d7a6c > .e-con-inner { column-gap: 10px !important; }
  .elementor-element-57c0dde {
    margin-left: 0 !important;
    align-self: center !important;
    height: auto !important;
    max-height: none !important;
  }
  .elementor-element-57c0dde .elementor-widget-container,
  .elementor-element-57c0dde .elementor-icon-wrapper { display: flex !important; line-height: 0 !important; }
  .elementor-element-57c0dde > .elementor-widget-container { margin: 0 !important; }
  .elementor-element-57c0dde .elementor-icon {
    width: 44px !important;
    height: 44px !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 10px !important;
    font-size: 22px !important;
    line-height: 1 !important;
  }
  .elementor-element-57c0dde .elementor-icon svg { width: 22px !important; height: 22px !important; }
}

/* ---- Mobile floating Call / Email / WhatsApp bar ---- */
@media (max-width: 1024px) {
  /* Leave room on the left for the live-chat button, so the two never overlap. */
  .elementor-element-a23f20b.e-con { padding-left: 92px !important; padding-right: 16px !important; padding-bottom: 16px !important; }
  /* Keep the end of every page visible above the bar. */
  body { padding-bottom: 96px !important; }
  /* The menu already lists phone and email: hide the bar while it is open. */
  body:has(.elementor-popup-modal:not([style*="display: none"])) .elementor-element-a23f20b { display: none !important; }
}

/* ---- Hero "Ad Spent" counters: keep "$75 Million+" on one line, sized to fit its card ---- */
:has(> #counter2), :has(> #counter3), :has(> #counter5) { container-type: inline-size; }
#counter2, #counter3, #counter5 { white-space: nowrap !important; font-size: min(30px, 16cqi) !important; }

/* ---- Phone/tablet menu: less empty space above the logo ---- */
@media (max-width: 1024px) {
  .elementor-element-08b5110 > .e-con-inner { padding-top: 16px !important; }
  .elementor-element-8e2ae2a img { width: auto !important; max-height: 72px !important; }
  .elementor-element-b726b74 .elementor-spacer-inner { height: 20px !important; }
}
