/* EvenSurge navigation — desktop mega menu and mobile slide-out */

:root {
  --es-nav-ink: #08272E;
  --es-nav-teal: #0F4A52;
  --es-nav-mint: #12D3A6;
  --es-nav-orange: #FF8A3D;
  --es-nav-panel: #E3EBE7;
  --es-nav-soft: #5A6B6C;
  --es-nav-rule: rgba(15, 74, 82, .16);
  --es-nav-display: var(--ff-display, 'Space Grotesk', Arial, Helvetica, sans-serif);
  --es-nav-body: var(--ff-body, 'Inter', Arial, Helvetica, sans-serif);
  --es-nav-wrap: 1400px;
  --es-nav-top: 96px;
}

/* Old slide-out and meanmenu clone */
.side-info-wrapper,
.mean-bar {
  display: none !important;
}

/* WordPress header: one flat full-width bar under the ticker */
.es-flat-bar {
  background: linear-gradient(137deg, #000000 0%, #0F4A52 49%, #0F4A52 100%);
  padding: 20px 0;
}

.es-flat-bar > .container {
  max-width: 100%;
  width: 100%;
  padding-left: clamp(16px, 3vw, 48px);
  padding-right: clamp(16px, 3vw, 48px);
}

.es-flat-bar .custom-nave {
  background: none;
  border-radius: 0;
  padding: 0;
  margin-top: 0;
}

/* ============================================================ desktop tab bar */

.es-nav,
.es-nav * {
  box-sizing: border-box;
}

.es-nav .es-nav-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.es-nav .es-nav-tabs > li {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Outranks the theme fork's .main-menu li spacing */
.es-nav .es-nav-tabs > li:not(:last-child),
.es-nav .es-nav-tabs > li:last-child {
  margin: 0;
}

/* Header CTA radius, against the theme fork's 38px */
.tp-header-11-btn-box .tp-btn-black-radius {
  border-radius: 15px;
}

.es-nav .es-nav-tab {
  appearance: none;
  -webkit-appearance: none;
  background: none;
  border: 0;
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  border-radius: 10px;
  font-family: var(--es-nav-display);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0;
  color: #EAF3F1;
  text-decoration: none;
  white-space: nowrap;
  transition: color .15s ease;
}

.es-nav .es-nav-tab:hover,
.es-nav .es-nav-tab:focus,
.es-nav .es-nav-tab[aria-expanded="true"] {
  color: var(--es-nav-mint);
  text-decoration: none;
}

.es-nav .es-nav-tab:focus-visible {
  outline: 2px solid var(--es-nav-mint);
  outline-offset: 2px;
}

.es-nav .es-nav-tab::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--es-nav-mint);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .22s ease;
}

.es-nav .es-nav-tab[aria-expanded="true"]::after {
  transform: scaleX(1);
}

.es-nav .es-nav-chev {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform .2s ease;
}

.es-nav .es-nav-tab[aria-expanded="true"] .es-nav-chev {
  transform: rotate(225deg) translate(-3px, -3px);
}

/* Release the flex min-content floor, or the CTA wraps */
.es-nav-col {
  min-width: 0;
}

/* ============================================================== panel surface */

.es-nav-stage {
  position: fixed;
  left: 0;
  right: 0;
  top: var(--es-nav-top);
  z-index: 9990;
  padding: 0 clamp(16px, 3vw, 48px);
  pointer-events: none;
}

.es-nav-stage .es-nav-panel {
  pointer-events: auto;
}

/* Width comes from render.php, per panel */
.es-nav-panel {
  width: min(var(--es-panel-w, 1400px), 100%);
  max-width: var(--es-nav-wrap);
  margin: 0 auto;
  padding: 10px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 26px 60px rgba(0, 0, 0, .42);
  animation: esNavDrop .18s ease-out;
  text-align: left;
}

.es-nav-panel[hidden] {
  display: none;
}

@keyframes esNavDrop {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: none; }
}

