/* Redex branding on top of the avec layout. Colours are avec's own tokens, nothing re-themed. */

/* ---- header logo: Redex wolf + wordmark in place of the avec wordmark ---- */
a[aria-label="Redex home"] { display: inline-flex; align-items: center; gap: 7px; color: var(--color-foreground, #171717); text-decoration: none; }
a[aria-label="Redex home"] > svg { display: none; }
a[aria-label="Redex home"]::before {
  content: ""; width: 22px; height: 26px; flex: none; background: currentColor;
  -webkit-mask: url(/redex/redex-mark.png) center / contain no-repeat; mask: url(/redex/redex-mark.png) center / contain no-repeat;
}
a[aria-label="Redex home"]::after {
  content: "Redex"; font-family: var(--font-gt-standard, ui-sans-serif, system-ui, sans-serif);
  font-weight: 600; font-size: 25px; letter-spacing: -.045em; line-height: 1;
}
@media (min-width: 768px) {
  a[aria-label="Redex home"] { gap: 8px; }
  a[aria-label="Redex home"]::before { width: 27px; height: 32px; }
  a[aria-label="Redex home"]::after { font-size: 31px; }
}

/* ---- hero: no picture, text centred at the top ---- */
section[data-section-name="hero"] .section-content > div:has(img[data-nimg="fill"]) { display: none !important; }
section[data-section-name="hero"] .section-content { flex-direction: column !important; justify-content: flex-start !important; align-items: center !important; }
section[data-section-name="hero"] .section-content > div:first-child {
  flex: none !important; width: 100%; max-width: 760px !important; align-items: center !important; justify-content: flex-start !important;
  padding: clamp(96px, 17vh, 190px) 16px 0 !important; text-align: center;
}
section[data-section-name="hero"] .section-content > div:first-child > * { text-align: center !important; margin-left: auto; margin-right: auto; }
section[data-section-name="hero"] .section-content > div:first-child > div { justify-content: center !important; }
section[data-section-name="hero"] .section-content > div:first-child > p { max-width: 560px !important; }
@media (max-width: 767px) {
  section[data-section-name="hero"] .section-content > div:first-child > div:first-of-type { width: 100%; max-width: 400px; }
}

/* ---- footer headline: wolf mark instead of the avec symbol (same box, same colour) ---- */
svg[viewBox="0 0 186.377 147.734"] { display: none !important; }
span:has(> svg[viewBox="0 0 186.377 147.734"]) { display: inline-flex !important; align-items: center; }
span:has(> svg[viewBox="0 0 186.377 147.734"])::before {
  content: ""; height: 1.05em; aspect-ratio: 730 / 880; background: currentColor;
  -webkit-mask: url(/redex/redex-mark.png) center / contain no-repeat; mask: url(/redex/redex-mark.png) center / contain no-repeat;
}

/* ---- hero rating row: Solana instead of the App Store mark ---- */
svg[viewBox="0 0 88 17"] { display: none !important; }
@media (min-width: 1024px) {
  div:has(> svg[viewBox="0 0 88 17"])::before {
    content: ""; width: 21px; height: 18px; flex: none; background: currentColor; margin-right: -4px;
    -webkit-mask: url(/redex/logos/solana.svg) center / contain no-repeat; mask: url(/redex/logos/solana.svg) center / contain no-repeat;
  }
}

/* ---- icon helper used by the checkout ---- */
.ic { display: inline-flex; width: 16px; height: 16px; flex: none; }
.ic svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* ---- contract address pill ---- */
.rx-ca-row { display: flex; justify-content: center; width: 100%; }
.rx-ca {
  display: inline-flex; align-items: center; gap: 10px; max-width: 100%; padding: 7px 8px 7px 7px; border-radius: 999px;
  border: 1px solid rgba(0,0,0,.12); background: rgba(255,255,255,.7); color: var(--color-foreground, #171717);
  font: 500 14px/1 var(--font-gt-standard, ui-sans-serif, system-ui, sans-serif); letter-spacing: -.01em; cursor: pointer;
  transition: transform .12s, background-color .2s, border-color .2s;
}
.rx-ca:hover { background: #fff; border-color: rgba(0,0,0,.22); }
.rx-ca:active { transform: scale(.97); }
.rx-ca-k { flex: none; padding: 5px 9px; border-radius: 999px; background: var(--color-foreground, #171717); color: #fff; font-size: 12px; font-weight: 600; letter-spacing: .02em; }
.rx-ca.is-copied .rx-ca-k { background: var(--color-accent-green, #03ce4c); }
.rx-ca-v { min-width: 0; font-family: var(--font-mono, ui-monospace, monospace); font-size: 13px; letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rx-ca-short { display: none; }
.rx-ca-i { flex: none; display: inline-flex; width: 17px; height: 17px; color: rgba(0,0,0,.55); }
.rx-ca-i svg { width: 100%; height: 100%; }
.rx-ca.is-copied .rx-ca-i { color: var(--color-accent-green, #03ce4c); }
@media (max-width: 520px) {
  .rx-ca-full { display: none; }
  .rx-ca-short { display: inline; }
}
