/* ---------- Header: logo + section links + CTA ---------- */
@media (min-width: 901px) {
  .nav__inner > :not(h1),
  .navOuter .nav__btn {
    display: none !important;
  }
}

.nav h1 a .nav__icon {
  display: none !important;
}

.nav h1 a {
  visibility: hidden;
}

#pupa-logo {
  position: fixed;
  top: 12px;
  left: var(--sideMargin, 20px);
  z-index: 61;
  font-family: ZentryScreamer, "Helvetica Neue", sans-serif;
  font-weight: 900;
  font-size: 30px;
  line-height: 1;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: #fff;
  mix-blend-mode: difference;
  opacity: 0;
  transition: opacity 0.5s ease;
}

#pupa-logo.is-ready {
  opacity: 1;
}

#pupa-logo {
  left: calc(var(--sideMargin, 20px) + 40px);
}

#pupa-mark {
  position: fixed;
  top: 12px;
  left: var(--sideMargin, 20px);
  z-index: 61;
  display: block;
  width: 30px;
  height: 30px;
  opacity: 0;
  transition: opacity 0.5s ease;
}

#pupa-mark.is-ready {
  opacity: 1;
}

#pupa-mark .pn__mark {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 8px;
}

/* Page transition: same indigo as the Mesis loader (the logo halves part over it). */
.pageTransition__inner {
  background: linear-gradient(180deg, #330084 0%, #230062 100%) !important;
}

#pupa-nav {
  position: fixed;
  top: 14px;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--sideMargin, 24px);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  font-family: "Roboto Mono", "Helvetica Neue", sans-serif;
}

#pupa-nav.is-ready {
  opacity: 1;
  transform: none;
}

#pupa-nav .pn__links {
  display: flex;
  gap: 2px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(223, 223, 242, 0.82);
  border: 1px solid rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  pointer-events: auto;
}

#pupa-nav a {
  text-decoration: none;
  color: #000;
  cursor: pointer;
}

#pupa-nav .pn__link {
  display: block;
  padding: 11px 18px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: background 0.2s ease, color 0.2s ease;
}

#pupa-nav .pn__link:hover {
  background: rgba(0, 0, 0, 0.08);
}

#pupa-nav .pn__link.is-active {
  background: #000;
  color: #dfdff2;
}

#pupa-nav .pn__right {
  position: absolute;
  right: var(--sideMargin, 24px);
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

#pupa-nav .pn__x {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(223, 223, 242, 0.82);
  border: 1px solid rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  color: #000;
  pointer-events: auto;
  transition: background 0.2s ease, color 0.2s ease;
}

#pupa-nav .pn__x:hover {
  background: #000;
  color: #dfdff2;
}

#pupa-nav .pn__ca {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(223, 223, 242, 0.82);
  border: 1px solid rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  color: #000;
  font-family: inherit;
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  pointer-events: auto;
  transition: background 0.2s ease, color 0.2s ease;
}

#pupa-nav .pn__ca:hover:not(:disabled) {
  background: #000;
  color: #dfdff2;
}

#pupa-nav .pn__ca:disabled {
  cursor: default;
}

#pupa-nav .pn__ca-k {
  font-weight: 700;
}

#pupa-nav .pn__ca-v {
  min-width: 3.4em;
  text-transform: none;
  letter-spacing: 0.02em;
}

#pupa-nav .pn__ca.is-empty .pn__ca-v {
  opacity: 0.55;
  text-transform: uppercase;
}

#pupa-nav .pn__cta {
  padding: 13px 22px;
  border-radius: 999px;
  background: #5724ff;
  color: #fff !important;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  pointer-events: auto;
  transition: background 0.2s ease;
}

#pupa-nav .pn__cta:hover {
  background: #000;
}

@media (max-width: 1280px) {
  #pupa-nav .pn__ca {
    display: none;
  }
}

@media (max-width: 1100px) {
  #pupa-nav .pn__link {
    padding: 10px 12px;
  }
}