.es-nav-panel-in {
  display: block;
}

/* ------------------------------------------------------------- link grids */

.es-nav-flat,
.es-nav-body {
  background: var(--es-nav-panel);
  border-radius: 18px;
  padding: 24px 26px;
}

.es-nav-grid {
  display: grid;
  gap: 2px 0;
  background-repeat: no-repeat;
}

.es-nav-grid--1 {
  grid-template-columns: minmax(0, 1fr);
}

/* Column rule painted in the gap */
.es-nav-grid--2 {
  --es-gap: 44px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--es-gap);
  background-image: linear-gradient(var(--es-nav-rule), var(--es-nav-rule));
  background-size: 1px calc(100% - 12px);
  background-position: 50% 6px;
}

.es-nav-grid--3 {
  --es-gap: 32px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: var(--es-gap);
  background-image:
    linear-gradient(var(--es-nav-rule), var(--es-nav-rule)),
    linear-gradient(var(--es-nav-rule), var(--es-nav-rule));
  background-size: 1px calc(100% - 12px), 1px calc(100% - 12px);
  background-position:
    calc((100% - 2 * var(--es-gap)) / 3 + var(--es-gap) / 2) 6px,
    calc((100% - 2 * var(--es-gap)) / 3 * 2 + var(--es-gap) * 1.5) 6px;
}

.es-nav-grid--flush {
  background-image: none;
}

/* Flat panels fill down each column */
.es-nav-grid--down {
  grid-auto-flow: column;
  grid-template-rows: repeat(var(--es-rows, 3), auto);
}

.es-nav-item {
  display: block;
  padding: 11px 14px;
  border-radius: 11px;
  text-decoration: none;
  transition: background .14s ease;
}

.es-nav-item:hover,
.es-nav-item:focus {
  background: rgba(255, 255, 255, .8);
  text-decoration: none;
}

.es-nav-item:focus-visible {
  outline: 2px solid var(--es-nav-teal);
  outline-offset: -2px;
}

.es-nav-item-t {
  display: block;
  margin-bottom: 3px;
  font-family: var(--es-nav-display);
  font-size: 15.5px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--es-nav-ink);
}

.es-nav-item-d {
  display: block;
  font-family: var(--es-nav-body);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--es-nav-soft);
}

/* --------------------------------------------------------------- category rail */

.es-nav-split {
  display: grid;
  grid-template-columns: 272px 1fr;
  gap: 10px;
}

.es-nav-rail {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 20px 14px;
  border-radius: 18px;
  background: var(--es-nav-ink);
}

.es-nav-railbtn {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: none;
  cursor: pointer;
  display: block;
  width: 100%;
  padding: 14px 18px;
  border-radius: 14px;
  text-align: left;
  font-family: var(--es-nav-display);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.25;
  color: #DCEAE7;
  transition: background .15s ease, color .15s ease;
}

.es-nav-railbtn:hover {
  background: rgba(255, 255, 255, .09);
  color: #fff;
}

.es-nav-railbtn[aria-selected="true"] {
  background: #fff;
  color: var(--es-nav-ink);
}

.es-nav-railbtn:focus-visible {
  outline: 2px solid var(--es-nav-mint);
  outline-offset: -2px;
}

.es-nav-rail-foot {
  margin-top: auto;
  padding: 18px 18px 4px;
  border-top: 1px solid rgba(255, 255, 255, .12);
}

.es-nav-rail-foot p {
  margin: 0 0 12px;
  font-family: var(--es-nav-body);
  font-size: 13.5px;
  line-height: 1.55;
  color: #A9C6C1;
}

.es-nav-rail-foot a {
  font-family: var(--es-nav-display);
  font-size: 14px;
  font-weight: 500;
  color: var(--es-nav-mint);
  text-decoration: none;
}

.es-nav-rail-foot a:hover {
  text-decoration: underline;
}

.es-nav-cat[hidden] {
  display: none;
}

