.hero--gl,
.hero--2d {
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.hero--drag,
.hero--drag * {
  cursor: grabbing;
}

.hero--gl .hero__glass,
.hero--2d .hero__glass {
  cursor: auto;
  user-select: text;
  -webkit-user-select: text;
}

.hero--lost .hero__canvas,
.hero--lost .hero__fallback {
  transition-duration: 0s;
}

.hero--2d .hero__canvas--2d {
  opacity: 1;
}

.hero--2d .hero__fallback {
  opacity: 0;
}

.hero--gl .hero__scrim,
.hero--2d .hero__scrim {
  background:
    linear-gradient(0deg, var(--ink) 0%, rgba(21, 11, 19, 0.55) 9%, rgba(21, 11, 19, 0) 24%),
    linear-gradient(180deg, rgba(21, 11, 19, 0.5) 0%, rgba(21, 11, 19, 0) 18%);
}

.hero__glass {
  --gx: 50%;
  --gy: 0%;
  --glass-tint: rgba(21, 11, 19, 0.34);
  --glass-tint-2: rgba(73, 38, 61, 0.1);
  --glass-blur: 30px;
  position: relative;
  isolation: isolate;
  width: fit-content;
  max-width: 100%;
  padding: clamp(1.5rem, 1rem + 2vw, 2.75rem) clamp(1.5rem, 1rem + 2.4vw, 3.25rem);
  border-radius: clamp(1.25rem, 0.9rem + 1.4vw, 2.25rem);
  background:
    linear-gradient(180deg, var(--glass-tint) 0%, var(--glass-tint) 62%, rgba(21, 11, 19, 0.08) 100%),
    linear-gradient(135deg, var(--glass-tint-2) 0%, rgba(73, 38, 61, 0) 50%, var(--glass-tint-2) 100%);
  box-shadow:
    0 2.5rem 5rem -2rem rgba(8, 3, 7, 0.75),
    0 0.5rem 1.5rem -0.75rem rgba(8, 3, 7, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.09),
    inset 0 -1px 0 rgba(255, 255, 255, 0.03);
  transition: transform 0.6s var(--ease-out);
}

.hero__glass::before,
.hero__glass::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  pointer-events: none;
}

.hero__glass::before {
  padding: 1px;
  background:
    radial-gradient(26rem 18rem at var(--gx) var(--gy), rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0) 60%),
    linear-gradient(118deg, rgba(255, 255, 255, 0.34) 0%, rgba(255, 255, 255, 0.05) 28%, rgba(242, 166, 96, 0.2) 58%, rgba(190, 150, 222, 0.26) 82%, rgba(255, 255, 255, 0.14) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

.hero__glass::after {
  background:
    radial-gradient(24rem 15rem at var(--gx) var(--gy), rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0) 62%),
    radial-gradient(60% 45% at 100% 100%, rgba(242, 166, 96, 0.06), rgba(242, 166, 96, 0) 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0) 36%, rgba(255, 255, 255, 0) 100%);
}

@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .hero__glass {
    -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(185%) brightness(0.94);
    backdrop-filter: blur(var(--glass-blur)) saturate(185%) brightness(0.94);
  }
}

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .hero__glass {
    --glass-tint: rgba(21, 11, 19, 0.84);
    --glass-tint-2: rgba(60, 31, 50, 0.7);
  }
}

.hero__glass .hero__title {
  text-shadow: 0 1px 2px rgba(8, 3, 7, 0.45), 0 0 2.5rem rgba(21, 11, 19, 0.7);
}

.hero__glass .hero__actions {
  margin-top: clamp(1.4rem, 1rem + 1.6vw, 2rem);
  gap: 1rem 1.5rem;
}

@media (max-width: 48rem) {
  .hero__glass {
    --glass-blur: 18px;
    width: 100%;
    padding: clamp(1.3rem, 5vw, 1.8rem) clamp(1.15rem, 4.5vw, 1.6rem) clamp(1.2rem, 4.5vw, 1.6rem);
    border-radius: 1.5rem;
  }

  .hero__glass .hero__actions {
    margin-top: 1.15rem;
    gap: 0.4rem 1.1rem;
  }

  .hero__glass .link-quiet {
    min-height: 2.4rem;
  }

  .hero__glass::after {
    background:
      radial-gradient(16rem 10rem at var(--gx) var(--gy), rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0) 62%),
      linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0) 40%);
  }

  .hero--gl .hero__scrim,
  .hero--2d .hero__scrim {
    background:
      linear-gradient(0deg, var(--ink) 0%, rgba(21, 11, 19, 0.5) 7%, rgba(21, 11, 19, 0) 20%),
      linear-gradient(180deg, rgba(21, 11, 19, 0.55) 0%, rgba(21, 11, 19, 0) 16%);
  }
}
