/**
 * EngageIQ site-wide typography contract v4
 * Authority: EngageIQ-Codex / 01 — Approved / Review
 * Measurable reference: protected approved homepage
 *
 * This layer closes legacy Elementor specificity gaps after the shared brand
 * foundation. It does not change page copy or invent a new type scale.
 */

body.ei-brand-sot :where(
    .elementor-button,
    .wp-element-button,
    button,
    input[type="button"],
    input[type="submit"],
    input[type="reset"]
  ) {
  font-family: var(--ei-font-body, "Inter Tight", Arial, sans-serif) !important;
  font-size: var(--ei-button-font-size, 16px) !important;
  font-weight: var(--ei-button-font-weight, 500) !important;
  line-height: 1 !important;
}

/**
 * The homepage header is a normal-flow design element: it remains at the top
 * of the document and scrolls away with the page. Header template 829 carried
 * a fixed-position rule that made its logo and menu follow the viewport.
 */
body.ei-brand-sot .elementor-location-header {
  position: relative !important;
  inset: auto !important;
}

body.ei-brand-sot
  .elementor-location-header
  > .elementor-element {
  position: relative !important;
  inset: auto !important;
  width: 100% !important;
  transform: none !important;
}

/**
 * Canonical static header for the five standalone pages that did not include
 * either approved Elementor header template.
 */