/* ---------------------------------------------------------------- promo strip */

.es-nav-promo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 6px;
  padding: 20px 26px;
  border-radius: 18px;
  background: var(--es-nav-ink);
}

.es-nav-promo-t {
  display: block;
  margin-bottom: 4px;
  font-family: var(--es-nav-display);
  font-size: 16px;
  font-weight: 500;
  color: #fff;
}

.es-nav-promo-d {
  display: block;
  font-family: var(--es-nav-body);
  font-size: 13.5px;
  line-height: 1.5;
  color: #9FBDB8;
}

.es-nav-promo-cta {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 9px 10px 9px 20px;
  border: 1px solid var(--es-nav-mint);
  border-radius: 14px;
  font-family: var(--es-nav-display);
  font-size: 15px;
  font-weight: 500;
  color: var(--es-nav-mint);
  text-decoration: none;
}

.es-nav-promo-cta:hover {
  color: var(--es-nav-mint);
  text-decoration: none;
}

.es-nav-promo-cta i {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--es-nav-orange);
  display: grid;
  place-items: center;
}

.es-nav-promo-cta i::before {
  content: "";
  width: 10px;
  height: 10px;
  border-top: 2px solid var(--es-nav-ink);
  border-right: 2px solid var(--es-nav-ink);
  transform: rotate(45deg) translate(-1px, 1px);
}

/* ------------------------------------------------------------ narrower desktop */

/* Tighten as the bar narrows */
@media (max-width: 1439.98px) {
  .es-nav .es-nav-tab { padding: 10px 11px; font-size: 15px; }
}

@media (max-width: 1279.98px) {
  .es-nav .es-nav-tab { padding: 9px 8px; font-size: 14px; gap: 6px; }
  .es-nav .es-nav-tab::after { left: 8px; right: 8px; }

  .es-nav-grid--3 {
    --es-gap: 44px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    background-image: linear-gradient(var(--es-nav-rule), var(--es-nav-rule));
    background-size: 1px calc(100% - 12px);
    background-position: 50% 6px;
  }

  .es-nav-split { grid-template-columns: 232px 1fr; }
}

/* Hidden below 1200px with the bar */
@media (max-width: 1199.98px) {
  .es-nav-stage { display: none; }
}

/* =============================================================== mobile drawer */

.es-drawer {
  position: fixed;
  inset: 0;
  z-index: 10000030;
  display: flex;
  flex-direction: column;
  background: var(--es-nav-ink);
  font-family: var(--es-nav-body);
  color: #fff;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity .2s ease, transform .2s ease, visibility 0s linear .2s;
}

.es-drawer.is-open {
  visibility: visible;
  opacity: 1;
  transform: none;
  transition: opacity .2s ease, transform .2s ease;
}

/* A closed drawer must not catch taps */
.es-drawer:not(.is-open) {
  pointer-events: none;
}

.es-drawer:not(.is-open) .es-drawer-view {
  visibility: hidden;
  pointer-events: none;
}

.es-drawer * {
  box-sizing: border-box;
}

.es-drawer-top {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 70px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.es-drawer-top img {
  max-height: 34px;
  width: auto;
}

.es-drawer-close {
  appearance: none;
  -webkit-appearance: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 12px;
  border: 1px solid rgba(18, 211, 166, .3);
  background: none;
  cursor: pointer;
  position: relative;
  color: var(--es-nav-mint);
}

.es-drawer-close::before,
.es-drawer-close::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 2px;
  margin: -1px 0 0 -8px;
  border-radius: 2px;
  background: currentColor;
}

.es-drawer-close::before { transform: rotate(45deg); }
.es-drawer-close::after  { transform: rotate(-45deg); }