/* ---------- Footer: Mesis mark + wordmark, internal links without the external arrow ---------- */
.pupa-footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  align-self: flex-start;
  height: auto;
  font-family: ZentryScreamer, "Helvetica Neue", sans-serif;
  font-weight: 900;
  font-size: 3.2rem;
  line-height: 1;
  letter-spacing: -0.01em;
  color: inherit;
  text-decoration: none;
}

.pupa-footer-logo .pn__mark {
  display: block;
  height: 3.4rem;
  width: 3.4rem;
  border-radius: 0.8rem;
}

.columnItem:has(a[href^="/"]) .btnMain__icon {
  display: none;
}

/* ---------- Illustrative pool card on the orb (desktop) ---------- */
.pn__pool {
  display: none;
}

@media (min-width: 769px) {
  .pn__pool {
    display: block;
    position: absolute;
    left: 80%;
    top: 70%;
    z-index: 2;
    width: clamp(260px, 21vw, 380px);
    padding: 2rem 2.2rem 1.8rem;
    border-radius: 1.8rem;
    background: rgba(14, 8, 40, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 3rem 8rem rgba(60, 20, 200, 0.35);
    color: #fff;
    font-family: "Roboto Mono", "Helvetica Neue", sans-serif;
    transform: translate(-50%, -50%);
    animation: pnPoolFloat 7s ease-in-out infinite;
    pointer-events: none;
  }
}

@keyframes pnPoolFloat {
  0%,
  100% {
    transform: translate(-50%, -50%) translateY(0);
  }
  50% {
    transform: translate(-50%, -50%) translateY(-0.8rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .pn__pool {
    animation: none;
  }
}

.pn__pool-head {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.85;
}

.pn__pool-dot {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: #edff66;
  box-shadow: 0 0 1rem #edff66;
}

.pn__pool-tag {
  margin-left: auto;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  font-size: 0.95rem;
}

.pn__pool-token {
  margin-top: 1.6rem;
  font-family: ZentryScreamer, "Helvetica Neue", sans-serif;
  font-weight: 900;
  font-size: 4.2rem;
  line-height: 1;
  letter-spacing: -0.01em;
}

.pn__pool-sub {
  margin-top: 0.6rem;
  font-size: 1.2rem;
  opacity: 0.7;
}

.pn__pool-rows {
  margin: 1.8rem 0 0;
  display: grid;
  gap: 0.9rem;
}

.pn__pool-rows > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 1.25rem;
}

.pn__pool-rows dt {
  opacity: 0.65;
}

.pn__pool-rows dd {
  margin: 0;
  font-weight: 500;
}

.pn__pool-bar {
  margin-top: 1.6rem;
  height: 0.6rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  overflow: hidden;
}

.pn__pool-bar span {
  display: block;
  height: 100%;
  width: 62%;
  border-radius: inherit;
  background: #edff66;
  transform-origin: left;
  animation: pnPoolBar 2.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes pnPoolBar {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.pn__pool-barlabel {
  margin-top: 0.7rem;
  display: flex;
  justify-content: space-between;
  font-size: 1.05rem;
  opacity: 0.7;
}

.pn__pool-note {
  margin-top: 1.4rem;
  font-size: 1rem;
  opacity: 0.5;
}

@media (max-width: 900px) {
  #pupa-nav {
    display: none;
  }
}

/* ---------- Tighter vertical rhythm between home sections (desktop only) ---------- */
@media (min-width: 769px) {
  main:has(.productGrid) section.section {
    padding-top: 8rem !important;
  }

  main:has(.productGrid) section.section:not(.nmb) {
    padding-bottom: 8rem !important;
  }

  .bento__boxes {
    margin-top: 5rem !important;
  }
}

/* ---------- About images: don't flash as a flat rectangle before the frame clip is applied ---------- */
.featuresCard .frame {
  opacity: 0;
  transition: opacity 0.7s ease;
}

.featuresCard .frame.show {
  opacity: 1;
}

/* ---------- CTA buttons: hover must stay visible on black sections ---------- */
.btnMain:not(.outlined):not(.joinZentryCard__cta):has(a.fill):hover {
  color: #fff !important;
}

.btnMain:not(.outlined):not(.joinZentryCard__cta):has(a.fill):hover .btnMain__shapePath {
  fill: #5724ff !important;
}

/* ---------- Product cards: shrink to content instead of empty gradient ---------- */
.mainContent__grid {
  gap: 2.4rem !important;
}

.mainContent__grid .productGrid__item {
  height: auto !important;
  align-items: flex-start !important;
}

.mainContent__text {
  position: relative !important;
  left: auto !important;
  top: auto !important;
  margin: 3.2rem 4rem !important;
  width: auto !important;
  max-width: 64rem;
}

.mainContent__text .mainContent__description {
  font-size: 1.7rem !important;
  line-height: 1.5;
  color: rgba(0, 0, 0, 0.78) !important;
  margin-top: 1.2rem;
}

.productGrid__grid {
  gap: 2.4rem !important;
}

.productGrid__grid .subContent__item {
  aspect-ratio: auto !important;
  height: auto !important;
}

.productGrid__grid .productGrid__item {
  padding: 3.2rem 4rem;
}

.productGrid__grid .productGrid__item .productGrid__text {
  position: relative !important;
  width: auto !important;
  max-width: 60rem;
}

.productGrid__grid .productGrid__item .productGrid__title {
  color: #000 !important;
  font-size: 3.4rem !important;
  line-height: 1.05 !important;
}

.productGrid__grid .productGrid__item .productGrid__description {
  font-size: 1.7rem !important;
  line-height: 1.5;
  margin-top: 1.2rem;
}

.productGrid__ui {
  font-size: 1.7rem !important;
  max-width: 80rem !important;
  margin: 4rem 0 2.4rem;
}

@media (max-width: 768px) {
  .mainContent__text {
    margin: 2.4rem 2rem !important;
  }

  .productGrid__grid .productGrid__item {
    padding: 2.4rem 2rem;
  }
}

/* ---------- "Powered by the pools": readable list ---------- */
.nexusItem__header {
  height: auto !important;
  min-height: 2rem;
}

.nexusItem__title {
  font-size: 1.6rem !important;
  line-height: 1.2 !important;
}

.nexusItem.active .nexusItem__title {
  font-size: 3rem !important;
  line-height: 1.1 !important;
}

.nexusItem__number {
  font-size: 1.3rem;
  bottom: 0.3rem;
}

.nexusItem__description {
  font-size: 1.6rem !important;
  line-height: 1.5;
  width: 44rem !important;
  max-width: 100%;
}

.nexusItem__progress {
  top: 3rem !important;
}

.nexus__coin {
  background-color: transparent !important;
  background-image: radial-gradient(
    closest-side,
    #8a7dff 0%,
    #5724ff 42%,
    rgba(87, 36, 255, 0) 100%
  ) !important;
  opacity: 0.9;
}

.nexus__attributes {
  margin-bottom: 4vh;
}

/* no dark bar behind the header: pill, logo and buttons sit directly on the page */
header.nav .nav__bg {
  display: none !important;
}

/* About: only one card left in the join block, centre it instead of pinning it to the right half */
@media (min-width: 769px) {
  .joinZentry__inner .joinZentry__card.joinZentry__card:only-child {
    grid-column: 5 / span 8;
  }
}

/* ---------- Phones: menu links are real tap targets; wordmark stays readable over the purple menu ---------- */
@media (max-width: 768px) {
  .mobileMenu__bottomNavItem.pn__m a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding-right: 12px;
  }

  body:has(.mobileMenu:not([style*="display:none"]):not([style*="display: none"])) #pupa-logo {
    mix-blend-mode: normal;
  }

  .btnMenu::after {
    content: "";
    position: absolute;
    inset: -12px;
  }

  footer a[href="/legal/privacy"] {
    display: inline-block;
    padding: 14px 0;
  }
}

/* The "Join" card on About was removed: hide its now-empty section so no gap is left before the footer. */
.section:has(> .joinZentry) {
  display: none !important;
}