body.ei-brand-sot .ei-canonical-header {
  box-sizing: border-box;
  position: relative;
  z-index: 50;
  width: 100%;
  padding: 22px 48px;
  color: var(--ei-color-black, #000000);
  background: var(--ei-color-white, #ffffff);
}

body.ei-brand-sot .ei-canonical-header *,
body.ei-brand-sot .ei-canonical-header *::before,
body.ei-brand-sot .ei-canonical-header *::after {
  box-sizing: border-box;
}

body.ei-brand-sot .ei-canonical-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(100%, var(--ei-content-max, 1376px));
  min-height: 102px;
  margin: 0 auto;
  padding: 0 32px;
  background: var(--ei-color-white, #ffffff);
}

body.ei-brand-sot .ei-canonical-header__logo {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  min-width: 56px;
  min-height: 56px;
}

body.ei-brand-sot .ei-canonical-header__logo img {
  display: block;
  width: auto;
  height: 56px;
}

body.ei-brand-sot .ei-canonical-header__desktop-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-left: auto;
  padding: 0 !important;
  color: inherit;
  background: transparent;
}

body.ei-brand-sot .ei-canonical-header a,
body.ei-brand-sot .ei-canonical-header summary {
  color: inherit;
  font-family: var(--ei-font-body, "Inter Tight", Arial, sans-serif) !important;
  font-size: 16px;
  font-weight: var(--ei-weight-medium, 500);
  line-height: 1;
  text-decoration: none;
}

body.ei-brand-sot .ei-canonical-header__group {
  position: relative;
}

body.ei-brand-sot .ei-canonical-header__group > summary {
  display: flex;
  align-items: center;
  min-height: 44px;
  gap: 8px;
  cursor: pointer;
  list-style: none;
}

body.ei-brand-sot
  .ei-canonical-header__group
  > summary::-webkit-details-marker,
body.ei-brand-sot .ei-canonical-header__mobile > summary::-webkit-details-marker {
  display: none;
}

body.ei-brand-sot .ei-canonical-header__group > summary::after {
  width: 8px;
  height: 8px;
  border-right: 1.5px solid currentcolor;
  border-bottom: 1.5px solid currentcolor;
  content: "";
  transform: translateY(-2px) rotate(45deg);
}

body.ei-brand-sot .ei-canonical-header__dropdown {
  position: absolute;
  top: calc(100% + 12px);
  left: -24px;
  display: grid;
  min-width: 260px;
  padding: 16px;
  gap: 4px;
  border: 1px solid var(--ei-color-border, #e4e4e4);
  background: var(--ei-color-white, #ffffff);
  box-shadow: none;
}

body.ei-brand-sot .ei-canonical-header__dropdown a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
}

body.ei-brand-sot .ei-canonical-header a:hover,
body.ei-brand-sot .ei-canonical-header summary:hover {
  color: var(--ei-color-red, #ff3c41);
}

body.ei-brand-sot .ei-canonical-header__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 14px 24px;
  border: 1px solid var(--ei-color-black, #000000);
}

body.ei-brand-sot .ei-canonical-header__mobile {
  display: none;
}

/**
 * The desktop compliance-card rows were authored as four 25% items plus an
 * 8px end margin on every item. Subtract that margin from each basis so the
 * row retains four equal cards without widening the document by 24px.
 */
@media (min-width: 1025px) {
  body.page-id-3138
    .elementor-element-a86fb3c
    > .e-con,
  body.page-id-3138
    .elementor-element-ea353b6
    > .e-con {
    --width: calc(25% - 8px) !important;
  }
}

@media (max-width: 767px) {
  /**
   * These shared Elementor IDs identify the "Problem / Challenge" band used by
   * the affected use-case templates. Their generated CSS carried a fixed
   * desktop line-height into mobile.
   */
  body.ei-brand-sot
    .elementor-element-a76858a
    > .elementor-heading-title {
    line-height: 1.08 !important;
  }

  /**
   * Comparison tables keep their column semantics and become independently
   * scrollable rather than widening the page.
   */
  body.ei-brand-sot table {
    display: block;
    width: 100%;
    max-width: 100% !important;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
  }

  /**
   * Standalone research and whitepaper pages use a direct child nav instead of
   * the Elementor header. Allow those approved links to wrap within the same
   * mobile canvas.
   */
  body.ei-brand-sot > nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    max-width: 100%;
  }

  body.ei-brand-sot > nav > a {
    margin-right: 0 !important;
  }

  /**
   * Legacy Elementor loop cards retained fixed desktop widths. A mobile loop
   * shows one full-width card while its own swiper/loop controls retain
   * horizontal behavior.
   */
  body.ei-brand-sot .e-loop-item,
  body.ei-brand-sot .e-loop-item > .e-con-boxed,
  body.ei-brand-sot .e-loop-item > .e-con-boxed > .e-con-inner {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  body.ei-brand-sot .e-loop-item img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto;
  }

  /**
   * The WordPress article export omitted the core mobile column rules. Reflow
   * article columns and media without changing their desktop composition.
   */
  body.ei-brand-sot .wp-block-columns {
    flex-wrap: wrap !important;
  }

  body.ei-brand-sot .wp-block-columns > .wp-block-column {
    flex-basis: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  body.ei-brand-sot .wp-block-image,
  body.ei-brand-sot .wp-block-image img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto;
  }

  body.ei-brand-sot .wp-block-image {
    margin-inline: 0 !important;
  }

  body.ei-brand-sot .ei-canonical-header {
    padding: 18px 12px;
  }

  body.ei-brand-sot .ei-canonical-header__inner {
    min-height: 48px;
    padding: 0 28px 0 36px;
  }

  body.ei-brand-sot .ei-canonical-header__logo,
  body.ei-brand-sot .ei-canonical-header__logo img {
    min-width: 0;
    min-height: 48px;
    height: 48px;
  }

  body.ei-brand-sot .ei-canonical-header__desktop-nav {
    display: none;
  }

  body.ei-brand-sot .ei-canonical-header__mobile {
    position: relative;
    display: block;
  }

  body.ei-brand-sot .ei-canonical-header__mobile > summary {
    display: grid;
    place-items: center;
    width: 32px;
    height: 48px;
    border: 0;
    cursor: pointer;
    list-style: none;
  }

  body.ei-brand-sot .ei-canonical-header__bars,
  body.ei-brand-sot .ei-canonical-header__bars::before,
  body.ei-brand-sot .ei-canonical-header__bars::after {
    display: block;
    width: 22px;
    height: 2px;
    background: currentcolor;
    content: "";
  }

  body.ei-brand-sot .ei-canonical-header__bars {
    position: relative;
  }

  body.ei-brand-sot .ei-canonical-header__bars::before {
    position: absolute;
    top: -7px;
  }

  body.ei-brand-sot .ei-canonical-header__bars::after {
    position: absolute;
    top: 7px;
  }

  body.ei-brand-sot .ei-canonical-header__mobile-menu {
    position: absolute;
    top: calc(100% + 18px);
    right: -40px;
    display: grid;
    width: 100vw;
    padding: 20px;
    gap: 4px;
    border-top: 1px solid var(--ei-color-border, #e4e4e4);
    background: var(--ei-color-white, #ffffff);
  }

  body.ei-brand-sot .ei-canonical-header__mobile-menu a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 8px;
  }

  body.ei-brand-sot .ei-canonical-header__mobile-menu .ei-canonical-header__cta {
    margin-top: 8px;
  }
}
