/* Mega-menu for the MailDeck homepage nav. Mirrors the leadsonar lsx-nav
   pattern (a vanilla layer injected after hydration) but in MailDeck's light /
   blue palette. All rules are scoped under .mdx-nav / .mdx-mega so nothing here
   can reach the compiled Tailwind markup.
   Rollback: remove this file, mdx-nav.js and the two tags in index.html. */

.mdx-navbar { position: relative; }

/* ---- trigger row (replaces the flat white link list) ---- */
.mdx-nav {
  display: none;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: 30px;
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #ffffff;
}
@media (min-width: 1280px) { .mdx-nav { display: flex; } }

.mdx-nav .mdx-trig { position: relative; }
.mdx-nav a,
.mdx-nav button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  white-space: nowrap;
  transition: color .2s ease, opacity .2s ease;
}
.mdx-nav > a:hover,
.mdx-nav .mdx-trig:hover,
.mdx-nav .mdx-open > button { color: #bfdbfe; }

/* Scrolled state: the navbar pill turns white and the original links switch to
   slate-500, so the triggers have to follow or they vanish into the white. The
   class is toggled from JS by watching the (hidden) original link. */
.mdx-nav.mdx-solid { color: #64748b; }
.mdx-nav.mdx-solid > a:hover,
.mdx-nav.mdx-solid .mdx-trig:hover,
.mdx-nav.mdx-solid .mdx-open > button { color: #2563eb; }
.mdx-nav.mdx-solid .mdx-trig::after {
  background: linear-gradient(90deg, transparent, #2563eb, transparent);
}

.mdx-nav .mdx-caret {
  width: 9px; height: 9px;
  opacity: .7;
  transition: transform .22s ease, opacity .22s ease;
}
.mdx-nav .mdx-open .mdx-caret { transform: rotate(180deg); opacity: 1; }

/* active trigger gets a white underline that grows from the centre */
.mdx-nav .mdx-trig::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -10px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, #ffffff, transparent);
  transform: scaleX(0);
  transition: transform .28s cubic-bezier(.2,.8,.2,1);
}
.mdx-nav .mdx-open .mdx-trig::after { transform: scaleX(1); }

/* ---- the panel ---- */
.mdx-mega {
  position: absolute;
  top: calc(100% + 16px);
  left: 0; right: 0;
  z-index: 70;
  padding: 24px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, .08);
  box-shadow:
    0 1px 0 rgba(255,255,255,.9) inset,
    0 30px 70px -24px rgba(30, 64, 175, .28),
    0 10px 26px -14px rgba(15, 23, 42, .22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px) scale(.995);
  transform-origin: top center;
  transition: opacity .2s ease, transform .26s cubic-bezier(.2,.8,.2,1), visibility .2s;
  text-transform: none;
  letter-spacing: normal;
  font-weight: 400;
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}
/* the trigger row sets nowrap on its links; panel content inherits it through
   the card <a> wrappers, so descriptions get clipped unless it is reset here */
.mdx-mega, .mdx-mega a { white-space: normal; }
.mdx-mega::before {
  /* soft blue bloom behind the first column */
  content: '';
  position: absolute;
  left: 6%; top: -26%;
  width: 420px; height: 240px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(37, 99, 235, .10), transparent);
  pointer-events: none;
}
.mdx-open .mdx-mega { opacity: 1; visibility: visible; transform: none; }

.mdx-mega-grid { position: relative; display: grid; gap: 26px; }
.mdx-mega-grid.c3 { grid-template-columns: 1fr 1fr 290px; }
.mdx-mega-grid.c4 { grid-template-columns: 1fr 1fr 1fr 280px; }

.mdx-col-h {
  display: block;
  margin: 0 0 12px 10px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: #94a3b8;
}

.mdx-mi {
  /* !important because the compiled bundle styles `nav a` as inline-flex, and
     the mega panel lives inside <nav> */
  display: flex !important;
  align-items: flex-start;
  gap: 11px;
  padding: 9px 10px;
  border-radius: 13px;
  text-decoration: none;
  transition: background .18s ease, transform .18s ease;
}
.mdx-mi:hover { background: rgba(37, 99, 235, .06); transform: translateX(2px); }

.mdx-mi-ic {
  flex: none;
  display: grid;
  place-items: center;
  width: 32px; height: 32px;
  border-radius: 9px;
  background: rgba(37, 99, 235, .08);
  border: 1px solid rgba(37, 99, 235, .12);
  color: #2563eb;
  transition: background .18s ease, border-color .18s ease;
}
.mdx-mi-ic svg { width: 16px; height: 16px; }
/* vendor favicons: white tile so dark marks stay legible on the blue-tinted box */
.mdx-mi-ic.logo { background: #fff; border-color: rgba(15, 23, 42, .10); }
.mdx-mi-ic img { width: 18px; height: 18px; object-fit: contain; border-radius: 3px; }
.mdx-mi:hover .mdx-mi-ic.logo { background: #fff; border-color: rgba(37, 99, 235, .3); }
.mdx-mi:hover .mdx-mi-ic { background: rgba(37, 99, 235, .14); border-color: rgba(37, 99, 235, .3); }

.mdx-mi-t { display: block; font-size: 13.5px; font-weight: 700; color: #0f172a; line-height: 1.35; }
.mdx-mi-d { display: block; margin-top: 2px; font-size: 11.5px; color: #64748b; line-height: 1.45; }

/* compact rows for the round-up / featured list */
.mdx-mi.slim { padding: 7px 10px; align-items: center; }
.mdx-mi.slim .mdx-mi-ic { width: 26px; height: 26px; border-radius: 7px; }
.mdx-mi.slim .mdx-mi-ic svg { width: 13px; height: 13px; }
.mdx-mi.slim .mdx-mi-t { font-size: 12.5px; font-weight: 600; }

.mdx-all {
  display: flex !important;
  width: fit-content;
  align-items: center;
  gap: 6px;
  margin: 14px 0 0 10px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #2563eb;
  text-decoration: none;
}
.mdx-all svg { width: 12px; height: 12px; transition: transform .2s ease; }
.mdx-all:hover svg { transform: translateX(3px); }

/* ---- promo card ---- */
.mdx-promo {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 20px;
  border-radius: 18px;
  background: radial-gradient(120% 120% at 100% 0%, rgba(37, 99, 235, .12), rgba(37, 99, 235, .03) 55%), #f8fafc;
  border: 1px solid rgba(37, 99, 235, .12);
  text-decoration: none;
}
.mdx-promo::after {
  content: '';
  position: absolute;
  right: -40px; top: -40px;
  width: 150px; height: 150px;
  border-radius: 50%;
  border: 1px solid rgba(37, 99, 235, .16);
  box-shadow: 0 0 0 26px rgba(37, 99, 235, .05);
  pointer-events: none;
}
.mdx-promo-k {
  font-size: 10px; font-weight: 800; letter-spacing: .22em;
  text-transform: uppercase; color: #2563eb;
}
.mdx-promo-t { margin-top: 10px; font-size: 16px; font-weight: 800; color: #0f172a; line-height: 1.3; }
.mdx-promo-d { margin-top: 7px; font-size: 12px; color: #64748b; line-height: 1.5; }
.mdx-promo-b {
  margin-top: auto;
  padding-top: 16px;
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 11.5px; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: #2563eb;
}
.mdx-promo-b svg { width: 13px; height: 13px; transition: transform .2s ease; }
.mdx-promo:hover .mdx-promo-b svg { transform: translateX(3px); }

.mdx-promo-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.mdx-promo-tags span {
  display: inline-flex; align-items: center;
  padding: 4px 9px; border-radius: 999px;
  background: rgba(37, 99, 235, .07);
  border: 1px solid rgba(37, 99, 235, .12);
  font-size: 10.5px; font-weight: 700; color: #1d4ed8;
}

@media (prefers-reduced-motion: reduce) {
  .mdx-mega, .mdx-mi, .mdx-nav .mdx-caret, .mdx-nav .mdx-trig::after { transition: none; }
}