.es-drawer-crumb {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.es-drawer-crumb[hidden] {
  display: none;
}

.es-drawer-back {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  cursor: pointer;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: rgba(18, 211, 166, .1);
  display: grid;
  place-items: center;
}

.es-drawer-back::before {
  content: "";
  width: 9px;
  height: 9px;
  border-left: 2px solid var(--es-nav-mint);
  border-bottom: 2px solid var(--es-nav-mint);
  transform: rotate(45deg) translate(1px, -1px);
}

.es-drawer-crumb-t {
  display: block;
  font-family: var(--es-nav-display);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
  color: #fff;
}

.es-drawer-crumb-s {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  line-height: 1.4;
  color: #8FADA8;
}

.es-drawer-views {
  flex: 1 1 auto;
  position: relative;
  overflow: hidden;
}

/* Levels slide; `hidden` is only the no-JS fallback */
.es-drawer-view {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateX(100%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: transform .26s cubic-bezier(.3, .7, .3, 1), opacity .2s ease,
              visibility 0s linear .26s;
}

.es-drawer-view[hidden] {
  display: none;
}

.es-drawer-view.is-rest {
  transform: none;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: transform .26s cubic-bezier(.3, .7, .3, 1), opacity .2s ease;
}

.es-drawer-view.is-left {
  transform: translateX(-28%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.es-row {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 17px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  text-align: left;
  text-decoration: none;
  color: #fff;
}

.es-row:hover,
.es-row:focus {
  color: #fff;
  text-decoration: none;
}

.es-row:active {
  background: rgba(255, 255, 255, .05);
}

.es-row:focus-visible {
  outline: 2px solid var(--es-nav-mint);
  outline-offset: -2px;
}

.es-row-lbl {
  flex: 1 1 auto;
  min-width: 0;
}

.es-row-lbl strong {
  display: block;
  font-family: var(--es-nav-display);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.35;
}

.es-row-go {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-top: 2px solid var(--es-nav-mint);
  border-right: 2px solid var(--es-nav-mint);
  transform: rotate(45deg);
}

.es-row--leaf .es-row-go {
  border-color: rgba(255, 255, 255, .28);
}

.es-drawer-foot {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.es-drawer-foot .es-drawer-cta {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  padding: 14px 16px;
  border-radius: 15px;
  background: var(--es-nav-mint);
  font-family: var(--es-nav-display);
  font-size: 15.5px;
  font-weight: 500;
  color: var(--es-nav-ink);
  text-decoration: none;
}

.es-drawer-foot .es-drawer-cta:hover {
  color: var(--es-nav-ink);
  text-decoration: none;
}

.es-drawer-foot .es-drawer-icon {
  flex: 0 0 auto;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  border: 1px solid rgba(18, 211, 166, .3);
  color: var(--es-nav-mint);
  font-size: 19px;
  text-decoration: none;
}

.es-drawer-foot .es-drawer-icon:hover {
  color: var(--es-nav-mint);
}

.es-drawer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 18px 20px 26px;
  list-style: none;
  margin: 0;
}

.es-drawer-social li { margin: 0; }

.es-drawer-social a {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .12);
  color: #DCEAE7;
  font-size: 17px;
  text-decoration: none;
}

.es-drawer-social a:hover {
  border-color: var(--es-nav-mint);
  color: var(--es-nav-mint);
}

.es-drawer-meta {
  padding: 20px 20px 4px;
}

.es-drawer-meta-h {
  display: block;
  margin-bottom: 8px;
  font-family: var(--es-nav-display);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #6E8F8A;
}

.es-drawer-meta a {
  display: block;
  padding: 4px 0;
  font-size: 14.5px;
  color: #DCEAE7;
  text-decoration: none;
}

.es-drawer-meta a:hover {
  color: var(--es-nav-mint);
}

body.es-nav-locked {
  overflow: hidden;
}

@media (min-width: 1200px) {
  .es-drawer { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .es-nav-panel { animation: none; }
  .es-nav .es-nav-tab::after,
  .es-nav .es-nav-chev,
  .es-drawer,
  .es-drawer-view { transition: none; }
}
