/* ECHO_UNIFIED_BANNER_VISUAL_V1_START
   Visual-only bridge for the Macro header.
   The public, portal, and pricing pages already use the canonical .site-header
   design. These rules make Macro's independent .echo-* header use the same
   dimensions, colors, typography, dropdown treatment, and search treatment.
   No navigation markup, route attributes, hrefs, or JavaScript are changed. */

.echo-site-header-host {
  position: sticky;
  top: 0;
  z-index: 2000;
  width: 100%;
  height: 76px;
  min-height: 76px;
  background: rgba(251, 248, 240, 0.94);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(17, 42, 72, 0.14);
  box-shadow: none;
}

.echo-nav-inner {
  width: 100%;
  max-width: none;
  height: 76px;
  margin: 0;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  display: flex;
  align-items: center;
  gap: 18px;
}

.echo-wordmark {
  min-width: 205px;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #162130;
  font: 500 1.3rem Georgia, "Times New Roman", serif;
  letter-spacing: normal;
  line-height: 1.08;
  text-decoration: none;
  text-transform: none;
}

.echo-wordmark::before {
  content: "E";
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #0b1f38;
  color: #f2c94c;
  font: 600 1.35rem Georgia, "Times New Roman", serif;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.echo-primary-nav {
  min-width: 0;
  height: auto;
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  overflow: visible;
  white-space: nowrap;
}

.echo-nav-dropdown {
  position: relative;
  height: auto;
  display: block;
}

.echo-nav-link,
.echo-nav-toggle {
  width: auto;
  height: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 10px 0;
  border: 0;
  background: transparent;
  color: #435163;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  box-shadow: none;
}

.echo-nav-link:hover,
.echo-nav-toggle:hover,
.echo-nav-link:focus-visible,
.echo-nav-toggle:focus-visible,
.echo-nav-link.active,
.echo-nav-dropdown.open > .echo-nav-toggle {
  background: transparent;
  color: #0b1f38;
  outline: none;
  box-shadow: none;
}

.echo-nav-toggle span {
  color: #667383;
  font-size: 0.78rem;
  transition: transform 0.18s ease;
}

.echo-nav-dropdown.open .echo-nav-toggle span,
.echo-nav-dropdown:hover .echo-nav-toggle span,
.echo-nav-dropdown:focus-within .echo-nav-toggle span {
  transform: rotate(180deg);
}

.echo-dropdown-menu,
.echo-dropdown-menu-about,
.echo-dropdown-menu-securities,
.echo-dropdown-menu-institutional {
  position: absolute;
  top: calc(100% + 9px);
  left: -18px;
  z-index: 2120;
  width: auto;
  min-width: 280px;
  grid-template-columns: 1fr;
  gap: 3px;
  padding: 10px;
  border: 1px solid rgba(17, 42, 72, 0.14);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.985);
  box-shadow: 0 22px 56px rgba(8, 25, 46, 0.18);
}

.echo-dropdown-menu-securities,
.echo-dropdown-menu-institutional {
  min-width: 330px;
}

.echo-menu-link {
  width: 100%;
  display: grid;
  gap: 2px;
  padding: 11px 12px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #162130;
  text-align: left;
  white-space: normal;
}

.echo-menu-link:hover,
.echo-menu-link:focus-visible {
  background: #f2f5f8;
  outline: none;
}

.echo-menu-link strong {
  color: #0b1f38;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 0.84rem;
  font-weight: 780;
  letter-spacing: 0;
}

.echo-menu-link span {
  color: #667383;
  font-size: 0.7rem;
  line-height: 1.35;
}

.echo-header-search {
  position: relative;
  width: clamp(190px, 18vw, 255px);
  min-width: 0;
  flex: 0 1 255px;
  margin-left: 0;
}

.echo-header-search::before {
  content: "⌕";
  position: absolute;
  left: 13px;
  top: 50%;
  z-index: 2;
  transform: translateY(-51%);
  color: #173b64;
  font-size: 1rem;
  pointer-events: none;
}

.echo-header-search input {
  width: 100%;
  height: auto;
  border: 1px solid rgba(17, 42, 72, 0.14);
  border-radius: 999px;
  background: #ffffff;
  color: #162130;
  padding: 9px 14px 9px 37px;
  font-size: 0.84rem;
  outline: none;
}

.echo-header-search input::placeholder {
  color: #667383;
}

.echo-header-search input:focus {
  border-color: #f2c94c;
  box-shadow: 0 0 0 3px rgba(242, 201, 76, 0.14);
}

@media (hover: hover) and (min-width: 1101px) {
  .echo-nav-dropdown:hover .echo-dropdown-menu {
    display: grid;
  }

  .echo-nav-dropdown:hover .echo-nav-toggle {
    background: transparent;
    color: #0b1f38;
  }
}

@media (max-width: 1260px) {
  .echo-nav-inner {
    gap: 12px;
  }

  .echo-primary-nav {
    gap: 12px;
  }

  .echo-nav-link,
  .echo-nav-toggle {
    padding: 10px 0;
    font-size: 0.8rem;
  }

  .echo-header-search {
    flex-basis: 190px;
  }
}

@media (max-width: 1100px) {
  .echo-site-header-host {
    height: auto;
    min-height: 76px;
  }

  .echo-nav-inner {
    height: auto;
    min-height: 76px;
    flex-wrap: wrap;
    padding: 0 24px;
  }

  .echo-wordmark {
    height: 76px;
  }

  .echo-primary-nav {
    order: 4;
    width: 100%;
    height: auto;
    display: none;
    align-items: stretch;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 12px;
    border: 1px solid rgba(17, 42, 72, 0.14);
    border-radius: 0 0 14px 14px;
    background: rgba(251, 248, 240, 0.99);
    box-shadow: 0 20px 60px rgba(8, 25, 46, 0.12);
  }

  .echo-site-header-host.nav-open .echo-primary-nav {
    display: flex;
  }

  .echo-nav-link,
  .echo-nav-toggle {
    width: 100%;
    height: auto;
    justify-content: space-between;
    padding: 11px 10px;
    color: #435163;
    text-align: left;
  }

  .echo-dropdown-menu,
  .echo-dropdown-menu-about,
  .echo-dropdown-menu-securities,
  .echo-dropdown-menu-institutional {
    position: static;
    width: 100%;
    min-width: 0;
    grid-template-columns: 1fr;
    gap: 2px;
    margin: 0 0 6px 8px;
    padding: 3px 0 3px 8px;
    border: 0;
    border-left: 2px solid #e5d8c1;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .echo-header-search {
    margin-left: auto;
    flex: 0 1 310px;
  }
}

@media (max-width: 720px) {
  .echo-site-header-host {
    min-height: 66px;
  }

  .echo-nav-inner {
    min-height: 66px;
    padding-inline: 14px;
  }

  .echo-wordmark {
    min-width: auto;
    height: 66px;
  }

  .echo-header-search {
    width: min(220px, calc(100vw - 145px));
    flex: 1 1 auto;
  }

  .echo-header-search input {
    padding-top: 8px;
    padding-bottom: 8px;
  }
}

/* ECHO_UNIFIED_BANNER_VISUAL_V1_END */
